Compare commits

..

70 Commits

Author SHA1 Message Date
Magier Marcin
2599967241 gigaset-elements 2.4.2 - dg400 integration, dectmngr2 support 2016-10-28 13:43:29 +02:00
Ronny Nilsson
8779369d7b dectproxy has been enabled in Dectmngr2 for
third party applications.
2016-09-20 15:55:44 +02:00
Magier Marcin
938583d960 gigaset-elements 2.3.0 - fixed rule engine bug 2016-09-01 08:39:25 +02:00
Magier Marcin
c29427fd51 gigaset-elements 2.1.4 - 200 bytes packet for SUOTA 2016-07-08 19:46:53 +02:00
Jonas Höglund
b19040d68e Updated Natalie to version 12.26
Conflicts:
	natalie-dect-h/Makefile
	natalie-dect/Makefile

Conflicts:
	natalie-dect/Makefile
2016-07-08 19:46:53 +02:00
Magier Marcin
ecc459f34d gigaset-elements 2.1.3 - do not use status LED 2016-07-08 19:46:53 +02:00
Sukru Senli
66c9db511b gigaset-elements: use correct git url 2016-07-08 19:46:53 +02:00
Sukru Senli
66d3110ebe dectmngr v1.0.23 2016-07-08 19:46:53 +02:00
Sukru Senli
5560428dc6 natalie-dect v12.13 2016-07-08 19:46:53 +02:00
Sukru Senli
2eed8f2684 natalie-dect-h v12.13 2016-07-08 19:46:53 +02:00
Magier Marcin
f7919b2471 bump gigaset-elements package to 2.1.2 2016-07-08 19:46:53 +02:00
Sukru Senli
69633fce7c gigaset-elements package 2016-07-08 19:46:53 +02:00
Sukru Senli
d666372df6 Merge remote-tracking branch 'origin/3.6' 2016-07-08 19:46:36 +02:00
Sukru Senli
a21c4aea1e icwmp-3.0-2016-07-07 2016-07-07 10:57:04 +02:00
Sukru Senli
ff0d48571e iop: select ntfs-3g 2016-07-05 17:45:02 +02:00
Sukru Senli
004b2b47c2 icwmp-3.0-2016-07-04 2016-07-04 20:19:42 +02:00
Sukru Senli
a215b5975d icwmp-3.0-2016-07-01 2016-07-01 13:13:18 +02:00
Sukru Senli
cf0ea79c93 icwmp: do not depend on libopenssl and libstrophe 2016-06-29 16:56:13 +02:00
Sukru Senli
da1c09a3f5 icwmp-3.0-2016-06-27 2016-06-29 16:54:40 +02:00
Sukru Senli
1c8f80f93d Merge remote-tracking branch 'origin/tmp' 2016-06-27 09:31:34 +02:00
Strhuan Blomquist
5ff7522148 layer2interface: adding icmp to QoS to prevent red intrenet on high uplink load refs #9647 2016-06-21 14:42:01 +02:00
Sukru Senli
3b322ba3cb updated questd 2016-06-18 15:29:11 +02:00
Sukru Senli
57a0b0bcca voice-client: turn of voice led and let asterisk handle it 2016-06-16 15:37:29 +02:00
Sukru Senli
0836a0cc62 3.0-2016-06-16 2016-06-16 14:32:42 +02:00
Sukru Senli
52c52247eb asterisk updated 2016-06-15 17:56:25 +02:00
Sukru Senli
4d7d03950a update questd 2016-06-14 19:09:44 +02:00
Ronny Nilsson
1d52207a7f Fix for dect unpair and re-pair with voice. refs #9463 2016-06-14 15:38:59 +02:00
Ronny Nilsson
194978c7d2 Update feed [ feed_inteno_packages ] package [ asterisk18-mod ]
Debug printouts

-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
2016-06-14 15:17:30 +02:00
Ronny Nilsson
931ae16fec New wrapper script for dectmngr2 which reloads kernel module when necessary 2016-06-14 10:31:28 +02:00
Sukru Senli
8e63cdb53b iop: do not select luci-app-catv by default in luci.diff profile 2016-06-09 17:38:20 +02:00
Sukru Senli
65be93fb61 icwmp: depend on curl 2016-06-09 17:26:41 +02:00
Sukru Senli
f9e105133a iop: remove uhttpd if profile is luci 2016-06-09 17:22:48 +02:00
Sukru Senli
463c4f0855 iop: genconfig applies luci profile correctly 2016-06-09 16:02:35 +02:00
Sukru Senli
aad4b455b2 layer2interface: set xtm qos weight to 1 2016-06-08 15:12:39 +02:00
Sukru Senli
961b2caaf9 3.0-2016-06-02 2016-06-02 16:04:25 +02:00
Sukru Senli
fe97541f89 updated questd 2016-06-01 17:29:51 +02:00
Sukru Senli
9c5b671627 questd-3.1.6 2016-06-01 17:02:28 +02:00
Jonas Höglund
7d47e904d1 New defconfig syntax in customer configs 2016-06-01 14:51:53 +02:00
Sukru Senli
b2a32dac16 peripheral_manager: wait for ubus button object to be created before exiting init script 2016-05-12 19:17:40 +02:00
Alex Oprea
0b353ab84e iup: option 224 fix ciclying reboot refs #9077 2016-05-12 18:53:03 +02:00
Alex Oprea
cd3e774fb1 iup: delay iup224 untill dns is reacheable refs #9073 2016-05-11 18:38:17 +02:00
Sukru Senli
3c60ea1eae voice-client: ringing schedule is off by default 2016-05-09 10:39:29 +02:00
Sukru Senli
4ac9dcbcf4 voice-client: call_filter0 is default call_filter 2016-05-09 10:36:33 +02:00
Sukru Senli
07a4f41116 peripheral_manager: wait fir led.status ubus object to be created 2016-05-09 10:34:32 +02:00
Sukru Senli
e8fd9b654a Update feed [ feed_inteno_packages ] package [ peripheral_manager ]
-------------------------------------------------------------------------------
* e130cb0 Add enable for leds.
-------------------------------------------------------------------------------
commit e130cb0369b750d97cf2d4af081149cad7f6bb38
Author: Kenneth Johansson <kenneth@southpole.se>
Date: 2016-04-27 12:54:13 +0200

    Add enable for leds.

    when enable set to 0 the led function will internally be set to state OFF.
    it will still record any updates to state and when enable is set to 1 again
    will show whatever state has been set to during the time it was disabled.

Base directory -> /
 src/led.c | 37 ++++++++++++++++++++++++++++++++++---
 1 file changed, 34 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
2016-05-06 16:34:16 +02:00
Kenneth Johansson
a81973c7ec Update feed [ feed_inteno_packages ] package [ peripheral_manager ]
-------------------------------------------------------------------------------
* bc5b822 add allflash state.
-------------------------------------------------------------------------------
commit bc5b8227410dac75d2525ef1946b842766982830
Author: Kenneth Johansson <kenneth@southpole.se>
Date: 2016-04-15 14:45:17 +0200

    add allflash state.

Base directory -> /
 src/led.c | 41 ++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 40 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
2016-05-06 16:34:08 +02:00
Kenneth Johansson
ab06c82297 Update feed [ feed_inteno_packages ] package [ peripheral_manager ]
-------------------------------------------------------------------------------
* 8be3060 Don't allow setting filter on model 302.
* d341ac8 add debug program for eco ghost press.
-------------------------------------------------------------------------------
commit 8be3060315f010fbf1bde723e0674e4a65fa9ccb
Author: Kenneth Johansson <kenneth@southpole.se>
Date: 2016-04-01 15:40:24 +0200

    Don't allow setting filter on model 302.

Base directory -> /
 src/catv.c | 32 +++++++++++++++++++++++++++-----
 1 file changed, 27 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit d341ac83376fb3714a6b1401d4a3e7c199bc76f7
Author: Kenneth Johansson <kenneth@southpole.se>
Date: 2016-03-15 15:53:30 +0100

    add debug program for eco ghost press.

Base directory -> /
 Makefile.am   |  7 ++++++-
 src/eco_bug.c | 25 +++++++++++++++++++++++++
 2 files changed, 31 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
2016-05-06 16:33:45 +02:00
Alex Oprea
e3e9147597 iup224: fix cicling reboot 2016-05-04 17:13:10 +02:00
Sukru Senli
ec82e9de8f questd-3.1.5 2016-05-04 17:13:00 +02:00
Sukru Senli
75e0d5a481 Update feed [ feed_inteno_packages ] package [ questd ]
-------------------------------------------------------------------------------
* ff58bac questd: add missing _ to parameters
* 0866c35 wificontrol: check arp list too
-------------------------------------------------------------------------------
commit ff58bac2696667ecab36afa2d93e7595fe9a992e
Author: Sukru Senli <sukru.senli@inteno.se>
Date: 2016-05-04 13:21:39 +0200

    questd: add missing _ to parameters

Base directory -> /
 questd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit 0866c3584e4ff0295b6b30afa30105fe3076a1bb
Author: Sukru Senli <sukru.senli@inteno.se>
Date: 2016-05-04 13:13:08 +0200

    wificontrol: check arp list too

Base directory -> /
 wificontrol.c | 26 ++++++++++++++++++++++++--
 1 file changed, 24 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
2016-05-04 13:23:31 +02:00
Sukru Senli
d3e9574ccc questd: install wificontrol 2016-05-03 13:56:48 +02:00
Sukru Senli
eccfa20011 Update feed [ feed_inteno_packages ] package [ questd ]
-------------------------------------------------------------------------------
* 9467625 add some more wireless info to clients
-------------------------------------------------------------------------------
commit 9467625ceb2636ca1487e400ef119f374946beb0
Author: Sukru Senli <sukru.senli@inteno.se>
Date: 2016-05-03 12:05:37 +0200

    add some more wireless info to clients

Base directory -> /
 questd.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)
-------------------------------------------------------------------------------
2016-05-03 13:56:46 +02:00
Sukru Senli
a4b44d7415 icwmp-3.0-2016-03-30 2016-05-03 13:55:54 +02:00
Sukru Senli
3384f5ae7f port_management: populate ports config if it has invalid config 2016-05-03 13:55:31 +02:00
Sukru Senli
2d1e46af5d questd-3.1.3 2016-05-02 11:35:59 +02:00
Sukru Senli
48a036c8aa questd-3.1.2 2016-04-30 11:58:17 +02:00
Sukru Senli
ca9ba7c9f8 iup: option 224 follows standard 2016-04-29 10:46:41 +02:00
Alex Oprea
063e270ec4 iup224 file permissions 2016-04-29 10:23:16 +02:00
Sukru Senli
5433164b08 ice-client-3.4.1RC11 2016-04-25 13:54:32 +02:00
Sukru Senli
c595f79545 layer2interface: for now populate network config ifnames along with layer2 configs 2016-04-23 18:21:17 +02:00
Sukru Senli
4f0d7b0de4 auto populate layer2 configs 2016-04-23 18:21:08 +02:00
Sukru Senli
ab0c5c06b2 Revert "questd: makefile corrected"
This reverts commit e89af64b6b.
2016-04-23 18:18:37 +02:00
Fredrik Åsberg
e89af64b6b questd: makefile corrected 2016-04-22 16:49:18 +02:00
Sukru Senli
c1f7ac0e5e questd: updated Makefile 2016-04-19 18:22:16 +02:00
Sukru Senli
aa4aa23108 questd-3.1.0 2016-04-15 13:00:41 +02:00
Erik Horemans
5d5890b591 new ice-client 3.4.1-RC9 2016-04-15 11:50:52 +02:00
Sukru Senli
737efb21cf set iup dhcp opts on all management interfaces 2016-04-05 17:52:43 +02:00
Sukru Senli
4209b2f153 questd: install ueventd and uscriptd 2016-04-05 17:23:49 +02:00
Sukru Senli
23a4f85301 Update feed [ feed_inteno_packages ] package [ questd ]
-------------------------------------------------------------------------------
* 5de4432 do not share object
-------------------------------------------------------------------------------
commit 5de4432d19b043677b9c729701057ae8c0c37589
Author: Sukru Senli <sukru.senli@inteno.se>
Date: 2016-04-05 15:47:48 +0200

    do not share object

Base directory -> /
 Makefile  |  4 ++--
 scriptd.c | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++--
 tools.c   |  2 +-
 3 files changed, 53 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
2016-04-05 17:23:46 +02:00
Sukru Senli
06068d3950 questd hosts uscriptd and ueventd as well 2016-04-05 17:23:37 +02:00
88 changed files with 555 additions and 4639 deletions

View File

