Compare commits

...

115 Commits

Author SHA1 Message Date
Andreas Gnau
4a96a1399a draft: Hack SSID
Needs corresponding MR in feed/targets as well.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2025-02-25 15:10:06 +05:30
Dariusz Iwanoczko
b6e5749b7f fwbank: add copy_config method to fwbank API
Implemented copy_config handler to create and copy a system upgrade backup
2025-02-25 08:53:03 +00:00
Janusz Dziedzic
2a1323bfd0 libwifi: 7.9.5 2025-02-24 16:10:55 +00:00
Vivek Kumar Dutta
0c56d3ab39 bbfdm: minor output fixes 2025-02-24 19:57:34 +05:30
Vivek Kumar Dutta
c59c53aa47 usp-js: Updated allow_partial default to true 2025-02-24 18:43:34 +05:30
Vivek Kumar Dutta
90c3949696 bbfdm: Add multi-ap services in usp critical list 2025-02-24 12:19:41 +05:30
Markus Gothe
14ca35a64b Revert "qosmngr: fix ebtables-extensions dependencies"
This reverts commit c55ab35b14.
2025-02-24 03:18:38 +00:00
Vivek Kumar Dutta
cf148f6c06 ebtables-extensions: 2.0.5 2025-02-24 08:29:28 +05:30
Erik Karlsson
c3e0426c36 gryphon-led-module: remove obsolete commented out test code 2025-02-21 17:04:22 +01:00
Erik Karlsson
c7f3e52f92 gryphon-led-module: clean up package Makefile
Use a more modern approach for building kernel modules
out-of-tree. Remove a lot of unused stuff.
2025-02-21 17:04:22 +01:00
Erik Karlsson
1605577538 gryphon-led-module: fix error handling
The dev_get_drvdata/platform_get_drvdata functions do not return an
error pointer. Use devm_gpiod_get_index to manage GPIO resources. Do
not support obsolete Linux versions. Check the return value of
gpiod_direction_output
2025-02-21 17:04:22 +01:00
Reidar Cederqvist
69ba712cb3 Sulu: update to latest devel 2025-02-21 14:51:31 +00:00
Amin Ben Romdhane
634d40fa01 logmngr: 1.0.9 2025-02-21 15:45:37 +01:00
Amin Ben Romdhane
088ed56c50 icwmp: 9.8.32 2025-02-21 15:44:08 +01:00
Amin Ben Romdhane
d49c758d04 ieee1905: 8.7.3 2025-02-21 15:43:14 +01:00
Amin Ben Romdhane
187492a827 packet-capture-diagnostics: 1.0.3 2025-02-21 15:39:24 +01:00
Amin Ben Romdhane
0a375e6ac4 self-diagnostics: 1.0.13 2025-02-21 15:38:43 +01:00
Amin Ben Romdhane
226c5b4685 obuspa: 9.0.4.8 2025-02-21 15:37:40 +01:00
Amin Ben Romdhane
e72352d7e1 netmngr: 1.1.4 2025-02-21 15:36:08 +01:00
Amin Ben Romdhane
322d80f151 sysmngr: 1.0.17 2025-02-21 15:34:25 +01:00
Amin Ben Romdhane
8e4d3920d9 wifidmd: 1.0.32 2025-02-21 15:32:47 +01:00
Amin Ben Romdhane
241afdc4fd hostmngr: 1.2.15 2025-02-21 15:31:05 +01:00
Amin Ben Romdhane
4ee68f7a84 bbfdm: introduce data model core micro-service and update bbfdmd to use async call to optimize RPCs handling 2025-02-21 15:29:45 +01:00
Janusz Dziedzic
11b13af489 libwifi: 7.9.4 2025-02-21 10:15:00 +00:00
Vivek Kumar Dutta
5abf23d711 Revert "icwmp: fix gateway info race condition"
This reverts commit c118da628d.
2025-02-21 15:08:22 +05:30
Mohd Mehdi
38c7075422 qosmngr: remove unused variable and fix error logs in uci-default 2025-02-21 06:28:14 +00:00
Suvendhu Hansa
dead11036c wifidmd: Remove iwinfo dependency 2025-02-21 10:44:27 +05:30
Markus Gothe
e708d6caec ipt-trigger: Resolve dependecies for Mediatek platform. 2025-02-20 15:14:32 +01:00
Markus Gothe
3a7c4119ff ipt-trigger: Clean up dependencies. 2025-02-20 13:59:21 +01:00
Markus Gothe
b1fc7a09be Update ipt-trigger dependencies. 2025-02-20 11:35:19 +00:00
Janusz Dziedzic
7c0a37c8a8 libwifi: 7.9.3 2025-02-20 09:31:53 +00:00
Mohd Mehdi
bfdd241330 parental-control: add support for Status and Enable 2025-02-20 05:43:09 +00:00
Markus Gothe
cdc8972031 ebtables-extensions: Fix usage of KERNEL_MAKE_FLAGS
KERNEL_MAKE_FLAGS passes arguments to 'make'
and not to the compiler which is probably
what was intended.
2025-02-19 16:25:39 +01:00
Markus Gothe
f668c5cc33 ipt-trigger: Fix usage of KERNEL_MAKE_FLAGS
KERNEL_MAKE_FLAGS passes arguments to 'make'
and not to the compiler which is probably
what was intended.

This solves a compilation issue on the
Broadcom platform.
2025-02-19 16:07:59 +01:00
Erik Karlsson
ed0373f188 libvoice-airoha: 1.1.1 2025-02-19 15:32:51 +01:00
Janusz Dziedzic
74f37ee761 wifimngr: 17.5.4 2025-02-19 13:52:47 +00:00
Janusz Dziedzic
3970668d0e libwifi: 7.9.2 2025-02-19 13:51:05 +00:00
Jakob Olsson
fe833164de map-agent: 6.3.2.4 2025-02-19 13:08:46 +01:00
Erik Karlsson
eca57960a0 libvoice-airoha: set the default transmit and receive gain in the UCI config 2025-02-19 11:01:25 +00:00
Mohd Husaam Mehdi
41c8325aae parental-control: Support BlockHistory 2025-02-19 08:21:58 +00:00
Suvendhu Hansa
c118da628d icwmp: fix gateway info race condition 2025-02-19 06:47:15 +00:00
Suvendhu Hansa
0714c79917 obuspa: Add csv report support in Bulkdata mqtt 2025-02-18 14:01:16 +00:00
Vivek Kumar Dutta
d01f484999 swmodd: 2.5.21 2025-02-17 18:52:13 +05:30
Jakob Olsson
d161ccf816 map-controller: 6.2.3.0 2025-02-17 11:01:21 +01:00
Jakob Olsson
e18da4e996 map-controller: add config option to provision disabled APs 2025-02-17 09:59:25 +00:00
Jakob Olsson
4aca931a23 map-agent: 6.3.2.3 2025-02-14 17:29:54 +01:00
Elena Vengerova
81b0f6e7fe libwifi: 7.9.1 2025-02-14 15:36:50 +04:00
Vivek Kumar Dutta
93873874bb sulu: Fix mqtt acl generation 2025-02-14 12:44:18 +05:30
Vivek Kumar Dutta
88ca4b3011 icwmp: config options to skip datatype check and insecure connect 2025-02-14 12:39:48 +05:30
Amin Ben Romdhane
a3bd6392a1 bbfdm: 1.14.5 2025-02-13 14:47:43 +01:00
Janusz Dziedzic
ed01591374 map-agent: 6.3.2.2 2025-02-13 13:08:17 +00:00
arbala
c48d4923d6 map-controller: 6.2.2.3 2025-02-12 16:45:58 +01:00
Erik Karlsson
3dbc47b54f gryphon-led-module: turn LED off on system shutdown and module unload 2025-02-12 13:55:21 +01:00
Anjan Chanda
d6ef40fd0f decollector: 6.2.0.1 2025-02-12 12:20:24 +01:00
arbala
b94dbcdbdf map-agent: 6.3.2.1 2025-02-11 17:00:01 +01:00
Vivek Kumar Dutta
d0be4f8056 mcastmngr: Fix instance add/del operations 2025-02-11 19:30:46 +05:30
Suvendhu Hansa
5e392d0832 wifidmd: Fix SSID instance deletion 2025-02-11 13:56:02 +00:00
Vivek Kumar Dutta
acc92dfb1f obuspa: Config option to override CT roles with fw default roles 2025-02-11 19:24:02 +05:30
Erik Karlsson
5e13161b70 Fix out-of-tree Broadcom kernel module build
The inclusion of bcm-kernel-toolchain.mk cannot be conditional since
CONFIG_TARGET_brcmbca is not defined when package metadata is being
generated. Instead make it optional in case broadcom feed is absent.
2025-02-11 10:26:44 +01:00
Amin Ben Romdhane
20034609e0 wifidmd: 1.0.29 2025-02-10 20:16:33 +01:00
Anjan Chanda
58ddcd7499 decollector: 6.2.0.0 2025-02-10 17:18:13 +01:00
Suvendhu Hansa
81755b83ad dnsmngr: optimize dns-sd advertise object 2025-02-10 12:24:20 +00:00
Vivek Kumar Dutta
b96e7077fc icwmp: 9.8.30 2025-02-10 17:33:51 +05:30
Jakob Olsson
1b0a792b56 map-controller: 6.2.2.2 2025-02-10 12:29:58 +01:00
Vivek Kumar Dutta
4e093e59f3 obuspa: Fix random delay in get calls 2025-02-09 11:42:45 +05:30
Vivek Kumar Dutta
9400526e47 wifidmd: Use dump2 output for Network.SSID. table 2025-02-08 16:17:29 +05:30
Mohd Mehdi
a2733b66b7 parental-control: 1.1.0 2025-02-08 06:15:20 +00:00
Markus Gothe
40251b2371 ponmngr: Refactorize PtP-mode detection. 2025-02-07 16:39:00 +01:00
Markus Gothe
980779a583 Don't start ponmngr microservice in PtP-mode. 2025-02-07 15:55:58 +01:00
Jakob Olsson
ad31d21380 map-agent: 6.3.2.0 2025-02-07 12:18:24 +01:00
Anjan Chanda
525b56ebc5 ieee1905: 8.7.2 2025-02-07 09:59:20 +01:00
Janusz Dziedzic
abc15029e6 wifimngr: 17.5.3 2025-02-05 19:17:54 +00:00
Janusz Dziedzic
d992340d98 libwifi: 7.9.0 2025-02-05 17:20:39 +00:00
Jakob Olsson
e5fa525364 map-controller: 6.2.2.1 2025-02-05 16:59:37 +01:00
Marina Maslova
39622c277c map-agent: 6.3.1.2 2025-02-05 18:59:53 +04:00
Vivek Kumar Dutta
98a6c9bd62 icwmp: faultstring improvements 2025-02-05 19:29:55 +05:30
Vivek Kumar Dutta
409cecd943 sulu: Fix admin acl for ParentalControl 2025-02-05 17:37:07 +05:30
Vivek Kumar Dutta
54c92d5b42 bbfdm: 1.14.4
- Fix kill sequence of bbfdm services
- Removed support of BBF_CONFIGMNGR_SCRIPT_BACKEND
- Removed support of BBF_MAX_OBJECT_INSTANCES
- Enabled debug release
2025-02-05 17:26:58 +05:30
Jakob Olsson
2ef97edd43 map-agent: 6.3.1.1 2025-02-05 11:45:40 +01:00
Vivek Kumar Dutta
e19c743888 wifidmd: Fix 80+80MHz in OperatingChannelBandwidth 2025-02-05 14:51:59 +05:30
Roman Azarenko
81b5ade110 self-diagnostics: 1.0.12
- Fix saving model and serial number for report filename

Fixes: b0049df366 ("self-diagnostics: 1.0.10")
2025-02-05 03:24:58 +00:00
Jakob Olsson
c0cfca286e map-controller: 6.2.2.0 2025-02-04 16:51:15 +01:00
Jakob Olsson
584b0b9721 map-agent: 6.3.1.0 2025-02-04 16:48:04 +01:00
Jakob Olsson
d5634eb756 ieee1905: 8.7.0 2025-02-04 16:48:04 +01:00
Vivek Kumar Dutta
38304c4d90 parental-control: Fix segfault with logs 2025-02-04 12:52:11 +05:30
Janusz Dziedzic
b92064f72b ieee1905: add arping dependency 2025-02-03 09:22:30 +00:00
Vivek Kumar Dutta
38814a8f89 sulu: Optimize sulu setup 2025-02-03 10:03:17 +05:30
Vivek Kumar Dutta
9d5ff37aca wifidmd: Optimize SetSSID operate cmd 2025-02-02 14:38:17 +05:30
Vivek Kumar Dutta
68dec1aa1b obuspa: Fix max controller definition 2025-02-02 11:02:13 +05:30
Markus Gothe
f3bbafc15c libethernet: 7.2.117 2025-02-01 14:06:32 +01:00
Janusz Dziedzic
1789bd5afd wifimngr: 17.5.2 2025-01-31 16:27:29 +00:00
arbala
8e5bbbd37f remove use of cat for map-backhaul file 2025-01-31 15:20:38 +00:00
Amin Ben Romdhane
95bd27f079 bbfdm: 1.14.3 2025-01-31 15:09:37 +01:00
Vivek Kumar Dutta
7a9cd965a0 usermngr: 1.3.3 2025-01-31 16:20:30 +05:30
Vivek Kumar Dutta
67673fa604 tr104: package specific vendor extension 2025-01-31 15:42:54 +05:30
Vivek Kumar Dutta
9f54857be0 timemngr: package specific vendor extension 2025-01-31 14:25:27 +05:30
Vivek Kumar Dutta
a733e610b4 qosmngr: package specific vendor extension 2025-01-31 14:04:28 +05:30
Vivek Kumar Dutta
f48ada800e obuspa: package specific vendor extension 2025-01-31 13:11:20 +05:30
Vivek Kumar Dutta
868785688e netmngr: package specific vendor extension 2025-01-31 13:00:22 +05:30
Vivek Kumar Dutta
e9ccbaa772 ethmngr: package specific vendor extension 2025-01-31 12:47:24 +05:30
Janusz Dziedzic
0b6b0e6ca2 wifimngr: 17.5.1 2025-01-30 14:47:15 +00:00
Janusz Dziedzic
47e0ecff71 libwifi: 7.8.9 2025-01-30 14:45:44 +00:00
Reidar Cederqvist
3123202381 SULU: update to version 4.0.4 ready for beta1 2025-01-30 15:27:25 +01:00
Jakob Olsson
9a1861aeb2 map-controller: 6.2.1.0 2025-01-30 15:19:28 +01:00
Jakob Olsson
bba41922cc ieee1905: 8.6.5 2025-01-30 15:18:33 +01:00
Vivek Kumar Dutta
373611b687 mcastmngr: package specific vendor extn 2025-01-30 11:24:45 +00:00
Vivek Kumar Dutta
9576104e83 bridgemngr: package specific vendor extn 2025-01-30 11:24:45 +00:00
Vivek Kumar Dutta
57f14e5e58 parental-control: Support to define vendor extension 2025-01-30 11:24:45 +00:00
Vivek Kumar Dutta
d51a6fe3c6 bbfdm: Support to handler vendor extensions 2025-01-30 11:24:45 +00:00
Jakob Olsson
05b0f91ae0 ieee1905: 8.6.4 2025-01-30 10:37:09 +01:00
Jakob Olsson
aea7fe15e6 map-controller: 6.2.0.0 2025-01-30 10:36:26 +01:00
Jakob Olsson
c6c5e53dc8 map-agent: 6.3.0.0 2025-01-30 10:35:03 +01:00
Vivek Kumar Dutta
03d6f8ab44 icwmp: 9.8.28 2025-01-30 09:59:29 +05:30
Suvendhu Hansa
06ad490dd8 qosmngr: fix unnamed uci section usages 2025-01-30 09:35:33 +05:30
Vivek Kumar Dutta
439e1ac346 wifidmd: Align with mld ubus object names 2025-01-29 19:03:02 +05:30
96 changed files with 1129 additions and 573 deletions

