diff --git a/.gitignore b/.gitignore index ceaefe5..127a552 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ poweradmin-2.1.3.tgz /poweradmin-2.1.5rc1.tgz /poweradmin-2.1.5.tgz +/poweradmin-2.1.6.tgz diff --git a/poweradmin-2.5.0-templatefix.diff b/poweradmin-2.5.0-templatefix.diff deleted file mode 100644 index 9de939b..0000000 --- a/poweradmin-2.5.0-templatefix.diff +++ /dev/null @@ -1,61 +0,0 @@ -Index: /edit.php -=================================================================== ---- /edit.php (revision 510) -+++ /edit.php (revision 512) -@@ -60,5 +60,5 @@ - success(SUC_ZONE_TEMPL_ADD); - $records = get_records_from_domain_id($zone_id); -- add_zone_templ_save_as($_POST['templ_name'], $_POST['templ_descr'], $_SESSION['userid'], $records); -+ add_zone_templ_save_as($_POST['templ_name'], $_POST['templ_descr'], $_SESSION['userid'], $records, get_zone_name_from_id($zone_id)); - } - } -Index: /inc/record.inc.php -=================================================================== ---- /inc/record.inc.php (revision 509) -+++ /inc/record.inc.php (revision 512) -@@ -1278,4 +1278,5 @@ - - if($zone_master_add == "1" || $zone_slave_add == "1") { -+ $domain = get_zone_name_from_id($zone_id); - $now = time(); - $templ_records = get_zone_templ_records($zone_template); -@@ -1283,7 +1284,7 @@ - if ((preg_match('/in-addr.arpa/i', $zone_id) && ($r["type"] == "NS" || $r["type"] == "SOA")) || (!preg_match('/in-addr.arpa/i', $zone_id))) - { -- $name = parse_template_value($r["name"], $zone_id); -+ $name = parse_template_value($r["name"], $domain); - $type = $r["type"]; -- $content = parse_template_value($r["content"], $zone_id); -+ $content = parse_template_value($r["content"], $domain); - $ttl = $r["ttl"]; - $prio = intval($r["prio"]); -@@ -1309,5 +1310,5 @@ - $query = "UPDATE zones - SET zone_templ_id = " . $db->quote($zone_template, 'integer') . " -- WHERE id = " . $db->quote($zone_id, 'integer') ; -+ WHERE domain_id = " . $db->quote($zone_id, 'integer') ; - $response = $db->exec($query); - -Index: /inc/templates.inc.php -=================================================================== ---- /inc/templates.inc.php (revision 509) -+++ /inc/templates.inc.php (revision 512) -@@ -314,5 +314,5 @@ - // Add a zone template from zone / another template. - --function add_zone_templ_save_as($template_name, $description, $userid, $records) { -+function add_zone_templ_save_as($template_name, $description, $userid, $records, $domain = null) { - global $db; - -@@ -341,7 +341,10 @@ - } - -+ $name = $domain ? preg_replace('/'.$domain.'/', '[ZONE]',$record['name']) : $record['name']; -+ $content = $domain ? preg_replace('/'.$domain.'/', '[ZONE]',$content) : $content; -+ - $query2 = "INSERT INTO zone_templ_records (zone_templ_id, name, type, content, ttl, prio) VALUES (" - . $db->quote($zone_templ_id, 'integer') . "," -- . $db->quote($record['name'], 'text') . "," -+ . $db->quote($name, 'text') . "," - . $db->quote($record['type'], 'text') . "," - . $content . "," diff --git a/poweradmin-config.inc.php b/poweradmin-config.inc.php index 399e45c..61957f0 100644 --- a/poweradmin-config.inc.php +++ b/poweradmin-config.inc.php @@ -12,5 +12,9 @@ $dns_hostmaster = "hostmaster.example.com"; $dns_ns1 = "ns1.example.com"; $dns_ns2 = "ns2.example.com"; -?> +// Security settings +// This should be changed upon install +$session_key = 'p0w3r4dm1n'; +$password_encryption = 'md5'; // or md5salt +?> diff --git a/poweradmin.spec b/poweradmin.spec index bfc5541..d62d381 100644 --- a/poweradmin.spec +++ b/poweradmin.spec @@ -1,7 +1,6 @@ -%define _default_patch_fuzz 2 Name: poweradmin -Version: 2.1.5 -Release: 2%{?dist} +Version: 2.1.6 +Release: 1%{?dist} Summary: A friendly web-based DNS administration tool for Bert Hubert's PowerDNS server Group: Applications/Internet @@ -10,7 +9,6 @@ URL: http://www.poweradmin.org Source0: https://www.poweradmin.org/download/%{name}-%{version}.tgz Source1: %{name}.conf Source2: %{name}-config.inc.php -Patch0: poweradmin-2.5.0-templatefix.diff BuildArch: noarch Requires: httpd @@ -29,8 +27,6 @@ for IPv6 and comes with multi-language support. %prep %setup -q -n %{name}-%{version} -%patch0 -p1 - %build @@ -47,7 +43,6 @@ rm -rf %{buildroot} %{__cp} %{SOURCE2} %{buildroot}/%{_sysconfdir}/%{name}/config.inc.php ln -s %{_sysconfdir}/%{name}/config.inc.php %{buildroot}/%{_datadir}/%{name}/inc/config.inc.php -%{__rm} -rfv %{buildroot}/%{_datadir}/%{name}/docs %{__rm} -rfv %{buildroot}/%{_datadir}/%{name}/install %files @@ -56,11 +51,14 @@ ln -s %{_sysconfdir}/%{name}/config.inc.php %{buildroot}/%{_datadir}/%{name}/inc %config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf %dir %{_sysconfdir}/%{name} %config(noreplace) %{_sysconfdir}/%{name}/config.inc.php -%doc docs/* - +%doc LICENSE README.markdown %changelog +* Mon May 07 2012 Sven Lankes - 2.1.6-1 +- new upstream release +- remove upstreamed templatefix + * Sat Jan 14 2012 Fedora Release Engineering - 2.1.5-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild diff --git a/sources b/sources index eb7dbf5..dac31b3 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -baa773f9a95f7dc2d3ae941372238f83 poweradmin-2.1.5.tgz +364fb1343260f27beec91b0835e19729 poweradmin-2.1.6.tgz