@@ -1,6 +1,6 @@
#!/bin/sh
local usb_dir uVid uPid uMa uPr uSe bConf bNumConfs vendor product mdmtyp netdev comdev cdcdev ttydev interface usbno usbbr
local usb_dir uVid uPid uMa uPr uSe bConf bNumConfs vendor product mdmtyp netdev comdev cdcdev ttydev usbno usbbr
sanitize() {
sed -e 's/[[:space:]]\+$//; s/[[:space:]]\+/_/g' "$@"
@@ -20,7 +20,6 @@ find_usb_attrs() {
netdev=$(find $usb_dir -name wwan* | awk -F'/' '{print$NF}' | head -2 | tail -1)
cdcdev=$(find $usb_dir -name cdc-wdm* | awk -F'/' '{print$NF}' | head -2 | tail -1)
ttydev=$(ls $(find $usb_dir -name tty | head -2 | tail -1) | tail -1)
interface=$(cat $usb_dir/interface)
if [ -n "$cdcdev" ]; then
comdev=$cdcdev
mdmtyp=$(grep $uVid:$uPid /etc/modemdb | grep 'qmi\|mbim' | awk '{print$2}' | head -1)
@@ -49,8 +48,6 @@ case "$usbbr" in
*:*) usbbr=$(echo $DEVPATH | cut -d'/' -f6) ;;
esac
#devno=$(basename $DEVPATH)
find_usb_attrs
if [ "$ACTION" = add ]; then
convert_to_mbim "$uVid:$uPid"
@@ -58,9 +55,6 @@ if [ "$ACTION" = add ]; then
if [ -n "$usbno" ] && [ -n "$usbbr" ]; then
sed -i "/$usbno:$usbbr/ d" /var/usbnets
echo $usbno:$usbbr $uVid:$uPid $uMa $uPr $netdev $comdev $mdmtyp $vendor $product >> /var/usbnets
ubus send hotplug.usb "{'action': 'add', 'devpath': '$DEVPATH', 'manufacturer': '$uMa', 'product': '$uPr', 'serial': '$uSe', 'vendor_id': '$uVid', \
'product_id': '$uPid', 'driver_interface': '$interface', 'driver': '$DRIVER', 'devtype': '$DEVTYPE'}"
fi
fi
fi
@@ -68,7 +62,5 @@ fi
if [ "$ACTION" = remove ]; then
if [ -n "$usbno" ] && [ -n "$usbbr" ]; then
sed -i "/$usbno:$usbbr/ d" /var/usbnets
ubus send hotplug.usb "{'action': 'remove', 'devpath': '$DEVPATH', 'manufacturer': '$uMa', 'product': '$uPr', 'serial': '$uSe', 'vendor_id': '$uVid', \
'product_id': '$uPid', 'driver_interface': '$interface', 'driver': '$DRIVER', 'devtype': '$DEVTYPE'}"
fi
fi

View File

@@ -119,7 +119,7 @@ endef
define Package/asterisk18-mod-cdr
$(call Package/asterisk18-mod/Default)
TITLE:=CDR support
DEPENDS:= asterisk18-mod +libsqlite3
DEPENDS:= asterisk18-mod
endef
define Package/asterisk18-mod-cdr/description
@@ -188,6 +188,17 @@ $(call Package/asterisk18-mod/Default/description)
support to Asterisk.
endef
define Package/asterisk18-mod-chan-mobile
$(call Package/asterisk18-mod/Default)
TITLE:=Mobile channel support
DEPENDS:= asterisk18-mod +bluez-libs
endef
define Package/asterisk18-mod-chan-mobile/description
$(call Package/asterisk18-mod/Default/description)
This package provides the channel chan_mobile support to Asterisk.
endef
define Package/asterisk18-mod-res-timing-timerfd
$(call Package/asterisk18-mod/Default)
TITLE:= Timerfd Timing Interface
@@ -330,6 +341,14 @@ else
--without-spandsp
endif
ifneq ($(SDK)$(CONFIG_PACKAGE_asterisk18-mod-chan-mobile),)
CONFIGURE_ARGS+= \
--with-bluetooth="$(STAGING_DIR)/usr"
else
CONFIGURE_ARGS+= \
--without-bluetooth
endif
ifneq ($(SDK)$(CONFIG_PACKAGE_asterisk18-mod-res-srtp),)
CONFIGURE_ARGS+= \
--with-srtp="$(STAGING_DIR)/usr"
@@ -552,6 +571,17 @@ define Package/asterisk18-mod-chan-gtalk/install
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/asterisk/modules/res_jabber.so $(1)/usr/lib/asterisk/modules/
endef
define Package/asterisk18-mod-chan-mobile/conffiles
/etc/asterisk/chan_mobile.conf
endef
define Package/asterisk18-mod-chan-mobile/install
$(INSTALL_DIR) $(1)/etc/asterisk
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/etc/asterisk/chan_mobile.conf $(1)/etc/asterisk/
$(INSTALL_DIR) $(1)/usr/lib/asterisk/modules
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/asterisk/modules/chan_mobile.so $(1)/usr/lib/asterisk/modules/
endef
define Package/asterisk18-mod-res-timing-timerfd/install
$(INSTALL_DIR) $(1)/usr/lib/asterisk/modules
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/asterisk/modules/res_timing_timerfd.so $(1)/usr/lib/asterisk/modules/
@@ -703,6 +733,7 @@ $(eval $(call BuildPackage,asterisk18-mod-cdr))
$(eval $(call BuildPackage,asterisk18-mod-res-musiconhold))
$(eval $(call BuildPackage,asterisk18-mod-res-voice))
$(eval $(call BuildPackage,asterisk18-mod-chan-gtalk))
$(eval $(call BuildPackage,asterisk18-mod-chan-mobile))
$(eval $(call BuildPackage,asterisk18-mod-res-fax))
$(eval $(call BuildPackage,asterisk18-mod-res-fax-spandsp))
$(eval $(call BuildPackage,asterisk18-mod-res-timing-timerfd))

81
bluez/Makefile Normal file
View File

@@ -0,0 +1,81 @@
#
# Copyright (C) 2006-2012 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=bluez
PKG_VERSION:=5.28
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=http://www.kernel.org/pub/linux/bluetooth
PKG_MD5SUM:=bc20a8285530758c68f6a60e4ca62a15
PKG_FIXUP:=autoreconf
PKG_BUILD_PARALLEL:=1
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
define Package/bluez
SECTION:=utils
CATEGORY:=Utilities
DEPENDS:=+libpthread +libusb-compat +glib2 +dbus +libreadline $(INTL_DEPENDS) $(ICONV_DEPENDS)
TITLE:=Bluetooth stack new version
URL:=http://www.bluez.org/
endef
define Package/bluez/conffiles
/etc/config/bluetooth
endef
TARGET_LDFLAGS+= \
-Wl,-rpath-link=$(STAGING_DIR)/usr/lib/libiconv-full/lib \
CONFIGURE_ARGS += \
--enable-shared \
--disable-cups \
--enable-debug \
--disable-test \
--disable-obex \
--disable-systemd \
--disable-udev \
--enable-tools \
--enable-experimental \
--enable-library \
--disable-static \
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) \
LDFLAGS="$(TARGET_LDFLAGS) \
-L$(ICONV_PREFIX)/lib \
-L$(INTL_PREFIX)/lib -lm -lncurses" \
DESTDIR="$(PKG_INSTALL_DIR)" \
all install
endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include/bluetooth
$(CP) $(PKG_INSTALL_DIR)/usr/include/bluetooth/*.h $(1)/usr/include/bluetooth
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libbluetooth.* $(1)/usr/lib/
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/bluez.pc $(1)/usr/lib/pkgconfig/
endef
define Package/bluez/install
$(INSTALL_DIR) $(1)/usr/bin
$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
$(INSTALL_DIR) $(1)/etc/bluetooth
$(INSTALL_DIR) $(1)/etc/dbus-1/system.d
$(CP) $(PKG_INSTALL_DIR)/etc/dbus-1/system.d/bluetooth.conf $(1)/etc/dbus-1/system.d/
$(INSTALL_DIR) $(1)/usr/lib/bluetooth
$(CP) $(PKG_INSTALL_DIR)/usr/lib/bluetooth/* $(1)/usr/lib/bluetooth
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libblue* $(1)/usr/lib
endef
$(eval $(call BuildPackage,bluez))

47
btle_alarm/Makefile Normal file
View File

@@ -0,0 +1,47 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=btle_alarm
PKG_VERSION:=1.0.6
PKG_RELEASE:=1
PKG_SOURCE_VERSION:=b505d7ae1524a213ca3de7f8ee15a7d51c6bbbd5
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=http://public.inteno.se:/btle_alarm
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_RELEASE)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk
define Package/btle_alarm
SECTION:=base
CATEGORY:=Utilities
TITLE:=Ethernet bridging configuration utility
#DESCRIPTION:=This variable is obsolete. use the Package/name/description define instead!
URL:=http://btle_alarm.sourceforge.net/
DEPENDS:=+bluez +libncurses
endef
define Package/btle_alarm/description
Ethernet bridging configuration utility
Manage ethernet bridging; a way to connect networks together to
form a larger network.
endef
define Package/btle_alarm/install
$(CP) ./files/* $(1)/
$(INSTALL_DIR) $(1)/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/btle_alarm $(1)/sbin/
$(INSTALL_DIR) $(1)/etc/config/
$(INSTALL_DATA) ./files/btle_alarm.conf $(1)/etc/config/btle_alarm
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/etc/init.d/* $(1)/etc/init.d/
endef
$(eval $(call BuildPackage,btle_alarm))

View File

@@ -0,0 +1,2 @@
config info 'Device'
option mac 'D0:39:72:B6:23:D6'

View File

@@ -0,0 +1,29 @@
#!/bin/sh /etc/rc.common
#
# Copyright (C) 2009 OpenWrt.org
#
START=99
start() {
for i in down reset up;do
hciconfig hci0 $i
done
mac=`uci get btle_alarm.Device.mac`
if [ $? -eq 0 ];then
hcitool lewladd $mac
else
hcitool lewladd D0:39:72:B6:43:8A
hcitool lewladd D0:39:72:B6:18:AA
fi
sleep 1
/sbin/btle_alarm &> /dev/null &
echo $! > /tmp/btle_alarm.pid
}
stop() {
hciconfig hci0 down
kill -9 `cat /tmp/btle_alarm.pid`
rm /tmp/btle_alarm.pid
sleep 1
}

View File

@@ -8,10 +8,10 @@
include $(TOPDIR)/rules.mk
PKG_RELEASE:=1
PKG_VERSION:=1.0.24
PKG_VERSION:=1.0.23
PKG_SOURCE_URL:=http://public.inteno.se:/dectmngr
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=6ba403663bc9cfdb8f89fb34de367f0796d68552
PKG_SOURCE_VERSION:=90aff0da98c626d58201c14c34b3b3a64878ceee
PKG_NAME:=dectmngr

Binary file not shown.

View File

@@ -11,7 +11,7 @@ PKG_RELEASE:=1
PKG_VERSION:=1.1.0
PKG_SOURCE_URL:=http://public.inteno.se:/dectmngr2
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=07c8a1665dc1f767c8ae2da92e41f482956f8959
PKG_SOURCE_VERSION:=ee63f0c087840adba9d944ae31d71a3ef9d64043
PKG_NAME:=dectmngr2

3
gigaset-elements/.gitignore vendored Normal file
View File

@@ -0,0 +1,3 @@
git-src

65
gigaset-elements/Makefile Normal file
View File

@@ -0,0 +1,65 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=gigaset-elements
PKG_VERSION:=2.4.2
# PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_GIGASET_ELEMENTS_SRC_URL ?= git@public.inteno.se:gigaset-elements.git
PKG_GIGASET_ELEMENTS_VERSION ?= v$(PKG_VERSION)
PKG_SOURCE_URL:=$(PKG_GIGASET_ELEMENTS_SRC_URL)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=$(PKG_GIGASET_ELEMENTS_VERSION)
PKG_MAINTAINER:=Magier Marcin, Figlarek Piotr
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
include $(INCLUDE_DIR)/package.mk
######################################################
define Package/gigaset-elements
SECTION:=utils
CATEGORY:=Utilities
DEPENDS:=+libjson-c +libcurl
TITLE:=Gigaset elements
endef
######################################################
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) all
endef
define Package/gigaset-elements/install
$(CP) -r $(PKG_BUILD_DIR)/sysroot_common/* $(1)/
$(CP) -r $(PKG_BUILD_DIR)/sysroot_$(CONFIG_ARCH)/* $(1)/
endef
define Package/gigaset-elements/preinst
#!/bin/sh
mkdir -p $${IPKG_INSTROOT}/usr/gigaset/data/cert
mkdir -p $${IPKG_INSTROOT}/usr/gigaset/data/fw
endef
define Package/gigaset-elements/postrm
#!/bin/sh
rm -rf $${IPKG_INSTROOT}/usr/gigaset/data
rm -rf /usr/share/gigaset
endef
######################################################
$(eval $(call BuildPackage,gigaset-elements))

View File

@@ -22,6 +22,7 @@ export PKG_VERSION
###########################--RELEASE--################################
PKG_SOURCE_URL:=ssh://git@private.inteno.se/ice-client.git
PKG_SOURCE_VERSION:=184d29446fe6103f567c968bf35569625326a82c
ifeq ($(CONFIG_ICE_OPEN),y)
BRCM_KERNEL_PROFILE=$(shell echo $(CONFIG_BCM_KERNEL_PROFILE) | sed s/\"//g)

View File

@@ -8,11 +8,11 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=icwmp
PKG_VERSION:=3.0-2016-07-01
PKG_VERSION:=3.0-2016-07-07
PKG_FIXUP:=autoreconf
PKG_SOURCE_URL:=http://public.inteno.se:/icwmp.git
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=85ecddf5a3993e60079c3a67bc74267480d0dc1a
PKG_SOURCE_VERSION:=6fac1df3418d727388162d5e006c7a756c9ff8d2
PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
@@ -34,7 +34,7 @@ define Package/icwmp/Default
SECTION:=utils
CATEGORY:=Utilities
TITLE:=CWMP client
DEPENDS:=+libuci +libmicroxml +libubox +jshn +libubus +libblobmsg-json +libpthread +ubusd +shflags +getopt +zlib +libjson-c +libopenssl +libexpat +libstrophe +curl
DEPENDS:=+libuci +libmicroxml +libubox +jshn +libubus +libblobmsg-json +libpthread +ubusd +shflags +getopt +zlib +libjson-c +libexpat +curl
endef
define Package/icwmp/description

View File

@@ -1,34 +0,0 @@
#
# Copyright (C) 2016 Inteno
#
include $(TOPDIR)/rules.mk
PKG_NAME:=inteno-netmodes
PKG_RELEASE:=1
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
include $(INCLUDE_DIR)/package.mk
define Package/inteno-netmodes
CATEGORY:=Base system
TITLE:=Predefined Network Modes
endef
define Package/inteno-netmodes/description
Predefined Network Modes
endef
define Build/Prepare
mkdir -p $(PKG_BUILD_DIR)
$(CP) ./files/* $(PKG_BUILD_DIR)/
endef
define Build/Compile
endef
define Package/inteno-netmodes/install
$(CP) ./files/* $(1)/
endef
$(eval $(call BuildPackage,inteno-netmodes))

View File

@@ -1,5 +0,0 @@
config mode 'setup'
option dir '/etc/netmodes'
option detail ''
option curmode 'routed'

View File

@@ -1,154 +0,0 @@
#!/bin/sh /etc/rc.common
START=10
USE_PROCD=1
. /usr/share/libubox/jshn.sh
. /lib/network/config.sh
local modedir=$(uci -q get netmode.setup.dir)
[ -n "$modedir" ] || modedir="/etc/netmodes"
get_device() {
local PORT_NAMES=$(db get hw.board.ethernetPortNames)
local PORT_ORDER=$(db get hw.board.ethernetPortOrder)
local cnt=1
local idx=0
local pnum=$(echo $PORT_NAMES | wc -w)
if [ $pnum -le 2 ]; then
PORT_NAMES=$(echo $PORT_NAMES | sed 's/LAN/LAN1/g')
fi
# get index of interface name
for i in $PORT_NAMES; do
if [ "$i" == "$1" ]; then
idx=$cnt
fi
cnt=$((cnt+1))
done
# get port name from index
cnt=1
for i in $PORT_ORDER; do
if [ "$cnt" == "$idx" ]; then
echo $i
fi
cnt=$((cnt+1))
done
}
populate_netmodes() {
[ -f /etc/config/netmode -a -d $modedir ] || return
delete_netmode() {
uci delete netmode.$1
}
config_load netmode
config_foreach delete_netmode netmode
uci commit netmode
wan=$(get_device WAN)
lan1=$(get_device LAN1)
lan2=$(get_device LAN2)
lan3=$(get_device LAN3)
lan4=$(get_device LAN4)
lan5=$(get_device LAN5)
for file in $(find $modedir -type f); do
grep -q "\$WAN" $file && sed -i "s/\$WAN/$wan/g" $file
grep -q "\$LAN1" $file && sed -i "s/\$LAN1/$lan1/g" $file
grep -q "\$LAN2" $file && sed -i "s/\$LAN2/$lan2/g" $file
grep -q "\$LAN3" $file && sed -i "s/\$LAN3/$lan3/g" $file
grep -q "\$LAN4" $file && sed -i "s/\$LAN4/$lan4/g" $file
done
local hardware=$(db get hw.board.hardware)
local keys lang desc exp exclude
for mode in $(ls $modedir); do
lang=""
desc=""
exp=""
uci -q set netmode.$mode=netmode
uci -q set netmode.$mode.conf=$mode
json_load "$(cat $modedir/$mode/DETAILS)"
exclude=0
json_get_var excluded_boards excluded_boards
for board in $excluded_boards; do
if [ "$board" == "$hardware" ]; then
uci -q delete netmode.$mode
exclude=1
break
fi
done
[ $exclude -eq 1 ] && continue
json_select description
json_get_keys keys
for k in $keys; do
json_get_keys lang $k
lang=$(echo $lang | sed 's/^[ \t]*//;s/[ \t]*$//')
json_select $k
json_get_var desc $lang
uci -q set netmode.$mode."desc_$lang"="$desc"
[ "$lang" == "en" ] && uci -q set netmode.$mode."desc"="$desc"
json_select ..
done
json_select ..
json_select explanation
json_get_keys keys
for k in $keys; do
json_get_keys lang $k
lang=$(echo $lang | sed 's/^[ \t]*//;s/[ \t]*$//')
json_select $k
json_get_var exp $lang
uci -q set netmode.$mode."exp_$lang"="$exp"
[ "$lang" == "en" ] && uci -q set netmode.$mode."exp"="$exp"
json_select ..
done
json_select ..
json_get_var cred credentials
uci -q set netmode.$mode.askcred="$cred"
json_get_var reboot reboot
uci -q set netmode.$mode.reboot="$reboot"
done
uci commit netmode
}
switch_netmode() {
[ -f /etc/config/netmode -a -d $modedir ] || return
config_load netmode
config_get curmode setup curmode
config_get conf $curmode conf
cp /etc/netmodes/$conf/* /etc/config/
rm -f /etc/config/DETAILS
sync
local reboot=$(uci -q get netmode.$curmode.reboot)
if [ "$reboot" == "0" ]; then
/etc/init.d/enviroment reload
else
reboot &
fi
}
start_service() {
populate_netmodes
}
reload_service() {
switch_netmode
}
service_triggers()
{
procd_add_reload_trigger netmode
}

View File

@@ -1,13 +0,0 @@
{
"description": [
{ "en" : "Bridged IPTV" },
{ "sv" : "Brygg IPTV" }
],
"explanation": [
{ "en" : "LAN4 port is bridged with IPTV VLAN" },
{ "sv" : "LAN4 port överbryggas med IPTV VLAN" }
],
"credentials" : 0,
"excluded_boards" : "CG300 CG301"
}

View File

@@ -1,22 +0,0 @@
config dnsmasq
option domainneeded 1
option boguspriv 1
option filterwin2k 0
option localise_queries 1
option rebind_protection 0
option rebind_localhost 1
option local '/lan/'
option domain 'lan'
option expandhosts 1
option nonegcache 0
option authoritative 1
option readethers 1
option leasefile '/tmp/dhcp.leases'
option resolvfile '/tmp/resolv.conf.auto'
config dhcp lan
option interface lan
option start 100
option limit 150
option leasetime 12h

View File

@@ -1,114 +0,0 @@
config defaults
option syn_flood 1
option input ACCEPT
option output ACCEPT
option forward REJECT
# Uncomment this line to disable ipv6 rules
# option disable_ipv6 1
config zone
option name lan
list network 'lan'
option input ACCEPT
option output ACCEPT
option forward ACCEPT
config zone
option name wan
list network 'wan'
list network 'wan6'
list network 'iptv'
option input REJECT
option output ACCEPT
option forward REJECT
option masq 1
option mtu_fix 1
config forwarding
option src lan
option dest wan
# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
option name Allow-DHCP-Renew
option src wan
option proto udp
option dest_port 68
option target ACCEPT
option family ipv4
option hidden 1
# Allow IPv4 ping
config rule
option name Allow-Ping
option src wan
option proto icmp
option icmp_type echo-request
option family ipv4
option target ACCEPT
option hidden 1
# Allow DHCPv6 replies
# see https://dev.openwrt.org/ticket/10381
config rule
option name Allow-DHCPv6
option src wan
option proto udp
option src_ip fe80::/10
option src_port 547
option dest_ip fe80::/10
option dest_port 546
option family ipv6
option target ACCEPT
option hidden 1
# Allow essential incoming IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Input
option src wan
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
list icmp_type router-solicitation
list icmp_type neighbour-solicitation
list icmp_type router-advertisement
list icmp_type neighbour-advertisement
option limit 1000/sec
option family ipv6
option target ACCEPT
option hidden 1
# Allow essential forwarded IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Forward
option src wan
option dest *
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
option limit 1000/sec
option family ipv6
option target ACCEPT
option hidden 1
# include a file with users custom iptables rules
config include
option path /etc/firewall.user
option reload 1
# include a file with rules for SIP and RTP traffic
config include
option path /etc/firewall.sip
option reload 1

View File

@@ -1,23 +0,0 @@
config atm_bridge
option link_type 'EoA'
option encapseoa 'llcsnap_eth'
option unit '0'
option ifname 'atm0.1'
option baseifname 'atm0'
option atmtype 'ubr'
option name 'atm_inet'
option vpi '8'
option vci '35'
config atm_bridge
option link_type 'EoA'
option encapseoa 'llcsnap_eth'
option unit '1'
option ifname 'atm1.1'
option baseifname 'atm1'
option atmtype 'ubr'
option name 'atm_tv'
option vpi '8'
option vci '45'

View File

@@ -1,5 +0,0 @@
config ethernet_interface 'Wan'
option baseifname '$WAN'
option ifname '$WAN.1'
option name 'WAN'

View File

@@ -1,9 +0,0 @@
config vdsl_interface
option unit '0'
option ifname 'ptm0.1'
option baseifname 'ptm0'
option name 'VDSL2'
option dslat '1'
option ptmprio '1'
option ipqos '1'

View File

@@ -1,18 +0,0 @@
config 'vlan_interface'
option name 'eth_tv'
option ifname '$WAN.100'
option baseifname '$WAN'
option vlan8021q '100'
option vlan8021p '0'
option bridge '1'
config 'vlan_interface'
option name 'vdsl_tv'
option ifname 'ptm0.100'
option baseifname 'ptm0'
option vlan8021q '100'
option vlan8021p '0'
option bridge '1'

View File

@@ -1,18 +0,0 @@
config mcpd 'mcpd'
option igmp_query_response_interval '10'
option igmp_last_member_query_interval '10'
option igmp_robustness_value '2'
option igmp_lan_to_lan_multicast '0'
option igmp_max_groups '25'
option igmp_max_sources '10'
option igmp_max_members '25'
option igmp_fast_leave '1'
option igmp_join_immediate '0'
option igmp_proxy_enable '0'
option igmp_snooping_enable '2'
option igmp_snooping_interfaces 'br-iptv'
option igmp_default_version '2'
option igmp_query_interval '120'
option igmp_proxy_interfaces 'iptv'

View File

@@ -1,37 +0,0 @@
config interface 'loopback'
option is_lan '1'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config interface 'lan'
option is_lan '1'
option type 'bridge'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.255.0'
option ifname '$LAN1 $LAN2 $LAN3'
option ip6assign '60'
config interface 'wan'
option type 'anywan'
option proto 'dhcp'
option vendorid '$HARDWAREID-INTENO'
option hostname 'Inteno_$MAC4'
option ifname 'ptm0.1 atm0.1 $WAN.1'
option ipv6 '1'
config interface 'iptv'
option type 'bridge'
option proto 'dhcp'
option gateway '0.0.0.0'
option reqopts 'staticroutes'
option ifname 'ptm0.100 atm1.1 $WAN.100 $LAN4'
option defaultroute '0'
config interface 'wan6'
option proto 'dhcpv6'
option ifname '@wan'

View File

@@ -1,13 +0,0 @@
{
"description": [
{ "en" : "VoIP + Bridged IPTV" },
{ "sv" : "VoIP + Brygg IPTV" }
],
"explanation": [
{ "en" : "VoIP on dedicated VLAN + LAN4 port is bridged with IPTV VLAN" },
{ "sv" : "VoIP on dedicated VLAN + LAN4 port överbryggas med IPTV VLAN" }
],
"credentials" : 0,
"excluded_boards" : "CG300 CG301"
}

View File

@@ -1,22 +0,0 @@
config dnsmasq
option domainneeded 1
option boguspriv 1
option filterwin2k 0
option localise_queries 1
option rebind_protection 0
option rebind_localhost 1
option local '/lan/'
option domain 'lan'
option expandhosts 1
option nonegcache 0
option authoritative 1
option readethers 1
option leasefile '/tmp/dhcp.leases'
option resolvfile '/tmp/resolv.conf.auto'
config dhcp lan
option interface lan
option start 100
option limit 150
option leasetime 12h

View File

@@ -1,114 +0,0 @@
config defaults
option syn_flood 1
option input ACCEPT
option output ACCEPT
option forward REJECT
# Uncomment this line to disable ipv6 rules
# option disable_ipv6 1
config zone
option name lan
list network 'lan'
option input ACCEPT
option output ACCEPT
option forward ACCEPT
config zone
option name wan
list network 'wan'
list network 'wan6'
list network 'iptv'
option input REJECT
option output ACCEPT
option forward REJECT
option masq 1
option mtu_fix 1
config forwarding
option src lan
option dest wan
# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
option name Allow-DHCP-Renew
option src wan
option proto udp
option dest_port 68
option target ACCEPT
option family ipv4
option hidden 1
# Allow IPv4 ping
config rule
option name Allow-Ping
option src wan
option proto icmp
option icmp_type echo-request
option family ipv4
option target ACCEPT
option hidden 1
# Allow DHCPv6 replies
# see https://dev.openwrt.org/ticket/10381
config rule
option name Allow-DHCPv6
option src wan
option proto udp
option src_ip fe80::/10
option src_port 547
option dest_ip fe80::/10
option dest_port 546
option family ipv6
option target ACCEPT
option hidden 1
# Allow essential incoming IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Input
option src wan
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
list icmp_type router-solicitation
list icmp_type neighbour-solicitation
list icmp_type router-advertisement
list icmp_type neighbour-advertisement
option limit 1000/sec
option family ipv6
option target ACCEPT
option hidden 1
# Allow essential forwarded IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Forward
option src wan
option dest *
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
option limit 1000/sec
option family ipv6
option target ACCEPT
option hidden 1
# include a file with users custom iptables rules
config include
option path /etc/firewall.user
option reload 1
# include a file with rules for SIP and RTP traffic
config include
option path /etc/firewall.sip
option reload 1

View File

@@ -1,34 +0,0 @@
config atm_bridge
option link_type 'EoA'
option encapseoa 'llcsnap_eth'
option unit '0'
option ifname 'atm0.1'
option baseifname 'atm0'
option atmtype 'ubr'
option name 'atm_inet'
option vpi '8'
option vci '35'
config atm_bridge
option link_type 'EoA'
option encapseoa 'llcsnap_eth'
option unit '1'
option ifname 'atm1.1'
option baseifname 'atm1'
option atmtype 'ubr'
option name 'atm_tv'
option vpi '8'
option vci '45'
config atm_bridge
option link_type 'EoA'
option encapseoa 'llcsnap_eth'
option unit '1'
option ifname 'atm2.1'
option baseifname 'atm2'
option atmtype 'ubr'
option name 'atm_voip'
option vpi '8'
option vci '55'

View File

@@ -1,5 +0,0 @@
config ethernet_interface 'Wan'
option baseifname '$WAN'
option ifname '$WAN.1'
option name 'WAN'

View File

@@ -1,9 +0,0 @@
config vdsl_interface
option unit '0'
option ifname 'ptm0.1'
option baseifname 'ptm0'
option name 'VDSL2'
option dslat '1'
option ptmprio '1'
option ipqos '1'

View File

@@ -1,32 +0,0 @@
config 'vlan_interface'
option name 'eth_tv'
option ifname '$WAN.100'
option baseifname '$WAN'
option vlan8021q '100'
option vlan8021p '0'
option bridge '1'
config 'vlan_interface'
option name 'eth_voip'
option ifname '$WAN.200'
option baseifname '$WAN'
option vlan8021q '200'
option vlan8021p '0'
config 'vlan_interface'
option name 'vdsl_tv'
option ifname 'ptm0.100'
option baseifname 'ptm0'
option vlan8021q '100'
option vlan8021p '0'
option bridge '1'
config 'vlan_interface'
option name 'vdsl_voip'
option ifname 'ptm0.200'
option baseifname 'ptm0'
option vlan8021q '200'
option vlan8021p '0'

View File

@@ -1,18 +0,0 @@
config mcpd 'mcpd'
option igmp_query_response_interval '10'
option igmp_last_member_query_interval '10'
option igmp_robustness_value '2'
option igmp_lan_to_lan_multicast '0'
option igmp_max_groups '25'
option igmp_max_sources '10'
option igmp_max_members '25'
option igmp_fast_leave '1'
option igmp_join_immediate '0'
option igmp_proxy_enable '0'
option igmp_snooping_enable '2'
option igmp_snooping_interfaces 'br-iptv'
option igmp_default_version '2'
option igmp_query_interval '120'
option igmp_proxy_interfaces 'iptv'

View File

@@ -1,45 +0,0 @@
config interface 'loopback'
option is_lan '1'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config interface 'lan'
option is_lan '1'
option type 'bridge'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.255.0'
option ifname '$LAN1 $LAN2 $LAN3'
option ip6assign '60'
config interface 'wan'
option type 'anywan'
option proto 'dhcp'
option vendorid '$HARDWAREID-INTENO'
option hostname 'Inteno_$MAC4'
option ifname 'ptm0.1 atm0.1 $WAN.1'
option ipv6 '1'
config interface 'iptv'
option type 'bridge'
option proto 'dhcp'
option gateway '0.0.0.0'
option reqopts 'staticroutes'
option ifname 'ptm0.100 atm1.1 $WAN.100 $LAN4'
option defaultroute '0'
config interface 'voip'
option type 'anywan'
option proto 'dhcp'
option gateway '0.0.0.0'
option reqopts 'staticroutes'
option ifname 'ptm0.200 atm2.1 $WAN.200'
option defaultroute '0'
config interface 'wan6'
option proto 'dhcpv6'
option ifname '@wan'

View File

@@ -1,13 +0,0 @@
{
"description": [
{ "en" : "Wireless Repeater" },
{ "sv" : "Trådlös Repeater" }
],
"explanation": [
{ "en" : "Your router is going to act as a wired extender or wireless repeater to the selected Wireless Access Point." },
{ "sv" : "Routern kommer att fungera som en trådbunden extender eller trådlös repeater till den valda trådlösa åtkomstpunkten." }
],
"credentials" : 1,
"reboot" : 0
}

View File

@@ -1,121 +0,0 @@
config defaults
option syn_flood 1
option input ACCEPT
option output ACCEPT
option forward REJECT
# Uncomment this line to disable ipv6 rules
# option disable_ipv6 1
config zone
option name lan
list network 'lan'
option input ACCEPT
option output ACCEPT
option forward ACCEPT
config zone
option name wan
list network 'wan'
option input REJECT
option output ACCEPT
option forward REJECT
option masq 1
option mtu_fix 1
config forwarding
option src lan
option dest wan
# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
option name Allow-DHCP-Renew
option src wan
option proto udp
option dest_port 68
option target ACCEPT
option family ipv4
option hidden 1
config rule
option name Repeater-Management
option src wan
option proto tcp
option dest_port '22 80 8080 8181 9876'
option target ACCEPT
option family ipv4
option hidden 1
# Allow IPv4 ping
config rule
option name Allow-Ping
option src wan
option proto icmp
option icmp_type echo-request
option family ipv4
option target ACCEPT
option hidden 1
# Allow DHCPv6 replies
# see https://dev.openwrt.org/ticket/10381
config rule
option name Allow-DHCPv6
option src wan
option proto udp
option src_ip fe80::/10
option src_port 547
option dest_ip fe80::/10
option dest_port 546
option family ipv6
option target ACCEPT
option hidden 1
# Allow essential incoming IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Input
option src wan
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
list icmp_type router-solicitation
list icmp_type neighbour-solicitation
list icmp_type router-advertisement
list icmp_type neighbour-advertisement
option limit 1000/sec
option family ipv6
option target ACCEPT
option hidden 1
# Allow essential forwarded IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Forward
option src wan
option dest *
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
option limit 1000/sec
option family ipv6
option target ACCEPT
option hidden 1
# include a file with users custom iptables rules
config include
option path /etc/firewall.user
option reload 1
# include a file with rules for SIP and RTP traffic
config include
option path /etc/firewall.sip
option reload 1

View File

@@ -1,6 +0,0 @@
config ethernet_interface 'Wan'
option baseifname '$WAN'
option ifname '$WAN.1'
option name 'WAN'
option bridge '1'

View File

@@ -1,24 +0,0 @@
config interface 'loopback'
option is_lan '1'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config interface 'wan'
option type 'bridge'
option proto 'dhcp'
option vendorid 'Inteno_Repeater_$MAC4'
option hostname 'Inteno_Repeater_$MAC4'
option ifname '$WAN.1'
option reqopts '43'
config interface 'lan'
option is_lan '1'
option type 'bridge'
option proto 'static'
option ifname '$LAN1 $LAN2 $LAN3 $LAN4'
option ipaddr '192.168.11.1'
option netmask '255.255.255.0'

View File

@@ -1,33 +0,0 @@
config uhttpd 'main'
list listen_http '0.0.0.0:80'
list listen_http '[::]:80'
list listen_http '0.0.0.0:8080'
list listen_http '[::]:8080'
list listen_http '0.0.0.0:8181'
list listen_http '[::]:8181'
list listen_https '0.0.0.0:443'
list listen_https '[::]:443'
option redirect_https '1'
option home '/www'
option rfc1918_filter '1'
option max_requests '3'
option max_connections '100'
option cert '/etc/uhttpd.crt'
option key '/etc/uhttpd.key'
option cgi_prefix '/cgi-bin'
option script_timeout '60'
option network_timeout '30'
option http_keepalive '20'
option tcp_keepalive '1'
option ubus_prefix '/ubus'
config cert 'px5g'
option days '730'
option bits '1024'
option country 'ZZ'
option state 'Somewhere'
option location 'Uknown'
option commonname 'OpenWrt'
config logopts 'logopts'

View File

@@ -1,101 +0,0 @@
config wifi-status 'status'
option wlan '1'
option wps '1'
option sched_status '0'
option schedule '0'
config wifi-device 'wl0'
option type 'broadcom'
option country 'EU/13'
option band 'a'
option bandwidth '20'
option hwmode '11ac'
option channel 'auto'
option scantimer '15'
option wmm '1'
option wmm_noack '0'
option wmm_apsd '0'
option txpower '100'
option rateset 'default'
option frag '2346'
option rts '2347'
option dtim_period '1'
option beacon_int '100'
option rxchainps '0'
option rxchainps_qt '10'
option rxchainps_pps '10'
option rifs '0'
option rifs_advert '0'
option maxassoc '32'
option beamforming '0'
option doth '1'
option dfsc '1'
config wifi-iface
option device 'wl0'
option network 'wan'
option mode 'ap'
option ssid 'Inteno-$BSSID4'
option encryption 'psk2'
option cipher 'auto'
option key '$WPAKEY'
option gtk_rekey '3600'
option macfilter '0'
option wps_pbc '1'
option wmf_bss_enable '1'
option bss_max '32'
option autoconf '1'
config wifi-device 'wl1'
option type 'broadcom'
option country 'EU/13'
option band 'b'
option bandwidth '20'
option hwmode 'auto'
option channel 'auto'
option scantimer '15'
option wmm '1'
option wmm_noack '0'
option wmm_apsd '0'
option txpower '100'
option rateset 'default'
option frag '2346'
option rts '2347'
option dtim_period '1'
option beacon_int '100'
option rxchainps '0'
option rxchainps_qt '10'
option rxchainps_pps '10'
option rifs '0'
option rifs_advert '0'
option maxassoc '32'
option doth '0'
option apsta '1'
config wifi-iface
option device 'wl1'
option ifname 'wl1'
option network 'wan'
option mode 'wet'
option ssid 'Inteno-$BSSID4'
option encryption 'psk2'
option cipher 'auto'
option wps_pbc '0'
option wmf_bss_enable '1'
option autoconf '1'
config wifi-iface
option device 'wl1'
option network 'wan'
option mode 'ap'
option ssid 'Inteno-$BSSID4'
option encryption 'psk2'
option cipher 'auto'
option key '$WPAKEY'
option gtk_rekey '3600'
option macfilter '0'
option wps_pbc '1'
option wmf_bss_enable '1'
option bss_max '32'
option autoconf '1'

View File

@@ -1,12 +0,0 @@
{
"description": [
{ "en" : "Fully Routed (NAT)" },
{ "sv" : "Fullt Omdirigerad (NAT)" }
],
"explanation": [
{ "en" : "" },
{ "sv" : "" }
],
"credentials" : 0
}

View File

@@ -1,22 +0,0 @@
config dnsmasq
option domainneeded 1
option boguspriv 1
option filterwin2k 0
option localise_queries 1
option rebind_protection 0
option rebind_localhost 1
option local '/lan/'
option domain 'lan'
option expandhosts 1
option nonegcache 0
option authoritative 1
option readethers 1
option leasefile '/tmp/dhcp.leases'
option resolvfile '/tmp/resolv.conf.auto'
config dhcp lan
option interface lan
option start 100
option limit 150
option leasetime 12h

View File

@@ -1,153 +0,0 @@
config settings settings
option disabled 0
config defaults
option syn_flood 1
option input ACCEPT
option output ACCEPT
option forward REJECT
# Uncomment this line to disable ipv6 rules
# option disable_ipv6 1
config zone
option name lan
list network 'lan'
option input ACCEPT
option output ACCEPT
option forward ACCEPT
config zone
option name wan
list network 'wan'
list network 'wan6'
option input REJECT
option output ACCEPT
option forward REJECT
option masq 1
option mtu_fix 1
config forwarding
option src lan
option dest wan
# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
option name Allow-DHCP-Renew
option src wan
option proto udp
option dest_port 68
option target ACCEPT
option family ipv4
# Allow IPv4 ping
config rule
option name Allow-Ping
option src wan
option proto icmp
option icmp_type echo-request
option family ipv4
option target ACCEPT
config rule
option name Allow-IGMP
option src wan
option proto igmp
option family ipv4
option target ACCEPT
# Allow DHCPv6 replies
# see https://dev.openwrt.org/ticket/10381
config rule
option name Allow-DHCPv6
option src wan
option proto udp
option src_ip fe80::/10
option src_port 547
option dest_ip fe80::/10
option dest_port 546
option family ipv6
option target ACCEPT
config rule
option name Allow-MLD
option src wan
option proto icmp
option src_ip fe80::/10
list icmp_type '130/0'
list icmp_type '131/0'
list icmp_type '132/0'
list icmp_type '143/0'
option family ipv6
option target ACCEPT
# Allow essential incoming IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Input
option src wan
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
list icmp_type router-solicitation
list icmp_type neighbour-solicitation
list icmp_type router-advertisement
list icmp_type neighbour-advertisement
option limit 1000/sec
option family ipv6
option target ACCEPT
# Allow essential forwarded IPv6 ICMP traffic
config rule
option name Allow-ICMPv6-Forward
option src wan
option dest *
option proto icmp
list icmp_type echo-request
list icmp_type echo-reply
list icmp_type destination-unreachable
list icmp_type packet-too-big
list icmp_type time-exceeded
list icmp_type bad-header
list icmp_type unknown-header-type
option limit 1000/sec
option family ipv6
option target ACCEPT
# allow IPsec/ESP and ISAKMP passthrough
config rule
option src wan
option dest lan
option proto esp
option target ACCEPT
config rule
option src wan
option dest lan
option dest_port 500
option proto udp
option target ACCEPT
config dmz dmz
option enabled '0'
option exclude_ports '5060 7547'
# include a file with users custom iptables rules
config include
option path /etc/firewall.user
option reload 1
# include a file with rules for prioritizing some specific packets
config include
option path /etc/firewall.qos
option reload 1
# include a file with rules for DMZ Host
config include dmzhost
option path /etc/firewall.dmz
option reload 1

View File

@@ -1,13 +0,0 @@
config atm_bridge
option link_type 'EoA'
option encapseoa 'llcsnap_eth'
option unit '0'
option ifname 'atm0.1'
option baseifname 'atm0'
option atmtype 'ubr'
option name 'atm_inet'
option vpi '8'
option vci '35'

View File

@@ -1,5 +0,0 @@
config ethernet_interface 'Wan'
option baseifname '$WAN'
option ifname '$WAN.1'
option name 'WAN'

View File

@@ -1,9 +0,0 @@
config vdsl_interface
option unit '0'
option ifname 'ptm0.1'
option baseifname 'ptm0'
option name 'VDSL2'
option dslat '1'
option ptmprio '1'
option ipqos '1'

View File

@@ -1,14 +0,0 @@
config mcpd 'mcpd'
option igmp_proxy_interfaces 'wan'
option igmp_default_version '2'
option igmp_query_interval '125'
option igmp_query_response_interval '100'
option igmp_last_member_query_interval '10'
option igmp_robustness_value '2'
option igmp_max_groups '25'
option igmp_max_sources '10'
option igmp_max_members '25'
option igmp_fast_leave '1'
option igmp_proxy_enable '1'
option igmp_snooping_enable '2'
option igmp_snooping_interfaces 'br-lan'

View File

@@ -1,29 +0,0 @@
config interface 'loopback'
option is_lan '1'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config interface 'lan'
option is_lan '1'
option type 'bridge'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.255.0'
option ifname '$LAN1 $LAN2 $LAN3 $LAN4'
option ip6assign '60'
config interface 'wan'
option type 'anywan'
option proto 'dhcp'
option vendorid '$HARDWAREID-INTENO'
option hostname 'Inteno_$MAC4'
option ifname 'ptm0.1 atm0.1 $WAN.1'
option ipv6 '1'
config interface 'wan6'
option proto 'dhcpv6'
option ifname '@wan'

View File

@@ -4,6 +4,7 @@ CONFIG_CCACHE=y
CONFIG_DEBUG=y
CONFIG_DEVEL=y
CONFIG_LOCALMIRROR="http://mirror.inteno.se/mirror"
CONFIG_PACKAGE_4g-support=y
CONFIG_PACKAGE_6in4=y
CONFIG_PACKAGE_6rd=y
CONFIG_PACKAGE_6to4=y
@@ -12,8 +13,6 @@ CONFIG_PACKAGE_alsa-lib=y
CONFIG_PACKAGE_bind-host=y
CONFIG_PACKAGE_chat=y
CONFIG_PACKAGE_comgt=y
CONFIG_PACKAGE_comgt-directip=y
CONFIG_PACKAGE_comgt-ncm=y
CONFIG_PACKAGE_crashlog=y
CONFIG_PACKAGE_ddns-scripts=y
CONFIG_PACKAGE_ds-lite=y
@@ -32,14 +31,10 @@ CONFIG_PACKAGE_ice-client-monitor=m
CONFIG_PACKAGE_ice-client-netrounds=m
CONFIG_PACKAGE_ice-client-rshell=m
CONFIG_PACKAGE_ice-client-texec=m
# CONFIG_PACKAGE_icgroupd is not set
CONFIG_PACKAGE_icwmp-curl=y
CONFIG_PACKAGE_inteno-netmodes=y
CONFIG_PACKAGE_iperf-mt=y
CONFIG_PACKAGE_ipset=y
CONFIG_PACKAGE_iptables=y
CONFIG_PACKAGE_iptables-mod-conntrack-extra=y
CONFIG_PACKAGE_iptables-mod-filter=y
CONFIG_PACKAGE_iptables-mod-ipopt=y
CONFIG_PACKAGE_iup=y
CONFIG_PACKAGE_iwatchdog=y
CONFIG_PACKAGE_juci=y
@@ -62,6 +57,7 @@ CONFIG_PACKAGE_juci-igmpinfo=y
CONFIG_PACKAGE_juci-inteno-backup=y
CONFIG_PACKAGE_juci-inteno-multiwan=y
CONFIG_PACKAGE_juci-inteno-provisioning=y
CONFIG_PACKAGE_juci-inteno-router=y
CONFIG_PACKAGE_juci-inteno-qos=y
CONFIG_PACKAGE_juci-inteno-voice-client=y
CONFIG_PACKAGE_juci-macdb=y
@@ -85,11 +81,11 @@ CONFIG_PACKAGE_juci-utils=y
CONFIG_PACKAGE_kmod-nls-base=y
CONFIG_PACKAGE_kmod-siit=y
CONFIG_PACKAGE_layer2interface=y
CONFIG_PACKAGE_libcgroup-daemon=y
CONFIG_PACKAGE_libcgroup=y
# CONFIG_PACKAGE_libcgroup-utils is not set
CONFIG_PACKAGE_ldd=y
# CONFIG_PACKAGE_libcgroup=y
# CONFIG_PACKAGE_libcgroup-daemon=y
CONFIG_PACKAGE_libdaemon=y
CONFIG_PACKAGE_libffmpeg-mini=y
CONFIG_PACKAGE_libgmp=y
CONFIG_PACKAGE_libreadline=y
CONFIG_PACKAGE_minidlna=y
@@ -99,6 +95,13 @@ CONFIG_PACKAGE_mtd-utils-deubinize=y
CONFIG_PACKAGE_mtd-utils-imagewrite=y
CONFIG_PACKAGE_mtd-utils-mkfs.jffs2=y
CONFIG_PACKAGE_mtd-utils-nanddump=y
CONFIG_PACKAGE_mtd-utils-ubiattach=y
CONFIG_PACKAGE_mtd-utils-ubidetach=y
CONFIG_PACKAGE_mtd-utils-ubimkvol=y
CONFIG_PACKAGE_mtd-utils-ubinfo=y
CONFIG_PACKAGE_mtd-utils-ubirmvol=y
CONFIG_PACKAGE_mtd-utils-ubirsvol=y
CONFIG_PACKAGE_mtd-utils-ubiupdatevol=y
CONFIG_PACKAGE_multiwan=y
CONFIG_PACKAGE_ndisc6=y
CONFIG_PACKAGE_netcheck=y
@@ -115,7 +118,6 @@ CONFIG_PACKAGE_power-management=y
CONFIG_PACKAGE_ppp-mod-pppoa=y
CONFIG_PACKAGE_ppp-mod-pppol2tp=y
CONFIG_PACKAGE_ppp-multilink=y
# CONFIG_PACKAGE_ppp is not set
CONFIG_PACKAGE_qos-scripts=y
CONFIG_PACKAGE_qrencode=y
CONFIG_PACKAGE_questd=y
@@ -132,15 +134,13 @@ CONFIG_PACKAGE_tcpdump=y
CONFIG_PACKAGE_terminfo=y
CONFIG_PACKAGE_tptest=y
CONFIG_PACKAGE_traceroute6=y
CONFIG_PACKAGE_umbim=y
CONFIG_PACKAGE_uqmi=y
CONFIG_PACKAGE_usb-modeswitch=y
CONFIG_PACKAGE_usbreset=y
CONFIG_PACKAGE_wwan=y
CONFIG_PACKAGE_xl2tpd=y
CONFIG_PACKAGE_zoneinfo-core=y
CONFIG_PACKAGE_zoneinfo-europe=y
CONFIG_TARGET_CUSTOMER="INT"
CONFIG_TARGET_ROOTFS_JFFS2=y
CONFIG_TARGET_ROOTFS_TARGZ=y
# CONFIG_USE_SSTRIP is not set
CONFIG_USE_STRIP=y
@@ -161,6 +161,7 @@ CONFIG_BUSYBOX_CONFIG_LSUSB=y
CONFIG_BUSYBOX_CONFIG_MICROCOM=y
CONFIG_BUSYBOX_CONFIG_RMMOD=y
CONFIG_BUSYBOX_CONFIG_STTY=y
CONFIG_BUSYBOX_CONFIG_TASKSET=y
CONFIG_BUSYBOX_CONFIG_TFTP=y
# CONFIG_BUSYBOX_CONFIG_FEATURE_2_4_MODULES is not set
CONFIG_BUSYBOX_CONFIG_FEATURE_CHECK_TAINTED_MODULE=y
@@ -191,4 +192,3 @@ CONFIG_BUSYBOX_CONFIG_FEATURE_TFTP_PUT=y
CONFIG_LIBCURL_CRYPTO_AUTH=y
CONFIG_OPENVPN_openssl_ENABLE_IPROUTE2=y
# CONFIG_SAMBA3_CONFIG_NO_PRINTING is not set
# CONFIG_SIGNED_PACKAGES is not set

View File

@@ -1,89 +0,0 @@
# Bash completion for IOPSYS "./iop" utility
# Source this file into the curent shell or copy it into
# /usr/share/bash-completion/completions/ and start a new shell
# for automatic availability.
_iop_get_profiles()
{
find feeds/feed_inteno_targets/iopsys-*/ -name '*.diff' \
|awk -F'/' '{print$NF}' \
|awk -F. '{print$1}'
}
_iop_get_models()
{
find feeds/feed_inteno_targets/iopsys-*/ -mindepth 1 -maxdepth 1 -type d \
|awk -F'/' '{print$NF}' \
|egrep '^(cg|dg|eg|vg|vox)[0-9]'
}
_iop_get_model_customers()
{
local model=$1
find customerconfigs/$prev -mindepth 1 -maxdepth 1 -type d \
|awk -F'/' '{print$NF}'
}
_iop()
{
local cur prev iopcmds
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
prev="${COMP_WORDS[COMP_CWORD-1]}"
iopcmds="bootstrap cfe_upgrade cfe_upgrade_latest extract_core \
feeds_update genconfig generate_tarballs install_key \
scp_changes setup_host ssh_install_key ssh_sysupgrade \
ssh_sysupgrade_latest ssh_sysupgrade_latest_w status \
update_package"
if [ $COMP_CWORD -eq 1 ] ; then
# Complete the primary iop command
COMPREPLY=($(compgen -W "${iopcmds}" -- ${cur}))
return 0
else
# Complete the arguments to "iopcmds"
local cmd="${COMP_WORDS[1]}"
case "$cmd" in
extract_core)
if [ "$prev" == "-e" ] ; then
_filedir -d
else
COMPREPLY=( $(compgen -W "-e -h" -- ${cur}) )
fi
return 0
;;
genconfig)
if [ "$prev" == "-p" ] ; then
local profiles=$(_iop_get_profiles)
COMPREPLY=( $(compgen -W "juci $profiles" -- ${cur}) )
elif [[ $cur == -* ]] ; then
COMPREPLY=( $(compgen -W "-c -h -p -s -t -u -v" -- ${cur}) )
else
local models=$(_iop_get_models)
if echo $models |grep -qw -- $prev ; then
local customers=$(_iop_get_model_customers $prev)
COMPREPLY=( $(compgen -W "$customers" -- ${cur}) )
else
COMPREPLY=( $(compgen -W "$models" -- ${cur}) )
fi
fi
return 0
;;
*)
# No arguments or arguments not supported yet
;;
esac
fi
}
complete -F _iop ./iop
complete -F _iop iop