View File

@@ -7,8 +7,4 @@ config BBF_VENDOR_PREFIX
config BBF_OBFUSCATION_KEY
string "Obfuscation key"
default "371d530c95a17d1ca223a29b7a6cdc97e1135c1e0959b51106cca91a0b148b5e42742d372a359760742803f2a44bd88fca67ccdcfaeed26d02ce3b6049cb1e04"
config BBF_MAX_OBJECT_INSTANCES
int "Maximum number of instances per object"
default 255
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=bbfdm
PKG_VERSION:=1.14.1
PKG_VERSION:=1.15.2
USE_LOCAL:=0
ifneq ($(USE_LOCAL),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/bbfdm.git
PKG_SOURCE_VERSION:=b7e5e0de5a12340f3fa9c9e9e40915c4de79e8c5
PKG_SOURCE_VERSION:=ba86b19b5ba979e814b27194a67af910bff46d28
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -19,6 +19,8 @@ endif
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE
RSTRIP:=true
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
include bbfdm.mk
@@ -68,10 +70,6 @@ define Package/bbfdmd/config
source "$(SOURCE)/Config_bbfdmd.in"
endef
define Package/bbf_configmngr/config
source "$(SOURCE)/bbf_configmngr.in"
endef
define Package/libbbfdm-api/description
Library contains the API(UCI, UBUS, JSON, CLI and Browse) of libbbfdm
endef
@@ -100,8 +98,9 @@ endif
CMAKE_OPTIONS += \
-DBBF_VENDOR_PREFIX:String="$(CONFIG_BBF_VENDOR_PREFIX)" \
-DBBF_MAX_OBJECT_INSTANCES:Integer=$(CONFIG_BBF_MAX_OBJECT_INSTANCES) \
-DBBFDMD_MAX_MSG_LEN:Integer=10485760
-DBBFDMD_MAX_MSG_LEN:Integer=10485760 \
-DCMAKE_BUILD_TYPE:String="Debug" \
define Package/libbbfdm-api/install
$(INSTALL_DIR) $(1)/lib
@@ -134,6 +133,7 @@ define Package/bbfdmd/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/bbfdmd/ubus/bbfdmd $(1)/usr/sbin/
$(STRIP) $(1)/usr/sbin/bbfdmd
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/etc/init.d/bbfdmd $(1)/etc/init.d/bbfdmd
@@ -154,22 +154,22 @@ define Package/dm-service/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/dm-service/dm-service $(1)/usr/sbin/
$(BBFDM_REGISTER_SERVICES) -v ${CONFIG_BBF_VENDOR_PREFIX} ./bbfdm_service.json $(1) core
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/libbbfdm/libcore.so $(1) core
endef
define Package/bbf_configmngr/install
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/etc/bbfdm/
ifeq ($(CONFIG_BBF_CONFIGMNGR_C_BACKEND),y)
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/utilities/bbf_configd $(1)/usr/sbin/
$(INSTALL_BIN) ./files/etc/init.d/bbf_configd $(1)/etc/init.d/bbf_configd
$(INSTALL_DIR) $(1)/usr/share/bbfdm/scripts
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/share/bbfdm/scripts/bbf_config_notify.sh $(1)/usr/share/bbfdm/scripts/
endif
ifeq ($(CONFIG_BBF_CONFIGMNGR_SCRIPT_BACKEND),y)
$(INSTALL_DIR) $(1)/usr/libexec/rpcd
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/libexec/rpcd/bbf.config $(1)/usr/libexec/rpcd/bbf.config
endif
$(INSTALL_BIN) $(PKG_BUILD_DIR)/utilities/bbf_configd $(1)/usr/sbin/
$(STRIP) $(1)/usr/sbin/bbf_configd
$(INSTALL_BIN) ./files/etc/init.d/bbf_configd $(1)/etc/init.d/bbf_configd
$(INSTALL_BIN) $(PKG_BUILD_DIR)/utilities/files/usr/share/bbfdm/scripts/bbf_config_notify.sh $(1)/usr/share/bbfdm/scripts/
$(INSTALL_DATA) ./files/etc/bbfdm/critical_services.json $(1)/etc/bbfdm/
endef

View File

@@ -1,19 +0,0 @@
if PACKAGE_bbf_configmngr
choice
prompt "Select backend daemon for bbf.config"
default BBF_CONFIGMNGR_C_BACKEND
help
Select which backend daemon should be used for ubus bbf.config
config BBF_CONFIGMNGR_SCRIPT_BACKEND
bool "Use shell script backend"
help
Enable this option to use shell script as the backend for bbf.config. This can be useful for quick and easy scripting of configuration tasks.
config BBF_CONFIGMNGR_C_BACKEND
bool "Use C code backend"
help
Enable this option to use a C code implementation as the backend for bbf.config. This option is generally preferred for performance-critical tasks and scenarios requiring more robust and efficient handling.
endchoice
endif

View File

@@ -89,28 +89,3 @@ BBFDM_INSTALL_SCRIPT:=$(BBFDM_DIR)/tools/bbfdm.sh -s
BBFDM_REGISTER_SERVICES:=$(BBFDM_DIR)/tools/bbfdm.sh -t
# Deprecated functions errors
define BbfdmInstallPluginInMicroservice
$(warning # BbfdmInstallPluginInMicroservice function is deprecated, use BBFDM_INSTALL_MS_PLUGIN macro #)
$(INSTALL_DIR) $(1)
$(INSTALL_DATA) $(2) $(1)/
endef
define BbfdmInstallMicroServiceInputFile
$(warning # function BbfdmInstallMicroServiceInputFile deprecated, input file auto generated with BBFDM_INSTALL_MS_DM #)
$(INSTALL_DIR) $(1)/etc/bbfdm/micro_services
$(INSTALL_DATA) $(2) $(1)/etc/bbfdm/micro_services/$(PKG_NAME).json
endef
define BbfdmInstallPlugin
$(warning # function BbfdmInstallPlugin deprecated, use BBFDM_INSTALL_CORE_PLUGIN macro #)
$(INSTALL_DIR) $(1)/etc/bbfdm/plugins
$(INSTALL_DATA) $(2) $(1)/etc/bbfdm/plugins/
endef
define BbfdmInstallPluginWithPriority
$(warning # fucntion BbfdmInstallPluginWithPriority deprecated, use BBFDM_INSTALL_CORE_PLUGIN #)
$(INSTALL_DIR) $(1)/etc/bbfdm/plugins
$(INSTALL_DATA) $(3) $(1)/etc/bbfdm/plugins/$(2)_$(shell basename ${3})
endef

58
bbfdm/bbfdm_service.json Normal file
View File

@@ -0,0 +1,58 @@
{
"daemon": {
"enable": "1",
"service_name": "core",
"unified_daemon": false,
"services": [
{
"parent_dm": "Device.",
"object": "LANConfigSecurity"
},
{
"parent_dm": "Device.",
"object": "Schedules"
},
{
"parent_dm": "Device.",
"object": "Security",
"proto": "cwmp"
},
{
"parent_dm": "Device.",
"object": "GatewayInfo"
},
{
"parent_dm": "Device.",
"object": "PacketCaptureDiagnostics"
},
{
"parent_dm": "Device.",
"object": "SelfTestDiagnostics"
},
{
"parent_dm": "Device.",
"object": "Syslog"
},
{
"parent_dm": "Device.",
"object": "{BBF_VENDOR_PREFIX}OpenVPN",
"proto": "usp"
},
{
"parent_dm": "Device.",
"object": "RootDataModelVersion"
},
{
"parent_dm": "Device.",
"object": "Reboot()"
},
{
"parent_dm": "Device.",
"object": "FactoryReset()"
}
],
"config": {
"loglevel": "3"
}
}
}

View File

@@ -3,8 +3,12 @@
"firewall",
"network",
"dhcp",
"time",
"wireless",
"time"
"ieee1905",
"mapcontroller",
"mosquitto",
"nginx"
],
"cwmp": [
"firewall",

View File

@@ -1,7 +1,7 @@
#!/bin/sh /etc/rc.common
START=80
STOP=10
STOP=07
USE_PROCD=1
PROG=/usr/sbin/bbf_configd

View File

@@ -1,7 +1,7 @@
#!/bin/sh /etc/rc.common
START=60
STOP=8
STOP=05
USE_PROCD=1
PROG=/usr/sbin/dm-service

View File

@@ -1,7 +1,7 @@
#!/bin/sh /etc/rc.common
START=97
STOP=10
STOP=06
USE_PROCD=1
PROG=/usr/sbin/bbfdmd

View File

@@ -9,10 +9,11 @@ SCRIPT=0
DIAG=0
PLUGIN=0
DEST=""
VENDOR_EXTN=""
TOOLS="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
SRC=""
while getopts ":mpsdtu:" opt; do
while getopts ":mpsdtv:" opt; do
case ${opt} in
m)
MICRO_SERVICE=1
@@ -29,6 +30,9 @@ while getopts ":mpsdtu:" opt; do
t)
INPUT_FILE=1
;;
v)
VENDOR_EXTN=${OPTARG}
;;
?)
echo "Invalid option: ${OPTARG}"
exit 1
@@ -88,6 +92,10 @@ bbfdm_install_dm()
minfile=$(mktemp)
jq -c 'del(..|.description?)' ${src} > ${minfile}
if [ -n "${VENDOR_EXTN}" ]; then
sed -i "s/{BBF_VENDOR_PREFIX}/${VENDOR_EXTN}/g" ${minfile}
fi
src=${minfile}
if dpkg -s python3-jsonschema >/dev/null 2>&1; then
echo "Verifying bbfdm Datamodel JSON file"
@@ -125,6 +133,7 @@ fi
if [ "${INPUT_FILE}" -eq "1" ]; then
tempfile=""
if [ ! -f "${SRC}" ]; then
echo "# Datamodel Input file ${SRC} not available"
exit 1
@@ -140,9 +149,18 @@ if [ "${INPUT_FILE}" -eq "1" ]; then
exit 1
fi
tempfile=$(mktemp)
cp ${SRC} ${tempfile}
if [ -n "${VENDOR_EXTN}" ]; then
sed -i "s/{BBF_VENDOR_PREFIX}/${VENDOR_EXTN}/g" ${tempfile}
fi
install_dir ${DEST}/etc/bbfdm/services
install_data ${SRC} ${DEST}/etc/bbfdm/services/${DATA}.json
install_data ${tempfile} ${DEST}/etc/bbfdm/services/${DATA}.json
if [ -f "${tempfile}" ]; then
rm ${tempfile}
fi
exit 0
fi
@@ -162,14 +180,15 @@ if [ "${MICRO_SERVICE}" -eq "1" ]; then
fi
else
if [ "${PLUGIN}" -eq "1" ]; then
echo "# WARNING: BBFDM_INSTALL_CORE_PLUGIN macro will be deprecated soon. Please use BBFDM_INSTALL_MS_PLUGIN macro instead, specifying 'core' as micro-service name #"
priority="${DATA:-0}"
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/plugins
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services/core
if [ "${priority}" -gt "0" ]; then
# install with priority if defined
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/plugins/${priority}_$(basename ${SRC})
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services/core/${priority}_$(basename ${SRC})
elif [ "${priority}" -eq "0" ]; then
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/plugins/$(basename ${SRC})
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services/core/$(basename ${SRC})
else
echo "# Priority should be an unsigned integer"
exit 1

View File

@@ -1,7 +1,5 @@
if PACKAGE_bridgemngr
menu "Configuration"
config BRIDGEMNGR_BRIDGE_VLAN
bool "Use bridge-vlan backend"
help
@@ -13,5 +11,7 @@ config BRIDGEMNGR_BRIDGE_VENDOR_EXT
help
Set this option to use bridge BBF vendor extensions.
endmenu
config BRIDGEMNGR_BRIDGE_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -5,7 +5,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=bridgemngr
PKG_VERSION:=1.0.10
PKG_VERSION:=1.0.11
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
LOCAL_DEV:=0
@@ -40,7 +40,13 @@ endef
MAKE_PATH:=src
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_BRIDGEMNGR_BRIDGE_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_BRIDGEMNGR_BRIDGE_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_BRIDGEMNGR_BRIDGE_VLAN),y)
TARGET_CFLAGS += -DBRIDGE_VLAN_BACKEND
@@ -54,7 +60,7 @@ define Package/bridgemngr/install
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libbridgemngr.so $(1) $(PKG_NAME)
ifeq ($(CONFIG_BRIDGEMNGR_BRIDGE_VENDOR_EXT), y)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/src/libbridgeext.so $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_PLUGIN) ./files/VLAN_Filtering_Extension.json $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_PLUGIN) -v ${VENDOR_PREFIX} ./files/VLAN_Filtering_Extension.json $(1) $(PKG_NAME)
endif
$(INSTALL_BIN) ./files/etc/init.d/bridging $(1)/etc/init.d/

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=decollector
PKG_VERSION:=6.1.0.7
PKG_VERSION:=6.2.0.1
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=db4eae19a3f716eec5a37aa2786b9bbbe3160b54
PKG_SOURCE_VERSION:=575ecfff3779aadcea83d890ba975109c0f7d6a3
PKG_SOURCE_URL:=https://dev.iopsys.eu/multi-ap/decollector.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=dnsmngr
PKG_VERSION:=1.0.14
PKG_VERSION:=1.0.15
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/dnsmngr.git
PKG_SOURCE_VERSION:=e64ec01b57d8b32e5230b34f6a3866250b1a8faf
PKG_SOURCE_VERSION:=32bd2501fca8a4f45ba13ee0e4762756c60fe721
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -64,6 +64,10 @@ ifeq ($(CONFIG_DNSMNGR_BACKEND_DNSMASQ),y)
endif
define Package/dnsmngr/install
$(INSTALL_DIR) $(1)/etc/umdns
$(INSTALL_DIR) $(1)/etc/umdns/tmp
$(INSTALL_DIR) $(1)/lib/upgrade/keep.d
$(INSTALL_DATA) ./files/lib/upgrade/keep.d/dnsmngr $(1)/lib/upgrade/keep.d/dnsmngr
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libdnsmngr.so $(1) $(PKG_NAME)
$(BBFDM_INSTALL_SCRIPT) -d $(PKG_BUILD_DIR)/scripts/nslookup $(1)

