aboutsummaryrefslogtreecommitdiffstats
path: root/config/autoconfigbackup
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2014-02-11 13:23:33 -0500
committerjim-p <jimp@pfsense.org>2014-02-11 13:23:33 -0500
commit33f2928e7e194394faf7eb3337e7ac2ef3a9949e (patch)
treebf5ee191bdc7f739858a1695d7fa267ef0017137 /config/autoconfigbackup
parent6f0bf7ee76336007a2c97270d2b8aadbc39d4771 (diff)
downloadpfsense-packages-33f2928e7e194394faf7eb3337e7ac2ef3a9949e.tar.gz
pfsense-packages-33f2928e7e194394faf7eb3337e7ac2ef3a9949e.tar.bz2
pfsense-packages-33f2928e7e194394faf7eb3337e7ac2ef3a9949e.zip
Fix ACB stats page, too
Diffstat (limited to 'config/autoconfigbackup')
-rw-r--r--config/autoconfigbackup/autoconfigbackup_stats.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/config/autoconfigbackup/autoconfigbackup_stats.php b/config/autoconfigbackup/autoconfigbackup_stats.php
index c024d689..b45d3993 100644
--- a/config/autoconfigbackup/autoconfigbackup_stats.php
+++ b/config/autoconfigbackup/autoconfigbackup_stats.php
@@ -48,13 +48,13 @@ $username = $config['installedpackages']['autoconfigbackup']['config'][0]['use
$password = $config['installedpackages']['autoconfigbackup']['config'][0]['password'];
// URL to restore.php
-$get_url = "https://{$username}:{$password}@portal.pfsense.org/pfSconfigbackups/restore.php";
+$get_url = "https://portal.pfsense.org/pfSconfigbackups/restore.php";
// URL to delete.php
-$del_url = "https://{$username}:{$password}@portal.pfsense.org/pfSconfigbackups/delete.php";
+$del_url = "https://portal.pfsense.org/pfSconfigbackups/delete.php";
// URL to stats.php
-$stats_url = "https://{$username}:{$password}@portal.pfsense.org/pfSconfigbackups/showstats.php";
+$stats_url = "https://portal.pfsense.org/pfSconfigbackups/showstats.php";
// Set hostname
$hostname = $config['system']['hostname'] . "." . $config['system']['domain'];
@@ -67,6 +67,7 @@ if(!$username) {
if($_REQUEST['delhostname']) {
$curl_session = curl_init();
curl_setopt($curl_session, CURLOPT_URL, $del_url);
+ curl_setopt($curl_session, CURLOPT_HTTPHEADER, array("Authorization: Basic " . base64_encode("{$username}:{$password}")));
curl_setopt($curl_session, CURLOPT_POST, 2);
curl_setopt($curl_session, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curl_session, CURLOPT_RETURNTRANSFER, 1);
@@ -138,6 +139,7 @@ include("head.inc");
// Populate available backups
$curl_session = curl_init();
curl_setopt($curl_session, CURLOPT_URL, $stats_url);
+ curl_setopt($curl_session, CURLOPT_HTTPHEADER, array("Authorization: Basic " . base64_encode("{$username}:{$password}")));
curl_setopt($curl_session, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($curl_session, CURLOPT_POST, 1);
curl_setopt($curl_session, CURLOPT_RETURNTRANSFER, 1);