View File

@@ -1,88 +0,0 @@
#!/bin/bash
# Intermediate repo for core packages
core_repo=git@public.inteno.se:iopsys-cc-core.git
# Repo to which core packages should be imported
import_repo=git@public.inteno.se:feed-inteno-openwrt.git
import_branch=openwrt-cc-core
function export_core {
local path=$1
# export paths to their own branches in an intermediate repo
repo=$(basename $path)
git subtree push -q --prefix=$path $core_repo $repo
}
function update_core {
local path=$1
if [ ! -d $topdir/feeds/feed_inteno_openwrt ]; then
echo "You need to run ./iop feeds_update"
exit -1
fi
# ensure that we are synced with the remote
cd $topdir/feeds/feed_inteno_openwrt
git checkout $import_branch
git pull
# first install subtrees if they don't already exist
repo=$(basename $path)
git subtree add --prefix=$repo $core_repo $repo
# install subtrees in feed from intermediate repo
repo=$(basename $path)
echo "Exporting $repo"
git subtree pull -q -m "Exporting $repo" --prefix=$repo $core_repo $repo
# update import repo sync branch
git push origin $import_branch
}
function display_help {
echo "Usage: ./iop export_core -e path/to/package"
}
function extract_core {
# Dir of script location
topdir=$(pwd)
if [ $# -eq 0 ]; then
display_help
exit -1
fi
# Execute user command
while getopts "he:" opt; do
case $opt in
e)
path=${OPTARG}
echo "Extracting ${path} from core to ${import_repo}:${import_branch}"
export_core $path
update_core $path
;;
h)
display_help
exit 0
;;
\?)
display_help
exit -1
;;
esac
done
}
register_command "extract_core" "Extract core package to feeds_inteno_openwrt"

View File

@@ -43,9 +43,6 @@ function feeds_update {
./scripts/feeds install -f -p feed_inteno_packages mtd-utils
./scripts/feeds uninstall qrencode
./scripts/feeds install -f -p feed_inteno_packages qrencode
./scripts/feeds uninstall libwebsockets
./scripts/feeds uninstall libwebsockets-openssl
./scripts/feeds install -f -p feed_inteno_juci libwebsockets
rm -rf package/feeds/oldpackages/libzstream # have to run this for now since uninstall is not working every time

View File

@@ -9,6 +9,7 @@ function genconfig {
export CUSTCONF="customerconfigs"
export VERBOSE=0
export DEVELOPER=0
export TMPDIR="/tmp/builder/"
LOCAL_MIRROR="http://mirror.inteno.se/mirror"
iopsys_brcm63xx_mips="cg300 cg301 dg150 dg150v2 dg150alv2 dg200 dg200al dg301 dg301al eg300 vg50 vox25"
@@ -249,8 +250,10 @@ function genconfig {
esac
shift;
done
[ -d $TMPDIR ] || mkdir $TMPDIR
setup_dirs
create_and_copy_files "$1" "$2"
[ -d $TMPDIR ] && rm -rf $TMPDIR
use_local_mirror
fi
}

177
iop/scripts/setup_host.sh Executable file
View File

@@ -0,0 +1,177 @@
#!/bin/bash
function setup_host {
if [ "$(whoami)" != "root" ]; then
echo "Please run this script as root!"
exit 1
fi
packages_all="bison flex g++ g++-multilib zlib1g-dev gettext gawk svn-buildpackage libncurses5-dev ncurses-term git automake gtk-doc-tools liblzo2-dev uuid-dev execstack"
packages_perl="libconvert-binary-c-perl libdigest-crc-perl"
packages_x64="libc6-dev-i386 lib32z1"
packages_npm="npm nodejs yui-compressor"
curdir=$(pwd)
#===============#
# Prerequisites #
#===============#
mysh=$(ls -hl /bin/sh | awk -F'[ ,/]' '{print$NF}')
if [ "$mysh" != "bash" ]; then
echo "On Debian based systems, e.g. Ubuntu, /bin/sh must point to bash instead of $mysh"
read -p "Do you approve this change (y/n): " ans
if [ "$ans" == "y" ]; then
rm -f /bin/sh
ln -s bash /bin/sh
else
echo "Warning! You haven't pointed /bin/sh to bash."
cd $curdir
exit 1
fi
fi
echo "The packages below must be installed"
echo $packages_all $packages_perl
read -p "Do you approve insallation of these packages (y/n): " ans
if [ "$ans" == "y" ]; then
apt-get install $packages_all
apt-get install $packages_perl
else
cd $curdir
exit 1
fi
if [ "$(uname -m | awk '{print$1}')" == "x86_64" ]; then
echo "You are running a Linux Distribution based on 64-bit kernel"
echo "The packages below must be installed"
echo $packages_x64
read -p "Do you approve insallation of these packages (y/n): " ans
if [ "$ans" == "y" ]; then
apt-get install $packages_x64
else
cd $curdir
exit 1
fi
fi
echo "The packages below must be installed in order to be able to compile JUCI"
echo $packages_npm
read -p "Do you approve insallation of these packages (y/n): " ans
if [ "$ans" == "y" ]; then
apt-get install npm nodejs yui-compressor
npm install -g npm
npm install -g grunt-cli
npm install -g mocha
npm install -g bower
npm install -g uglify-js
npm install -g less
if [ "$(which node)" == "" ]; then
NODEJS=$(which nodejs)
if [ "$NODEJS" != "" ]; then
read -p "Found nodejs executable at $(which nodejs), but no path to 'node'. Do you want to create a symlink? (y/n): " ans
if [ "$ans" == "y" ]; then
ln -s "$NODEJS" "/usr/bin/node"
fi
fi
fi
user=$(who | head -1 | awk '{print$1}')
[ -n $user ] && chown -R $user:$user /home/$user/.npm/
else
cd $curdir
exit 1
fi
# Get the Broadcom toolchain from here and unpack the mips/arm package to /opt:
echo -n "Checking for Broadcom MIPS toolchain: "
if [ -d /opt/toolchains/crosstools-mips-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21 ]; then
install_mips=0
echo "YES"
else
install_mips=1
echo "NO"
fi
echo -n "Checking for Broadcom ARM toolchain: "
if [ -d /opt/toolchains/crosstools-arm-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21-NPTL ]; then
install_arm=0
echo "YES"
else
install_arm=1
echo "NO"
fi
if [ $install_mips -eq 1 -o $install_arm -eq 1 ]; then
read -p "Do you approve insallation of missing toolchains (y/n): " ans
if [ "$ans" == "y" ]; then
echo "Downloading toolchain"
else
cd $curdir
exit 1
fi
cd ~
wget http://iopsys.inteno.se/iopsys/toolchain/crosstools-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21.Rel1.2-full.tar.bz2
tar jxf crosstools-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21.Rel1.2-full.tar.bz2
cd /
if [ $install_mips -eq 1 ]; then
echo "Installing MIPS toolchain"
tar jxf ~/crosstools-mips-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21.Rel1.2.tar.bz2
fi
if [ $install_arm -eq 1 ]; then
echo "Installing ARM toolchain"
tar jxf ~/crosstools-arm-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21-NPTL.Rel1.2.tar.bz2
fi
rm -f ~/crosstools-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21-sources.tar.bz2
rm -f ~/crosstools-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21.Rel1.2-full.tar.bz2
rm -f ~/crosstools-mip*-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21.Rel1.2.tar.bz2
rm -f ~/crosstools-arm-gcc-4.6-linux-3.4-uclibc-0.9.32-binutils-2.21-NPTL.Rel1.2.tar.bz2
fi
gcc_ver=$(ls -l /usr/bin/gcc-[0-9]* | head -1 | awk '{print$NF}' | cut -d'-' -f2)
if [ "$gcc_ver" != "4.8" ]; then
echo "Your current gcc version is $gcc_ver, but it must be changed to 4.8"
read -p "Do you approve this change (y/n): " ans
if [ "$ans" == "y" ]; then
apt-get install gcc-4.8
apt-get install g++-4.8
apt-get install gcc-4.8-multilib
update-alternatives --install /usr/bin/g++ c++ /usr/bin/g++-4.8 100
update-alternatives --install /usr/bin/g++ c++ /usr/bin/g++-$gcc_ver 90
update-alternatives --install /usr/bin/gcc cc /usr/bin/gcc-4.8 100
update-alternatives --install /usr/bin/gcc cc /usr/bin/gcc-$gcc_ver 90
update-alternatives --install /usr/bin/cpp cpp /usr/bin/cpp-4.8 100
update-alternatives --install /usr/bin/cpp cpp /usr/bin/cpp-$gcc_ver 90
update-alternatives --set c++ /usr/bin/g++-4.8
update-alternatives --set cc /usr/bin/gcc-4.8
update-alternatives --set cpp /usr/bin/cpp-4.8
ln -s /etc/alternatives/cc /usr/bin/cc
echo "The deafult gcc version has now been changed from $gcc_ver to 4.8"
else
cd $curdir
exit 1
fi
fi
echo ""
echo ""
echo "You have successfully installed and configred prerequisites to be able to build an iopsys firmware"
echo ""
echo ""
cd $curdir
}
register_command "setup_host" "Install needed packets to host machine"

View File

@@ -17,7 +17,7 @@ define Package/iup
SECTION:=net
CATEGORY:=Network
TITLE:=iup client
DEPENDS:=+libuci +uci +busybox
DEPENDS:=+libuci +uci +busybox
endef
define Package/iup/description

View File

@@ -1,9 +1,6 @@
#!/bin/sh
echo $$ > /var/run/iup.pid
. /lib/functions.sh
. /lib/functions/network.sh
. /usr/share/libubox/jshn.sh
include /lib/upgrade
@@ -55,8 +52,8 @@ get_packages()
local pack
pack=$(grep -w 'package' $1)
pack=${pack//package/}
#pack=${pack//[\'|\"]/}
echo $pack | tr -d '\"' | tr -d "'"
pack=${pack//[\'|\"]/}
echo $pack
}
reload ()
@@ -234,141 +231,10 @@ handle_Downloaded_file()
fi
}
# function: change_to_vlan
# arg 1 = vlan id
# arg 2 = vlan priority
# arg 3 = $INTERFACE
change_to_vlan() {
# local variables.
local name="vlan$1" # construct name = vlan + vlanid.
local base_dev # varible holding device name of wan port.
local wan_if # variable holding wan interfaces.
local new_wan_if #
# extract device name.
network_get_device base_dev $3
# bring down old interface/device.
ifdown "${base_dev}"
logger -t dhcp_opt132 "bringing down old if: ${base_dev}"
# extract base name of device.
base_dev=$(echo ${base_dev} | cut -d. -f1)
# add "VLAN interface" to the "end of the file".
uci add layer2_interface_vlan vlan_interface
uci set layer2_interface_vlan.@vlan_interface[-1].name=${name}
uci set layer2_interface_vlan.@vlan_interface[-1].vlan8021q=${1}
uci set layer2_interface_vlan.@vlan_interface[-1].vlan8021p=${2}
uci set layer2_interface_vlan.@vlan_interface[-1].ifname="${base_dev}.${1}"
uci set layer2_interface_vlan.@vlan_interface[-1].baseifname=${base_dev}
# and commit the change.
uci commit layer2_interface_vlan
logger -t dhcp_opt132 "committed update to file layer2_interface_vlan"
# reload configuration files.
/etc/init.d/layer2_interface_vlan reload
logger -t dhcp_opt132 "reload layer2_interface_vlan config"
# replace old interface (like eth0.1 with new eth0.101).
wan_if=$(uci get network.$3.ifname)
logger -t dhcp_opt132 "old network.${3}.ifname: $wan_if"
# loop through the string, remove any word close to "base_dev".
for word in ${wan_if}; do
#echo $word
case $word in
${base_dev}*) # don't add if.
;;
*) new_wan_if=${word}' '${new_wan_if} # add if.
#new_wan_if+=" ${word}" # probably not working in ash.
;;
esac
done
# append new interface.
new_wan_if=${new_wan_if}${base_dev}.${1}
uci set network.wan.ifname="${new_wan_if}"
# and commit the change.
uci commit network
logger -t dhcp_opt132 "committed update to file network: ifname=${new_wan_if}"
# reboot into new if configuration.
reboot
}
handle_option224()
{
if [ -z "$1" ] ; then
echo "No argument"
return 1
fi
if [ $(echo $1|grep -o "," | wc -l) -eq 0 ] ; then
url=$1
else
url=$(echo $1|cut -d',' -f1)
a=$(echo $1|cut -d',' -f2)
b=$(echo $1|cut -d',' -f3)
c=$(echo $1|cut -d',' -f4)
fi
echo "url" $url
echo "a" $a
echo "b" $b
echo "c" $c
currdate=$(date +"%Y-%m-%d")
active=0
if [ -z $a ] ; then
active=1
elif [ $a ] && [ $b ] && [ $a -lt 25 ] ; then
#Time
begin=$(date +%s -d"$currdate $a")
now=$(date +%s)
end=$((begin+3600*$b))
if [ $now -gt $begin ] && [ $now -lt $end ] ; then
active=1
fi
elif [ $a ] && [ $b ] && [ $c ] && [ $a -gt 25 ] ; then
#Date
y=$(echo $a| cut -c1-4)
m=$(echo $a| cut -c5-6)
d=$(echo $a| cut -c7-8)
begin=$(date +%s -d"$y-$m-$d $b")
now=$(date +%s)
end=$((begin+3600*$c))
if [ $now -gt $begin ] && [ $now -lt $end ] ; then
active=1
fi
else
echo "Bad format"
return 1
fi
softwareminuspath=${url##*/}
if [ $url ] && [ $active -eq 1 ]; then
echo "Software version to download $softwareminuspath"
local sysinfo=$(ubus call router quest "{ \"info\": \"system\" }")
json_load "$sysinfo"
json_get_var firmware firmware
local firmware_new=${softwareminuspath%.*} # remove extension (.w, .y or .y2) from filename
if [ "$firmware_new" != "$firmware" ] ; then
echo "Image found $url will start flashing"
wait_for_dns $url
/sbin/sysupgrade -v $url &
return 1
else
echo "Will not update software, already up to date"
return 0
fi
fi
}
### MAIN ###
###main
while [ -n "$1" ]; do
case "$1" in
-v) export VERBOSE="$(($VERBOSE + 1))";;
-q) export VERBOSE="$(($VERBOSE - 1))";;
-*)
@@ -380,65 +246,15 @@ while [ -n "$1" ]; do
shift;
done
# Process IUP related DHCP options #
if [ -n "$1" ]; then
local privopt224 vendorspecinf httpurl128
local tftp bootfile vlanid vlanpriority interface
json_load "$1"
json_get_var interface interface
json_get_var privopt224 privopt224
json_get_var vendorspecinf vendorspecinf
json_get_var httpurl128 httpurl128
json_get_var tftp tftp
json_get_var bootfile bootfile
json_get_var vlanid vlanid
json_get_var vlanpriority vlanpriority
if [ $privopt224 ]; then
echo "Option224 recived " $privopt224 > /dev/console
handle_option224 $privopt224
[ $? -eq 1 ] && exit
fi
if [ $vendorspecinf ]; then
url=${vendorspecinf%%,*}; rest=${vendorspecinf#*,}
provisioningcode=${rest%%,*};
uci_set_state provisioning iup url "$url"
uci_set_state provisioning iup provisioningcode "$provisioningcode"
elif [ $httpurl128 ]; then
uci_set_state provisioning iup urliup "$httpurl128"
elif [ $tftp ]; then
if [ ${bootfile:0:1} == '/' ]; then
uci_set_state provisioning iup urliup "tftp://$tftp$bootfile"
else
uci_set_state provisioning iup urliup "tftp://$tftp/$bootfile"
fi
fi
# if we get vlanid and maybe vlanpriority, configure for that.
if [ -n "$vlanid" -a -n "$vlanpriority" ]; then
logger -t dhcp_opt132 "vlanid: ${vlanid}, vlanpriority: ${vlanpriority}"
change_to_vlan ${vlanid} ${vlanpriority} ${interface}
elif [ -n "$vlanid" ]; then
logger -t dhcp_opt132 "vlanid: ${vlanid}"
change_to_vlan ${vlanid} 0 ${interface}
else
logger -t dhcp_opt132 "no vlanid given"
fi
fi
local iupurl
local configurl
local software
local sofwareminuspath
config_load provisioning
#check if iup should be used or if its overridden by /etc/config
config_get configurl configserver url
config_get reboot configserver reboot
config_get iupurl iup urliup
if [ $configurl ]; then
handle_provisioning configserver "0"
elif [ $iupurl ]; then
@@ -447,7 +263,6 @@ else
v "No Provisioning Server Found"
exit
fi
config_load provisioning
config_foreach handle_provisioning subconfig "0"
config_get software uppgradeserver url
@@ -480,5 +295,4 @@ if [ "$reboot" == "on" ]; then
v "Reboot Signaled"
/sbin/reboot
fi
rm -rf /var/run/iup.pid

72
iup/files/sbin/iup224 Executable file
View File

@@ -0,0 +1,72 @@
#!/bin/sh
. /usr/share/libubox/jshn.sh
. /lib/network/config.sh
if [ -z $1 ] ; then
echo "No argument"
exit 1
fi
if [ $(echo $1|grep -o "," | wc -l) -eq 0 ] ; then
url=$1
else
url=$(echo $1|cut -d',' -f1)
a=$(echo $1|cut -d',' -f2)
b=$(echo $1|cut -d',' -f3)
c=$(echo $1|cut -d',' -f4)
fi
echo "url" $url
echo "a" $a
echo "b" $b
echo "c" $c
currdate=$(date +"%Y-%m-%d")
active=0
if [ -z $a ] ; then
active=1
elif [ $a ] && [ $b ] && [ $a -lt 25 ] ; then
#Time
begin=$(date +%s -d"$currdate $a")
now=$(date +%s)
end=$((begin+3600*$b))
if [ $now -gt $begin ] && [ $now -lt $end ] ; then
active=1
fi
elif [ $a ] && [ $b ] && [ $c ] && [ $a -gt 25 ] ; then
#Date
y=$(echo $a| cut -c1-4)
m=$(echo $a| cut -c5-6)
d=$(echo $a| cut -c7-8)
begin=$(date +%s -d"$y-$m-$d $b")
now=$(date +%s)
end=$((begin+3600*$c))
if [ $now -gt $begin ] && [ $now -lt $end ] ; then
active=1
fi
else
echo "Bad format"
exit 1
fi
softwareminuspath=${url##*/}
if [ $url ] && [ $active -eq 1 ]; then
echo "Software version to download $softwareminuspath"
local sysinfo=$(ubus call router quest "{ \"info\": \"system\" }")
json_load "$sysinfo"
json_get_var firmware firmware
local firmware_new=${softwareminuspath%.*} # remove extension (.w, .y or .y2) from filename
if [ "$firmware_new" != "$firmware" ] ; then
echo "Image found $url will start flashing"
wait_for_dns $url
/sbin/sysupgrade -v $url &
exit 1
else
echo "Will not update software, already up to date"
exit 0
fi
fi

View File

@@ -48,7 +48,7 @@ endef
define Package/libcgroup-daemon
SECTION:=base
CATEGORY:=Base system
DEPENDS:=+libcgroup +librt
DEPENDS:=+libcgroup
TITLE:=Control group management daemon
URL:=https://sourceforge.net/p/libcg/
endef

View File

@@ -1,14 +0,0 @@
choice
depends on PACKAGE_libstrophe
prompt "Select XML library"
default libstrophe-expat
config libstrophe-expat
bool "expat"
select PACKAGE_libexpat
config libstrophe-libxml2
bool "libxml2"
select PACKAGE_libxml2
endchoice

View File

@@ -1,61 +0,0 @@
#
# Copyright (C) 2015 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=libstrophe
PKG_VERSION:=0.8.8
PKG_RELEASE=1
PKG_SOURCE_URL:=https://github.com/strophe/libstrophe/archive/
PKG_SOURCE:=$(PKG_VERSION).tar.gz
PKG_FIXUP:=autoreconf
PKG_INSTALL:=1
PKG_CONFIG_DEPENDS:= \
CONFIG_libstrophe-libxml2 \
CONFIG_libstrophe-expat
include $(INCLUDE_DIR)/package.mk
ifeq ($(CONFIG_libstrophe-libxml2),y)
CONFIGURE_ARGS += \
--with-libxml2
endif
define Package/libstrophe
SECTION:=libs
CATEGORY:=Libraries
TITLE:=XMPP client library
URL:=http://strophe.im/libstrophe
DEPENDS:= +libopenssl +libstrophe-libxml2:libxml2 +libstrophe-expat:libexpat
MENU:=1
endef
define Package/libstrophe/description
A simple, lightweight C library for writing XMPP clients
endef
define Package/libstrophe/config
source "$(SOURCE)/Config.in"
endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/
$(CP) $(PKG_INSTALL_DIR)/usr/include/ $(1)/usr/
$(INSTALL_DIR) $(1)/usr/lib/
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libstrophe.{la,a,so*} $(1)/usr/lib/
endef
define Package/libstrophe/install
$(INSTALL_DIR) $(1)/usr/lib/
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libstrophe.so.* $(1)/usr/lib
endef
$(eval $(call BuildPackage,libstrophe))

View File

@@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=natalie-dect-h
PKG_VERSION:=11.19
PKG_VERSION:=12.26
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_URL:=http://public.inteno.se:/natalie-dect-h
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=c2139d05e3d082f1dcf58ce3f19306cb76fd0873
PKG_SOURCE_VERSION:=9e2236989ff58d0db897f938b6b07b535144e0e2
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk

View File

@@ -8,9 +8,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=natalie-dect
PKG_VERSION:=11.19
PKG_VERSION:=12.26
PKG_SOURCE_VERSION:=2015e8106c7d541dd038381c2845bd8462d74a30
PKG_SOURCE_VERSION:=35fed3a10124bd660b74704011256039ba9cf54d
ifeq ($(CONFIG_NATALIE_OPEN),y)
BRCM_KERNEL_PROFILE=$(shell echo $(CONFIG_BCM_KERNEL_PROFILE) | sed s/\"//g)
PKG_SOURCE:=$(PKG_NAME)-$(BRCM_KERNEL_PROFILE)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
@@ -18,7 +18,7 @@ PKG_SOURCE_URL:=http://iopsys.inteno.se/iopsys/consumer/
PKG_NAME:=natalie-dect-open
else
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_URL:=git@private.inteno.se:natalie-dect-11.19
PKG_SOURCE_URL:=git@private.inteno.se:natalie-dect-12.26
PKG_SOURCE_PROTO:=git
endif
@@ -46,10 +46,6 @@ define Package/natalie-dect/description
Kernel dect driver
endef
define Package/natalie-dect/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(CONFIG_NATALIE_OPEN),y)
define Build/Compile
endef

View File

@@ -12,7 +12,7 @@ PKG_NAME:=peripheral_manager
PKG_VERSION:=1.0.0
PKG_RELEASE:=1
PKG_SOURCE_VERSION:=71c89213516c735b6c12d0e8c17a5bd75333421c
PKG_SOURCE_VERSION:=2a16b98543580d376d5862a34415f24d8be15b27
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=http://public.inteno.se/peripheral_manager

View File

@@ -6,9 +6,9 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=questd
PKG_VERSION:=3.1.8
PKG_VERSION:=3.1.6
PKG_SOURCE_VERSION:=4466c00f581968c4b2299d2464ffe283d906b758
PKG_SOURCE_VERSION:=2b2f6928fde8ce9f7ab41957418104487b5b8c33
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=http://public.inteno.se:/questd
@@ -49,6 +49,7 @@ define Package/questd/install
$(CP) ./files/* $(1)/
$(INSTALL_DIR) $(1)/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/questd $(1)/sbin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/ueventd $(1)/sbin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/uscriptd $(1)/sbin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/wificontrol $(1)/sbin/
endef

View File

@@ -16,11 +16,17 @@ start_service() {
procd_set_param command "/sbin/uscriptd"
procd_set_param respawn
procd_close_instance
procd_open_instance
procd_set_param command "/sbin/ueventd"
procd_set_param respawn
procd_close_instance
}
stop() {
service_stop /sbin/questd
service_stop /sbin/uscriptd
service_stop /sbin/ueventd
}
service_triggers()

View File

@@ -1,23 +0,0 @@
config SAMBA3_CONFIG_DEBUG
bool "Enable Logging for samba3"
depends on PACKAGE_samba3
default n
help
Enables debugging support (will make binaries *much* bigger)
Also increases MAX_DEBUG_LEVEL to get more messages (also increases binary sizes!)
config SAMBA3_CONFIG_SMALLER
bool "Make samba3 even smaller"
depends on PACKAGE_samba3
default y
help
Removes support for ???
Saves about 18kB for smbd, about 16kB for nmbd and about 17kB for smbpasswd
config SAMBA3_CONFIG_NO_PRINTING
bool "Remove shared printing support"
depends on PACKAGE_samba3
default y
help
Removes shared printing support.
Saves about 18kB for smbd, about 15kB for nmbd and about 18kB for smbpasswd

View File

@@ -1,146 +0,0 @@
#
# Copyright (C) 2008-2011 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
include $(TOPDIR)/rules.mk
PKG_NAME:=samba3
PKG_VERSION:=3.0.37
PKG_RELEASE:=1
PKG_MD5SUM:=11ed2bfef4090bd5736b194b43f67289
PKG_SOURCE_URL:=ftp://ftp.samba.org/pub/samba/old-versions/
PKG_SOURCE:=samba-$(PKG_VERSION).tar.gz
PKG_BUILD_DIR:=$(BUILD_DIR)/samba-$(PKG_VERSION)
PKG_BUILD_PARALLEL:=1
#PKG_FIXUP:=autoreconf
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
define Package/samba3/Default
SECTION:=net
CATEGORY:=Network
SUBMENU:=Filesystem
URL:=http://www.samba.org/
endef
define Package/samba3
$(call Package/samba3/Default)
TITLE:=SMB server for file and printer sharing
DEPENDS:=+libpthread +libpopt $(ICONV_DEPENDS) +libattr
endef
define Package/samba3-nmbd
$(call Package/samba3/Default)
TITLE:=NetBIOS name server
DEPENDS:=+samba3
endef
define Package/samba3-mountcifs
$(call Package/samba3/Default)
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Mount utility for samba shares
endef
define Package/samba3/description
SMB server for file and printer sharing
Also contains a SMB password utility (smbpasswd)
Made small with patches taken from AVM GPL releases and freetz
endef
define Package/samba3-nmbd/description
NetBIOS name server
Made small with patches taken from AVM GPL releases and freetz
endef
define Package/cifsmount/description
An user space helper utility for mounting remote CIFS shares.
endef
define Package/samba3/conffiles
/etc/config/samba
/etc/samba/smb.conf.template
endef
define Package/samba3/config
source "$(SOURCE)/Config.in"
endef
TARGET_CFLAGS+=$(if $(CONFIG_SAMBA3_CONFIG_DEBUG),-DSAMBA_DEBUG,-DMAX_DEBUG_LEVEL=2)
TARGET_CFLAGS+=$(if $(CONFIG_SAMBA3_CONFIG_SMALLER),-DAVM_SMALLER)
TARGET_CFLAGS+=$(if $(CONFIG_SAMBA3_CONFIG_NO_PRINTING),-DAVM_NO_PRINTING)
CONFIGURE_PATH:=source
CONFIGURE_ARGS+= \
$(if $(CONFIG_SAMBA3_CONFIG_DEBUG),--enable-debug) \
--without-krb5 \
--without-ads \
--without-ldap \
--enable-largefile \
--with-configdir=/etc/samba \
--with-libiconv=$(ICONV_PREFIX) \
--with-privatedir=/etc/samba
# Make sure we tell the configure script that we support negative enum values and want to use setresuid
CONFIGURE_VARS+= \
SMB_BUILD_CC_NEGATIVE_ENUM_VALUES=yes \
samba_cv_USE_SETEUID=no \
samba_cv_have_setresuid=yes \
samba_cv_USE_SETRESUID=yes \
samba_cv_HAVE_C99_VSNPRINTF=yes \
samba_cv_have_longlong=yes \
ac_cv_type_long_long=yes \
MAKE_PATH=source
MAKE_FLAGS += \
$(if $(CONFIG_SAMBA3_CONFIG_NO_PRINTING),OWRT_NO_PRINTING=1) \
$(if $(CONFIG_SAMBA3_CONFIG_SMALLER),OWRT_SMALLER=1)
#define Build/Configure
# $(SH) pushd $(PKG_BUILD_DIR)/source && ./autogen.sh ; popd
# $(Build/Configure/Default)
#endef
define Build/Compile
# Ugly fix for parallel building (without this some generated files will be missing upon clean build)
$(call Build/Compile/Default, proto_exists)
$(call Build/Compile/Default, \
$(if $(CONFIG_PACKAGE_samba3),bin/smbd bin/smbpasswd) \
$(if $(CONFIG_PACKAGE_samba3-nmbd),bin/nmbd) \
$(if $(CONFIG_PACKAGE_samba3-mountcifs),bin/mount.cifs bin/umount.cifs) \
)
endef
define Package/samba3/install
$(INSTALL_DIR) $(1)/etc/{samba,init.d,config}
$(INSTALL_BIN) ./files/samba.init $(1)/etc/init.d/samba
$(INSTALL_DATA) ./files/samba.config $(1)/etc/config/samba
$(INSTALL_DATA) ./files/smb.conf.template $(1)/etc/samba/
touch $(1)/etc/samba/smbpasswd
$(INSTALL_DIR) $(1)/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/source/bin/smbpasswd $(1)/bin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/source/bin/smbd $(1)/bin/
endef
define Package/samba3-nmbd/install
$(INSTALL_DIR) $(1)/etc/init.d
# $(INSTALL_BIN) ./files/samba-nmbd.init $(1)/etc/init.d/samba-nmbd
$(INSTALL_DIR) $(1)/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/source/bin/nmbd $(1)/bin/
endef
define Package/samba3-mountcifs/install
$(INSTALL_DIR) $(1)/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/source/bin/mount.cifs $(1)/bin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/source/bin/umount.cifs $(1)/bin/
endef
$(eval $(call BuildPackage,samba3))
$(eval $(call BuildPackage,samba3-nmbd))
$(eval $(call BuildPackage,samba3-mountcifs))

View File

@@ -1,56 +0,0 @@
#undef HAVE_CREAT64
#define HAVE_CREAT64 1
#undef HAVE_FSEEKO64
#define HAVE_FSEEKO64 1
#undef HAVE_FSTAT64
#define HAVE_FSTAT64 1
#undef HAVE_FTELLO64
#define HAVE_FTELLO64 1
#undef HAVE_FTRUNCATE64
#define HAVE_FTRUNCATE64 1
#undef HAVE_LSEEK64
#define HAVE_LSEEK64 1
#undef HAVE_LSTAT64
#define HAVE_LSTAT64 1
#undef HAVE_OPEN64
#define HAVE_OPEN64 1
#undef HAVE_PREAD64
#define HAVE_PREAD64 1
#undef HAVE_PWRITE64
#define HAVE_PWRITE64 1
#undef HAVE_READDIR64
#define HAVE_READDIR64 1
#undef HAVE_STAT64
#define HAVE_STAT64 1
#undef HAVE_STRUCT_FLOCK64
#define HAVE_STRUCT_FLOCK64 1
#undef SIZEOF_LONG_LONG
#define SIZEOF_LONG_LONG 8
#undef SIZEOF_OFF_T
#define SIZEOF_OFF_T 8
#undef _FILE_OFFSET_BITS
#define _FILE_OFFSET_BITS 64
#undef _GNU_SOURCE
#define _GNU_SOURCE 1
#undef _LARGEFILE_SOURCE
#define _LARGEFILE_SOURCE 1
#undef _LARGEFILE64_SOURCE
#define _LARGEFILE64_SOURCE 1

View File

@@ -1,12 +0,0 @@
#!/bin/sh /etc/rc.common
# Copyright (C) 2011 OpenWrt.org
START=61
start() {
service_start /bin/nmbd -D
}
stop() {
service_stop /bin/nmbd
}

View File

@@ -1,81 +0,0 @@
#!/bin/sh /etc/rc.common
# Copyright (C) 2008-2011 OpenWrt.org
START=60
smb_header() {
local name
local workgroup
local description
local homes
local interface
config_get name $1 name
config_get workgroup $1 workgroup
config_get description $1 description
config_get homes $1 homes
config_get interface $1 interface "lan"
# resolve interfaces
local interfaces=$(
include /lib/network
scan_interfaces
local net ifname; for net in $interface; do
config_get ifname "$net" ifname "$net"
echo -n "$ifname "
done
)
[ -z "$name" ] && name=openwrt
[ -z "$workgroup" ] && workgroup=openwrt
[ -z "$description" ] && description=openwrt
mkdir -p /var/etc
cp /etc/samba/smb.conf.template /var/etc/smb.conf
[ -L /etc/samba/smb.conf ] || ln -nsf /var/etc/smb.conf /etc/samba/smb.conf
sed -i "s/|NAME|/$name/g" /var/etc/smb.conf
sed -i "s/|WORKGROUP|/$workgroup/g" /var/etc/smb.conf
sed -i "s/|DESCRIPTION|/$description/g" /var/etc/smb.conf
sed -i "s/|INTERFACES|/$interfaces/g" /var/etc/smb.conf
[ "$homes" == "1" ] && {
echo -e "\n[homes]\n\tcomment = Home Directories\n\tbrowseable = no\n\tread only = no\n\tcreate mode = 0750" >> /var/etc/smb.conf
}
}
smb_add_share() {
local name
local path
local users
local read_only
local guest_ok
local create_mask
local dir_mask
config_get name $1 name
config_get path $1 path
config_get users $1 users
config_get read_only $1 read_only
config_get guest_ok $1 guest_ok
config_get create_mask $1 create_mask
config_get dir_mask $1 dir_mask
[ -z "$name" -o -z "$path" ] && return
echo -e "\n[$name]\n\tpath = $path" >> /var/etc/smb.conf
[ -n "$users" ] && echo -e "\tvalid users = $users" >> /var/etc/smb.conf
[ -n "$read_only" ] && echo -e "\tread only = $read_only" >> /var/etc/smb.conf
[ -n "$guest_ok" ] && echo -e "\tguest ok = $guest_ok" >> /var/etc/smb.conf
[ -n "$create_mask" ] && echo -e "\tcreate mask = $create_mask" >> /var/etc/smb.conf
[ -n "$dir_mask" ] && echo -e "\tdirectory mask = $dir_mask" >> /var/etc/smb.conf
}
start() {
config_load samba
config_foreach smb_header samba
config_foreach smb_add_share sambashare
service_start /bin/smbd -D
}
stop() {
service_stop /bin/smbd
}

View File

@@ -1,7 +0,0 @@
config samba
option 'name' 'IntenoSMB'
option 'workgroup' 'IntenoSMB'
option 'description' 'IntenoSMB'
option 'homes' '0'
option 'interface' 'lan'

View File

@@ -1,168 +0,0 @@
#!/bin/sh /etc/rc.common
# Copyright (C) 2008-2012 OpenWrt.org
START=60
STOP=40
USE_PROCD=1
useradd()
{
local user
local password
config_get user $1 user
config_get password $1 password
if ! $(grep -rq "^$user:" /etc/passwd) ; then
echo "adding user $user"
adduser $user -s /bin/false -D -H -h /mnt/$user -g "samba,pass=$password" && smbpasswd $user $password
else
tmp=$(grep -r "^$user:" /etc/passwd | cut -d":" -f5)
if $(echo $tmp | grep -rq "^samba") ; then
if [ "$tmp" != "samba,pass=$password" ] ; then
echo "change user $user"
deluser $user
adduser $user -s /bin/false -D -H -h /mnt/$user -g "samba,pass=$password" && smbpasswd $user $password
fi
else
echo "activating samba for system user $user"
smbpasswd $user $password
fi
fi
}
samba_user_exists()
{
local user
config_get user $1 user
[ "$user" == "$2" ] && echo "1" && break
}
purgepasswd()
{
for us in `grep -r "^.*:" /etc/samba/smbpasswd | cut -d":" -f1`; do
if [ -z "$(config_foreach samba_user_exists sambausers $us)" ] ; then
smbpasswd -del $us
grep -r "^$us:" /etc/passwd | cut -d":" -f5 | grep -rq "^samba" && deluser $us
fi
done
# delete left over samba users in case they were not in /etc/samba/smbpasswd
for us in `grep ":/mnt/" /etc/passwd | cut -d":" -f1`; do
deluser $us
done
}
smb_header() {
local interface
config_get interface $1 interface
# resolve interfaces
local interfaces=$(
. /lib/functions/network.sh
local net
for net in $interface; do
local device
network_get_device device "$net" && {
local subnet
network_get_subnet subnet "$net" && echo -n "$subnet "
network_get_subnet6 subnet "$net" && echo -n "$subnet "
}
echo -n "${device:-$net} "
done
)
local name workgroup description charset
local hostname="$(uci_get system.@system[0].hostname)"
config_get name $1 name "${hostname:-OpenWrt}"
config_get workgroup $1 workgroup "${hostname:-OpenWrt}"
config_get description $1 description "Samba on ${hostname:-OpenWrt}"
config_get charset $1 charset "UTF-8"
mkdir -p /var/etc
sed -e "s#|NAME|#$name#g" \
-e "s#|WORKGROUP|#$workgroup#g" \
-e "s#|DESCRIPTION|#$description#g" \
-e "s#|INTERFACES|#$interfaces#g" \
-e "s#|CHARSET|#$charset#g" \
/etc/samba/smb.conf.template > /var/etc/smb.conf
local homes
config_get_bool homes $1 homes 0
[ $homes -gt 0 ] && {
cat <<EOT >> /var/etc/smb.conf
[homes]
comment = Home Directories
browsable = no
read only = no
create mode = 0750
EOT
}
[ -L /etc/samba/smb.conf ] || $(rm -f /etc/samba/smb.conf; ln -nsf /var/etc/smb.conf /etc/samba/smb.conf)
}
smb_add_share() {
local name
local path
local users
local read_only
local guest_ok
local create_mask
local dir_mask
local browseable
local dirpath
config_get name $1 name
config_get path $1 path
config_get users $1 users
config_get read_only $1 read_only
config_get guest_ok $1 guest_ok
config_get create_mask $1 create_mask
config_get dir_mask $1 dir_mask
config_get browseable $1 browseable
config_get dirpath $1 dirpath
path="$path/$dirpath"
[ -z "$name" -o -z "$path" ] && return
echo -e "\n[$name]\n\tpath = $path" >> /var/etc/smb.conf
[ -n "$users" ] && echo -e "\tvalid users = $users" >> /var/etc/smb.conf
[ -n "$read_only" ] && echo -e "\tread only = $read_only" >> /var/etc/smb.conf
[ -n "$guest_ok" ] && echo -e "\tguest ok = $guest_ok" >> /var/etc/smb.conf
[ -n "$create_mask" ] && echo -e "\tcreate mask = $create_mask" >> /var/etc/smb.conf
[ -n "$dir_mask" ] && echo -e "\tdirectory mask = $dir_mask" >> /var/etc/smb.conf
[ -n "$browseable" ] && echo -e "\tbrowseable = $browseable" >> /var/etc/smb.conf
}
start_service() {
config_load samba
purgepasswd
config_foreach useradd sambausers
config_foreach smb_header samba
config_foreach smb_add_share sambashare
procd_open_instance
procd_set_param command "/bin/smbd" -F
procd_close_instance
procd_open_instance
procd_set_param command "/bin/nmbd" -F
procd_close_instance
}
stop_service() {
service_stop /bin/smbd
service_stop /bin/nmbd
}
reload_service() {
stop
start
}
service_triggers() {
procd_add_reload_trigger samba network
}

View File

@@ -1,19 +0,0 @@
[global]
netbios name = |NAME|
workgroup = |WORKGROUP|
server string = |DESCRIPTION|
syslog = 10
encrypt passwords = true
passdb backend = smbpasswd
obey pam restrictions = yes
socket options = TCP_NODELAY
unix charset = UTF-8
preferred master = yes
os level = 20
security = user
guest account = nobody
invalid users = root
smb passwd file = /etc/samba/smbpasswd
interfaces = |INTERFACES|
bind interfaces only = yes

File diff suppressed because it is too large Load Diff

View File

@@ -1,48 +0,0 @@
Index: samba-3.0.37/source/popt/popt.c
===================================================================
--- samba-3.0.37.orig/source/popt/popt.c 2011-04-11 23:35:04.000000000 +0200
+++ samba-3.0.37/source/popt/popt.c 2011-04-11 23:35:10.000000000 +0200
@@ -10,13 +10,14 @@
#include "system.h"
-#if HAVE_FLOAT_H
+//#if HAVE_FLOAT_H
#include <float.h>
-#endif
+//#endif
#include <math.h>
#include "findme.h"
#include "poptint.h"
+#include "../include/config.h"
#ifdef MYDEBUG
/*@unchecked@*/
@@ -388,7 +389,7 @@
sprintf(s, "%s/%s", con->execPath, item->argv[0]);
argv[argc] = s;
} else {
- argv[argc] = findProgramPath(item->argv[0]);
+ argv[argc] = ""/*findProgramPath(item->argv[0])*/;
}
if (argv[argc++] == NULL) return POPT_ERROR_NOARG;
@@ -1246,4 +1247,3 @@
return numargs;
}
-/*@=boundswrite@*/
Index: samba-3.0.37/source/modules/vfs_default.c
===================================================================
--- samba-3.0.37.orig/source/modules/vfs_default.c 2011-04-11 23:35:08.000000000 +0200
+++ samba-3.0.37/source/modules/vfs_default.c 2011-04-11 23:35:10.000000000 +0200
@@ -977,7 +977,7 @@
START_PROFILE(syscall_linux_setlease);
-#ifdef LINUX
+#if defined(LINUX) && defined(HAVE_KERNEL_OPLOCKS_LINUX)
/* first set the signal handler */
if(linux_set_lease_sighandler(fd) == -1)
return -1;

