From 1f8aaf8a9104af92b86dac7ac0c1d5c4ad73a224 Mon Sep 17 00:00:00 2001 From: Andrii Pientsov Date: Thu, 21 May 2020 08:44:40 +0300 Subject: Remove duplicate --- recipes-connectivity/bluez/bluez5.inc | 159 ---- ...-obexd-without-systemd-in-the-user-sessio.patch | 63 -- ...-target-for-building-tests-without-runnin.patch | 28 - .../bluez/bluez5/CVE-2017-1000250.patch | 26 - recipes-connectivity/bluez/bluez5/bt-pan/bt-pan | 422 ----------- recipes-connectivity/bluez/bluez5/bt-pan/default | 2 - recipes-connectivity/bluez/bluez5/bt-pan/init | 40 - recipes-connectivity/bluez/bluez5/default | 8 - recipes-connectivity/bluez/bluez5/init | 72 -- recipes-connectivity/bluez/bluez5/main.conf | 108 --- .../bluez/bluez5/out-of-tree.patch | 26 - recipes-connectivity/bluez/bluez5/rfcomm/default | 2 - recipes-connectivity/bluez/bluez5/rfcomm/init | 39 - recipes-connectivity/bluez/bluez5/rfcomm/rfcomm.py | 650 ----------------- recipes-connectivity/bluez/bluez5/run-ptest | 31 - recipes-connectivity/bluez/bluez5_%.bbappend | 4 - recipes-connectivity/bluez/bluez5_5.47.bb | 55 -- .../bluez/python-gatt-server_1.0.bb | 24 - recipes-connectivity/c-ares/c-ares_1.10.0.bb | 13 - recipes-connectivity/lldpd/lldpd/lldpd.default | 3 - recipes-connectivity/lldpd/lldpd/lldpd.init.d | 129 ---- recipes-connectivity/lldpd/lldpd_%.bbappend | 1 - .../mosquitto/mosquitto/config_mk.patch | 27 - .../mosquitto/mosquitto/mosquitto.conf | 812 --------------------- .../mosquitto/mosquitto/mosquitto.default | 2 - .../mosquitto/mosquitto/mosquitto.init | 53 -- .../mosquitto/mosquitto/mosquitto.logrotate.conf | 7 - .../mosquitto/mosquitto/nostrip.patch | 58 -- recipes-connectivity/mosquitto/mosquitto_1.5.1.bb | 81 -- ...ial-signed-overflow-in-pointer-arithmatic.patch | 99 --- recipes-connectivity/openssh/openssh/init | 153 ---- ...penssh-8.1p1-add-test-support-for-busybox.patch | 48 -- ...h-8.1p1-conditional-compile-des-in-cipher.patch | 13 - ...h-8.1p1-conditional-compile-des-in-pkcs11.patch | 52 -- recipes-connectivity/openssh/openssh/run-ptest | 44 -- recipes-connectivity/openssh/openssh/ssh.default | 2 - recipes-connectivity/openssh/openssh/ssh_config | 48 -- recipes-connectivity/openssh/openssh/sshd | 11 - recipes-connectivity/openssh/openssh/sshd.socket | 10 - recipes-connectivity/openssh/openssh/sshd@.service | 13 - recipes-connectivity/openssh/openssh/sshd_config | 132 ---- .../openssh/openssh/sshdgenkeys.service | 22 - .../openssh/openssh/volatiles.99_sshd | 2 - recipes-connectivity/openssh/openssh_%.bbappend | 22 - recipes-connectivity/openssh/openssh_8.1p1.bb | 160 ---- recipes-connectivity/ppp/files/default | 8 - recipes-connectivity/ppp/files/init.patch | 34 - recipes-connectivity/ppp/files/poff.patch | 12 - recipes-connectivity/ppp/ppp_%.bbappend | 18 - .../usb-gadget-mode/files/usb-gadget | 69 -- .../usb-gadget-mode/files/usb-gadget.conf | 6 - .../usb-gadget-mode/files/usb-gadget.init | 21 - .../usb-gadget-mode/usb-gadget-mode.bb | 56 -- recipes-core/annex-client/annex-client-from-src.bb | 28 - recipes-core/annex-client/annex-client.bb | 53 -- .../annex-client/annex-client/annex-client.init | 43 -- recipes-core/annex-client/annex-client/call_home | 192 ----- .../annex-client/annex-client/call_home.init | 40 - .../annex-client/annex-client/config.json.sample | 10 - .../annex-client/annex-client/monitor-annexcd | 46 -- .../annex-client/push_api_mdm_connected | 59 -- .../annex-client/annex-client/push_api_mdm_status | 30 - recipes-core/annex-proto/annex-proto.bb | 24 - .../eglibc/cvs-gethostbyname4-memory-leak.patch | 576 --------------- recipes-core/eglibc/eglibc_%.bbappend.obsolete | 3 - .../file-magic-db-images_0.1.bb | 27 - recipes-core/file-magic-db-images/files/COPYING | 29 - .../file-magic-db-images/files/Magdir/images | 78 -- .../file-magic-db-images/files/Magdir/jpeg | 119 --- .../file-magic-db-images/files/Magdir/msdos | 29 - .../file-magic-db-images/files/Magdir/sgml | 8 - recipes-core/initscripts/initscripts-1.0/umountfs | 346 --------- recipes-core/initscripts/initscripts_1.0.bbappend | 6 - .../0001-usb.h-Include-sys-types.h.patch | 30 - recipes-core/libusb/libusb1/no-dll.patch | 19 - recipes-core/libusb/libusb1_1.0.21.bb | 35 - .../files/0001-lighttpd-pcre-use-pkg-config.patch | 41 -- .../lighttpd/files/0002_extended_tls_conf.patch | 110 --- .../files/0004_fastcgi_env_with_unixsocket.patch | 57 -- recipes-core/lighttpd/files/lighttpd.conf | 209 ------ recipes-core/lighttpd/files/lighttpd.init | 310 -------- .../lighttpd/files/lighttpd_custom_images_setup | 57 -- recipes-core/lighttpd/files/lighttpd_nrs.conf | 66 -- recipes-core/lighttpd/lighttpd_1.4.48.bb | 100 --- recipes-core/useradd/useradd.bb | 63 -- recipes-devtools/node-red/node-red_0.15.3.bb | 59 -- recipes-devtools/nodejs/nodejs_10.16.2.bb | 9 - recipes-devtools/nodejs/nodejs_10.4.0.bb | 9 - recipes-devtools/nodejs/nodejs_10.inc | 98 --- recipes-devtools/nodejs/nodejs_12.8.0.bb | 9 - recipes-devtools/nodejs/nodejs_12.inc | 98 --- ...eate-opkg.lock-in-run-lock-instead-of-run.patch | 12 - recipes-devtools/opkg/opkg_%.bbappend | 7 - recipes-devtools/php/files/init.d.php-rpm.patch | 36 - recipes-devtools/php/files/php-fpm.conf.patch | 30 - recipes-devtools/php/files/php-fpm.default | 2 - recipes-devtools/php/php_%.bbappend | 13 - .../multitech/helloworld-autotools_1.0.0.bb | 14 - recipes-extended/autossh/autossh_1.4c.bb | 22 - recipes-extended/fatrace/fatrace_0.9.bb | 20 - .../logrotate/act-as-mv-when-rotate.patch | 147 ---- .../disable-check-different-filesystems.patch | 32 - .../logrotate/logrotate/logrotate.conf | 36 - .../logrotate/logrotate/update-the-manual.patch | 38 - recipes-extended/logrotate/logrotate_%.bbappend | 20 - .../logrotate/logrotate_3.9.1-mlinux1.bb | 73 -- recipes-extended/mii-diag/mii-diag-2.11/libmii.c | 630 ---------------- recipes-extended/mii-diag/mii-diag-2.11/mii-diag.c | 648 ---------------- recipes-extended/mii-diag/mii-diag_2.11.bb | 25 - recipes-extended/monit/monit/monit.default | 2 - recipes-extended/monit/monit/monit.init | 37 - recipes-extended/monit/monit/monitrc | 272 ------- recipes-extended/monit/monit_5.22.0.bb | 51 -- recipes-extended/multitech/set-rs485/set-rs485.c | 81 -- recipes-extended/multitech/set-rs485_0.1.bb | 18 - recipes-extended/multitech/sms-utils.inc | 22 - recipes-extended/multitech/sms-utils_1.0.6.bb | 3 - .../multitech/venus-gps/fix_nmea_intervals.patch | 79 -- recipes-extended/multitech/venus-gps_0.1.0.bb | 16 - .../stressapptest/stressapptest_svn.bb | 13 - recipes-extended/sudo/files/sudo.pam | 6 - recipes-extended/sudo/sudo.inc | 52 -- ...1-Include-sys-types.h-for-id_t-definition.patch | 34 - recipes-extended/sudo/sudo/privacy | 1 - recipes-extended/sudo/sudo/sudoers.patch | 21 - recipes-extended/sudo/sudo_%.bbappend | 12 - recipes-extended/sudo/sudo_1.8.27.bb | 45 -- recipes-extended/uvccapture/files/makefile.patch | 29 - .../files/uvccapture_use_videodev2.patch | 24 - recipes-extended/uvccapture/uvccapture_0.5.bb | 15 - 130 files changed, 9763 deletions(-) delete mode 100644 recipes-connectivity/bluez/bluez5.inc delete mode 100644 recipes-connectivity/bluez/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch delete mode 100644 recipes-connectivity/bluez/bluez5/0001-tests-add-a-target-for-building-tests-without-runnin.patch delete mode 100644 recipes-connectivity/bluez/bluez5/CVE-2017-1000250.patch delete mode 100755 recipes-connectivity/bluez/bluez5/bt-pan/bt-pan delete mode 100755 recipes-connectivity/bluez/bluez5/bt-pan/default delete mode 100755 recipes-connectivity/bluez/bluez5/bt-pan/init delete mode 100644 recipes-connectivity/bluez/bluez5/default delete mode 100755 recipes-connectivity/bluez/bluez5/init delete mode 100644 recipes-connectivity/bluez/bluez5/main.conf delete mode 100644 recipes-connectivity/bluez/bluez5/out-of-tree.patch delete mode 100755 recipes-connectivity/bluez/bluez5/rfcomm/default delete mode 100755 recipes-connectivity/bluez/bluez5/rfcomm/init delete mode 100644 recipes-connectivity/bluez/bluez5/rfcomm/rfcomm.py delete mode 100644 recipes-connectivity/bluez/bluez5/run-ptest delete mode 100644 recipes-connectivity/bluez/bluez5_%.bbappend delete mode 100644 recipes-connectivity/bluez/bluez5_5.47.bb delete mode 100644 recipes-connectivity/bluez/python-gatt-server_1.0.bb delete mode 100644 recipes-connectivity/c-ares/c-ares_1.10.0.bb delete mode 100644 recipes-connectivity/lldpd/lldpd/lldpd.default delete mode 100644 recipes-connectivity/lldpd/lldpd/lldpd.init.d delete mode 100644 recipes-connectivity/lldpd/lldpd_%.bbappend delete mode 100644 recipes-connectivity/mosquitto/mosquitto/config_mk.patch delete mode 100644 recipes-connectivity/mosquitto/mosquitto/mosquitto.conf delete mode 100644 recipes-connectivity/mosquitto/mosquitto/mosquitto.default delete mode 100755 recipes-connectivity/mosquitto/mosquitto/mosquitto.init delete mode 100644 recipes-connectivity/mosquitto/mosquitto/mosquitto.logrotate.conf delete mode 100644 recipes-connectivity/mosquitto/mosquitto/nostrip.patch delete mode 100644 recipes-connectivity/mosquitto/mosquitto_1.5.1.bb delete mode 100644 recipes-connectivity/openssh/openssh/fix-potential-signed-overflow-in-pointer-arithmatic.patch delete mode 100644 recipes-connectivity/openssh/openssh/init delete mode 100644 recipes-connectivity/openssh/openssh/openssh-8.1p1-add-test-support-for-busybox.patch delete mode 100644 recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-cipher.patch delete mode 100644 recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-pkcs11.patch delete mode 100755 recipes-connectivity/openssh/openssh/run-ptest delete mode 100644 recipes-connectivity/openssh/openssh/ssh.default delete mode 100644 recipes-connectivity/openssh/openssh/ssh_config delete mode 100644 recipes-connectivity/openssh/openssh/sshd delete mode 100644 recipes-connectivity/openssh/openssh/sshd.socket delete mode 100644 recipes-connectivity/openssh/openssh/sshd@.service delete mode 100644 recipes-connectivity/openssh/openssh/sshd_config delete mode 100644 recipes-connectivity/openssh/openssh/sshdgenkeys.service delete mode 100644 recipes-connectivity/openssh/openssh/volatiles.99_sshd delete mode 100644 recipes-connectivity/openssh/openssh_%.bbappend delete mode 100644 recipes-connectivity/openssh/openssh_8.1p1.bb delete mode 100644 recipes-connectivity/ppp/files/default delete mode 100644 recipes-connectivity/ppp/files/init.patch delete mode 100644 recipes-connectivity/ppp/files/poff.patch delete mode 100644 recipes-connectivity/ppp/ppp_%.bbappend delete mode 100755 recipes-connectivity/usb-gadget-mode/files/usb-gadget delete mode 100644 recipes-connectivity/usb-gadget-mode/files/usb-gadget.conf delete mode 100755 recipes-connectivity/usb-gadget-mode/files/usb-gadget.init delete mode 100644 recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb delete mode 100644 recipes-core/annex-client/annex-client-from-src.bb delete mode 100644 recipes-core/annex-client/annex-client.bb delete mode 100644 recipes-core/annex-client/annex-client/annex-client.init delete mode 100755 recipes-core/annex-client/annex-client/call_home delete mode 100755 recipes-core/annex-client/annex-client/call_home.init delete mode 100644 recipes-core/annex-client/annex-client/config.json.sample delete mode 100755 recipes-core/annex-client/annex-client/monitor-annexcd delete mode 100755 recipes-core/annex-client/annex-client/push_api_mdm_connected delete mode 100755 recipes-core/annex-client/annex-client/push_api_mdm_status delete mode 100644 recipes-core/annex-proto/annex-proto.bb delete mode 100644 recipes-core/eglibc/eglibc/cvs-gethostbyname4-memory-leak.patch delete mode 100644 recipes-core/eglibc/eglibc_%.bbappend.obsolete delete mode 100644 recipes-core/file-magic-db-images/file-magic-db-images_0.1.bb delete mode 100644 recipes-core/file-magic-db-images/files/COPYING delete mode 100644 recipes-core/file-magic-db-images/files/Magdir/images delete mode 100644 recipes-core/file-magic-db-images/files/Magdir/jpeg delete mode 100644 recipes-core/file-magic-db-images/files/Magdir/msdos delete mode 100644 recipes-core/file-magic-db-images/files/Magdir/sgml delete mode 100644 recipes-core/initscripts/initscripts-1.0/umountfs delete mode 100644 recipes-core/initscripts/initscripts_1.0.bbappend delete mode 100644 recipes-core/libusb/libusb-compat/0001-usb.h-Include-sys-types.h.patch delete mode 100644 recipes-core/libusb/libusb1/no-dll.patch delete mode 100644 recipes-core/libusb/libusb1_1.0.21.bb delete mode 100644 recipes-core/lighttpd/files/0001-lighttpd-pcre-use-pkg-config.patch delete mode 100644 recipes-core/lighttpd/files/0002_extended_tls_conf.patch delete mode 100644 recipes-core/lighttpd/files/0004_fastcgi_env_with_unixsocket.patch delete mode 100644 recipes-core/lighttpd/files/lighttpd.conf delete mode 100644 recipes-core/lighttpd/files/lighttpd.init delete mode 100644 recipes-core/lighttpd/files/lighttpd_custom_images_setup delete mode 100644 recipes-core/lighttpd/files/lighttpd_nrs.conf delete mode 100644 recipes-core/lighttpd/lighttpd_1.4.48.bb delete mode 100644 recipes-core/useradd/useradd.bb delete mode 100644 recipes-devtools/node-red/node-red_0.15.3.bb delete mode 100644 recipes-devtools/nodejs/nodejs_10.16.2.bb delete mode 100644 recipes-devtools/nodejs/nodejs_10.4.0.bb delete mode 100644 recipes-devtools/nodejs/nodejs_10.inc delete mode 100644 recipes-devtools/nodejs/nodejs_12.8.0.bb delete mode 100644 recipes-devtools/nodejs/nodejs_12.inc delete mode 100644 recipes-devtools/opkg/files/0003-opkg_conf-create-opkg.lock-in-run-lock-instead-of-run.patch delete mode 100644 recipes-devtools/opkg/opkg_%.bbappend delete mode 100644 recipes-devtools/php/files/init.d.php-rpm.patch delete mode 100644 recipes-devtools/php/files/php-fpm.conf.patch delete mode 100644 recipes-devtools/php/files/php-fpm.default delete mode 100644 recipes-devtools/php/php_%.bbappend delete mode 100644 recipes-examples/multitech/helloworld-autotools_1.0.0.bb delete mode 100644 recipes-extended/autossh/autossh_1.4c.bb delete mode 100644 recipes-extended/fatrace/fatrace_0.9.bb delete mode 100644 recipes-extended/logrotate/logrotate/act-as-mv-when-rotate.patch delete mode 100644 recipes-extended/logrotate/logrotate/disable-check-different-filesystems.patch delete mode 100644 recipes-extended/logrotate/logrotate/logrotate.conf delete mode 100644 recipes-extended/logrotate/logrotate/update-the-manual.patch delete mode 100644 recipes-extended/logrotate/logrotate_%.bbappend delete mode 100644 recipes-extended/logrotate/logrotate_3.9.1-mlinux1.bb delete mode 100644 recipes-extended/mii-diag/mii-diag-2.11/libmii.c delete mode 100644 recipes-extended/mii-diag/mii-diag-2.11/mii-diag.c delete mode 100644 recipes-extended/mii-diag/mii-diag_2.11.bb delete mode 100644 recipes-extended/monit/monit/monit.default delete mode 100755 recipes-extended/monit/monit/monit.init delete mode 100644 recipes-extended/monit/monit/monitrc delete mode 100644 recipes-extended/monit/monit_5.22.0.bb delete mode 100644 recipes-extended/multitech/set-rs485/set-rs485.c delete mode 100644 recipes-extended/multitech/set-rs485_0.1.bb delete mode 100644 recipes-extended/multitech/sms-utils.inc delete mode 100644 recipes-extended/multitech/sms-utils_1.0.6.bb delete mode 100644 recipes-extended/multitech/venus-gps/fix_nmea_intervals.patch delete mode 100644 recipes-extended/multitech/venus-gps_0.1.0.bb delete mode 100644 recipes-extended/stressapptest/stressapptest_svn.bb delete mode 100644 recipes-extended/sudo/files/sudo.pam delete mode 100644 recipes-extended/sudo/sudo.inc delete mode 100644 recipes-extended/sudo/sudo/0001-Include-sys-types.h-for-id_t-definition.patch delete mode 100644 recipes-extended/sudo/sudo/privacy delete mode 100644 recipes-extended/sudo/sudo/sudoers.patch delete mode 100644 recipes-extended/sudo/sudo_%.bbappend delete mode 100644 recipes-extended/sudo/sudo_1.8.27.bb delete mode 100644 recipes-extended/uvccapture/files/makefile.patch delete mode 100644 recipes-extended/uvccapture/files/uvccapture_use_videodev2.patch delete mode 100644 recipes-extended/uvccapture/uvccapture_0.5.bb diff --git a/recipes-connectivity/bluez/bluez5.inc b/recipes-connectivity/bluez/bluez5.inc deleted file mode 100644 index 35ebd0c..0000000 --- a/recipes-connectivity/bluez/bluez5.inc +++ /dev/null @@ -1,159 +0,0 @@ -SUMMARY = "Linux Bluetooth Stack Userland V5" -PR = "m4" -DESCRIPTION = "Linux Bluetooth stack V5 userland components. These include a system configurations, daemons, tools and system libraries." -HOMEPAGE = "http://www.bluez.org" -SECTION = "libs" -LICENSE = "GPLv2+ & LGPLv2.1+" -LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ - file://COPYING.LIB;md5=fb504b67c50331fc78734fed90fb0e09 \ - file://src/main.c;beginline=1;endline=24;md5=9bc54b93cd7e17bf03f52513f39f926e" -DEPENDS = "udev libusb dbus-glib glib-2.0 libcheck readline" -RDEPENDS_${PN}-pand += "bash python-dbus python-logging python-syslog python-subprocess python-argparse" -RDEPENDS_${PN}-rfcomm += "bash python-pygobject python-syslog python-logging python-dbus" -PROVIDES += "bluez-hcidump" -RPROVIDES_${PN} += "bluez-hcidump" - -RCONFLICTS_${PN} = "bluez4" - -PACKAGECONFIG ??= "obex-profiles" -PACKAGECONFIG[obex-profiles] = "--enable-obex,--disable-obex,libical" -PACKAGECONFIG[experimental] = "--enable-experimental,--enable-experimental" - -SRC_URI = "\ - ${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \ - file://out-of-tree.patch \ - file://init \ - file://run-ptest \ - ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'file://0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch', d)} \ - file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \ - file://default \ - file://main.conf \ - file://bt-pan/init \ - file://bt-pan/default \ - file://bt-pan/bt-pan \ - file://rfcomm/rfcomm.py \ - file://rfcomm/init \ - file://rfcomm/default \ -" -S = "${WORKDIR}/bluez-${PV}" - -inherit autotools pkgconfig systemd update-rc.d distro_features_check ptest - -EXTRA_OECONF = "\ - --enable-tools \ - --disable-cups \ - --enable-test \ - --enable-datafiles \ - ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '--enable-systemd', '--disable-systemd', d)} \ - --enable-library \ - --enable-deprecated \ - --enable-experimental \ -" - -# bluez5 builds a large number of useful utilities but does not -# install them. Specify which ones we want put into ${PN}-noinst-tools. -NOINST_TOOLS_READLINE ??= "" -NOINST_TOOLS_EXPERIMENTAL ??= "" -NOINST_TOOLS = " \ - ${NOINST_TOOLS_READLINE} \ - ${@bb.utils.contains('PACKAGECONFIG', 'experimental', '${NOINST_TOOLS_EXPERIMENTAL}', '', d)} \ -" - -DBTEXEC = "${D}${libexecdir}/bluetooth/" - -do_install_append() { - install -d ${D}${INIT_D_DIR} - install -m 0755 ${WORKDIR}/init ${D}${INIT_D_DIR}/bluetooth - install -m 0755 ${WORKDIR}/bt-pan/init ${D}${INIT_D_DIR}/bt-pan - install -m 0755 ${WORKDIR}/rfcomm/init ${D}${INIT_D_DIR}/rfcomm - install -d ${DBTEXEC} - install -m 0755 ${WORKDIR}/bt-pan/bt-pan ${DBTEXEC} - install -m 0755 ${WORKDIR}/rfcomm/rfcomm.py ${DBTEXEC}/rfcomm - - install -d ${D}${sysconfdir}/bluetooth/ - if [ -f ${S}/profiles/audio/audio.conf ]; then - install -m 0644 ${S}/profiles/audio/audio.conf ${D}/${sysconfdir}/bluetooth/ - fi - if [ -f ${S}/profiles/network/network.conf ]; then - install -m 0644 ${S}/profiles/network/network.conf ${D}/${sysconfdir}/bluetooth/ - fi - if [ -f ${S}/profiles/input/input.conf ]; then - install -m 0644 ${S}/profiles/input/input.conf ${D}/${sysconfdir}/bluetooth/ - fi - - if [ -f ${D}/${sysconfdir}/init.d/bluetooth ]; then - sed -i -e 's#@LIBEXECDIR@#${libexecdir}#g' ${D}/${sysconfdir}/init.d/bluetooth - fi - - # Install desired tools that upstream leaves in build area - for f in ${NOINST_TOOLS} ; do - install -m 755 ${B}/$f ${D}/${bindir} - done - - # Patch python tools to use Python 3; they should be source compatible, but - # still refer to Python 2 in the shebang - sed -i -e '1s,#!.*python.*,#!${bindir}/python3,' ${D}${libdir}/bluez/test/* - - install -d ${D}${sysconfdir}/default - install -m 0644 ${WORKDIR}/default ${D}${sysconfdir}/default/bluetooth - install -m 0644 ${WORKDIR}/bt-pan/default ${D}${sysconfdir}/default/bt-pan - install -m 0644 ${WORKDIR}/rfcomm/default ${D}${sysconfdir}/default/rfcomm - install -m 0644 ${WORKDIR}/main.conf ${D}${sysconfdir}/bluetooth/ -} - -ALLOW_EMPTY_libasound-module-bluez = "1" -PACKAGES =+ "libasound-module-bluez ${PN}-testtools ${PN}-obex ${PN}-noinst-tools ${PN}-pand ${PN}-rfcomm" - -FILES_libasound-module-bluez = "${libdir}/alsa-lib/lib*.so ${datadir}/alsa" -FILES_${PN} += "${libdir}/bluetooth/plugins/*.so ${systemd_unitdir}/ ${datadir}/dbus-1" -CONFFILES_${PN} += "${sysconfdir}/default/bluetooth ${sysconfdir}/bluetooth/main.conf ${sysconfdir}/bluetooth/input.conf ${sysconfdir}/bluetooth/network.conf" -FILES_${PN}-dev += "\ - ${libdir}/bluetooth/plugins/*.la \ - ${libdir}/alsa-lib/*.la \ -" - -FILES_${PN}-obex = "${libexecdir}/bluetooth/obexd \ - ${exec_prefix}/lib/systemd/user/obex.service \ - ${datadir}/dbus-1/services/org.bluez.obex.service \ - " - -FILES_${PN}-pand = "${libexecdir}/bluetooth/bt-pan ${sysconfdir}/default/bt-pan ${sysconfdir}/init.d/bt-pan" -FILES_${PN}-rfcomm = "${libexecdir}/bluetooth/bt-pan ${sysconfdir}/default/bt-pan ${sysconfdir}/init.d/bt-pan" -FILES_${PN}-rfcomm = "${libexecdir}/bluetooth/rfcomm ${sysconfdir}/default/rfcomm ${sysconfdir}/init.d/rfcomm" -CONFFILES_${PN}-pand = "${sysconfdir}/default/bt-pan" -CONFFILES_${PN}-rfcomm = "${sysconfdir}/default/rfcomm" -SYSTEMD_SERVICE_${PN}-obex = "obex.service" - -FILES_${PN}-testtools = "${libdir}/bluez/test/*" - -def get_noinst_tools_paths (d, bb, tools): - s = list() - bindir = d.getVar("bindir", True) - for bdp in tools.split(): - f = os.path.basename(bdp) - s.append("%s/%s" % (bindir, f)) - return "\n".join(s) - -FILES_${PN}-noinst-tools = "${@get_noinst_tools_paths(d, bb, d.getVar('NOINST_TOOLS', True))}" - -RDEPENDS_${PN}-testtools += "python3 python3-dbus python3-pygobject" - -SYSTEMD_SERVICE_${PN} = "bluetooth.service" -INITSCRIPT_PACKAGES = "${PN} ${PN}-pand ${PN}-rfcomm" -INITSCRIPT_NAME_${PN} = "bluetooth" -INITSCRIPT_NAME_${PN}-pand = "bt-pan" -INITSCRIPT_NAME_${PN}-rfcomm = "rfcomm" -INITSCRIPT_PARAMS_${PN} = "defaults 20 20" -INITSCRIPT_PARAMS_${PN}-pand = "defaults 22 22" -INITSCRIPT_PARAMS_${PN}-rfcomm = "defaults 22 22" - -EXCLUDE_FROM_WORLD = "1" - -do_compile_ptest() { - oe_runmake buildtests -} - -do_install_ptest() { - cp -r ${B}/unit/ ${D}${PTEST_PATH} - rm -f ${D}${PTEST_PATH}/unit/*.o -} diff --git a/recipes-connectivity/bluez/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch b/recipes-connectivity/bluez/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch deleted file mode 100644 index 2fde7bc..0000000 --- a/recipes-connectivity/bluez/bluez5/0001-Allow-using-obexd-without-systemd-in-the-user-sessio.patch +++ /dev/null @@ -1,63 +0,0 @@ -From: Giovanni Campagna -Date: Sat, 12 Oct 2013 17:45:25 +0200 -Subject: [PATCH] Allow using obexd without systemd in the user session - -Not all sessions run systemd --user (actually, the majority -doesn't), so the dbus daemon must be able to spawn obexd -directly, and to do so it needs the full path of the daemon. - -Upstream-Status: Denied - -Not accepted by upstream maintainer for being a distro specific -configuration. See thread: - -http://thread.gmane.org/gmane.linux.bluez.kernel/38725/focus=38843 - -Signed-off-by: Javier Viguera ---- - Makefile.obexd | 4 ++-- - obexd/src/org.bluez.obex.service | 4 ---- - obexd/src/org.bluez.obex.service.in | 4 ++++ - 3 files changed, 6 insertions(+), 6 deletions(-) - delete mode 100644 obexd/src/org.bluez.obex.service - create mode 100644 obexd/src/org.bluez.obex.service.in - -diff --git a/Makefile.obexd b/Makefile.obexd -index 2e33cbc72f2b..d5d858c857b4 100644 ---- a/Makefile.obexd -+++ b/Makefile.obexd -@@ -2,12 +2,12 @@ - if SYSTEMD - systemduserunitdir = @SYSTEMD_USERUNITDIR@ - systemduserunit_DATA = obexd/src/obex.service -+endif - - dbussessionbusdir = @DBUS_SESSIONBUSDIR@ - dbussessionbus_DATA = obexd/src/org.bluez.obex.service --endif - --EXTRA_DIST += obexd/src/obex.service.in obexd/src/org.bluez.obex.service -+EXTRA_DIST += obexd/src/obex.service.in obexd/src/org.bluez.obex.service.in - - obex_plugindir = $(libdir)/obex/plugins - -diff --git a/obexd/src/org.bluez.obex.service b/obexd/src/org.bluez.obex.service -deleted file mode 100644 -index a53808884554..000000000000 ---- a/obexd/src/org.bluez.obex.service -+++ /dev/null -@@ -1,4 +0,0 @@ --[D-BUS Service] --Name=org.bluez.obex --Exec=/bin/false --SystemdService=dbus-org.bluez.obex.service -diff --git a/obexd/src/org.bluez.obex.service.in b/obexd/src/org.bluez.obex.service.in -new file mode 100644 -index 000000000000..9c815f246b77 ---- /dev/null -+++ b/obexd/src/org.bluez.obex.service.in -@@ -0,0 +1,4 @@ -+[D-BUS Service] -+Name=org.bluez.obex -+Exec=@libexecdir@/obexd -+SystemdService=dbus-org.bluez.obex.service diff --git a/recipes-connectivity/bluez/bluez5/0001-tests-add-a-target-for-building-tests-without-runnin.patch b/recipes-connectivity/bluez/bluez5/0001-tests-add-a-target-for-building-tests-without-runnin.patch deleted file mode 100644 index 24ddae6..0000000 --- a/recipes-connectivity/bluez/bluez5/0001-tests-add-a-target-for-building-tests-without-runnin.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 4bdf0f96dcaa945fd29f26d56e5b36d8c23e4c8b Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin -Date: Fri, 1 Apr 2016 17:07:34 +0300 -Subject: [PATCH] tests: add a target for building tests without running them - -Upstream-Status: Inappropriate [oe specific] -Signed-off-by: Alexander Kanavin ---- - Makefile.am | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/Makefile.am b/Makefile.am -index 1a48a71..ba3b92f 100644 ---- a/Makefile.am -+++ b/Makefile.am -@@ -425,6 +425,9 @@ endif - TESTS = $(unit_tests) - AM_TESTS_ENVIRONMENT = MALLOC_CHECK_=3 MALLOC_PERTURB_=69 - -+# This allows building tests without running them -+buildtests: $(TESTS) -+ - if DBUS_RUN_SESSION - AM_TESTS_ENVIRONMENT += dbus-run-session -- - endif --- -2.8.0.rc3 - diff --git a/recipes-connectivity/bluez/bluez5/CVE-2017-1000250.patch b/recipes-connectivity/bluez/bluez5/CVE-2017-1000250.patch deleted file mode 100644 index 05359da..0000000 --- a/recipes-connectivity/bluez/bluez5/CVE-2017-1000250.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 9e009647b14e810e06626dde7f1bb9ea3c375d09 Mon Sep 17 00:00:00 2001 -From: Luiz Augusto von Dentz -Date: Wed, 13 Sep 2017 10:01:40 +0300 -Subject: sdp: Fix Out-of-bounds heap read in service_search_attr_req function - -Check if there is enough data to continue otherwise return an error. ---- - src/sdpd-request.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/sdpd-request.c b/src/sdpd-request.c -index 1eefdce..318d044 100644 ---- a/src/sdpd-request.c -+++ b/src/sdpd-request.c -@@ -917,7 +917,7 @@ static int service_search_attr_req(sdp_req_t *req, sdp_buf_t *buf) - } else { - /* continuation State exists -> get from cache */ - sdp_buf_t *pCache = sdp_get_cached_rsp(cstate); -- if (pCache) { -+ if (pCache && cstate->cStateValue.maxBytesSent < pCache->data_size) { - uint16_t sent = MIN(max, pCache->data_size - cstate->cStateValue.maxBytesSent); - pResponse = pCache->data; - memcpy(buf->data, pResponse + cstate->cStateValue.maxBytesSent, sent); --- -cgit v1.1 - diff --git a/recipes-connectivity/bluez/bluez5/bt-pan/bt-pan b/recipes-connectivity/bluez/bluez5/bt-pan/bt-pan deleted file mode 100755 index f142bb1..0000000 --- a/recipes-connectivity/bluez/bluez5/bt-pan/bt-pan +++ /dev/null @@ -1,422 +0,0 @@ -#!/usr/bin/env python2 -from __future__ import absolute_import, print_function - -import os, sys, time, types, subprocess, signal - -import dbus -import logging -import logging.handlers - -# cgitb is in python-misc and requires python-pkgutil and python-pydoc -# It is very usefull for analyzing exceptions. -# import cgitb - -# who am i -myscript = os.path.basename(__file__) - -# Log formating class -class flog: - # priority strings to be used - # with the __init__ function - priorities = { - 'debug': logging.DEBUG, - 'info': logging.INFO, - 'warn': logging.WARNING, - 'warning': logging.WARNING, - 'error': logging.ERROR, - 'critical': logging.CRITICAL, - } - - def __init__(self,myscript,facility,priority): - """ - Initialize for logging - - :param myscript: The name of the python program script - :param facility: The syslog facility, such as daemon or user - :param priority: The minimum priority to be printed to the log - :returns: Nothing - :raises TBD: logging class errors. - """ - name_len = str(len(myscript)) - self.myscript = myscript - self.log = logging.getLogger(myscript) - self.handler = logging.handlers.SysLogHandler(address=('/dev/log'),facility=facility) - self.default_fmt = ' %(levelname)-9s %(name)-' + name_len + 's %(message)s' - self.verbose_fmt1 = ' %(levelname)-9s %(name)-' + name_len + 's %(threadName)-14s ' - self.verbose_fmt2 = ' %(message)s' - formatter = logging.Formatter(self.default_fmt) - self.handler.setFormatter(formatter) - self.log.setLevel(self.priorities[priority]) # Minimum infolevel to log - self.log.addHandler(self.handler) - self.handler.createLock() - - def __default(self,func,*args): - self.handler.acquire() - formatter = logging.Formatter(self.default_fmt) - self.handler.setFormatter(formatter) - func(*args) - self.handler.release() - - def setThreshold(self,threshold): - """ - Change the syslog priority threshold - - :param priority: Character string corresponding to the threshold - """ - self.handler.acquire() - self.log.setLevel(self.priorities[threshold]) # Minimum infolevel to log - self.handler.release() - - def critical(self,*args): - """ - Prints a variable argument list at critical priority - - :returns: logging result - """ - self.__default(self.log.critical,*args) - - def error(self,*args): - """ - Prints a variable argument list at error priority - - :returns: logging result - """ - self.__default(self.log.error,*args) - - def warning(self,*args): - """ - Prints a variable argument list at warning priority - - :returns: logging result - """ - self.__default(self.log.warning,*args) - - # Python has no notice level! - - def info(self,*args): - """ - Prints a variable argument list at info priority - - :returns: logging result - """ - self.__default(self.log.info,*args) - - def debug(self,*args): - """ - Prints a variable argument list at debug priority - - Printing debug includes function name and line - number. - - :returns: logging result - """ - caller_frame = sys._getframe().f_back - callerfunc = caller_frame.f_code.co_name + '@' + str(caller_frame.f_lineno); - callerfunc = callerfunc.ljust(16) - self.handler.acquire() - log = logging.getLogger(self.myscript) - formatter = logging.Formatter(self.verbose_fmt1+callerfunc+self.verbose_fmt2) - self.handler.setFormatter(formatter) - log.debug(*args) - self.handler.release() - -# End of log handler - -### ~bluezutils.py - -iface_base = 'org.bluez' -iface_dev = '{}.Device1'.format(iface_base) -iface_adapter = '{}.Adapter1'.format(iface_base) -iface_props = 'org.freedesktop.DBus.Properties' -global lg - -# Will this write to syslog????? -class BTError(Exception): pass - -def get_bus(): - bus = getattr(get_bus, 'cached_obj', None) - if not bus: bus = get_bus.cached_obj = dbus.SystemBus() - return bus - -def get_manager(): - manager = getattr(get_manager, 'cached_obj', None) - if not manager: - try: - manager = get_manager.cached_obj = dbus.Interface( - get_bus().get_object(iface_base, '/'), - 'org.freedesktop.DBus.ObjectManager' ) - except dbus.exceptions.DBusException as e: - s="" - try: - s = e.__dict__["_dbus_error_name"] - except KeyError: - pass - unk = 'org.freedesktop.DBus.Error.ServiceUnknown' - cexit = 'org.freedesktop.DBus.Error.Spawn.ChildExited' - if (s == unk) or (s == cexit): - msg = 'Is bluetoothd running? Bluetooth tree missing from DBUS' - lg.error(msg) - print(msg) - exit(1) - else: - raise - return manager - -def prop_get(obj, k, iface=None): - if iface is None: iface = obj.dbus_interface - return obj.Get(iface, k, dbus_interface=iface_props) -def prop_set(obj, k, v, iface=None): - if iface is None: iface = obj.dbus_interface - return obj.Set(iface, k, v, dbus_interface=iface_props) - -msg='' -def find_adapter(pattern=None): - try: - adapter = find_adapter_in_objects(get_manager().GetManagedObjects(), pattern) - - # DBusException - # Original code: - # template = "An exception of type {0} occurred. Arguments:\n{1!r}" - # message = template.format(type(ex).__name__, ex.args) - # print message - # dbus.exceptions.DBusException: - # org.freedesktop.DBus.Error.AccessDenied: - except dbus.exceptions.DBusException as e: - s="" - try: - s = e.__dict__["_dbus_error_name"] - except KeyError: - pass - - if "org.freedesktop.DBus.Error.AccessDenied" == s: - rot="You do not have sufficient privilege to run bt-pan" - print(rot) - lg.error(rot) - exit(1) - else: - raise - return adapter - -def find_adapter_in_objects(objects, pattern=None): - bus, obj = get_bus(), None - for path, ifaces in objects.iteritems(): - adapter = ifaces.get(iface_adapter) - if adapter is None: continue - if not pattern or pattern == adapter['Address'] or path.endswith(pattern): - obj = bus.get_object(iface_base, path) - yield dbus.Interface(obj, iface_adapter) - if obj is None: - msg = 'Bluetooth adapter not found' - lg.error(msg) - raise BTError(msg) - -def find_device(device_address, adapter_pattern=None): - return find_device_in_objects(get_manager().GetManagedObjects(), device_address, adapter_pattern) - -def find_device_in_objects(objects, device_address, adapter_pattern=None): - bus = get_bus() - path_prefix = '' - if adapter_pattern: - if not isinstance(adapter_pattern, types.StringTypes): adapter = adapter_pattern - else: adapter = find_adapter_in_objects(objects, adapter_pattern) - path_prefix = adapter.object_path - for path, ifaces in objects.iteritems(): - device = ifaces.get(iface_dev) - if device is None: continue - if device['Address'] == device_address and path.startswith(path_prefix): - obj = bus.get_object(iface_base, path) - return dbus.Interface(obj, iface_dev) - msg = 'Bluetooth device not found' - lg.error(msg) - raise BTError(msg) - -pidPath = "" - -def writePidFile(device): - global pidPath - pid = str(os.getpid()) - pidPath = '/run/bt-pan.' + device + '.pid' - f = open(pidPath, 'w') - f.write(pid) - f.close() - -def hexdump(string): - return ":".join("{:02x}".format(ord(c)) for c in string) - -### bt-pan - -def main(args=None): - import argparse - global lg - - # Set up logging initially info and above - lg = flog(myscript,'daemon','info') - - # cgitb.enable(format='text') - - parser = argparse.ArgumentParser( - description='BlueZ bluetooth PAN network server/client.') - - parser.add_argument('-i', '--device', metavar='local-addr/pattern', - help='Local device address/pattern to use (if not default).') - parser.add_argument('-a', '--device-all', action='store_true', - help='Use all local hci devices, not just default one.' - ' Only valid with "server" mode, mutually exclusive with --device option.') - parser.add_argument('-u', '--uuid', - metavar='uuid_or_shortcut', default='nap', - help='Service UUID to use. Can be either full UUID' - ' or one of the shortcuts: gn, panu, nap. Default: %(default)s.') - parser.add_argument('--systemd', action='store_true', - help='Use systemd service' - ' notification/watchdog mechanisms in daemon modes, if available.') - parser.add_argument('--debug', - action='store_true', help='Verbose operation mode.') - - cmds = parser.add_subparsers( dest='call', - title='Supported operations (have their own suboptions as well)' ) - - cmd = cmds.add_parser('server', help='Run infinitely as a NAP network server.') - cmd.add_argument('iface_name', - help='Bridge interface name to which each link will be added by bluez.' - ' It must be created and configured before starting the server.') - - cmd = cmds.add_parser('client', help='Connect to a PAN network.') - cmd.add_argument('remote_addr', help='Remote device address to connect to.') - cmd.add_argument('-d', '--disconnect', action='store_true', - help='Instead of connecting (default action), disconnect' - ' (if connected) and exit. Overrides all other options for this command.') - cmd.add_argument('-w', '--wait', action='store_true', - help='Go into an endless wait-loop after connection, terminating it on exit.') - cmd.add_argument('-c', '--if-not-connected', action='store_true', - help='Dont raise error if connection is already established.') - cmd.add_argument('-r', '--reconnect', action='store_true', - help='Force reconnection if some connection is already established.') - - opts = parser.parse_args() - - if opts.debug: - lg.setThreshold('debug') - - if not opts.device_all: devs = [next(iter(find_adapter(opts.device)))] - else: - if opts.call != 'server': - parser.error('--device-all option is only valid with "server" mode.') - devs = list(find_adapter()) - devs = dict((prop_get(dev, 'Address'), dev) for dev in devs) - for dev_addr, dev in devs.viewitems(): - prop_set(dev, 'Powered', True) - lg.debug('Using local device (addr: %s): %s', dev_addr, dev.object_path) - - wait_iter_noop = 3600 - if opts.systemd: - from systemd import daemon - def wait_iter(): - if not wait_iter.sd_ready: - daemon.notify('READY=1') - daemon.notify('STATUS=Running in {} mode...'.format(opts.call)) - wait_iter.sd_ready = True - time.sleep(wait_iter.timeout) - if wait_iter.sd_wdt: daemon.notify('WATCHDOG=1') - wd_pid, wd_usec = (os.environ.get(k) for k in ['WATCHDOG_PID', 'WATCHDOG_USEC']) - if wd_pid and wd_pid.isdigit() and int(wd_pid) == os.getpid(): - wd_interval = float(wd_usec) / 2e6 # half of interval in seconds - assert wd_interval > 0, wd_interval - else: wd_interval = None - if wd_interval: - lg.debug('Initializing systemd watchdog pinger with interval: %ss', wd_interval) - wait_iter.sd_wdt, wait_iter.timeout = True, min(wd_interval, wait_iter_noop) - else: wait_iter.sd_wdt, wait_iter.timeout = False, wait_iter_noop - wait_iter.sd_ready = False - else: wait_iter = lambda: time.sleep(wait_iter_noop) - signal.signal(signal.SIGTERM, lambda sig,frm: sys.exit(0)) - - - if opts.call == 'server': - inm = opts.iface_name - brctl = subprocess.Popen( - ['brctl', 'show', inm], - stdout=open(os.devnull, 'wb'), stderr=subprocess.PIPE ) - brctl_stderr = brctl.stderr.read() - writePidFile(opts.iface_name) - if brctl.wait() or brctl_stderr: - lg.error('brctl check failed for interface (missing?): {}'.format(inm)) - lg.error('Bridge interface must be added and configured before starting server, e.g. with:') - lg.error(' brctl addbr {}'.format(inm)) - lg.error(' brctl setfd {} 0'.format(inm)) - lg.error(' brctl stp {} off'.format(inm)) - lg.error(' ip addr add 10.101.225.84/24 dev {}'.format(inm)) - lg.error(' ip link set {} up'.format(inm)) - return 1 - - servers = list() - try: - for dev_addr, dev in devs.viewitems(): - server = dbus.Interface(dev, 'org.bluez.NetworkServer1') - server.Unregister(opts.uuid) # in case already registered - server.Register(opts.uuid, opts.iface_name) - servers.append(server) - lg.debug( 'Registered uuid %r with' - ' bridge/dev: %s / %s', opts.uuid, opts.iface_name, dev_addr ) - while True: wait_iter() - except KeyboardInterrupt: pass - finally: - if servers: - for server in servers: server.Unregister(opts.uuid) - lg.debug('Unregistered server uuids') - - - elif opts.call == 'client': - dev_remote = find_device(opts.remote_addr, devs.values()[0]) - lg.debug( 'Using remote device (addr: %s): %s', - prop_get(dev_remote, 'Address'), dev_remote.object_path ) - try: dev_remote.ConnectProfile(opts.uuid) - except: pass # no idea why it fails sometimes, but still creates dbus interface - net = dbus.Interface(dev_remote, 'org.bluez.Network1') - - if opts.disconnect: - try: net.Disconnect() - except dbus.exceptions.DBusException as err: - if err.get_dbus_name() != 'org.bluez.Error.Failed': raise - connected = prop_get(net, 'Connected') - if connected: raise - lg.debug( - 'Disconnected from network' - ' (dev_remote: %s, addr: %s) uuid %r, by explicit command', - dev_remote.object_path, prop_get(dev_remote, 'Address'), opts.uuid ) - return - - for n in xrange(2): - try: iface = net.Connect(opts.uuid) - except dbus.exceptions.DBusException as err: - if err.get_dbus_name() != 'org.bluez.Error.Failed': raise - connected = prop_get(net, 'Connected') - if not connected: raise - if opts.reconnect: - lg.debug( 'Detected pre-established connection' - ' (iface: %s), reconnecting', prop_get(net, 'Interface') ) - net.Disconnect() - continue - if not opts.if_not_connected: raise - else: break - lg.debug( - 'Connected to network (dev_remote: %s, addr: %s) uuid %r with iface: %s', - dev_remote.object_path, prop_get(dev_remote, 'Address'), opts.uuid, iface ) - - if opts.wait: - try: - while True: wait_iter() - except KeyboardInterrupt: pass - finally: - net.Disconnect() - lg.debug('Disconnected from network') - - - else: raise ValueError(opts.call) - global pidPath - try: - os.remove(pidPath) - except OSError: - pass - lg.debug('Finished') - -if __name__ == '__main__': sys.exit(main()) diff --git a/recipes-connectivity/bluez/bluez5/bt-pan/default b/recipes-connectivity/bluez/bluez5/bt-pan/default deleted file mode 100755 index c960298..0000000 --- a/recipes-connectivity/bluez/bluez5/bt-pan/default +++ /dev/null @@ -1,2 +0,0 @@ -ENABLED="no" -PANOPTS="--debug" diff --git a/recipes-connectivity/bluez/bluez5/bt-pan/init b/recipes-connectivity/bluez/bluez5/bt-pan/init deleted file mode 100755 index 3f7062e..0000000 --- a/recipes-connectivity/bluez/bluez5/bt-pan/init +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/bash - -NAME=bt-pan -SERVER=/usr/libexec/bluetooth/${NAME} -PYTHON=$(readlink -f /usr/bin/python2) -BRIDGE=pan0 -DNAME="${NAME}.${BRIDGE}" -PIDFILE="/run/${DNAME}.pid" - -ENABLED=yes -[ -f /etc/default/$NAME ] && . /etc/default/$NAME - -if [ "$ENABLED" != "yes" ]; then - echo "$NAME: disabled in /etc/default" - exit -fi - -case $1 in - start) - echo "Starting ${DNAME}" - /usr/sbin/start-stop-daemon -S -p ${PIDFILE} -x ${PYTHON} -b -- ${SERVER} ${PANOPTS} server $BRIDGE - ;; - - stop) - /usr/sbin/start-stop-daemon -K -p ${PIDFILE} -x ${PYTHON} - echo "Stopping ${DNAME}" - ;; - - restart) - $0 stop - $0 start - ;; - - *) - echo "Usage: $0 {start|stop|restart}" - exit 2 - ;; -esac - - diff --git a/recipes-connectivity/bluez/bluez5/default b/recipes-connectivity/bluez/bluez5/default deleted file mode 100644 index e912922..0000000 --- a/recipes-connectivity/bluez/bluez5/default +++ /dev/null @@ -1,8 +0,0 @@ -# Set to 1 to enable bluetooth daemon -BLUETOOTH_ENABLED=0 - -# Use the following to setup bluetooth usability -BLUETOOTHCTL_CMD="power on\ndiscoverable on\npairable on\n" - -#Compatilitity mode -#MOREOPTIONS="-C" diff --git a/recipes-connectivity/bluez/bluez5/init b/recipes-connectivity/bluez/bluez5/init deleted file mode 100755 index 4d84195..0000000 --- a/recipes-connectivity/bluez/bluez5/init +++ /dev/null @@ -1,72 +0,0 @@ -#!/bin/sh - -PATH=/sbin:/bin:/usr/sbin:/usr/bin -DESC=bluetooth - -DAEMON=/usr/libexec/bluetooth/bluetoothd - -# If you want to be ignore error of "org.freedesktop.hostname1", -# please enable NOPLUGIN_OPTION. -# NOPLUGIN_OPTION="--noplugin=hostname" -NOPLUGIN_OPTION="" -SSD_OPTIONS="--oknodo --quiet --exec $DAEMON -- $NOPLUGIN_OPTION" - -test -f $DAEMON || exit 0 - -# FIXME: any of the sourced files may fail if/with syntax errors -test -f /etc/default/bluetooth && . /etc/default/bluetooth -test -f /etc/default/rcS && . /etc/default/rcS - -set -e - -case $1 in - start) - echo "Starting $DESC" - - if test "$BLUETOOTH_ENABLED" = 0; then - echo "disabled. see /etc/default/bluetooth" - exit 0 - fi - - start-stop-daemon --start --background $SSD_OPTIONS $MOREOPTIONS - sleep 1 - if [[ -n ${BLUETOOTHCTL_CMD} ]] ; then - echo -e "${BLUETOOTHCTL_CMD}" | /usr/bin/bluetoothctl 2>&1 | logger -t bluetoothctl -p daemon.info - fi - echo "${DAEMON##*/}" - - ;; - stop) - echo "Stopping $DESC" - if test "$BLUETOOTH_ENABLED" = 0; then - echo "disabled." - exit 0 - fi - start-stop-daemon --stop $SSD_OPTIONS - echo "${DAEMON}" - ;; - restart|force-reload) - $0 stop - sleep 1 - $0 start - ;; - status) - pidof ${DAEMON} >/dev/null - status=$? - if [ $status -eq 0 ]; then - echo "bluetooth is running." - else - echo "bluetooth is not running" - fi - exit $status - ;; - *) - N=/etc/init.d/bluetooth - echo "Usage: $N {start|stop|restart|force-reload|status}" >&2 - exit 1 - ;; -esac - -exit 0 - -# vim:noet diff --git a/recipes-connectivity/bluez/bluez5/main.conf b/recipes-connectivity/bluez/bluez5/main.conf deleted file mode 100644 index 40ad113..0000000 --- a/recipes-connectivity/bluez/bluez5/main.conf +++ /dev/null @@ -1,108 +0,0 @@ -[General] - -# Default adapter name -# Defaults to 'BlueZ X.YZ' -Name = MTCDT-Bluez - -# Default device class. Only the major and minor device class bits are -# considered. Defaults to '0x000000'. -#Class = 0x000100 - -# How long to stay in discoverable mode before going back to non-discoverable -# The value is in seconds. Default is 180, i.e. 3 minutes. -# 0 = disable timer, i.e. stay discoverable forever -DiscoverableTimeout = 0 - -# How long to stay in pairable mode before going back to non-discoverable -# The value is in seconds. Default is 0. -# 0 = disable timer, i.e. stay pairable forever -#PairableTimeout = 0 - -# Automatic connection for bonded devices driven by platform/user events. -# If a platform plugin uses this mechanism, automatic connections will be -# enabled during the interval defined below. Initially, this feature -# intends to be used to establish connections to ATT channels. Default is 60. -AutoConnectTimeout = 0 - -# Use vendor id source (assigner), vendor, product and version information for -# DID profile support. The values are separated by ":" and assigner, VID, PID -# and version. -# Possible vendor id source values: bluetooth, usb (defaults to usb) -#DeviceID = bluetooth:1234:5678:abcd - -# Do reverse service discovery for previously unknown devices that connect to -# us. This option is really only needed for qualification since the BITE tester -# doesn't like us doing reverse SDP for some test cases (though there could in -# theory be other useful purposes for this too). Defaults to 'true'. -#ReverseServiceDiscovery = true - -# Enable name resolving after inquiry. Set it to 'false' if you don't need -# remote devices name and want shorter discovery cycle. Defaults to 'true'. -#NameResolving = true - -# Enable runtime persistency of debug link keys. Default is false which -# makes debug link keys valid only for the duration of the connection -# that they were created for. -#DebugKeys = false - -# Restricts all controllers to the specified transport. Default value -# is "dual", i.e. both BR/EDR and LE enabled (when supported by the HW). -# Possible values: "dual", "bredr", "le" -#ControllerMode = dual - -# Enables Multi Profile Specification support. This allows to specify if -# system supports only Multiple Profiles Single Device (MPSD) configuration -# or both Multiple Profiles Single Device (MPSD) and Multiple Profiles Multiple -# Devices (MPMD) configurations. -# Possible values: "off", "single", "multiple" -#MultiProfile = off - -# Permanently enables the Fast Connectable setting for adapters that -# support it. When enabled other devices can connect faster to us, -# however the tradeoff is increased power consumptions. This feature -# will fully work only on kernel version 4.1 and newer. Defaults to -# 'false'. -#FastConnectable = false - -# Default privacy setting. -# Enables use of private address. -# Possible values: "off", "device", "network" -# "network" option not supported currently -# Defaults to "off" -# Privacy = off - -[GATT] -# GATT attribute cache. -# Possible values: -# always: Always cache attributes even for devices not paired, this is -# recommended as it is best for interoperability, with more consistent -# reconnection times and enables proper tracking of notifications for all -# devices. -# yes: Only cache attributes of paired devices. -# no: Never cache attributes -# Default: always -#Cache = always - -[Policy] -# -# The ReconnectUUIDs defines the set of remote services that should try -# to be reconnected to in case of a link loss (link supervision -# timeout). The policy plugin should contain a sane set of values by -# default, but this list can be overridden here. By setting the list to -# empty the reconnection feature gets disabled. -#ReconnectUUIDs=00001112-0000-1000-8000-00805f9b34fb,0000111f-0000-1000-8000-00805f9b34fb,0000110a-0000-1000-8000-00805f9b34fb - -# ReconnectAttempts define the number of attempts to reconnect after a link -# lost. Setting the value to 0 disables reconnecting feature. -#ReconnectAttempts=7 - -# ReconnectIntervals define the set of intervals in seconds to use in between -# attempts. -# If the number of attempts defined in ReconnectAttempts is bigger than the -# set of intervals the last interval is repeated until the last attempt. -#ReconnectIntervals=1,2,4,8,16,32,64 - -# AutoEnable defines option to enable all controllers when they are found. -# This includes adapters present on start as well as adapters that are plugged -# in later on. Defaults to 'false'. -AutoEnable=true diff --git a/recipes-connectivity/bluez/bluez5/out-of-tree.patch b/recipes-connectivity/bluez/bluez5/out-of-tree.patch deleted file mode 100644 index 3ee79d7..0000000 --- a/recipes-connectivity/bluez/bluez5/out-of-tree.patch +++ /dev/null @@ -1,26 +0,0 @@ -From ed55b49a226ca3909f52416be2ae5ce1c5ca2cb2 Mon Sep 17 00:00:00 2001 -From: Ross Burton -Date: Fri, 22 Apr 2016 15:40:37 +0100 -Subject: [PATCH] Makefile.obexd: add missing mkdir in builtin.h generation - -In parallel out-of-tree builds it's possible that obexd/src/builtin.h is -generated before the target directory has been implicitly created. Solve this by -creating the directory before writing into it. - -Upstream-Status: Submitted -Signed-off-by: Ross Burton ---- - Makefile.obexd | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/Makefile.obexd b/Makefile.obexd -index 2e33cbc..c8286f0 100644 ---- a/Makefile.obexd -+++ b/Makefile.obexd -@@ -105,2 +105,3 @@ obexd/src/plugin.$(OBJEXT): obexd/src/builtin.h - obexd/src/builtin.h: obexd/src/genbuiltin $(obexd_builtin_sources) -+ $(AM_V_at)$(MKDIR_P) $(dir $@) - $(AM_V_GEN)$(srcdir)/obexd/src/genbuiltin $(obexd_builtin_modules) > $@ --- -2.8.0.rc3 - diff --git a/recipes-connectivity/bluez/bluez5/rfcomm/default b/recipes-connectivity/bluez/bluez5/rfcomm/default deleted file mode 100755 index 613a72c..0000000 --- a/recipes-connectivity/bluez/bluez5/rfcomm/default +++ /dev/null @@ -1,2 +0,0 @@ -ENABLED="no" -RFCOMMOPTS="--debug --login" diff --git a/recipes-connectivity/bluez/bluez5/rfcomm/init b/recipes-connectivity/bluez/bluez5/rfcomm/init deleted file mode 100755 index 69455d8..0000000 --- a/recipes-connectivity/bluez/bluez5/rfcomm/init +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/bash - -NAME=rfcomm -SERVER=/usr/libexec/bluetooth/${NAME} -PYTHON=$(readlink -f /usr/bin/python2) -PIDFILE="/run/${NAME}.pid" - -ENABLED=yes -[ -f /etc/default/$NAME ] && . /etc/default/$NAME - -if [ "$ENABLED" != "yes" ]; then - echo "$NAME: disabled in /etc/default" - exit -fi - -case $1 in - start) - echo "Starting ${NAME}" - echo /usr/sbin/start-stop-daemon -S -p ${PIDFILE} -x ${PYTHON} -b -- ${SERVER} ${RFCOMMOPTS} - /usr/sbin/start-stop-daemon -S -p ${PIDFILE} -x ${PYTHON} -b -- ${SERVER} ${RFCOMMOPTS} - ;; - - stop) - /usr/sbin/start-stop-daemon -K -p ${PIDFILE} -x ${PYTHON} - echo "Stopping ${DNAME}" - ;; - - restart) - $0 stop - $0 start - ;; - - *) - echo "Usage: $0 {start|stop|restart}" - exit 2 - ;; -esac - - diff --git a/recipes-connectivity/bluez/bluez5/rfcomm/rfcomm.py b/recipes-connectivity/bluez/bluez5/rfcomm/rfcomm.py deleted file mode 100644 index e8f2554..0000000 --- a/recipes-connectivity/bluez/bluez5/rfcomm/rfcomm.py +++ /dev/null @@ -1,650 +0,0 @@ -#!/usr/bin/env python2 -import thread -import os -import dbus -import dbus.service -import dbus.mainloop.glib -from gi.repository import GObject, GLib -import sys -import time -import threading -import socket -import logging -import logging.handlers -import syslog -import grp -import stat -import atexit -import re -import mmap -import subprocess -import threading -import struct -import fcntl -import termios -import signal -import time -import bluetooth - -# Do we need stty onlcr???? - -#SerialPortProfile = '00001101-0000-1000-8000-00805f9b34fb' - -global lg -global opts -global RFCOMMDIR -RFCOMMDIR = '/run/rfcomm' -SLAVEDIR='/dev/pts' -BLUEZLIB='/var/lib/bluetooth' - -global TTY_GID # Group-ID number of the TTY group -global doterm # If true, this python program is a terminal console. -global needpseudot # Login option and pseudoterminal option -needpseudot = False -global terminatenow -terminatenow = False - -myscript = os.path.basename(__file__) -class dopidfile(object): - pidPath = "/" - - def writePidFile(self): - global pidPath - pid = str(os.getpid()) - pidPath = '/run/rfcomm' + '.pid' - f = open(pidPath, 'w') - f.write(pid) - f.close() - - def rmPidFile(self): - try: - os.remove(pidPath) - except OSError: - pass - - -# Log formating class -class flog: - # priority strings to be used - # with the __init__ function - priorities = { - 'debug': logging.DEBUG, - 'info': logging.INFO, - 'warn': logging.WARNING, - 'warning': logging.WARNING, - 'error': logging.ERROR, - 'critical': logging.CRITICAL, - } - - def __init__(self,myscript,facility,priority): - """ - Initialize for logging - - :param myscript: The name of the python program script - :param facility: The syslog facility, such as daemon or user - :param priority: The minimum priority to be printed to the log - :returns: Nothing - :raises TBD: logging class errors. - """ - name_len = str(len(myscript)) - self.myscript = myscript - self.log = logging.getLogger(myscript) - self.handler = logging.handlers.SysLogHandler(address=('/dev/log'),facility=facility) - self.default_fmt = ' %(levelname)-9s %(name)-' + name_len + 's %(message)s' - self.verbose_fmt1 = ' %(levelname)-9s %(name)-' + name_len + 's %(threadName)-14s ' - self.verbose_fmt2 = ' %(message)s' - formatter = logging.Formatter(self.default_fmt) - self.handler.setFormatter(formatter) - self.log.setLevel(self.priorities[priority]) # Minimum infolevel to log - self.log.addHandler(self.handler) - self.handler.createLock() - - def __default(self,func,*args): - self.handler.acquire() - formatter = logging.Formatter(self.default_fmt) - self.handler.setFormatter(formatter) - func(*args) - self.handler.release() - - def setThreshold(self,threshold): - """ - Change the syslog priority threshold - - :param priority: Character string corresponding to the threshold - """ - self.handler.acquire() - self.log.setLevel(self.priorities[threshold]) # Minimum infolevel to log - self.handler.release() - - def critical(self,*args): - """ - Prints a variable argument list at critical priority - - :returns: logging result - """ - self.__default(self.log.critical,*args) - - def error(self,*args): - """ - Prints a variable argument list at error priority - - :returns: logging result - """ - self.__default(self.log.error,*args) - - def warning(self,*args): - """ - Prints a variable argument list at warning priority - - :returns: logging result - """ - self.__default(self.log.warning,*args) - - # Python has no notice level! - - def info(self,*args): - """ - Prints a variable argument list at info priority - - :returns: logging result - """ - self.__default(self.log.info,*args) - - def debug(self,*args): - """ - Prints a variable argument list at debug priority - - Printing debug includes function name and line - number. - - :returns: logging result - """ - caller_frame = sys._getframe().f_back - callerfunc = caller_frame.f_code.co_name + '@' + str(caller_frame.f_lineno); - callerfunc = callerfunc.ljust(16) - self.handler.acquire() - log = logging.getLogger(self.myscript) - formatter = logging.Formatter(self.verbose_fmt1+callerfunc+self.verbose_fmt2) - self.handler.setFormatter(formatter) - log.debug(*args) - self.handler.release() - -# End of log handler - - - -# Thread to create login process, with -# stdin, stdout, stderr matching the file descriptor -# This is because NewConnection cannot create threads or -# use a mutex. Workarounds are pipes, IPC semamphores, -# IPC messaging -class logins(object): - slavefd = -1 - - # Thread to wait on our children - def IgnoreWait(self,pid): - lg.debug("IgnoreWait: Waiting on process pid: %d" % (pid.pid)) - pid.wait() - lg.debug("login terminated: %d" % (pid.pid)) - - def StartLogin(self,rpipe,mainloop): - datafd='' - masters = [] - lg.debug("StartLogin enter: rpipe fd=%d" % (rpipe)) - while 1: - try: - datafd=os.read(rpipe,8) - except Exception as e: - lg.error('os.read error: %s' % (e)) - lg.debug('Done with StartLogin, calling quit') - for fd in masters: - os.close(fd) - os.kill(os.getpid(), signal.SIGINT) - thread.exit() - # Single integer. - (slavefd,masterfd) = struct.unpack("ii",bytearray(datafd)) - if masterfd > 0: - masters.append(masterfd) - lg.debug("StartLogin: slavefd %d" % (slavefd)) - if slavefd < 0: - lg.debug("Told to exit, so exiting StartLogin thread") - os.close(rpipe) - # We try to close all the masters, as it gets - # things wound down in a hurry. - for fd in masters: - lg.debug('StartLogin: Try to close fd %d' % (fd)) - try: - os.close(fd) - except Exception as e: - lg.debug('StartLogin (ignore error): OK: Did not close fd: %d %s' % (fd,e)) - sys.exc_clear() - os.kill(os.getpid(), signal.SIGINT) - thread.exit() - # Start login with fd, and close it. - Env = {'TERM': 'dumb'} - self.slavefd = slavefd - lg.debug('Popen slavefd: %d' % (slavefd)) - try: - # Mar 16 14:23:35 mtcdt daemon.err ERROR rfcomm.py Popen login: global name 's' is not defined - pid = subprocess.Popen(['/bin/login','--'],env=Env,preexec_fn = lambda: ( os.setsid(),fcntl.ioctl(0, termios.TIOCSCTTY, 0) ),stdin=slavefd,stdout=slavefd,stderr=slavefd,close_fds=True,cwd='/') - lg.debug('Start IgnoreWait thread') - try: - IgnoreWaitThread = threading.Thread(target=self.IgnoreWait,args=[pid]) - except Exception as e: - lg.error('IgnoreWaitThread: threading.Thread: %s' % (e)) - try: - IgnoreWaitThread.start() - except Exception as e: - lg.error('IgnoreWaitThread: start: %s' % (e)) - except Exception as e: - lg.error('Popen login: %s' % (e)) - os.close(slavefd) - -class Profile(dbus.service.Object): - fd = -1 - readThread = None - path = None - io_id = -1 - io_id2 = -1 - hup_id = -1 - hup_id2 = -1 - io_pty_master = -1 - io_pty_slave = -1 - slavePath = None - linkPath = None - w = -1 - # True False pseudonyms for making code readable (or not!) - exiting = True - notexiting = False - - @dbus.service.method('org.bluez.Profile1', - in_signature='', - out_signature='') - def Release(self): - lg.info('Release/quit') - mainloop.quit() - - @dbus.service.method("org.bluez.Profile1", - in_signature="", out_signature="") - def Cancel(self): - lg.info("Cancel") - - def removeLink(self,state): - lg.debug('removeLink: state: %r' % (state)) - path = self.linkPath - lg.debug('removeLink: path %s' % (path)) - if state == self.exiting: - lg.debug('Clearing out linkPath') - self.linkPath = None # Burn bridges, do it once. - if path and os.path.lexists(path): - try: - os.remove(path) - except Exception as e: - lg.error("os.remove(self.linkPath): Tried to remove %s" % (path)) - lg.error('%s' % (e)) - - - - # New Connection is called when a new Bluetooth - # is established - @dbus.service.method('org.bluez.Profile1', - in_signature='oha{sv}', - out_signature='') - def NewConnection(self, path, fd, properties): - dbus.mainloop.glib.threads_init() - self.fd = fd.take() # Extract File Descriptor from dbus UnixFD class. - self.path = path - - # Bluetooth address portion of the path - address = os.path.basename(self.path) - - numaddr = address[address.find("_")+1:] - # Replace _ with : - Name = bluetooth.lookup_name(numaddr.replace("_",":")) - - print('NewConnection(%s, %s, %s:%d)' % (path,Name,type(fd).__name__,self.fd)) - lg.info('NewConnection(%s, %s, %s:%d)' % (path,Name,type(fd).__name__,self.fd)) - atexit.register(self.RequestDisconnection,self.path) - lg.debug('Past atexit.register') - - # Get a pseudoterminal to provide an I/O driver for - # a program that needs a TTY. - if needpseudot: - (self.io_pty_master,self.io_pty_slave) = os.openpty() - slavestat = os.fstat(self.io_pty_slave) - self.minor = os.minor(slavestat.st_rdev) - lg.debug('pseudoterminal major and minor: (%d,%d)' % (os.major(slavestat.st_rdev),self.minor)) - if not os.path.isdir(RFCOMMDIR): - lg.debug('Before mkdir: RFCOMMDIR %s' % (RFCOMMDIR)) - os.mkdir(RFCOMMDIR,0755) - - - lg.debug('Address %s' % (address)) - self.linkPath = RFCOMMDIR + '/' + address + '_' + Name + '_pts' + str(self.minor) - self.slavePath = SLAVEDIR + '/' + str(self.minor) - lg.debug('termPath %s' % (self.linkPath)) - self.removeLink(self.notexiting) - # linkPath was removed - - lg.debug('os.symlink(%s,%s)' % (self.slavePath,self.linkPath)) - old = os.umask(002) - lg.debug('past umask') - try: - os.symlink(self.slavePath,self.linkPath) - try: - atexit.register(self.removeLink,self.exiting); - except Exception as e: - lg.error('Register atexit: %s' % (e)) - except Exception as e: - lg.error('symlink failed: %s' % (e)) - return False - lg.debug('Before umask') - os.umask(old) - lg.debug('After umask') - # os.chown(self.myPath,0,TTY_GID) - - # Completed pseudoterminal case to create device and node - - # + For loopback, we only monitor the RFCOMM line (self.fd). - # + For interactive (not pseudoterminal or loopback option, - # we monitor the stdin (0) and the RFCOMM line for input - # + For pseudoterminal, we monitor input on the RFCOMM line, - # and the slave pseudoterminal. - # Note that io_add_watch causes a poll to be done by the - # python GI library. The callback functions (io_term and io_cb) - # will be called when there is an event on the file descriptor - # being polled. - sys.stdout.flush() - if not opts.loopback: - if needpseudot: - local_fd = self.io_pty_master - lg.debug('NewConnection: master_fd: %d slave_fd: %d' % (local_fd,self.io_pty_slave)) #success to here. - else: - # stdin - local_fd = 0 - lg.debug('Ready to do io_add_watch on local_fd: %d' % (local_fd)) - try: - self.io_id2 = GObject.io_add_watch(local_fd, - GObject.PRIORITY_DEFAULT, - GObject.IO_IN | GObject.IO_PRI | GObject.IO_HUP | GObject.IO_ERR, - self.io_term) - except Exception as e: - lg.error('io_addwatch failed for local_fd %d: IO_IN, IO_PRI %s' % (local_fd,e)) - - if opts.login: - # Writing the slave file descriptor causes the login process to start. - lg.debug('opts.login is true slave fd: %d pipe: %d' % (self.io_pty_slave,self.w)) - try: - os.write(self.w,struct.pack('ii',self.io_pty_slave,self.io_pty_master)) - except Exception as e: - lg.error('os.write of slave fd:%d master fd: %d failed: %s' % (self.io_pty_slave,self.io_pty_slave,e)) - os.close(self.io_pty_slave) - self.io_pty_slave = -1 - return False - self.io_pty_slave = -1 - - if doterm: - lg.debug('Profile: Write the prompt') - os.write(1,'TTY> ') - - lg.debug('NewConnection: doterm: %s, io_add_watch is next' % doterm) - - self.io_id = GObject.io_add_watch(self.fd, - GObject.PRIORITY_DEFAULT, - GObject.IO_IN | GObject.IO_PRI | GObject.IO_HUP | GObject.IO_ERR, - self.io_cb) - lg.debug('io_id(remote input) = %d io_id2(local input) = %d' % (self.io_id,self.io_id2)) - - - # I/O read from Bluetooth remote to local application. - def io_cb(self, fd, conditions): - if terminatenow: - self.RequestDisconnection(self.path) - - if (conditions & GObject.IO_HUP or conditions & GObject.IO_ERR): - lg.debug('Found HUP on fd: %d, so terminate' % (fd)) - self.RequestDisconnection(self.path) - return False - # Read from remote - data = None - try: - data = os.read(fd, 1024) - except: - return True - lg.debug('io_cb: past read: doterm: %s' % doterm) - if opts.loopback: - toutput = fd # same as input - else: - toutput = self.io_pty_master - - if opts.loopback or needpseudot or opts.login: - if data: - start = 0 - remain = len(data) - result = 1 - lg.debug('remain is %d entering the loop' % (remain)) - while remain > 0 and result > 0: - try: - result = os.write(toutput,data) - except Exception as e: - lg.debug('os.write failed: %s' % (e)) - return True - lg.debug('os.write returned %d for %s remain: %d' % (result,data,remain)) - if remain != result and remain > 0: - remain -= result - lg.debug('remain is now %d result is %d' % (remain,result)) - data = data[-remain:] - lg.debug('remain to print %s' % (data)) - else: - remain = 0 - lg.debug('returning true to end this routing') - return True - - if data and len(data) > 0: - final = data[-1] - if data[-1] == '\n': - date = data[:-1] - if doterm: - print('\n'+data.decode('ascii')) - os.write(1,'TTY> ') - - return True - - # I/O written to bluetooth from local slave (application write to remote) - def io_term(self, fd0, conditions): - if terminatenow: - self.RequestDisconnection(self.path) - if (conditions & GObject.IO_HUP or conditions & GObject.IO_ERR): - lg.debug('Found HUP on fd0: %d, so terminate' % (fd0)) - self.RequestDisconnection(self.path) - return False - # Read from local (not used for loopback) - data = None - data = os.read(fd0, 1024) - lg.debug('io_term: fd0: %d len(data): %d' % (fd0,len(data))) - if not data: - # No Data == EOF - self.RequestDisconnection(self.path) - return True - #for character in data: - # print character, character.encode('hex') - try: - os.write(self.fd,data) - except Exception as e: - print '%s' % (e) - lg.error('%s' % (e)) - self.RequestDisconnection(self.path) - return True - if doterm: - os.write(fd0,'TTY> ') - return True - - @dbus.service.method('org.bluez.Profile1', - in_signature='o', - out_signature='') - def RequestDisconnection(self, path): - print('RequestDisconnection(%s)' % (path)) - lg.info('RequestDisconnection(%s)' % (path)) - if self.fd != -1: - lg.debug('closing fd: %s' % (self.fd)) - s = socket.fromfd(self.fd,socket.AF_INET,socket.SOCK_STREAM) - result = s.shutdown(socket.SHUT_RDWR) - lg.debug('After shutdown fd: %s %s %s' % (self.fd,' result:',result)) - result = os.close(self.fd) - lg.debug('After closing fd: %s %s %s' % (self.fd,' result:',result)) - self.fd = -1 - if self.io_id != -1: - lg.debug('remove id: %s' % (self.io_id)) - rmv = GObject.source_remove(self.io_id) - self.io_id = -1 - if self.io_id2 != -1: - lg.debug('closing id2: %s' % (self.io_id2)) - rmv = GObject.source_remove(self.io_id2) - lg.debug('removed id2: %s %s %s' % (self.io_id2,'result: ',rmv)) - self.io_id2 = -1 - if self.hup_id != -1: - lg.debug('closing hup_id: %s' % (self.hup_id)) - rmv = GObject.source_remove(self.hup_id) - lg.debug('removed id2: %s %s %s' % (self.hup_id,'result: ',rmv)) - self.hup_id = -1 - if self.hup_id2 != -1: - lg.debug('closing hup_id2: %s' % (self.hup_id2)) - rmv = GObject.source_remove(self.hup_id2) - lg.debug('removed id2: %s %s %s' % (self.hup_id2,'result: ',rmv)) - self.hup_id2 = -1 - if needpseudot: - if self.io_pty_slave != -1: - os.close(self.io_pty_slave) - self.io_pty_slave = -1 - if self.io_pty_master != -1: - try: - savefd = self.io_pty_master - self.io_pty_master = -1 - os.close(savefd) - except Exception as e: - lg.error("close(io_pty_master): Tried to close %d" % (savefd)) - lg.error('%s' % (e)) - - self.removeLink(self.exiting) - -def terminationHandler(mainloop): - lg.debug('SIGTERM: terminationHandler was called') - mainloop.quit() - - -if __name__ == '__main__': - import argparse - - doterm = False - TTY_GID = grp.getgrnam('tty').gr_gid - # Set up logging initially info and above - lg = flog(myscript,'daemon','info') - - parser = argparse.ArgumentParser( - description='BlueZ RFCOMM server.') - - parser.add_argument('-u', '--uuid', - metavar='uuid_or_shortcut', default='spp', - help='Service UUID to use. Can be either full UUID' - ' or one of the shortcuts: gn, panu, nap. Default: %(default)s.') - parser.add_argument('--pseudoterminal', action='store_true', - help='Create a pseudoterminal and put slave in /run/rfcomm' - ' Suitable for background operation.') - parser.add_argument('--loopback', action='store_true', - help='Echo data for testing (exclusive with pseudoterminal)') - parser.add_argument('--debug', - action='store_true', help='Verbose operation mode.') - parser.add_argument('--login', - action='store_true', help='Use RFCOMM to log into this device.') - opts = parser.parse_args() - - if opts.debug: - lg.setThreshold('debug') - - if opts.pseudoterminal and opts.loopback: - msg = 'Cannot have both pseudoterminal and loopback option' - print msg - lg.error(msg) - exit(1) - if not opts.pseudoterminal and not opts.loopback and not opts.login: - doterm = True - print "main: doterm is %s" % (str(doterm)) - - if opts.pseudoterminal or opts.login: - needpseudot = True - - - - dbus.mainloop.glib.DBusGMainLoop(set_as_default=True) - - bus = dbus.SystemBus() - - manager = dbus.Interface(bus.get_object('org.bluez', - '/org/bluez'), - 'org.bluez.ProfileManager1') - - mainloop = GObject.MainLoop() - - GLib.unix_signal_add(GLib.PRIORITY_HIGH,signal.SIGTERM,terminationHandler,mainloop) - mypidfile = dopidfile() - mypidfile.writePidFile() - - if opts.login: - # Need to create thead to exec logins. - rpipe,wpipe = os.pipe() - loginProcess = logins() - Profile.w = wpipe - lg.debug('Call threading next') - try: - StartLoginThread = threading.Thread(target=loginProcess.StartLogin,args=[rpipe,mainloop]) - except Exception as e: - lg.error('threading.Thread: StartLogin %s' % (e)) - try: - StartLoginThread.start() - except Exception as e: - lg.error('StartLogin.start: %s' % (e)) - - - profile_path = '/foo/bar/profile' - - SPP_opts = { - 'AutoConnect': True, - 'Role': 'server', - 'Name': 'SerialPort' - } - - print('Starting Serial Port Profile...') - lg.info('Starting Serial Port Profile...') - - profile = Profile(bus, profile_path) - - try: - manager.RegisterProfile(profile_path, opts.uuid, SPP_opts) - except dbus.exceptions.DBusException as inst: - print 'dbus exception:',inst._dbus_error_name - lg.error('dbus exception: %s',inst._dbus_error_name) - if inst._dbus_error_name == 'org.freedesktop.DBus.Error.AccessDenied': - print 'Try running as root' - exit(1) - - lg.debug('Completed Register Profile...') - dbus.mainloop.glib.threads_init() - lg.debug('Completed threads init... Now mainloop.run') - try: - mainloop.run() - except KeyboardInterrupt: - pass - except Exception as e: - lg.error('mainloop exception: %s' % (e)) - print '\nSerial Port Profile: ERROR Goodbye' - lg.error('Serial Port Profile: ERROR Goodbye') - data = struct.pack('i',-1) - os.write(wpipe,data) - mainloop.quit() - - lg.info('Serial Port Profile: Goodbye') - if opts.login: - data = struct.pack('ii',-1,-1) - os.write(wpipe,data) - mypidfile.rmPidFile() - mainloop.quit() diff --git a/recipes-connectivity/bluez/bluez5/run-ptest b/recipes-connectivity/bluez/bluez5/run-ptest deleted file mode 100644 index 21df00c..0000000 --- a/recipes-connectivity/bluez/bluez5/run-ptest +++ /dev/null @@ -1,31 +0,0 @@ -#! /bin/sh - -cd unit - -failed=0 -all=0 - -for f in test-*; do - "./$f" - case "$?" in - 0) - echo "PASS: $f" - all=$((all + 1)) - ;; - 77) - echo "SKIP: $f" - ;; - *) - echo "FAIL: $f" - failed=$((failed + 1)) - all=$((all + 1)) - ;; - esac -done - -if [ "$failed" -eq 0 ] ; then - echo "All $all tests passed" -else - echo "$failed of $all tests failed" -fi - diff --git a/recipes-connectivity/bluez/bluez5_%.bbappend b/recipes-connectivity/bluez/bluez5_%.bbappend deleted file mode 100644 index ab89900..0000000 --- a/recipes-connectivity/bluez/bluez5_%.bbappend +++ /dev/null @@ -1,4 +0,0 @@ -EXTRA_OECONF += "--enable-deprecated --enable-experimental" - -RDEPENDS_${PN}-rfcomm += "python-pybluez" - diff --git a/recipes-connectivity/bluez/bluez5_5.47.bb b/recipes-connectivity/bluez/bluez5_5.47.bb deleted file mode 100644 index fb17add..0000000 --- a/recipes-connectivity/bluez/bluez5_5.47.bb +++ /dev/null @@ -1,55 +0,0 @@ -require bluez5.inc - -REQUIRED_DISTRO_FEATURES = "bluez5" - -SRC_URI[md5sum] = "783e15f65e70cdb8f721c659e140dd56" -SRC_URI[sha256sum] = "cf75bf7cd5d564f21cc4a2bd01d5c39ce425397335fd47d9bbe43af0a58342c8" - -# noinst programs in Makefile.tools that are conditional on READLINE -# support -NOINST_TOOLS_READLINE ?= " \ - attrib/gatttool \ - tools/obex-client-tool \ - tools/obex-server-tool \ - tools/bluetooth-player \ - tools/obexctl \ - tools/btmgmt \ -" - -# noinst programs in Makefile.tools that are conditional on EXPERIMENTAL -# support -NOINST_TOOLS_EXPERIMENTAL ?= " \ - emulator/btvirt \ - emulator/b1ee \ - emulator/hfp \ - tools/3dsp \ - tools/mgmt-tester \ - tools/gap-tester \ - tools/l2cap-tester \ - tools/sco-tester \ - tools/smp-tester \ - tools/hci-tester \ - tools/rfcomm-tester \ - tools/bdaddr \ - tools/avinfo \ - tools/avtest \ - tools/scotest \ - tools/amptest \ - tools/hwdb \ - tools/hcieventmask \ - tools/hcisecfilter \ - tools/btinfo \ - tools/btattach \ - tools/btsnoop \ - tools/btproxy \ - tools/btiotest \ - tools/mcaptest \ - tools/cltest \ - tools/oobtest \ - tools/seq2bseq \ - tools/ibeacon \ - tools/btgatt-client \ - tools/btgatt-server \ - tools/gatt-service \ - profiles/iap/iapd \ -" diff --git a/recipes-connectivity/bluez/python-gatt-server_1.0.bb b/recipes-connectivity/bluez/python-gatt-server_1.0.bb deleted file mode 100644 index 76069f6..0000000 --- a/recipes-connectivity/bluez/python-gatt-server_1.0.bb +++ /dev/null @@ -1,24 +0,0 @@ -inherit allarch -HOMEPAGE = "https://github.com/Jumperr-labs/python-gatt-server" -SRCREV = "a39ef9773e9ba845f4303b1dfd2efddf24b02238" -PR = "r0" - -S = "${WORKDIR}/git" - -LICENSE = "GPLv2" -LIC_FILES_CHKSUM = "file://LICENSE;md5=c53d04442d1a229d62549856b7ec456a" - -SRC_URI = "git://github.com/Jumperr-labs/python-gatt-server.git;protocol=git" - -RDEPENDS_${PN} += "python-dbus python-pygobject" - -DBTEXEC = "${libexecdir}/bluetooth/" -DEST = "${D}${DBTEXEC}" - -FILES_${PN} = "${DBTEXEC}" - - -do_install_append() { - install -d ${DEST}/${PN} - install -m 0755 ${S}/*.py ${DEST}/${PN} -} diff --git a/recipes-connectivity/c-ares/c-ares_1.10.0.bb b/recipes-connectivity/c-ares/c-ares_1.10.0.bb deleted file mode 100644 index 0d1ef9d..0000000 --- a/recipes-connectivity/c-ares/c-ares_1.10.0.bb +++ /dev/null @@ -1,13 +0,0 @@ -DESCRIPTION = "C library for asynchronous DNS requests (including name resolves)" -HOMEPAGE = "http://c-ares.haxx.se/" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://README;beginline=17;endline=23;md5=d08205a43bc63c12cf394ac1d2cce7c3" - -PR = "r0" - -SRC_URI = "http://c-ares.haxx.se/download/c-ares-${PV}.tar.gz" - -SRC_URI[md5sum] = "1196067641411a75d3cbebe074fd36d8" -SRC_URI[sha256sum] = "3d701674615d1158e56a59aaede7891f2dde3da0f46a6d3c684e0ae70f52d3db" - -inherit autotools diff --git a/recipes-connectivity/lldpd/lldpd/lldpd.default b/recipes-connectivity/lldpd/lldpd/lldpd.default deleted file mode 100644 index b33facf..0000000 --- a/recipes-connectivity/lldpd/lldpd/lldpd.default +++ /dev/null @@ -1,3 +0,0 @@ -ENABLED="no" -# Uncomment to start SNMP subagent and enable CDP, SONMP and EDP protocol -#DAEMON_ARGS="-x -c -s -e" diff --git a/recipes-connectivity/lldpd/lldpd/lldpd.init.d b/recipes-connectivity/lldpd/lldpd/lldpd.init.d deleted file mode 100644 index d071e1b..0000000 --- a/recipes-connectivity/lldpd/lldpd/lldpd.init.d +++ /dev/null @@ -1,129 +0,0 @@ -#! /bin/sh -### BEGIN INIT INFO -# Provides: lldpd -# Required-Start: $remote_fs $network $syslog -# Required-Stop: $network $remote_fs $syslog -# Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 -# Short-Description: LLDP daemon -# Description: lldpd is a 802.1AB implementation, a L2 network -# discovery protocol. It also supports CDP, EDP and -# various other protocols. -### END INIT INFO - -# Do NOT "set -e" - -log_daemon_msg() { - echo $* -} - -log_end_msg() { - if [ $1 -eq 0 ]; then - success $* - else - failure $* - fi -} - -log_failure_msg() { - echo $* -} - -log_success_msg() { - echo $* -} - - -# PATH should only include /usr/* if it runs after the mountnfs.sh script -PATH=/sbin:/usr/sbin:/bin:/usr/bin -DESC="LLDP daemon" -NAME=lldpd -DAEMON=/usr/sbin/$NAME -DAEMON_ARGS="" -PIDFILE=/var/run/$NAME.pid -SCRIPTNAME=/etc/init.d/$NAME -CHROOT=/var/run/$NAME - -# Exit if the package is not installed -[ -x "$DAEMON" ] || exit 0 - -# Read configuration variable file if it is present -[ -r /etc/default/$NAME ] && . /etc/default/$NAME -[ "$ENABLED" == "yes" ] || exit 0 - -# LSB log_* functions -. /etc/init.d/functions - -do_start() -{ - start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $DAEMON -- \ - $DAEMON_ARGS \ - || return 2 -} - -do_stop() -{ - start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME - RETVAL="$?" - [ "$RETVAL" = 2 ] && return 2 - start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON - [ "$?" = 2 ] && return 2 - rm -f $PIDFILE - return "$RETVAL" -} - -do_reload() { - start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE --name $NAME - return 0 -} - -case "$1" in - start) - [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME" - do_start - case "$?" in - 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; - 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; - esac - ;; - stop) - [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME" - do_stop - case "$?" in - 0|1) [ "$VERBOSE" != no ] && log_end_msg 0 ;; - 2) [ "$VERBOSE" != no ] && log_end_msg 1 ;; - esac - ;; - reload) - log_daemon_msg "Reloading $DESC" "$NAME" - do_reload - log_end_msg $? - ;; - restart|force-reload) - log_daemon_msg "Restarting $DESC" "$NAME" - do_stop - case "$?" in - 0|1) - do_start - case "$?" in - 0) log_end_msg 0 ;; - 1) log_end_msg 1 ;; # Old process is still running - *) log_end_msg 1 ;; # Failed to start - esac - ;; - *) - # Failed to stop - log_end_msg 1 - ;; - esac - ;; - status) - status_of_proc $DAEMON $NAME -p $PIDFILE && exit 0 || exit $? - ;; - *) - echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload|status}" >&2 - exit 3 - ;; -esac - -: diff --git a/recipes-connectivity/lldpd/lldpd_%.bbappend b/recipes-connectivity/lldpd/lldpd_%.bbappend deleted file mode 100644 index 72d991c..0000000 --- a/recipes-connectivity/lldpd/lldpd_%.bbappend +++ /dev/null @@ -1 +0,0 @@ -FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" diff --git a/recipes-connectivity/mosquitto/mosquitto/config_mk.patch b/recipes-connectivity/mosquitto/mosquitto/config_mk.patch deleted file mode 100644 index 437022c..0000000 --- a/recipes-connectivity/mosquitto/mosquitto/config_mk.patch +++ /dev/null @@ -1,27 +0,0 @@ -diff -Naur old/config.mk new/config.mk ---- old/config.mk 2017-04-17 14:33:32.504351936 -0500 -+++ new/config.mk 2017-04-17 14:34:27.061557282 -0500 -@@ -83,9 +83,9 @@ - # Strip executables and shared libraries on install. - WITH_STRIP:=no - - # Build static libraries --WITH_STATIC_LIBRARIES:=no -+WITH_STATIC_LIBRARIES:=yes - - # Build with async dns lookup support for bridges (temporary). Requires glibc. - #WITH_ADNS:=yes - -@@ -272,7 +272,7 @@ - endif - - INSTALL?=install --prefix=/usr/local -+prefix=/usr - mandir=${prefix}/share/man - localedir=${prefix}/share/locale - STRIP?=strip - - - - diff --git a/recipes-connectivity/mosquitto/mosquitto/mosquitto.conf b/recipes-connectivity/mosquitto/mosquitto/mosquitto.conf deleted file mode 100644 index 25821b8..0000000 --- a/recipes-connectivity/mosquitto/mosquitto/mosquitto.conf +++ /dev/null @@ -1,812 +0,0 @@ -# Config file for mosquitto -# -# See mosquitto.conf(5) for more information. -# -# Default values are shown, uncomment to change. -# -# Use the # character to indicate a comment, but only if it is the -# very first character on the line. - -# ================================================================= -# General configuration -# ================================================================= - -# Time in seconds to wait before resending an outgoing QoS=1 or -# QoS=2 message. -#retry_interval 20 - -# Time in seconds between updates of the $SYS tree. -# Set to 0 to disable the publishing of the $SYS tree. -#sys_interval 10 - -# Time in seconds between cleaning the internal message store of -# unreferenced messages. Lower values will result in lower memory -# usage but more processor time, higher values will have the -# opposite effect. -# Setting a value of 0 means the unreferenced messages will be -# disposed of as quickly as possible. -#store_clean_interval 10 - -# Write process id to a file. Default is a blank string which means -# a pid file shouldn't be written. -# This should be set to /var/run/mosquitto.pid if mosquitto is -# being run automatically on boot with an init script and -# start-stop-daemon or similar. -pid_file /var/run/mosquitto.pid - -# When run as root, drop privileges to this user and its primary -# group. -# Leave blank to stay as root, but this is not recommended. -# If run as a non-root user, this setting has no effect. -# Note that on Windows this has no effect and so mosquitto should -# be started by the user you wish it to run as. -user root - -# The maximum number of QoS 1 and 2 messages currently inflight per -# client. -# This includes messages that are partway through handshakes and -# those that are being retried. Defaults to 20. Set to 0 for no -# maximum. Setting to 1 will guarantee in-order delivery of QoS 1 -# and 2 messages. -#max_inflight_messages 20 - -# The maximum number of QoS 1 and 2 messages to hold in a queue -# above those that are currently in-flight. Defaults to 100. Set -# to 0 for no maximum (not recommended). -# See also queue_qos0_messages. -#max_queued_messages 100 - -# Set to true to queue messages with QoS 0 when a persistent client is -# disconnected. These messages are included in the limit imposed by -# max_queued_messages. -# Defaults to false. -# This is a non-standard option for the MQTT v3.1 spec but is allowed in -# v3.1.1. -#queue_qos0_messages false - -# This option sets the maximum publish payload size that the broker will allow. -# Received messages that exceed this size will not be accepted by the broker. -# The default value is 0, which means that all valid MQTT messages are -# accepted. MQTT imposes a maximum payload size of 268435455 bytes. -#message_size_limit 0 - -# This option controls whether a client is allowed to connect with a zero -# length client id or not. This option only affects clients using MQTT v3.1.1 -# and later. If set to false, clients connecting with a zero length client id -# are disconnected. If set to true, clients will be allocated a client id by -# the broker. This means it is only useful for clients with clean session set -# to true. -#allow_zero_length_clientid true - -# If allow_zero_length_clientid is true, this option allows you to set a prefix -# to automatically generated client ids to aid visibility in logs. -#auto_id_prefix - -# This option allows persistent clients (those with clean session set to false) -# to be removed if they do not reconnect within a certain time frame. -# -# This is a non-standard option in MQTT V3.1 but allowed in MQTT v3.1.1. -# -# Badly designed clients may set clean session to false whilst using a randomly -# generated client id. This leads to persistent clients that will never -# reconnect. This option allows these clients to be removed. -# -# The expiration period should be an integer followed by one of h d w m y for -# hour, day, week, month and year respectively. For example -# -# persistent_client_expiration 2m -# persistent_client_expiration 14d -# persistent_client_expiration 1y -# -# The default if not set is to never expire persistent clients. -#persistent_client_expiration - -# If a client is subscribed to multiple subscriptions that overlap, e.g. foo/# -# and foo/+/baz , then MQTT expects that when the broker receives a message on -# a topic that matches both subscriptions, such as foo/bar/baz, then the client -# should only receive the message once. -# Mosquitto keeps track of which clients a message has been sent to in order to -# meet this requirement. The allow_duplicate_messages option allows this -# behaviour to be disabled, which may be useful if you have a large number of -# clients subscribed to the same set of topics and are very concerned about -# minimising memory usage. -# It can be safely set to true if you know in advance that your clients will -# never have overlapping subscriptions, otherwise your clients must be able to -# correctly deal with duplicate messages even when then have QoS=2. -#allow_duplicate_messages false - -# The MQTT specification requires that the QoS of a message delivered to a -# subscriber is never upgraded to match the QoS of the subscription. Enabling -# this option changes this behaviour. If upgrade_outgoing_qos is set true, -# messages sent to a subscriber will always match the QoS of its subscription. -# This is a non-standard option explicitly disallowed by the spec. -#upgrade_outgoing_qos false - -# ================================================================= -# Default listener -# ================================================================= - -# IP address/hostname to bind the default listener to. If not -# given, the default listener will not be bound to a specific -# address and so will be accessible to all network interfaces. -# bind_address ip-address/host name -bind_address 127.0.0.1 - -# Port to use for the default listener. -port 1883 - -# The maximum number of client connections to allow. This is -# a per listener setting. -# Default is -1, which means unlimited connections. -# Note that other process limits mean that unlimited connections -# are not really possible. Typically the default maximum number of -# connections possible is around 1024. -#max_connections -1 - -# Choose the protocol to use when listening. -# This can be either mqtt or websockets. -# Websockets support is currently disabled by default at compile time. -# Certificate based TLS may be used with websockets, except that -# only the cafile, certfile, keyfile and ciphers options are supported. -protocol mqtt - -# When a listener is using the websockets protocol, it is possible to serve -# http data as well. Set http_dir to a directory which contains the files you -# wish to serve. If this option is not specified, then no normal http -# connections will be possible. -#http_dir - -# Set use_username_as_clientid to true to replace the clientid that a client -# connected with with its username. This allows authentication to be tied to -# the clientid, which means that it is possible to prevent one client -# disconnecting another by using the same clientid. -# If a client connects with no username it will be disconnected as not -# authorised when this option is set to true. -# Do not use in conjunction with clientid_prefixes. -# See also use_identity_as_username. -#use_username_as_clientid - -# ----------------------------------------------------------------- -# Certificate based SSL/TLS support -# ----------------------------------------------------------------- -# The following options can be used to enable SSL/TLS support for -# this listener. Note that the recommended port for MQTT over TLS -# is 8883, but this must be set manually. -# -# See also the mosquitto-tls man page. - -# At least one of cafile or capath must be defined. They both -# define methods of accessing the PEM encoded Certificate -# Authority certificates that have signed your server certificate -# and that you wish to trust. -# cafile defines the path to a file containing the CA certificates. -# capath defines a directory that will be searched for files -# containing the CA certificates. For capath to work correctly, the -# certificate files must have ".crt" as the file ending and you must run -# "c_rehash " each time you add/remove a certificate. -#cafile -#capath - -# Path to the PEM encoded server certificate. -#certfile - -# Path to the PEM encoded keyfile. -#keyfile - -# This option defines the version of the TLS protocol to use for this listener. -# The default value allows v1.2, v1.1 and v1.0, if they are all supported by -# the version of openssl that the broker was compiled against. For openssl >= -# 1.0.1 the valid values are tlsv1.2 tlsv1.1 and tlsv1. For openssl < 1.0.1 the -# valid values are tlsv1. -#tls_version - -# By default a TLS enabled listener will operate in a similar fashion to a -# https enabled web server, in that the server has a certificate signed by a CA -# and the client will verify that it is a trusted certificate. The overall aim -# is encryption of the network traffic. By setting require_certificate to true, -# the client must provide a valid certificate in order for the network -# connection to proceed. This allows access to the broker to be controlled -# outside of the mechanisms provided by MQTT. -#require_certificate false - -# If require_certificate is true, you may set use_identity_as_username to true -# to use the CN value from the client certificate as a username. If this is -# true, the password_file option will not be used for this listener. -#use_identity_as_username false - -# If you have require_certificate set to true, you can create a certificate -# revocation list file to revoke access to particular client certificates. If -# you have done this, use crlfile to point to the PEM encoded revocation file. -#crlfile - -# If you wish to control which encryption ciphers are used, use the ciphers -# option. The list of available ciphers can be optained using the "openssl -# ciphers" command and should be provided in the same format as the output of -# that command. -# If unset defaults to DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:@STRENGTH -#ciphers DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:@STRENGTH - -# ----------------------------------------------------------------- -# Pre-shared-key based SSL/TLS support -# ----------------------------------------------------------------- -# The following options can be used to enable PSK based SSL/TLS support for -# this listener. Note that the recommended port for MQTT over TLS is 8883, but -# this must be set manually. -# -# See also the mosquitto-tls man page and the "Certificate based SSL/TLS -# support" section. Only one of certificate or PSK encryption support can be -# enabled for any listener. - -# The psk_hint option enables pre-shared-key support for this listener and also -# acts as an identifier for this listener. The hint is sent to clients and may -# be used locally to aid authentication. The hint is a free form string that -# doesn't have much meaning in itself, so feel free to be creative. -# If this option is provided, see psk_file to define the pre-shared keys to be -# used or create a security plugin to handle them. -#psk_hint - -# Set use_identity_as_username to have the psk identity sent by the client used -# as its username. Authentication will be carried out using the PSK rather than -# the MQTT username/password and so password_file will not be used for this -# listener. -#use_identity_as_username false - -# When using PSK, the encryption ciphers used will be chosen from the list of -# available PSK ciphers. If you want to control which ciphers are available, -# use the "ciphers" option. The list of available ciphers can be optained -# using the "openssl ciphers" command and should be provided in the same format -# as the output of that command. -#ciphers - -# ================================================================= -# Extra listeners -# ================================================================= - -# Listen on a port/ip address combination. By using this variable -# multiple times, mosquitto can listen on more than one port. If -# this variable is used and neither bind_address nor port given, -# then the default listener will not be started. -# The port number to listen on must be given. Optionally, an ip -# address or host name may be supplied as a second argument. In -# this case, mosquitto will attempt to bind the listener to that -# address and so restrict access to the associated network and -# interface. By default, mosquitto will listen on all interfaces. -# listener port-number [ip address/host name] -#listener - -# The maximum number of client connections to allow. This is -# a per listener setting. -# Default is -1, which means unlimited connections. -# Note that other process limits mean that unlimited connections -# are not really possible. Typically the default maximum number of -# connections possible is around 1024. -#max_connections -1 - -# The listener can be restricted to operating within a topic hierarchy using -# the mount_point option. This is achieved be prefixing the mount_point string -# to all topics for any clients connected to this listener. This prefixing only -# happens internally to the broker; the client will not see the prefix. -#mount_point - -# Choose the protocol to use when listening. -# This can be either mqtt or websockets. -# Certificate based TLS may be used with websockets, except that only the -# cafile, certfile, keyfile and ciphers options are supported. -protocol mqtt - -# When a listener is using the websockets protocol, it is possible to serve -# http data as well. Set http_dir to a directory which contains the files you -# wish to serve. If this option is not specified, then no normal http -# connections will be possible. -#http_dir - -# Set use_username_as_clientid to true to replace the clientid that a client -# connected with with its username. This allows authentication to be tied to -# the clientid, which means that it is possible to prevent one client -# disconnecting another by using the same clientid. -# If a client connects with no username it will be disconnected as not -# authorised when this option is set to true. -# Do not use in conjunction with clientid_prefixes. -# See also use_identity_as_username. -#use_username_as_clientid - -# ----------------------------------------------------------------- -# Certificate based SSL/TLS support -# ----------------------------------------------------------------- -# The following options can be used to enable certificate based SSL/TLS support -# for this listener. Note that the recommended port for MQTT over TLS is 8883, -# but this must be set manually. -# -# See also the mosquitto-tls man page and the "Pre-shared-key based SSL/TLS -# support" section. Only one of certificate or PSK encryption support can be -# enabled for any listener. - -# At least one of cafile or capath must be defined to enable certificate based -# TLS encryption. They both define methods of accessing the PEM encoded -# Certificate Authority certificates that have signed your server certificate -# and that you wish to trust. -# cafile defines the path to a file containing the CA certificates. -# capath defines a directory that will be searched for files -# containing the CA certificates. For capath to work correctly, the -# certificate files must have ".crt" as the file ending and you must run -# "c_rehash " each time you add/remove a certificate. -#cafile -#capath - -# Path to the PEM encoded server certificate. -#certfile - -# Path to the PEM encoded keyfile. -#keyfile - -# By default an TLS enabled listener will operate in a similar fashion to a -# https enabled web server, in that the server has a certificate signed by a CA -# and the client will verify that it is a trusted certificate. The overall aim -# is encryption of the network traffic. By setting require_certificate to true, -# the client must provide a valid certificate in order for the network -# connection to proceed. This allows access to the broker to be controlled -# outside of the mechanisms provided by MQTT. -#require_certificate false - -# If require_certificate is true, you may set use_identity_as_username to true -# to use the CN value from the client certificate as a username. If this is -# true, the password_file option will not be used for this listener. -#use_identity_as_username false - -# If you have require_certificate set to true, you can create a certificate -# revocation list file to revoke access to particular client certificates. If -# you have done this, use crlfile to point to the PEM encoded revocation file. -#crlfile - -# If you wish to control which encryption ciphers are used, use the ciphers -# option. The list of available ciphers can be optained using the "openssl -# ciphers" command and should be provided in the same format as the output of -# that command. -#ciphers - -# ----------------------------------------------------------------- -# Pre-shared-key based SSL/TLS support -# ----------------------------------------------------------------- -# The following options can be used to enable PSK based SSL/TLS support for -# this listener. Note that the recommended port for MQTT over TLS is 8883, but -# this must be set manually. -# -# See also the mosquitto-tls man page and the "Certificate based SSL/TLS -# support" section. Only one of certificate or PSK encryption support can be -# enabled for any listener. - -# The psk_hint option enables pre-shared-key support for this listener and also -# acts as an identifier for this listener. The hint is sent to clients and may -# be used locally to aid authentication. The hint is a free form string that -# doesn't have much meaning in itself, so feel free to be creative. -# If this option is provided, see psk_file to define the pre-shared keys to be -# used or create a security plugin to handle them. -#psk_hint - -# Set use_identity_as_username to have the psk identity sent by the client used -# as its username. Authentication will be carried out using the PSK rather than -# the MQTT username/password and so password_file will not be used for this -# listener. -#use_identity_as_username false - -# When using PSK, the encryption ciphers used will be chosen from the list of -# available PSK ciphers. If you want to control which ciphers are available, -# use the "ciphers" option. The list of available ciphers can be optained -# using the "openssl ciphers" command and should be provided in the same format -# as the output of that command. -#ciphers - -# ================================================================= -# Persistence -# ================================================================= - -# If persistence is enabled, save the in-memory database to disk -# every autosave_interval seconds. If set to 0, the persistence -# database will only be written when mosquitto exits. See also -# autosave_on_changes. -# Note that writing of the persistence database can be forced by -# sending mosquitto a SIGUSR1 signal. -#autosave_interval 1800 - -# If true, mosquitto will count the number of subscription changes, retained -# messages received and queued messages and if the total exceeds -# autosave_interval then the in-memory database will be saved to disk. -# If false, mosquitto will save the in-memory database to disk by treating -# autosave_interval as a time in seconds. -#autosave_on_changes false - -# Save persistent message data to disk (true/false). -# This saves information about all messages, including -# subscriptions, currently in-flight messages and retained -# messages. -# retained_persistence is a synonym for this option. -#persistence false - -# The filename to use for the persistent database, not including -# the path. -#persistence_file mosquitto.db - -# Location for persistent database. Must include trailing / -# Default is an empty string (current directory). -# Set to e.g. /var/lib/mosquitto/ if running as a proper service on Linux or -# similar. -#persistence_location - -# ================================================================= -# Logging -# ================================================================= - -# Places to log to. Use multiple log_dest lines for multiple -# logging destinations. -# Possible destinations are: stdout stderr syslog topic file -# -# stdout and stderr log to the console on the named output. -# -# syslog uses the userspace syslog facility which usually ends up -# in /var/log/messages or similar. -# -# topic logs to the broker topic '$SYS/broker/log/', -# where severity is one of D, E, W, N, I, M which are debug, error, -# warning, notice, information and message. Message type severity is used by -# the subscribe/unsubscribe log_types and publishes log messages to -# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe. -# -# The file destination requires an additional parameter which is the file to be -# logged to, e.g. "log_dest file /var/log/mosquitto.log". The file will be -# closed and reopened when the broker receives a HUP signal. Only a single file -# destination may be configured. -# -# Note that if the broker is running as a Windows service it will default to -# "log_dest none" and neither stdout nor stderr logging is available. -# Use "log_dest none" if you wish to disable logging. -log_dest file /var/log/mosquitto.log - -# If using syslog logging (not on Windows), messages will be logged to the -# "daemon" facility by default. Use the log_facility option to choose which of -# local0 to local7 to log to instead. The option value should be an integer -# value, e.g. "log_facility 5" to use local5. -#log_facility - -# Types of messages to log. Use multiple log_type lines for logging -# multiple types of messages. -# Possible types are: debug, error, warning, notice, information, -# none, subscribe, unsubscribe, websockets, all. -# Note that debug type messages are for decoding the incoming/outgoing -# network packets. They are not logged in "topics". -log_type error -log_type warning -log_type notice -log_type information - -# If set to true, client connection and disconnection messages will be included -# in the log. -connection_messages true - -# If set to true, add a timestamp value to each log message. -log_timestamp true - -# ================================================================= -# Security -# ================================================================= - -# If set, only clients that have a matching prefix on their -# clientid will be allowed to connect to the broker. By default, -# all clients may connect. -# For example, setting "secure-" here would mean a client "secure- -# client" could connect but another with clientid "mqtt" couldn't. -#clientid_prefixes - -# Boolean value that determines whether clients that connect -# without providing a username are allowed to connect. If set to -# false then a password file should be created (see the -# password_file option) to control authenticated client access. -# Defaults to true. -#allow_anonymous true - -# In addition to the clientid_prefixes, allow_anonymous and TLS -# authentication options, username based authentication is also -# possible. The default support is described in "Default -# authentication and topic access control" below. The auth_plugin -# allows another authentication method to be used. -# Specify the path to the loadable plugin and see the -# "Authentication and topic access plugin options" section below. -#auth_plugin - -# ----------------------------------------------------------------- -# Default authentication and topic access control -# ----------------------------------------------------------------- - -# Control access to the broker using a password file. This file can be -# generated using the mosquitto_passwd utility. If TLS support is not compiled -# into mosquitto (it is recommended that TLS support should be included) then -# plain text passwords are used, in which case the file should be a text file -# with lines in the format: -# username:password -# The password (and colon) may be omitted if desired, although this -# offers very little in the way of security. -# -# See the TLS client require_certificate and use_identity_as_username options -# for alternative authentication options. -#password_file - -# Access may also be controlled using a pre-shared-key file. This requires -# TLS-PSK support and a listener configured to use it. The file should be text -# lines in the format: -# identity:key -# The key should be in hexadecimal format without a leading "0x". -#psk_file - -# Control access to topics on the broker using an access control list -# file. If this parameter is defined then only the topics listed will -# have access. -# If the first character of a line of the ACL file is a # it is treated as a -# comment. -# Topic access is added with lines of the format: -# -# topic [read|write|readwrite] -# -# The access type is controlled using "read", "write" or "readwrite". This -# parameter is optional (unless contains a space character) - if not -# given then the access is read/write. can contain the + or # -# wildcards as in subscriptions. -# -# The first set of topics are applied to anonymous clients, assuming -# allow_anonymous is true. User specific topic ACLs are added after a -# user line as follows: -# -# user -# -# The username referred to here is the same as in password_file. It is -# not the clientid. -# -# -# If is also possible to define ACLs based on pattern substitution within the -# topic. The patterns available for substition are: -# -# %c to match the client id of the client -# %u to match the username of the client -# -# The substitution pattern must be the only text for that level of hierarchy. -# -# The form is the same as for the topic keyword, but using pattern as the -# keyword. -# Pattern ACLs apply to all users even if the "user" keyword has previously -# been given. -# -# If using bridges with usernames and ACLs, connection messages can be allowed -# with the following pattern: -# pattern write $SYS/broker/connection/%c/state -# -# pattern [read|write|readwrite] -# -# Example: -# -# pattern write sensor/%u/data -# -#acl_file - -# ----------------------------------------------------------------- -# Authentication and topic access plugin options -# ----------------------------------------------------------------- - -# If the auth_plugin option above is used, define options to pass to the -# plugin here as described by the plugin instructions. All options named -# using the format auth_opt_* will be passed to the plugin, for example: -# -# auth_opt_db_host -# auth_opt_db_port -# auth_opt_db_username -# auth_opt_db_password - - -# ================================================================= -# Bridges -# ================================================================= - -# A bridge is a way of connecting multiple MQTT brokers together. -# Create a new bridge using the "connection" option as described below. Set -# options for the bridges using the remaining parameters. You must specify the -# address and at least one topic to subscribe to. -# Each connection must have a unique name. -# The address line may have multiple host address and ports specified. See -# below in the round_robin description for more details on bridge behaviour if -# multiple addresses are used. -# The direction that the topic will be shared can be chosen by -# specifying out, in or both, where the default value is out. -# The QoS level of the bridged communication can be specified with the next -# topic option. The default QoS level is 0, to change the QoS the topic -# direction must also be given. -# The local and remote prefix options allow a topic to be remapped when it is -# bridged to/from the remote broker. This provides the ability to place a topic -# tree in an appropriate location. -# For more details see the mosquitto.conf man page. -# Multiple topics can be specified per connection, but be careful -# not to create any loops. -# If you are using bridges with cleansession set to false (the default), then -# you may get unexpected behaviour from incoming topics if you change what -# topics you are subscribing to. This is because the remote broker keeps the -# subscription for the old topic. If you have this problem, connect your bridge -# with cleansession set to true, then reconnect with cleansession set to false -# as normal. -#connection -#address [:] [[:]] -#topic [[[out | in | both] qos-level] local-prefix remote-prefix] - -# Set the version of the MQTT protocol to use with for this bridge. Can be one -# of mqttv31 or mqttv311. Defaults to mqttv31. -#bridge_protocol_version mqttv31 - -# If a bridge has topics that have "out" direction, the default behaviour is to -# send an unsubscribe request to the remote broker on that topic. This means -# that changing a topic direction from "in" to "out" will not keep receiving -# incoming messages. Sending these unsubscribe requests is not always -# desirable, setting bridge_attempt_unsubscribe to false will disable sending -# the unsubscribe request. -#bridge_attempt_unsubscribe true - -# If the bridge has more than one address given in the address/addresses -# configuration, the round_robin option defines the behaviour of the bridge on -# a failure of the bridge connection. If round_robin is false, the default -# value, then the first address is treated as the main bridge connection. If -# the connection fails, the other secondary addresses will be attempted in -# turn. Whilst connected to a secondary bridge, the bridge will periodically -# attempt to reconnect to the main bridge until successful. -# If round_robin is true, then all addresses are treated as equals. If a -# connection fails, the next address will be tried and if successful will -# remain connected until it fails -#round_robin false - -# Set the client id to use on the remote end of this bridge connection. If not -# defined, this defaults to 'name.hostname' where name is the connection name -# and hostname is the hostname of this computer. -# This replaces the old "clientid" option to avoid confusion. "clientid" -# remains valid for the time being. -#remote_clientid - -# Set the clientid to use on the local broker. If not defined, this defaults to -# 'local.'. If you are bridging a broker to itself, it is important -# that local_clientid and clientid do not match. -#local_clientid - -# Set the clean session variable for this bridge. -# When set to true, when the bridge disconnects for any reason, all -# messages and subscriptions will be cleaned up on the remote -# broker. Note that with cleansession set to true, there may be a -# significant amount of retained messages sent when the bridge -# reconnects after losing its connection. -# When set to false, the subscriptions and messages are kept on the -# remote broker, and delivered when the bridge reconnects. -#cleansession false - -# If set to true, publish notification messages to the local and remote brokers -# giving information about the state of the bridge connection. Retained -# messages are published to the topic $SYS/broker/connection//state -# unless the notification_topic option is used. -# If the message is 1 then the connection is active, or 0 if the connection has -# failed. -#notifications true - -# Choose the topic on which notification messages for this bridge are -# published. If not set, messages are published on the topic -# $SYS/broker/connection//state -#notification_topic - -# Set the keepalive interval for this bridge connection, in -# seconds. -#keepalive_interval 60 - -# Set the start type of the bridge. This controls how the bridge starts and -# can be one of three types: automatic, lazy and once. Note that RSMB provides -# a fourth start type "manual" which isn't currently supported by mosquitto. -# -# "automatic" is the default start type and means that the bridge connection -# will be started automatically when the broker starts and also restarted -# after a short delay (30 seconds) if the connection fails. -# -# Bridges using the "lazy" start type will be started automatically when the -# number of queued messages exceeds the number set with the "threshold" -# parameter. It will be stopped automatically after the time set by the -# "idle_timeout" parameter. Use this start type if you wish the connection to -# only be active when it is needed. -# -# A bridge using the "once" start type will be started automatically when the -# broker starts but will not be restarted if the connection fails. -#start_type automatic - -# Set the amount of time a bridge using the automatic start type will wait -# until attempting to reconnect. Defaults to 30 seconds. -#restart_timeout 30 - -# Set the amount of time a bridge using the lazy start type must be idle before -# it will be stopped. Defaults to 60 seconds. -#idle_timeout 60 - -# Set the number of messages that need to be queued for a bridge with lazy -# start type to be restarted. Defaults to 10 messages. -# Must be less than max_queued_messages. -#threshold 10 - -# If try_private is set to true, the bridge will attempt to indicate to the -# remote broker that it is a bridge not an ordinary client. If successful, this -# means that loop detection will be more effective and that retained messages -# will be propagated correctly. Not all brokers support this feature so it may -# be necessary to set try_private to false if your bridge does not connect -# properly. -#try_private true - -# Set the username to use when connecting to a broker that requires -# authentication. -# This replaces the old "username" option to avoid confusion. "username" -# remains valid for the time being. -#remote_username - -# Set the password to use when connecting to a broker that requires -# authentication. This option is only used if remote_username is also set. -# This replaces the old "password" option to avoid confusion. "password" -# remains valid for the time being. -#remote_password - -# ----------------------------------------------------------------- -# Certificate based SSL/TLS support -# ----------------------------------------------------------------- -# Either bridge_cafile or bridge_capath must be defined to enable TLS support -# for this bridge. -# bridge_cafile defines the path to a file containing the -# Certificate Authority certificates that have signed the remote broker -# certificate. -# bridge_capath defines a directory that will be searched for files containing -# the CA certificates. For bridge_capath to work correctly, the certificate -# files must have ".crt" as the file ending and you must run "c_rehash " each time you add/remove a certificate. -#bridge_cafile -#bridge_capath - -# Path to the PEM encoded client certificate, if required by the remote broker. -#bridge_certfile - -# Path to the PEM encoded client private key, if required by the remote broker. -#bridge_keyfile - -# When using certificate based encryption, bridge_insecure disables -# verification of the server hostname in the server certificate. This can be -# useful when testing initial server configurations, but makes it possible for -# a malicious third party to impersonate your server through DNS spoofing, for -# example. Use this option in testing only. If you need to resort to using this -# option in a production environment, your setup is at fault and there is no -# point using encryption. -#bridge_insecure false - -# ----------------------------------------------------------------- -# PSK based SSL/TLS support -# ----------------------------------------------------------------- -# Pre-shared-key encryption provides an alternative to certificate based -# encryption. A bridge can be configured to use PSK with the bridge_identity -# and bridge_psk options. These are the client PSK identity, and pre-shared-key -# in hexadecimal format with no "0x". Only one of certificate and PSK based -# encryption can be used on one -# bridge at once. -#bridge_identity -#bridge_psk - - -# ================================================================= -# External config files -# ================================================================= - -# External configuration files may be included by using the -# include_dir option. This defines a directory that will be searched -# for config files. All files that end in '.conf' will be loaded as -# a configuration file. It is best to have this as the last option -# in the main file. This option will only be processed from the main -# configuration file. The directory specified must not contain the -# main configuration file. -#include_dir - -# ================================================================= -# rsmb options - unlikely to ever be supported -# ================================================================= - -#ffdc_output -#max_log_entries -#trace_level -#trace_output diff --git a/recipes-connectivity/mosquitto/mosquitto/mosquitto.default b/recipes-connectivity/mosquitto/mosquitto/mosquitto.default deleted file mode 100644 index be7dcd5..0000000 --- a/recipes-connectivity/mosquitto/mosquitto/mosquitto.default +++ /dev/null @@ -1,2 +0,0 @@ -# set to "yes" or "no" to control starting on boot -ENABLED="yes" diff --git a/recipes-connectivity/mosquitto/mosquitto/mosquitto.init b/recipes-connectivity/mosquitto/mosquitto/mosquitto.init deleted file mode 100755 index 7b3e634..0000000 --- a/recipes-connectivity/mosquitto/mosquitto/mosquitto.init +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/sh -# -# mosquitto Starts and stops Mosquitto -# mosquitto (MQTT 3.5 broker) -# -# chkconfig: - 58 74 -# description: mosquitto is a MQTT 3.5 broker. \ -# http://mosquitto.org/ - -### BEGIN INIT INFO -# Provides: mosquitto -# Required-Start: $network $local_fs -# Required-Stop: $network $local_fs -# Should-Start: $syslog $named -# Should-Stop: $syslog $named -# Short-Description: start and stop mosquitto -# Description: mosquitto is a MQTT 3.5 broker. -### END INIT INFO - -PIDFILE=/var/run/mosquitto.pid -DAEMON=/usr/sbin/mosquitto -ENABLED="yes" - -[ -f /etc/default/mosquitto ] && . /etc/default/mosquitto - -start() { - echo "Starting Mosquitto..." - start-stop-daemon --start --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON -- -d -c /etc/mosquitto/mosquitto.conf -} - -stop() { - echo "Stopping Mosquitto..." - start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE -} - -[ "$ENABLED" = "yes" ] || exit - -case "$1" in - start) - start - ;; - stop) - stop - ;; - restart) - stop - start - ;; - *) - echo $"Usage: $0 {start|stop|restart}" - exit 2 -esac - diff --git a/recipes-connectivity/mosquitto/mosquitto/mosquitto.logrotate.conf b/recipes-connectivity/mosquitto/mosquitto/mosquitto.logrotate.conf deleted file mode 100644 index 5f4779b..0000000 --- a/recipes-connectivity/mosquitto/mosquitto/mosquitto.logrotate.conf +++ /dev/null @@ -1,7 +0,0 @@ -/var/log/mosquitto.log { - size 512k - rotate 4 - compress - copytruncate - missingok -} diff --git a/recipes-connectivity/mosquitto/mosquitto/nostrip.patch b/recipes-connectivity/mosquitto/mosquitto/nostrip.patch deleted file mode 100644 index b36be35..0000000 --- a/recipes-connectivity/mosquitto/mosquitto/nostrip.patch +++ /dev/null @@ -1,58 +0,0 @@ -Index: mosquitto-1.4/client/Makefile -=================================================================== ---- mosquitto-1.4.orig/client/Makefile 2015-02-17 19:44:09.000000000 -0600 -+++ mosquitto-1.4/client/Makefile 2015-03-25 11:34:01.388614891 -0500 -@@ -24,8 +24,8 @@ - - install : all - $(INSTALL) -d ${DESTDIR}$(prefix)/bin -- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto_pub ${DESTDIR}${prefix}/bin/mosquitto_pub -- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto_sub ${DESTDIR}${prefix}/bin/mosquitto_sub -+ $(INSTALL) mosquitto_pub ${DESTDIR}${prefix}/bin/mosquitto_pub -+ $(INSTALL) mosquitto_sub ${DESTDIR}${prefix}/bin/mosquitto_sub - - uninstall : - -rm -f ${DESTDIR}${prefix}/bin/mosquitto_pub -Index: mosquitto-1.4/lib/Makefile -=================================================================== ---- mosquitto-1.4.orig/lib/Makefile 2015-02-17 19:44:09.000000000 -0600 -+++ mosquitto-1.4/lib/Makefile 2015-03-25 11:34:01.388614891 -0500 -@@ -25,7 +25,7 @@ - - install : all - $(INSTALL) -d ${DESTDIR}$(prefix)/lib${LIB_SUFFIX}/ -- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} libmosquitto.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquitto.so.${SOVERSION} -+ $(INSTALL) libmosquitto.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquitto.so.${SOVERSION} - ln -sf libmosquitto.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquitto.so - $(INSTALL) -d ${DESTDIR}${prefix}/include/ - $(INSTALL) mosquitto.h ${DESTDIR}${prefix}/include/mosquitto.h -Index: mosquitto-1.4/src/Makefile -=================================================================== ---- mosquitto-1.4.orig/src/Makefile 2015-02-17 19:44:09.000000000 -0600 -+++ mosquitto-1.4/src/Makefile 2015-03-25 11:34:01.388614891 -0500 -@@ -103,10 +103,10 @@ - - install : all - $(INSTALL) -d ${DESTDIR}$(prefix)/sbin -- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto ${DESTDIR}${prefix}/sbin/mosquitto -+ $(INSTALL) mosquitto ${DESTDIR}${prefix}/sbin/mosquitto - $(INSTALL) mosquitto_plugin.h ${DESTDIR}${prefix}/include/mosquitto_plugin.h - ifeq ($(WITH_TLS),yes) -- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto_passwd ${DESTDIR}${prefix}/bin/mosquitto_passwd -+ $(INSTALL) mosquitto_passwd ${DESTDIR}${prefix}/bin/mosquitto_passwd - endif - - uninstall : -Index: mosquitto-1.4/lib/cpp/Makefile -=================================================================== ---- mosquitto-1.4.orig/lib/cpp/Makefile 2015-02-17 19:44:09.000000000 -0600 -+++ mosquitto-1.4/lib/cpp/Makefile 2015-03-25 11:34:25.984217051 -0500 -@@ -10,7 +10,7 @@ - - install : all - $(INSTALL) -d ${DESTDIR}$(prefix)/lib${LIB_SUFFIX}/ -- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} libmosquittopp.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquittopp.so.${SOVERSION} -+ $(INSTALL) libmosquittopp.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquittopp.so.${SOVERSION} - ln -sf libmosquittopp.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquittopp.so - $(INSTALL) -d ${DESTDIR}${prefix}/include/ - $(INSTALL) mosquittopp.h ${DESTDIR}${prefix}/include/mosquittopp.h diff --git a/recipes-connectivity/mosquitto/mosquitto_1.5.1.bb b/recipes-connectivity/mosquitto/mosquitto_1.5.1.bb deleted file mode 100644 index 947dcdf..0000000 --- a/recipes-connectivity/mosquitto/mosquitto_1.5.1.bb +++ /dev/null @@ -1,81 +0,0 @@ -# This recipe was a merger of the Multitech Daisy 3.5 Recipe with the -# reciped found at: -# http://git.yoctoproject.org/cgit/cgit.cgi/meta-intel-iot-middleware/plain/recipes-connectivity/mosquitto/mosquitto_1.4.10.bb -inherit autotools-brokensep -SUMMARY = "Open source MQTT v3.5 implemention" -DESCRIPTION = "Mosquitto is an open source (BSD licensed) message broker that implements the MQ Telemetry Transport protocol version 3.5. MQTT provides a lightweight method of carrying out messaging using a publish/subscribe model. " -HOMEPAGE = "http://mosquitto.org/" -SECTION = "console/network" -LICENSE = "EPL-1.0 & EDL-1.0" -LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=62ddc846179e908dc0c8efec4a42ef20" - -# util-linux is needed to provide libuuid dependancy -DEPENDS = "c-ares openssl util-linux" - -PR = "r3" - -SRC_URI = "http://mosquitto.org/files/source/${PN}-${PV}.tar.gz \ - file://mosquitto.init \ - file://mosquitto.conf \ - file://mosquitto.default \ - file://mosquitto.logrotate.conf \ - file://config_mk.patch \ - " -SRC_URI[md5sum] = "f98c99998a36a234f3a9d9b402b991db" -SRC_URI[sha256sum] = "8557bc7ae34dfaf32a0fb56d2491b7a7f731269c88337227233013502df4d5b0" - -export LIB_SUFFIX="${@d.getVar('baselib', True).replace('lib', '')}" -inherit autotools update-rc.d - -INITSCRIPT_NAME = "mosquitto" -INITSCRIPT_PARAMS = "defaults 70 30" -do_compile() { - WITH_STATIC_LIBRARIES=1 oe_runmake PREFIX=/usr WITH_STATIC_LIBRARIES=1 -} -do_install() { - # oe_runmake DESTDIR=${D} prefix=/usr install - oe_runmake install DESTDIR=${D} - install -m 0755 -d ${D}/usr/lib - install -m 0644 lib/libmosquitto.a ${D}${libdir}/ - - install -d ${D}${sysconfdir}/init.d - install -d ${D}${sysconfdir}/default - install -m 0755 ${WORKDIR}/mosquitto.init ${D}${sysconfdir}/init.d/mosquitto - install -m 0644 ${WORKDIR}/mosquitto.conf ${D}${sysconfdir}/mosquitto/ - install -m 0644 ${WORKDIR}/mosquitto.default ${D}${sysconfdir}/default/mosquitto - - install -d ${D}${sysconfdir}/logrotate.d - install -m 0644 ${WORKDIR}/mosquitto.logrotate.conf ${D}${sysconfdir}/logrotate.d/mosquitto.conf -} - -do_rm_work() { - echo "skipping" -} - - -PACKAGES += "libmosquitto1 libmosquittopp1 ${PN}-clients ${PN}-python" - -CONFFILES_${PN} = "${sysconfdir}/mosquitto.conf ${sysconfdir}/default/mosquitto" -FILES_${PN} = "${sbindir}/mosquitto \ - ${bindir}/mosquitto_passwd \ - ${sysconfdir}/mosquitto \ - ${systemd_unitdir}/system/mosquitto.service \ - ${sysconfdir}/ \ -" - -FILES_libmosquitto1 = "${libdir}/libmosquitto.so.1" - -FILES_libmosquittopp1 = "${libdir}/libmosquittopp.so.1" - -FILES_${PN}-clients = "${bindir}/mosquitto_pub \ - ${bindir}/mosquitto_sub \ -" - -FILES_${PN}-staticdev += "${libdir}/libmosquitto.a" - -FILES_${PN}-python = "/usr/lib/python2.7/site-packages" - -inherit systemd - -SYSTEMD_SERVICE_${PN} = "mosquitto.service" - diff --git a/recipes-connectivity/openssh/openssh/fix-potential-signed-overflow-in-pointer-arithmatic.patch b/recipes-connectivity/openssh/openssh/fix-potential-signed-overflow-in-pointer-arithmatic.patch deleted file mode 100644 index 7e043a2..0000000 --- a/recipes-connectivity/openssh/openssh/fix-potential-signed-overflow-in-pointer-arithmatic.patch +++ /dev/null @@ -1,99 +0,0 @@ -From 3328e98bcbf2930cd7eea3e6c92ad5dcbdf4794f Mon Sep 17 00:00:00 2001 -From: Yuanjie Huang -Date: Wed, 24 Aug 2016 03:15:43 +0000 -Subject: [PATCH] Fix potential signed overflow in pointer arithmatic - -Pointer arithmatic results in implementation defined signed integer -type, so that 's - src' in strlcpy and others may trigger signed overflow. -In case of compilation by gcc or clang with -ftrapv option, the overflow -would lead to program abort. - -Upstream-Status: Submitted [http://bugzilla.mindrot.org/show_bug.cgi?id=2608] - -Signed-off-by: Yuanjie Huang ---- - openbsd-compat/strlcat.c | 8 ++++++-- - openbsd-compat/strlcpy.c | 8 ++++++-- - openbsd-compat/strnlen.c | 8 ++++++-- - 3 files changed, 18 insertions(+), 6 deletions(-) - -diff --git a/openbsd-compat/strlcat.c b/openbsd-compat/strlcat.c -index bcc1b61..e758ebf 100644 ---- a/openbsd-compat/strlcat.c -+++ b/openbsd-compat/strlcat.c -@@ -23,6 +23,7 @@ - - #include - #include -+#include - - /* - * Appends src to string dst of size siz (unlike strncat, siz is the -@@ -55,8 +56,11 @@ strlcat(char *dst, const char *src, size_t siz) - s++; - } - *d = '\0'; -- -- return(dlen + (s - src)); /* count does not include NUL */ -+ /* -+ * Cast pointers to unsigned type before calculation, to avoid signed -+ * overflow when the string ends where the MSB has changed. -+ */ -+ return (dlen + ((uintptr_t)s - (uintptr_t)src)); /* count does not include NUL */ - } - - #endif /* !HAVE_STRLCAT */ -diff --git a/openbsd-compat/strlcpy.c b/openbsd-compat/strlcpy.c -index b4b1b60..b06f374 100644 ---- a/openbsd-compat/strlcpy.c -+++ b/openbsd-compat/strlcpy.c -@@ -23,6 +23,7 @@ - - #include - #include -+#include - - /* - * Copy src to string dst of size siz. At most siz-1 characters -@@ -51,8 +52,11 @@ strlcpy(char *dst, const char *src, size_t siz) - while (*s++) - ; - } -- -- return(s - src - 1); /* count does not include NUL */ -+ /* -+ * Cast pointers to unsigned type before calculation, to avoid signed -+ * overflow when the string ends where the MSB has changed. -+ */ -+ return ((uintptr_t)s - (uintptr_t)src - 1); /* count does not include NUL */ - } - - #endif /* !HAVE_STRLCPY */ -diff --git a/openbsd-compat/strnlen.c b/openbsd-compat/strnlen.c -index 93d5155..9b8de5d 100644 ---- a/openbsd-compat/strnlen.c -+++ b/openbsd-compat/strnlen.c -@@ -23,6 +23,7 @@ - #include - - #include -+#include - - size_t - strnlen(const char *str, size_t maxlen) -@@ -31,7 +32,10 @@ strnlen(const char *str, size_t maxlen) - - for (cp = str; maxlen != 0 && *cp != '\0'; cp++, maxlen--) - ; -- -- return (size_t)(cp - str); -+ /* -+ * Cast pointers to unsigned type before calculation, to avoid signed -+ * overflow when the string ends where the MSB has changed. -+ */ -+ return (size_t)((uintptr_t)cp - (uintptr_t)str); - } - #endif --- -1.9.1 - diff --git a/recipes-connectivity/openssh/openssh/init b/recipes-connectivity/openssh/openssh/init deleted file mode 100644 index 386628a..0000000 --- a/recipes-connectivity/openssh/openssh/init +++ /dev/null @@ -1,153 +0,0 @@ -#! /bin/sh -set -e - -PIDFILE=/var/run/sshd.pid - -# source function library -. /etc/init.d/functions - -# /etc/init.d/ssh: start and stop the OpenBSD "secure shell" daemon - -test -x /usr/sbin/sshd || exit 0 -( /usr/sbin/sshd -\? 2>&1 | grep -q OpenSSH ) 2>/dev/null || exit 0 - -# /etc/default/ssh may set SYSCONFDIR and SSHD_OPTS -if test -f /etc/default/ssh; then - . /etc/default/ssh -fi - -[ -z "$SYSCONFDIR" ] && SYSCONFDIR=/etc/ssh -mkdir -p $SYSCONFDIR - -parse_sshd_opts() { - set -- ${SSHD_OPTS} -- - sshd_config=/etc/ssh/sshd_config - while true ; do - case "$1" in - -f*) if [ "$1" = "-f" ] ; then - sshd_config="$2" - shift - else - sshd_config="${1#-f}" - fi - shift - ;; - --) shift; break;; - *) shift;; - esac - done -} - -check_for_no_start() { - # forget it if we're trying to start, and /etc/ssh/sshd_not_to_be_run exists - if [ -e $SYSCONFDIR/sshd_not_to_be_run ]; then - echo "OpenBSD Secure Shell server not in use ($SYSCONFDIR/sshd_not_to_be_run)" - exit 0 - fi -} - -check_privsep_dir() { - # Create the PrivSep empty dir if necessary - if [ ! -d /var/run/sshd ]; then - mkdir /var/run/sshd - chmod 0755 /var/run/sshd - fi -} - -check_config() { - /usr/sbin/sshd -t $SSHD_OPTS || exit 1 -} - -check_keys() { - # parse location of keys - local HOST_KEY_RSA - local HOST_KEY_DSA - local HOST_KEY_ECDSA - local HOST_KEY_ED25519 - - parse_sshd_opts - HOST_KEY_RSA=$(grep ^HostKey "${sshd_config}" | grep _rsa_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_RSA}" ] && HOST_KEY_RSA=$(grep HostKey "${sshd_config}" | grep _rsa_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_RSA}" ] && HOST_KEY_RSA=$SYSCONFDIR/ssh_host_rsa_key - HOST_KEY_DSA=$(grep ^HostKey "${sshd_config}" | grep _dsa_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_DSA}" ] && HOST_KEY_DSA=$(grep HostKey "${sshd_config}" | grep _dsa_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_DSA}" ] && HOST_KEY_DSA=$SYSCONFDIR/ssh_host_dsa_key - HOST_KEY_ECDSA=$(grep ^HostKey "${sshd_config}" | grep _ecdsa_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_ECDSA}" ] && HOST_KEY_ECDSA=$(grep HostKey "${sshd_config}" | grep _ecdsa_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_ECDSA}" ] && HOST_KEY_ECDSA=$SYSCONFDIR/ssh_host_ecdsa_key - HOST_KEY_ED25519=$(grep ^HostKey "${sshd_config}" | grep _ed25519_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_ED25519}" ] && HOST_KEY_ED25519=$(grep HostKey "${sshd_config}" | grep _ed25519_ | tail -1 | awk ' { print $2 } ') - [ -z "${HOST_KEY_ED25519}" ] && HOST_KEY_ED25519=$SYSCONFDIR/ssh_host_ed25519_key - - # create keys if necessary - if [ ! -f $HOST_KEY_RSA ]; then - echo " generating ssh RSA key..." - mkdir -p $(dirname $HOST_KEY_RSA) - ssh-keygen -q -f $HOST_KEY_RSA -N '' -t rsa - fi - if [ ! -f $HOST_KEY_ECDSA ]; then - echo " generating ssh ECDSA key..." - mkdir -p $(dirname $HOST_KEY_ECDSA) - ssh-keygen -q -f $HOST_KEY_ECDSA -N '' -t ecdsa - fi - if [ ! -f $HOST_KEY_DSA ]; then - echo " generating ssh DSA key..." - mkdir -p $(dirname $HOST_KEY_DSA) - ssh-keygen -q -f $HOST_KEY_DSA -N '' -t dsa - fi - if [ ! -f $HOST_KEY_ED25519 ]; then - echo " generating ssh ED25519 key..." - mkdir -p $(dirname $HOST_KEY_ED25519) - ssh-keygen -q -f $HOST_KEY_ED25519 -N '' -t ed25519 - fi -} - -export PATH="${PATH:+$PATH:}/usr/sbin:/sbin" - -case "$1" in - start) - check_for_no_start - echo "Starting OpenBSD Secure Shell server: sshd" - check_keys - check_privsep_dir - start-stop-daemon -S -p $PIDFILE -x /usr/sbin/sshd -- $SSHD_OPTS - echo "done." - ;; - stop) - echo -n "Stopping OpenBSD Secure Shell server: sshd" - start-stop-daemon -K -p $PIDFILE -x /usr/sbin/sshd - echo "." - ;; - - reload|force-reload) - check_for_no_start - check_keys - check_config - echo -n "Reloading OpenBSD Secure Shell server's configuration" - start-stop-daemon -K -p $PIDFILE -s 1 -x /usr/sbin/sshd - echo "." - ;; - - restart) - check_keys - check_config - echo -n "Restarting OpenBSD Secure Shell server: sshd" - start-stop-daemon -K -p $PIDFILE --oknodo -x /usr/sbin/sshd - check_for_no_start - check_privsep_dir - sleep 2 - start-stop-daemon -S -p $PIDFILE -x /usr/sbin/sshd -- $SSHD_OPTS - echo "." - ;; - - status) - status /usr/sbin/sshd - exit $? - ;; - - *) - echo "Usage: /etc/init.d/ssh {start|stop|status|reload|force-reload|restart}" - exit 1 -esac - -exit 0 diff --git a/recipes-connectivity/openssh/openssh/openssh-8.1p1-add-test-support-for-busybox.patch b/recipes-connectivity/openssh/openssh/openssh-8.1p1-add-test-support-for-busybox.patch deleted file mode 100644 index d6fbd3b..0000000 --- a/recipes-connectivity/openssh/openssh/openssh-8.1p1-add-test-support-for-busybox.patch +++ /dev/null @@ -1,48 +0,0 @@ -diff -ruN a/regress/cipher-speed.sh b/regress/cipher-speed.sh ---- a/regress/cipher-speed.sh 2019-12-03 13:16:36.091896387 -0600 -+++ b/regress/cipher-speed.sh 2019-12-03 13:28:29.726275955 -0600 -@@ -17,7 +17,7 @@ - printf "%-60s" "$c/$m:" - ( ${SSH} -o 'compression no' \ - -F $OBJ/ssh_proxy -m $m -c $c somehost \ -- exec sh -c \'"dd of=/dev/null obs=32k"\' \ -+ exec sh -c \'"dd of=/dev/null bs=32k"\' \ - < ${DATA} ) 2>&1 | getbytes - - if [ $? -ne 0 ]; then -diff -ruN a/regress/key-options.sh b/regress/key-options.sh ---- a/regress/key-options.sh 2019-12-03 13:24:44.164243780 -0600 -+++ b/regress/key-options.sh 2019-12-03 13:33:14.447235791 -0600 -@@ -84,7 +84,7 @@ - fi - - sed 's/.*/from="'"$f"'" &/' $origkeys >$authkeys -- from=`head -1 $authkeys | cut -f1 -d ' '` -+ from=`head -n 1 $authkeys | cut -f1 -d ' '` - verbose "key option $from" - r=`${SSH} -q -F $OBJ/ssh_proxy somehost 'echo true'` - if [ "$r" = "true" ]; then -diff -ruN a/regress/transfer.sh b/regress/transfer.sh ---- a/regress/transfer.sh 2019-12-03 13:16:58.342857354 -0600 -+++ b/regress/transfer.sh 2019-12-03 13:29:08.733267753 -0600 -@@ -13,7 +13,7 @@ - for s in 10 100 1k 32k 64k 128k 256k; do - trace "dd-size ${s}" - rm -f ${COPY} -- dd if=$DATA obs=${s} 2> /dev/null | \ -+ dd if=$DATA bs=${s} 2> /dev/null | \ - ${SSH} -q -F $OBJ/ssh_proxy somehost "cat > ${COPY}" - if [ $? -ne 0 ]; then - fail "ssh cat $DATA failed" -diff -ruN a/regress/yes-head.sh b/regress/yes-head.sh ---- a/regress/yes-head.sh 2019-12-03 13:17:11.682259074 -0600 -+++ b/regress/yes-head.sh 2019-12-03 13:32:47.699869866 -0600 -@@ -3,7 +3,7 @@ - - tid="yes pipe head" - --lines=`${SSH} -F $OBJ/ssh_proxy thishost 'sh -c "while true;do echo yes;done | _POSIX2_VERSION=199209 head -2000"' | (sleep 3 ; wc -l)` -+lines=`${SSH} -F $OBJ/ssh_proxy thishost 'sh -c "while true;do echo yes;done | _POSIX2_VERSION=199209 head -n 2000"' | (sleep 3 ; wc -l)` - if [ $? -ne 0 ]; then - fail "yes|head test failed" - lines = 0; diff --git a/recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-cipher.patch b/recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-cipher.patch deleted file mode 100644 index 507026c..0000000 --- a/recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-cipher.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- a/cipher.c 2019-12-03 12:46:22.282290586 -0600 -+++ b/cipher.c 2019-12-03 12:45:19.273805437 -0600 -@@ -158,8 +158,10 @@ - u_int - cipher_seclen(const struct sshcipher *c) - { -+#ifndef OPENSSL_NO_DES - if (strcmp("3des-cbc", c->name) == 0) - return 14; -+#endif - return cipher_keylen(c); - } - diff --git a/recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-pkcs11.patch b/recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-pkcs11.patch deleted file mode 100644 index 46b60b5..0000000 --- a/recipes-connectivity/openssh/openssh/openssh-8.1p1-conditional-compile-des-in-pkcs11.patch +++ /dev/null @@ -1,52 +0,0 @@ ---- a/pkcs11.h 2019-12-03 12:52:10.920974412 -0600 -+++ b/pkcs11.h 2019-12-03 12:56:56.383171416 -0600 -@@ -342,9 +342,11 @@ - #define CKK_GENERIC_SECRET (0x10) - #define CKK_RC2 (0x11) - #define CKK_RC4 (0x12) -+#ifndef OPENSSL_NO_DES - #define CKK_DES (0x13) - #define CKK_DES2 (0x14) - #define CKK_DES3 (0x15) -+#endif /* OPENSSL_NO_DES */ - #define CKK_CAST (0x16) - #define CKK_CAST3 (0x17) - #define CKK_CAST128 (0x18) -@@ -512,6 +514,7 @@ - #define CKM_RC2_CBC_PAD (0x105) - #define CKM_RC4_KEY_GEN (0x110) - #define CKM_RC4 (0x111) -+#ifndef OPENSSL_NO_DES - #define CKM_DES_KEY_GEN (0x120) - #define CKM_DES_ECB (0x121) - #define CKM_DES_CBC (0x122) -@@ -525,6 +528,7 @@ - #define CKM_DES3_MAC (0x134) - #define CKM_DES3_MAC_GENERAL (0x135) - #define CKM_DES3_CBC_PAD (0x136) -+#endif /* OPENSSL_NO_DES */ - #define CKM_CDMF_KEY_GEN (0x140) - #define CKM_CDMF_ECB (0x141) - #define CKM_CDMF_CBC (0x142) -@@ -610,8 +614,10 @@ - #define CKM_MD5_KEY_DERIVATION (0x390) - #define CKM_MD2_KEY_DERIVATION (0x391) - #define CKM_SHA1_KEY_DERIVATION (0x392) -+#ifndef OPENSSL_NO_DES - #define CKM_PBE_MD2_DES_CBC (0x3a0) - #define CKM_PBE_MD5_DES_CBC (0x3a1) -+#endif /* OPENSSL_NO_DES */ - #define CKM_PBE_MD5_CAST_CBC (0x3a2) - #define CKM_PBE_MD5_CAST3_CBC (0x3a3) - #define CKM_PBE_MD5_CAST5_CBC (0x3a4) -@@ -620,8 +626,10 @@ - #define CKM_PBE_SHA1_CAST128_CBC (0x3a5) - #define CKM_PBE_SHA1_RC4_128 (0x3a6) - #define CKM_PBE_SHA1_RC4_40 (0x3a7) -+#ifndef OPENSSL_NO_DES - #define CKM_PBE_SHA1_DES3_EDE_CBC (0x3a8) - #define CKM_PBE_SHA1_DES2_EDE_CBC (0x3a9) -+#endif /* OPENSSL_NO_DES */ - #define CKM_PBE_SHA1_RC2_128_CBC (0x3aa) - #define CKM_PBE_SHA1_RC2_40_CBC (0x3ab) - #define CKM_PKCS5_PBKD2 (0x3b0) diff --git a/recipes-connectivity/openssh/openssh/run-ptest b/recipes-connectivity/openssh/openssh/run-ptest deleted file mode 100755 index 36a3d2a..0000000 --- a/recipes-connectivity/openssh/openssh/run-ptest +++ /dev/null @@ -1,44 +0,0 @@ -#!/bin/sh - -export TEST_SHELL=sh - -cd regress -sed -i "/\t\tagent-ptrace /d" Makefile -make -k .OBJDIR=`pwd` .CURDIR=`pwd` SUDO="sudo" tests \ - | sed -e 's/^skipped/SKIP: /g' -e 's/^ok /PASS: /g' -e 's/^failed/FAIL: /g' - -SSHAGENT=`which ssh-agent` -GDB=`which gdb` - -if [ -z "${SSHAGENT}" -o -z "${GDB}" ]; then - echo "SKIP: agent-ptrace" - exit -fi - -useradd openssh-test - -eval `su -c "${SSHAGENT} -s" openssh-test` > /dev/null -r=$? -if [ $r -ne 0 ]; then - echo "FAIL: could not start ssh-agent: exit code $r" -else - su -c "gdb -p ${SSH_AGENT_PID}" openssh-test > /tmp/gdb.out 2>&1 << EOF - quit -EOF - r=$? - if [ $r -ne 0 ]; then - echo "gdb failed: exit code $r" - fi - egrep 'ptrace: Operation not permitted.|procfs:.*Permission denied.|ttrace.*Permission denied.|procfs:.*: Invalid argument.|Unable to access task ' >/dev/null /tmp/gdb.out - r=$? - rm -f /tmp/gdb.out - if [ $r -ne 0 ]; then - echo "FAIL: ptrace agent" - else - echo "PASS: ptrace agent" - fi - - ${SSHAGENT} -k > /dev/null -fi -userdel openssh-test - diff --git a/recipes-connectivity/openssh/openssh/ssh.default b/recipes-connectivity/openssh/openssh/ssh.default deleted file mode 100644 index d5c0507..0000000 --- a/recipes-connectivity/openssh/openssh/ssh.default +++ /dev/null @@ -1,2 +0,0 @@ -# put keys here -SYSCONFDIR=/var/config/ssh diff --git a/recipes-connectivity/openssh/openssh/ssh_config b/recipes-connectivity/openssh/openssh/ssh_config deleted file mode 100644 index 9e91915..0000000 --- a/recipes-connectivity/openssh/openssh/ssh_config +++ /dev/null @@ -1,48 +0,0 @@ -# $OpenBSD: ssh_config,v 1.28 2013/09/16 11:35:43 sthen Exp $ - -# This is the ssh client system-wide configuration file. See -# ssh_config(5) for more information. This file provides defaults for -# users, and the values can be changed in per-user configuration files -# or on the command line. - -# Configuration data is parsed as follows: -# 1. command line options -# 2. user-specific file -# 3. system-wide file -# Any configuration value is only changed the first time it is set. -# Thus, host-specific definitions should be at the beginning of the -# configuration file, and defaults at the end. - -# Site-wide defaults for some commonly used options. For a comprehensive -# list of available options, their meanings and defaults, please see the -# ssh_config(5) man page. - -Host * - ForwardAgent yes - ForwardX11 yes -# RhostsRSAAuthentication no -# RSAAuthentication yes -# PasswordAuthentication yes -# HostbasedAuthentication no -# GSSAPIAuthentication no -# GSSAPIDelegateCredentials no -# BatchMode no -# CheckHostIP yes -# AddressFamily any -# ConnectTimeout 0 -# StrictHostKeyChecking ask -# IdentityFile ~/.ssh/identity -# IdentityFile ~/.ssh/id_rsa -# IdentityFile ~/.ssh/id_dsa -# Port 22 -# Protocol 2,1 -# Cipher 3des -# Ciphers aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc -# MACs hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160 -# EscapeChar ~ -# Tunnel no -# TunnelDevice any:any -# PermitLocalCommand no -# VisualHostKey no -# ProxyCommand ssh -q -W %h:%p gateway.example.com -# RekeyLimit 1G 1h diff --git a/recipes-connectivity/openssh/openssh/sshd b/recipes-connectivity/openssh/openssh/sshd deleted file mode 100644 index 182650b..0000000 --- a/recipes-connectivity/openssh/openssh/sshd +++ /dev/null @@ -1,11 +0,0 @@ -#%PAM-1.0 - -auth include common-auth -account required pam_nologin.so -account include common-account -password include common-password -session optional pam_keyinit.so force revoke -session optional pam_radauth.so -session include common-session -session required pam_loginuid.so - diff --git a/recipes-connectivity/openssh/openssh/sshd.socket b/recipes-connectivity/openssh/openssh/sshd.socket deleted file mode 100644 index 12c39b2..0000000 --- a/recipes-connectivity/openssh/openssh/sshd.socket +++ /dev/null @@ -1,10 +0,0 @@ -[Unit] -Conflicts=sshd.service - -[Socket] -ExecStartPre=@BASE_BINDIR@/mkdir -p /var/run/sshd -ListenStream=22 -Accept=yes - -[Install] -WantedBy=sockets.target diff --git a/recipes-connectivity/openssh/openssh/sshd@.service b/recipes-connectivity/openssh/openssh/sshd@.service deleted file mode 100644 index 9d83dfb..0000000 --- a/recipes-connectivity/openssh/openssh/sshd@.service +++ /dev/null @@ -1,13 +0,0 @@ -[Unit] -Description=OpenSSH Per-Connection Daemon -Wants=sshdgenkeys.service -After=sshdgenkeys.service - -[Service] -Environment="SSHD_OPTS=" -EnvironmentFile=-/etc/default/ssh -ExecStart=-@SBINDIR@/sshd -i $SSHD_OPTS -ExecReload=@BASE_BINDIR@/kill -HUP $MAINPID -StandardInput=socket -StandardError=syslog -KillMode=process diff --git a/recipes-connectivity/openssh/openssh/sshd_config b/recipes-connectivity/openssh/openssh/sshd_config deleted file mode 100644 index 31fe5d9..0000000 --- a/recipes-connectivity/openssh/openssh/sshd_config +++ /dev/null @@ -1,132 +0,0 @@ -# $OpenBSD: sshd_config,v 1.80 2008/07/02 02:24:18 djm Exp $ - -# This is the sshd server system-wide configuration file. See -# sshd_config(5) for more information. - -# This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin - -# The strategy used for options in the default sshd_config shipped with -# OpenSSH is to specify options with their default value where -# possible, but leave them commented. Uncommented options change a -# default value. - -#Port 22 -#AddressFamily any -#ListenAddress 0.0.0.0 -#ListenAddress :: - -# The default requires explicit activation of protocol 1 -Protocol 2 - -# HostKey for protocol version 1 -#HostKey /etc/ssh/ssh_host_key -# HostKeys for protocol version 2 -#HostKey /etc/ssh/ssh_host_rsa_key -#HostKey /etc/ssh/ssh_host_dsa_key -#HostKey /etc/ssh/ssh_host_ecdsa_key -#HostKey /etc/ssh/ssh_host_ed25519_key - -# Lifetime and size of ephemeral version 1 server key -#KeyRegenerationInterval 1h -#ServerKeyBits 1024 - -# Ciphers and keying -#RekeyLimit default none - -# Logging -# obsoletes QuietMode and FascistLogging -#SyslogFacility AUTH -#LogLevel INFO - -# Authentication: - -#LoginGraceTime 2m -#PermitRootLogin yes -#StrictModes yes -#MaxAuthTries 6 -#MaxSessions 10 - -#RSAAuthentication yes -#PubkeyAuthentication yes - -# The default is to check both .ssh/authorized_keys and .ssh/authorized_keys2 -# but this is overridden so installations will only check .ssh/authorized_keys -AuthorizedKeysFile .ssh/authorized_keys - -#AuthorizedPrincipalsFile none - -#AuthorizedKeysCommand none -#AuthorizedKeysCommandUser nobody - -# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts -#RhostsRSAAuthentication no -# similar for protocol version 2 -#HostbasedAuthentication no -# Change to yes if you don't trust ~/.ssh/known_hosts for -# RhostsRSAAuthentication and HostbasedAuthentication -#IgnoreUserKnownHosts no -# Don't read the user's ~/.rhosts and ~/.shosts files -#IgnoreRhosts yes - -# To disable tunneled clear text passwords, change to no here! -#PasswordAuthentication yes -#PermitEmptyPasswords no - -# Change to no to disable s/key passwords -ChallengeResponseAuthentication no - -# Kerberos options -#KerberosAuthentication no -#KerberosOrLocalPasswd yes -#KerberosTicketCleanup yes -#KerberosGetAFSToken no - -# GSSAPI options -#GSSAPIAuthentication no -#GSSAPICleanupCredentials yes - -# Set this to 'yes' to enable PAM authentication, account processing, -# and session processing. If this is enabled, PAM authentication will -# be allowed through the ChallengeResponseAuthentication and -# PasswordAuthentication. Depending on your PAM configuration, -# PAM authentication via ChallengeResponseAuthentication may bypass -# the setting of "PermitRootLogin without-password". -# If you just want the PAM account and session checks to run without -# PAM authentication, then enable this but set PasswordAuthentication -# and ChallengeResponseAuthentication to 'no'. -#UsePAM no - -#AllowAgentForwarding yes -#AllowTcpForwarding yes -#GatewayPorts no -#X11Forwarding no -#X11DisplayOffset 10 -#X11UseLocalhost yes -#PermitTTY yes -#PrintMotd yes -#PrintLastLog yes -#TCPKeepAlive yes -#UseLogin no -#PermitUserEnvironment no -Compression no -ClientAliveInterval 15 -ClientAliveCountMax 4 -#UseDNS yes -#PidFile /var/run/sshd.pid -#MaxStartups 10:30:100 -#PermitTunnel no -#ChrootDirectory none -#VersionAddendum none - -# no default banner path -#Banner none - -# override default of no subsystems -Subsystem sftp /usr/libexec/sftp-server - -# Example of overriding settings on a per-user basis -#Match User anoncvs -# X11Forwarding no -# AllowTcpForwarding no -# PermitTTY no -# ForceCommand cvs server diff --git a/recipes-connectivity/openssh/openssh/sshdgenkeys.service b/recipes-connectivity/openssh/openssh/sshdgenkeys.service deleted file mode 100644 index 148e6ad..0000000 --- a/recipes-connectivity/openssh/openssh/sshdgenkeys.service +++ /dev/null @@ -1,22 +0,0 @@ -[Unit] -Description=OpenSSH Key Generation -RequiresMountsFor=/var /run -ConditionPathExists=!/var/run/ssh/ssh_host_rsa_key -ConditionPathExists=!/var/run/ssh/ssh_host_dsa_key -ConditionPathExists=!/var/run/ssh/ssh_host_ecdsa_key -ConditionPathExists=!/var/run/ssh/ssh_host_ed25519_key -ConditionPathExists=!/etc/ssh/ssh_host_rsa_key -ConditionPathExists=!/etc/ssh/ssh_host_dsa_key -ConditionPathExists=!/etc/ssh/ssh_host_ecdsa_key -ConditionPathExists=!/etc/ssh/ssh_host_ed25519_key - -[Service] -Environment="SYSCONFDIR=/etc/ssh" -EnvironmentFile=-/etc/default/ssh -ExecStart=@BASE_BINDIR@/mkdir -p $SYSCONFDIR -ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_rsa_key -N '' -t rsa -ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_dsa_key -N '' -t dsa -ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_ecdsa_key -N '' -t ecdsa -ExecStart=@BINDIR@/ssh-keygen -q -f ${SYSCONFDIR}/ssh_host_ed25519_key -N '' -t ed25519 -Type=oneshot -RemainAfterExit=yes diff --git a/recipes-connectivity/openssh/openssh/volatiles.99_sshd b/recipes-connectivity/openssh/openssh/volatiles.99_sshd deleted file mode 100644 index a0d2af3..0000000 --- a/recipes-connectivity/openssh/openssh/volatiles.99_sshd +++ /dev/null @@ -1,2 +0,0 @@ -d root root 0755 /var/run/sshd none -f root root 0644 /var/log/lastlog none diff --git a/recipes-connectivity/openssh/openssh_%.bbappend b/recipes-connectivity/openssh/openssh_%.bbappend deleted file mode 100644 index 53d3da1..0000000 --- a/recipes-connectivity/openssh/openssh_%.bbappend +++ /dev/null @@ -1,22 +0,0 @@ -FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" - -SRC_URI += "file://ssh.default" - -KEYFILES = "ssh_host_dsa_key \ -ssh_host_dsa_key.pub \ -ssh_host_ecdsa_key \ -ssh_host_ecdsa_key.pub \ -ssh_host_rsa_key \ -ssh_host_rsa_key.pub \ -ssh_host_ed25519_key \ -ssh_host_ed25519_key.pub \ -" - -do_install_append() { - install -d ${D}${sysconfdir}/default - install -m 644 ${WORKDIR}/ssh.default ${D}${sysconfdir}/default/ssh - for f in ${KEYFILES}; do - ln -sf /var/config/ssh/$f ${D}${sysconfdir}/ssh/$f - done -} -CONFFILES_${PN}-sshd += "${sysconfdir}/init.d/sshd" diff --git a/recipes-connectivity/openssh/openssh_8.1p1.bb b/recipes-connectivity/openssh/openssh_8.1p1.bb deleted file mode 100644 index 5bfd8e3..0000000 --- a/recipes-connectivity/openssh/openssh_8.1p1.bb +++ /dev/null @@ -1,160 +0,0 @@ -SUMMARY = "A suite of security-related network utilities based on \ -the SSH protocol including the ssh client and sshd server" -DESCRIPTION = "Secure rlogin/rsh/rcp/telnet replacement (OpenSSH) \ -Ssh (Secure Shell) is a program for logging into a remote machine \ -and for executing commands on a remote machine." -HOMEPAGE = "http://www.openssh.com/" -SECTION = "console/network" -LICENSE = "BSD" -LIC_FILES_CHKSUM = "file://LICENCE;md5=18d9e5a8b3dd1790d73502f50426d4d3" - -DEPENDS = "zlib openssl" -DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}" - -SRC_URI = "http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-${PV}.tar.gz \ - file://sshd_config \ - file://ssh_config \ - file://init \ - ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${PAM_SRC_URI}', '', d)} \ - file://sshd.socket \ - file://sshd@.service \ - file://sshdgenkeys.service \ - file://volatiles.99_sshd \ - file://openssh-8.1p1-add-test-support-for-busybox.patch \ - file://run-ptest \ - file://openssh-8.1p1-conditional-compile-des-in-cipher.patch \ - file://openssh-8.1p1-conditional-compile-des-in-pkcs11.patch \ - file://fix-potential-signed-overflow-in-pointer-arithmatic.patch \ - " - -PAM_SRC_URI = "file://sshd" - -SRC_URI[md5sum] = "513694343631a99841e815306806edf0" -SRC_URI[sha256sum] = "02f5dbef3835d0753556f973cd57b4c19b6b1f6cd24c03445e23ac77ca1b93ff" - -inherit useradd update-rc.d update-alternatives systemd - -USERADD_PACKAGES = "${PN}-sshd" -USERADD_PARAM_${PN}-sshd = "--system --no-create-home --home-dir /var/run/sshd --shell /bin/false --user-group sshd" -INITSCRIPT_PACKAGES = "${PN}-sshd" -INITSCRIPT_NAME_${PN}-sshd = "sshd" -INITSCRIPT_PARAMS_${PN}-sshd = "defaults 9" - -SYSTEMD_PACKAGES = "${PN}-sshd" -SYSTEMD_SERVICE_${PN}-sshd = "sshd.socket" - -inherit autotools-brokensep ptest - -# LFS support: -CFLAGS += "-D__FILE_OFFSET_BITS=64" - -# login path is hardcoded in sshd -EXTRA_OECONF = "'LOGIN_PROGRAM=${base_bindir}/login' \ - ${@bb.utils.contains('DISTRO_FEATURES', 'pam', '--with-pam', '--without-pam', d)} \ - --without-zlib-version-check \ - --with-privsep-path=/var/run/sshd \ - --sysconfdir=${sysconfdir}/ssh \ - --with-xauth=/usr/bin/xauth \ - --disable-strip \ - " - -# Since we do not depend on libbsd, we do not want configure to use it -# just because it finds libutil.h. But, specifying --disable-libutil -# causes compile errors, so... -CACHED_CONFIGUREVARS += "ac_cv_header_bsd_libutil_h=no ac_cv_header_libutil_h=no" - -# passwd path is hardcoded in sshd -CACHED_CONFIGUREVARS += "ac_cv_path_PATH_PASSWD_PROG=${bindir}/passwd" - -# We don't want to depend on libblockfile -CACHED_CONFIGUREVARS += "ac_cv_header_maillock_h=no" - -do_configure_prepend () { - export LD="${CC}" - install -m 0644 ${WORKDIR}/sshd_config ${B}/ - install -m 0644 ${WORKDIR}/ssh_config ${B}/ - if [ ! -e acinclude.m4 -a -e aclocal.m4 ]; then - cp aclocal.m4 acinclude.m4 - fi -} - -do_compile_ptest() { - # skip regress/unittests/ binaries: this will silently skip - # unittests in run-ptests which is good because they are so slow. - oe_runmake regress/modpipe regress/setuid-allowed regress/netcat -} - -do_install_append () { - if [ "${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam', '', d)}" = "pam" ]; then - install -D -m 0644 ${WORKDIR}/sshd ${D}${sysconfdir}/pam.d/sshd - sed -i -e 's:#UsePAM no:UsePAM yes:' ${D}${sysconfdir}/ssh/sshd_config - fi - - if [ "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}" = "x11" ]; then - sed -i -e 's:#X11Forwarding no:X11Forwarding yes:' ${D}${sysconfdir}/ssh/sshd_config - fi - - install -d ${D}${sysconfdir}/init.d - install -m 0755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/sshd - rm -f ${D}${bindir}/slogin ${D}${datadir}/Ssh.bin - rmdir ${D}${localstatedir}/run/sshd ${D}${localstatedir}/run ${D}${localstatedir} - install -d ${D}/${sysconfdir}/default/volatiles - install -m 644 ${WORKDIR}/volatiles.99_sshd ${D}/${sysconfdir}/default/volatiles/99_sshd - install -m 0755 ${S}/contrib/ssh-copy-id ${D}${bindir} - - # Create config files for read-only rootfs - install -d ${D}${sysconfdir}/ssh - install -m 644 ${D}${sysconfdir}/ssh/sshd_config ${D}${sysconfdir}/ssh/sshd_config_readonly - sed -i '/HostKey/d' ${D}${sysconfdir}/ssh/sshd_config_readonly - echo "HostKey /var/run/ssh/ssh_host_rsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly - echo "HostKey /var/run/ssh/ssh_host_dsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly - echo "HostKey /var/run/ssh/ssh_host_ecdsa_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly - echo "HostKey /var/run/ssh/ssh_host_ed25519_key" >> ${D}${sysconfdir}/ssh/sshd_config_readonly - - install -d ${D}${systemd_unitdir}/system - install -c -m 0644 ${WORKDIR}/sshd.socket ${D}${systemd_unitdir}/system - install -c -m 0644 ${WORKDIR}/sshd@.service ${D}${systemd_unitdir}/system - install -c -m 0644 ${WORKDIR}/sshdgenkeys.service ${D}${systemd_unitdir}/system - sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \ - -e 's,@SBINDIR@,${sbindir},g' \ - -e 's,@BINDIR@,${bindir},g' \ - ${D}${systemd_unitdir}/system/sshd.socket ${D}${systemd_unitdir}/system/*.service -} - -do_install_ptest () { - sed -i -e "s|^SFTPSERVER=.*|SFTPSERVER=${libexecdir}/sftp-server|" regress/test-exec.sh - cp -r regress ${D}${PTEST_PATH} -} - -ALLOW_EMPTY_${PN} = "1" - -PACKAGES =+ "${PN}-keygen ${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-sftp ${PN}-misc ${PN}-sftp-server" -FILES_${PN}-scp = "${bindir}/scp.${BPN}" -FILES_${PN}-ssh = "${bindir}/ssh.${BPN} ${sysconfdir}/ssh/ssh_config" -FILES_${PN}-sshd = "${sbindir}/sshd ${sysconfdir}/init.d/sshd ${systemd_unitdir}/system" -FILES_${PN}-sshd += "${sysconfdir}/ssh/moduli ${sysconfdir}/ssh/sshd_config ${sysconfdir}/ssh/sshd_config_readonly ${sysconfdir}/default/volatiles/99_sshd ${sysconfdir}/pam.d/sshd" -FILES_${PN}-sftp = "${bindir}/sftp" -FILES_${PN}-sftp-server = "${libexecdir}/sftp-server" -FILES_${PN}-misc = "${bindir}/ssh* ${libexecdir}/ssh*" -FILES_${PN}-keygen = "${bindir}/ssh-keygen" - -RDEPENDS_${PN} += "${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-keygen" -RDEPENDS_${PN}-sshd += "${PN}-keygen ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-keyinit pam-plugin-loginuid', '', d)}" -RDEPENDS_${PN}-ptest += "${PN}-sftp ${PN}-misc ${PN}-sftp-server make" - -RPROVIDES_${PN}-ssh = "ssh" -RPROVIDES_${PN}-sshd = "sshd" - -RCONFLICTS_${PN} = "dropbear" -RCONFLICTS_${PN}-sshd = "dropbear" -RCONFLICTS_${PN}-keygen = "ssh-keygen" - -CONFFILES_${PN}-sshd = "${sysconfdir}/ssh/sshd_config" -CONFFILES_${PN}-ssh = "${sysconfdir}/ssh/ssh_config" - -ALTERNATIVE_PRIORITY = "90" -ALTERNATIVE_${PN}-scp = "scp" -ALTERNATIVE_${PN}-ssh = "ssh" - -do_rm_work () { -} diff --git a/recipes-connectivity/ppp/files/default b/recipes-connectivity/ppp/files/default deleted file mode 100644 index 6cc92df..0000000 --- a/recipes-connectivity/ppp/files/default +++ /dev/null @@ -1,8 +0,0 @@ -# Check to see if the SIM is registered before using ppp. -# Need this if using a cellular connection. -CHECKREGISTRATION=1 -# Note that boot will not complete until -# ppp completes, and the PPPTIMEOUT is the -# maximum wait time for the SIM to register -# for cellular PPP. -PPPTIMEOUT=60 diff --git a/recipes-connectivity/ppp/files/init.patch b/recipes-connectivity/ppp/files/init.patch deleted file mode 100644 index e74e981..0000000 --- a/recipes-connectivity/ppp/files/init.patch +++ /dev/null @@ -1,34 +0,0 @@ -diff -Naru old/init new/init ---- old/init 2017-09-05 19:07:19.810885424 -0500 -+++ new/init 2017-09-05 19:08:05.106884083 -0500 -@@ -8,11 +8,29 @@ - - test -x /usr/sbin/pppd -a -f /etc/ppp/ppp_on_boot || exit 0 - if [ -x /etc/ppp/ppp_on_boot ]; then RUNFILE=1; fi -- -+: ${PPPTIMEOUT:=60} -+logger timeout is $PPPTIMEOUT -+[ -f /etc/default/ppp ] && . /etc/default/ppp - case "$1" in - start) -+ t0=($(cat /proc/uptime)) -+ if (( CHECKREGISTRATION == 1 )) ; then while : ; do -+ REG=$(/usr/bin/radio-query --netreg) -+ [[ $REG == "REGISTERED" ]] && break -+ t1=($(cat /proc/uptime)) -+ diff=$(awk "BEGIN{print int($t1-$t0)}") -+ logger -s "Modem not ready. Waited $diff of $PPPTIMEOUT seconds" -+ if ((diff > PPPTIMEOUT)) ; then -+ logger -s "Timed out waiting for modem registration" -+ exit 1 -+ fi -+ sleep 1 -+ done ; fi -+ -+ logger "Starting up PPP link: pppd" - echo -n "Starting up PPP link: pppd" - if [ "$RUNFILE" = "1" ]; then -+ logger "ppp_on_boot" - /etc/ppp/ppp_on_boot - else - pppd call provider diff --git a/recipes-connectivity/ppp/files/poff.patch b/recipes-connectivity/ppp/files/poff.patch deleted file mode 100644 index 2385886..0000000 --- a/recipes-connectivity/ppp/files/poff.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -Naru old/poff new/poff ---- old/poff 2017-09-05 19:07:11.630885666 -0500 -+++ new/poff 2017-09-05 19:08:09.586883950 -0500 -@@ -1,7 +1,7 @@ - #!/bin/sh - - # Lets see how many pppds are running.... --set -- `cat /var/run/ppp*.pid 2>/dev/null` -+set -- `cat /var/run/ppp[0-9]*.pid 2>/dev/null` - - case $# in - 0) # pppd only creates a pid file once ppp is up, so let's try killing pppd diff --git a/recipes-connectivity/ppp/ppp_%.bbappend b/recipes-connectivity/ppp/ppp_%.bbappend deleted file mode 100644 index 55c47df..0000000 --- a/recipes-connectivity/ppp/ppp_%.bbappend +++ /dev/null @@ -1,18 +0,0 @@ -SRC_URI_append = "\ - file://init.patch;patchdir=.. \ - file://poff.patch;patchdir=.. \ - file://default" - -PR = "r9" - -FILESEXTRAPATHS_prepend := "${THISDIR}/files:" - -FILES_${PN} += "/etc/default/ppp" - -# AEP compatibility -CONFFILES_${PN} += "${sysconfdir}/default/ppp ${sysconfdir}/init.d/ppp" - -do_install_append() { - install -d -m 0755 ${D}/${sysconfdir}/default/ - install -m 644 ${WORKDIR}/default ${D}/${sysconfdir}/default/ppp -} diff --git a/recipes-connectivity/usb-gadget-mode/files/usb-gadget b/recipes-connectivity/usb-gadget-mode/files/usb-gadget deleted file mode 100755 index 8da88ad..0000000 --- a/recipes-connectivity/usb-gadget-mode/files/usb-gadget +++ /dev/null @@ -1,69 +0,0 @@ -#! /bin/sh -# -# Copyright Matthias Hentges (c) 2007 -# License: GPL (see http://www.gnu.org/licenses/gpl.txt for a copy of the license) -# -# Filename: usb-gadget -# Date: 20070606 (YMD) -# -################################################################################# -# -# 20070606 - v0.0.1 - Initial release -# 20070630 - v0.0.2 - Add forgotten host mode -# 20090529 - add support for all gadgets in 2.6.29 (koen) - -CONF_FILE="/etc/default/usb-gadget" - -die() { - echo "ERROR: $1" - exit 1 -} - -go() { - test -e "$CONF_FILE" && . "$CONF_FILE" - - case "$USB_MODE" in - networking) setup_usb g_ether ;; - zero) setup_usb g_zero ;; - midi) setup_usb g_midi ;; - printer) setup_usb g_printer ;; - gadgetfs) setup_usb gadgetfs ;; - composite) setup_usb g_cdc ;; - serial) setup_usb g_serial ;; - storage) setup_usb g_file_storage ;; - hostmode) unload_usb_gadgets - setup_usb ohci_hcd ;; - none) unload_usb_gadgets ;; - esac - -} - -setup_usb() { - - if ! ( lsmod | grep -q "$1" ) - then - unload_usb_gadgets - echo "Loading [$1]" - modprobe "$1" $MODULE_OPTIONS - else - echo "Already loaded: [$1]" - fi -} - -unload_usb_gadgets() { - KERNEL_VERSION="`uname -r`" - GADGET_MODULES="`find /lib/modules/$KERNEL_VERSION/kernel/drivers/usb/gadget -name "*g_*"`" - - for module in $GADGET_MODULES - do - MODULE_NAME="`basename $module | sed "s/\.ko//"`" - - if ( lsmod | grep -q "$MODULE_NAME" ) - then - echo "Unloading [$MODULE_NAME]" - rmmod "$module" - fi - done -} - -go diff --git a/recipes-connectivity/usb-gadget-mode/files/usb-gadget.conf b/recipes-connectivity/usb-gadget-mode/files/usb-gadget.conf deleted file mode 100644 index f3a7a6b..0000000 --- a/recipes-connectivity/usb-gadget-mode/files/usb-gadget.conf +++ /dev/null @@ -1,6 +0,0 @@ -# set to "no" to disable usb-gadget -ENABLED="yes" - -USB_MODE="serial" -MODULE_OPTIONS="" - diff --git a/recipes-connectivity/usb-gadget-mode/files/usb-gadget.init b/recipes-connectivity/usb-gadget-mode/files/usb-gadget.init deleted file mode 100755 index 403fd23..0000000 --- a/recipes-connectivity/usb-gadget-mode/files/usb-gadget.init +++ /dev/null @@ -1,21 +0,0 @@ -#! /bin/sh -# -# Copyright Matthias Hentges (c) 2007 -# License: GPL (see http://www.gnu.org/licenses/gpl.txt for a copy of the license) -# -# Filename: usb-gadget.init -# Date: 20070606 (YMD) -# -################################################################################# -# -# 20070606 - v0.0.1 - Initial release - -ENABLED="yes" - -[ -r /etc/default/usb-gadget ] && source /etc/default/usb-gadget -[ "$ENABLED" == "yes" ] || exit 0 - -case "$1" in -start) usb-gadget ;; -esac - diff --git a/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb b/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb deleted file mode 100644 index 0f15830..0000000 --- a/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb +++ /dev/null @@ -1,56 +0,0 @@ -# Copyright Matthias Hentges (c) 2007 -# License: MIT (see http://www.opensource.org/licenses/mit-license.php -# for a copy of the license) -# -# Filename: usb-gadget-mode.bb -# Date: 20070606 (YMD) - -DESCRIPTION = "Manage the default USB gadget mode" -SECTION = "console/network" -LICENSE = "GPLv2" -LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6" -PV = "0.0.2" -PR = "r3" - -SRC_URI = "\ - file://usb-gadget.conf \ - file://usb-gadget \ - file://usb-gadget.init \ -" - -do_install() { - install -d ${D}${sysconfdir} - install -d ${D}${sysconfdir}/init.d - install -d ${D}${bindir} - install -d ${D}${sysconfdir}/default - - install -m 0644 ${WORKDIR}/usb-gadget.conf ${D}${sysconfdir}/default/usb-gadget - install -m 0755 ${WORKDIR}/usb-gadget.init ${D}${sysconfdir}/init.d/usb-gadget - install -m 0755 ${WORKDIR}/usb-gadget ${D}${bindir} -} - -# disbale usb-gadget for mtcap hardware -do_install_append_mtcap() { - sed -i 's/ENABLED="yes"/ENABLED="no"/g' ${D}${sysconfdir}/default/usb-gadget -} - -pkg_postinst_${PN}() { - test -n "$D" && opt="-r $D" - update-rc.d $opt usb-gadget defaults 50 -} - -pkg_postrm_${PN}() { - update-rc.d -f usb-gadget remove -} - -PACKAGE_ARCH = "${MACHINE_ARCH}" - -# disable usb-gadget on mtr -do_install_append_mtr() { - sed -i 's/ENABLED="yes"/ENABLED="no"/g' ${D}${sysconfdir}/default/usb-gadget -} - -# disable usb-gadget on mtrv1 -do_install_append_mtrv1() { - sed -i 's/ENABLED="yes"/ENABLED="no"/g' ${D}${sysconfdir}/default/usb-gadget -} diff --git a/recipes-core/annex-client/annex-client-from-src.bb b/recipes-core/annex-client/annex-client-from-src.bb deleted file mode 100644 index 3534f23..0000000 --- a/recipes-core/annex-client/annex-client-from-src.bb +++ /dev/null @@ -1,28 +0,0 @@ -DESCRIPTION = "Provides the Multi-Tech MDM client" -SECTION = "remote-management" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" -PROVIDES = "annex-client-from-src" -DEPENDS = "jsoncpp curl protobuf cyrus-sasl protobuf-native annex-proto mts-io" - -# IMPORTANT: if you change PR, you'll also want to change the url in annex-client.bb -PR = "r1" -SRCREV = "b954c83e155f95ecd68c14a890f9455331e19878" - -SRC_URI = "git://git@${MTS_INTERNAL_GIT}/multitech/annex-client.git;protocol=ssh;branch=master" - -S = "${WORKDIR}/git" - -do_compile() { - echo "directory: `pwd`" - mkdir -p annex_pb - cp ${STAGING_DIR_NATIVE}/annex.proto annex_pb/ - make all CFLAGS+="-DMLINUX_BUILD" -} - -# IMPORTANT NOTE: -# this recipe is only used for the annex-client Jenkin's job to build IPK. -# annex-client.bb is used to install the binary in an image -do_install() { - oe_runmake install DESTDIR=${D} SUBDIRS="src" -} diff --git a/recipes-core/annex-client/annex-client.bb b/recipes-core/annex-client/annex-client.bb deleted file mode 100644 index 83dd602..0000000 --- a/recipes-core/annex-client/annex-client.bb +++ /dev/null @@ -1,53 +0,0 @@ -DESCRIPTION = "Provides the Multi-Tech MDM client" -SECTION = "remote-management" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" -PROVIDES = "annex-client" - -# NOTE: annex-client binary is built with Jenkin's job using annex-client-from-src.bb -# To update this, manually copy ipk from Jenkin's job to .net/downloads/ -PR = "r3" -ANNEX_PR = "r1" -SRC_URI = "http://multitech.net/downloads/annex-client-from-src_1.0-${ANNEX_PR}.0_${TUNE_PKGARCH}.ipk \ - file://annex-client.init \ - file://monitor-annexcd \ - file://call_home \ - file://call_home.init \ - file://config.json.sample \ - file://push_api_mdm_connected \ - file://push_api_mdm_status \ -" - -SRC_URI[md5sum] = "e180f4e569fbba2f5b9d524b5a9e944e" -SRC_URI[sha256sum] = "1e93c65005c630cf211615dc143eb64f177591efcdbed6952142c7bac0e95988" - -#inherit update-rc.d -# -#INITSCRIPT_NAME = "annex-client" -#INITSCRIPT_PARAMS = "defaults 95 1" -S = "${WORKDIR}" - -DHQ_DIR="/opt/devicehq" - -do_install() { - install -d ${D}${sbindir} - install -m 755 sbin/annexcd ${D}${sbindir} - - install -d ${D}/etc/ssl/certs - install -m 644 etc/ssl/certs/rootCA.pem ${D}/etc/ssl/certs - - install -d ${D}${base_sbindir} - install -m 755 ${WORKDIR}/monitor-annexcd ${D}${base_sbindir} - install -m 755 ${WORKDIR}/call_home ${D}${base_sbindir} - install -m 755 ${WORKDIR}/push_api_mdm_connected ${D}${base_sbindir} - install -m 755 ${WORKDIR}/push_api_mdm_status ${D}${base_sbindir} - - install -d ${D}${sysconfdir}/init.d - install -m 755 ${WORKDIR}/annex-client.init ${D}${sysconfdir}/init.d/annex-client - install -m 755 ${WORKDIR}/call_home.init ${D}${sysconfdir}/init.d/call_home - - install -d ${D}${DHQ_DIR} - install -m 644 ${WORKDIR}/config.json.sample ${D}${DHQ_DIR} -} - -FILES_${PN} += "${DHQ_DIR}" diff --git a/recipes-core/annex-client/annex-client/annex-client.init b/recipes-core/annex-client/annex-client/annex-client.init deleted file mode 100644 index 4a5dc4b..0000000 --- a/recipes-core/annex-client/annex-client/annex-client.init +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/bash - -MONITOR="/sbin/monitor-annexcd" -CLIENT="annexcd" - -start() { - if [[ $(pidof -x $MONITOR) ]]; then - echo "RM client is already running" - else - echo "Starting RM client" - $MONITOR & - fi -} - -stop() { - MONITOR_PID=$(pidof -x $MONITOR) - CLIENT_PID=$(pidof $CLIENT) - if [[ $MONITOR_PID ]]; then - echo "Stopping RM client" - kill $MONITOR_PID $CLIENT_PID - else - echo "RM client is not running" - fi -} - -case "$1" in - start) - start - ;; - stop) - stop - ;; - restart) - stop - start - ;; - *) - echo "Usage: /etc/init.d/annex-client {start|stop|restart}" >&2 - exit 1 - ;; -esac - -exit 0 diff --git a/recipes-core/annex-client/annex-client/call_home b/recipes-core/annex-client/annex-client/call_home deleted file mode 100755 index 64887ec..0000000 --- a/recipes-core/annex-client/annex-client/call_home +++ /dev/null @@ -1,192 +0,0 @@ -#!/bin/bash -#Attempt to gain a WAN connection for MDM Registration to query for this device's MDM account ID -#PREREQ: Firewall allows outgoing DHCP requests and MDM Client connection - -CONFIG_FILE="/var/config/devicehq/config.json" -STATUS_FILE="/var/config/devicehq/status.json" - -if [ ! -f $CONFIG_FILE ]; then - logger -t callhome "Config file missing!" - logger -t callhome "Do: mkdir /var/config/devicehq" - logger -t callhome "Then: cp /opt/devicehq/config.json.sample /var/config/devicehq/config.json" - exit 1 -fi - -JSON=$(cat $CONFIG_FILE) -ENABLED=$( echo $JSON | jsparser -p /enabled ) -KEY=$( echo $JSON | jsparser -p /accountKey ) -MDM_URL=$( echo $JSON | jsparser -p /deviceHqUrl ) - -if [ "$ENABLED" != "true" ]; then - logger -t callhome "Not calling home because DeviceHQ is disabled in /var/config/devicehq/config..json." - exit 1 -fi - -UUID=$(mts-io-sysfs show uuid) -DEVID=$(mts-io-sysfs show device-id) - - -MDM_REG_URL="$MDM_URL/api/v1/register-device" -TMPFILE="/var/run/callhome" -DONE=false -FORCE=false -WAN_AVAILABLE=true -MAX_ATTEMPTS=0 #Infinite -INTERVAL_SECONDS=30 - -#Gather options from command line -# Reset in case getopts has been used previously in the shell. -OPTIND=1 - -function show_help() { - echo "Usage: $0 -k -a -i " -} - -while getopts "h?k:a:i:d:u:m:f" opt; do - case "$opt" in - h|\?) - show_help - exit 0 - ;; - k) KEY=$OPTARG - ;; - a) MAX_ATTEMPTS=$OPTARG - ;; - a) INTERVAL_SECONDS=$OPTARG - ;; - f) FORCE=true - ;; - d) DEVID=$OPTARG - ;; - u) UUID=$OPTARG - ;; - m) MDM_URL=$OPTARG - ;; - esac -done - -shift $((OPTIND-1)) - -[ "$1" = "--" ] && shift - -if [ "$FORCE" == "true" ]; then - DONE=false -fi - - -function checkCallHomeNeeded() { - if [ "$FORCE" != "true" ]; then - JSON=$(cat $CONFIG_FILE) - KEY=$( echo $JSON | jsparser -p /accountKey ) - - LAST_CONNECTED="unknown" - STATUS="" - if [ -f $STATUS_FILE ]; then - JSON=$(cat $STATUS_FILE) - LAST_CONNECTED=$( echo $JSON | jsparser -p /lastConnected ) - STATUS=$( echo $JSON | jsparser -p /status ) - fi - - if [ "$KEY" != "" ] && [ $LAST_CONNECTED != "unknown" ] && [ $STATUS == "idle" ]; then - echo "Found that Call-Home Not Needed" - exit 0 - fi - fi -} - -function saveConfigs() { - logger -t callhome "Saving accountKey" - - sed -i "s/\"accountKey\"\s*:\s*\".*\"/\"accountKey\": \"$KEY\"/" $CONFIG_FILE - - if [ $? != 0 ]; then - logger -t callhome "Failed to add account key [$KEY] to $CONFIG_FILE" - fi -} - -function checkForCheckIn() { - - i=0 - while [ $i -lt 10 ]; do - if [ -f $STATUS_FILE ]; then - JSON=$(cat $STATUS_FILE) - LAST_CONNECTED=$( echo $JSON | jsparser -p /lastConnected ) - STATUS=$( echo $JSON | jsparser -p /status ) - if [ "$LAST_CONNECTED" == "unknown" ] || [ $STATUS != "idle" ]; then - logger -t callhome "MDM client has not checked-in yet" - else - logger -t callhome "SUCCESS! MDM Client has checked-in." - DONE=true - return - fi - else - logger -t callhome "MDM client has not checked-in yet" - fi - - let i=i+1 - logger -t callhome "Sleeping for 30 seconds." - sleep 30 - done - -} - -function attemptMdmRegistration() { - - logger -t callhome "Attempting to register with MDM" - CODE=$( curl -m 20 -ks -o $TMPFILE -w "%{http_code}" -X POST -H "Content-Type: application/json" \ - -d '{ "device_id" : "'$DEVID'", "uuid" : "'$UUID'" }' \ - $MDM_REG_URL ) - - if [ $? == 0 ]; then - if [ "$CODE" == "200" ]; then - logger -t callhome "Registered with MDM. Checking for Account Key" - - #Request returned 200 - KEY=$( cat $TMPFILE | jsparser -p /account_key ) - if [ $? == 0 ]; then - if [ "$KEY" != "" ]; then - logger -t callhome "Received Account Key! [$KEY]" - saveConfigs - /etc/init.d/annex-client start - checkForCheckIn - else - logger -t callhome "Account Key not returned. This device may not be registered with a user account" - fi - else - RESULT=$(cat $TMPFILE) - logger -t callhome "Error: Unexpected MDM Registration Server response: $RESULT" - fi - else - RESULT=$(cat $TMPFILE) - logger -t callhome "Error: MDM Registration Failed with Device ID [$DEVID] and UUID [$UUID]" - logger -t callhome "Error: MDM Registration Server Response Header Code: $CODE" - logger -t callhome "Error: MDM Registration Server Response Body Content: $RESULT" - fi - else - logger -t callhome "Warning: Could not connect to MDM server: $MDM_REG_URL" - fi -} - -logger -t callhome "Setting Up Call-Home " -COUNT=0 - -while [ $DONE == false ]; do - logger -t callhome "Attempts: $COUNT" - - checkCallHomeNeeded - - attemptMdmRegistration - - COUNT=$(($COUNT+1)) - if [ $MAX_ATTEMPTS != 0 ] && [ $COUNT -gt $MAX_ATTEMPTS ]; then - DONE=true - logger -t callhome "Reached Maximum Attempts [$MAX_ATTEMPTS]" - fi - - if [ $DONE == false ]; then - logger -t callhome "Sleeping for $INTERVAL_SECONDS seconds before next attempt" - sleep $INTERVAL_SECONDS - fi - -done - diff --git a/recipes-core/annex-client/annex-client/call_home.init b/recipes-core/annex-client/annex-client/call_home.init deleted file mode 100755 index b874565..0000000 --- a/recipes-core/annex-client/annex-client/call_home.init +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/bash -CALLHOME="/sbin/call_home" - -start() { - if [[ $(pidof $CALLHOME) ]]; then - echo "Call-Home Service is already running" - else - echo "Starting Call-Home Service" - $CALLHOME & - fi -} - -stop() { - CALLHOME_PID=$(pidof -x $CALLHOME) - if [[ $CALLHOME_PID ]]; then - echo "Stopping Call-Home Service" - kill $CALLHOME_PID - else - echo "Call-Home Service is not running" - fi -} - -case "$1" in - start) - start - ;; - stop) - stop - ;; - restart) - stop - start - ;; - *) - echo "Usage: /etc/init.d/call_home {start|stop|restart}" >&2 - exit 1 - ;; -esac - -exit 0 diff --git a/recipes-core/annex-client/annex-client/config.json.sample b/recipes-core/annex-client/annex-client/config.json.sample deleted file mode 100644 index 5e83c64..0000000 --- a/recipes-core/annex-client/annex-client/config.json.sample +++ /dev/null @@ -1,10 +0,0 @@ -{ - "enabled": true, - "accountKey": "", - "deviceHqUrl": "https://www.devicehq.com", - "deviceServerUrl": "ds.devicehq.com", - "checkInIntervalMins": 720, - "gpsDataIntervalMins": 720, - "allowFirmwareUpgrade": true, - "allowConfigUpgrade": false -} diff --git a/recipes-core/annex-client/annex-client/monitor-annexcd b/recipes-core/annex-client/annex-client/monitor-annexcd deleted file mode 100755 index 21d5a6b..0000000 --- a/recipes-core/annex-client/annex-client/monitor-annexcd +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/bash - -CONFIG_FILE="/var/config/devicehq/config.json" - -if [ ! -f $CONFIG_FILE ]; then - logger -t monitor-annexcd "Config file missing!" - logger -t monitor-annexcd "Do: mkdir /var/config/devicehq" - logger -t monitor-annexcd "Then: cp /opt/devicehq/config.json.sample /var/config/devicehq/config.json" - logger -t monitor-annexcd "Exiting..." - exit 1 -fi - -DEVICE_ID=$(mts-io-sysfs show device-id) -PRODUCT_ID=$(mts-io-sysfs show product-id) - -get_args() { - JSON=$(cat $CONFIG_FILE) - - ENABLED=$( echo $JSON | jsparser -p enabled ) - KEY=$( echo $JSON | jsparser -p accountKey ) - SERVER=$( echo $JSON | jsparser -p deviceServerUrl ) - PORT=5798 - QUERY_INT=$( echo $JSON | jsparser -p checkInIntervalMins ) - GPS_INT=$( echo $JSON | jsparser -p gpsDataIntervalMins ) - FW_UPGRADE=$( echo $JSON | jsparser -p allowFirmwareUpgrade ) - CONFIG_UPGRADE=$(echo $JSON | jsparser -p allowConfigUpgrade ) -} - - -get_args - -if [ "$KEY" == "" ]; then - logger -t monitor-annexcd "Account key missing in $CONFIG_FILE" - logger -t monitor-annexcd "Exiting..." - exit 1 -fi - -MIN_TO_MS=60000 - -if [[ $ENABLED == "true" ]]; then - ANNEXCD="annexcd --account-key $KEY --host $SERVER --port $PORT --product-id $PRODUCT_ID --device-id $DEVICE_ID --rpd-interval $(( $QUERY_INT * $MIN_TO_MS )) --gps-interval $(( $GPS_INT * $MIN_TO_MS )) --net-interval $(( $QUERY_INT * $MIN_TO_MS )) --cell-interval $(( $QUERY_INT * $MIN_TO_MS )) --active-apps-interval $(( $QUERY_INT * $MIN_TO_MS )) --lora-interval $(( $QUERY_INT * $MIN_TO_MS )) --when-ppp-up on --firmware-upgrade $FW_UPGRADE --config-upgrade $CONFIG_UPGRADE --ssl-method ssl --ssl-ca-certificate /etc/ssl/certs/rootCA.pem --ssl-ca-strict --log-upto 7" - until $ANNEXCD; do - echo "annexcd exited with status $? - restarting..." >&2 - sleep 1 - done -fi diff --git a/recipes-core/annex-client/annex-client/push_api_mdm_connected b/recipes-core/annex-client/annex-client/push_api_mdm_connected deleted file mode 100755 index ec8a23d..0000000 --- a/recipes-core/annex-client/annex-client/push_api_mdm_connected +++ /dev/null @@ -1,59 +0,0 @@ -#!/bin/bash -# This script pushes the current time to the API's remote management -# to track last connected time - -STATUS_FILE="/var/config/devicehq/status.json" -DHQ_DIR="/var/config/devicehq" - -LAST_CONNECTED=$(date +%m/%d/%Y/%H:%M:%S) -INTERVAL="" - -# Reset in case getopts has been used previously in the shell. -OPTIND=1 - -function show_help() { - echo "Usage: $0 -t