summaryrefslogtreecommitdiffstats
path: root/usr/local/www/pkg_mgr.php
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2014-07-02 12:07:33 -0400
committerjim-p <jimp@pfsense.org>2014-07-02 12:07:33 -0400
commit7c8f3711075d9671eda430b86ac59d6013d12cae (patch)
tree7a4f6c4e9c01728a68a7bed6bfe7890823d0b40a /usr/local/www/pkg_mgr.php
parent38c7d42e4b47e9c8d968ebf2c7a5b75806d87203 (diff)
downloadpfsense-7c8f3711075d9671eda430b86ac59d6013d12cae.zip
pfsense-7c8f3711075d9671eda430b86ac59d6013d12cae.tar.gz
More refinements to the unofficial package repository warning ( Issue #484 ) -- Now also shows on Dashboard and installed package list. Cleaned up some code and shuffled things around to avoid unnecessary repetition.
Diffstat (limited to 'usr/local/www/pkg_mgr.php')
-rw-r--r--usr/local/www/pkg_mgr.php10
1 files changed, 3 insertions, 7 deletions
diff --git a/usr/local/www/pkg_mgr.php b/usr/local/www/pkg_mgr.php
index 454cedd..79e6961 100644
--- a/usr/local/www/pkg_mgr.php
+++ b/usr/local/www/pkg_mgr.php
@@ -74,7 +74,7 @@ function domTT_title($title_msg) {
//get_pkg_info only if cache file has more then $g[min_pkg_cache_file_time] seconds
$pkg_cache_file_time=($g['min_pkg_cache_file_time'] ? $g['min_pkg_cache_file_time'] : 120);
-$xmlrpc_base_url = isset($config['system']['altpkgrepo']['enable']) ? $config['system']['altpkgrepo']['xmlrpcbaseurl'] : $g['xmlrpcbaseurl'];
+$xmlrpc_base_url = get_active_xml_rpc_base_url();
if (!file_exists("{$g['tmp_path']}/pkg_info.cache") || (time() - filemtime("{$g['tmp_path']}/pkg_info.cache")) > $pkg_cache_file_time) {
$pkg_info = get_pkg_info('all', array("noembedded", "name", "category", "website", "version", "status", "descr", "maintainer", "required_version", "maximum_version", "pkginfolink", "config_file"));
//create cache file after get_pkg_info
@@ -116,13 +116,9 @@ include("head.inc");
<?php
include("fbegin.inc");
+ /* Print package server mismatch warning. See https://redmine.pfsense.org/issues/484 */
if (!verify_all_package_servers())
- print_info_box(sprintf(gettext("The package server currently "
- . "configured on this firewall (%s) is NOT an official package "
- . "server. The contents of such servers cannot be verified and "
- . "may contain malicious files. To ensure that you receive "
- . "verifiable and trusted packages, return the package server "
- . "settings to their default values."), htmlspecialchars($xmlrpc_base_url)));
+ print_info_box(package_server_mismatch_message());
if ($savemsg)
print_info_box($savemsg);
OpenPOWER on IntegriCloud