View File

@@ -0,0 +1 @@
/etc/umdns/*

View File

@@ -6,14 +6,14 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=ebtables-extensions
PKG_VERSION:=2.0.4
PKG_VERSION:=2.0.5
PKG_LICENSE:=GPL-2.0
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/ebtables-extensions.git
PKG_SOURCE_VERSION:=9a2af49b455ee25ca0694274e004ced7c09855a0
PKG_SOURCE_VERSION:=7357622d806833d93d317164dc6673fbf5fd1629
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -189,9 +189,7 @@ define KernelPackage/ebt-mldsnooping/description
Kernel module to enable MLD snooping for ebtables
endef
ifeq ($(CONFIG_TARGET_brcmbca),y)
include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
endif
-include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
define Build/Prepare
@@ -236,7 +234,6 @@ endif
$(CP) $(PKG_BUILD_DIR)/src/ebt_mldsnooping.h $(1)/include/uapi/linux/netfilter_bridge/
endef
KERNEL_MAKE_FLAGS += -I$(LINUX_DIR)/include
ifeq ($(CONFIG_TARGET_airoha),y)
KERNEL_MAKE_FLAGS += PLATFORM="ECONET"
endif

View File

@@ -9,5 +9,9 @@ config ETHMNGR_MACVLAN_EXTENSION
config ETHMNGR_EXPOSE_ETHERNET_OBJECT
bool "Expose ethernet ubus object to fetch and clear interface stats"
default y
config ETHMNGR_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endmenu
endif

View File

@@ -5,7 +5,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ethmngr
PKG_VERSION:=3.0.4
PKG_VERSION:=3.0.5
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
@@ -41,17 +41,25 @@ define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
TARGET_CFLAGS += \
-I$(STAGING_DIR)/usr/include \
-I$(STAGING_DIR)/usr/include/libnl3 \
-D_GNU_SOURCE
ifeq ($(CONFIG_ETHMNGR_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_ETHMNGR_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/ethmngr/* $(PKG_BUILD_DIR)/
endef
endif
TARGET_CFLAGS += \
-I$(STAGING_DIR)/usr/include \
-I$(STAGING_DIR)/usr/include/libnl3 \
-D_GNU_SOURCE \
-DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_ETHMNGR_MACVLAN_EXTENSION),y)
TARGET_CFLAGS += -DETHMNGR_MACVLAN_EXTENSION

View File

@@ -29,7 +29,7 @@ define Package/firewallmngr
CATEGORY:=Network
TITLE:=Package to add Device.Firewall and Device.NAT. data model support.
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +firewall
DEPENDS+=+FIREWALLMNGR_PORT_TRIGGER:kmod-ipt-trigger +FIREWALLMNGR_PORT_TRIGGER:kmod-ip6t-trigger
DEPENDS+=+FIREWALLMNGR_PORT_TRIGGER:iptables-mod-trigger
DEPENDS+=+FIREWALLMNGR_PORT_TRIGGER:iptables-mod-nfqueue
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef

View File

@@ -18,7 +18,8 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=gryphon-led-kernel-module
PKG_RELEASE:=1
PKG_VERSION:=1.0.0
PKG_LICENSE:=GPL-2.0
include $(INCLUDE_DIR)/package.mk
@@ -26,41 +27,18 @@ define KernelPackage/$(PKG_NAME)
SUBMENU:=LED modules
TITLE:=LED driver for Gryphon
FILES:=$(PKG_BUILD_DIR)/$(PKG_NAME).$(LINUX_KMOD_SUFFIX)
KCONFIG:=CONFIG_PACKAGE_kmod-gryphon-led-kernel-module=y
AUTOLOAD:=$(call AutoLoad,60,$(PKG_NAME))
DEPENDS:= +(TARGET_brcmbca):bcm963xx-bsp
PKG_LICENSE:=GPLv2
PKG_LICENSE_URL:=
endef
define KernelPackage/$(PKG_NAME)/description
This package contains the LED driver for Gryphon devices.
endef
EXTRA_KCONFIG:= CONFIG_RGB_LED=m
MODULE_INCLUDE=-I$(PKG_BUILD_DIR)
# support compilation against BCM SDK kernel
include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
define Build/Prepare
mkdir -p $(PKG_BUILD_DIR)/kdevlinks/
$(CP) -s `pwd`/src/* $(PKG_BUILD_DIR)/kdevlinks/
$(CP) src/* $(PKG_BUILD_DIR)
endef
-include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
define Build/Compile
$(MAKE) -C "$(LINUX_DIR)" \
CROSS_COMPILE="$(TARGET_CROSS)" \
ARCH="$(LINUX_KARCH)" \
SUBDIRS="$(PKG_BUILD_DIR)" \
EXTRA_CFLAGS="-DKERNEL_MODULE $(BUILDFLAGS) -I$(LINUX_DIR)/include -include generated/autoconf.h $(MODULE_INCLUDE)" \
modules
endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)" modules
endef
$(eval $(call KernelPackage,$(PKG_NAME)))

View File

@@ -28,6 +28,7 @@
#include <linux/gpio/consumer.h>
#include <linux/of.h>
#include <linux/version.h>
#include <linux/string.h>
#include "sk9822.h"
@@ -46,11 +47,6 @@ static ssize_t get_led_color(struct device *dev,
int len;
struct sk9822_leds *sk9822 = dev_get_drvdata(dev);
if (IS_ERR(sk9822)) {
printk(KERN_ERR "Platform get drvdata returned NULL\n");
return -EIO;
}
len = scnprintf(buf, PAGE_SIZE, "%02x%02x%02x\n", sk9822->led_colors[0].r, sk9822->led_colors[0].g, sk9822->led_colors[0].b);
if (len <= 0) {
dev_err(dev, "sk9822: Invalid sprintf len: %d\n", len);
@@ -73,11 +69,6 @@ static ssize_t set_led_color(struct device *dev,
size_t buflen = count;
struct sk9822_leds *sk9822 = dev_get_drvdata(dev);
if (IS_ERR(sk9822)) {
printk(KERN_ERR "Platform get drvdata returned NULL\n");
return -EIO;
}
/* strip newline */
if ((count > 0) && (buf[count-1] == '\n')) {
buflen--;
@@ -111,11 +102,6 @@ static ssize_t get_led_brightness(struct device *dev,
int len;
struct sk9822_leds *sk9822 = dev_get_drvdata(dev);
if (IS_ERR(sk9822)) {
printk(KERN_ERR "Platform get drvdata returned NULL\n");
return -EIO;
}
len = scnprintf(buf, PAGE_SIZE, "%x\n", sk9822->led_brightness);
if (len <= 0) {
dev_err(dev, "sk9822: Invalid sprintf len: %d\n", len);
@@ -138,11 +124,6 @@ static ssize_t set_led_brightness(struct device *dev,
struct sk9822_leds *sk9822 = dev_get_drvdata(dev);
unsigned long val = SK9822_DEFAULT_BRIGHTNESS;
if (IS_ERR(sk9822)) {
printk(KERN_ERR "Platform get drvdata returned NULL\n");
return -EIO;
}
if (kstrtoul(buf, 16, &val)) {
return -EINVAL;
}
@@ -209,49 +190,33 @@ static int canyon_led_probe(struct platform_device *pdev)
platform_set_drvdata(pdev, leds);
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 3, 0)
leds->clock_gpio = gpiod_get_index(&pdev->dev, "led", 0);
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
leds->clock_gpio = gpiod_get_index(&pdev->dev, "led", 0, GPIOD_OUT_HIGH);
#else
dev_warn(&pdev->dev, "Kernel version Not supported\n");
exit(1);
#endif
leds->clock_gpio = devm_gpiod_get_index(&pdev->dev, "led", 0, GPIOD_OUT_HIGH);
if (IS_ERR(leds->clock_gpio)) {
dev_err(&pdev->dev, "Failed to acquire clock GPIO %ld\n",
PTR_ERR(leds->clock_gpio));
return PTR_ERR(leds->clock_gpio);
}
gpiod_direction_output(leds->clock_gpio, 1);
if (IS_ERR(leds->clock_gpio)) {
dev_err(&pdev->dev, "Failed to acquire clock GPIO %ld\n",
PTR_ERR(leds->clock_gpio));
return PTR_ERR(leds->clock_gpio);
ret = gpiod_direction_output(leds->clock_gpio, 1);
if (ret) {
dev_err(&pdev->dev, "Failed to set clock GPIO output %d\n", ret);
return ret;
} else {
printk(KERN_INFO "Got clock gpio\n");
gpiod_set_value(leds->clock_gpio, 0);
}
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 3, 0)
leds->data_gpio = gpiod_get_index(&pdev->dev, "led", 1);
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(4, 3, 0)
leds->data_gpio = gpiod_get_index(&pdev->dev, "led", 1, GPIOD_OUT_HIGH);
#else
dev_warn(&pdev->dev, "Kernel version Not supported\n");
exit(1);
#endif
leds->data_gpio = devm_gpiod_get_index(&pdev->dev, "led", 1, GPIOD_OUT_HIGH);
if (IS_ERR(leds->data_gpio)) {
dev_err(&pdev->dev, "Failed to acquire data GPIO %ld\n",
PTR_ERR(leds->data_gpio));
return PTR_ERR(leds->data_gpio);
}
gpiod_direction_output(leds->data_gpio, 1);
if (IS_ERR(leds->data_gpio)) {
dev_err(&pdev->dev, "Failed to acquire data GPIO %ld\n",
PTR_ERR(leds->data_gpio));
return PTR_ERR(leds->data_gpio);
ret = gpiod_direction_output(leds->data_gpio, 1);
if (ret) {
dev_err(&pdev->dev, "Failed to set data GPIO output %d\n", ret);
return ret;
} else {
printk(KERN_INFO "Got data gpio\n");
gpiod_set_value(leds->data_gpio, 0);
@@ -264,45 +229,31 @@ static int canyon_led_probe(struct platform_device *pdev)
return ret;
}
#if 0
printk(KERN_INFO "Flash LEDs to verify they work\n");
sk9822_set_color_str(leds, "00FF00");
sk9822_update(leds);
msleep(200);
sk9822_set_color_str(leds, "000000");
sk9822_update(leds);
#endif
printk(KERN_INFO "canyon led successfully probed\n");
return 0;
}
static void canyon_led_off(struct sk9822_leds *leds)
{
leds->led_brightness = 0;
memset(leds->led_colors, 0, sizeof(cRGB) * leds->led_count);
sk9822_update(leds);
}
static int canyon_led_remove(struct platform_device *pdev)
{
struct sk9822_leds *leds;
sysfs_remove_group(&pdev->dev.kobj, &sk9822_dev_attr_group);
leds = platform_get_drvdata(pdev);
if (IS_ERR(leds)) {
printk(KERN_ERR "Platform get drvdata returned NULL\n");
return -1;
}
if (leds->clock_gpio) {
gpiod_put(leds->clock_gpio);
}
if (leds->data_gpio) {
gpiod_put(leds->data_gpio);
}
printk(KERN_NOTICE "Bye, bye\n");
canyon_led_off(platform_get_drvdata(pdev));
return 0;
}
static void canyon_led_shutdown(struct platform_device *pdev)
{
canyon_led_off(platform_get_drvdata(pdev));
}
/**
* platform driver metadata
*/
@@ -315,6 +266,7 @@ static const struct of_device_id canyon_led_of_ids[] = {
static struct platform_driver canyon_led = {
.probe = &canyon_led_probe,
.remove = &canyon_led_remove,
.shutdown = &canyon_led_shutdown,
.driver = {
.name = DRIVER_NAME,
.owner = THIS_MODULE,

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=hostmngr
PKG_VERSION:=1.2.14
PKG_VERSION:=1.2.15
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=6ea9fdb38a8e067b850841d6e7f7266bf76c363a
PKG_SOURCE_VERSION:=3b50823da3f2904191332634c1e45d46090def1d
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/hostmngr.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip

View File

@@ -1,5 +1,5 @@
#
# Copyright (C) 2020-2023 IOPSYS Software Solutions AB
# Copyright (C) 2020-2025 IOPSYS Software Solutions AB
#
# This is free software, licensed under the BSD-3-Clause
# See /LICENSE for more information.
@@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=icwmp
PKG_VERSION:=9.8.27
PKG_VERSION:=9.8.32
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/icwmp.git
PKG_SOURCE_VERSION:=868abeb86c2974b3647c7f66e085808c0f296721
PKG_SOURCE_VERSION:=6e80cefd0056f2d13122ad22b73895ea7fb5e438
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -13,6 +13,7 @@ config acs 'acs'
#­ possible configs interval :[1000:65535]
option retry_interval_multiplier '2000'
option skip_dhcp_boot_options '0'
option insecure_enable '0'
config cpe 'cpe'
option enable '1'
@@ -20,9 +21,8 @@ config cpe 'cpe'
option default_lan_interface 'lan'
option log_to_console 'disable'
option log_to_file 'disable'
# log_severity: INFO (Default)
# log_severity possible configs: EMERG, ALERT, CRITIC ,ERROR, WARNING, NOTICE, INFO, DEBUG
option log_severity 'ERROR'
option log_severity 'WARNING'
option log_file_name '/var/log/icwmpd.log'
option log_max_size '102400'
option userid '' #$OUI-$SER
@@ -42,6 +42,7 @@ config cpe 'cpe'
option disable_gatewayinfo '0'
option fw_upgrade_keep_settings '1'
option clock_sync_timeout '128'
option disable_datatype_check '0'
config lwn 'lwn'
option enable '0'

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ieee1905
PKG_VERSION:=8.6.3
PKG_VERSION:=8.7.3
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=64a2c525c8b66d10643696fcd51bb916f4fb1d7b
PKG_SOURCE_VERSION:=f3f4dbaac6b2ff6cfd38852e8625625d24996a53
PKG_SOURCE_URL:=https://dev.iopsys.eu/multi-ap/ieee1905.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip
@@ -41,7 +41,8 @@ define Package/libieee1905
$(call Package/ieee1905/Default)
TITLE:=libieee1905.so (library for CMDU and TLV handling)
DEPENDS= +libubox +libuci +libubus +libeasy +libnl-genl \
+libjson-c +libblobmsg-json +libwifiutils
+libjson-c +libblobmsg-json +libwifiutils \
+iputils-arping
endef
define Package/ieee1905
@@ -50,7 +51,7 @@ define Package/ieee1905
DEPENDS= +libubox +libuci +libubus +libeasy +libnl-genl \
+libjson-c +libblobmsg-json +ubus +libpthread \
+libieee1905 +IEEE1905_PLATFORM_HAS_WIFI:libwifi \
+libwifiutils
+libwifiutils +iputils-arping
DEPENDS+=+IEEE1905_BUILD_TR181_PLUGIN:libbbfdm-api \
+IEEE1905_BUILD_TR181_PLUGIN:libbbfdm-ubus \
+IEEE1905_BUILD_TR181_PLUGIN:dm-service

View File

@@ -24,7 +24,7 @@ define KernelPackage/ipt-trigger
SUBMENU:=Other modules
TITLE:=Kernel module for iptables port trigger
FILES:=$(PKG_BUILD_DIR)/src/ipv4/ipt_TRIGGER.ko
DEPENDS+=+kmod-nf-nat +xtables-legacy
DEPENDS+=+kmod-nf-nat +kmod-ipt-core
AUTOLOAD:=$(call AutoLoad,30,ipt_TRIGGER,1)
KCONFIG:=
endef
@@ -32,7 +32,7 @@ endef
define KernelPackage/ip6t-trigger
SUBMENU:=Other modules
TITLE:=Kernel module for ip6tables port trigger
DEPENDS+=+kmod-nf-nat +xtables-legacy
DEPENDS+=+kmod-nf-nat +kmod-ipt-core
FILES:=$(PKG_BUILD_DIR)/src/ipv6/ip6t_TRIGGER.ko
AUTOLOAD:=$(call AutoLoad,30,ip6t_TRIGGER,1)
KCONFIG:=
@@ -46,9 +46,7 @@ define KernelPackage/ip6t-trigger/description
Kernel module to enable port trigger for ip6tables
endef
ifeq ($(CONFIG_TARGET_brcmbca),y)
include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
endif
-include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
@@ -67,8 +65,6 @@ define Build/InstallDev
$(CP) $(PKG_BUILD_DIR)/include/ipt_TRIGGER.h $(1)/include/linux/netfilter_ipv4/
endef
KERNEL_MAKE_FLAGS += -I$(LINUX_DIR)/include
define Build/Compile
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/src/ipv4/" modules
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/src/ipv6/" modules

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libethernet
PKG_VERSION:=7.2.116
PKG_VERSION:=7.2.117
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=243de75f54baa44a7c1aec2460e07478c4479ed9
PKG_SOURCE_VERSION:=e917cdcfa0beb15a452f204521bea3d3571190b3
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/libethernet.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip

View File

@@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=libvoice-airoha
PKG_RELEASE:=1
PKG_VERSION:=1.0.12
PKG_VERSION:=1.1.1
PKG_LICENSE:=PROPRIETARY
PKG_LICENSE_FILES:=LICENSE
@@ -17,7 +17,7 @@ LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/$(PKG_NAME).git
PKG_SOURCE_VERSION:=68f0b4f3edecea9b8f05e72b6bbf3952d3946b7c
PKG_SOURCE_VERSION:=83fdadd72e4c7fb2b2f295145e599a7b784e6b52
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -0,0 +1,17 @@
#!/bin/sh
hasVoice=$(db -q get hw.board.hasVoice)
[ "$hasVoice" = "1" ] || exit 0
SLIC=`cat /proc/device-tree/airoha-voice/slic-type`
[ "${SLIC#pef}" != "${SLIC}" ] || exit 0
echo Configure TxGain and RxGain for MXL SLIC $SLIC
ports=$(db -q get hw.board.VoicePorts)
for p in $(seq 0 $((ports-1))); do
uci set asterisk.extension${p}.txgain='10'
uci set asterisk.extension${p}.rxgain='-15'
done
uci commit asterisk

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libwifi
PKG_VERSION:=7.8.8
PKG_VERSION:=7.9.5
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=4a1eaa7bfcaf4d2c0efeb453ea7c40b5ab7904ac
PKG_SOURCE_VERSION:=1e70b170de2c06b3db1491283870bf9100aef6f0
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/libwifi.git
PKG_MAINTAINER:=Anjan Chanda <anjan.chanda@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=logmngr
PKG_VERSION:=1.0.8
PKG_VERSION:=1.0.9
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/system/logmngr.git
PKG_SOURCE_VERSION:=7c2056c9f5dc23fd1260846c72210365ec69c882
PKG_SOURCE_VERSION:=e2ffe2b9e7722ce19dff7db6e47e62a305dc568b
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -65,7 +65,7 @@ endif
ifeq ($(CONFIG_LOGMNGR_BACKEND_SYSLOG_NG),y)
$(INSTALL_DATA) ./files/lib/logmngr/syslog-ng.sh $(1)/lib/logmngr/
endif
$(BBFDM_INSTALL_CORE_PLUGIN) $(PKG_BUILD_DIR)/bbf_plugin/libbbfsyslog.so $(1)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/bbf_plugin/libbbfsyslog.so $(1) core
ifeq ($(CONFIG_LOGMNGR_LOGROTATE),y)
$(INSTALL_BIN) ./files/11-logmngr_logrotate_config_generate $(1)/etc/uci-defaults/
$(INSTALL_DATA) ./files/lib/logmngr/logrotate.sh $(1)/lib/logmngr/

View File

@@ -5,9 +5,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=map-agent
PKG_VERSION:=6.2.3.13
PKG_VERSION:=6.3.2.4
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=9e7e81b46a2f0aa0c8fca2024e100af2eb723fb6
PKG_SOURCE_VERSION:=3626e70e317ed9dccff9a62dd9ed9d477232f5c1
PKG_MAINTAINER:=Jakob Olsson <jakob.olsson@iopsys.eu>
PKG_LICENSE:=BSD-3-Clause

View File

@@ -63,7 +63,7 @@ else
[ $dhcp -eq 1 ] || exit 0
else
[ -f $map_bh_file ] || exit 0
cur_bh="$(cat $map_bh_file | jsonfilter -e @.ifname)"
cur_bh="$(jsonfilter -e @.ifname < "$map_bh_file" 2>/dev/null)" || exit 0
[ "$cur_bh" = "$PORT" ] || exit 0
fi
########################################################

View File

@@ -10,6 +10,11 @@ config CONTROLLER_EASYMESH_VENDOR_EXT
bool "Enable extra features through Easymesh vendor extension"
default y
config CONTROLLER_PROVISION_DISABLED_AP
depends on CONTROLLER_EASYMESH_VENDOR_EXT
bool "Enable vendor extension that provisions disabled APs to agents"
default n
config CONTROLLER_EASYMESH_VENDOR_EXT_OUI_DEFAULT
hex "Vendor OUI default"
default 0xB456FA

View File

@@ -5,9 +5,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=map-controller
PKG_VERSION:=6.1.2.21
PKG_VERSION:=6.2.3.0
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=1551c1f2a444ed7c90d81bf8292a89ef88460795
PKG_SOURCE_VERSION:=f296140a88c5c9010b80903be2802a22f8eae4e9
PKG_MAINTAINER:=Jakob Olsson <jakob.olsson@iopsys.eu>
LOCAL_DEV=0
@@ -61,6 +61,9 @@ endif
ifeq ($(CONFIG_CONTROLLER_EASYMESH_VENDOR_EXT),y)
TARGET_CFLAGS += -DEASYMESH_VENDOR_EXT_OUI=$(CONFIG_CONTROLLER_EASYMESH_VENDOR_EXT_OUI)
TARGET_CFLAGS += -DEASYMESH_VENDOR_EXT
ifeq ($(CONFIG_CONTROLLER_PROVISION_DISABLED_AP),y)
TARGET_CFLAGS += -DPROVISION_DISABLED_AP
endif
endif
ifeq ($(CONFIG_CONTROLLER_PROPAGATE_PROBE_REQ),y)

View File

@@ -39,7 +39,7 @@ config sta_steering
config ap
option band '2'
option ssid '$DEVICE_MANUFACTURER-$BASEMAC_ADDR'
option ssid '$DEFAULT_SSID'
option encryption 'sae-mixed'
option key '$WIFI_FH_KEY'
option vid '1'
@@ -48,7 +48,7 @@ config ap
config ap
option band '5'
option ssid '$DEVICE_MANUFACTURER-$BASEMAC_ADDR'
option ssid '$DEFAULT_SSID'
option encryption 'sae-mixed'
option key '$WIFI_FH_KEY'
option vid '1'
@@ -57,7 +57,7 @@ config ap
config ap
option band '6'
option ssid '$DEVICE_MANUFACTURER-$BASEMAC_ADDR'
option ssid '$DEFAULT_SSID'
option encryption 'sae'
option key '$WIFI_FH_KEY'
option vid '1'

View File

@@ -1,6 +1,7 @@
#!/bin/sh
. /etc/device_info
. /lib/functions/system.sh
WIFI_BH_KEY=$(openssl rand -rand /dev/urandom -hex 64 2>/dev/null | openssl dgst -hex -sha256 | cut -d " " -f 2)
WIFI_BH_KEY=${WIFI_BH_KEY::-1}
@@ -8,10 +9,17 @@ WIFI_BH_KEY=${WIFI_BH_KEY::-1}
BASEMAC_ADDR="$(fw_printenv -n ethaddr | tr -d ':' | tr 'a-z' 'A-Z')"
[ ${#BASEMAC_ADDR} -eq 12 ] || BASEMAC_ADDR="$(db -q get device.deviceinfo.BaseMACAddress | tr -d ':')"
source /boarddata/board-data
DEFAULT_SSID="${var_ssid_prefix}${var_ssid_mac_postfix_r0}"
if [ -z "$DEFAULT_SSID" ]; then
DEFAULT_SSID="${DEVICE_MANUFACTURER}-${BASEMAC_ADDR}"
fi
WIFI_FH_KEY="$(db get hw.board.wpa_key)"
WIFI_FH_KEY="${WIFI_FH_KEY:-1234567890}"
sed -i -e "s/\$BASEMAC_ADDR/$BASEMAC_ADDR/g" \
-e "s/\$DEFAULT_SSID/$DEFAULT_SSID/g" \
-e "s/\$WIFI_FH_KEY/$WIFI_FH_KEY/g" \
-e "s/\$WIFI_BH_KEY/$WIFI_BH_KEY/g" \
-e "s/\$DEVICE_MANUFACTURER/$DEVICE_MANUFACTURER/g" \

5
mcastmngr/Config.in Normal file
View File

@@ -0,0 +1,5 @@
if PACKAGE_mcastmngr
config MCASTMNGR_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -6,14 +6,14 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=mcastmngr
PKG_VERSION:=1.2.9
PKG_VERSION:=1.2.11
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/hal/mcastmngr.git
PKG_SOURCE_VERSION:=275d7e5448333e53f8bc980344b39f7f577d4664
PKG_SOURCE_VERSION:=17d73b8f1947823a0d32ed589a240a2642904fe1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -39,13 +39,23 @@ define Package/mcastmngr/description
Configures IGMP and MLD snooping and proxy
endef
define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/mcastmngr/* $(PKG_BUILD_DIR)/
endef
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_MCASTMNGR_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_MCASTMNGR_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
define Package/mcastmngr/install
$(CP) ./files/common/* $(1)/
@@ -54,7 +64,7 @@ ifneq ($(CONFIG_TARGET_brcmbca),)
else
$(CP) ./files/linux/* $(1)/
endif
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_REGISTER_SERVICES) -v ${VENDOR_PREFIX} ./bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/bbf_plugin/libmcast_bbf.so $(1) $(PKG_NAME)
endef

View File

@@ -24,4 +24,7 @@ config NETMNGR_IPV6RD_OBJ
bool "Enable Device.IPv6rd. Object"
default y
config NETMNGR_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=netmngr
PKG_VERSION:=1.1.2
PKG_VERSION:=1.1.4
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/netmngr.git
PKG_SOURCE_VERSION:=f9a0e9490743c55bf7c6df02495b4dbba8c66aeb
PKG_SOURCE_VERSION:=34b7163a759038edbbc0304be36abad05b9bc9b4
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -39,7 +39,13 @@ endef
MAKE_PATH:=src
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_NETMNGR_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_NETMNGR_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_NETMNGR_GRE_OBJ),y)
MAKE_FLAGS += NETMNGR_GRE_OBJ=y
@@ -68,7 +74,6 @@ endif
define Package/netmngr/install
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libnetmngr.so $(1) $(PKG_NAME)
$(BBFDM_INSTALL_CORE_PLUGIN) $(PKG_BUILD_DIR)/src/libinterface_stack.so $(1)
endef
ifeq ($(LOCAL_DEV),1)

View File

@@ -27,6 +27,10 @@
{
"parent_dm": "Device.",
"object": "IPv6rd"
},
{
"parent_dm": "Device.",
"object": "InterfaceStack"
}
],
"config": {

View File

@@ -62,4 +62,12 @@ config OBUSPA_CWMP_DATAMODEL_SUPPORT
help
Expose Device.USPAgent., Device.STOMP., Device.MQTT.Client. objects over
ubus to make it available to bbfdm for CWMP access
config OBUSPA_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
config OBUSPA_OVERRIDE_CT_ROLE
bool "Override ControllerTrust role with factory default roles"
default y
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=obuspa
PKG_VERSION:=9.0.4.2
PKG_VERSION:=9.0.4.8
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/obuspa.git
PKG_SOURCE_VERSION:=ccba361190e42000da16380591df80e5e5225d68
PKG_SOURCE_VERSION:=e6dd22754d3a4fee1c804f8f17fe57b3f38a2c1f
PKG_MAINTAINER:=Vivek Dutta <vivek.dutta@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
@@ -50,9 +50,16 @@ TARGET_CFLAGS += \
-D_GNU_SOURCE \
-DHAVE_STRERROR_R \
-Wall \
-D_DM_VENDOR_PREFIX=$(CONFIG_BBF_VENDOR_PREFIX) \
-Werror
ifeq ($(CONFIG_OBUSPA_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_OBUSPA_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -D_DM_VENDOR_PREFIX=$(VENDOR_PREFIX)
CMAKE_OPTIONS += -DCMAKE_INSTALL_PREFIX=/tmp
CMAKE_OPTIONS += -DCMAKE_INSTALL_LOCALSTATEDIR=""
@@ -96,7 +103,7 @@ ifeq ($(CONFIG_OBUSPA_SESSION_EXTENSION),y)
TARGET_CFLAGS += -DOBUSPA_ENABLE_SESSION_EXT
endif
ifdef $(CONFIG_OBUSPA_MAX_CONTROLLERS_NUM)
ifneq ($(CONFIG_OBUSPA_MAX_CONTROLLERS_NUM),)
TARGET_CFLAGS += -DOBUSPA_MAX_CONTROLLERS_NUM=$(CONFIG_OBUSPA_MAX_CONTROLLERS_NUM)
endif
@@ -120,7 +127,7 @@ define Package/obuspa/install
$(INSTALL_DATA) ./files/etc/config/obuspa $(1)/etc/config/
$(INSTALL_DATA) ./files/etc/users/roles/*.json $(1)/etc/users/roles/
$(INSTALL_DATA) ./files/etc/obuspa/usp_utils.sh $(1)/etc/obuspa/
echo "$(CONFIG_BBF_VENDOR_PREFIX)" > $(1)/etc/obuspa/vendor_prefix
echo "$(VENDOR_PREFIX)" > $(1)/etc/obuspa/vendor_prefix
$(INSTALL_BIN) ./files/etc/uci-defaults/01-fix-upgrade-uci $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/60-generate-ctrust-defaults $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/obuspa-set-dhcp-option $(1)/etc/uci-defaults/
@@ -138,6 +145,9 @@ ifeq ($(CONFIG_OBUSPA_ENABLE_TEST_CONTROLLER_LOCAL),y)
$(INSTALL_BIN) ./files/etc/init.d/usptest $(1)/etc/init.d/
$(INSTALL_BIN) ./files/etc/uci-defaults/55-test-usp-controller $(1)/etc/uci-defaults/
endif
ifeq ($(CONFIG_OBUSPA_OVERRIDE_CT_ROLE),y)
$(INSTALL_BIN) ./files/etc/uci-defaults/61-override-ct-roles $(1)/etc/uci-defaults/
endif
endef
$(eval $(call BuildPackage,obuspa))

View File

@@ -2,22 +2,20 @@
"daemon": {
"enable": "1",
"service_name": "obuspa",
"proto": "cwmp",
"unified_daemon": false,
"services": [
{
"parent_dm": "Device.",
"object": "USPAgent",
"proto": "cwmp"
"object": "USPAgent"
},
{
"parent_dm": "Device.",
"object": "MQTT",
"proto": "cwmp"
"object": "MQTT"
},
{
"parent_dm": "Device.",
"object": "STOMP",
"proto": "cwmp"
"object": "STOMP"
}
],
"config": {

View File

@@ -5,7 +5,6 @@ config obuspa 'global'
option log_level '2'
option prototrace '0'
option db_file '/etc/obuspa/usp.db'
#option max_group_sep '2'
#option ipc_timeout '30'
#option max_cache_time '600'
#option trust_cert '/etc/obuspa/ca.pem'

View File

@@ -958,12 +958,6 @@ db_init()
mv ${SQL_DB_FILE}.old ${SQL_DB_FILE}
fi
if [ -f "${role_file}" ]; then
configure_ctrust_role "${role_file}"
uci_set obuspa global role_file ""
uci commit ${CONFIGURATION}
fi
# Dump datamodel parameters from DB
if [ -f "${SQL_DB_FILE}" ]; then
dump_db

View File

@@ -4,6 +4,7 @@ CTRUST_RESET_FILE="/tmp/obuspa/ctrust_reset"
VENDOR_PREFIX_FILE="/etc/obuspa/vendor_prefix"
FW_DEFAULT_ROLE_DIR="/etc/users/roles"
mkdir -p /tmp/obuspa/
# include jshn.sh
if [ -f "/usr/local/share/libubox/jshn.sh" ]; then
@@ -196,6 +197,10 @@ configure_ctrust_role()
local num
local roles_obj
if [ -f "${CTRUST_RESET_FILE}" ]; then
return 0
fi
mkdir -p /tmp/obuspa/
if [ -f "${1}" ]; then
json_init

View File

@@ -4,12 +4,14 @@
. /etc/obuspa/usp_utils.sh
rfile="$(uci -q get obuspa.global.role_file)"
db_file="$(uci -q get obuspa.global.db_file)"
# Reset the role_file if present
if [ -n "${rfile}" ]; then
uci -q set obuspa.global.role_file=""
fi
configure_ctrust_role "${rfile}"
if [ ! -f "${db_file}" ]; then
configure_ctrust_role
fi
exit 0

View File

@@ -0,0 +1,8 @@
#!/bin/sh
. /lib/functions.sh
. /etc/obuspa/usp_utils.sh
configure_ctrust_role
exit 0

View File

@@ -455,16 +455,37 @@ index 915b282..f799793 100755
// From the point of view of this code, the report(s) have been successfully sent, so don't retain them
// NOTE: Sending of the reports successfully is delegated to the USP notification retry mechanism
@@ -2547,7 +2729,7 @@ void bulkdata_process_profile_mqtt(bulkdata_profile_t *bp)
@@ -2547,11 +2729,24 @@ void bulkdata_process_profile_mqtt(bulkdata_profile_t *bp)
}
// Exit if unable to generate the report
- report = bulkdata_generate_json_report(bp, ctrl.report_timestamp);
+ report = bulkdata_generate_json_report(bp, ctrl.report_timestamp, ctrl.report_format);
if (report == NULL)
{
USP_ERR_SetMessage("%s: bulkdata_generate_json_report failed", __FUNCTION__);
@@ -2762,7 +2944,7 @@ int bulkdata_reduce_to_alt_name(char *spec, char *path, char *alt_name, char *ou
- if (report == NULL)
- {
- USP_ERR_SetMessage("%s: bulkdata_generate_json_report failed", __FUNCTION__);
- return;
+ if (strcmp(ctrl.encoding_type, BULKDATA_ENCODING_TYPE_JSON) == 0) {
+ report = bulkdata_generate_json_report(bp, ctrl.report_timestamp, ctrl.report_format);
+ if (report == NULL)
+ {
+ USP_ERR_SetMessage("%s: bulkdata_generate_json_report failed", __FUNCTION__);
+ return;
+ }
+ } else if (strcmp(ctrl.encoding_type, BULKDATA_ENCODING_TYPE_CSV) == 0) {
+ report = bulkdata_generate_csv_report(bp, ctrl.field_separator, ctrl.row_separator, ctrl.escape_char,
+ ctrl.csv_format, ctrl.row_timestamp);
+ if (report == NULL)
+ {
+ USP_ERR_SetMessage("%s: bulkdata_generate_csv_report failed", __FUNCTION__);
+ return;
+ }
+ } else {
+ USP_ERR_SetMessage("%s: bulkdata invalid report encoding type %s", __FUNCTION__, ctrl.encoding_type);
+ return;
}
// Print out the JSON report, if debugging is enabled
@@ -2762,7 +2957,7 @@ int bulkdata_reduce_to_alt_name(char *spec, char *path, char *alt_name, char *ou
** \return pointer to NULL terminated dynamically allocated buffer containing the serialized report to send
**
**************************************************************************/
@@ -473,7 +494,7 @@ index 915b282..f799793 100755
{
JsonNode *top; // top of report
JsonNode *array; // array of reports (retained + current)
@@ -2867,6 +3049,483 @@ char *bulkdata_generate_json_report(bulkdata_profile_t *bp, char *report_timesta
@@ -2867,6 +3062,483 @@ char *bulkdata_generate_json_report(bulkdata_profile_t *bp, char *report_timesta
return result;
}
@@ -957,7 +978,7 @@ index 915b282..f799793 100755
/*********************************************************************//**
**
** bulkdata_compress_report
@@ -3070,6 +3729,20 @@ int bulkdata_schedule_sending_http_report(profile_ctrl_params_t *ctrl, bulkdata_
@@ -3070,6 +3742,20 @@ int bulkdata_schedule_sending_http_report(profile_ctrl_params_t *ctrl, bulkdata_
flags |= BDC_FLAG_DATE_HEADER;
}

View File

@@ -0,0 +1,11 @@
--- a/src/core/device_bulkdata.c 2025-02-18 16:49:27.507575767 +0530
+++ b/src/core/device_bulkdata.c 2025-02-18 16:51:45.535693108 +0530
@@ -374,6 +374,8 @@
// Device.BulkData.Profile.{i}.MQTT
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.MQTT.Reference", "", Validate_BulkDataMqttReference, NULL, DM_STRING);
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.MQTT.PublishTopic", "", NULL, NULL, DM_STRING);
+ err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.MQTT.PublishQoS", TO_STR(MQTT_FALLBACK_QOS), NULL, NULL, DM_UINT);
+ err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.MQTT.PublishRetain", "false", NULL, NULL, DM_BOOL);
#endif
// Register Push! Event

View File

@@ -5,7 +5,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=packet-capture-diagnostics
PKG_VERSION:=1.0.2
PKG_VERSION:=1.0.3
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
@@ -46,7 +46,7 @@ endif
define Package/packet-capture-diagnostics/install
$(BBFDM_INSTALL_SCRIPT) ./files/scripts/packetcapture $(1)
$(BBFDM_INSTALL_CORE_PLUGIN) $(PKG_BUILD_DIR)/src/libpackcapture.so $(1)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/src/libpackcapture.so $(1) core
endef
$(eval $(call BuildPackage,packet-capture-diagnostics))

View File

@@ -1,7 +1,5 @@
if PACKAGE_parental-control
menu "Configuration"
config PARENTAL_CONTROL_INCLUDE_URLFILTER_BUNDLES
bool "Include default bundle files"
default n
@@ -9,5 +7,8 @@ config PARENTAL_CONTROL_INCLUDE_URLFILTER_BUNDLES
Set this option to include bundle files by default,
they are also included in the UCI, urlfilter
still needs to be enabled though.
endmenu
config PARENTAL_CONTROL_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=parental-control
PKG_VERSION:=1.0.3
PKG_VERSION:=1.1.3
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/parental-control.git
PKG_SOURCE_VERSION:=410d1af9de498615090c5d4ac0388701d1870f68
PKG_SOURCE_VERSION:=3e3bbbb660a23fd31744b0521998f79516db98fd
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -39,9 +39,15 @@ define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
TARGET_CFLAGS += \
-D_GNU_SOURCE\
-DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
TARGET_CFLAGS += -D_GNU_SOURCE
ifeq ($(CONFIG_PARENTAL_CONTROL_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_PARENTAL_CONTROL_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
TARGET_LDFLAGS += \
-lcmph
@@ -53,8 +59,10 @@ endef
endif
define Package/parental-control/install
$(INSTALL_DIR) $(1)/etc/parentalcontrol
$(INSTALL_DIR) $(1)/lib/parentalcontrol
$(INSTALL_DATA) ./files/lib/parentalcontrol/parentalcontrol.sh $(1)/lib/parentalcontrol/
$(INSTALL_BIN) ./files/lib/parentalcontrol/sync_bundles.sh $(1)/lib/parentalcontrol/
$(INSTALL_DIR) $(1)/etc
$(INSTALL_DATA) ./files/etc/firewall.parentalcontrol $(1)/etc/
@@ -71,11 +79,14 @@ define Package/parental-control/install
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_DATA) ./files/etc/uci-defaults/95-firewall_parentalcontrol.ucidefaults $(1)/etc/uci-defaults/
$(INSTALL_DATA) ./files/etc/uci-defaults/95-migrate_urlfilter.ucidefaults $(1)/etc/uci-defaults/
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) parentalcontrol
$(INSTALL_DIR) $(1)/lib/upgrade/keep.d
$(INSTALL_DATA) ./files/lib/upgrade/keep.d/parentalcontrol $(1)/lib/upgrade/keep.d/parentalcontrol
$(BBFDM_REGISTER_SERVICES) -v ${VENDOR_PREFIX} ./bbfdm_service.json $(1) parentalcontrol
ifeq ($(CONFIG_PARENTAL_CONTROL_INCLUDE_URLFILTER_BUNDLES),y)
$(INSTALL_DIR) $(1)/etc/parental-control
$(INSTALL_DATA) ./files/etc/parental-control/urlbundles.tar.xz $(1)/etc/parental-control/
$(INSTALL_DATA) ./files/etc/parentalcontrol/urlbundles.tar.xz $(1)/etc/parentalcontrol/
endif
endef

View File

@@ -1,3 +1,93 @@
config globals 'globals'
option enable '0'
option loglevel '3'
option enable '0'
option loglevel '3'
config urlbundle 'urlbundle_1'
option enable '0'
option name 'Abuse'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/abuse-nl.txt'
config urlbundle 'urlbundle_2'
option enable '0'
option name 'Ads'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/ads-nl.txt'
config urlbundle 'urlbundle_3'
option enable '0'
option name 'Crypto'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/crypto-nl.txt'
config urlbundle 'urlbundle_4'
option enable '1'
option name 'Drugs'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/drugs-nl.txt'
config urlbundle 'urlbundle_5'
option enable '0'
option name 'Everything else'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/everything-nl.txt'
config urlbundle 'urlbundle_6'
option enable '1'
option name 'Facebook/Instagram'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/facebook-nl.txt'
config urlbundle 'urlbundle_7'
option enable '1'
option name 'Fraud'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/fraud-nl.txt'
config urlbundle 'urlbundle_8'
option enable '1'
option name 'Gambling'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/gambling-nl.txt'
config urlbundle 'urlbundle_9'
option enable '0'
option name 'Malware'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/malware-nl.txt'
config urlbundle 'urlbundle_10'
option enable '1'
option name 'Phishing'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/phishing-nl.txt'
config urlbundle 'urlbundle_11'
option enable '1'
option name 'Piracy'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/piracy-nl.txt'
config urlbundle 'urlbundle_12'
option enable '0'
option name 'Porn'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/porn-nl.txt'
config urlbundle 'urlbundle_13'
option enable '1'
option name 'Ransomware'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/ransomware-nl.txt'
config urlbundle 'urlbundle_14'
option enable '0'
option name 'Redirect'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/redirect-nl.txt'
config urlbundle 'urlbundle_15'
option enable '1'
option name 'Scam'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/scam-nl.txt'
config urlbundle 'urlbundle_16'
option enable '0'
option name 'TikTok'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/tiktok-nl.txt'
config urlbundle 'urlbundle_17'
option enable '0'
option name 'Torrent'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/torrent-nl.txt'
config urlbundle 'urlbundle_18'
option enable '0'
option name 'Tracking'
option download_url 'https://blocklistproject.github.io/Lists/alt-version/tracking-nl.txt'

View File

@@ -11,7 +11,8 @@ PROG=/usr/sbin/urlfilter
validate_global_section() {
uci_validate_section parentalcontrol globals globals \
'enable:bool:1' \
'loglevel:uinteger:3'
'loglevel:uinteger:3' \
'bundle_path:string'
}
remove_fw_rules() {
@@ -47,19 +48,48 @@ configure_fw_rules() {
add_internet_schedule_rules
}
copy_dhcp_leases() {
src="/tmp/dhcp.leases"
dest="/etc/parentalcontrol/dhcp.leases"
dest_dir="/etc/parentalcontrol/"
# Ensure the destination directory exists
mkdir -p "$dest_dir" || { logger -p err "Failed to create directory $dest_dir."; return 1; }
# Check if the source file exists and is not empty
if [ -s "$src" ]; then
# Compare the content of the source and destination
if ! cmp -s "$src" "$dest"; then
# Use atomic copy to prevent partial writes
tmp_dest="${dest}.tmp"
cp "$src" "$tmp_dest" && mv "$tmp_dest" "$dest"
fi
fi
}
start_service() {
local enable loglevel
local enable loglevel bundle_path
config_load parentalcontrol
validate_global_section
[ -n "${bundle_path}" ] && mkdir -p ${bundle_path}
# add default bundles
process_default_bundles
# add firewall rules
configure_fw_rules
procd_open_instance parentalcontrol_dm
procd_set_param command ${PROG}
# if the router is, for example, upgraded and then it boots up
# then /tmp/dhcp.leases will be empty until clients try to get a lease,
# in that case, hostnames will not be processed by the daemon,
# for this we copy /tmp/dhcp.leases to /etc/parentalcontrol/dhcp.leases
# which will be persistent acrros reboots and upgrade where settings are kept
# and will be used as a backup in case /tmp/dhcp.leases is empty
copy_dhcp_leases
procd_open_instance "parentalcontrol_dm"
procd_set_param command nice -n 10 "${PROG}" # Lower priority
procd_append_param command -l ${loglevel}
procd_set_param respawn
procd_close_instance
@@ -69,6 +99,7 @@ stop_service() {
# remove default bundles
remove_default_bundles
remove_fw_rules
copy_dhcp_leases
}
reload_service() {
@@ -78,6 +109,7 @@ reload_service() {
start
else
configure_fw_rules
copy_dhcp_leases
ubus send parentalcontrol.reload
fi
}

View File

@@ -13,8 +13,8 @@ IP_RULE=""
ACL_FILE=""
parentalcontrol_ipv4_forward=""
parentalcontrol_ipv6_forward=""
default_bundle_dir="/tmp/urlfilter/default/"
bundle_archive="/etc/parental-control/urlbundles.tar.xz"
default_bundle_dir="/tmp/parentalcontrol/default/"
bundle_archive="/etc/parentalcontrol/urlbundles.tar.xz"
log() {
echo "$*" |logger -t urlfilter.init -p debug

View File

@@ -0,0 +1,295 @@
#!/bin/sh
. /lib/functions.sh
LOCKFILE="/tmp/sync_bundles.lock"
# this script handles syncing bundles
# if its a remote file, then it would be downloaded and placed in bundle_dir
bundle_path="$(uci -q get parentalcontrol.globals.bundle_path)"
if [ -z "${bundle_path}" ]; then
bundle_path="/tmp/parentalcontrol"
fi
stringstore_dir="${bundle_path}/stringstore"
bundle_dir="${bundle_path}/urlbundles"
bundle_sizes="${bundle_path}/bundle_sizes"
# Ensure required directories and files exist
initialize_environment() {
mkdir -p "$bundle_dir"
mkdir -p "$stringstore_dir"
[ ! -f "$bundle_sizes" ] && touch "$bundle_sizes"
}
# Function to sanitize URLs to avoid code injection and ensure safety
sanitize_url() {
local raw_url="$1"
echo "$raw_url" | sed 's/[^a-zA-Z0-9_.:/?-]//g'
}
update_bundle_file_from_url() {
local download_url="$1"
local bundle_file_name="$2"
local bundle_file_size="$3"
local bundle_name="$4"
local file_name="$5"
local available_memory
available_memory=$(df "$bundle_dir" | tail -n 1 | awk '{print $(NF-2)}') # Available memory in 1K blocks
local needed_blocks=$((bundle_file_size / 1024)) # Convert bundle_file_size to 1K blocks
local max_size=$((10 * 1024 * 1024)) # 10MB in bytes
if [ "$available_memory" -le "$needed_blocks" ]; then
logger -p info "Error: Not enough disk space for bundle: ${bundle_name}"
return 1
fi
if [ "$bundle_file_size" -gt "$max_size" ]; then
logger -p info "update_bundle_file_from_url: Error: File size for ${bundle_name} exceeds 10MB"
return 1
fi
# Determine file path
local file_path
if echo "$download_url" | grep -q "^file://"; then
file_path=${download_url#file://}
else
# Random delay (0-5s) before starting the download
local delay=$((RANDOM % 6))
logger -p info "update_bundle_file_from_url: Waiting ${delay}s before downloading..."
sleep "$delay"
# Retry logic with exponential backoff
local temp_file="${bundle_dir}/tmp_${file_name}"
local attempt=1
local success=0
while [ $attempt -le 3 ]; do
curl -s -o "$temp_file" "$download_url"
if [ $? -eq 0 ]; then
success=1
break
else
logger -p info "update_bundle_file_from_url: Download failed. Retrying $attempt ..."
local backoff=$(( (2 ** attempt) + (RANDOM % 3) )) # Exponential backoff + 0-2s jitter
sleep "$backoff"
fi
attempt=$(( attempt+1 ))
done
if [ $success -ne 1 ]; then
logger -p info "update_bundle_file_from_url: Failed to download bundle: ${bundle_name}"
rm -f "$temp_file"
return 1
fi
file_path="$temp_file"
fi
# Handle compressed files
local final_path="${bundle_dir}/${bundle_file_name}"
if [[ "$file_path" =~ \.xz$ ]]; then
if ! xz -dc "$file_path" > "$final_path"; then
logger -p info "update_bundle_file_from_url: Decompression failed."
rm -f "$final_path"
rm -f "$file_path"
return 1
fi
rm -f "$file_path"
elif [[ "$file_path" =~ \.gz$ ]]; then
if ! gzip -dc "$file_path" > "$final_path"; then
logger -p info "update_bundle_file_from_url: Decompression failed."
rm -f "$final_path"
rm -f "$file_path"
return 1
fi
rm -f "$file_path"
else
mv "$file_path" "$final_path"
fi
# file would have lines of the format: 0.0.0.0 www.facebook.com
# so we keep only the url part and remove duplicates
local processed_final_path="${final_path}_urls"
awk '{print $NF}' "$final_path" | sort -u > "$processed_final_path"
# delete unprocessed file
rm -rf "$final_path"
# Update the bundle size and send ubus event
echo "$bundle_file_name $bundle_file_size" >> "$bundle_sizes"
ubus send "parentalcontrol.bundle.update" "{\"bundle_file_path\":\"${processed_final_path}\",\"bundle_name\":\"${bundle_name}\"}"
return 0
}
handle_download_url() {
local raw_download_url="$1"
local bundle_name="$2"
local sanitized_url
sanitized_url=$(sanitize_url "$raw_download_url")
local file_name="${sanitized_url##*/}" # Get everything after the last '/'
local bundle_file_name="${file_name}.urlbundle"
local unprocessed_file=0
local file_path="${sanitized_url#file://}"
if echo "$sanitized_url" | grep -qE "^https?://|^file://"; then
local previous_bundle_size
previous_bundle_size=$(grep "^${bundle_file_name} " "$bundle_sizes" | awk '{print $2}')
# If the URL is HTTP, fetch the file size
local bundle_file_size
if echo "$sanitized_url" | grep -qE "^https?://"; then
bundle_file_size="$(curl -I "$sanitized_url" 2>&1 | grep -i 'content-length' | cut -d: -f2 | xargs)"
[ -z "$bundle_file_size" ] && bundle_file_size=0
else
# If it's a file:// URL, get the file size from the filesystem
bundle_file_size=$(ls -l "$file_path" 2>/dev/null | awk '{print $5}')
[ -z "$bundle_file_size" ] && bundle_file_size=0
fi
if [ -n "$previous_bundle_size" ] && [ "$bundle_file_size" -eq "$previous_bundle_size" ]; then
return
fi
if echo "$sanitized_url" | grep -q "^file://" && ! echo "$sanitized_url" | grep -Eq "\.(xz|gz)$"; then
# the file is not processed and hence not moved if it is a local uncompressed file
sed -i "/^${bundle_file_name} /d" "$bundle_sizes"
echo "$bundle_file_name $bundle_file_size" >> "$bundle_sizes"
ubus send "parentalcontrol.bundle.update" "{\"bundle_file_path\":\"${file_path}\",\"bundle_name\":\"${bundle_name}\"}"
return
fi
# Remove existing entries
if [ -n "$previous_bundle_size" ]; then
sed -i "/^${bundle_file_name} /d" "$bundle_sizes"
rm -f "${bundle_dir}/${bundle_file_name}"
fi
update_bundle_file_from_url "$sanitized_url" "$bundle_file_name" "$bundle_file_size" "$bundle_name" "$file_name"
return $?
else
logger -p info "Error: Unsupported URL format for ${bundle_file_name}"
return 1
fi
return 0
}
cleanup_bundle_files() {
local dir="$1"
[ -d "$dir" ] || return 1
# Collect all download_url entries using config_foreach
local urls=""
get_download_url() {
local section="$1"
config_get url "$section" download_url
config_get_bool enable "$1" enable 0
if [ "${enable}" -eq 0 ]; then
# bundle is disabled
return 0
fi
url="${url#file://}"
url="${url#https://}"
url="${url#http://}"
url="${url##*/}" # Get everything after the last '/'
urls="$urls $url"
}
config_load parentalcontrol
config_foreach get_download_url urlbundle
# Loop through all files in the directory
for file in "$dir"/*; do
[ -f "$file" ] || continue # Skip non-files
# Remove the suffix after the last dot
base_name="$(basename "$file")"
name="${base_name%.*}" # Removes the last dot and suffix
# Check if the name is present in the collected urls
if ! echo "$urls" | grep -q "$name"; then
rm -f "$file"
sed -i "/^${name} /d" "$bundle_sizes"
fi
done
}
# Main handler for all profile URL bundles
handle_filter_for_bundles() {
ubus -t 20 wait_for bbfdm.parentalcontrol
if [ "$?" -ne 0 ]; then
logger -p error "bbfdm.parentalcontrol object not found"
return
fi
initialize_environment
cleanup_bundle_files "$bundle_dir"
cleanup_bundle_files "$stringstore_dir"
config_load parentalcontrol
config_get_bool enable globals enable 0
if [ "${enable}" -eq 0 ]; then
# Parental control is disabled
return 0
fi
local profile enable bundles bundle_name download_url
check_bundle_exists() {
local cfg="$1"
config_get name "$cfg" name
config_get_bool enable "$cfg" enable 0
config_get download_url "$cfg" download_url
if [ "${enable}" -eq 0 ]; then
# bundle is disabled
return 0
fi
if [ "$name" = "$2" ]; then
handle_download_url "$download_url" "$name"
local exit_status=$?
if [ "$exit_status" -eq 1 ]; then
uci -q set "parentalcontrol.${cfg}.status"="Error"
else
uci -q set "parentalcontrol.${cfg}.status"=""
fi
uci commit parentalcontrol
fi
}
handle_bundle_from_profile() {
local bundle_name="$1"
config_foreach check_bundle_exists urlbundle "$bundle_name"
}
handle_profile() {
config_get_bool enable "$1" enable 0
[ "$enable" -ne 1 ] && return
config_list_foreach "$1" profile_urlbundle handle_bundle_from_profile
}
config_foreach handle_profile profile_urlfilter
}
# Open file descriptor 200 for locking
exec 200>"$LOCKFILE"
# Try to acquire an exclusive lock; exit if another instance is running
flock -n 200 || { logger -p info "sync_bundles.sh is already running, exiting."; exit 1; }
handle_filter_for_bundles

View File

@@ -0,0 +1 @@
/etc/parentalcontrol/dhcp.leases

View File

@@ -1,6 +1,48 @@
#!/bin/sh
. /lib/functions.sh
. /usr/share/libubox/jshn.sh
check_ptp_mode() {
local wanport enabled updated
if [ -f /etc/board.json ]; then
json_init
json_load_file /etc/board.json
json_select network
json_select wan 2>/dev/null
json_get_var wanport device
json_select ..
json_select ..
json_cleanup
if [ -f /etc/bbfdm/services/ponmngr.json ]; then
json_init
json_load_file /etc/bbfdm/services/ponmngr.json
json_select daemon
json_get_var enabled enable
if [ "$wanport" = "pon" ]; then
updated=1
else
updated=0
fi
# Avoid writing to flash if not necessary, since it might affect wear-leveling
if [ "$enabled" != "$updated" ]; then
json_add_string enable "$updated"
json_select ..
json_pretty
json_dump > /etc/bbfdm/services/ponmngr.json
fi
json_cleanup
fi
fi
}
apply_extra_xpon_config() {
check_ptp_mode
}
set_serial_number() {
local vendor_id="$1"
@@ -49,6 +91,8 @@ apply_xpon_uci_config() {
}
init_xpon() {
check_ptp_mode
# don't start pon daemons if xpon module is not loaded
[ -d /sys/module/xpon -o -d /sys/module/xpon_10g ] || return
@@ -65,4 +109,3 @@ init_xpon() {
deinit_xpon() {
return
}

View File

@@ -2,6 +2,10 @@
. /lib/functions.sh
apply_extra_xpon_config() {
return
}
set_serial_number() {
local vendor_id="$1"
local vssn="$2"

View File

@@ -29,6 +29,8 @@ start_service() {
configure_serial_number
apply_xpon_uci_config
init_xpon
else
apply_extra_xpon_config
fi
}

View File

@@ -26,7 +26,7 @@ define Package/port-trigger
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Port Trigger Daemon
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +kmod-ipt-trigger +kmod-ip6t-trigger +iptables-mod-nfqueue
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +iptables-mod-trigger +iptables-mod-nfqueue
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef

7
qosmngr/Config.in Normal file
View File

@@ -0,0 +1,7 @@
if PACKAGE_qosmngr
config QOSMNGR_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -6,13 +6,13 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=qosmngr
PKG_VERSION:=1.0.18
PKG_VERSION:=1.0.20
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/qosmngr.git
PKG_SOURCE_VERSION:=19c4b31eefe45bbbee2ba53f5394b5e32691451e
PKG_SOURCE_VERSION:=cc1d993b853f360c0aa19f08bfbaf1e05667527a
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -29,7 +29,7 @@ define Package/qosmngr
CATEGORY:=Utilities
TITLE:=QoS Manager
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libqos +!(TARGET_brcmbca||TARGET_airoha):tc-full
DEPENDS+=+!TARGET_brcmbca:kmod-ebt-vlantranslation +!TARGET_brcmbca:kmod-ebt-dscp2pbit +!TARGET_brcmbca:ebtables-legacy
DEPENDS+=+kmod-ebt-vlantranslation +kmod-ebt-dscp2pbit +!(TARGET_brcmbca):ebtables-legacy
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service +bridgemngr
endef
@@ -37,7 +37,17 @@ define Package/qosmngr/description
Configures L2 QoS and collects queue statistics
endef
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(CONFIG_QOSMNGR_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_QOSMNGR_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
ifeq ($(LOCAL_DEV),1)
define Build/Prepare

View File

@@ -4,7 +4,6 @@
. /usr/share/libubox/jshn.sh
cpu_model="$(cat /proc/socinfo | grep 'SoC Name' | cut -d':' -f2)"
queue_num=8
populate_no_of_queue(){
@@ -26,7 +25,9 @@ generate_queue(){
for i in $no_of_q; do
local order=$((total_q - i))
uci add qos queue
uci rename qos.@queue[-1]="q_${i}_${ifname}"
sec_name="q_${i}_${ifname}"
sec_name="$(echo $sec_name | sed -r 's/[.]+/_/g')"
uci rename qos.@queue[-1]="$sec_name"
uci set qos.@queue[-1].enable="1"
uci set qos.@queue[-1].ifname="$ifname"
uci set qos.@queue[-1].precedence="$order"

View File

@@ -1,7 +1,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=self-diagnostics
PKG_VERSION:=1.0.11
PKG_VERSION:=1.0.13
PKG_RELEASE:=1
PKG_LICENSE:=GPL-2.0-only
@@ -25,7 +25,7 @@ endef
define Package/self-diagnostics/install
$(INSTALL_DIR) $(1)/etc/self-diagnostics/spec/
$(CP) ./files/* $(1)/
$(BBFDM_INSTALL_CORE_PLUGIN) $(PKG_BUILD_DIR)/libselftest.so $(1)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/libselftest.so $(1) core
endef
$(eval $(call BuildPackage,self-diagnostics))

View File

@@ -84,11 +84,11 @@ config_load()
fi
temp="$(db -q get device.deviceinfo.ModelName)"
[ -d "${temp}" ] && \
[ -n "${temp}" ] && \
MODEL="${temp}"
temp="$(db -q get device.deviceinfo.SerialNumber)"
[ -d "${temp}" ] && \
[ -n "${temp}" ] && \
SERIAL="${temp}"
temp="$(uci -q get self-diagnostics.globals.extended_spec_dir)"

View File

@@ -5,11 +5,11 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sulu-base
PKG_VERSION:=4.0.3
PKG_VERSION:=4.0.5
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/websdk/sulu.git
PKG_SOURCE_VERSION:=ecb31135596a052bb14904a47c42d39cb81ce9d4
PKG_SOURCE_VERSION:=2e715b0f9c00105b88d2d5c8e6607081c0cffc3a
PKG_MIRROR_HASH:=skip
SULU_MOD:=core

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sulu-builder
PKG_VERSION:=4.0.3
PKG_VERSION:=4.0.8
PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/websdk/sulu-builder.git
PKG_SOURCE_VERSION:=f9c98be88d79ecf5499e46f385899e4221f036e1
PKG_SOURCE_VERSION:=8afd3a3a4623caa7ca99f28310272b4e88a5719d
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_SOURCE_VERSION)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz
PKG_BUILD_DIR:=$(BUILD_DIR)/sulu-$(PKG_VERSION)/sulu-builder-$(PKG_SOURCE_VERSION)
@@ -28,7 +28,7 @@ define Package/sulu/default
CATEGORY:=Utilities
SUBMENU:=SULU
TITLE:=SULU-CE
DEPENDS:=+mosquitto-auth-shadow +usermngr +jq
DEPENDS:=+mosquitto-auth-shadow +usermngr +jq +userinterface +obuspa
EXTRA_DEPENDS:=nginx
endef
@@ -109,13 +109,10 @@ define Package/sulu/install/Default
$(INSTALL_DATA) ./files/etc/users/roles/*.json $(1)/etc/users/roles/
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_BIN) ./files/etc/uci-defaults/99-fix-sulu-config $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/40-add-sulu-userinterface-config $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/40-add-sulu-config $(1)/etc/uci-defaults/
ifneq ($(CONFIG_SULU_DEFAULT_UI)$(CONFIG_SULU_BUILDER_DEFAULT_UI),)
$(INSTALL_BIN) ./files/etc/uci-defaults/41-make-sulu-default-ui $(1)/etc/uci-defaults/
endif
$(INSTALL_BIN) ./files/etc/uci-defaults/01-update-nginx-uci-template $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/10-add-mqtt-config $(1)/etc/uci-defaults/
endef
define Package/sulu/install/Post

View File

@@ -2,7 +2,7 @@
USE_PROCD=1
START=60
START=90
STOP=01
. /lib/functions.sh
@@ -30,18 +30,19 @@ start_service() {
return 0
fi
update_nginx_template
/etc/sulu/sulu.sh -r
if [ "${1}" = "update" ]; then
log "Reloading related services"
/etc/sulu/sulu.sh -r
fi
procd_close_instance
}
reload_service() {
stop
start
start update
}
service_triggers()
{
procd_add_reload_trigger "sulu" "userinterface"
procd_add_reload_trigger "sulu" "userinterface" "mosquitto"
}

View File

@@ -11,7 +11,7 @@ _RESTART_SERVICES="0"
mkdir -p /tmp/sulu/
function slog() {
echo "$*" | logger -t sulu.init -p debug
echo "$*" | logger -t sulu.sh -p debug
}
function _get_agent_id() {
@@ -25,19 +25,7 @@ function _get_agent_id() {
else
endpointid="$(echo "${endpointid/::/,}" | cut -d "," -f 2)"
endpointid="${endpointid//+/%2B}"
fi
}
function _get_endpoint_id() {
local oui serial endpointid
endpointid="$(uci_get obuspa localagent EndpointID)"
if [ -z "${endpointid}" ]; then
oui="$(db -q get device.deviceinfo.ManufacturerOUI)"
serial="$(db -q get device.deviceinfo.SerialNumber)"
echo "os::${oui}-${serial//+/%2B}"
else
echo "${endpointid//+/%2B}"
echo "${endpointid}"
fi
}
@@ -73,13 +61,6 @@ function _get_sulu_session_mode() {
echo "$(uci -q get sulu.global.SessionMode)"
}
function _get_usp_upstream_port() {
local port
port="$(uci -q get mosquitto.sulu.port)"
echo "${port:-9009}"
}
function _get_sulu_acl_file() {
local file
@@ -87,27 +68,6 @@ function _get_sulu_acl_file() {
echo "${file}"
}
function _get_sulu_http_port() {
local port listen
listen="$(uci -q get nginx._sulu_http.listen)"
port="$(echo $listen | grep -Eo '[0-9]+' | head -n 1)"
echo "${port:-8080}"
}
function update_nginx_template() {
local port
UCI_TEMPLATE="/etc/nginx/uci.conf.template"
port="$(_get_usp_upstream_port)"
if ! grep -q "upstream websocket { server 127.0.0.1:${port}; }" ${UCI_TEMPLATE}; then
sed -i "s/upstream websocket { server 127.0.0.1:[0-9]\+; }/upstream websocket { server 127.0.0.1:${var}; }/" ${UCI_TEMPLATE}
slog "Restarting nginx"
ubus call uci commit '{"config":"nginx"}'
fi
}
function generate_sulu_conn_config() {
local users SCONFIG session
@@ -121,7 +81,7 @@ function generate_sulu_conn_config() {
{
json_add_object 'main'
{
json_add_string 'toId' "$(_get_endpoint_id)"
json_add_string 'toId' "os::$(_get_agent_id)"
json_add_string 'port' "auto"
json_add_string 'path' "/wss"
@@ -151,24 +111,6 @@ function generate_sulu_conn_config() {
json_dump >${SCONFIG}
}
cleanup_sulu_usp_config() {
local users sec stype tmp
sec="${1}"
stype="${2}"
users="${3}"
if [[ "${sec}" == "${stype}_sulu_"* ]]; then
tmp="${sec//${stype}_sulu_/}"
val="$(echo ${users}|grep -w -o $tmp)"
if [ -z "$val" ]; then
_remove_sulu_section "${sec}"
RESTART_REQ=1
fi
fi
}
function _update_obuspa_config_rbac() {
local agent users session
@@ -176,10 +118,6 @@ function _update_obuspa_config_rbac() {
users="$(_get_sulu_user_roles)"
session="$(_get_sulu_session_mode)"
config_foreach cleanup_sulu_usp_config controller controller "${users}"
config_foreach cleanup_sulu_usp_config mtp mtp "${users}"
config_foreach cleanup_sulu_usp_config mqtt mqtt "${users}"
for user in ${users}; do
local section
@@ -223,19 +161,9 @@ function _update_obuspa_config_rbac() {
done
}
function _remove_sulu_section() {
local section="$1"
if [[ "${section}" == *"_sulu_"* ]]; then
uci_remove obuspa ${1}
return 1
fi
return 0
}
function _create_acl() {
function _create_mosquitto_acl() {
local agentid users
local ACL_FILE
local ACL_FILE acl_users
RESTART_REQ="0"
@@ -244,12 +172,17 @@ function _create_acl() {
return 0
fi
users="$(_get_sulu_user_roles)"
if [ -f "${ACL_FILE}" ]; then
rm -f "${ACL_FILE}"
acl_users="$(awk '/^user/ {print $2}' ${ACL_FILE})"
for user in ${users}; do
if ! grep -q "$user" ${acl_users}; then
rm -f "${ACL_FILE}"
fi
done
fi
touch "${ACL_FILE}"
users="$(_get_sulu_user_roles)"
agentid="$(_get_agent_id)"
for user in ${users}; do
if ! grep -q "user $user" ${ACL_FILE}; then
@@ -262,7 +195,7 @@ function _create_acl() {
fi
done
if [ "${RESTART_REQ}" -gt "0" ]; then
if [ "${_RESTART_SERVICES}" -eq "1" -a "${RESTART_REQ}" -gt "0" ]; then
slog "Restarting mosquitto..."
ubus call uci commit '{"config":"mosquitto"}'
fi
@@ -282,9 +215,9 @@ function update_obuspa_config() {
}
function configure_sulu() {
generate_sulu_conn_config
_create_acl
_create_mosquitto_acl
update_obuspa_config
generate_sulu_conn_config
}
while getopts ":r" opt; do

View File

@@ -1,12 +0,0 @@
#!/bin/sh
UCI_TEMPLATE="/etc/nginx/uci.conf.template"
update_nginx_uci_template()
{
if ! grep -q "upstream websocket" ${UCI_TEMPLATE}; then
sed -i '/#UCI_HTTP_CONFIG$/i\ map $http_upgrade $connection_upgrade { default upgrade; "" close; }' ${UCI_TEMPLATE}
sed -i '/#UCI_HTTP_CONFIG$/i\ upstream websocket { server 127.0.0.1:9009; }' ${UCI_TEMPLATE}
fi
}
update_nginx_uci_template

View File

@@ -1,37 +0,0 @@
#!/bin/sh
. /lib/functions.sh
if [ ! -f "/etc/config/mosquitto" ]; then
echo "Local mosquitto broker not available"
return 0
fi
add_sulu_config()
{
if ! uci_get mosquitto sulu >/dev/null 2>&1; then
uci_add mosquitto listener sulu
uci_set mosquitto sulu enabled 1
uci_set mosquitto sulu port '9009'
uci_set mosquitto sulu no_remote_access '1'
uci_set mosquitto sulu protocol 'websockets'
uci_set mosquitto sulu require_certificates '0'
uci_set mosquitto sulu auth_plugin '/usr/lib/mosquitto_auth_shadow.so'
uci_set mosquitto sulu acl_file '/tmp/sulu/mqtt.acl'
fi
}
add_obuspa_config()
{
if ! uci_get mosquitto obuspa >/dev/null 2>&1; then
uci_add mosquitto listener obuspa
uci_set mosquitto obuspa enabled 1
uci_set mosquitto obuspa port '1883'
uci_set mosquitto obuspa no_remote_access '1'
uci_set mosquitto obuspa allow_anonymous '1'
fi
}
uci_load mosquitto
add_obuspa_config
add_sulu_config

View File

@@ -0,0 +1,91 @@
#!/bin/sh
UCI_TEMPLATE="/etc/nginx/uci.conf.template"
if [ ! -f "/etc/config/mosquitto" ]; then
echo "Local mosquitto broker not available"
return 0
fi
if [ ! -f "${UCI_TEMPLATE}" ]; then
echo "nginx utils not installed, sulu can't run"
return 0
fi
function _get_usp_upstream_port() {
local port
port="$(uci -q get mosquitto.sulu.port)"
echo "${port:-9009}"
}
update_nginx_uci_template()
{
local port
UCI_TEMPLATE="/etc/nginx/uci.conf.template"
port="$(_get_usp_upstream_port)"
if ! grep -q "upstream websocket" ${UCI_TEMPLATE}; then
sed -i '/#UCI_HTTP_CONFIG$/i\ map $http_upgrade $connection_upgrade { default upgrade; "" close; }' ${UCI_TEMPLATE}
sed -i "/#UCI_HTTP_CONFIG$/i\ upstream websocket { server 127.0.0.1:${port}; }" ${UCI_TEMPLATE}
fi
}
add_sulu_config_to_mosquitto()
{
if ! uci_get mosquitto sulu >/dev/null 2>&1; then
uci_add mosquitto listener sulu
uci_set mosquitto sulu enabled 1
uci_set mosquitto sulu port '9009'
uci_set mosquitto sulu no_remote_access '1'
uci_set mosquitto sulu protocol 'websockets'
uci_set mosquitto sulu require_certificates '0'
uci_set mosquitto sulu auth_plugin '/usr/lib/mosquitto_auth_shadow.so'
uci_set mosquitto sulu acl_file '/etc/sulu/mqtt.acl'
fi
}
add_obuspa_config_to_mosquitto()
{
uci_load mosquitto
if ! uci_get mosquitto obuspa >/dev/null 2>&1; then
uci_add mosquitto listener obuspa
uci_set mosquitto obuspa enabled 1
uci_set mosquitto obuspa port '1883'
uci_set mosquitto obuspa no_remote_access '1'
uci_set mosquitto obuspa allow_anonymous '1'
fi
}
add_sulu_userinterface_uci()
{
uci_load userinterface
if ! uci_get userinterface _sulu_s >/dev/null 2>&1; then
uci_add userinterface http_access _sulu_s
uci_set userinterface _sulu_s path_prefix '/sulu'
uci_set userinterface _sulu_s port '8443'
uci_add_list userinterface _sulu_s _nginx_include '/etc/sulu/nginx.locations'
uci_set userinterface _sulu_s _nginx_uci_manage_ssl 'self-signed'
uci_set userinterface _sulu_s _nginx_ssl_certificate '/etc/nginx/conf.d/_lan.crt'
uci_set userinterface _sulu_s _nginx_ssl_certificate_key '/etc/nginx/conf.d/_lan.key'
uci_set userinterface _sulu_s _nginx_ssl_session_cache 'none'
uci_set userinterface _sulu_s protocol 'HTTPS'
uci_add_list userinterface _sulu_s role 'admin'
uci_add_list userinterface _sulu_s role 'user'
fi
if ! uci_get userinterface _suluredirect >/dev/null 2>&1; then
uci_add userinterface http_access _suluredirect
uci_set userinterface _suluredirect redirect '_sulu_s'
uci_set userinterface _suluredirect protocol 'HTTP'
uci_set userinterface _suluredirect port "8080"
fi
}
add_obuspa_config_to_mosquitto
add_sulu_config_to_mosquitto
update_nginx_uci_template
add_sulu_userinterface_uci
/etc/sulu/sulu.sh

View File

@@ -1,32 +0,0 @@
#!/bin/sh
. /lib/functions.sh
add_sulu_userinterface_uci()
{
uci_load userinterface
if ! uci_get userinterface _sulu_s >/dev/null 2>&1; then
uci_add userinterface http_access _sulu_s
uci_set userinterface _sulu_s path_prefix '/sulu'
uci_set userinterface _sulu_s port '8443'
uci_add_list userinterface _sulu_s _nginx_include '/etc/sulu/nginx.locations'
uci_set userinterface _sulu_s _nginx_uci_manage_ssl 'self-signed'
uci_set userinterface _sulu_s _nginx_ssl_certificate '/etc/nginx/conf.d/_lan.crt'
uci_set userinterface _sulu_s _nginx_ssl_certificate_key '/etc/nginx/conf.d/_lan.key'
uci_set userinterface _sulu_s _nginx_ssl_session_cache 'none'
uci_set userinterface _sulu_s protocol 'HTTPS'
uci_add_list userinterface _sulu_s role 'admin'
uci_add_list userinterface _sulu_s role 'user'
fi
if ! uci_get userinterface _suluredirect >/dev/null 2>&1; then
uci_add userinterface http_access _suluredirect
uci_set userinterface _suluredirect redirect '_sulu_s'
uci_set userinterface _suluredirect protocol 'HTTP'
uci_set userinterface _suluredirect port "8080"
fi
}
add_sulu_userinterface_uci

View File

@@ -8,7 +8,7 @@ if uci_get nginx _sulu_s >/dev/null 2>&1; then
exit 0
fi
move_default_nginx_listener_to_8443() {
update_default_nginx_listner() {
if [ ! -f /etc/config/nginx ]; then
return
@@ -18,18 +18,24 @@ move_default_nginx_listener_to_8443() {
return
fi
uci_remove nginx _lan listen
uci_add_list nginx _lan listen "8443 ssl default_server"
uci_add_list nginx _lan listen "[::]:8443 ssl default_server"
if ! opkg list-installed |grep -q "luci "; then
echo "Luci not installed, removing luci config"
uci_remove nginx _lan
uci_remove nginx _redirect2ssl
else
uci_remove nginx _lan listen
uci_add_list nginx _lan listen "8443 ssl default_server"
uci_add_list nginx _lan listen "[::]:8443 ssl default_server"
if ! uci_get nginx _redirect2ssl >/dev/null 2>&1; then
return
if ! uci_get nginx _redirect2ssl >/dev/null 2>&1; then
return
fi
uci_remove nginx _redirect2ssl listen
uci_add_list nginx _redirect2ssl listen "8080"
uci_add_list nginx _redirect2ssl listen "[::]:8080"
uci_set nginx _redirect2ssl return '302 https://$host:8443$request_uri'
fi
uci_remove nginx _redirect2ssl listen
uci_add_list nginx _redirect2ssl listen "8080"
uci_add_list nginx _redirect2ssl listen "[::]:8080"
uci_set nginx _redirect2ssl return '302 https://$host:8443$request_uri'
}
move_sulu_to_443_and_80() {
@@ -50,5 +56,5 @@ move_sulu_to_443_and_80() {
config_foreach set_port http_access
}
move_default_nginx_listener_to_8443
update_default_nginx_listner
move_sulu_to_443_and_80

View File

@@ -1,14 +0,0 @@
#!/bin/sh
. /lib/functions.sh
set_sulu_pwa_key()
{
if [ -f "/etc/sulu/pwa.crt" -a -f "/etc/sulu/pwa.key" ]; then
uci_load nginx
uci_set nginx _sulu_s ssl_certificate '/etc/sulu/pwa.crt'
uci_set nginx _sulu_s ssl_certificate_key '/etc/sulu/pwa.key'
fi
}
set_sulu_pwa_key

View File

@@ -1,3 +0,0 @@
#!/bin/sh
/etc/sulu/sulu.sh

View File

@@ -63,7 +63,7 @@
]
},
{
"object":"Device.Time.",
"object": "Device.Time.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -78,7 +78,7 @@
]
},
{
"object":"Device.UPnP.",
"object": "Device.UPnP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -93,7 +93,7 @@
]
},
{
"object":"Device.Bridging.",
"object": "Device.Bridging.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -108,7 +108,7 @@
]
},
{
"object":"Device.Ethernet.",
"object": "Device.Ethernet.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -123,7 +123,7 @@
]
},
{
"object":"Device.DHCPv4.",
"object": "Device.DHCPv4.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -138,7 +138,7 @@
]
},
{
"object":"Device.DHCPv4.Server.Pool.{i}.StaticAddress.",
"object": "Device.DHCPv4.Server.Pool.{i}.StaticAddress.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -155,7 +155,7 @@
]
},
{
"object":"Device.DHCPv6.",
"object": "Device.DHCPv6.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -170,7 +170,7 @@
]
},
{
"object":"Device.Hosts.",
"object": "Device.Hosts.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -187,7 +187,7 @@
]
},
{
"object":"Device.{BBF_VENDOR_PREFIX}URLFilter.",
"object": "Device.{BBF_VENDOR_PREFIX}ParentalControl.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -204,7 +204,7 @@
]
},
{
"object":"Device.{BBF_VENDOR_PREFIX}OpenVPN.",
"object": "Device.{BBF_VENDOR_PREFIX}OpenVPN.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -221,7 +221,7 @@
]
},
{
"object":"Device.NAT.",
"object": "Device.NAT.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -238,7 +238,7 @@
]
},
{
"object":"Device.PPP.",
"object": "Device.PPP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -253,7 +253,7 @@
]
},
{
"object":"Device.Routing.",
"object": "Device.Routing.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -268,7 +268,7 @@
]
},
{
"object":"Device.IEEE1905.",
"object": "Device.IEEE1905.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -283,7 +283,7 @@
]
},
{
"object":"Device.InterfaceStack.",
"object": "Device.InterfaceStack.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -298,7 +298,7 @@
]
},
{
"object":"Device.DynamicDNS.",
"object": "Device.DynamicDNS.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -315,7 +315,7 @@
]
},
{
"object":"Device.LANConfigSecurity.",
"object": "Device.LANConfigSecurity.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -330,7 +330,7 @@
]
},
{
"object":"Device.Security.",
"object": "Device.Security.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -345,7 +345,7 @@
]
},
{
"object":"Device.RouterAdvertisement.",
"object": "Device.RouterAdvertisement.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -360,7 +360,7 @@
]
},
{
"object":"Device.Services.",
"object": "Device.Services.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -377,7 +377,7 @@
]
},
{
"object":"Device.UserInterface.",
"object": "Device.UserInterface.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -392,7 +392,7 @@
]
},
{
"object":"Device.PeriodicStatistics.",
"object": "Device.PeriodicStatistics.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -409,7 +409,7 @@
]
},
{
"object":"Device.SoftwareModules.",
"object": "Device.SoftwareModules.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -426,7 +426,7 @@
]
},
{
"object":"Device.Users.",
"object": "Device.Users.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -517,7 +517,7 @@
]
},
{
"object":"Device.SSH.",
"object": "Device.SSH.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
@@ -532,6 +532,10 @@
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LEDs.LED.{i}.X_GENEXIS_EU_Brightness",
"perm": ["PERMIT_GET", "PERMIT_SET", "PERMIT_GET_INST"]
}
]
}

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=swmodd
PKG_VERSION:=2.5.20
PKG_VERSION:=2.5.21
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/lcm/swmodd.git
PKG_SOURCE_VERSION:=efc41f62740e425751b71beabf940324a37cc08d
PKG_SOURCE_VERSION:=560d1e39a57d93ec6e0bee5c67785be414649393
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sysmngr
PKG_VERSION:=1.0.16
PKG_VERSION:=1.0.17
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/system/sysmngr.git
PKG_SOURCE_VERSION:=7d5bf8e0751d3e2ec848b4da6e4a6c8366caf05c
PKG_SOURCE_VERSION:=28f575dd0e09b35eb9a9241c69b1898b88c4a282
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -22,7 +22,7 @@ fwbank_get_bootbank() {
case "$1" in
list)
echo '{ "dump" : {}, "set_bootbank" : {"bank":32} , "upgrade": {"path":"String","auto_activate":true,"bank":32,"keep_settings":true}}'
echo '{ "dump" : {}, "set_bootbank" : {"bank":32}, "copy_config" : {}, "upgrade": {"path":"String","auto_activate":true,"bank":32,"keep_settings":true}}'
;;
call)
case "$2" in
@@ -124,6 +124,29 @@ case "$1" in
echo '{"success": false}'
fi
;;
copy_config)
if [ -z "$UPGRADE_BACKUP" ]; then
UPGRADE_BACKUP=/tmp/sysupgrade.tgz
fi
ret=0
sysupgrade -b "$UPGRADE_BACKUP" || ret=1
if [ "$ret" -eq 0 ]; then
if command -v platform_copy_config >/dev/null 2>&1; then
platform_copy_config 1>&2 || ret=1
else
ret=1
fi
fi
if [ "$ret" -eq 0 ]; then
echo '{"success": true}'
else
echo '{"success": false}'
fi
;;
upgrade)
# Read the JSON object provided for the arguments
read -r input

View File

@@ -32,4 +32,8 @@ config TIMEMNGR_VENDOR_EXTENSIONS
bool "Iopsys vendor extensions for Device.Time."
depends on PACKAGE_timemngr
default y
config TIMEMNGR_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -5,7 +5,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=timemngr
PKG_VERSION:=1.1.5
PKG_VERSION:=1.1.6
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
@@ -50,7 +50,13 @@ define Build/Prepare
endef
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_TIMEMNGR_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_TIMEMNGR_VENDOR_PREFIX)
endif
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(VENDOR_PREFIX)\\\"
define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/etc/timemngr/

View File

@@ -1,3 +1,5 @@
if PACKAGE_tr104
config TR104_RUNAS_BBFDM_MICROSERVICE
bool "Use bbfdmd datamodel microservice to run tr104, preferred if TR104 and BBFDMD are on different base"
depends on PACKAGE_tr104
@@ -7,3 +9,8 @@ config TR104_VENDOR_EXTENSIONS
bool "Use TR104 vendor extensions"
depends on PACKAGE_tr104
default y
config TR104_VENDOR_PREFIX
string "Package specific datamodel Vendor Prefix for TR181 extensions"
default ""
endif

View File

@@ -5,7 +5,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=tr104
PKG_VERSION:=1.0.36
PKG_VERSION:=1.0.37
LOCAL_DEV:=0
ifeq ($(LOCAL_DEV),0)
@@ -43,8 +43,14 @@ define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(CONFIG_TR104_VENDOR_PREFIX),"")
VENDOR_PREFIX = $(CONFIG_BBF_VENDOR_PREFIX)
else
VENDOR_PREFIX = $(CONFIG_TR104_VENDOR_PREFIX)
endif
CMAKE_OPTIONS += \
-DBBF_VENDOR_PREFIX:String="$(CONFIG_BBF_VENDOR_PREFIX)" \
-DBBF_VENDOR_PREFIX:String="$(VENDOR_PREFIX)" \
-DDAEMON_JSON_INPUT:String="/etc/tr104/input.json" \
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
-DDM_ENABLE_UBUS:BOOL=ON

View File

@@ -5,7 +5,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=usermngr
PKG_VERSION:=1.3.2
PKG_VERSION:=1.3.3
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
@@ -30,6 +30,7 @@ define Package/usermngr
SUBMENU:=TRx69
DEPENDS:= +shadow-utils +libopenssl +libuci +libubox +ubus
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +bbfdmd
DEPENDS+=+@BUSYBOX_CONFIG_ADDUSER +@BUSYBOX_CONFIG_DELUSER +@BUSYBOX_CONFIG_ADDGROUP +@BUSYBOX_CONFIG_DELGROUP +shadow-usermod
TITLE:=Package to add Device.Users. datamodel support
endef

View File

@@ -6,11 +6,11 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=usp-js
PKG_VERSION:=1.2.6
PKG_VERSION:=1.2.7
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/websdk/usp-js.git
PKG_SOURCE_VERSION:=fa4586a0fc5fe13bc83165c8401e63d84db89e72
PKG_SOURCE_VERSION:=a4be8f6d8442d56c632514abb16f3de0817fb22f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip

View File

@@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=voicemngr
PKG_RELEASE:=1
PKG_VERSION:=1.2.3
PKG_VERSION:=1.2.4
PKG_LICENSE:=MIT
PKG_LICENSE_FILES:=LICENSE
@@ -19,7 +19,7 @@ LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/$(PKG_NAME).git
PKG_SOURCE_VERSION:=105ccc7534671d639d225efc48b43028f617f0f1
PKG_SOURCE_VERSION:=7be53608b4cacb5107652bb2c0c09e5e3fd0c20e
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=wifidmd
PKG_VERSION:=1.0.24
PKG_VERSION:=1.0.32
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/wifidmd.git
PKG_SOURCE_VERSION:=f6b6a2d68ec5523b8d2b118d7931fb9e590cba03
PKG_SOURCE_VERSION:=a45e93de6bef236c5f657e92bc8b76f565893957
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -27,7 +27,6 @@ define Package/wifidmd
TITLE:=WiFi Data Model Support
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
DEPENDS+=+rpcd-mod-iwinfo
endef
define Package/wifidmd/config
@@ -46,20 +45,18 @@ define Build/Prepare
endef
endif
ifeq ($(CONFIG_WIFIDMD_WIFI_DATAELEMENTS),y)
MAKE_FLAGS += WIFIDMD_WIFI_DATAELEMENTS=y
endif
define Package/wifidmd/install
$(INSTALL_DIR) $(1)/etc/bbfdm/services
$(INSTALL_DIR) $(1)/usr/share/bbfdm/micro_services
ifneq ($(CONFIG_WIFIDMD_DISABLE_LEGACY_WIFI),y)
$(BBFDM_REGISTER_SERVICES) ./files/bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libwifi.so $(1) $(PKG_NAME)
endif
ifeq ($(CONFIG_WIFIDMD_WIFI_DATAELEMENTS),y)
$(BBFDM_REGISTER_SERVICES) ./files/bbfdm_service_dataelements.json $(1) $(PKG_NAME).dataelements
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libdataelements.so $(1) $(PKG_NAME).dataelements
endif
endef

View File

@@ -1,16 +0,0 @@
{
"daemon": {
"enable": "1",
"service_name": "wifidmd.dataelements",
"unified_daemon": false,
"services": [
{
"parent_dm": "Device.",
"object": "WiFi"
}
],
"config": {
"loglevel": "3"
}
}
}

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=wifimngr
PKG_VERSION:=17.5.0
PKG_VERSION:=17.5.4
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=479368d84dca6d98cf0da3707c5f4f35b2168dcb
PKG_SOURCE_VERSION:=e9098aa1192695ad2e80f7e70367977af2a52022
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/wifimngr.git
PKG_MAINTAINER:=Anjan Chanda <anjan.chanda@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz