]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
Merge branch 'captive-portal' into next
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 4 Oct 2017 15:10:07 +0000 (16:10 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 4 Oct 2017 15:10:07 +0000 (16:10 +0100)
41 files changed:
config/rootfiles/common/apache2
config/rootfiles/common/aprutil
config/rootfiles/common/unbound
config/rootfiles/core/115/exclude [moved from config/rootfiles/core/114/exclude with 100% similarity]
config/rootfiles/core/115/filelists/files [new file with mode: 0644]
config/rootfiles/core/115/filelists/openvpn [new symlink]
config/rootfiles/core/115/filelists/wpa_supplicant [new symlink]
config/rootfiles/core/115/meta [moved from config/rootfiles/core/114/meta with 100% similarity]
config/rootfiles/core/115/update.sh [moved from config/rootfiles/core/114/update.sh with 75% similarity]
config/rootfiles/oldcore/114/exclude [new file with mode: 0644]
config/rootfiles/oldcore/114/filelists/apache2 [moved from config/rootfiles/core/114/filelists/apache2 with 100% similarity]
config/rootfiles/oldcore/114/filelists/apr [moved from config/rootfiles/core/114/filelists/apr with 100% similarity]
config/rootfiles/oldcore/114/filelists/aprutil [moved from config/rootfiles/core/114/filelists/aprutil with 100% similarity]
config/rootfiles/oldcore/114/filelists/files [moved from config/rootfiles/core/114/filelists/files with 100% similarity]
config/rootfiles/oldcore/114/filelists/gnutls [moved from config/rootfiles/core/114/filelists/gnutls with 100% similarity]
config/rootfiles/oldcore/114/filelists/hdparm [moved from config/rootfiles/core/114/filelists/hdparm with 100% similarity]
config/rootfiles/oldcore/114/filelists/i586/strongswan-padlock [moved from config/rootfiles/core/114/filelists/i586/strongswan-padlock with 100% similarity]
config/rootfiles/oldcore/114/filelists/php [new symlink]
config/rootfiles/oldcore/114/filelists/squid [moved from config/rootfiles/core/114/filelists/squid with 100% similarity]
config/rootfiles/oldcore/114/filelists/strongswan [moved from config/rootfiles/core/114/filelists/strongswan with 100% similarity]
config/rootfiles/oldcore/114/filelists/unbound [moved from config/rootfiles/core/114/filelists/unbound with 100% similarity]
config/rootfiles/oldcore/114/meta [new file with mode: 0644]
config/rootfiles/oldcore/114/update.sh [new file with mode: 0644]
html/cgi-bin/proxy.cgi
html/cgi-bin/wlanap.cgi
langs/de/cgi-bin/de.pl
langs/en/cgi-bin/en.pl
lfs/apache2
lfs/hostapd
lfs/openvpn
lfs/tcpdump
lfs/tor
lfs/unbound
lfs/wio
lfs/wpa_supplicant
make.sh
src/paks/wio/install.sh
src/patches/apache-2.4.27-CVE-2017-9798-fix.patch [new file with mode: 0644]
src/patches/apache-2.4.27-PR61382-fix.patch [new file with mode: 0644]
src/wio/wio.cgi
src/wio/wiographs.cgi

index d75ffd11ed6309f0420dd5e711e4c85b044b09b0..040b482141614b12f02cf82df0d4538d8663daa8 100644 (file)
@@ -1527,7 +1527,7 @@ usr/bin/htpasswd
 #usr/include/apache/util_time.h
 #usr/include/apache/util_varbuf.h
 #usr/include/apache/util_xml.h
-usr/lib/apache
+#usr/lib/apache
 #usr/lib/apache/build
 #usr/lib/apache/build/config.nice
 #usr/lib/apache/build/config_vars.mk
index 9a56ad13b093f9e3c0ee081b29ca008cb31fffd7..e9cf3e0dadee7f86a2b10eec846d7dc4421fa268 100644 (file)
@@ -35,7 +35,7 @@ usr/bin/apu-1-config
 #usr/include/apr-1/apu_version.h
 #usr/include/apr-1/apu_want.h
 #usr/include/apr-1/expat.h
-usr/lib/apr-util-1
+#usr/lib/apr-util-1
 usr/lib/apr-util-1/apr_crypto_openssl-1.so
 #usr/lib/apr-util-1/apr_crypto_openssl.la
 usr/lib/apr-util-1/apr_crypto_openssl.so
index b029c8b985f9d9501cfa85cc010769b276a4c352..6d153f265da8d02b7e5ca56bf6e3d9573f380898 100644 (file)
@@ -11,7 +11,7 @@ etc/unbound/unbound.conf
 #usr/lib/libunbound.la
 #usr/lib/libunbound.so
 usr/lib/libunbound.so.2
-usr/lib/libunbound.so.2.5.4
+usr/lib/libunbound.so.2.5.5
 usr/sbin/unbound
 usr/sbin/unbound-anchor
 usr/sbin/unbound-checkconf
diff --git a/config/rootfiles/core/115/filelists/files b/config/rootfiles/core/115/filelists/files
new file mode 100644 (file)
index 0000000..d3c27e8
--- /dev/null
@@ -0,0 +1,3 @@
+etc/system-release
+etc/issue
+srv/web/ipfire/cgi-bin/proxy.cgi
diff --git a/config/rootfiles/core/115/filelists/openvpn b/config/rootfiles/core/115/filelists/openvpn
new file mode 120000 (symlink)
index 0000000..493f3f7
--- /dev/null
@@ -0,0 +1 @@
+../../../common/openvpn
\ No newline at end of file
diff --git a/config/rootfiles/core/115/filelists/wpa_supplicant b/config/rootfiles/core/115/filelists/wpa_supplicant
new file mode 120000 (symlink)
index 0000000..1d04c03
--- /dev/null
@@ -0,0 +1 @@
+../../../common/wpa_supplicant
\ No newline at end of file
similarity index 75%
rename from config/rootfiles/core/114/update.sh
rename to config/rootfiles/core/115/update.sh
index 6d7a10b5ed00f73780da338cd974ca78c5ee7253..e0ee121ce7a34141fa2d25cf392def98783a9c84 100644 (file)
@@ -24,7 +24,7 @@
 . /opt/pakfire/lib/functions.sh
 /usr/local/bin/backupctrl exclude >/dev/null 2>&1
 
-core=114
+core=115
 
 # Remove old core updates from pakfire cache to save space...
 for (( i=1; i<=$core; i++ )); do
@@ -32,21 +32,8 @@ for (( i=1; i<=$core; i++ )); do
 done
 
 # Stop services
-ipsec stop
-/etc/init.d/squid stop
-/etc/init.d/unbound stop
-/etc/init.d/apache stop
-
-# Remove old apache configuration files of add-ons
-# These will be reinstalled by the updated packages
-# as soon as the core update is finished.
-rm -f \
-       /etc/httpd/conf/vhosts.d/cacti.conf \
-       /etc/httpd/conf/vhosts.d/icinga.conf \
-       /etc/httpd/conf/vhosts.d/nagios.conf \
-       /etc/httpd/conf/vhosts.d/openmailadmin.conf \
-       /etc/httpd/conf/vhosts.d/owncloud.conf \
-       /etc/httpd/conf/vhosts.d/phpSANE.conf
+openvpnctrl -k
+openvpnctrl -kn2n
 
 # Extract files
 extract_files
@@ -54,23 +41,16 @@ extract_files
 # update linker config
 ldconfig
 
-# Remove some files
-rm -f /usr/sbin/htpasswd
-
 # Update Language cache
-/usr/local/bin/update-lang-cache
+#/usr/local/bin/update-lang-cache
 
 # Start services
-/etc/init.d/unbound start
-/etc/init.d/apache start
-/etc/init.d/squid start
+openvpnctrl -s
+openvpnctrl -sn2n
 
-if grep -q "ENABLED=on" /var/ipfire/vpn/settings; then
-       ipsec start
-fi
 
 # This update need a reboot...
-touch /var/run/need_reboot
+#touch /var/run/need_reboot
 
 # Finish
 /etc/init.d/fireinfo start
diff --git a/config/rootfiles/oldcore/114/exclude b/config/rootfiles/oldcore/114/exclude
new file mode 100644 (file)
index 0000000..d6fd053
--- /dev/null
@@ -0,0 +1,30 @@
+boot/config.txt
+boot/grub/grub.cfg
+boot/grub/grubenv
+etc/alternatives
+etc/collectd.custom
+etc/default/grub
+etc/ipsec.conf
+etc/ipsec.secrets
+etc/ipsec.user.conf
+etc/ipsec.user.secrets
+etc/localtime
+etc/shadow
+etc/snort/snort.conf
+etc/ssh/ssh_config
+etc/ssh/sshd_config
+etc/ssl/openssl.cnf
+etc/sudoers
+etc/sysconfig/firewall.local
+etc/sysconfig/rc.local
+etc/udev/rules.d/30-persistent-network.rules
+srv/web/ipfire/html/proxy.pac
+var/ipfire/dma
+var/ipfire/time
+var/ipfire/ovpn
+var/lib/alternatives
+var/log/cache
+var/log/dhcpcd.log
+var/log/messages
+var/state/dhcp/dhcpd.leases
+var/updatecache
diff --git a/config/rootfiles/oldcore/114/filelists/php b/config/rootfiles/oldcore/114/filelists/php
new file mode 120000 (symlink)
index 0000000..1ae48d7
--- /dev/null
@@ -0,0 +1 @@
+../../../common/php
\ No newline at end of file
diff --git a/config/rootfiles/oldcore/114/meta b/config/rootfiles/oldcore/114/meta
new file mode 100644 (file)
index 0000000..d547fa8
--- /dev/null
@@ -0,0 +1 @@
+DEPS=""
diff --git a/config/rootfiles/oldcore/114/update.sh b/config/rootfiles/oldcore/114/update.sh
new file mode 100644 (file)
index 0000000..ac59cc9
--- /dev/null
@@ -0,0 +1,108 @@
+#!/bin/bash
+############################################################################
+#                                                                          #
+# This file is part of the IPFire Firewall.                                #
+#                                                                          #
+# IPFire is free software; you can redistribute it and/or modify           #
+# it under the terms of the GNU General Public License as published by     #
+# the Free Software Foundation; either version 3 of the License, or        #
+# (at your option) any later version.                                      #
+#                                                                          #
+# IPFire is distributed in the hope that it will be useful,                #
+# but WITHOUT ANY WARRANTY; without even the implied warranty of           #
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the            #
+# GNU General Public License for more details.                             #
+#                                                                          #
+# You should have received a copy of the GNU General Public License        #
+# along with IPFire; if not, write to the Free Software                    #
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA #
+#                                                                          #
+# Copyright (C) 2017 IPFire-Team <info@ipfire.org>.                        #
+#                                                                          #
+############################################################################
+#
+. /opt/pakfire/lib/functions.sh
+/usr/local/bin/backupctrl exclude >/dev/null 2>&1
+
+core=114
+
+# Remove old core updates from pakfire cache to save space...
+for (( i=1; i<=$core; i++ )); do
+       rm -f /var/cache/pakfire/core-upgrade-*-$i.ipfire
+done
+
+# Stop services
+ipsec stop
+/etc/init.d/squid stop
+/etc/init.d/unbound stop
+/etc/init.d/apache stop
+
+# Remove old apache configuration files of add-ons
+# These will be reinstalled by the updated packages
+# as soon as the core update is finished.
+rm -f \
+       /etc/httpd/conf/vhosts.d/cacti.conf \
+       /etc/httpd/conf/vhosts.d/icinga.conf \
+       /etc/httpd/conf/vhosts.d/nagios.conf \
+       /etc/httpd/conf/vhosts.d/openmailadmin.conf \
+       /etc/httpd/conf/vhosts.d/owncloud.conf \
+       /etc/httpd/conf/vhosts.d/phpSANE.conf
+
+# Extract files
+extract_files
+
+# update linker config
+ldconfig
+
+# Remove some files
+rm -f /usr/sbin/htpasswd
+
+# Update Language cache
+/usr/local/bin/update-lang-cache
+
+# Start services
+/etc/init.d/unbound start
+/etc/init.d/apache start
+/etc/init.d/squid start
+
+if grep -q "ENABLED=on" /var/ipfire/vpn/settings; then
+       ipsec start
+fi
+
+#
+# After pakfire has ended run it again and update all addons
+# this is needed for apache update.
+#
+echo '#!/bin/bash'                                        >  /tmp/pak_update
+echo 'while [ "$(ps -A | grep " update.sh")" != "" ]; do' >> /tmp/pak_update
+echo '    sleep 1'                                        >> /tmp/pak_update
+echo 'done'                                               >> /tmp/pak_update
+echo 'while [ "$(ps -A | grep " pakfire")" != "" ]; do'   >> /tmp/pak_update
+echo '    sleep 1'                                        >> /tmp/pak_update
+echo 'done'                                               >> /tmp/pak_update
+echo '/opt/pakfire/pakfire update -y --force'             >> /tmp/pak_update
+echo '/opt/pakfire/pakfire upgrade -y'                    >> /tmp/pak_update
+echo '/opt/pakfire/pakfire upgrade -y'                    >> /tmp/pak_update
+echo '/opt/pakfire/pakfire upgrade -y'                    >> /tmp/pak_update
+echo 'touch /var/run/need_reboot ' >> /tmp/pak_update
+#
+killall -KILL pak_update
+chmod +x /tmp/pak_update
+/tmp/pak_update &
+
+# This update need a reboot...
+touch /var/run/need_reboot
+
+# Finish
+/etc/init.d/fireinfo start
+sendprofile
+
+# Update grub config to display new core version
+if [ -e /boot/grub/grub.cfg ]; then
+       grub-mkconfig -o /boot/grub/grub.cfg
+fi
+
+sync
+
+# Don't report the exitcode last command
+exit 0
index 0b7d36c3cabbc537a046a6bbaf98b2b7074280b2..dd83bba73b3f97c9c28053d12ddb56e7eb3ba610 100644 (file)
@@ -1054,11 +1054,11 @@ if ( -e "/usr/bin/squidclamav" ) {
 } else {
        print "<td></td>";
 }
-print "<td class='base'><b>".$Lang::tr{'advproxy url filter'}."</b><br />";
+print "<td class='base'><a href='/cgi-bin/urlfilter.cgi'><b>".$Lang::tr{'advproxy url filter'}."</a></b><br />";
 print $Lang::tr{'advproxy enabled'}."<input type='checkbox' name='ENABLE_FILTER' ".$checked{'ENABLE_FILTER'}{'on'}." /><br />";
 print "+ ".int(($count**(1/3)) * 6);
 print "</td>";
-print "<td class='base'><b>".$Lang::tr{'advproxy update accelerator'}."</b><br />";
+print "<td class='base'><a href='/cgi-bin/updatexlrator.cgi'><b>".$Lang::tr{'advproxy update accelerator'}."</a></b><br />";
 print $Lang::tr{'advproxy enabled'}."<input type='checkbox' name='ENABLE_UPDXLRATOR' ".$checked{'ENABLE_UPDXLRATOR'}{'on'}." /><br />";
 print "+ ".int(($count**(1/3)) * 5);
 print "</td></tr>";
index 844c395e2f7738dddd26cd3c36ad5bcfe8577c93..bb40021cf8936af8b0e20c80796b728303eec73a 100644 (file)
@@ -154,7 +154,7 @@ if ( $wlanapsettings{'ACTION'} eq "$Lang::tr{'save'}" ){
        $memory=0;
 }
 
-&Header::openpage('', 1, '', '');
+&Header::openpage($Lang::tr{'wlanap configuration'}, 1, '', '');
 &Header::openbigbox('100%', 'left', '', $errormessage);
 
 if ( $errormessage ){
@@ -323,7 +323,7 @@ if ( $wlan_card_status ne '' ){
        print "<tr><td class='base'>$Lang::tr{'wlanap wlan card'} ($wlanapsettings{'DRIVER'})</td>";
        print $wlan_card_status eq 'up' ? $status_started : $status_stopped;
        print"<td colspan='4'></td></tr>";
-       print "<tr><td class='base' bgcolor='$color{'color22'}'>$Lang::tr{'wlanap access point'}</td>";
+       print "<tr><td class='base' bgcolor='$color{'color22'}'>$Lang::tr{'wlanap'}</td>";
        print $wlan_ap_status eq 'up' ? $status_started : $status_stopped;
        if ( ($memory != 0) && (@pid[0] ne "///") ){
                print "<td bgcolor='$color{'color22'}' align='center'>@pid[0]</td>";
index b23994a9a8462d4be50173685210960e10f3818f..af96a6445bc9f99a11322e7543411123f369e48a 100644 (file)
 'wlan client wpa mode ccmp tkip' => 'CCMP-TKIP',
 'wlan client wpa mode tkip tkip' => 'TKIP-TKIP',
 'wlan clients' => 'WLAN-Clients',
-'wlanap access point' => 'Access Point',
+'wlanap' => 'Access Point',
 'wlanap channel' => 'Kanal',
+'wlanap configuration' => 'Access Point Konfiguration',
 'wlanap country' => 'Ländercode',
 'wlanap debugging' => 'Debugging',
 'wlanap del interface' => 'Ausgewähltes Interface zurücksetzen?',
index 064fd7fc9e5f823d6060562b24e53a4afc01e3a0..7e4f95ccfd0c2c73fc3cfbed7c7ab60e4adb9402 100644 (file)
 'wlan client wpa mode ccmp tkip' => 'CCMP-TKIP',
 'wlan client wpa mode tkip tkip' => 'TKIP-TKIP',
 'wlan clients' => 'Wireless clients',
-'wlanap access point' => 'Access Point',
+'wlanap' => 'Access Point',
 'wlanap channel' => 'Channel',
+'wlanap configuration' => 'Access Point Configuration',
 'wlanap country' => 'Country Code',
 'wlanap debugging' => 'Debugging',
 'wlanap del interface' => 'Remove selected interface?',
index dbefff922a02c932935cefe3402328537be6771a..138ede8de3121f10ceb36872514a5caa2612d3fd 100644 (file)
@@ -41,14 +41,11 @@ DEPS       = "aprutil pcre"
 # Top-level Rules
 ###############################################################################
 
-objects = $(DL_FILE) \
-       PR61382-Fix.patch
+objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
-PR61382-Fix.patch = ${DL_FROM}/patches/apply_to_2.4.27/PR61382-Fix.patch
 
 $(DL_FILE)_MD5 = 97b6bbfa83c866dbe20ef317e3afd108
-PR61382-Fix.patch_MD5 = 5c1107bb1f399419574d983ce103c99a
 
 install : $(TARGET)
 
@@ -78,8 +75,8 @@ $(subst %,%_MD5,$(objects)) :
 $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        @$(PREBUILD)
        @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
-       cd $(DIR_APP) && patch -Np0 -i $(DIR_DL)/PR61382-Fix.patch
-
+       cd $(DIR_APP) && patch -Np0 -i $(DIR_SRC)/src/patches/apache-2.4.27-PR61382-fix.patch
+       cd $(DIR_APP) && patch -Np0 -i $(DIR_SRC)/src/patches/apache-2.4.27-CVE-2017-9798-fix.patch
        ### Add IPFire's layout, too
        echo "# IPFire layout" >> $(DIR_APP)/config.layout
        echo "<Layout IPFire>" >> $(DIR_APP)/config.layout
index d94c0e752f02a71c2b6d08b1a79b64a114ea72a6..11b4d1cdf1ed4e7cae0e8ed47f79912f30faa893 100644 (file)
@@ -32,7 +32,7 @@ DL_FROM    = $(URL_IPFIRE)
 DIR_APP    = $(DIR_SRC)/$(THISAPP)
 TARGET     = $(DIR_INFO)/$(THISAPP)
 PROG       = hostapd
-PAK_VER    = 38
+PAK_VER    = 39
 
 DEPS       = ""
 
index b7f5217597235946dee55dd16cd84e928d266ef8..8307d0147b9fc7e6b02e66164e74bfd827fcbb0b 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2015  IPFire Team  <info@ipfire.org>                          #
+# Copyright (C) 2017  IPFire Team  <info@ipfire.org>                          #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -24,7 +24,7 @@
 
 include Config
 
-VER        = 2.3.17
+VER        = 2.3.18
 
 THISAPP    = openvpn-$(VER)
 DL_FILE    = $(THISAPP).tar.xz
@@ -40,7 +40,7 @@ objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = df9291c5bd466fe73c2544a800f3b441
+$(DL_FILE)_MD5 = 844ec9c64aae62051478784b8562f881
 
 install : $(TARGET)
 
@@ -74,7 +74,6 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
                --prefix=/usr \
                --sysconfdir=/var/ipfire/ovpn \
                --enable-iproute2 \
-               --enable-password-save \
                --enable-plugins \
                --enable-plugin-auth-pam \
                --enable-plugin-down-root
index 42536f16a3a3a4e671dd9a260882281974a4d6b7..acf752ce2f3611c64d4ccbea2c2e88ee3013fd74 100644 (file)
@@ -24,7 +24,7 @@
 
 include Config
 
-VER        = 4.9.0
+VER        = 4.9.2
 
 THISAPP    = tcpdump-$(VER)
 DL_FILE    = $(THISAPP).tar.gz
@@ -32,7 +32,7 @@ DL_FROM    = $(URL_IPFIRE)
 DIR_APP    = $(DIR_SRC)/$(THISAPP)
 TARGET     = $(DIR_INFO)/$(THISAPP)
 PROG       = tcpdump
-PAK_VER    = 8
+PAK_VER    = 9
 
 DEPS       = ""
 
@@ -44,7 +44,7 @@ objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = 2b83364eef53b63ca3181b4eb56dab0c
+$(DL_FILE)_MD5 = 9bbc1ee33dab61302411b02dd0515576
 
 install : $(TARGET)
 
diff --git a/lfs/tor b/lfs/tor
index 9e463445bc3bdb96de6e5dfaf2124ecfc9d32704..867f01fb4b500976b9666c24965bece69937f2f4 100644 (file)
--- a/lfs/tor
+++ b/lfs/tor
@@ -24,7 +24,7 @@
 
 include Config
 
-VER        = 0.3.0.10
+VER        = 0.3.1.7
 
 THISAPP    = tor-$(VER)
 DL_FILE    = $(THISAPP).tar.gz
@@ -32,7 +32,7 @@ DL_FROM    = $(URL_IPFIRE)
 DIR_APP    = $(DIR_SRC)/$(THISAPP)
 TARGET     = $(DIR_INFO)/$(THISAPP)
 PROG       = tor
-PAK_VER    = 22
+PAK_VER    = 23
 
 DEPS       = ""
 
@@ -44,7 +44,7 @@ objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = c9920169798c28b60b03fa3f0e592509
+$(DL_FILE)_MD5 = ec7c9f588c9e1a42c09bcc097a1e55eb
 
 install : $(TARGET)
 
index 4625284186611983203a36c418a330f6e403a281..39ad0def7dc008afb51f96068fec944106c82eaf 100644 (file)
@@ -24,7 +24,7 @@
 
 include Config
 
-VER        = 1.6.5
+VER        = 1.6.6
 
 THISAPP    = unbound-$(VER)
 DL_FILE    = $(THISAPP).tar.gz
@@ -40,7 +40,7 @@ objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = 5825332b72bae9d8793f9cba16cb13fd
+$(DL_FILE)_MD5 = f2cc56bd88c9634fe18334d2421205f1
 
 install : $(TARGET)
 
diff --git a/lfs/wio b/lfs/wio
index 25726cd934a46028f69be993b8b49490887e350d..d70b12b469e43e36f34bc9dc7248608587a0d458 100644 (file)
--- a/lfs/wio
+++ b/lfs/wio
@@ -15,7 +15,7 @@ THISAPP    = wio-$(VER)
 DIR_APP    = $(DIR_SRC)/$(THISAPP)
 TARGET     = $(DIR_INFO)/$(THISAPP)
 PROG       = wio
-PAK_VER    = 2
+PAK_VER    = 3
 
 ###############################################################################
 # Top-level Rules
@@ -58,7 +58,7 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        install -v -m 644 $(DIR_APP)/wio/images/* /srv/web/ipfire/html/images/wio/
        install -v -m 655 $(DIR_APP)/wio/lang/wio.de.pl /var/ipfire/addon-lang/
        install -v -m 655 $(DIR_APP)/wio/lang/wio.en.pl /var/ipfire/addon-lang/
-       install -v -m 655 $(DIR_APP)/wio/EX-wio.menu /var/ipfire/menu.d/
+       install -v -m 644 $(DIR_APP)/wio/EX-wio.menu /var/ipfire/menu.d/
        install -v -m 644 $(DIR_APP)/wio/config/backup/includes/wio /var/ipfire/backup/addons/includes/wio
 
        @rm -rf $(DIR_APP)
index 76aa6c673834b4281bf3b9d5727aa723e8fce546..02e78ea355a22c2413b28bc281e139050ddcf204 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2015  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2017  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -24,7 +24,7 @@
 
 include Config
 
-VER        = 2.5
+VER        = 2.6
 
 THISAPP    = wpa_supplicant-$(VER)
 DL_FILE    = $(THISAPP).tar.gz
@@ -41,7 +41,7 @@ objects = $(DL_FILE)
 
 $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
 
-$(DL_FILE)_MD5 = 96ff75c3a514f1f324560a2376f13110
+$(DL_FILE)_MD5 = 091569eb4440b7d7f2b4276dbfc03c3c
 
 install : $(TARGET)
 
@@ -51,7 +51,7 @@ download :$(patsubst %,$(DIR_DL)/%,$(objects))
 
 md5 : $(subst %,%_MD5,$(objects))
 
-dist: 
+dist:
        @$(PAK)
 
 ###############################################################################
diff --git a/make.sh b/make.sh
index ba59ac023677ab740dcfe911d2c1da3647c2b855..790c6b81f025d550ad1e39c28276f3e2621fb9ed 100755 (executable)
--- a/make.sh
+++ b/make.sh
@@ -25,8 +25,8 @@
 NAME="IPFire"                                                  # Software name
 SNAME="ipfire"                                                 # Short name
 VERSION="2.19"                                                 # Version number
-CORE="113"                                                     # Core Level (Filename)
-PAKFIRE_CORE="113"                                             # Core Level (PAKFIRE)
+CORE="115"                                                     # Core Level (Filename)
+PAKFIRE_CORE="114"                                             # Core Level (PAKFIRE)
 GIT_BRANCH=`git rev-parse --abbrev-ref HEAD`                   # Git Branch
 SLOGAN="www.ipfire.org"                                                # Software slogan
 CONFIG_ROOT=/var/ipfire                                                # Configuration rootdir
index f46ae350e9a60d05b15be212746762a15f1dc580..5c7705bf14744a2aff2ad12fafdf857c8aed30d2 100644 (file)
@@ -30,6 +30,7 @@ chown -R nobody.nobody /var/log/rrd/wio
 chown -R nobody.nobody /var/log/wio
 chown root.nobody /usr/local/bin/wioscan
 chown root.nobody /usr/local/bin/wiohelper
+chown nobody.nobody /var/ipfire/menu.d/EX-wio.menu
 
 chmod 4750 /usr/local/bin/wioscan
 chmod 4750 /usr/local/bin/wiohelper
diff --git a/src/patches/apache-2.4.27-CVE-2017-9798-fix.patch b/src/patches/apache-2.4.27-CVE-2017-9798-fix.patch
new file mode 100644 (file)
index 0000000..eb82c8b
--- /dev/null
@@ -0,0 +1,15 @@
+--- server/core.c      2017/08/16 16:50:29     1805223
++++ server/core.c      2017/09/08 13:13:11     1807754
+@@ -2262,6 +2262,12 @@
+             /* method has not been registered yet, but resource restriction
+              * is always checked before method handling, so register it.
+              */
++            if (cmd->pool == cmd->temp_pool) {
++                /* In .htaccess, we can't globally register new methods. */
++                return apr_psprintf(cmd->pool, "Could not register method '%s' "
++                                   "for %s from .htaccess configuration",
++                                    method, cmd->cmd->name);
++            }
+             methnum = ap_method_register(cmd->pool,
+                                          apr_pstrdup(cmd->pool, method));
+         }
diff --git a/src/patches/apache-2.4.27-PR61382-fix.patch b/src/patches/apache-2.4.27-PR61382-fix.patch
new file mode 100644 (file)
index 0000000..128621a
--- /dev/null
@@ -0,0 +1,783 @@
+Index: modules/http2/h2_bucket_beam.c
+===================================================================
+--- modules/http2/h2_bucket_beam.c     (revision 1804645)
++++ modules/http2/h2_bucket_beam.c     (working copy)
+@@ -287,7 +287,7 @@
+             /* do not count */
+         }
+         else if (APR_BUCKET_IS_FILE(b)) {
+-            /* if unread, has no real mem footprint. how to test? */
++            /* if unread, has no real mem footprint. */
+         }
+         else {
+             len += b->length;
+@@ -316,32 +316,80 @@
+     return APR_SIZE_MAX;
+ }
+-static apr_status_t wait_cond(h2_bucket_beam *beam, apr_thread_mutex_t *lock)
++static int buffer_is_empty(h2_bucket_beam *beam)
+ {
+-    if (beam->timeout > 0) {
+-        return apr_thread_cond_timedwait(beam->cond, lock, beam->timeout);
++    return ((!beam->recv_buffer || APR_BRIGADE_EMPTY(beam->recv_buffer))
++            && H2_BLIST_EMPTY(&beam->send_list));
++}
++
++static apr_status_t wait_empty(h2_bucket_beam *beam, apr_read_type_e block,  
++                               apr_thread_mutex_t *lock)
++{
++    apr_status_t rv = APR_SUCCESS;
++    
++    while (!buffer_is_empty(beam) && APR_SUCCESS == rv) {
++        if (APR_BLOCK_READ != block || !lock) {
++            rv = APR_EAGAIN;
++        }
++        else if (beam->timeout > 0) {
++            rv = apr_thread_cond_timedwait(beam->change, lock, beam->timeout);
++        }
++        else {
++            rv = apr_thread_cond_wait(beam->change, lock);
++        }
+     }
+-    else {
+-        return apr_thread_cond_wait(beam->cond, lock);
++    return rv;
++}
++
++static apr_status_t wait_not_empty(h2_bucket_beam *beam, apr_read_type_e block,  
++                                   apr_thread_mutex_t *lock)
++{
++    apr_status_t rv = APR_SUCCESS;
++    
++    while (buffer_is_empty(beam) && APR_SUCCESS == rv) {
++        if (beam->aborted) {
++            rv = APR_ECONNABORTED;
++        }
++        else if (beam->closed) {
++            rv = APR_EOF;
++        }
++        else if (APR_BLOCK_READ != block || !lock) {
++            rv = APR_EAGAIN;
++        }
++        else if (beam->timeout > 0) {
++            rv = apr_thread_cond_timedwait(beam->change, lock, beam->timeout);
++        }
++        else {
++            rv = apr_thread_cond_wait(beam->change, lock);
++        }
+     }
++    return rv;
+ }
+-static apr_status_t r_wait_space(h2_bucket_beam *beam, apr_read_type_e block,
+-                                 h2_beam_lock *pbl, apr_size_t *premain) 
++static apr_status_t wait_not_full(h2_bucket_beam *beam, apr_read_type_e block, 
++                                  apr_size_t *pspace_left, h2_beam_lock *bl)
+ {
+-    *premain = calc_space_left(beam);
+-    while (!beam->aborted && *premain <= 0 
+-           && (block == APR_BLOCK_READ) && pbl->mutex) {
+-        apr_status_t status;
+-        report_prod_io(beam, 1, pbl);
+-        status = wait_cond(beam, pbl->mutex);
+-        if (APR_STATUS_IS_TIMEUP(status)) {
+-            return status;
++    apr_status_t rv = APR_SUCCESS;
++    apr_size_t left;
++    
++    while (0 == (left = calc_space_left(beam)) && APR_SUCCESS == rv) {
++        if (beam->aborted) {
++            rv = APR_ECONNABORTED;
+         }
+-        r_purge_sent(beam);
+-        *premain = calc_space_left(beam);
++        else if (block != APR_BLOCK_READ || !bl->mutex) {
++            rv = APR_EAGAIN;
++        }
++        else {
++            if (beam->timeout > 0) {
++                rv = apr_thread_cond_timedwait(beam->change, bl->mutex, beam->timeout);
++            }
++            else {
++                rv = apr_thread_cond_wait(beam->change, bl->mutex);
++            }
++        }
+     }
+-    return beam->aborted? APR_ECONNABORTED : APR_SUCCESS;
++    *pspace_left = left;
++    return rv;
+ }
+ static void h2_beam_emitted(h2_bucket_beam *beam, h2_beam_proxy *proxy)
+@@ -404,8 +452,8 @@
+         if (!bl.mutex) {
+             r_purge_sent(beam);
+         }
+-        else if (beam->cond) {
+-            apr_thread_cond_broadcast(beam->cond);
++        else {
++            apr_thread_cond_broadcast(beam->change);
+         }
+         leave_yellow(beam, &bl);
+     }
+@@ -425,9 +473,7 @@
+ {
+     if (!beam->closed) {
+         beam->closed = 1;
+-        if (beam->cond) {
+-            apr_thread_cond_broadcast(beam->cond);
+-        }
++        apr_thread_cond_broadcast(beam->change);
+     }
+     return APR_SUCCESS;
+ }
+@@ -582,7 +628,7 @@
+                             apr_interval_time_t timeout)
+ {
+     h2_bucket_beam *beam;
+-    apr_status_t status = APR_SUCCESS;
++    apr_status_t rv = APR_SUCCESS;
+     
+     beam = apr_pcalloc(pool, sizeof(*beam));
+     if (!beam) {
+@@ -601,16 +647,15 @@
+     beam->max_buf_size = max_buf_size;
+     beam->timeout = timeout;
+-    status = apr_thread_mutex_create(&beam->lock, APR_THREAD_MUTEX_DEFAULT, 
+-                                     pool);
+-    if (status == APR_SUCCESS) {
+-        status = apr_thread_cond_create(&beam->cond, pool);
+-        if (status == APR_SUCCESS) {
++    rv = apr_thread_mutex_create(&beam->lock, APR_THREAD_MUTEX_DEFAULT, pool);
++    if (APR_SUCCESS == rv) {
++        rv = apr_thread_cond_create(&beam->change, pool);
++        if (APR_SUCCESS == rv) {
+             apr_pool_pre_cleanup_register(pool, beam, beam_cleanup);
+             *pbeam = beam;
+         }
+     }
+-    return status;
++    return rv;
+ }
+ void h2_beam_buffer_size_set(h2_bucket_beam *beam, apr_size_t buffer_size)
+@@ -691,9 +736,7 @@
+             h2_blist_cleanup(&beam->send_list);
+             report_consumption(beam, &bl);
+         }
+-        if (beam->cond) {
+-            apr_thread_cond_broadcast(beam->cond);
+-        }
++        apr_thread_cond_broadcast(beam->change);
+         leave_yellow(beam, &bl);
+     }
+ }
+@@ -730,18 +773,7 @@
+     h2_beam_lock bl;
+     
+     if ((status = enter_yellow(beam, &bl)) == APR_SUCCESS) {
+-        while (status == APR_SUCCESS
+-               && !H2_BLIST_EMPTY(&beam->send_list)
+-               && !H2_BPROXY_LIST_EMPTY(&beam->proxies)) {
+-            if (block == APR_NONBLOCK_READ || !bl.mutex) {
+-                status = APR_EAGAIN;
+-                break;
+-            }
+-            if (beam->cond) {
+-                apr_thread_cond_broadcast(beam->cond);
+-            }
+-            status = wait_cond(beam, bl.mutex);
+-        }
++        status = wait_empty(beam, block, bl.mutex);
+         leave_yellow(beam, &bl);
+     }
+     return status;
+@@ -761,13 +793,18 @@
+ static apr_status_t append_bucket(h2_bucket_beam *beam, 
+                                   apr_bucket *b,
+                                   apr_read_type_e block,
++                                  apr_size_t *pspace_left,
+                                   h2_beam_lock *pbl)
+ {
+     const char *data;
+     apr_size_t len;
+-    apr_size_t space_left = 0;
+     apr_status_t status;
++    int can_beam, check_len;
+     
++    if (beam->aborted) {
++        return APR_ECONNABORTED;
++    }
++    
+     if (APR_BUCKET_IS_METADATA(b)) {
+         if (APR_BUCKET_IS_EOS(b)) {
+             beam->closed = 1;
+@@ -777,11 +814,31 @@
+         return APR_SUCCESS;
+     }
+     else if (APR_BUCKET_IS_FILE(b)) {
+-        /* file bucket lengths do not really count */
++        /* For file buckets the problem is their internal readpool that
++         * is used on the first read to allocate buffer/mmap.
++         * Since setting aside a file bucket will de-register the
++         * file cleanup function from the previous pool, we need to
++         * call that only from the sender thread.
++         *
++         * Currently, we do not handle file bucket with refcount > 1 as
++         * the beam is then not in complete control of the file's lifetime.
++         * Which results in the bug that a file get closed by the receiver
++         * while the sender or the beam still have buckets using it. 
++         * 
++         * Additionally, we allow callbacks to prevent beaming file
++         * handles across. The use case for this is to limit the number 
++         * of open file handles and rather use a less efficient beam
++         * transport. */
++        apr_bucket_file *bf = b->data;
++        apr_file_t *fd = bf->fd;
++        can_beam = (bf->refcount.refcount == 1);
++        if (can_beam && beam->can_beam_fn) {
++            can_beam = beam->can_beam_fn(beam->can_beam_ctx, beam, fd);
++        }
++        check_len = !can_beam;
+     }
+     else {
+-        space_left = calc_space_left(beam);
+-        if (space_left > 0 && b->length == ((apr_size_t)-1)) {
++        if (b->length == ((apr_size_t)-1)) {
+             const char *data;
+             status = apr_bucket_read(b, &data, &len, APR_BLOCK_READ);
+             if (status != APR_SUCCESS) {
+@@ -788,19 +845,15 @@
+                 return status;
+             }
+         }
+-        
+-        if (space_left <= 0) {
+-            status = r_wait_space(beam, block, pbl, &space_left);
+-            if (status != APR_SUCCESS) {
+-                return status;
+-            }
+-            if (space_left <= 0) {
+-                return APR_EAGAIN;
+-            }
++        check_len = 1;
++    }
++    
++    if (check_len) {
++        if (b->length > *pspace_left) {
++            apr_bucket_split(b, *pspace_left);
+         }
+-        /* space available, maybe need bucket split */
++        *pspace_left -= b->length;
+     }
+-    
+     /* The fundamental problem is that reading a sender bucket from
+      * a receiver thread is a total NO GO, because the bucket might use
+@@ -830,32 +883,8 @@
+             apr_bucket_heap_make(b, data, len, NULL);
+         }
+     }
+-    else if (APR_BUCKET_IS_FILE(b)) {
+-        /* For file buckets the problem is their internal readpool that
+-         * is used on the first read to allocate buffer/mmap.
+-         * Since setting aside a file bucket will de-register the
+-         * file cleanup function from the previous pool, we need to
+-         * call that only from the sender thread.
+-         *
+-         * Currently, we do not handle file bucket with refcount > 1 as
+-         * the beam is then not in complete control of the file's lifetime.
+-         * Which results in the bug that a file get closed by the receiver
+-         * while the sender or the beam still have buckets using it. 
+-         * 
+-         * Additionally, we allow callbacks to prevent beaming file
+-         * handles across. The use case for this is to limit the number 
+-         * of open file handles and rather use a less efficient beam
+-         * transport. */
+-        apr_bucket_file *bf = b->data;
+-        apr_file_t *fd = bf->fd;
+-        int can_beam = (bf->refcount.refcount == 1);
+-        if (can_beam && beam->can_beam_fn) {
+-            can_beam = beam->can_beam_fn(beam->can_beam_ctx, beam, fd);
+-        }
+-        if (can_beam) {
+-            status = apr_bucket_setaside(b, beam->send_pool);
+-        }
+-        /* else: enter ENOTIMPL case below */
++    else if (APR_BUCKET_IS_FILE(b) && can_beam) {
++        status = apr_bucket_setaside(b, beam->send_pool);
+     }
+     
+     if (status == APR_ENOTIMPL) {
+@@ -865,12 +894,6 @@
+          * a counter example).
+          * We do the read while in the sender thread, so that the bucket may
+          * use pools/allocators safely. */
+-        if (space_left < APR_BUCKET_BUFF_SIZE) {
+-            space_left = APR_BUCKET_BUFF_SIZE;
+-        }
+-        if (space_left < b->length) {
+-            apr_bucket_split(b, space_left);
+-        }
+         status = apr_bucket_read(b, &data, &len, APR_BLOCK_READ);
+         if (status == APR_SUCCESS) {
+             status = apr_bucket_setaside(b, beam->send_pool);
+@@ -884,7 +907,7 @@
+     APR_BUCKET_REMOVE(b);
+     H2_BLIST_INSERT_TAIL(&beam->send_list, b);
+     beam->sent_bytes += b->length;
+-    
++
+     return APR_SUCCESS;
+ }
+@@ -904,7 +927,8 @@
+                           apr_read_type_e block)
+ {
+     apr_bucket *b;
+-    apr_status_t status = APR_SUCCESS;
++    apr_status_t rv = APR_SUCCESS;
++    apr_size_t space_left = 0;
+     h2_beam_lock bl;
+     /* Called from the sender thread to add buckets to the beam */
+@@ -914,23 +938,31 @@
+         
+         if (beam->aborted) {
+             move_to_hold(beam, sender_bb);
+-            status = APR_ECONNABORTED;
++            rv = APR_ECONNABORTED;
+         }
+         else if (sender_bb) {
+-            int force_report = !APR_BRIGADE_EMPTY(sender_bb); 
+-            while (!APR_BRIGADE_EMPTY(sender_bb) && status == APR_SUCCESS) {
++            int force_report = !APR_BRIGADE_EMPTY(sender_bb);
++            
++            space_left = calc_space_left(beam);
++            while (!APR_BRIGADE_EMPTY(sender_bb) && APR_SUCCESS == rv) {
++                if (space_left <= 0) {
++                    report_prod_io(beam, force_report, &bl);
++                    rv = wait_not_full(beam, block, &space_left, &bl);
++                    if (APR_SUCCESS != rv) {
++                        break;
++                    }
++                }
+                 b = APR_BRIGADE_FIRST(sender_bb);
+-                status = append_bucket(beam, b, block, &bl);
++                rv = append_bucket(beam, b, block, &space_left, &bl);
+             }
++            
+             report_prod_io(beam, force_report, &bl);
+-            if (beam->cond) {
+-                apr_thread_cond_broadcast(beam->cond);
+-            }
++            apr_thread_cond_broadcast(beam->change);
+         }
+         report_consumption(beam, &bl);
+         leave_yellow(beam, &bl);
+     }
+-    return status;
++    return rv;
+ }
+ apr_status_t h2_beam_receive(h2_bucket_beam *beam, 
+@@ -942,11 +974,16 @@
+     apr_bucket *bsender, *brecv, *ng;
+     int transferred = 0;
+     apr_status_t status = APR_SUCCESS;
+-    apr_off_t remain = readbytes;
++    apr_off_t remain;
+     int transferred_buckets = 0;
+     
+     /* Called from the receiver thread to take buckets from the beam */
+     if (enter_yellow(beam, &bl) == APR_SUCCESS) {
++        if (readbytes <= 0) {
++            readbytes = APR_SIZE_MAX;
++        }
++        remain = readbytes;
++        
+ transfer:
+         if (beam->aborted) {
+             recv_buffer_cleanup(beam, &bl);
+@@ -955,11 +992,12 @@
+         }
+         /* transfer enough buckets from our receiver brigade, if we have one */
+-        while (beam->recv_buffer
+-               && !APR_BRIGADE_EMPTY(beam->recv_buffer)
+-               && (readbytes <= 0 || remain >= 0)) {
++        while (remain >= 0 
++               && beam->recv_buffer 
++               && !APR_BRIGADE_EMPTY(beam->recv_buffer)) {
++               
+             brecv = APR_BRIGADE_FIRST(beam->recv_buffer);
+-            if (readbytes > 0 && brecv->length > 0 && remain <= 0) {
++            if (brecv->length > 0 && remain <= 0) {
+                 break;
+             }            
+             APR_BUCKET_REMOVE(brecv);
+@@ -970,11 +1008,11 @@
+         /* transfer from our sender brigade, transforming sender buckets to
+          * receiver ones until we have enough */
+-        while (!H2_BLIST_EMPTY(&beam->send_list) && (readbytes <= 0 || remain >= 0)) {
+-            bsender = H2_BLIST_FIRST(&beam->send_list);
++        while (remain >= 0 && !H2_BLIST_EMPTY(&beam->send_list)) {
++               
+             brecv = NULL;
+-            
+-            if (readbytes > 0 && bsender->length > 0 && remain <= 0) {
++            bsender = H2_BLIST_FIRST(&beam->send_list);            
++            if (bsender->length > 0 && remain <= 0) {
+                 break;
+             }
+                         
+@@ -1020,11 +1058,12 @@
+                  * been handed out. See also PR 59348 */
+                 apr_bucket_file_enable_mmap(ng, 0);
+ #endif
+-                remain -= bsender->length;
+-                ++transferred;
+                 APR_BUCKET_REMOVE(bsender);
+                 H2_BLIST_INSERT_TAIL(&beam->hold_list, bsender);
++
++                remain -= bsender->length;
+                 ++transferred;
++                ++transferred_buckets;
+                 continue;
+             }
+             else {
+@@ -1041,6 +1080,7 @@
+              * receiver bucket references it any more. */
+             APR_BUCKET_REMOVE(bsender);
+             H2_BLIST_INSERT_TAIL(&beam->hold_list, bsender);
++            
+             beam->received_bytes += bsender->length;
+             ++transferred_buckets;
+             
+@@ -1063,8 +1103,8 @@
+             }
+         }
+-        if (readbytes > 0 && remain < 0) {
+-            /* too much, put some back */
++        if (remain < 0) {
++            /* too much, put some back into out recv_buffer */
+             remain = readbytes;
+             for (brecv = APR_BRIGADE_FIRST(bb);
+                  brecv != APR_BRIGADE_SENTINEL(bb);
+@@ -1081,15 +1121,7 @@
+             }
+         }
+-        if (transferred_buckets > 0) {
+-           if (beam->cons_ev_cb) { 
+-               beam->cons_ev_cb(beam->cons_ctx, beam);
+-            }
+-        }
+-        
+-        if (beam->closed 
+-            && (!beam->recv_buffer || APR_BRIGADE_EMPTY(beam->recv_buffer))
+-            && H2_BLIST_EMPTY(&beam->send_list)) {
++        if (beam->closed && buffer_is_empty(beam)) {
+             /* beam is closed and we have nothing more to receive */ 
+             if (!beam->close_sent) {
+                 apr_bucket *b = apr_bucket_eos_create(bb->bucket_alloc);
+@@ -1100,28 +1132,23 @@
+             }
+         }
+         
++        if (transferred_buckets > 0) {
++           if (beam->cons_ev_cb) { 
++               beam->cons_ev_cb(beam->cons_ctx, beam);
++            }
++        }
++        
+         if (transferred) {
+-            if (beam->cond) {
+-                apr_thread_cond_broadcast(beam->cond);
+-            }
++            apr_thread_cond_broadcast(beam->change);
+             status = APR_SUCCESS;
+         }
+-        else if (beam->closed) {
+-            status = APR_EOF;
+-        }
+-        else if (block == APR_BLOCK_READ && bl.mutex && beam->cond) {
+-            status = wait_cond(beam, bl.mutex);
++        else {
++            status = wait_not_empty(beam, block, bl.mutex);
+             if (status != APR_SUCCESS) {
+                 goto leave;
+             }
+             goto transfer;
+         }
+-        else {
+-            if (beam->cond) {
+-                apr_thread_cond_broadcast(beam->cond);
+-            }
+-            status = APR_EAGAIN;
+-        }
+ leave:        
+         leave_yellow(beam, &bl);
+     }
+Index: modules/http2/h2_bucket_beam.h
+===================================================================
+--- modules/http2/h2_bucket_beam.h     (revision 1804645)
++++ modules/http2/h2_bucket_beam.h     (working copy)
+@@ -190,7 +190,7 @@
+     unsigned int tx_mem_limits : 1; /* only memory size counts on transfers */
+     struct apr_thread_mutex_t *lock;
+-    struct apr_thread_cond_t *cond;
++    struct apr_thread_cond_t *change;
+     void *m_ctx;
+     h2_beam_mutex_enter *m_enter;
+     
+Index: modules/http2/h2_stream.c
+===================================================================
+--- modules/http2/h2_stream.c  (revision 1804645)
++++ modules/http2/h2_stream.c  (working copy)
+@@ -774,20 +774,20 @@
+     return NULL;
+ }
+-static apr_status_t add_data(h2_stream *stream, apr_off_t requested,
+-                             apr_off_t *plen, int *peos, int *complete, 
+-                             h2_headers **pheaders)
++static apr_status_t add_buffered_data(h2_stream *stream, apr_off_t requested,
++                                      apr_off_t *plen, int *peos, int *is_all, 
++                                      h2_headers **pheaders)
+ {
+     apr_bucket *b, *e;
+     
+     *peos = 0;
+     *plen = 0;
+-    *complete = 0;
++    *is_all = 0;
+     if (pheaders) {
+         *pheaders = NULL;
+     }
+-    H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "add_data");
++    H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "add_buffered_data");
+     b = APR_BRIGADE_FIRST(stream->out_buffer);
+     while (b != APR_BRIGADE_SENTINEL(stream->out_buffer)) {
+         e = APR_BUCKET_NEXT(b);
+@@ -833,7 +833,7 @@
+         }
+         b = e;
+     }
+-    *complete = 1;
++    *is_all = 1;
+     return APR_SUCCESS;
+ }
+@@ -865,7 +865,7 @@
+     requested = (*plen > 0)? H2MIN(*plen, max_chunk) : max_chunk;
+     
+     /* count the buffered data until eos or a headers bucket */
+-    status = add_data(stream, requested, plen, peos, &complete, pheaders);
++    status = add_buffered_data(stream, requested, plen, peos, &complete, pheaders);
+     
+     if (status == APR_EAGAIN) {
+         /* TODO: ugly, someone needs to retrieve the response first */
+@@ -882,29 +882,39 @@
+         return APR_SUCCESS;
+     }
+     
++    /* If there we do not have enough buffered data to satisfy the requested
++     * length *and* we counted the _complete_ buffer (and did not stop in the middle
++     * because of meta data there), lets see if we can read more from the
++     * output beam */
+     missing = H2MIN(requested, stream->max_mem) - *plen;
+     if (complete && !*peos && missing > 0) {
++        apr_status_t rv = APR_EOF;
++        
+         if (stream->output) {
+             H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "pre");
+-            status = h2_beam_receive(stream->output, stream->out_buffer, 
+-                                     APR_NONBLOCK_READ, 
+-                                     stream->max_mem - *plen);
++            rv = h2_beam_receive(stream->output, stream->out_buffer, 
++                                 APR_NONBLOCK_READ, stream->max_mem - *plen);
+             H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "post");
+         }
+-        else {
+-            status = APR_EOF;
++        
++        if (rv == APR_SUCCESS) {
++            /* count the buffer again, now that we have read output */
++            status = add_buffered_data(stream, requested, plen, peos, &complete, pheaders);
+         }
+-        
+-        if (APR_STATUS_IS_EOF(status)) {
++        else if (APR_STATUS_IS_EOF(rv)) {
+             apr_bucket *eos = apr_bucket_eos_create(c->bucket_alloc);
+             APR_BRIGADE_INSERT_TAIL(stream->out_buffer, eos);
+             *peos = 1;
+-            status = APR_SUCCESS;
+         }
+-        else if (status == APR_SUCCESS) {
+-            /* do it again, now that we have gotten more */
+-            status = add_data(stream, requested, plen, peos, &complete, pheaders);
++        else if (APR_STATUS_IS_EAGAIN(rv)) {
++            /* we set this is the status of this call only if there
++             * is no buffered data, see check below */
+         }
++        else {
++            /* real error reading. Give this back directly, even though
++             * we may have something buffered. */
++            status = rv;
++        }
+     }
+     
+     if (status == APR_SUCCESS) {
+Index: modules/http2/h2_task.c
+===================================================================
+--- modules/http2/h2_task.c    (revision 1804645)
++++ modules/http2/h2_task.c    (working copy)
+@@ -129,7 +129,7 @@
+                               apr_bucket_brigade* bb)
+ {
+     apr_bucket *b;
+-    apr_status_t status = APR_SUCCESS;
++    apr_status_t rv = APR_SUCCESS;
+     int flush = 0, blocking;
+     
+     if (task->frozen) {
+@@ -148,17 +148,16 @@
+         return APR_SUCCESS;
+     }
++send:
+     /* we send block once we opened the output, so someone is there
+      * reading it *and* the task is not assigned to a h2_req_engine */
+     blocking = (!task->assigned && task->output.opened);
+-    if (!task->output.opened) {
+-        for (b = APR_BRIGADE_FIRST(bb);
+-             b != APR_BRIGADE_SENTINEL(bb);
+-             b = APR_BUCKET_NEXT(b)) {
+-            if (APR_BUCKET_IS_FLUSH(b)) {
+-                flush = 1;
+-                break;
+-            }
++    for (b = APR_BRIGADE_FIRST(bb);
++         b != APR_BRIGADE_SENTINEL(bb);
++         b = APR_BUCKET_NEXT(b)) {
++        if (APR_BUCKET_IS_FLUSH(b) || APR_BUCKET_IS_EOS(b) || AP_BUCKET_IS_EOR(b)) {
++            flush = 1;
++            break;
+         }
+     }
+     
+@@ -166,32 +165,48 @@
+         /* still have data buffered from previous attempt.
+          * setaside and append new data and try to pass the complete data */
+         if (!APR_BRIGADE_EMPTY(bb)) {
+-            status = ap_save_brigade(f, &task->output.bb, &bb, task->pool);
++            if (APR_SUCCESS != (rv = ap_save_brigade(f, &task->output.bb, &bb, task->pool))) {
++                goto out;
++            }
+         }
+-        if (status == APR_SUCCESS) {
+-            status = send_out(task, task->output.bb, blocking);
+-        } 
++        rv = send_out(task, task->output.bb, blocking);
+     }
+     else {
+-        /* no data buffered here, try to pass the brigade directly */
+-        status = send_out(task, bb, blocking); 
+-        if (status == APR_SUCCESS && !APR_BRIGADE_EMPTY(bb)) {
+-            /* could not write all, buffer the rest */
+-            ap_log_cerror(APLOG_MARK, APLOG_DEBUG, status, task->c, APLOGNO(03405)
+-                          "h2_slave_out(%s): saving brigade", 
+-                          task->id);
+-            status = ap_save_brigade(f, &task->output.bb, &bb, task->pool);
+-            flush = 1;
++        /* no data buffered previously, pass brigade directly */
++        rv = send_out(task, bb, blocking);
++
++        if (APR_SUCCESS == rv && !APR_BRIGADE_EMPTY(bb)) {
++            /* output refused to buffer it all, time to open? */
++            if (!task->output.opened && APR_SUCCESS == (rv = open_output(task))) {
++                /* Make another attempt to send the data. With the output open,
++                 * the call might be blocking and send all data, so we do not need
++                 * to save the brigade */
++                goto send;
++            }
++            else if (blocking && flush) {
++                /* Need to keep on doing this. */
++                goto send;
++            }
++            
++            if (APR_SUCCESS == rv) {
++                /* could not write all, buffer the rest */
++                ap_log_cerror(APLOG_MARK, APLOG_DEBUG, rv, task->c, APLOGNO(03405)
++                              "h2_slave_out(%s): saving brigade", task->id);
++                ap_assert(NULL);
++                rv = ap_save_brigade(f, &task->output.bb, &bb, task->pool);
++                flush = 1;
++            }
+         }
+     }
+     
+-    if (status == APR_SUCCESS && !task->output.opened && flush) {
++    if (APR_SUCCESS == rv && !task->output.opened && flush) {
+         /* got a flush or could not write all, time to tell someone to read */
+-        status = open_output(task);
++        rv = open_output(task);
+     }
+-    ap_log_cerror(APLOG_MARK, APLOG_TRACE2, status, task->c, 
++out:
++    ap_log_cerror(APLOG_MARK, APLOG_TRACE2, rv, task->c, 
+                   "h2_slave_out(%s): slave_out leave", task->id);    
+-    return status;
++    return rv;
+ }
+ static apr_status_t output_finish(h2_task *task)
+Index: modules/http2/h2_version.h
+===================================================================
+--- modules/http2/h2_version.h (revision 1804645)
++++ modules/http2/h2_version.h (working copy)
+@@ -26,7 +26,7 @@
+  * @macro
+  * Version number of the http2 module as c string
+  */
+-#define MOD_HTTP2_VERSION "1.10.7"
++#define MOD_HTTP2_VERSION "1.10.10"
+ /**
+  * @macro
+@@ -34,7 +34,7 @@
+  * release. This is a 24 bit number with 8 bits for major number, 8 bits
+  * for minor and 8 bits for patch. Version 1.2.3 becomes 0x010203.
+  */
+-#define MOD_HTTP2_VERSION_NUM 0x010a06
++#define MOD_HTTP2_VERSION_NUM 0x010a0a
+ #endif /* mod_h2_h2_version_h */
+Index: modules/http2
+===================================================================
+--- modules/http2      (revision 1804645)
++++ modules/http2      (working copy)
+
+Property changes on: modules/http2
+___________________________________________________________________
+Modified: svn:mergeinfo
+## -0,0 +0,1 ##
+   Merged /httpd/httpd/trunk/modules/http2:r1803420,1803454,1804090
+Index: .
+===================================================================
+--- .  (revision 1804645)
++++ .  (working copy)
+
+Property changes on: .
+___________________________________________________________________
+Modified: svn:mergeinfo
+## -0,0 +0,1 ##
+   Merged /httpd/httpd/trunk:r1803420,1803454,1804090
index aa471e621a4ccbb2f15e0f3257c9aa9ee7852b38..4fbf34aee115d5116a6ad99a071a2c09f1019bdf 100644 (file)
@@ -21,7 +21,7 @@
 #                                                                             #
 ###############################################################################
 #
-# id: wio.cgi, v1.3.1 2017/07/11 21:31:16 sfeddersen
+# id: wio.cgi, v1.3.2 2017/08/27 14:11:16 sfeddersen
 #
 # This wio.cgi is based on the Code from the IPCop WIO Addon
 # and is extremly adapted to work with IPFire.
@@ -917,7 +917,10 @@ print"
        <td align='left'><select size='1' name='CRON' size='5'>
 ";
 
-for ($i=5; $i<=60; $i+=5) { printf("<option %s>%02s</option>\n",$selected{'CRON'}{$i},$i); }
+for ($i=5; $i<=60; $i+=5) {
+       $_ = sprintf("%02s",$i);
+       print "<option $selected{'CRON'}{$_}>$_</option>\n";
+}
 
 print"
        </select>&nbsp;$Lang::tr{'wio min'}</td>
@@ -929,7 +932,10 @@ print"
        <td align='left'><select size='1' name='TIMEOUT' size='5'>
 ";
 
-for ($i=1; $i<=15; $i++) { printf("<option %s>%02s</option>\n",$selected{'TIMEOUT'}{$i},$i); }
+for ($i=1; $i<=15; $i++) {
+       $_ = sprintf("%02s",$i);
+       print "<option $selected{'TIMEOUT'}{$_}>$_</option>\n";
+}
 
 print" 
        </select>&nbsp;$Lang::tr{'wio sec'}</td>
@@ -980,7 +986,10 @@ print"
        <td align='left'><select size='1' name='OVPNCRON' size='5'>
 ";
 
-for ($i=1; $i<=15; $i++) { printf("<option %s>%02s</option>\n",$selected{'OVPNCRON'}{$i},$i); }
+for ($i=1; $i<=15; $i++) {
+       $_ = sprintf("%02s",$i);
+       print "<option $selected{'OVPNCRON'}{$_}>$_</option>\n";
+}
 
 print"
        </select>&nbsp;$Lang::tr{'wio min'}</td>
@@ -1947,7 +1956,13 @@ print"
 <table border='0' width='100%' bordercolor='$Header::bordercolour' cellspacing='0' cellpadding='0' style='border-collapse: collapse'>
 <tr bgcolor='$color{'color22'}'>
        <td colspan='2' align='right'></td>
-       <td width='10%' align='right'><form method='post' action='/cgi-bin/logs.cgi/log.dat' enctype='multipart/form-data'><input type='hidden' name='SECTION' value='wio' /><input type='submit' name='SUBMIT' value='$Lang::tr{'system logs'}' /></form></td>
+";
+
+if ( $wiosettings{'LOGGING'} eq 'on' ) {
+       print"<td width='10%' align='right'><form method='post' action='/cgi-bin/logs.cgi/log.dat' enctype='multipart/form-data'><input type='hidden' name='SECTION' value='wio' /><input type='submit' name='SUBMIT' value='$Lang::tr{'system logs'}' /></form></td>";
+}
+
+print"
        <td width='10%' align='right'><form method='post' action='$ENV{'SCRIPT_NAME'}' enctype='multipart/form-data'><input type='hidden' name='ACTION' value='$Lang::tr{'edit'}1' /><input type='submit' name='SUBMIT' value='$Lang::tr{'wio_edit_set'}' /></form></td>
 </tr>
 </table>
index 73702370eba55fc310c88530609441479c40654f..06b6946451e36b9d5f7f67812e23cd0486ad2775 100644 (file)
@@ -21,7 +21,7 @@
 #                                                                             #
 ###############################################################################
 #
-# id: wiographs.cgi, v1.3.1 2017/07/11 21:31:16 sfeddersen
+# id: wiographs.cgi, v1.3.2 2017/08/27 14:11:16 sfeddersen
 #
 # This wiographs.cgi is based on the Code from the IPCop WIO Addon
 # and is extremly adapted to work with IPFire.