View File

@@ -1,39 +0,0 @@
Index: samba-3.0.37/source/Makefile.in
===================================================================
--- samba-3.0.37.orig/source/Makefile.in 2009-09-30 14:21:56.000000000 +0200
+++ samba-3.0.37/source/Makefile.in 2011-04-03 20:35:19.000000000 +0200
@@ -92,7 +92,7 @@
# or in smb.conf (see smb.conf(5))
LOGFILEBASE = @logfilebase@
CONFIGFILE = $(CONFIGDIR)/smb.conf
-LMHOSTSFILE = $(CONFIGDIR)/lmhosts
+LMHOSTSFILE = /etc/lmhosts
# This is where smbpasswd et al go
PRIVATEDIR = @privatedir@
Index: samba-3.0.37/source/configure
===================================================================
--- samba-3.0.37.orig/source/configure 2009-09-30 15:08:58.000000000 +0200
+++ samba-3.0.37/source/configure 2011-04-03 20:35:20.000000000 +0200
@@ -1536,8 +1536,8 @@
--with-fhs Use FHS-compliant paths (default=no)
--with-privatedir=DIR Where to put smbpasswd ($ac_default_prefix/private)
--with-rootsbindir=DIR Which directory to use for root sbin ($ac_default_prefix/sbin)
- --with-lockdir=DIR Where to put lock files ($ac_default_prefix/var/locks)
- --with-piddir=DIR Where to put pid files ($ac_default_prefix/var/locks)
+ --with-lockdir=DIR Where to put lock files ($ac_default_prefix/var/lock)
+ --with-piddir=DIR Where to put pid files ($ac_default_prefix/var/run)
--with-swatdir=DIR Where to put SWAT files ($ac_default_prefix/swat)
--with-configdir=DIR Where to put configuration files ($libdir)
--with-logfilebase=DIR Where to put log files ($VARDIR)
@@ -2295,8 +2295,8 @@
rootsbindir="\${SBINDIR}"
-lockdir="\${VARDIR}/locks"
-piddir="\${VARDIR}/locks"
+lockdir="\${VARDIR}/lock"
+piddir="\${VARDIR}/run"
test "${mandir}" || mandir="\${prefix}/man"
logfilebase="\${VARDIR}"
privatedir="\${prefix}/private"

