summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/pfsense-utils.inc7
1 files changed, 7 insertions, 0 deletions
diff --git a/etc/inc/pfsense-utils.inc b/etc/inc/pfsense-utils.inc
index 217f068..f519962 100644
--- a/etc/inc/pfsense-utils.inc
+++ b/etc/inc/pfsense-utils.inc
@@ -794,6 +794,13 @@ function call_pfsense_method($method, $params, $timeout = 0) {
$xmlrpc_path = $g['xmlrpcpath'];
$msg = new XML_RPC_Message($method, array(XML_RPC_Encode($params)));
$cli = new XML_RPC_Client($xmlrpc_path, $xmlrpc_base_url);
+ // If the ALT PKG Repo has a username/password set, use it.
+ if($config['system']['altpkgrepo']['username'] &&
+ $config['system']['altpkgrepo']['password']) {
+ $username = $config['system']['altpkgrepo']['username'];
+ $password = $config['system']['altpkgrepo']['password'];
+ $cli->setCredentials($username, $password);
+ }
$resp = $cli->send($msg, $timeout);
if(!$resp) {
log_error("XMLRPC communication error: " . $cli->errstr);
OpenPOWER on IntegriCloud