From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Tremer <michael.tremer@ipfire.org> To: development@lists.ipfire.org Subject: Re: [PATCH] bluetooth: drop outdated bluetooth addon Date: Mon, 02 Mar 2020 12:01:43 +0000 Message-ID: <73C54C49-E2AF-49C3-AE9D-BDCEADCD51B0@ipfire.org> In-Reply-To: <20200302115835.17639-1-arne_f@ipfire.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5485457045838234863==" List-Id: <development.lists.ipfire.org> --===============5485457045838234863== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hi, I totally ACK this, because we have a lot of software at the moment that is b= asically unused and therefore unmaintained. Acked-by: Michael Tremer <michael.tremer(a)ipfire.org> -Michael > On 2 Mar 2020, at 11:58, Arne Fitzenreiter <arne_f(a)ipfire.org> wrote: >=20 > The cgi support only rfcomm modem dialup. This is not used by modern hardwa= re. > Also the used bluez stack version is outdated long time. >=20 > Signed-off-by: Arne Fitzenreiter <arne_f(a)ipfire.org> > --- > config/backup/includes/bluetooth | 2 - > config/menu/EX-bluetooth.menu | 5 - > config/rootfiles/common/web-user-interface | 1 - > html/cgi-bin/bluetooth.cgi | 187 --------------------- > lfs/bluetooth | 134 --------------- > lfs/cups | 6 +- > lfs/initscripts | 5 +- > make.sh | 1 - > 8 files changed, 4 insertions(+), 337 deletions(-) > delete mode 100644 config/backup/includes/bluetooth > delete mode 100644 config/menu/EX-bluetooth.menu > delete mode 100644 html/cgi-bin/bluetooth.cgi > delete mode 100644 lfs/bluetooth >=20 > diff --git a/config/backup/includes/bluetooth b/config/backup/includes/blue= tooth > deleted file mode 100644 > index 342aa6296..000000000 > --- a/config/backup/includes/bluetooth > +++ /dev/null > @@ -1,2 +0,0 @@ > -/etc/bluetooth/ > -/var/ipfire/bluetooth/ > diff --git a/config/menu/EX-bluetooth.menu b/config/menu/EX-bluetooth.menu > deleted file mode 100644 > index b7f1728a5..000000000 > --- a/config/menu/EX-bluetooth.menu > +++ /dev/null > @@ -1,5 +0,0 @@ > - $subipfire->{'55.bluetooth'} =3D {'caption' =3D> bluetooth, > - 'uri' =3D> '/cgi-bin/bluetooth.cgi', > - 'title' =3D> bluetooth, > - 'enabled' =3D> 1, > - }; > diff --git a/config/rootfiles/common/web-user-interface b/config/rootfiles/= common/web-user-interface > index a88dd8770..a3636002e 100644 > --- a/config/rootfiles/common/web-user-interface > +++ b/config/rootfiles/common/web-user-interface > @@ -7,7 +7,6 @@ srv/web/ipfire/cgi-bin/aliases.cgi > #srv/web/ipfire/cgi-bin/asterisk/status.cgi > srv/web/ipfire/cgi-bin/atm-status.cgi > srv/web/ipfire/cgi-bin/backup.cgi > -srv/web/ipfire/cgi-bin/bluetooth.cgi > #srv/web/ipfire/cgi-bin/captive > srv/web/ipfire/cgi-bin/captive.cgi > srv/web/ipfire/cgi-bin/captive/index.cgi > diff --git a/html/cgi-bin/bluetooth.cgi b/html/cgi-bin/bluetooth.cgi > deleted file mode 100644 > index 32bd8e8e0..000000000 > --- a/html/cgi-bin/bluetooth.cgi > +++ /dev/null > @@ -1,187 +0,0 @@ > -#!/usr/bin/perl > -##########################################################################= ##### > -# = # > -# IPFire.org - A linux based firewall = # > -# Copyright (C) 2007 Michael Tremer & Christian Schmidt = # > -# = # > -# 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 = # > -# the Free Software Foundation, either version 3 of the License, or = # > -# (at your option) any later version. = # > -# = # > -# This program 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 this program. If not, see <http://www.gnu.org/licenses/>. = # > -# = # > -##########################################################################= ##### > -# > - > -use strict; > - > -# enable only the following on debugging purpose > -use warnings; > -use CGI::Carp 'fatalsToBrowser'; > - > -require '/var/ipfire/general-functions.pl'; > -require '/var/ipfire/lang.pl'; > -require '/var/ipfire/header.pl'; > - > -my $debug =3D 0; > -my $i =3D 0; > -my $errormessage =3D ''; > -my $status_started =3D "<td align=3D'center' bgcolor=3D'${Header::colourgr= een}'><font color=3D'white'><b>$Lang::tr{'running'}</b></font></td>"; > -my $status_stopped =3D "<td align=3D'center' bgcolor=3D'${Header::colourre= d}'><font color=3D'white'><b>$Lang::tr{'stopped'}</b></font></td>"; > - > -# get rid of used only once warnings > -my @onlyonce =3D ( $Header::colourgreen, $Header::colourred ); > -undef @onlyonce; > - > -my %selected=3D(); > -my %checked=3D(); > -my %color =3D (); > -my %mainsettings =3D (); > - > -&General::readhash("${General::swroot}/main/settings", \%mainsettings); > -&General::readhash("/srv/web/ipfire/html/themes/".$mainsettings{'THEME'}."= /include/colors.txt", \%color); > - > -my %bluetoothsettings=3D(); > -$bluetoothsettings{'PASSKEY_AGENT'} =3D 'on'; > -$bluetoothsettings{'PWD'} =3D '12345'; > -$bluetoothsettings{'RFCOMM0_BIND'} =3D 'off'; > -$bluetoothsettings{'RFCOMM0_DEVICE'} =3D ''; > -$bluetoothsettings{'RFCOMM0_CHANNEL'} =3D '1'; > -$bluetoothsettings{'RFCOMM1_BIND'} =3D 'off'; > -$bluetoothsettings{'RFCOMM1_DEVICE'} =3D ''; > -$bluetoothsettings{'RFCOMM1_CHANNEL'} =3D '1'; > - > -&General::readhash("/var/ipfire/bluetooth/settings", \%bluetoothsettings); > - > -my %cgiparams=3D(); > -$cgiparams{'ACTION'} =3D ''; > -$cgiparams{'RUNNING'} =3D 'off'; > -$cgiparams{'PASSKEY_AGENT'} =3D 'off'; > -$cgiparams{'PWD'} =3D ''; > -$cgiparams{'RFCOMM0_BIND'} =3D 'off'; > -$cgiparams{'RFCOMM0_DEVICE'} =3D ''; > -$cgiparams{'RFCOMM0_CHANNEL'} =3D ''; > -$cgiparams{'RFCOMM1_BIND'} =3D 'off'; > -$cgiparams{'RFCOMM1_DEVICE'} =3D ''; > -$cgiparams{'RFCOMM1_CHANNEL'} =3D ''; > - > - > -&Header::getcgihash(\%cgiparams); > - > -&Header::showhttpheaders(); > - > -if ( $cgiparams{'ACTION'} eq "$Lang::tr{'save'}" ){ > - $bluetoothsettings{'PASSKEY_AGENT'} =3D $cgiparams{'PASSKEY_AGENT'}; > - $bluetoothsettings{'PWD'} =3D $cgiparams{'PWD'}; > - if ( (length($bluetoothsettings{'PWD'}) < 4) || (length($bluetoothsetting= s{'PWD'}) > 8) ){ > - $errormessage .=3D "Invalid length in Passphrase. Must be between 4 and = 8 characters.<br />"; > - } > - $bluetoothsettings{'RFCOMM0_BIND'} =3D $cgiparams{'RFCOMM0_BIND'}; > - $bluetoothsettings{'RFCOMM1_BIND'} =3D $cgiparams{'RFCOMM1_BIND'}; > - $bluetoothsettings{'RFCOMM0_DEVICE'} =3D $cgiparams{'RFCOMM0_DEVICE'}; > - $bluetoothsettings{'RFCOMM1_DEVICE'} =3D $cgiparams{'RFCOMM1_DEVICE'}; > - $bluetoothsettings{'RFCOMM0_CHANNEL'} =3D $cgiparams{'RFCOMM0_CHANNEL'}; > - $bluetoothsettings{'RFCOMM1_CHANNEL'} =3D $cgiparams{'RFCOMM1_CHANNEL'}; > -=09 > -# TODO: CHECK RFCOMM DEVICES > - > - if ( $errormessage eq '' ){ > - &WriteConfig(); > - system("/usr/local/bin/addonctrl bluetooth restart >/dev/null 2>&1") > - } > -} > - > -&Header::openpage('Bluetooth', 1, '', ''); > -&Header::openbigbox('100%', 'left', '', $errormessage); > -print "<form method=3D'post' action=3D'$ENV{'SCRIPT_NAME'}'>"; > - > -if ( $errormessage ){ > - &Header::openbox('100%', 'left', $Lang::tr{'error messages'}); > - print "<class name=3D'base'>$errormessage\n"; > - print " </class>\n"; > - &Header::closebox(); > -} > - > - > -# Found this usefull piece of code in BlockOutTraffic AddOn 8-) > -# fwrules.cgi > -############### > -# DEBUG DEBUG > -if ( $debug ){ > - &Header::openbox('100%', 'left', 'DEBUG'); > - my $debugCount =3D 0; > - foreach my $line (sort keys %cgiparams) { > - print "$line =3D '$cgiparams{$line}'<br />\n"; > - $debugCount++; > - } > - print " Count: $debugCount\n"; > - &Header::closebox(); > -} > -# DEBUG DEBUG > -############### > - > - > -my $checked_passkey_agent =3D ''; > -my $checked_rfcomm0_bind =3D ''; > -my $checked_rfcomm1_bind =3D ''; > - > -$checked_passkey_agent =3D "checked=3D'checked'" if ( $bluetoothsettings{'= PASSKEY_AGENT'} eq 'on' ); > -$checked_rfcomm0_bind =3D "checked=3D'checked'" if ( $bluetoothsettings{'R= FCOMM0_BIND'} eq 'on' ); > -$checked_rfcomm1_bind =3D "checked=3D'checked'" if ( $bluetoothsettings{'R= FCOMM1_BIND'} eq 'on' ); > - > -# > -# Devices box > -# > -&Header::openbox('100%', 'left', "Bluetooth devices in range"); > -print <<END > -<table width=3D'100%'> > -END > -; > -my $bluetooth_scan =3D `hcitool scan | grep -v "Scanning ..." | sed 's|:|-= |g'`; > - > -print "<table width=3D'80%'><td bgcolor=3D'${Header::colourblue}'><font co= lor=3D'white'><pre>$bluetooth_scan</pre></font></td></table>"; > - > -&Header::closebox(); > - > -# > -# Bluetooth settings > -# > -&Header::openbox('100%', 'left', "Bluetooth Settings"); > -print <<END > -<table width=3D'100%'> > -<tr><td width=3D'25%' class=3D'base'>Passkey-Agent: </td><td class=3D= 'base'><input type=3D'checkbox' name=3D'PASSKEY_AGENT' $checked_passkey_agent= /></td> > - <td width=3D'25%' class=3D'base'>Password: </td><td class=3D'base= '><input type=3D'text' name=3D'PWD' size=3D'8' value=3D'$bluetoothsettings{'P= WD'}' /></td></tr> > -<tr><td width=3D'25%' class=3D'base'>Bind rfcomm0: </td><td class=3D'= base' colspan=3D'3'><input type=3D'checkbox' name=3D'RFCOMM0_BIND' $checked_r= fcomm0_bind /> > - Device: <input type=3D'text' name=3D'RFCOMM0_DEVICE' size=3D'17'= value=3D'$bluetoothsettings{'RFCOMM0_DEVICE'}' /> > - Channel: <input type=3D'text' name=3D'RFCOMM0_CHANNEL' size=3D'1= ' value=3D'$bluetoothsettings{'RFCOMM0_CHANNEL'}' /></td></tr> > -<tr><td width=3D'25%' class=3D'base'>Bind rfcomm1: </td><td class=3D'= base' colspan=3D'3'><input type=3D'checkbox' name=3D'RFCOMM1_BIND' $checked_r= fcomm1_bind /> > - Device: <input type=3D'text' name=3D'RFCOMM1_DEVICE' size=3D'17'= value=3D'$bluetoothsettings{'RFCOMM1_DEVICE'}' /> > - Channel: <input type=3D'text' name=3D'RFCOMM1_CHANNEL' size=3D'1= ' value=3D'$bluetoothsettings{'RFCOMM1_CHANNEL'}' /></td></tr> > - > -</table> > -<hr /><table width=3D'100%'> > -<tr> > -<td width=3D'55%' class=3D'base' valign=3D'top'> </td> > -<td width=3D'40%' align=3D'center'><input type=3D'submit' name=3D'ACTION' = value=3D'$Lang::tr{'save'}' /></td> > -</tr> > -</table> > -END > -; > -&Header::closebox(); > - > -print "</form>"; > -&Header::closebigbox(); > -&Header::closepage(); > - > - > -sub WriteConfig{ > - &General::writehash("/var/ipfire/bluetooth/settings", \%bluetoothsettings= ); > -} > - > diff --git a/lfs/bluetooth b/lfs/bluetooth > deleted file mode 100644 > index 2a0130085..000000000 > --- a/lfs/bluetooth > +++ /dev/null > @@ -1,134 +0,0 @@ > -##########################################################################= ##### > -# = # > -# IPFire.org - A linux based firewall = # > -# Copyright (C) 2007-2018 IPFire Team <info(a)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 = # > -# the Free Software Foundation, either version 3 of the License, or = # > -# (at your option) any later version. = # > -# = # > -# This program 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 this program. If not, see <http://www.gnu.org/licenses/>. = # > -# = # > -##########################################################################= ##### > - > -##########################################################################= ##### > -# Definitions > -##########################################################################= ##### > - > -include Config > - > -VER =3D 3.36 > - > -THISAPP =3D bluez-libs-$(VER) > -DL_FILE =3D $(THISAPP).tar.gz > -DL_FROM =3D $(URL_IPFIRE) > -DIR_APP =3D $(DIR_SRC)/$(THISAPP) > -TARGET =3D $(DIR_INFO)/$(THISAPP) > -PROG =3D bluetooth > -PAK_VER =3D 1 > - > -DEPS =3D "dbus" > - > -##########################################################################= ##### > -# Top-level Rules > -##########################################################################= ##### > - > -objects =3D $(DL_FILE) bluez-utils-$(VER).tar.gz bluez-firmware-1.2.tar.gz= bluez-hcidump-1.42.tar.gz > - > -$(DL_FILE) =3D $(DL_FROM)/$(DL_FILE) > -bluez-utils-$(VER).tar.gz =3D $(DL_FROM)/bluez-utils-$(VER).tar.gz > -bluez-firmware-1.2.tar.gz =3D $(DL_FROM)/bluez-firmware-1.2.tar.gz > -bluez-hcidump-1.42.tar.gz =3D $(DL_FROM)/bluez-hcidump-1.42.tar.gz > - > -$(DL_FILE)_MD5 =3D 8c2ca546c0e7bb73dbd0e906fce7f6b1 > -bluez-utils-$(VER).tar.gz_MD5 =3D 4fc292b635ba7b442c7aaf5680199012 > -bluez-firmware-1.2.tar.gz_MD5 =3D 1cc3cefad872e937e05de5a0a2b390dd > -bluez-hcidump-1.42.tar.gz_MD5 =3D 5704737aaf72104eeaf77335218a1827 > - > -install : $(TARGET) > - > -check : $(patsubst %,$(DIR_CHK)/%,$(objects)) > - > -download :$(patsubst %,$(DIR_DL)/%,$(objects)) > - > -md5 : $(subst %,%_MD5,$(objects)) > - > -dist:=20 > - @$(PAK) > - > -##########################################################################= ##### > -# Downloading, checking, md5sum > -##########################################################################= ##### > - > -$(patsubst %,$(DIR_CHK)/%,$(objects)) : > - @$(CHECK) > - > -$(patsubst %,$(DIR_DL)/%,$(objects)) : > - @$(LOAD) > - > -$(subst %,%_MD5,$(objects)) : > - @$(MD5) > - > -##########################################################################= ##### > -# Installation Details > -##########################################################################= ##### > - > -$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) > - @$(PREBUILD) > - @rm -rf $(DIR_SRC)/bluez* > - cd $(DIR_SRC) && tar zxf $(DIR_DL)/$(DL_FILE) > - cd $(DIR_APP) && tar xzf $(DIR_DL)/bluez-utils-$(VER).tar.gz > - cd $(DIR_APP) && tar xzf $(DIR_DL)/bluez-firmware-1.2.tar.gz > - cd $(DIR_APP) && tar xzf $(DIR_DL)/bluez-hcidump-1.42.tar.gz > - $(UPDATE_AUTOMAKE) > - cd $(DIR_APP) && ./configure --prefix=3D/usr \ > - --sysconfdir=3D/etc --localstatedir=3D/var --libexecdir=3D/lib > - cd $(DIR_APP) && make $(MAKETUNING) > - cd $(DIR_APP) && make install > - cd $(DIR_APP)/bluez-utils-$(VER) && ./configure --prefix=3D/usr \ > - --sysconfdir=3D/etc --localstatedir=3D/var --libexecdir=3D/lib \ > - --enable-alsa --enable-usb --enable-netlink --enable-tools \ > - --enable-bccmd --enable-hid2hci --enable-dfutool --enable-hidd \ > - --enable-pand --enable-dund --enable-cups --enable-test \ > - --enable-configfiles --enable-pcmciarules > - cd $(DIR_APP)/bluez-utils-$(VER) && make $(MAKETUNING) > - cd $(DIR_APP)/bluez-utils-$(VER) && make install > - cd $(DIR_APP)/bluez-utils-$(VER) && install -m 755 \ > - test/passkey-agent /usr/bin/passkey-agent > - cd $(DIR_APP)/bluez-firmware-1.2 && ./configure --libdir=3D/lib > - cd $(DIR_APP)/bluez-firmware-1.2 && make $(MAKETUNING) > - cd $(DIR_APP)/bluez-firmware-1.2 && make install > - cd $(DIR_APP)/bluez-hcidump-1.42 && ./configure --prefix=3D/usr \ > - --sysconfdir=3D/etc --localstatedir=3D/var --libexecdir=3D/lib > - cd $(DIR_APP)/bluez-hcidump-1.42 && make $(MAKETUNING) > - cd $(DIR_APP)/bluez-hcidump-1.42 && make install > - mv -f /etc/udev/bluetooth.rules /lib/udev/rules.d/24-bluetooth.rules > - # Patch udev rules for new udev version > - sed -i -e "s/SYSFS{/ATTRS{/g" /lib/udev/rules.d/24-bluetooth.rules > - sed -i -e "s/BUS=3D=3D/SUBSYSTEMS=3D=3D/g" /lib/udev/rules.d/24-bluetooth= .rules > - # Change bluetooth peername to Hostname-devicenumber > - sed -i -e 's|name "BlueZ (%d)";|name "%h-%d";|g' /etc/bluetooth/hcid.conf > - # Create empty config files > - echo '# Bluetooth audio configuration' > /etc/bluetooth/audio.conf > - echo '# Bluetooth main configuration' > /etc/bluetooth/main.conf > - echo '# Bluetooth input configuration' > /etc/bluetooth/input.conf > - echo '# Bluetooth network configuration' > /etc/bluetooth/network.conf > - echo '# Bluetooth rfcomm configuration' > /etc/bluetooth/rfcomm.conf > - mkdir -p /var/ipfire/bluetooth > - touch /var/ipfire/bluetooth/settings > - chown nobody:nobody /var/ipfire/bluetooth/settings > - chmod 644 /var/ipfire/bluetooth/settings > - install -v -m 644 $(DIR_SRC)/config/backup/includes/bluetooth /var/ipfire= /backup/addons/includes/bluetooth > - > - #install initscripts > - $(call INSTALL_INITSCRIPT,bluetooth) > - > - @rm -rf $(DIR_SRC)/bluez* > - @$(POSTBUILD) > diff --git a/lfs/cups b/lfs/cups > index dfa41188c..2a564ccaa 100644 > --- a/lfs/cups > +++ b/lfs/cups > @@ -1,7 +1,7 @@ > ###########################################################################= #### > # = # > # IPFire.org - A linux based firewall = # > -# Copyright (C) 2007-2018 IPFire Team <info(a)ipfire.org> = # > +# Copyright (C) 2007-2020 IPFire Team <info(a)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 = # > @@ -32,9 +32,9 @@ DL_FROM =3D $(URL_IPFIRE) > DIR_APP =3D $(DIR_SRC)/cups-$(VER) > TARGET =3D $(DIR_INFO)/$(THISAPP) > PROG =3D cups > -PAK_VER =3D 18 > +PAK_VER =3D 19 >=20 > -DEPS =3D "avahi bluetooth cups-filters dbus ghostscript krb5 libtiff" > +DEPS =3D "avahi cups-filters dbus ghostscript krb5 libtiff" >=20 > ###########################################################################= #### > # Top-level Rules > diff --git a/lfs/initscripts b/lfs/initscripts > index 3a769bd99..173a0b142 100644 > --- a/lfs/initscripts > +++ b/lfs/initscripts > @@ -1,7 +1,7 @@ > ###########################################################################= #### > # = # > # IPFire.org - A linux based firewall = # > -# Copyright (C) 2007-2018 IPFire Team <info(a)ipfire.org> = # > +# Copyright (C) 2007-2020 IPFire Team <info(a)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 = # > @@ -102,9 +102,6 @@ $(TARGET) : > ln -sf ../init.d/messagebus /etc/rc.d/rc3.d/S15messagebus > ln -sf ../init.d/messagebus /etc/rc.d/rc0.d/K85messagebus > ln -sf ../init.d/messagebus /etc/rc.d/rc6.d/K85messagebus > - ln -sf ../init.d/bluetooth /etc/rc.d/rc3.d/S16bluetooth > - ln -sf ../init.d/bluetooth /etc/rc.d/rc0.d/K84bluetooth > - ln -sf ../init.d/bluetooth /etc/rc.d/rc6.d/K84bluetooth > ln -sf ../init.d/cpufreq /etc/rc.d/rc3.d/S18cpufreq > ln -sf ../init.d/sysklogd /etc/rc.d/rc6.d/K90sysklogd > ln -sf ../init.d/sendsignals /etc/rc.d/rc6.d/S60sendsignals > diff --git a/make.sh b/make.sh > index 984fc95b2..72603f2cd 100755 > --- a/make.sh > +++ b/make.sh > @@ -1498,7 +1498,6 @@ buildipfire() { > lfsmake2 syslinux > lfsmake2 tftpd > lfsmake2 cpufrequtils > - lfsmake2 bluetooth > lfsmake2 gutenprint > lfsmake2 apcupsd > lfsmake2 iperf > --=20 > 2.17.1 >=20 --===============5485457045838234863==--