diff --git a/src/etc/inc/pfsense-utils.inc b/src/etc/inc/pfsense-utils.inc index 3b0e1216c..27f9bdeae 100644 --- a/src/etc/inc/pfsense-utils.inc +++ b/src/etc/inc/pfsense-utils.inc @@ -93,21 +93,6 @@ function get_carp_interface_status($carpinterface) { return; } -/* - * backup_config_section($section): returns as an xml file string of - * the configuration section - */ -function backup_config_section($section_name) { - global $config; - $new_section = &$config[$section_name]; - /* generate configuration XML */ - $xmlconfig = dump_xml_config($new_section, $section_name); - $xmlconfig = str_replace("", "", $xmlconfig); - return $xmlconfig; -} - -/* KEEP THIS: unbreaks syntax highlighting array('version' => file_get_contents('/usr/local/opnsense/version/opnsense')), - 'kernel' => array('version' => file_get_contents('/usr/local/opnsense/version/opnsense-update.kernel')), - 'base' => array('version' => file_get_contents('/usr/local/opnsense/version/opnsense-update.base')), - 'config_version' => $config['version'] - ); -} - -function reload_all() -{ - configd_run('service reload all', true); -} - function setup_serial_port($sync = true) { global $config; @@ -250,25 +215,6 @@ function reload_ttys() exec('/bin/kill -HUP 1'); } - -/* Any PPPoE servers enabled? */ -function is_pppoe_server_enabled() -{ - global $config; - $pppoeenable = false; - if (!isset($config['pppoes']['pppoe']) || !is_array($config['pppoes']['pppoe'])) { - return false; - } - - foreach ($config['pppoes']['pppoe'] as $pppoes) { - if ($pppoes['mode'] == 'server') { - $pppoeenable = true; - } - } - - return $pppoeenable; -} - function add_hostname_to_watch($hostname) { if (!is_dir("/var/db/dnscache")) { mkdir("/var/db/dnscache"); diff --git a/src/etc/inc/xmlrpc/legacy.inc b/src/etc/inc/xmlrpc/legacy.inc index a9379dc94..c9af9e51b 100644 --- a/src/etc/inc/xmlrpc/legacy.inc +++ b/src/etc/inc/xmlrpc/legacy.inc @@ -1,7 +1,7 @@ array('version' => file_get_contents('/usr/local/opnsense/version/opnsense-update.kernel')), + 'base' => array('version' => file_get_contents('/usr/local/opnsense/version/opnsense-update.base')), + 'firmware' => array('version' => file_get_contents('/usr/local/opnsense/version/opnsense')), + 'config_version' => $config['version'], + ); +} /** * filter reconfigure diff --git a/src/wizard/setup.xml b/src/wizard/setup.xml index 05925e8c3..d068da071 100644 --- a/src/wizard/setup.xml +++ b/src/wizard/setup.xml @@ -632,7 +632,7 @@ diff --git a/src/www/diag_backup.php b/src/www/diag_backup.php index 1243a83c9..32eda58e6 100644 --- a/src/www/diag_backup.php +++ b/src/www/diag_backup.php @@ -40,6 +40,21 @@ require_once("rrd.inc"); require_once("system.inc"); require_once("pfsense-utils.inc"); +/* + * backup_config_section($section): returns as an xml file string of + * the configuration section + */ +function backup_config_section($section_name) { + global $config; + $new_section = &$config[$section_name]; + /* generate configuration XML */ + $xmlconfig = dump_xml_config($new_section, $section_name); + $xmlconfig = str_replace("", "", $xmlconfig); + return $xmlconfig; +} + +/* KEEP THIS: unbreaks syntax highlighting