diff options
-rwxr-xr-x | build.sh | 3 | ||||
-rw-r--r-- | src/etc/inc/dyndns.class | 14 | ||||
-rw-r--r-- | src/etc/inc/filter_log.inc | 15 | ||||
-rw-r--r-- | src/etc/inc/interfaces.inc | 74 | ||||
-rw-r--r-- | src/etc/inc/openvpn.inc | 16 | ||||
-rw-r--r-- | src/etc/inc/services.inc | 4 | ||||
-rw-r--r-- | src/etc/inc/util.inc | 9 | ||||
-rwxr-xr-x | src/etc/rc.carpbackup | 15 | ||||
-rwxr-xr-x | src/etc/rc.carpmaster | 15 | ||||
-rw-r--r-- | src/usr/local/www/css/pfSense-BETA.css | 61 | ||||
-rw-r--r-- | src/usr/local/www/css/pfSense-dark-BETA.css | 63 | ||||
-rw-r--r-- | src/usr/local/www/firewall_nat_out.php | 2 | ||||
-rw-r--r-- | src/usr/local/www/interfaces.php | 13 | ||||
-rw-r--r-- | src/usr/local/www/pkg_mgr_installed.php | 9 | ||||
-rw-r--r-- | src/usr/local/www/status_dhcpv6_leases.php | 15 | ||||
-rw-r--r-- | src/usr/local/www/widgets/widgets/installed_packages.widget.php | 2 | ||||
-rw-r--r-- | tools/builder_common.sh | 6 | ||||
-rw-r--r-- | tools/builder_defaults.sh | 3 |
18 files changed, 283 insertions, 56 deletions
@@ -362,6 +362,9 @@ elif [ "$IMAGETYPE" = "all" ]; then _IMAGESTOBUILD="iso fullupdate nanobsd nanobsd-vga memstick memstickserial" if [ "${TARGET}" = "amd64" ]; then _IMAGESTOBUILD="${_IMAGESTOBUILD} memstickadi" + if [ -n "${_IS_RELEASE}" ]; then + _IMAGESTOBUILD="${_IMAGESTOBUILD} ova" + fi fi else _IMAGESTOBUILD="${IMAGETYPE}" diff --git a/src/etc/inc/dyndns.class b/src/etc/inc/dyndns.class index bd8fa05..41f3cc4 100644 --- a/src/etc/inc/dyndns.class +++ b/src/etc/inc/dyndns.class @@ -79,6 +79,7 @@ * - Custom DDNS (any URL) * - Custom DDNS IPv6 (any URL) * - CloudFlare (www.cloudflare.com) + * - CloudFlare IPv6 (www.cloudflare.com) * - Eurodns (eurodns.com) * - GratisDNS (gratisdns.dk) * - City Network (citynetwork.se) @@ -126,7 +127,8 @@ * SelfHost - Last Tested: 26 December 2011 * Amazon Route 53 - Last tested: 01 April 2012 * DNS-O-Matic - Last Tested: 9 September 2010 - * CloudFlare - Last Tested: 30 May 2013 + * CloudFlare - Last Tested: 17 July 2016 + * CloudFlare IPv6 - Last Tested: 17 July 2016 * Eurodns - Last Tested: 27 June 2013 * GratisDNS - Last Tested: 15 August 2012 * OVH DynHOST - Last Tested: NEVER @@ -249,6 +251,7 @@ case 'custom-v6': case 'spdyn-v6': case 'freedns-v6': + case 'cloudflare-v6': $this->_useIPv6 = true; break; default: @@ -319,6 +322,7 @@ case 'he-net-tunnelbroker': case 'route53': case 'cloudflare': + case 'cloudflare-v6': case 'eurodns': case 'gratisdns': case 'ovh-dynhost': @@ -724,7 +728,10 @@ } curl_setopt($ch, CURLOPT_URL, $server); break; + case 'cloudflare-v6': case 'cloudflare': + $isv6 = ($this->_dnsService === 'cloudflare-v6'); + $recordType = $isv6 ? "AAAA" : "A"; $needsIP = TRUE; $dnsServer ='api.cloudflare.com'; $dnsHost = str_replace(' ', '', $this->_dnsHost); @@ -744,14 +751,14 @@ $output = json_decode(curl_exec($ch)); $zone = $output->result[0]->id; if ($zone) { // If zone ID was found get host ID - $getHostId = "https://{$dnsServer}/client/v4/zones/{$zone}/dns_records?name={$this->_dnsHost}"; + $getHostId = "https://{$dnsServer}/client/v4/zones/{$zone}/dns_records?name={$this->_dnsHost}&type={$recordType}"; curl_setopt($ch, CURLOPT_URL, $getHostId); $output = json_decode(curl_exec($ch)); $host = $output->result[0]->id; if ($host) { // If host ID was found update host $hostData = array( "content" => "{$this->_dnsIP}", - "type" => "A", + "type" => "{$recordType}", "name" => "{$this->_dnsHost}" ); $data_json = json_encode($hostData); @@ -1320,6 +1327,7 @@ $status = $status_intro . $error_str . gettext("Result did not match.") . " [" . $data . "]"; } break; + case 'cloudflare-v6': case 'cloudflare': $output = json_decode($data); if ($output->result->content === $this->_dnsIP) { diff --git a/src/etc/inc/filter_log.inc b/src/etc/inc/filter_log.inc index 0f9c1a2..1208711 100644 --- a/src/etc/inc/filter_log.inc +++ b/src/etc/inc/filter_log.inc @@ -66,8 +66,9 @@ function conv_log_filter($logfile, $nentries, $tail = 50, $filtertext = "", $fil return; } + /* Safety belt to ensure we get enough lines for filtering without overloading the parsing code */ if ($filtertext) { - $tail = 5000; + $tail = 10000; } /* Always do a reverse tail, to be sure we're grabbing the 'end' of the log. */ @@ -114,29 +115,29 @@ function conv_log_filter($logfile, $nentries, $tail = 50, $filtertext = "", $fil # Construct RegEx for specific log file type. - if ($logfile_type == 'firewall') { + if ($logfile_type == 'firewall') { $pattern = "filterlog:"; } - else if ($logfile_type == 'system') { + else if ($logfile_type == 'system') { $pattern = "^" . $date_pattern . "\ +" . $host_pattern . "\ +" . $process_pid_pattern . "\ +" . $log_message_pattern . "$"; } - else if ($logfile_type == 'vpn_login') { + else if ($logfile_type == 'vpn_login') { $action_pattern = "\(.*?\)"; $type_pattern = "\(.*?\)"; $ip_address_pattern = "\(.*?\)"; $user_pattern = "\(.*?\)"; $pattern = "^" . $date_pattern . "\ +" . $host_pattern . "\ +" . $process_pattern . "\ +" . $action_pattern . "\,\ *" . $type_pattern . "\,\ *" . $ip_address_pattern . "\,\ *" . $user_pattern . "$"; } - else if ($logfile_type == 'vpn_service') { + else if ($logfile_type == 'vpn_service') { $type_pattern = "\(.*?\):"; $pid_pattern = "\(?:process\ +\([0-9:]*\)\)?"; $pattern = "^" . $date_pattern . "\ +" . $host_pattern . "\ +" . $type_pattern . "\ +" . $pid_pattern . "\ *" . $log_message_pattern . "$"; } - else if ($logfile_type == 'unknown') { + else if ($logfile_type == 'unknown') { $pattern = "^" . $date_pattern . "\ +" . $log_message_pattern . "$"; } - else { + else { $pattern = "^\(.*\)$"; } diff --git a/src/etc/inc/interfaces.inc b/src/etc/inc/interfaces.inc index 4eee7bc..9d6baec 100644 --- a/src/etc/inc/interfaces.inc +++ b/src/etc/inc/interfaces.inc @@ -3061,6 +3061,22 @@ function find_dhcp6c_process($interface) { return intval($pid); } +function kill_dhcp6client_process($interface) { + if (empty($interface) || !does_interface_exist($interface)) { + return; + } + + $i = 0; + while ((($pid = find_dhcp6c_process($interface)) != 0) && ($i < 3)) { + /* 3rd time make it die for sure */ + $sig = ($i == 2 ? SIGKILL : SIGTERM); + posix_kill($pid, $sig); + sleep(1); + $i++; + } + unset($i); +} + function interface_virtual_create($interface) { global $config; @@ -3997,6 +4013,20 @@ function interface_dhcpv6_configure($interface = "wan", $wancfg) { $debugOption = isset($wancfg['dhcp6debug']) ? "-D" : "-d"; $rtsoldscript .= "/usr/local/sbin/dhcp6c {$debugOption} -c {$g['varetc_path']}/dhcp6c_{$interface}.conf -p {$g['varrun_path']}/dhcp6c_{$wanif}.pid {$wanif}\n"; $rtsoldscript .= "/usr/bin/logger -t rtsold \"Starting dhcp6 client for interface {$interface}({$wanif})\"\n"; + /* non ipoe Process */ + if (!isset($wancfg['dhcp6withoutra'])) { + $rtsoldscript .= "if [ -f {$g['varrun_path']}/dhcp6c_{$wanif}.pid ]; then\n"; + $rtsoldscript .= "\t/bin/pkill -F {$g['varrun_path']}/dhcp6c_{$wanif}.pid\n"; + $rtsoldscript .= "\t/bin/sleep 1\n"; + $rtsoldscript .= "fi\n"; + } else { + $rtsoldscript .= "\t/bin/sleep 1\n"; + } + $debugOption = isset($wancfg['dhcp6debug']) ? "-D" : "-d"; + if (!isset($wancfg['dhcp6withoutra'])) { + $rtsoldscript .= "/usr/local/sbin/dhcp6c {$debugOption} -c {$g['varetc_path']}/dhcp6c_{$interface}.conf -p {$g['varrun_path']}/dhcp6c_{$wanif}.pid {$wanif}\n"; + $rtsoldscript .= "/usr/bin/logger -t rtsold \"Starting dhcp6 client for interface {$interface}({$wanif})\"\n"; + } /* Add wide-dhcp6c shell script here. Because we can not pass a argument to it. */ if (!@file_put_contents("{$g['varetc_path']}/rtsold_{$wanif}_script.sh", $rtsoldscript)) { printf("Error: cannot open rtsold_{$wanif}_script.sh in interface_dhcpv6_configure() for writing.\n"); @@ -4015,6 +4045,12 @@ function interface_dhcpv6_configure($interface = "wan", $wancfg) { killbypid("{$g['varrun_path']}/rtsold_{$wanif}.pid"); sleep(2); } + if (isset($wancfg['dhcp6withoutra'])) { + kill_dhcp6client_process($wanif); + + mwexec("/usr/local/sbin/dhcp6c {$debugOption} -c {$g['varetc_path']}/dhcp6c_wan.conf -p {$g['varrun_path']}/dhcp6c_{$wanif}.pid {$wanif}"); + mwexec("/usr/bin/logger -t mwtag 'Starting dhcp6 client for interface wan({$wanif} in IPoE mode)'"); + } mwexec("/usr/sbin/rtsold -1 -p {$g['varrun_path']}/rtsold_{$wanif}.pid -O {$g['varetc_path']}/rtsold_{$wanif}_script.sh {$wanif}"); /* NOTE: will be called from rtsold invoked script @@ -4976,6 +5012,7 @@ function interface_find_child_cfgmtu($realiface) { $interface = convert_real_interface_to_friendly_interface_name($realiface); $vlans = link_interface_to_vlans($realiface); + $qinqs = link_interface_to_qinqs($realiface); $bridge = link_interface_to_bridge($realiface); if (!empty($interface)) { $gifs = link_interface_to_gif($interface); @@ -4999,6 +5036,19 @@ function interface_find_child_cfgmtu($realiface) { } } } + if (is_array($qinqs)) { + foreach ($qinqs as $qinq) { + $ifass = convert_real_interface_to_friendly_interface_name($qinq['vlanif']); + if (empty($ifass)) { + continue; + } + if (!empty($config['interfaces'][$ifass]['mtu'])) { + if (intval($config['interfaces'][$ifass]['mtu']) > $mtu) { + $mtu = intval($config['interfaces'][$ifass]['mtu']); + } + } + } + } if (is_array($gifs)) { foreach ($gifs as $gif) { $ifass = convert_real_interface_to_friendly_interface_name($gif['gifif']); @@ -5060,6 +5110,30 @@ function link_interface_to_vlans($int, $action = "") { } } +function link_interface_to_qinqs($int, $action = "") { + global $config; + + if (empty($int)) { + return; + } + + if (is_array($config['qinqs']['qinqentry'])) { + $ifaces = array(); + foreach ($config['qinqs']['qinqentry'] as $qinq) { + if ($int == $qinq['if']) { + if ($action == "update") { + interfaces_bring_up($int); + } else { + $ifaces[$qinq['tag']] = $qinq; + } + } + } + if (!empty($ifaces)) { + return $ifaces; + } + } +} + function link_interface_to_vips($int, $action = "", $vhid = '') { global $config; diff --git a/src/etc/inc/openvpn.inc b/src/etc/inc/openvpn.inc index 7f2897a..ecf84d0 100644 --- a/src/etc/inc/openvpn.inc +++ b/src/etc/inc/openvpn.inc @@ -1006,8 +1006,16 @@ function openvpn_reconfigure($mode, $settings) { case 'server_tls': case 'server_tls_user': case 'server_user': - $ca = lookup_ca($settings['caref']); - openvpn_add_keyfile($ca['crt'], $conf, $mode_id, "ca"); + // ca_chain() expects parameter to be passed by reference. + // avoid passing the whole settings array, as param names or + // types might change in future releases. + $param = array('caref' => $settings['caref']); + $ca = ca_chain($param); + $ca = base64_encode($ca); + + openvpn_add_keyfile($ca, $conf, $mode_id, "ca"); + + unset($ca, $param); if (!empty($settings['certref'])) { $cert = lookup_cert($settings['certref']); @@ -1124,8 +1132,8 @@ function openvpn_restart($mode, $settings) { return; } - /* Do not start a client if we are a CARP backup on this vip! */ - if (($mode == "client") && (strstr($settings['interface'], "_vip") && get_carp_interface_status($settings['interface']) != "MASTER")) { + /* Do not start an instance if we are not CARP master on this vip! */ + if (strstr($settings['interface'], "_vip") && get_carp_interface_status($settings['interface']) != "MASTER") { return; } diff --git a/src/etc/inc/services.inc b/src/etc/inc/services.inc index 947ff98..3147c3a 100644 --- a/src/etc/inc/services.inc +++ b/src/etc/inc/services.inc @@ -55,8 +55,8 @@ * OF THE POSSIBILITY OF SUCH DAMAGE. */ -define('DYNDNS_PROVIDER_VALUES', 'citynetwork cloudflare custom custom-v6 dnsexit dnsimple dnsmadeeasy dnsomatic dyndns dyndns-custom dyndns-static dyns easydns eurodns freedns freedns-v6 glesys googledomains gratisdns he-net he-net-v6 he-net-tunnelbroker loopia namecheap noip noip-free ods opendns ovh-dynhost route53 selfhost spdyn spdyn-v6 zoneedit'); -define('DYNDNS_PROVIDER_DESCRIPTIONS', 'City Network,CloudFlare,Custom,Custom (v6),DNSexit,DNSimple,DNS Made Easy,DNS-O-Matic,DynDNS (dynamic),DynDNS (custom),DynDNS (static),DyNS,easyDNS,Euro Dns,freeDNS,freeDNS (v6),GleSYS,Google Domains,GratisDNS,HE.net,HE.net (v6),HE.net Tunnelbroker,Loopia,Namecheap,No-IP,No-IP (free),ODS.org,OpenDNS,OVH DynHOST,Route 53,SelfHost,SPDYN,SPDYN (v6),ZoneEdit'); +define('DYNDNS_PROVIDER_VALUES', 'citynetwork cloudflare cloudflare-v6 custom custom-v6 dnsexit dnsimple dnsmadeeasy dnsomatic dyndns dyndns-custom dyndns-static dyns easydns eurodns freedns freedns-v6 glesys googledomains gratisdns he-net he-net-v6 he-net-tunnelbroker loopia namecheap noip noip-free ods opendns ovh-dynhost route53 selfhost spdyn spdyn-v6 zoneedit'); +define('DYNDNS_PROVIDER_DESCRIPTIONS', 'City Network,CloudFlare,CloudFlare (v6),Custom,Custom (v6),DNSexit,DNSimple,DNS Made Easy,DNS-O-Matic,DynDNS (dynamic),DynDNS (custom),DynDNS (static),DyNS,easyDNS,Euro Dns,freeDNS,freeDNS (v6),GleSYS,Google Domains,GratisDNS,HE.net,HE.net (v6),HE.net Tunnelbroker,Loopia,Namecheap,No-IP,No-IP (free),ODS.org,OpenDNS,OVH DynHOST,Route 53,SelfHost,SPDYN,SPDYN (v6),ZoneEdit'); /* implement ipv6 route advertising daemon */ function services_radvd_configure($blacklist = array()) { diff --git a/src/etc/inc/util.inc b/src/etc/inc/util.inc index e164881..e063d5d 100644 --- a/src/etc/inc/util.inc +++ b/src/etc/inc/util.inc @@ -838,12 +838,9 @@ function is_subnetoralias($subnet) { Returns 0 for bad data or if cannot represent size as an INT when $exact is set. */ function subnet_size($subnet, $exact=false) { $parts = explode("/", $subnet); - if (count($parts) == 2) { - if (is_ipaddrv4($parts[0])) { - return subnet_size_by_netmask(4, $parts[1], $exact); - } elseif (is_ipaddrv6($parts[0])) { - return subnet_size_by_netmask(6, $parts[1], $exact); - } + $iptype = is_ipaddr($parts[0]); + if (count($parts) == 2 && $iptype) { + return subnet_size_by_netmask($iptype, $parts[1], $exact); } return 0; } diff --git a/src/etc/rc.carpbackup b/src/etc/rc.carpbackup index ed460bb..a0399a7 100755 --- a/src/etc/rc.carpbackup +++ b/src/etc/rc.carpbackup @@ -113,9 +113,20 @@ if (is_array($config['openvpn']) && is_array($config['openvpn']['openvpn-client' if (is_array($config['openvpn']) && is_array($config['openvpn']['openvpn-server'])) { foreach ($config['openvpn']['openvpn-server'] as $settings) { + if (substr($settings['interface'], 0, 4) == '_vip') { + $openvpn_vip = $settings['interface']; + } else if (is_array($a_groups[$settings['interface']])) { + // interface is a gateway group, check CARP VIP + if (substr($a_groups[$settings['interface']][0]['vip'], 0, 4) == '_vip') { + $openvpn_vip = $a_groups[$settings['interface']][0]['vip']; + } + } else { + // this OpenVPN instance not on a CARP IP + continue; + } foreach ($vips as $vip) { - if ($settings['interface'] == "_vip{$vip['uniqid']}") { - log_error("Stopping OpenVPN instance on {$friendly_descr} because of transition to CARP backup."); + if ($openvpn_vip == "_vip{$vip['uniqid']}") { + log_error("Stopping OpenVPN server instance on {$friendly_descr} because of transition to CARP backup."); openvpn_restart('server', $settings); } } diff --git a/src/etc/rc.carpmaster b/src/etc/rc.carpmaster index 6b68a71..3bc08c8 100755 --- a/src/etc/rc.carpmaster +++ b/src/etc/rc.carpmaster @@ -112,9 +112,20 @@ if (is_array($config['openvpn']) && is_array($config['openvpn']['openvpn-client' } if (is_array($config['openvpn']) && is_array($config['openvpn']['openvpn-server'])) { foreach ($config['openvpn']['openvpn-server'] as $settings) { + if (substr($settings['interface'], 0, 4) == '_vip') { + $openvpn_vip = $settings['interface']; + } else if (is_array($a_groups[$settings['interface']])) { + // interface is a gateway group, check CARP VIP + if (substr($a_groups[$settings['interface']][0]['vip'], 0, 4) == '_vip') { + $openvpn_vip = $a_groups[$settings['interface']][0]['vip']; + } + } else { + // this OpenVPN instance not on a CARP IP + continue; + } foreach ($vips as $vip) { - if ($settings['interface'] == "_vip{$vip['uniqid']}") { - log_error("Starting OpenVPN instance on {$friendly_descr} because of transition to CARP master."); + if ($openvpn_vip == "_vip{$vip['uniqid']}") { + log_error("Starting OpenVPN server instance on {$friendly_descr} because of transition to CARP master."); openvpn_restart('server', $settings); } } diff --git a/src/usr/local/www/css/pfSense-BETA.css b/src/usr/local/www/css/pfSense-BETA.css index 8d31a89..a8ec5e8 100644 --- a/src/usr/local/www/css/pfSense-BETA.css +++ b/src/usr/local/www/css/pfSense-BETA.css @@ -54,14 +54,61 @@ /*** Experimental Changes Go Here ***/ -.panel-heading a:link, .panel-heading a:visited { - color: #404040; - text-decoration: underline; +body { + font-size: 12px; } -.panel-default>.panel-heading { - color: #404040; - background-color: #cccccc; - letter-spacing: 1px; +.navbar-nav { + padding: 5px 5px 0px 5px; } +table[data-sortable].sortable-theme-bootstrap { + font-size: 12px; +} + +.table>tbody>tr>td { + padding: 4px 4px 4px 10px; +} + +.table>tbody>tr>td, .table>tbody>tr>th, .table>tfoot>tr>td, .table>tfoot>tr>th, .table>thead>tr>td, .table>thead>tr>th { + padding: 4px 5px; +} + +a.fa, i.fa { + font-size: 14px; +} + +.breadcrumb { + padding: 8px 15px; + margin-bottom: 16px; + font-size: 18px; +} + +.nav>li>a { + padding: 10px 15px 10px 15px; +} + +.nav-pills { + margin-bottom: 16px; +} + +.dropdown-menu>li>a { + padding: 3px 20px; +} + +.panel-title { + font-size: 14px; +} + +.form-group { + padding: 5px 5px 5px 5px; +} + +.icon-embed-btn { + padding-right: 16px; + padding-bottom: 13px; +} + +.panel-heading { + padding: 5px 10px; +}
\ No newline at end of file diff --git a/src/usr/local/www/css/pfSense-dark-BETA.css b/src/usr/local/www/css/pfSense-dark-BETA.css index 32b1a3b..e7e9727 100644 --- a/src/usr/local/www/css/pfSense-dark-BETA.css +++ b/src/usr/local/www/css/pfSense-dark-BETA.css @@ -53,3 +53,66 @@ @import url("/css/pfSense-dark.css"); /*** Experimental Changes Go Here ***/ + +body { + font-size: 12px; +} + +.navbar-nav { + padding: 5px 5px 0px 5px; +} + +table[data-sortable].sortable-theme-bootstrap { + font-size: 12px; +} + +.table>tbody>tr>td { + padding: 4px 4px 4px 10px; +} + +.table>tbody>tr>td, .table>tbody>tr>th, .table>tfoot>tr>td, .table>tfoot>tr>th, .table>thead>tr>td, .table>thead>tr>th { + padding: 4px 5px; +} + +a.fa, i.fa { + font-size: 14px; +} + +.breadcrumb { + padding: 8px 15px; + margin-bottom: 16px; + font-size: 18px; +} + +.nav>li>a { + padding: 10px 15px 10px 15px; +} + +.nav-pills { + margin-bottom: 16px; +} + +.dropdown-menu>li>a { + padding: 3px 20px; +} + +.panel-title { + font-size: 14px; +} + +.form-group { + padding: 5px 5px 5px 5px; +} + +.text-danger { + color: #F44336; +} + +.icon-embed-btn { + padding-right: 16px; + padding-bottom: 13px; +} + +.panel-heading { + padding: 5px 10px; +}
\ No newline at end of file diff --git a/src/usr/local/www/firewall_nat_out.php b/src/usr/local/www/firewall_nat_out.php index 26b055f..4a27324 100644 --- a/src/usr/local/www/firewall_nat_out.php +++ b/src/usr/local/www/firewall_nat_out.php @@ -256,7 +256,7 @@ display_top_tabs($tab_array); $form = new Form(); -$section = new Form_Section('General Logging Options'); +$section = new Form_Section('Outbound NAT Mode'); $group = new Form_Group('Mode'); diff --git a/src/usr/local/www/interfaces.php b/src/usr/local/www/interfaces.php index c8d38f3..beaad37 100644 --- a/src/usr/local/www/interfaces.php +++ b/src/usr/local/www/interfaces.php @@ -316,6 +316,7 @@ switch ($wancfg['ipaddrv6']) { $pconfig['dhcp6prefixonly'] = isset($wancfg['dhcp6prefixonly']); $pconfig['dhcp6usev4iface'] = isset($wancfg['dhcp6usev4iface']); $pconfig['dhcp6debug'] = isset($wancfg['dhcp6debug']); + $pconfig['dhcp6withoutra'] = isset($wancfg['dhcp6withoutra']); break; case "6to4": $pconfig['type6'] = "6to4"; @@ -1010,6 +1011,7 @@ if ($_POST['apply']) { unset($wancfg['dhcp6debug']); unset($wancfg['track6-interface']); unset($wancfg['track6-prefix-id']); + unset($wancfg['dhcp6withoutra']); unset($wancfg['prefix-6rd']); unset($wancfg['prefix-6rd-v4plen']); unset($wancfg['gateway-6rd']); @@ -1257,6 +1259,10 @@ if ($_POST['apply']) { $wancfg['dhcp6debug'] = true; } + if ($_POST['dhcp6withoutra'] == "yes") { + $wancfg['dhcp6withoutra'] = true; + } + if (!empty($_POST['adv_dhcp6_interface_statement_send_options'])) { $wancfg['adv_dhcp6_interface_statement_send_options'] = $_POST['adv_dhcp6_interface_statement_send_options']; } @@ -2154,6 +2160,13 @@ $section->addInput(new Form_Checkbox( $pconfig['dhcp6debug'] )); +$section->addInput(new Form_Checkbox( + 'dhcp6withoutra', + 'Do not wait for a RA', + 'Required by some ISPs, especially those not using PPPoE', + $pconfig['dhcp6withoutra'] +)); + $section->addInput(new Form_Input( 'adv_dhcp6_config_file_override_path', 'Configuration File Override', diff --git a/src/usr/local/www/pkg_mgr_installed.php b/src/usr/local/www/pkg_mgr_installed.php index 24d4db6..174d5e3 100644 --- a/src/usr/local/www/pkg_mgr_installed.php +++ b/src/usr/local/www/pkg_mgr_installed.php @@ -99,8 +99,6 @@ function get_pkg_table() { exit; } - $pkgtbl .=' <div class="panel panel-default">'; - $pkgtbl .=' <div class="panel-heading"><h2 class="panel-title">' . gettext('Installed Packages') . '</h2></div>'; $pkgtbl .=' <div class="table-responsive">'; $pkgtbl .=' <table class="table table-striped table-hover table-condensed">'; $pkgtbl .=' <thead>'; @@ -194,7 +192,6 @@ function get_pkg_table() { } $pkgtbl .=' </td>'; $pkgtbl .=' <td>'; - $pkgtbl .=' <div class="row">'; $pkgtbl .=' <a title="' . sprintf(gettext("Remove package %s"), $pkg['name']) . '" href="pkg_mgr_install.php?mode=delete&pkg=' . $pkg['name'] . '" class="fa fa-trash"></a>'; @@ -210,7 +207,6 @@ function get_pkg_table() { $pkgtbl .=' <a target="_blank" title="' . gettext("View more information") . '" href="' . htmlspecialchars($pkg['www']) . '" class="fa fa-info"></a>'; } - $pkgtbl .=' </div>'; $pkgtbl .=' </td>'; $pkgtbl .=' </tr>'; } @@ -232,7 +228,6 @@ function get_pkg_table() { $pkgtbl .=' </p>'; $pkgtbl .=' <p><span class="text-warning">' . gettext("Newer version available") . '</span></p>'; $pkgtbl .=' <p><span class="text-danger">' . gettext("Package is configured but not (fully) installed") . '</span></p>'; - $pkgtbl .=' </div>'; return $pkgtbl; } @@ -248,8 +243,8 @@ display_top_tabs($tab_array); ?> <div class="panel panel-default"> - <div class="panel-heading"><h2 class="panel-title"><?=gettext('Packages')?></h2></div> - <div id="pkgtbl" class="panel-body table-responsive"> + <div class="panel-heading"><h2 class="panel-title"><?=gettext('Installed Packages')?></h2></div> + <div id="pkgtbl" class="panel-body"> <div id="waitmsg"> <?php print_info_box(gettext("Please wait while the list of packages is retrieved and formatted.") . ' <i class="fa fa-cog fa-spin"></i>'); ?> </div> diff --git a/src/usr/local/www/status_dhcpv6_leases.php b/src/usr/local/www/status_dhcpv6_leases.php index 9c07b89..a8b644a 100644 --- a/src/usr/local/www/status_dhcpv6_leases.php +++ b/src/usr/local/www/status_dhcpv6_leases.php @@ -129,17 +129,14 @@ function adjust_gmt($dt) { } } - $timezone = $config['system']['timezone']; - $ts = strtotime($dt . " GMT"); if ($dhcpv6leaseinlocaltime == "yes") { - $this_tz = new DateTimeZone($timezone); - $dhcp_lt = new DateTime(strftime("%I:%M:%S%p", $ts), $this_tz); - $offset = $this_tz->getOffset($dhcp_lt); - $ts = $ts + $offset; - return strftime("%Y/%m/%d %I:%M:%S%p", $ts); - } else { - return strftime("%Y/%m/%d %H:%M:%S", $ts); + $ts = strtotime($dt . " GMT"); + if ($ts !== false) { + return strftime("%Y/%m/%d %I:%M:%S%p", $ts); + } } + /* If we did not need to convert to local time or the conversion failed, just return the input. */ + return $dt; } function remove_duplicate($array, $field) { diff --git a/src/usr/local/www/widgets/widgets/installed_packages.widget.php b/src/usr/local/www/widgets/widgets/installed_packages.widget.php index cc818b2..7444d57 100644 --- a/src/usr/local/www/widgets/widgets/installed_packages.widget.php +++ b/src/usr/local/www/widgets/widgets/installed_packages.widget.php @@ -80,7 +80,6 @@ if ($_REQUEST && $_REQUEST['ajax']) { print("<thead>\n"); print( "<tr>\n"); print( "<th>" . gettext("Name") . "</th>\n"); - print( "<th>" . gettext("Category") . "</th>\n"); print( "<th>" . gettext("Version") . "</th>\n"); print( "<th>" . gettext("Actions") . "</th>\n"); print( "</tr>\n"); @@ -132,7 +131,6 @@ if ($_REQUEST && $_REQUEST['ajax']) { print("<tr>\n"); print( '<td><span class="' . $txtcolor . '">' . $pkg['shortname'] . "</span></td>\n"); - print( "<td>" . implode(' ', $pkg['categories']) . "</td>\n"); print( "<td>\n"); print( '<i title="' . $status . '" class="fa fa-' . $statusicon . '"></i> '); diff --git a/tools/builder_common.sh b/tools/builder_common.sh index 7c2916f..7c29c49 100644 --- a/tools/builder_common.sh +++ b/tools/builder_common.sh @@ -1020,7 +1020,7 @@ create_ova_image() { fi echo "Done!" | tee -a ${LOGFILE} - rm -f ${OVA_TMP}/i${OVFRAW} + rm -f ${OVA_TMP}/${OVFRAW} ova_setup_ovf_template @@ -1377,9 +1377,9 @@ customize_stagearea_for_image() { } create_distribution_tarball() { - mkdir -p ${FINAL_CHROOT_DIR}/install + mkdir -p ${FINAL_CHROOT_DIR}/distrib - tar -C ${FINAL_CHROOT_DIR} --exclude ./install --exclude ./pkgs -cJf ${FINAL_CHROOT_DIR}/install/${PRODUCT_NAME}.txz . + tar -C ${FINAL_CHROOT_DIR} --exclude ./distrib --exclude ./pkgs -cJf ${FINAL_CHROOT_DIR}/distrib/${PRODUCT_NAME}.txz . } create_iso_image() { diff --git a/tools/builder_defaults.sh b/tools/builder_defaults.sh index 6e80123..abac096 100644 --- a/tools/builder_defaults.sh +++ b/tools/builder_defaults.sh @@ -138,7 +138,8 @@ else export GIT_REPO_BRANCH_OR_TAG="${_cur_git_repo_branch_or_tag}" fi # Use vX_Y instead of RELENG_X_Y for poudriere to make it shorter -POUDRIERE_BRANCH=$(echo "${GIT_REPO_BRANCH_OR_TAG}" | sed 's,RELENG_,v,') +# Replace . by _ to make tag names look correct +POUDRIERE_BRANCH=$(echo "${GIT_REPO_BRANCH_OR_TAG}" | sed 's,RELENG_,v,; s,\.,_,g') GIT_REPO_BASE=$(git -C ${BUILDER_ROOT} config --get remote.origin.url | sed -e 's,/[^/]*$,,') |