View File

@@ -1,216 +0,0 @@
Index: samba-3.0.37/source/Makefile.in
===================================================================
--- samba-3.0.37.orig/source/Makefile.in 2011-08-08 23:40:18.004444730 +0200
+++ samba-3.0.37/source/Makefile.in 2011-08-08 23:40:19.054444730 +0200
@@ -538,10 +538,7 @@
PASSWD_UTIL_OBJ = utils/passwd_util.o
-SMBPASSWD_OBJ = utils/smbpasswd.o $(PASSWD_UTIL_OBJ) $(PASSCHANGE_OBJ) \
- $(PARAM_OBJ) $(SECRETS_OBJ) $(LIBSMB_OBJ) $(PASSDB_OBJ) \
- $(GROUPDB_OBJ) $(LIB_NONSMBD_OBJ) $(KRBCLIENT_OBJ) \
- $(POPT_LIB_OBJ) $(SMBLDAP_OBJ) $(RPC_PARSE_OBJ) $(LIBMSRPC_GEN_OBJ) $(LIBMSRPC_OBJ)
+SMBPASSWD_OBJ = utils/owrt_smbpasswd.o lib/md4.o
PDBEDIT_OBJ = utils/pdbedit.o $(PASSWD_UTIL_OBJ) $(PARAM_OBJ) $(PASSDB_OBJ) \
$(LIBSAMBA_OBJ) $(LIB_NONSMBD_OBJ) $(GROUPDB_OBJ) \
Index: samba-3.0.37/source/utils/owrt_smbpasswd.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ samba-3.0.37/source/utils/owrt_smbpasswd.c 2011-08-08 23:40:19.064444730 +0200
@@ -0,0 +1,195 @@
+/*
+ * Copyright (C) John Crispin <blogic@openwrt.org>
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation; either version 2 of the License, or (at your
+ * option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ * more details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program; if not, write to the Free Software Foundation, Inc., 675
+ * Mass Ave, Cambridge, MA 02139, USA. */
+
+#include "includes.h"
+#include <endian.h>
+
+void E_md4hash(const char *passwd, uchar p16[16])
+{
+ int len;
+ smb_ucs2_t wpwd[129];
+ int i;
+
+ len = strlen(passwd);
+ for (i = 0; i < len; i++) {
+#if __BYTE_ORDER == __LITTLE_ENDIAN
+ wpwd[i] = (unsigned char)passwd[i];
+#else
+ wpwd[i] = (unsigned char)passwd[i] << 8;
+#endif
+ }
+ wpwd[i] = 0;
+
+ len = len * sizeof(int16);
+ mdfour(p16, (unsigned char *)wpwd, len);
+ ZERO_STRUCT(wpwd);
+}
+
+/* returns -1 if user is not present in /etc/passwd*/
+int find_uid_for_user(char *user)
+{
+ char t[256];
+ FILE *fp = fopen("/etc/passwd", "r");
+ int ret = -1;
+
+ if(!fp)
+ {
+ printf("failed to open /etc/passwd");
+ goto out;
+ }
+
+ while(!feof(fp))
+ {
+ if(fgets(t, 255, fp))
+ {
+ char *p1, *p2;
+ p1 = strchr(t, ':');
+ if(p1 && (p1 - t == strlen(user)) && (strncmp(t, user, strlen(user))) == 0)
+ {
+ p1 = strchr(t, ':');
+ if(!p1)
+ goto out;
+ p2 = strchr(++p1, ':');
+ if(!p2)
+ goto out;
+ p1 = strchr(++p2, ':');
+ if(!p1)
+ goto out;
+ *p1 = '\0';
+ ret = atoi(p2);
+ goto out;
+ }
+ }
+ }
+ printf("No valid user found in /etc/passwd\n");
+
+out:
+ if(fp)
+ fclose(fp);
+ return ret;
+}
+
+void insert_user_in_smbpasswd(char *user, char *line)
+{
+ char t[256];
+ FILE *fp = fopen("/etc/samba/smbpasswd", "r+");
+
+ if(!fp)
+ {
+ printf("failed to open /etc/samba/smbpasswd");
+ goto out;
+ }
+
+ while(!feof(fp))
+ {
+ if(fgets(t, 255, fp))
+ {
+ char *p;
+ p = strchr(t, ':');
+ if(p && (p - t == strlen(user)) && (strncmp(t, user, strlen(user))) == 0)
+ {
+ fseek(fp, -strlen(line), SEEK_CUR);
+ break;
+ }
+ }
+ }
+
+ fprintf(fp, line);
+
+out:
+ if(fp)
+ fclose(fp);
+}
+
+void delete_user_from_smbpasswd(char *user)
+{
+ char t[256];
+ FILE *fp = fopen("/etc/samba/smbpasswd", "r+");
+
+ if(!fp)
+ {
+ printf("failed to open /etc/samba/smbpasswd");
+ goto out;
+ }
+
+ while(!feof(fp))
+ {
+ if(fgets(t, 255, fp))
+ {
+ char *p;
+ p = strchr(t, ':');
+ if(p && (p - t == strlen(user)) && (strncmp(t, user, strlen(user))) == 0)
+ {
+ fpos_t r_pos, w_pos;
+ char t2[256];
+ fgetpos(fp, &r_pos);
+ w_pos = r_pos;
+ w_pos.__pos -= strlen(t);
+ while(fgets(t2, 256, fp))
+ {
+ fsetpos(fp, &w_pos);
+ fputs(t2, fp);
+ r_pos.__pos += strlen(t2);
+ w_pos.__pos += strlen(t2);
+ fsetpos(fp, &r_pos);
+ }
+ ftruncate(fileno(fp), w_pos.__pos);
+ break;
+ }
+ }
+ }
+
+out:
+ if(fp)
+ fclose(fp);
+}
+
+int main(int argc, char **argv)
+{
+ unsigned uid;
+ uchar new_nt_p16[NT_HASH_LEN];
+ int g;
+ int smbpasswd_present;
+ char smbpasswd_line[256];
+ char *s;
+
+ if(argc != 3)
+ {
+ printf("usage for openwrt_smbpasswd - \n\t%s USERNAME PASSWD\n\t%s -del USERNAME\n", argv[0], argv[0]);
+ exit(1);
+ }
+ if(strcmp(argv[1], "-del") == 0)
+ {
+ printf("deleting user %s\n", argv[2]);
+ delete_user_from_smbpasswd(argv[2]);
+ return 0;
+ }
+ uid = find_uid_for_user(argv[1]);
+ if(uid == -1)
+ exit(2);
+
+ E_md4hash(argv[2], new_nt_p16);
+ s = smbpasswd_line;
+ s += snprintf(s, 256 - (s - smbpasswd_line), "%s:%u:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:", argv[1], uid);
+ for(g = 0; g < 16; g++)
+ s += snprintf(s, 256 - (s - smbpasswd_line), "%02X", new_nt_p16[g]);
+ snprintf(s, 256 - (s - smbpasswd_line), ":[U ]:LCT-00000001:\n");
+
+ insert_user_in_smbpasswd(argv[1], smbpasswd_line);
+
+ return 0;
+}

View File

@@ -1,15 +0,0 @@
Index: samba-3.0.24/source/lib/ms_fnmatch.c
===================================================================
--- samba-3.0.24.orig/source/lib/ms_fnmatch.c 2008-08-11 11:08:03.000000000 +0200
+++ samba-3.0.24/source/lib/ms_fnmatch.c 2008-08-11 11:11:33.000000000 +0200
@@ -153,6 +153,10 @@
int ret, count, i;
struct max_n *max_n = NULL;
+ if (strcmp(pattern, "*") == 0) {
+ return 0;
+ }
+
if (strcmp(string, "..") == 0) {
string = ".";
}

View File

@@ -1,13 +0,0 @@
Index: samba-3.0.24/source/lib/popt_common.c
===================================================================
--- samba-3.0.24.orig/source/lib/popt_common.c 2008-08-11 11:25:26.000000000 +0200
+++ samba-3.0.24/source/lib/popt_common.c 2008-08-11 11:26:03.000000000 +0200
@@ -54,7 +54,7 @@
else
pname++;
- pstr_sprintf(logfile, "%s/log.%s", arg, pname);
+ pstr_sprintf(logfile, "%s/log/%s.log", arg, pname);
lp_set_logfile(logfile);
}

View File

@@ -1,23 +0,0 @@
Index: samba-3.0.37/source/configure
===================================================================
--- samba-3.0.37.orig/source/configure 2011-04-03 20:35:20.000000000 +0200
+++ samba-3.0.37/source/configure 2011-04-03 20:36:51.000000000 +0200
@@ -22548,6 +22548,17 @@
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }
+# Force disable RPC
+$as_echo "test=$ac_header" >&6
+if test "$ac_header" = "rpc/rpc.h"; then
+ if test "$ac_header_compiler" = "yes" -o "$ac_header_preproc" = "yes"; then
+ $as_echo "RPC support force disabled by OpenWRT patch" >&5
+ $as_echo "RPC support force disabled by OpenWRT patch" >&6
+ fi
+fi
+ac_header_compiler=no
+ac_header_preproc=no
+
# So? What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
yes:no: )

View File

@@ -1,28 +0,0 @@
Index: samba-3.0.37/source/configure.in
===================================================================
--- samba-3.0.37.orig/source/configure.in
+++ samba-3.0.37/source/configure.in
@@ -1389,23 +1389,6 @@ AC_DEFINE(HAVE_PRCTL, 1, [Whether prctl
case "$host_os" in
*linux*)
# glibc <= 2.3.2 has a broken getgrouplist
- AC_TRY_RUN([
-#include <unistd.h>
-#include <sys/utsname.h>
-main() {
- /* glibc up to 2.3 has a broken getgrouplist */
-#if defined(__GLIBC__) && defined(__GLIBC_MINOR__)
- int libc_major = __GLIBC__;
- int libc_minor = __GLIBC_MINOR__;
-
- if (libc_major < 2)
- exit(1);
- if ((libc_major == 2) && (libc_minor <= 3))
- exit(1);
-#endif
- exit(0);
-}
-], [linux_getgrouplist_ok=yes], [linux_getgrouplist_ok=no])
if test x"$linux_getgrouplist_ok" = x"yes"; then
AC_DEFINE(HAVE_GETGROUPLIST, 1, [Have good getgrouplist])
fi

View File

@@ -1,12 +0,0 @@
Get rid of error due to cross compilation, as glibc version in OpenWRT is high enough
--- a/source/configure
+++ b/source/configure
@@ -37222,7 +37222,7 @@ rm -f core conftest.err conftest.$ac_obj
case "$host_os" in
*linux*)
# glibc <= 2.3.2 has a broken getgrouplist
- if test "$cross_compiling" = yes; then
+ if test "false" = yes; then
{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling

View File

@@ -1,76 +0,0 @@
--- a/source/Makefile.in
+++ b/source/Makefile.in
@@ -291,7 +291,7 @@ SECRETS_OBJ = passdb/secrets.o passdb/ma
LIBNMB_OBJ = libsmb/unexpected.o libsmb/namecache.o libsmb/nmblib.o \
libsmb/namequery.o libsmb/conncache.o libads/dns.o
-LIBSAMBA_OBJ = libsmb/nterr.o libsmb/dcerpc_err.o libsmb/smbdes.o \
+LIBSAMBA_OBJ = libsmb/nterr.o $(if $(OWRT_SMALLER),,libsmb/dcerpc_err.o) libsmb/smbdes.o \
libsmb/smbencrypt.o libsmb/ntlm_check.o \
libsmb/ntlmssp.o libsmb/ntlmssp_parse.o libsmb/ntlmssp_sign.o
@@ -323,35 +323,35 @@ REGISTRY_OBJ = registry/reg_frontend.o r
registry/reg_db.o registry/reg_eventlog.o registry/reg_shares.o \
registry/reg_util.o registry/reg_dynamic.o registry/reg_perfcount.o
-RPC_LSA_OBJ = rpc_server/srv_lsa.o rpc_server/srv_lsa_nt.o
+RPC_LSA_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_lsa.o rpc_server/srv_lsa_nt.o)
-RPC_NETLOG_OBJ = rpc_server/srv_netlog.o rpc_server/srv_netlog_nt.o
+RPC_NETLOG_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_netlog.o rpc_server/srv_netlog_nt.o)
-RPC_SAMR_OBJ = rpc_server/srv_samr.o rpc_server/srv_samr_nt.o \
- rpc_server/srv_samr_util.o
+RPC_SAMR_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_samr.o rpc_server/srv_samr_nt.o \
+ rpc_server/srv_samr_util.o)
REGFIO_OBJ = registry/regfio.o
-RPC_REG_OBJ = rpc_server/srv_reg.o rpc_server/srv_reg_nt.o $(REGFIO_OBJ)
+RPC_REG_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_reg.o rpc_server/srv_reg_nt.o $(REGFIO_OBJ))
-RPC_LSA_DS_OBJ = rpc_server/srv_lsa_ds.o rpc_server/srv_lsa_ds_nt.o
+RPC_LSA_DS_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_lsa_ds.o rpc_server/srv_lsa_ds_nt.o)
RPC_SVC_OBJ = rpc_server/srv_srvsvc.o rpc_server/srv_srvsvc_nt.o
RPC_WKS_OBJ = librpc/gen_ndr/srv_wkssvc.o rpc_server/srv_wkssvc_nt.o
-RPC_SVCCTL_OBJ = rpc_server/srv_svcctl.o rpc_server/srv_svcctl_nt.o \
+RPC_SVCCTL_OBJ = $(if $(OWRT_SMALLER),, rpc_server/srv_svcctl.o) rpc_server/srv_svcctl_nt.o \
services/svc_spoolss.o services/svc_rcinit.o services/services_db.o \
services/svc_netlogon.o services/svc_winreg.o \
services/svc_wins.o
-RPC_NTSVCS_OBJ = rpc_server/srv_ntsvcs.o rpc_server/srv_ntsvcs_nt.o
+RPC_NTSVCS_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_ntsvcs.o rpc_server/srv_ntsvcs_nt.o)
-RPC_DFS_OBJ = rpc_server/srv_dfs.o rpc_server/srv_dfs_nt.o
+RPC_DFS_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_dfs.o rpc_server/srv_dfs_nt.o)
-RPC_SPOOLSS_OBJ = rpc_server/srv_spoolss.o rpc_server/srv_spoolss_nt.o
+RPC_SPOOLSS_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_spoolss.o rpc_server/srv_spoolss_nt.o)
-RPC_EVENTLOG_OBJ = rpc_server/srv_eventlog.o rpc_server/srv_eventlog_nt.o rpc_server/srv_eventlog_lib.o
+RPC_EVENTLOG_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_eventlog.o rpc_server/srv_eventlog_nt.o rpc_server/srv_eventlog_lib.o)
RPC_PIPE_OBJ = rpc_server/srv_pipe_hnd.o \
rpc_server/srv_pipe.o rpc_server/srv_lsa_hnd.o
@@ -431,7 +431,7 @@ PLAINTEXT_AUTH_OBJ = auth/pampass.o auth
SLCACHE_OBJ = libsmb/samlogon_cache.o
-DCUTIL_OBJ = libsmb/namequery_dc.o libsmb/trustdom_cache.o libsmb/trusts_util.o
+DCUTIL_OBJ = libsmb/namequery_dc.o $(if $(OWRT_SMALLER),,libsmb/trustdom_cache.o libsmb/trusts_util.o)
AUTH_BUILTIN_OBJ = auth/auth_builtin.o
AUTH_DOMAIN_OBJ = auth/auth_domain.o
@@ -468,7 +468,7 @@ SMBD_OBJ_SRV = smbd/files.o smbd/chgpass
smbd/change_trust_pw.o smbd/fake_file.o \
smbd/ntquotas.o $(AFS_OBJ) smbd/msdfs.o \
$(AFS_SETTOKEN_OBJ) smbd/aio.o smbd/statvfs.o \
- smbd/dmapi.o $(MANGLE_OBJ) @VFS_STATIC@
+ $(if $(OWRT_SMALLER),,smbd/dmapi.o) $(MANGLE_OBJ) @VFS_STATIC@
SMBD_OBJ_BASE = $(PARAM_OBJ) $(SMBD_OBJ_SRV) $(LIBSMB_OBJ) \
$(RPC_SERVER_OBJ) $(RPC_PARSE_OBJ) $(SECRETS_OBJ) \

View File

@@ -1,47 +0,0 @@
--- a/source/Makefile.in
+++ b/source/Makefile.in
@@ -319,7 +319,7 @@ LIBMSRPC_GEN_OBJ = librpc/gen_ndr/cli_wk
REGOBJS_OBJ = registry/reg_objects.o
-REGISTRY_OBJ = registry/reg_frontend.o registry/reg_cachehook.o registry/reg_printing.o \
+REGISTRY_OBJ = registry/reg_frontend.o registry/reg_cachehook.o $(if $(OWRT_NO_PRINTING),,registry/reg_printing.o) \
registry/reg_db.o registry/reg_eventlog.o registry/reg_shares.o \
registry/reg_util.o registry/reg_dynamic.o registry/reg_perfcount.o
@@ -349,7 +349,7 @@ RPC_NTSVCS_OBJ = $(if $(OWRT_SMALLER),,r
RPC_DFS_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_dfs.o rpc_server/srv_dfs_nt.o)
-RPC_SPOOLSS_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_spoolss.o rpc_server/srv_spoolss_nt.o)
+RPC_SPOOLSS_OBJ = $(if $(OWRT_NO_PRINTING),,rpc_server/srv_spoolss.o rpc_server/srv_spoolss_nt.o)
RPC_EVENTLOG_OBJ = $(if $(OWRT_SMALLER),,rpc_server/srv_eventlog.o rpc_server/srv_eventlog_nt.o rpc_server/srv_eventlog_lib.o)
@@ -463,7 +463,7 @@ SMBD_OBJ_SRV = smbd/files.o smbd/chgpass
smbd/vfs.o smbd/statcache.o \
smbd/posix_acls.o lib/sysacls.o $(SERVER_MUTEX_OBJ) \
smbd/process.o smbd/service.o smbd/error.o \
- printing/printfsp.o lib/sysquotas.o lib/sysquotas_linux.o \
+ $(if $(OWRT_NO_PRINTING),,printing/printfsp.o) lib/sysquotas.o lib/sysquotas_linux.o \
lib/sysquotas_xfs.o lib/sysquotas_4A.o \
smbd/change_trust_pw.o smbd/fake_file.o \
smbd/ntquotas.o $(AFS_OBJ) smbd/msdfs.o \
@@ -480,13 +480,13 @@ SMBD_OBJ_BASE = $(PARAM_OBJ) $(SMBD_OBJ_
$(REGISTRY_OBJ) $(POPT_LIB_OBJ) \
$(BUILDOPT_OBJ) $(SMBLDAP_OBJ)
-PRINTING_OBJ = printing/pcap.o printing/print_svid.o printing/print_aix.o \
+PRINTING_OBJ = $(if $(OWRT_NO_PRINTING),,printing/pcap.o printing/print_svid.o printing/print_aix.o \
printing/print_cups.o printing/print_generic.o \
printing/lpq_parse.o printing/load.o \
- printing/print_iprint.o printing/print_test.o
+ printing/print_iprint.o printing/print_test.o)
-PRINTBASE_OBJ = printing/notify.o printing/printing_db.o
-PRINTBACKEND_OBJ = printing/printing.o printing/nt_printing.o $(PRINTBASE_OBJ)
+PRINTBASE_OBJ = $(if $(OWRT_NO_PRINTING),,printing/notify.o printing/printing_db.o)
+PRINTBACKEND_OBJ = $(if $(OWRT_NO_PRINTING),,printing/printing.o printing/nt_printing.o $(PRINTBASE_OBJ))
SMBD_OBJ = $(SMBD_OBJ_BASE) $(SMBD_OBJ_MAIN)
NMBD_OBJ1 = nmbd/asyncdns.o nmbd/nmbd.o nmbd/nmbd_become_dmb.o \

View File

@@ -1,37 +0,0 @@
#
# Copyright (C) 2016 Inteno
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=uci-diff
PKG_VERSION:=1.0
PKG_SOURCE_VERSION:=2fbd9ca65e0f670dcf34a5dd17a0fd1fde6bf54c
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=git@private.inteno.se:/uci-diff
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk
define Package/uci-diff
CATEGORY:=Utilities
DEPENDS:=+libc +libuci +libubox +ubus +libjson-c +libblobmsg-json
TITLE:=uci-diff
endef
define Package/uci-diff/description
uci-diff
endef
define Package/uci-diff/install
$(CP) ./files/* $(1)/
$(INSTALL_DIR) $(1)/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/uci-diff $(1)/bin/
endef
$(eval $(call BuildPackage,uci-diff))

View File

@@ -1,43 +0,0 @@
{"wireless": {
"wifi-device": {
"type": "broadcom",
"country": "EU/13",
"band": "a",
"bandwidth": "80",
"hwmode": "11ac",
"channel": "auto",
"scantimer": "0",
"wmm": "1",
"wmm_noack": "0",
"wmm_apsd": "1",
"txpower": "100",
"rateset": "default",
"frag": "2346",
"rts": "2347",
"dtim_period": "1",
"beacon_int": "100",
"rxchainps": "0",
"rxchainps_qt": "10",
"rxchainps_pps": "10",
"rifs": "0",
"rifs_advert": "0",
"maxassoc": "32",
"doth": "1",
"dfsc": "1",
"disabled": "1"
},
"wifi-iface": {
"device": "wl0",
"network": "lan",
"mode": "ap",
"ssid": "Inteno-4BC8",
"encryption": "mixed-psk",
"cipher": "auto",
"key": "1234567890",
"gtk_rekey": "3600",
"macfilter": "0",
"wps_pbc": "1",
"wmf_bss_enable": "1",
"bss_max": "16"
}
}}

View File

@@ -1,22 +0,0 @@
{"wireless": {
"wl0": {
".name": "wl0",
".type": "wifi-device",
"channel": 100
},
"wl1": {
".name": "wl1",
".type": "wifi-device",
"wmm": 0
},
"wi0-0": {
".type": "wifi-iface",
"device": "wi0-0",
"ssid": "Fredrik"
},
"wi1-0": {
".type": "wifi-iface",
"device": "wi1-0",
"ssid": "blah"
}
}}