Compare commits

..

204 Commits
voip ... dmexec

Author SHA1 Message Date
Vivek Kumar Dutta
fd8ed20c33 Draft: datamodel for shell exec 2025-09-14 18:57:04 +05:30
Suvendhu Hansa
5232cc61ac bbfdm: handle externally changed uci 2025-09-14 12:47:21 +05:30
Anjan Chanda
98d8e9866c map-plugins: 1.0.31 2025-09-12 17:02:49 +02:00
Vivek Kumar Dutta
0e59fd0d47 parental-control: 1.3.2 2025-09-11 15:03:46 +05:30
Anjan Chanda
a7e8e65d88 map-controller: 6.4.2.6 2025-09-11 10:45:06 +02:00
Suvendhu Hansa
1fd74364fa wifidmd: add external apply handler 2025-09-11 14:10:32 +05:30
Suvendhu Hansa
20c49302c1 bbfdm: add default apply handler 2025-09-11 13:59:47 +05:30
Anjan Chanda
c2e5ade3bb ieee1905: 8.7.37 2025-09-10 17:08:14 +02:00
Anjan Chanda
b933622547 map-plugins: 1.0.24 2025-09-10 17:06:16 +02:00
Reidar Cederqvist
7b12c29425 sulu: update to version 5.1.1 for IOWRT-7.6.0ALPHA2 2025-09-10 16:01:27 +02:00
Vivek Kumar Dutta
082452bfb5 mosquitto-auth-shadow: support libpam based authentication 2025-09-10 15:32:24 +05:30
Mohd Husaam Mehdi
a6b8987dac parental-control: only flush relevant connections using conntrack 2025-09-10 12:14:27 +05:30
Vivek Kumar Dutta
d1307bfd76 obuspa: Fix setting multiple params 2025-09-09 18:34:08 +05:30
Andreas Gnau
edd78f675e peripheral_manager: Remove
Remove peripheral_manager, it is no longer used or maintainted.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2025-09-09 13:23:06 +02:00
Janusz Dziedzic
3a1772e1b8 ieee1905: 8.7.36 2025-09-09 09:36:29 +00:00
Jakob Olsson
b2dd40cae3 map-controller: 6.4.2.2 2025-09-08 16:27:29 +02:00
Jakob Olsson
24f22d0ecc map-agent: 6.4.1.11 2025-09-08 13:59:36 +02:00
Jakob Olsson
a86f478014 map-controller: 6.4.2.1 2025-09-08 11:18:12 +02:00
Vivek Kumar Dutta
9a59ccc498 swmodd: Replace jq with jsonfilter 2025-09-06 15:14:24 +05:30
Vivek Kumar Dutta
15e4dd732a obuspa: 10.0.7.3 2025-09-06 09:57:18 +05:30
Husaam Mehdi
784a281fa6 logmngr: 1.1.4 2025-09-05 19:24:00 +05:30
Vivek Kumar Dutta
8f82b31658 obuspa: align with bbfdm 2025-09-05 19:10:41 +05:30
Vivek Kumar Dutta
3745b4e913 icwmp: align with bbfdm 2025-09-05 19:10:41 +05:30
Suvendhu Hansa
90d646319b bbfdm: update critical service config & dmmap path 2025-09-05 19:10:41 +05:30
Vivek Kumar Dutta
13064e27b3 bbfdm: Only commit changes done by datamodel 2025-09-05 19:10:41 +05:30
Vivek Kumar Dutta
539bf50985 ieee1905: 8.7.35 2025-09-05 18:42:16 +05:30
Anjan Chanda
1b7b377bd1 map-plugins: 1.0.18 - fix build when multiple plugins selected 2025-09-05 11:41:40 +02:00
Anjan Chanda
1c9ba1c83c map-plugins: 1.0.18 (bsteer) 2025-09-05 10:07:00 +02:00
Anjan Chanda
e307ee7aa8 map-controller: 6.4.2.0 2025-09-05 08:58:23 +02:00
Jakob Olsson
6bcf7987d7 map-agent: 6.4.1.10 2025-09-04 16:08:10 +02:00
Vivek Kumar Dutta
ff146bf093 tr104: 1.0.39 2025-09-04 18:32:44 +05:30
Vivek Kumar Dutta
0f23bee1da userinterface: Support for ISP info parameters 2025-09-04 18:06:03 +05:30
Amin Ben Romdhane
2070630b07 wifidmd: 1.3.9 2025-09-04 12:51:48 +02:00
Amin Ben Romdhane
f1702b3e70 map-controller: 6.4.1.3 2025-09-04 12:50:47 +02:00
Amin Ben Romdhane
9634b0678b wifidmd: 1.3.8 2025-09-03 17:21:18 +02:00
Amin Ben Romdhane
d395030be7 decollector: 6.2.1.12 2025-09-03 17:20:15 +02:00
Amin Ben Romdhane
4cb0504eb3 map-agent: 6.4.1.9 2025-09-03 17:19:11 +02:00
Mohd Husaam Mehdi
6df57301f9 logmngr: fix severity and facility configuration issues 2025-09-03 18:44:21 +05:30
Vivek Kumar Dutta
f527b8a25a obuspa: fallback to get connection params from db 2025-09-03 18:08:52 +05:30
Jakob Olsson
fbba67542e map-agent: 6.4.1.8 2025-09-02 17:27:43 +02:00
Amin Ben Romdhane
824d6d3abe decollector: 6.2.1.11 2025-09-02 16:30:45 +02:00
Jakob Olsson
1a9a339cc6 map-controller: 6.4.1.2 2025-09-02 13:04:54 +02:00
Vivek Kumar Dutta
0533f114d1 bbfdm: 1.17.7 2025-09-02 14:15:18 +05:30
Andreas Gnau
dc579e3c60 xmppc: Remove the dependency on jq
jq is used inside xmppc init script but it is not declared as a
dependency. Remove this usage of jq.

jq is a complex piece of software that requires security maintenance and
adds bloat to the image. Using existing tools like jshn and jsonfilter
is preferred where the additional functionality provided by jq is not
required.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2025-09-02 10:07:45 +02:00
Andreas Gnau
d232e76905 packet-capture-diagnostics: Don't use jq
jq is used inside packetcapture but it is not declared as a dependency.
Remove this usage of jq.

jq is a complex piece of software that requires security maintenance and
adds bloat to the image. Using existing tools like jshn and jsonfilter
is preferred where the additional functionality provided by jq is not
required.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2025-09-02 10:06:16 +02:00
Filip Matusiak
2fffb45748 map-controller: 6.4.1.1 2025-09-02 10:00:24 +02:00
Filip Matusiak
b15f1b5026 map-agent: 6.4.1.7 2025-09-02 09:59:48 +02:00
Amin Ben Romdhane
43a0dfc863 wifidmd: 1.3.7 2025-08-29 10:11:28 +02:00
Jakob Olsson
307381c9af decollector: 6.2.1.10 2025-08-28 18:10:13 +02:00
Vivek Kumar Dutta
1a80f2df47 parental-control: improve dns packet inspection 2025-08-28 12:05:15 +05:30
Mohd Husaam Mehdi
9b79eb42db parental-control: improve packet capture rules for DNS 2025-08-28 11:53:12 +05:30
Mohd Husaam Mehdi
602926b076 parental-control: flush hw_nat along with conntrack 2025-08-28 11:22:11 +05:30
Vivek Kumar Dutta
74cfe57095 sulu: remove jq dependency 2025-08-28 10:56:55 +05:30
Jakob Olsson
01845eded6 map-controller: 6.4.1.0 2025-08-27 16:39:08 +02:00
arbala
11dce5812c map-agent: 6.4.1.6 2025-08-27 15:17:58 +02:00
Vivek Kumar Dutta
7af15ec9a9 sshmngr: 1.1.1 2025-08-27 16:24:12 +05:30
Vivek Kumar Dutta
8359755dc8 bbfdm: 1.17.6 2025-08-27 16:05:18 +05:30
Amin Ben Romdhane
1a735b7730 wifidmd: 1.3.6 2025-08-26 16:26:29 +02:00
Vivek Kumar Dutta
6a008d3419 bbfdm: 1.17.5 2025-08-26 18:52:24 +05:30
Vivek Kumar Dutta
6142da5d43 sshmngr: align with bbfdm dmmap schema 2025-08-26 11:56:31 +05:30
Mohd Husaam Mehdi
f5715d478a fluent-bit: fix kmsg plugin issues
* improved type conversion
* improved error checking while string parsing
* misc improvements
2025-08-26 11:30:20 +05:30
Amin Ben Romdhane
bce9364d14 wifidmd: 1.3.5 2025-08-25 17:38:14 +02:00
Amin Ben Romdhane
425949900b decollector: 6.2.1.9 2025-08-25 17:37:22 +02:00
Amin Ben Romdhane
938681c270 map-controller: 6.4.0.18 2025-08-25 17:36:05 +02:00
Jakob Olsson
30f7a15450 map-agent: 6.4.1.5 2025-08-25 16:08:24 +02:00
Jakob Olsson
4d4006309b map-agent: 6.4.1.4 2025-08-25 15:43:18 +02:00
Vivek Kumar Dutta
41f1e0d52a bbfdm: 1.17.4 2025-08-23 17:41:26 +05:30
Vivek Kumar Dutta
db207a87fc obuspa: Integrate v10.0.7 2025-08-23 10:08:37 +05:30
Jakob Olsson
89ab349565 map-agent: 6.4.1.3 2025-08-22 16:30:08 +02:00
Filip Matusiak
8ffe108f95 map-controller: 6.4.0.17
Set debug level to 2 (INFO) by default.
2025-08-22 16:20:24 +02:00
Erik Karlsson
074d9268b0 sulu: depend on local MQTT listener regardlessly of variant 2025-08-22 16:09:49 +05:30
Vivek Kumar Dutta
fc7b21aa73 bbfdm: Fix fault message for 9007 2025-08-22 15:15:37 +05:30
Husaam Mehdi
6f83732b0e logmngr: use multiple workers for logging 2025-08-22 12:08:27 +05:30
Erik Karlsson
97141307ed sulu: remove faulty mosquitto option
The actual spelling of this option is require_certificate and it is
anyway not relevant here since it is not a TLS listener.
2025-08-21 15:19:46 +02:00
Vivek Dutta
ddec5540bc sulu: Fix restarting of mqtt broker 2025-08-21 18:39:36 +05:30
Filip Matusiak
09b97ae69d self-diagnostics: get status of MLD stations 2025-08-21 11:18:18 +00:00
Jakob Olsson
977c1b5767 map-agent: 6.4.1.2 2025-08-21 12:31:22 +02:00
Anjan Chanda
467b3897fb Revert "libwifi: 7.13.0"
This reverts commit 9917da1ca3.
2025-08-21 09:50:01 +02:00
Filip Matusiak
a688381a3c self-diagnostics: update wifi data collection 2025-08-20 15:12:51 +00:00
Vivek Kumar Dutta
9bad79439b usermngr: 1.4.0 2025-08-20 20:29:50 +05:30
Vivek Dutta
608b9637b0 parental-control: fix cleanup when bundle is default enabled
(cherry picked from commit 8bdc47344a)

Co-authored-by: Mohd Husaam Mehdi <husaam.mehdi@iopsys.eu>
2025-08-20 20:28:06 +05:30
Vivek Dutta
fcd59e95f0 parental-control: auto enable urlbundle based on /apps 2025-08-20 20:27:48 +05:30
Vivek Kumar Dutta
5820d98e2c iopsys-analytics: enable dmcli remote connection 2025-08-20 20:09:17 +05:30
Erik Karlsson
9c6b9d6260 logmngr: use fluent-bit filters to adapt kmsg fields and add hostname 2025-08-20 13:25:27 +00:00
Erik Karlsson
9fad74246e fluent-bit: human readable time in file output 2025-08-20 13:25:27 +00:00
Erik Karlsson
aab3f74290 fluent-bit: remove patches for hostname and kmsg field adaptation
Filters will be used instead.
2025-08-20 13:25:27 +00:00
Jakob Olsson
0eb2ce3728 map-agent: 6.4.1.1 2025-08-20 15:19:51 +02:00
Anjan Chanda
f9aabb68d5 wifimngr: 20.0.0 2025-08-20 10:56:02 +02:00
Anjan Chanda
9917da1ca3 libwifi: 7.13.0 2025-08-20 10:38:39 +02:00
Anjan Chanda
acf7344c13 libeasy: 7.5.0 2025-08-20 10:10:16 +02:00
Filip Matusiak
693ff8bd19 map-controller: 6.4.0.16
Reduce stale sta timeout to 20 days, to avoid exceeding
max value of parameter to uloop_timeout_set.
2025-08-20 07:25:12 +00:00
Jakob Olsson
c1286064bb map-agent: 6.4.1.0 2025-08-19 15:17:14 +02:00
Erik Karlsson
2503b1fc72 logmngr: miscellaneous fixes
Always migrate configuration. Do not set executable bit on config
files and uci-defaults scripts. Remove unused /lib/functions.sh
include. Remove redundant "default y" on choice.
2025-08-19 11:07:11 +00:00
Vivek Kumar Dutta
d468c13b3f usp-js: 1.2.9 2025-08-19 13:42:18 +05:30
Vivek Kumar Dutta
064611a15d obuspa: removed test controller definition 2025-08-19 13:42:18 +05:30
Filip Matusiak
5c427dd08a map-controller: config: change default sta timeout to 20d 2025-08-18 15:14:07 +00:00
Amin Ben Romdhane
1703e6d328 wifidmd: 1.3.4 2025-08-18 17:10:59 +02:00
Amin Ben Romdhane
35c27393ce map-controller: 6.4.0.15 2025-08-18 17:09:31 +02:00
Amin Ben Romdhane
fca93627ba bbfdm: 1.17.2 2025-08-18 10:36:21 +02:00
Erik Karlsson
417a127dd9 quickjs: clean up integration
Pass CFLAGS and LDFLAGS the correct way via environment variables and
not as arguments so the upstream Makefile CFLAGS/LDFLAGS do not get
overwritten and no ugly workaround is needed. Set PREFIX correctly and
do not set CONFIG_SMALL which was implemented in a patch that was
dropped. Remove commented out code (libquickjs.lto.a is no longer
built by default). Set PKG_SOURCE_DATE correctly as the date of the
upstream git repo and not the date of the OpenWrt package. Fix
whitespace issues in patch. Do not create empty /usr/lib/quickjs
2025-08-17 13:28:55 +05:30
arbala
afde0b98ad map-agent: 6.4.0.3 2025-08-15 16:45:12 +02:00
Markus Gothe
a0069cc9be qos: airoha: Fix mapping of accounter. 2025-08-14 21:20:07 +02:00
Markus Gothe
368255f50b qos: airoha: Use Meter 0 for IF-based QoS. 2025-08-14 18:34:40 +02:00
Janusz Dziedzic
ad1233ff32 wifimngr: 17.7.8 2025-08-14 14:47:23 +00:00
Janusz Dziedzic
697ddc356e libwifi: 7.14.0 2025-08-14 14:25:45 +00:00
Janusz Dziedzic
b82eb8325e libwifi: 7.13.9 2025-08-14 11:56:01 +00:00
Suvendhu Hansa
c150053a83 usermngr: modify password policy 2025-08-14 16:40:17 +05:30
Vivek Kumar Dutta
7ee83ff47f usp-js: 1.2.8 2025-08-14 16:27:42 +05:30
Vivek Kumar Dutta
98905256f8 periodicstats: Align with new dmmap 2025-08-14 12:42:51 +05:30
Amin Ben Romdhane
a8a511c4ff wifidmd: 1.3.3 2025-08-12 13:35:04 +02:00
Amin Ben Romdhane
d0d90946b3 map-agent: 6.4.0.2 2025-08-12 13:34:04 +02:00
Vivek Dutta
c2ad0fa44d swmodd: disable lxc support in defaults 2025-08-12 15:20:10 +05:30
Vivek Kumar Dutta
be7fa433c5 obuspa: Fix fault msg in failed set cmd 2025-08-12 15:07:35 +05:30
Mohd Husaam Mehdi
01e9d7c0bc usermngr: add UCI support for passwdqc parameters 2025-08-12 12:17:21 +05:30
Suvendhu Hansa
2f398a2671 icwmp: generate a random cpe port if not defined 2025-08-12 10:11:52 +05:30
Markus Gothe
8254547866 udhcpc_obuspa_opt125.user: Fix typo 2025-08-11 23:25:08 +02:00
Janusz Dziedzic
e8ceb167b5 ieee1905: 8.7.34 2025-08-11 11:38:51 +00:00
Amin Ben Romdhane
434c794671 decollector: 6.2.1.8 2025-08-11 12:19:37 +02:00
George Yang
9628be4812 dectmngr-3.7.11 2025-08-08 17:09:57 +02:00
Markus Gothe
bd90dc7ec2 libdsl: 7.3.2 2025-08-11 09:05:22 +02:00
Janusz Dziedzic
e0736df927 wifimngr: 17.7.7 2025-08-11 05:24:03 +00:00
Amin Ben Romdhane
afa58be1f8 wifidmd: 1.3.2 2025-08-09 22:03:24 +02:00
Vivek Kumar Dutta
3cbcac96ba netmode: Fix dm-service depedency 2025-08-08 16:55:35 +05:30
Suvendhu Hansa
a92f32eba4 icwmp: Fix overriding of port definition 2025-08-08 12:52:57 +05:30
Amin Ben Romdhane
842968da4f wifidmd: 1.3.1 2025-08-07 15:21:16 +02:00
Jakob Olsson
60ef90c1b6 map-agent: 6.4.0.1 2025-08-07 15:17:22 +02:00
Suvendhu Hansa
56cec9cb7f icwmpd: retry on bind failure 2025-08-07 18:06:53 +05:30
Vivek Kumar Dutta
4042d46009 tr104: Fix CallControlGroup Extension references 2025-08-07 17:48:46 +05:30
Markus Gothe
d6dfc5bd08 libdsl: Fix issue with G.vectoring. 2025-08-07 14:15:25 +02:00
Vivek Kumar Dutta
451036aebc obuspa: Integrated v10.0.6 2025-08-07 17:33:16 +05:30
Amin Ben Romdhane
8d01ace7a6 wifidmd: 1.3.0 2025-08-07 12:37:44 +02:00
Jakob Olsson
d7e22b922b map-agent: map-dynamic-backhaul: pass macaddr when setting uplink 2025-08-07 10:40:26 +02:00
Elena Vengerova
a1d535058d libwifi: 7.13.8 2025-08-06 22:37:57 +04:00
Markus Gothe
1bb307ef4f xdsl_wan: ros -> roc. 2025-08-06 19:50:31 +02:00
Markus Gothe
404a642e41 xdsl_wan: Enable vectoring and G.iNP by default. 2025-08-06 19:33:52 +02:00
Elena Vengerova
ae3f1819e6 libwifi: invent target for Mediatek, change path for vendor header search
Mediatek passes rather -I$(LINUX_DIR)/include/uapi/linux/mtk_nl80211_inc
than installs header with vendor attributes into the toolchain.
2025-08-06 21:00:38 +04:00
Elena Vengerova
fbd8f64c40 mapagent: invent branch for logan driver handling
Logan driver assumes that ra/rai interface names are used.
It's the same for all platforms.
2025-08-06 16:32:33 +00:00
Jakob Olsson
369fc0d4bb map-agent: 6.4.0.0: dynbh rework 2025-08-06 16:29:57 +00:00
Jakob Olsson
b44afe067f map-agent: remove dynbhd 2025-08-06 16:29:57 +00:00
Suvendhu Hansa
d69245f570 map-agent: map_genconfig: use ubus uci to commit mapcontroller changes 2025-08-06 14:53:54 +00:00
Suvendhu Hansa
c3564ff528 wifidmd: Reload wifidmd by signal 2025-08-06 20:19:54 +05:30
Vivek Kumar Dutta
fafe1d9447 icwmp: 9.9.10 2025-08-06 18:41:01 +05:30
Husaam Mehdi
e35bf1d509 logmngr: add support for Syslog Source and Template 2025-08-05 17:06:51 +05:30
Amin Ben Romdhane
8e11e5dbc8 twamp: 1.5.0 2025-08-04 17:09:23 +02:00
Amin Ben Romdhane
2698ee9358 netmngr: 1.2.0 2025-08-04 16:50:16 +02:00
Amin Ben Romdhane
92be6f1129 ethmngr: 3.1.0 2025-08-04 16:49:03 +02:00
Amin Ben Romdhane
4dfc196968 bbfdm: 1.17.1 2025-08-04 16:47:16 +02:00
Mohd Husaam Mehdi
1c17fed77d fluent-bit: align kmsg output fields with syslog fields
- this allows for a better mapping to the data model
- this reduces load on fluent-bit because now one OUTPUT section
  is sufficient (earlier we needed two output sections because of
  two different templates)
2025-08-04 14:33:28 +05:30
Markus Gothe
27b9fb9350 logmngr: Make sure we never fail to setup /var/log/messages.
If it fails during MP the verfication of buttons will not work
as expected. The problem is that the file is created before
data is commited and when power is cut prematurely it won't
re-create the file, maybe because the uci-default script has
been removed already as well.
2025-07-30 21:49:58 +02:00
arbala
b917a2177e map-agent: 6.3.7.3 2025-07-30 16:08:02 +02:00
Vivek Kumar Dutta
2372de4864 logmngr: fix /dev/log creation 2025-07-30 17:31:26 +05:30
Vivek Kumar Dutta
c5d7ddd851 logmngr: generate kmsg,log config if dev exists 2025-07-29 13:33:50 +00:00
arbala
a688b2091c map-agent: 6.3.7.2 2025-07-29 15:27:25 +02:00
Vivek Kumar Dutta
bfc7e6a78a tr143: 1.1.5 2025-07-29 18:16:33 +05:30
Suvendhu Hansa
41495cf6e5 icwmp,obuspa,gateway-info: Fix ShellCheck issues 2025-07-29 18:11:53 +05:30
Vivek Kumar Dutta
d3d1b444de obuspa: Integrate v10.0.5 2025-07-25 09:09:29 +05:30
Janusz Dziedzic
9681b6222c map-controller: 6.4.0.14 2025-07-24 10:55:16 +00:00
Meng
d20fb01a1b Upgrade quickjs to latest stable
Reworked the 002-fix_std_loadFile.patch
Removed the patches:
- 000-build-options.patch: the build options are now done in the
  Makefile
- 001-no-fenv-dtoa-libbf.patch: this patch is not needed anymore
  in the latest version: quickJS now uses a custom, high-precision
  floating-point conversion library that doesn't rely on the system's
  printf/snprintf for floating-point formatting.
2025-07-24 07:06:09 +00:00
Mohd Husaam Mehdi
85e49b3df6 usermngr: 1.3.11 2025-07-24 09:13:45 +05:30
Mohd Husaam Mehdi
511e0af668 passwdqc: align with usermngr (move PAM setup to usermngr) 2025-07-23 13:12:31 +05:30
Mohd Husaam Mehdi
1151478d13 linux-pam: align with usermngr (move PAM setup to usermngr) 2025-07-23 13:12:31 +05:30
Mohd Husaam Mehdi
7e87028731 usermngr: add support for USERMNGR_SECURITY_HARDENING
* this compile time flag will set up faildelay, lock out upon
  6 failed attempts during login via shell or console and enable
  password strength checks when changing password
* this will set openssh usePam option
* openssh and shadow-utils with PAM backend need to be selected for
  this compile time flag to work
2025-07-23 13:12:31 +05:30
arbala
cb18ecc420 map-controller: 6.4.0.13 2025-07-23 09:38:11 +02:00
Jakob Olsson
e581c05d27 map-agent: 6.3.7.1 2025-07-22 16:11:01 +02:00
Jakob Olsson
3ae6c52e7d map-agent: 6.3.7.0 2025-07-22 14:56:12 +02:00
Amin Ben Romdhane
498a06916b netmode: Align with reference updates 2025-07-21 17:46:16 +05:30
Suvendhu Hansa
332057fdd4 wifidmd,map-agent: Fix WiFi lagecy nodes for extenders 2025-07-21 17:44:04 +05:30
Vivek Kumar Dutta
58aff3cb45 obuspa: Improve file handling 2025-07-21 17:40:53 +05:30
Vivek Kumar Dutta
5678b6dcaa bbfdm: Optimize datamodel references 2025-07-21 17:08:38 +05:30
Vivek Kumar Dutta
a597c514f7 bbfdm: 1.16.8 2025-07-18 17:10:20 +05:30
Mohd Husaam Mehdi
3c1dcf90eb usermngr: set compile time flag to use pam with shadow-utils 2025-07-18 16:27:42 +05:30
Mohd Husaam Mehdi
62dc6c28a3 firewallmngr: 1.0.10 2025-07-17 19:45:09 +05:30
Amin Ben Romdhane
2703ea0421 timemngr: 1.1.11 2025-07-17 15:35:25 +02:00
Amin Ben Romdhane
b4a0572b7c bridgemngr: 1.1.1 2025-07-17 15:34:09 +02:00
Husaam Mehdi
428055c911 sshmngr: use openssh-with-pam as the default backend 2025-07-17 16:16:18 +05:30
Mohd Husaam Mehdi
97723f9e7a usermngr: include passwdqc and linux-pam
* passwdqc helps us enforce strong passwords policy
* linux-pam helps in managing failed login attempts
2025-07-17 14:48:32 +05:30
Vivek Kumar Dutta
2dceb5b44b wifidmd: 1.1.38 2025-07-16 16:51:49 +05:30
Vivek Kumar Dutta
8c9689caf7 fluent-bit: build using git proto 2025-07-16 11:56:36 +05:30
Janusz Dziedzic
af5bb94c8c fluent-bit: fix package hash 2025-07-15 14:45:26 +02:00
Janusz Dziedzic
9db65fcfba libwifi: 7.13.7 2025-07-15 10:24:24 +00:00
Vivek Kumar Dutta
2b43c27e53 xmppc: Fix ConnReqXMPPConnection reference 2025-07-15 10:07:05 +05:30
Vivek Kumar Dutta
c16f4d3f82 wifidmd: 1.1.37 2025-07-14 19:09:46 +05:30
Janusz Dziedzic
99a4f3c036 map-controller: 6.4.0.12 2025-07-14 12:37:53 +02:00
Erik Karlsson
71217d4f68 ieee1905: avoid installing datamodel_description.json into root 2025-07-14 08:50:46 +02:00
Vivek Kumar Dutta
ad012d7549 wifidmd: fix log spamming when radio disabled 2025-07-14 10:01:09 +05:30
Vivek Kumar Dutta
6cca837500 sulu: support dynamic QR 2025-07-14 09:49:23 +05:30
Amin Ben Romdhane
6bec3c159c bbfdm: Ensure UCI savedir paths are created before initialization from C code 2025-07-14 00:37:43 +02:00
Mohd Husaam Mehdi
fd921bb196 fluent-bit: bump version and adjust patch accordingly 2025-07-10 14:53:55 +05:30
Janusz Dziedzic
60d2f92da3 wifimngr: 17.7.6 2025-07-10 08:51:47 +00:00
Janusz Dziedzic
8f83250890 libwifi: 7.13.6 2025-07-10 08:50:48 +00:00
Vivek Kumar Dutta
652ec8a4af wifidmd: Updated default log level 2025-07-09 16:58:15 +05:30
Vivek Kumar Dutta
937b824055 tr143: 1.1.4 2025-07-09 16:56:02 +05:30
Vivek Kumar Dutta
889723079b bridgemngr: Add support for Bridge Type 2025-07-09 16:52:06 +05:30
Janusz Dziedzic
7a457ae32a libwifi: 7.13.5 2025-07-09 12:39:38 +02:00
Vivek Kumar Dutta
7e5e38e657 wifidmd: Support for AgentOnboard event 2025-07-09 15:44:40 +05:30
Vivek Kumar Dutta
44edac6572 icwmp: return 9003 for duplicate param in spv 2025-07-09 15:42:10 +05:30
Amin Ben Romdhane
fea3e1e4ef timemngr: Added support for SupportedZones object 2025-07-09 14:54:54 +05:30
Vivek Kumar Dutta
eae31a6dd4 obuspa: Integrated v10.0.4 2025-07-09 14:29:55 +05:30
Husaam Mehdi
3a1a65d5df logmngr: Use kmsg module instead of klogd 2025-07-09 12:45:43 +05:30
Husaam Mehdi
70a22d0299 logmngr: Include kernel logs 2025-07-09 12:43:46 +05:30
Amin Ben Romdhane
2a19a1a92a ieeee1905: Add data model description 2025-07-09 11:28:59 +05:30
Mohd Husaam Mehdi
5b865c9dbc fluent-bit: fix kmsg plugin and add syslog timestamp to kmsg logs 2025-07-09 11:20:51 +05:30
Mohd Husaam Mehdi
bc041faf04 fluent-bit: enable kmsg plugin 2025-07-09 11:20:51 +05:30
Janusz Dziedzic
de08bc79a1 ieee1905: 8.7.33 2025-07-08 08:16:56 +00:00
134 changed files with 2427 additions and 4690 deletions

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=bbfdm
PKG_VERSION:=1.16.6.2
PKG_VERSION:=1.18.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:=aa480554461c82e6f6f44ee6c23108d3e44fce21
PKG_SOURCE_VERSION:=786863cf0ef48dd70610598cdf8e2bbc0462a504
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -55,7 +55,7 @@ define Package/dm-service
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:=Datamodel ubus backend to expose micro-service tree
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libbbfdm-api +libbbfdm-ubus +bbf_configmngr
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libbbfdm-api +libbbfdm-ubus +bbf_configmngr +libeasy
endef
define Package/bbf_configmngr
@@ -183,6 +183,7 @@ define Package/bbf_configmngr/install
$(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_BIN) $(PKG_BUILD_DIR)/utilities/files/usr/share/bbfdm/scripts/bbf_default_reload.sh $(1)/etc/bbfdm/
$(INSTALL_DATA) ./files/etc/bbfdm/critical_services.json $(1)/etc/bbfdm/
endef

View File

@@ -1,23 +1,51 @@
{
"usp": [
"firewall",
"network",
"dhcp",
"time",
"wireless",
"ieee1905",
"mapcontroller",
"mosquitto",
"nginx",
"netmode"
"/etc/config/firewall",
"/etc/bbfdm/dmmap/dmmap_firewall",
"/etc/config/network",
"/etc/bbfdm/dmmap/IP",
"/etc/bbfdm/dmmap/Ethernet",
"/etc/bbfdm/dmmap/GRE",
"/etc/bbfdm/dmmap/IPv6rd",
"/etc/bbfdm/dmmap/PPP",
"/etc/bbfdm/dmmap/Routing",
"/etc/config/dhcp",
"/etc/bbfdm/dmmap/dmmap_dhcp",
"/etc/bbfdm/dmmap/dmmap_dhcp_client",
"/etc/bbfdm/dmmap/dmmap_dhcp_relay",
"/etc/bbfdm/dmmap/dmmap_dhcpv6",
"/etc/config/time",
"/etc/bbfdm/dmmap/dmmap_time",
"/etc/config/mapcontroller",
"/etc/config/wireless",
"/etc/bbfdm/dmmap/WiFi",
"/etc/config/ieee1905",
"/etc/config/mosquitto",
"/etc/config/nginx",
"/etc/config/netmode",
"/etc/bbfdm/dmmap/dmmap_netmode"
],
"cwmp": [
"firewall",
"network",
"dhcp",
"mapcontroller",
"wireless",
"time",
"netmode"
"/etc/config/firewall",
"/etc/bbfdm/dmmap/dmmap_firewall",
"/etc/config/network",
"/etc/bbfdm/dmmap/IP",
"/etc/bbfdm/dmmap/Ethernet",
"/etc/bbfdm/dmmap/GRE",
"/etc/bbfdm/dmmap/IPv6rd",
"/etc/bbfdm/dmmap/PPP",
"/etc/bbfdm/dmmap/Routing",
"/etc/config/dhcp",
"/etc/bbfdm/dmmap/dmmap_dhcp",
"/etc/bbfdm/dmmap/dmmap_dhcp_client",
"/etc/bbfdm/dmmap/dmmap_dhcp_relay",
"/etc/bbfdm/dmmap/dmmap_dhcpv6",
"/etc/config/mapcontroller",
"/etc/config/wireless",
"/etc/bbfdm/dmmap/WiFi",
"/etc/config/time",
"/etc/bbfdm/dmmap/dmmap_time",
"/etc/config/netmode",
"/etc/bbfdm/dmmap/dmmap_netmode"
]
}

View File

@@ -10,19 +10,10 @@ log() {
echo "${@}"|logger -t bbf.config -p info
}
create_needed_directories()
{
mkdir -p /tmp/bbfdm/.cwmp
mkdir -p /tmp/bbfdm/.usp
mkdir -p /tmp/bbfdm/.bbfdm
}
start_service()
{
local log_level
create_needed_directories
config_load bbfdm
config_get log_level "reload_handler" log_level 2
@@ -36,6 +27,6 @@ start_service()
service_triggers() {
for config_file in /etc/config/*; do
config_name=$(basename "$config_file")
procd_add_config_trigger "config.change" "$config_name" /usr/share/bbfdm/scripts/bbf_config_notify.sh
procd_add_config_trigger "config.change" "$config_name" /usr/share/bbfdm/scripts/bbf_config_notify.sh "$config_name"
done
}

View File

@@ -5,13 +5,14 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=bridgemngr
PKG_VERSION:=1.0.18.2
PKG_VERSION:=1.1.1
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/network/bridgemngr
PKG_SOURCE_VERSION:=71ed529be038392071b0399bcfe9d46e89d3cb46
PKG_SOURCE_VERSION:=b6a657e1c83b49f09323b4012ef229c604b82854
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -6,12 +6,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=decollector
PKG_VERSION:=6.2.1.8
PKG_VERSION:=6.2.1.12
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=b7e294d7c610adfd80cf40a0628c189695dc5156
PKG_SOURCE_VERSION:=ce738316065e4608811312f0a254d1fee22fa343
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

@@ -2,13 +2,13 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=dectmngr
PKG_RELEASE:=3
PKG_VERSION:=3.7.10
PKG_VERSION:=3.7.11
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/dectmngr.git
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=1f851980a6ba616df54f79930225f8bcd563b711
PKG_SOURCE_VERSION:=815ee44808169b8e1efa2cac44bd7d238ad33cdc
PKG_MIRROR_HASH:=skip
endif

44
dmexec/Makefile Executable file
View File

@@ -0,0 +1,44 @@
#
# Copyright (C) 2025 iopsys Software Solutions AB
#
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=dmexec
PKG_VERSION:=0.0.1
PKG_RELEASE:=1
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=GPL-2.0-only
include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/dmexec
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Datamodel for shell exec
DEPENDS:=+dm-service
endef
define Package/dmexec/description
datamodel extension for running shell commands.
endef
define Build/Compile
# pass
endef
define Package/dmexec/install
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DATA) ./files/etc/config/dmexec $(1)/etc/config/
$(INSTALL_BIN) ./files/etc/init.d/dmexec $(1)/etc/init.d/
$(BBFDM_REGISTER_SERVICES) ./bbfdm_service.json $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_DM) ./files/dm_exec.json $(1) $(PKG_NAME)
endef
$(eval $(call BuildPackage,dmexec))

View File

@@ -1,16 +1,16 @@
{
"daemon": {
"enable": "1",
"service_name": "hostmngr",
"service_name": "dmexec",
"unified_daemon": false,
"services": [
{
"parent_dm": "Device.",
"object": "Hosts"
"object": "X_GENEXIS_EU_CLI"
}
],
"config": {
"loglevel": "3"
"loglevel": "7"
}
}
}

81
dmexec/files/dm_exec.json Normal file
View File

@@ -0,0 +1,81 @@
{
"json_plugin_version": 2,
"Device.X_GENEXIS_EU_CLI.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"Enable": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "dmexec",
"section": {
"name": "dmexec"
},
"option": {
"name": "enable"
}
}
}
]
},
"REQUEST": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "dmexec",
"section": {
"name": "dmexec"
},
"option": {
"name": "cmd"
}
}
}
]
},
"RESULT": {
"type": "string",
"read": true,
"write": false,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "dmexec",
"section": {
"name": "dmexec"
},
"option": {
"name": "result"
}
}
}
]
}
}
}

View File

@@ -0,0 +1,3 @@
config dmexec 'dmexec'
option enable '0'

40
dmexec/files/etc/init.d/dmexec Executable file
View File

@@ -0,0 +1,40 @@
#!/bin/sh /etc/rc.common
START=99
STOP=01
USE_PROCD=1
log() {
logger -t dmexec.init "$*"
}
start_service() {
procd_open_instance
procd_close_instance
}
reload_service() {
local cmd result enable
enable="$(uci -q get dmexec.dmexec.enable)"
enable="${enable:-0}"
if [ "${enable}" -eq "0" ]; then
log "dmexec is disabled"
fi
uci -q set dmexec.dmexec.result=""
cmd="$(uci -q get dmexec.dmexec.cmd)"
if [ -n "${cmd}" ]; then
log "Executing [${cmd}]"
result="$(eval $cmd 2>&1 |head -n 1 |head -c 256)"
result="${result//\'/}"
uci -q set dmexec.dmexec.result="${result}"
uci commit dmexec
fi
}
service_triggers() {
procd_add_reload_trigger dmexec
}

View File

@@ -5,8 +5,6 @@ source "/lib/functions/network.sh"
source "/lib/functions/system.sh"
PREVLINK=""
LINK=""
LINKSPEED=""
PREVWANMODE=""
WANMODE=""
CONFIGURED=0
@@ -152,12 +150,6 @@ while [ true ]; do
if [ "$LINK" != "$PREVLINK" -a \( "$LINK" = "down" -o "$LINK" = "up" \) ]; then
if [ "$LINK" = "down" ]; then
if [ ! -s /tmp/qos/wan_link_shape_rate ]; then
rm -rf /tmp/qos/wan_link_shape_rate
rm -rf /tmp/qos/wan_link_speed
/usr/sbin/qos-uplink-bandwidth
fi
[ "$CONFIGURED" -eq 0 ] && configure_lines # Needs to be done once the slave SoC is in down state and we've not been able to auto-sync.
if [ -n "$WANMODE" ]; then
if [ "$WANMODE" = "PTM" ]; then
@@ -234,26 +226,6 @@ while [ true ]; do
call_wan_hotplug "up" "$WANPORT"
PREVWANMODE="$WANMODE"
if [ ! -s /tmp/qos/wan_link_shape_rate ]; then
LINKSPEED="$(awk '/far-end interleaved channel bit rate/{print $6}' /proc/tc3162/adsl_stats)"
LINKSPEED=$((LINKSPEED))
if [ "$LINKSPEED" -eq 0 ]; then
LINKSPEED="$(awk '/far-end fast channel bit rate/{print $6}' /proc/tc3162/adsl_stats)"
LINKSPEED=$((LINKSPEED))
fi
if [ "$LINKSPEED" -ne 0 ]; then
mkdir -p /tmp/qos
touch /tmp/qos/wan_link_shape_rate
/userfs/bin/qosrule discpline Rate uplink-bandwidth ${LINKSPEED}
hw_nat -! > /dev/null 2>&1
else
rm -rf /tmp/qos/wan_link_speed
/usr/sbin/qos-uplink-bandwidth
fi
fi
fi
# Toggle link state

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ethmngr
PKG_VERSION:=3.0.8
PKG_VERSION:=3.1.0
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/hal/ethmngr.git
PKG_SOURCE_VERSION:=c73e5b15718ca40b2740bbe6151dfbb2bcca16df
PKG_SOURCE_VERSION:=da6b25430123f03a74b59369b36dc4a777207d3f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=firewallmngr
PKG_VERSION:=1.0.9
PKG_VERSION:=1.0.10
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/firewallmngr.git
PKG_SOURCE_VERSION:=77ad8425b73a3ac63f6160dc217635394ac87907
PKG_SOURCE_VERSION:=05ad0d6f7f21520eecd05429c14d1963de2a8463
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -40,22 +40,22 @@ get_vivsoi() {
#hex-string 2 character=1 Byte
# length in hex string will be twice of actual Byte length
[ "$len" -gt "8" ] || return
[ "${len}" -gt 8 ] || return
data="${opt125}"
rem_len="${len}"
while [ $rem_len -gt 0 ]; do
while [ "${rem_len}" -gt 0 ]; do
ent_id=${data:0:8}
ent_id=$(printf "%d\n" "0x$ent_id")
if [ $ent_id -ne 3561 ]; then
if [ "${ent_id}" -ne 3561 ]; then
len_val=${data:8:2}
data_len=$(printf "%d\n" "0x$len_val")
# add 4 byte for ent_id and 1 byte for len
data_len=$(( data_len * 2 + 10 ))
# move ahead data to next enterprise id
data=${data:"${data_len}":"${rem_len}"}
rem_len=$(( rem_len - $data_len ))
rem_len=$(( rem_len - data_len ))
continue
fi
@@ -66,7 +66,7 @@ get_vivsoi() {
data_len=$(( data_len * 2 + 10 ))
opt_len=$(printf "%d\n" "0x$len_val")
[ $opt_len -eq 0 ] && return
[ "${opt_len}" -eq 0 ] && return
# populate the option data of enterprise id
sub_data_len=$(( opt_len * 2))
@@ -74,7 +74,7 @@ get_vivsoi() {
sub_data=${data:10:"${sub_data_len}"}
# parsing of suboption of option 125
while [ $sub_data_len -gt 0 ]; do
while [ "${sub_data_len}" -gt 0 ]; do
# get the suboption id
sub_opt_id=${sub_data:0:2}
sub_opt_id=$(printf "%d\n" "0x$sub_opt_id")
@@ -85,20 +85,20 @@ get_vivsoi() {
sub_opt_len=$(( sub_opt_len * 2 ))
# get the value of sub option starting 4 means starting after length
sub_opt_val=${sub_data:4:${sub_opt_len}}
sub_opt_val=${sub_data:4:"${sub_opt_len}"}
# assign the value found in sub option
case "${sub_opt_id}" in
"4")
OUI=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
OUI=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
GW_DISCOVERED=1
;;
"5")
SERIAL=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
SERIAL=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
GW_DISCOVERED=1
;;
"6")
CLASS=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
CLASS=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
GW_DISCOVERED=1
;;
esac
@@ -110,7 +110,7 @@ get_vivsoi() {
sub_data_len=$((sub_data_len - sub_opt_end))
# fetch next sub option hex string
sub_data=${sub_data:${sub_opt_end}:${sub_data_len}}
sub_data=${sub_data:"${sub_opt_end}":"${sub_data_len}"}
done
# move ahead data to next enterprise id
@@ -131,15 +131,13 @@ send_host_query() {
sleep 5
json_load "$(ubus call umdns browse)"
json_select discovered_services
if [ "${?}" -ne 0 ]; then
if ! json_select discovered_services; then
json_cleanup
loop=$(( loop - 1 ))
continue
fi
json_select _usp-agt-mqtt._tcp
if [ "${?}" -ne 0 ]; then
if ! json_select _usp-agt-mqtt._tcp; then
json_cleanup
loop=$(( loop - 1 ))
continue
@@ -156,7 +154,7 @@ send_host_query() {
json_get_keys keys
for key in $keys; do
json_select $key
json_select "${key}"
json_get_var _host host ""
if [ -z "${_host}" ] || [[ "${sent_host}" =~ " ${_host}" ]]; then
@@ -166,9 +164,10 @@ send_host_query() {
sent_host="${sent_host} ${_host}"
cmd="ubus call umdns query '{\"question\":\"$_host\",\"interface\":\"$intf\"}'"
eval $cmd
sh -c "${cmd}"
resp=0
json_select ..
sleep 2 # umdns query sometime takes time to resolve so adding some sleep
done
json_cleanup
@@ -185,32 +184,29 @@ get_usp_agent_id() {
fi
json_load "$(ubus call umdns browse)"
json_select discovered_services
if [ "${?}" -ne 0 ]; then
if ! json_select discovered_services; then
json_cleanup
echo ${ID}
echo "${ID}"
return 0
fi
json_select _usp-agt-mqtt._tcp
if [ "${?}" -ne 0 ]; then
if ! json_select _usp-agt-mqtt._tcp; then
json_cleanup
echo ${ID}
echo "${ID}"
return 0
fi
json_get_keys keys
for key in $keys; do
json_select $key
json_select $family
if [ "${?}" -ne 0 ]; then
json_select "${key}"
if ! json_select "${family}"; then
json_select ..
continue
fi
json_get_keys ips
for ip in $ips; do
json_get_var ip_val $ip
json_get_var ip_val "${ip}"
if [ "${ip_val}" != "${dhcp_ip}" ]; then
continue
fi
@@ -219,8 +215,8 @@ get_usp_agent_id() {
json_select txt
json_get_keys txts
for _txt in $txts; do
json_get_var text_val $_txt
if [[ "${text_val:0:3}" == "ID=" ]]; then
json_get_var text_val "${_txt}"
if [[ "${text_val:0:3}" = "ID=" ]]; then
ID="${text_val:3}"
break
fi
@@ -238,16 +234,16 @@ get_usp_agent_id() {
done
json_cleanup
echo ${ID}
echo "${ID}"
}
get_mac_address() {
ip="${1}"
device="${2}"
mac="$(cat /proc/net/arp | grep $ip | awk '{print $4}')"
mac=$(grep "${ip}" /proc/net/arp | awk '{print $4}')
if [ -z "${mac}" ]; then
arp_resp="$(arping -b -f -c 5 -I $device $ip | grep 'Unicast reply from' | awk '{print $5}')"
arp_resp=$(arping -b -f -c 5 -I "${device}" "${ip}" | grep 'Unicast reply from' | awk '{print $5}')
if [ -n "${arp_resp}" ]; then
mac=${arp_resp:1:-1}
fi
@@ -260,7 +256,7 @@ send_unknown_gw_event() {
mac="${1}"
cmd="ubus -t 5 send gateway-info.gateway.unknown '{\"hwaddr\":\"$mac\"}'"
eval $cmd
sh -c "${cmd}"
}
send_cwmp_gw_event() {
@@ -269,14 +265,14 @@ send_cwmp_gw_event() {
serial="${3}"
cmd="ubus -t 5 send gateway-info.gateway.cwmp '{\"oui\":\"$oui\",\"class\":\"$class\",\"serial\":\"$serial\"}'"
eval $cmd
sh -c "${cmd}"
}
send_usp_gw_event() {
endpoint="${1}"
cmd="ubus -t 5 send gateway-info.gateway.usp '{\"endpoint\":\"$endpoint\"}'"
eval $cmd
sh -c "${cmd}"
}
config_load gateway
@@ -287,13 +283,13 @@ if [ "${enable}" -eq 0 ]; then
return 0
fi
if [ "${wan_intf}" == "${INTERFACE}" ]; then
if [ "${1}" == "deconfig" ]; then
if [ "${wan_intf}" = "${INTERFACE}" ]; then
if [ "${1}" = "deconfig" ]; then
rm -rf /var/state/gwinfo
return 0
fi
json_load "$(ifstatus ${INTERFACE})"
json_load "$(ifstatus "${INTERFACE}")"
json_get_var dev_name device ""
json_select data
json_get_var dhcp_ip dhcpserver ""
@@ -303,7 +299,7 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
return 0
fi
MAC="$(get_mac_address $dhcp_ip $dev_name)"
MAC=$(get_mac_address "${dhcp_ip}" "${dev_name}")
mkdir -p /var/state
touch /var/state/gwinfo
@@ -326,8 +322,8 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
return 0
fi
len=$(printf "$opt125"|wc -c)
get_vivsoi "$opt125" "$len"
len=$(echo -n "${opt125}" | wc -c)
get_vivsoi "${opt125}" "${len}"
if [ "${GW_DISCOVERED}" -eq 0 ]; then
send_unknown_gw_event "${MAC}"
@@ -341,19 +337,18 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
uci -q -c /var/state commit gwinfo
# Check for USP parameters
ubus -t 15 wait_for umdns
if [ "${?}" -ne 0 ]; then
if ! ubus -t 15 wait_for umdns; then
send_cwmp_gw_event "${OUI}" "${CLASS}" "${SERIAL}"
return 0
fi
resp=$(send_host_query $dev_name)
resp=$(send_host_query "${dev_name}")
if [ "${resp}" -ne 0 ]; then
send_cwmp_gw_event "${OUI}" "${CLASS}" "${SERIAL}"
return 0
fi
ID="$(get_usp_agent_id $dhcp_ip)"
ID=$(get_usp_agent_id "${dhcp_ip}")
if [ -z "${ID}" ]; then
send_cwmp_gw_event "${OUI}" "${CLASS}" "${SERIAL}"
return 0

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=hostmngr
PKG_VERSION:=1.3.3
PKG_VERSION:=1.3.1
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=fee5bd0067fc1f30498bc2b81e893d170796b459
PKG_SOURCE_VERSION:=3663ca4d001508509774115d6797b932f9ed4f69
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

@@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=icwmp
PKG_VERSION:=9.9.9.3
PKG_VERSION:=9.10.1
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/icwmp.git
PKG_SOURCE_VERSION:=55a64d756afd6249b8bb4cccf2cdaa7e1aa05f91
PKG_SOURCE_VERSION:=c4b0fa4272ab44a8c78462d5cc8df6501acbeb55
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -31,7 +31,6 @@ config cpe 'cpe'
option bind_retries '5'
option userid '' #$OUI-$SER
option passwd ''
option port '7547'
option provisioning_code ''
option amd_version '5'
# compression possible configs: InstanceNumber, InstanceAlias

View File

@@ -133,9 +133,56 @@ add_firewall_rule() {
fi
}
remove_port_protection() {
local enabled chain rule rule_num
config_get enabled "${1}" "${2}"
if [ "${enabled}" -eq 1 ]; then
config_get zonename "$1" name
[ -n "$zonename" ] || return 0
chain='prerouting_'$zonename'_rule'
while rule=$(iptables -w -t nat -nL "$chain" --line-numbers | grep -m 1 -w CWMP_Port_protection); do
rule_num=${rule%%[$' \t']*}
iptables -w -t nat -D "$chain" "$rule_num"
done
fi
}
cleanup_port_protection() {
config_load firewall
config_foreach remove_port_protection zone masq
}
install_port_protection() {
local PORT="${3}"
local enabled zonename chain
config_get enabled "${1}" "${2}"
if [ "${enabled}" -eq 1 ]; then
config_get zonename "${1}" name
[ -n "$zonename" ] || return 0
chain='prerouting_'$zonename'_rule'
iptables -w -t nat -I "$chain" -p tcp --dport "$PORT" -j ACCEPT -m comment --comment=CWMP_Port_protection
iptables -w -t nat -I "$chain" -p udp --dport "$PORT" -j ACCEPT -m comment --comment=CWMP_Port_protection
fi
}
add_port_protection() {
config_load firewall
config_foreach install_port_protection zone masq "${1}"
}
configure_connection_req_rules() {
app="${1}"
cleanup_port_protection
wan="$(uci -q get cwmp.cpe.default_wan_interface)"
wan="${wan:-wan}"
@@ -175,8 +222,11 @@ configure_connection_req_rules() {
fi
fi
port=$(uci -q get cwmp.cpe.port)
port="${port:-7547}"
port=$(uci -q -c /var/state get icwmp.cpe.port)
if [ -z "${port}" ]; then
log "cwmp cpe port not configured"
exit 0
fi
ipaddr=$(uci -q get cwmp.cpe.allowed_cr_ip)
if [ -n "${ipaddr}" ]; then
@@ -197,6 +247,8 @@ configure_connection_req_rules() {
# Close the ACS port at Lan side
close_downstream_acs_port "${lan}" "${port}"
fi
add_port_protection "${port}"
}
load_zone_names

View File

@@ -5,7 +5,6 @@ uci -q batch <<-EOT
set firewall.cwmp=include
set firewall.cwmp.path=/etc/icwmpd/firewall.cwmp
set firewall.cwmp.reload=1
commit firewall
EOT
exit 0

View File

@@ -16,12 +16,12 @@ get_opt43() {
local opt43="$1"
local len="$2"
[ "$len" -gt "2" ] || return
[ "${len}" -gt 2 ] || return
first_byte=${opt43:0:2}
first_byte=$(printf "%d\n" "0x$first_byte")
if [ $len -ge 4 ] && [ $first_byte -ge 1 ] && [ $first_byte -le 4 ]; then
if [ "${len}" -ge 4 ] && [ "${first_byte}" -ge 1 ] && [ "${first_byte}" -le 4 ]; then
# it is in encapsulated form
# opt43 encapsulated vendor-specific option has data in below format
# Code Len Data item Code Len Data item Code
@@ -35,7 +35,7 @@ get_opt43() {
data="${opt43}"
rem_len="${len}"
# parsing of suboption of option 43
while [ $rem_len -gt 0 ]; do
while [ "${rem_len}" -gt 0 ]; do
# get the suboption id
sub_opt_id=${data:0:2}
sub_opt_id=$(printf "%d\n" "0x$sub_opt_id")
@@ -50,13 +50,13 @@ get_opt43() {
# assign the value found in sub option
case "${sub_opt_id}" in
"1") DHCP_ACS_URL=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
"1") DHCP_ACS_URL=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
;;
"2") DHCP_PROV_CODE=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
"2") DHCP_PROV_CODE=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
;;
"3") MIN_WAIT_INVL=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
"3") MIN_WAIT_INVL=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
;;
"4") INVL_MULTIPLIER=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
"4") INVL_MULTIPLIER=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
;;
esac
@@ -70,7 +70,7 @@ get_opt43() {
rem_len=$((rem_len - sub_opt_end))
done
else
DHCP_ACS_URL=$(echo -n $opt43 | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
DHCP_ACS_URL=$(echo -n "${opt43}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
fi
}
@@ -92,9 +92,9 @@ if [ "$discovery_enable" = "0" ]; then
return 0
fi
if [ "${wan_intf}" == "${INTERFACE}" ]; then
if [ "${wan_intf}" = "${INTERFACE}" ]; then
if [ -n "$opt43" ]; then
len=$(printf "$opt43"|wc -c)
len=$(echo -n "$opt43"|wc -c)
get_opt43 "$opt43" "$len"
fi

View File

@@ -6,12 +6,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ieee1905
PKG_VERSION:=8.7.33
PKG_VERSION:=8.7.37
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=f28f1c04cae008d7d6448ba02b992506af28448c
PKG_SOURCE_VERSION:=c711e1e132478d6443ffb5aad15d12b90f0d59b5
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
@@ -116,7 +116,7 @@ MAKE_PATH:=src
define Package/ieee1905/install
$(CP) ./files/* $(1)/
$(CP) ./files/etc $(1)/
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/lib/ieee1905
$(INSTALL_DIR) $(1)/usr/sbin

View File

@@ -0,0 +1,23 @@
{
"Device.IEEE1905.AL.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"{BBF_VENDOR_PREFIX}LocalOnlyMode": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"description": "Enable or disable interfaces from ieee1905.",
"datatype": "boolean"
}
}
}

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libdpp
PKG_VERSION:=2.1.2
PKG_VERSION:=2.1.1
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=5f1184c52be19f3bfd3bc7e9bc582ef09b0a2b1c
PKG_SOURCE_VERSION:=6024efd3db9dd490c07465ea9b0c15120063165c
PKG_SOURCE_URL:=https://dev.iopsys.eu/multi-ap/libdpp.git
PKG_MAINTAINER:=Jakob Olsson <jakob.olsson@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz

View File

@@ -1,32 +1,28 @@
#
# Copyright (C) 2020-2023 Iopsys
# Copyright (C) 2025 Genexis Sweden AB
#
include $(TOPDIR)/rules.mk
PKG_NAME:=libeasy
PKG_VERSION:=7.4.6
PKG_VERSION:=7.5.0
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=ca7b20068c9d373e41045a2e899a9c697576262c
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/libeasy.git
PKG_MAINTAINER:=Anjan Chanda <anjan.chanda@iopsys.eu>
PKG_SOURCE_VERSION:=18f93677bb4d33ebb6249324a5043294f0eae16c
PKG_SOURCE_URL:=https://dev.iopsys.eu/hal/libeasy.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip
endif
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=LGPL-2.1-only
PKG_LICENSE_FILES:=LICENSE
PKG_LICENSE_FILES:=
PKG_MAINTAINER:=Anjan Chanda <anjan.chanda@genexis.eu>
include $(INCLUDE_DIR)/package.mk
TARGET_CFLAGS += \
-I$(STAGING_DIR)/usr/include \
-I$(STAGING_DIR)/usr/include/openssl \
-I$(STAGING_DIR)/usr/include/libnl3
include $(INCLUDE_DIR)/cmake.mk
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
@@ -34,9 +30,6 @@ define Build/Prepare
endef
endif
MAKE_FLAGS += \
CFLAGS="$(TARGET_CFLAGS) -Wall"
define Package/libeasy
SECTION:=libs
CATEGORY:=Libraries
@@ -47,7 +40,7 @@ define Package/libeasy
endef
define Package/libeasy/description
Library provides common utility functions
This package provides libeasy.so for common utility functions.
endef
define Build/InstallDev/libeasy
@@ -67,6 +60,7 @@ define Build/InstallDev/libeasy
endef
define Build/InstallDev
$(call Build/InstallDev/cmake,$(1))
$(call Build/InstallDev/libeasy,$(1),$(2))
endef

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libwifi
PKG_VERSION:=7.13.6
PKG_VERSION:=7.14.0
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=d17ad7415a821e95618c4739507bf129df3fdebf
PKG_SOURCE_VERSION:=b4b8f524a93d03fd1f89d4c32b8eaca90d9ccc1a
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
@@ -22,6 +22,7 @@ PKG_LICENSE:=LGPL-2.1-only
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/kernel.mk
ifeq ($(CONFIG_TARGET_brcmbca),y)
TARGET_PLATFORM=BROADCOM
@@ -42,10 +43,14 @@ else ifeq ($(CONFIG_TARGET_armvirt),y)
else ifeq ($(CONFIG_TARGET_airoha),y)
TARGET_PLATFORM=ECONET
TARGET_WIFI_TYPE=MEDIATEK
TARGET_CFLAGS +=-DIOPSYS_ECONET
TARGET_CFLAGS +=-DIOPSYS_ECONET -I$(LINUX_DIR)/include/uapi/linux/mtk_nl80211_inc
ifeq ($(CONFIG_TARGET_airoha_an7581),y)
TARGET_CFLAGS +=-DCONFIG_MTK
endif
else ifeq ($(CONFIG_TARGET_mediatek),y)
TARGET_PLATFORM=MEDIATEK
TARGET_WIFI_TYPE=MEDIATEK
TARGET_CFLAGS +=-DCONFIG_MTK -I$(LINUX_DIR)/include/uapi/linux/mtk_nl80211_inc
else ifeq ($(CONFIG_TARGET_ipq95xx),y)
TARGET_PLATFORM=IPQ95XX
TARGET_WIFI_TYPE=QUALCOMM

View File

@@ -31,8 +31,8 @@ MESON_ARGS += \
define Package/linux-pam/install
$(INSTALL_DIR) $(1)/usr/lib/security
$(INSTALL_DIR) $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/pam_faillock.uci_default $(1)/etc/uci-defaults/99-add_pam_faillock
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./linux_pam.init $(1)/etc/init.d/linux_pam
endef
$(eval $(call BuildPackage,linux-pam))

View File

@@ -1,43 +0,0 @@
#!/bin/sh
create_faillock_files()
{
# also create files needed by pam_faillock
touch /var/log/faillock
chmod 700 /var/log/faillock
touch /var/log/btmp
chmod 700 /var/log/btmp
}
update_pam_common_auth()
{
local file="/etc/pam.d/common-auth"
local deny=6
local unlock_time=300
# update pam_unix.so line
sed -i -E 's|^.*pam_unix\.so.*|auth\t sufficient\tpam_unix.so nullok_secure|' "$file"
# Insert pam_faillock lines before and after pam_unix.so
sed -i -E "/pam_unix.so nullok_secure/i auth required pam_faillock.so preauth deny=$deny even_deny_root unlock_time=$unlock_time" "$file"
sed -i -E "/pam_unix.so nullok_secure/a auth [default=die] pam_faillock.so authfail audit deny=$deny even_deny_root unlock_time=$unlock_time" "$file"
}
update_pam_common_account()
{
# update account file
sed -i "/pam_unix.so/ i account required pam_faillock.so" /etc/pam.d/common-account
}
if [ -f "/usr/lib/security/pam_faillock.so" ]; then
update_pam_common_auth
update_pam_common_account
create_faillock_files
fi
if [ -f /etc/config/sshd ]; then
uci -q set sshd.@sshd[0].UsePAM=1
uci commit sshd
fi
exit 0

18
linux-pam/linux_pam.init Executable file
View File

@@ -0,0 +1,18 @@
#!/bin/sh /etc/rc.common
START=11
STOP=90
USE_PROCD=1
create_faillock_files()
{
# also create files needed by pam_faillock
touch /var/log/faillock
chmod 700 /var/log/faillock
touch /var/log/btmp
chmod 700 /var/log/btmp
}
boot() {
create_faillock_files
}

View File

@@ -94,7 +94,6 @@ create_input_section() {
append_conf "[INPUT]"
append_conf " name syslog"
append_conf " unix_perm 0666"
append_conf " tag $tag"
append_conf " path /dev/log"
append_conf ""

View File

@@ -59,8 +59,12 @@ config AGENT_CHECK_PARTIAL_WIFI_RELOAD
bool "Option that allow SSID/PSK simple reload"
default y
config DYNBHD_DYNAMICALLY_PERSIST_CONTROLLER
bool "Let dynbhd through AP-Autoconfiguration Search and DHCP Discovery determine the controller or agent role"
config DYNBH
bool "Enable map-agent dynamic Ethernet backhaul management"
default n
config DYNBH_DYNAMICALLY_PERSIST_CONTROLLER
bool "Let map-agent through AP-Autoconfiguration Search and DHCP Discovery determine the controller or agent role"
config AGENT_UNASSOC_STA_CONT_MONITOR
bool "Enable continuos monitoring of unassociated clients"

View File

@@ -5,9 +5,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=map-agent
PKG_VERSION:=6.3.6.15
PKG_VERSION:=6.4.1.11
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=7b05d265776fca2ff84a63188fcec55c08057e33
PKG_SOURCE_VERSION:=671bb0e693adbeb3e06b967350ce7f96ee91321b
PKG_MAINTAINER:=Jakob Olsson <jakob.olsson@iopsys.eu>
PKG_LICENSE:=BSD-3-Clause
@@ -37,23 +37,10 @@ ifeq ($(CONFIG_AGENT_USE_LIBDPP),y)
TARGET_CFLAGS += -DUSE_LIBDPP
endif
define Package/dynbhd
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Dynamic Backhaul Daemon
DEPENDS:=+libwifi +libuci +libubox +ubus +libeasy +libieee1905 +ieee1905 \
+ieee1905-map-plugin +map-agent
endef
define Package/map-agent/description
This package implements EasyMesh R2 compliant WiFi Agent.
endef
define Package/dynbhd/description
Dyanmic LAN/WAN port detection and loop avoidance.
endef
define Package/map-agent/config
source "$(SOURCE)/Config.in"
endef
@@ -111,7 +98,11 @@ ifeq ($(CONFIG_AGENT_CHECK_PARTIAL_WIFI_RELOAD),y)
TARGET_CFLAGS += -DCHECK_PARTIAL_WIFI_RELOAD
endif
ifeq ($(CONFIG_DYNBHD_DYNAMICALLY_PERSIST_CONTROLLER),y)
ifeq ($(CONFIG_DYNBH),y)
TARGET_CFLAGS += -DDYNBH
endif
ifeq ($(CONFIG_DYNBH_DYNAMICALLY_PERSIST_CONTROLLER),y)
TARGET_CFLAGS += -DPERSIST_CONTROLLER
endif
@@ -124,6 +115,10 @@ MAKE_PATH:=src
define Package/map-agent/install
$(INSTALL_DIR) $(1)/etc
$(CP) ./files/* $(1)/
ifeq ($(CONFIG_DYNBH),y)
$(RM) $(1)/etc/hotplug.d/ethernet/map-dynamic-backhaul
$(RM) $(1)/etc/hotplug.d/ethernet/map-topology-discovery
endif
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_DIR) $(1)/lib/wifi
@@ -131,15 +126,6 @@ define Package/map-agent/install
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/mapagent $(1)/usr/sbin/
endef
define Package/dynbhd/install
$(INSTALL_DIR) $(1)/etc
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_DIR) $(1)/lib/wifi/dynbhd
$(INSTALL_DIR) $(1)/etc/hotplug.d/ethernet
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/dynbh/dynbhd $(1)/usr/sbin/dynbhd
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/dynbh/api $(1)/lib/wifi/dynbhd/api
# $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/dynbh/map-dynamic-backhaul $(1)/etc/hotplug.d/ethernet/map-dynamic-backhaul
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
@@ -148,4 +134,3 @@ endef
endif
$(eval $(call BuildPackage,map-agent))
$(eval $(call BuildPackage,dynbhd))

View File

@@ -17,7 +17,7 @@ config dynamic_backhaul
option missing_bh_reconfig_timer '1800'
config controller_select
option id 'auto'
option mode 'auto'
option probe_int '20'
option retry_int '9'
option autostart '1'

View File

@@ -27,11 +27,6 @@ done
al_brnet="${al_bridge:3}"
[ "$(uci -q get network.${al_brnet}.proto)" == "dhcp" ] || exit 0
############## Dynamic Backhaul Daemon ##############
if [ -n "$(which dynbhd)" ]; then
exit 0
fi
########################################################
################ Dedicated ETH WAN Port ################
wanport="$(jsonfilter -i /etc/board.json -e @.network.wan.device)"
@@ -95,7 +90,8 @@ if [ "$LINK" = "up" ]; then
config_foreach remove_from_bridge bsta
config_foreach update_bstas bsta down
/lib/wifi/multiap set_uplink "eth" "$PORT"
hwaddr="$(ifconfig $PORT | grep -i hwaddr | awk '{print $5}' | awk '{print tolower($0)}')"
/lib/wifi/multiap set_uplink "eth" "$PORT" "$hwaddr"
else
/lib/wifi/multiap unset_uplink "eth"
#rm -f "$map_bh_file"

View File

@@ -7,20 +7,6 @@ USE_PROCD=1
IS_CFG_VALID=1
MAP_DEV="map_dev"
MAP_IF="map"
start_dynbhd_service() {
rm -f /var/run/multiap/multiap.backhaul
procd_open_instance
procd_set_param command "/usr/sbin/dynbhd"
procd_set_param respawn
# procd_set_param stdout 1
# procd_set_param stderr 1
procd_close_instance
}
validate_agent_section() {
uci_validate_section mapagent agent "agent" \
'enabled:bool:true' \
@@ -51,7 +37,7 @@ validate_cs_section() {
uci_validate_section mapagent $section "${section}" \
'local:bool:false' \
'id:string' \
'mode:string' \
'probe_int:range(0,1000):20' \
'retry_int:range(0,255):3' \
'autostart:bool:false'
@@ -179,17 +165,6 @@ create_dir() {
}
start_service() {
if [ -f /usr/sbin/dynbhd ]; then
# Start dynbhd only if the device is operating in extender/repeater mode
al_bridge="$(uci -q get mapagent.agent.al_bridge)"
if [ "${al_bridge:0:3}" = "br-" ]; then
al_brnet="${al_bridge:3}"
if [ "$(uci -q get network.${al_brnet}.proto)" == "dhcp" ]; then
start_dynbhd_service
fi
fi
fi
config_load "mapagent"
validate_agent_config || return 1;

View File

@@ -0,0 +1,15 @@
#!/bin/sh
. /lib/functions.sh
adapt_cntlr_sel() {
local section=$1
id=$(uci -q get mapagent.@controller_select[0].id)
uci -q del mapagent.@controller_select[0].id
# re-apply any custom value
[ -z "${id}" ] || uci -q set mapagent.@controller_select[0].mode="${id}"
}
adapt_cntlr_sel

View File

@@ -10,6 +10,11 @@ network_mode="$(fw_printenv -n netmode)" # default is layer3
multiap_mode="$(fw_printenv -n multiap_mode)" # default is full
disable_mlo="$(fw_printenv -n disable_mlo)"
is_logan() {
[ -d /sys/module/mt_wifi ] && return 0
return 1
}
is_airoha() {
[ -f /proc/device-tree/compatible ] || return
strings /proc/device-tree/compatible | grep -qE '^(econet,|airoha,)'; return
@@ -67,45 +72,44 @@ generate_multiap_config() {
device="$dev"
ifprefix_radio=""
if is_airoha; then
if is_logan; then
uci set mapagent.agent.mld_prefix="bss"
ifname_sta=""
case "$band" in
2g)
ifprefix="ra%"
ifname="ra0"
ifname_bh="ra1"
ifname_sta="apcli0"
;;
5g)
ifprefix="rai%"
ifname="rai0"
ifname_bh="rai1"
ifname_sta="apclii0"
;;
6g)
ifprefix="rax%"
ifname="rax0"
ifname_bh="rax1"
ifname_sta="apclix0"
;;
esac
ifprefix_radio="${ifprefix}"
if [ "${network_mode}" == "extender" ]; then
ifname="${ifname_sta}"
fi
[ "$disable_mlo" == "1" ] || {
uci set wireless.$dev.mlo="1"
uci set wireless.$dev.mlo_capable="1"
}
elif is_airoha; then
if [ -d "/sys/module/mt76" ]; then
ifprefix="wlan%_%"
ifname="wlan${devidx}_0"
ifname_bh="wlan${devidx}_1"
else
uci set mapagent.agent.mld_prefix="bss"
ifname_sta=""
case "$band" in
2g)
ifprefix="ra%"
ifname="ra0"
ifname_bh="ra1"
ifname_sta="apcli0"
;;
5g)
ifprefix="rai%"
ifname="rai0"
ifname_bh="rai1"
ifname_sta="apclii0"
;;
6g)
ifprefix="rax%"
ifname="rax0"
ifname_bh="rax1"
ifname_sta="apclix0"
;;
esac
ifprefix_radio="${ifprefix}"
if [ "${network_mode}" == "extender" ]; then
ifname="${ifname_sta}"
fi
[ "$disable_mlo" == "1" ] || {
uci set wireless.$dev.mlo="1"
uci set wireless.$dev.mlo_capable="1"
}
fi
uci set wireless.$dev.channels="$channels"
uci commit wireless
elif is_broadcom; then

View File

@@ -6,9 +6,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=map-controller
PKG_VERSION:=6.4.2.9
PKG_VERSION:=6.4.2.6
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=c427bbaa53ce470a45a59326281f214f1111c3f7
PKG_SOURCE_VERSION:=5e93ea36c4fb93dd473b233b098ecacf6395a20c
PKG_MAINTAINER:=Jakob Olsson <jakob.olsson@genexis.eu>
LOCAL_DEV=0

View File

@@ -8,7 +8,7 @@ config controller 'controller'
option enable_ts '0'
option primary_vid '1'
option primary_pcp '0'
option stale_sta_timeout '30d'
option stale_sta_timeout '20d'
option de_collect_interval '60'
config sta_steering

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=map-plugins
PKG_VERSION:=1.0.32
PKG_VERSION:=1.0.31
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=d8b310edad1b9777aed805682394e3f9bb300d81
PKG_SOURCE_VERSION:=565cade8fe08807b345404c567243fbdfdcb96c8
PKG_SOURCE_URL:=https://dev.iopsys.eu/multi-ap/map-plugins.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip

View File

@@ -0,0 +1,7 @@
if PACKAGE_mosquitto-auth-shadow
config MOSQUITTO_AUTH_PAM_SUPPORT
bool "Enable support of Linux PAM module for Authentication"
default y
endif

View File

@@ -14,12 +14,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=mosquitto-auth-shadow
PKG_VERSION:=1.0.1
PKG_VERSION:=1.1.0
PKG_MAINTAINER:=Erik Karlsson <erik.karlsson@genexis.eu>
PKG_LICENSE:=EPL-2.0
PKG_BUILD_PARALLEL:=1
PKG_CONFIG_DEPENDS:=CONFIG_MOSQUITTO_AUTH_PAM_SUPPORT
include $(INCLUDE_DIR)/package.mk
@@ -27,7 +28,7 @@ define Package/mosquitto-auth-shadow
SECTION:=net
CATEGORY:=Network
TITLE:=mosquitto - /etc/shadow authentication plugin
DEPENDS:=+mosquitto-ssl
DEPENDS:=+mosquitto-ssl +MOSQUITTO_AUTH_PAM_SUPPORT:libpam
USERID:=mosquitto=200:mosquitto=200 mosquitto=200:shadow=11
endef
@@ -36,6 +37,14 @@ define Package/mosquitto-auth-shadow/description
users using /etc/shadow
endef
define Package/mosquitto-auth-shadow/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(CONFIG_MOSQUITTO_AUTH_PAM_SUPPORT),y)
TARGET_CFLAGS+=-DENABLE_PAM_SUPPORT
endif
define Package/mosquitto-auth-shadow/install
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_BIN) $(PKG_BUILD_DIR)/mosquitto_auth_shadow.so $(1)/usr/lib/

View File

@@ -19,7 +19,7 @@ all: $(TARGETS)
$(CC) $(CFLAGS) -Wall -Werror -fPIC -c -o $@ $<
mosquitto_auth_shadow.so: mosquitto_auth_shadow.pic.o
$(CC) $(LDFLAGS) -shared -o $@ $^
$(CC) $(LDFLAGS) -shared -o $@ $^ $(if $(filter -DENABLE_PAM_SUPPORT,$(CFLAGS)),-lpam)
clean:
rm -f *.o $(TARGETS)

View File

@@ -15,22 +15,78 @@
#include <string.h>
#include <shadow.h>
#include <crypt.h>
#include <stdlib.h>
#include <mosquitto.h>
#include <mosquitto_broker.h>
#include <mosquitto_plugin.h>
static int basic_auth_callback(int event, void *event_data, void *userdata)
#ifdef ENABLE_PAM_SUPPORT
#include <security/pam_appl.h>
static int pam_conversation(int num_msg, const struct pam_message **msg, struct pam_response **resp, void *appdata_ptr)
{
int i;
const char *pass = (const char *)appdata_ptr;
*resp = calloc(num_msg, sizeof(struct pam_response));
if (*resp == NULL) {
mosquitto_log_printf(MOSQ_LOG_ERR, "pam failed to allocate buffer for validation");
return PAM_BUF_ERR;
}
if (pass == NULL)
return PAM_SUCCESS;
for (i = 0; i < num_msg; ++i) {
if (msg[i]->msg_style == PAM_PROMPT_ECHO_OFF) {
(*resp)[i].resp = strdup(pass);
if ((*resp)[i].resp == NULL) {
for (int j = 0; j < i ; j++)
free((*resp)[j].resp);
free(*resp);
*resp = NULL;
mosquitto_log_printf(MOSQ_LOG_ERR, "pam failed in strdup");
return PAM_BUF_ERR;
}
}
}
return PAM_SUCCESS;
}
static int process_pam_auth_callback(struct mosquitto_evt_basic_auth *ed)
{
struct pam_conv conv;
int retval;
pam_handle_t *pamh = NULL;
conv.conv = pam_conversation;
conv.appdata_ptr = (void *)ed->password;
retval = pam_start("mosquitto", ed->username, &conv, &pamh);
if (retval != PAM_SUCCESS) {
mosquitto_log_printf(MOSQ_LOG_ERR, "pam start failed: %s", pam_strerror(pamh, retval));
return MOSQ_ERR_AUTH;
}
retval = pam_authenticate(pamh, 0);
pam_end(pamh, retval);
if (retval == PAM_SUCCESS) {
mosquitto_log_printf(MOSQ_LOG_NOTICE, "pam user [%s] logged in", ed->username);
return MOSQ_ERR_SUCCESS;
}
mosquitto_log_printf(MOSQ_LOG_NOTICE, "pam user [%s] failed authentication, err [%s]", ed->username, pam_strerror(pamh, retval));
return MOSQ_ERR_AUTH;
}
#else
static int process_shadow_auth_callback(struct mosquitto_evt_basic_auth *ed)
{
struct mosquitto_evt_basic_auth *ed = event_data;
struct spwd spbuf, *sp = NULL;
char buf[256];
struct crypt_data data;
char *hash;
/* Let other plugins or broker decide about anonymous login */
if (ed->username == NULL)
return MOSQ_ERR_PLUGIN_DEFER;
getspnam_r(ed->username, &spbuf, buf, sizeof(buf), &sp);
if (sp == NULL || sp->sp_pwdp == NULL)
@@ -54,6 +110,22 @@ static int basic_auth_callback(int event, void *event_data, void *userdata)
return MOSQ_ERR_AUTH;
}
#endif
static int basic_auth_callback(int event, void *event_data, void *userdata)
{
struct mosquitto_evt_basic_auth *ed = event_data;
/* Let other plugins or broker decide about anonymous login */
if (ed->username == NULL)
return MOSQ_ERR_PLUGIN_DEFER;
#ifdef ENABLE_PAM_SUPPORT
return process_pam_auth_callback(ed);
#else
return process_shadow_auth_callback(ed);
#endif
}
int mosquitto_plugin_version(int supported_version_count,
const int *supported_versions)

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=netmngr
PKG_VERSION:=1.1.8
PKG_VERSION:=1.2.0
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/netmngr.git
PKG_SOURCE_VERSION:=6310f32b80f8abeccbf99ad55ce88792b19342d6
PKG_SOURCE_VERSION:=ff08a8cc5c860056a022e5376a973dee5a323595
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -8,7 +8,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=netmode
PKG_VERSION:=1.1.5
PKG_VERSION:=1.1.7
PKG_RELEASE:=1
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=GPL-2.0-only
@@ -18,6 +18,7 @@ include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/netmode
CATEGORY:=Utilities
TITLE:=Network Modes and Utils
DEPENDS:=+dm-service
endef
define Package/netmode/description

View File

@@ -58,7 +58,7 @@
"name": "mode"
}
},
"linker_obj": "Device.{BBF_VENDOR_PREFIX}NetMode.SupportedModes.[Name==@key]."
"linker_obj": "Device.{BBF_VENDOR_PREFIX}NetMode.SupportedModes.*.Name"
}
]
},

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=obuspa
PKG_VERSION:=10.0.0.16
PKG_VERSION:=10.0.7.4
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/obuspa.git
PKG_SOURCE_VERSION:=479ffb3582aa245a84829502d9412ca2539eefca
PKG_SOURCE_VERSION:=84d5ae575134d501b8ca171a5a65c6f410f01d08
PKG_MAINTAINER:=Vivek Dutta <vivek.dutta@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip

View File

@@ -57,18 +57,18 @@ get_vivsoi() {
data="${opt125}"
rem_len="${len}"
while [ $rem_len -gt 0 ]; do
while [ "${rem_len}" -gt 0 ]; do
ent_id=${data:0:8}
ent_id=$(printf "%d\n" "0x$ent_id")
if [ $ent_id -ne 3561 ]; then
if [ "${ent_id}" -ne 3561 ]; then
len_val=${data:8:2}
data_len=$(printf "%d\n" "0x$len_val")
# add 4 byte for ent_id and 1 byte for len
data_len=$(( data_len * 2 + 10 ))
# move ahead data to next enterprise id
data=${data:"${data_len}":"${rem_len}"}
rem_len=$(( rem_len - $data_len ))
rem_len=$(( rem_len - data_len ))
continue
fi
@@ -79,7 +79,7 @@ get_vivsoi() {
data_len=$(( data_len * 2 + 10 ))
opt_len=$(printf "%d\n" "0x$len_val")
[ $opt_len -eq 0 ] && return
[ "${opt_len}" -eq 0 ] && return
# populate the option data of enterprise id
sub_data_len=$(( opt_len * 2))
@@ -98,28 +98,28 @@ get_vivsoi() {
sub_opt_len=$(( sub_opt_len * 2 ))
# get the value of sub option starting 4 means starting after length
sub_opt_val=${sub_data:4:${sub_opt_len}}
sub_opt_val=${sub_data:4:"${sub_opt_len}"}
# assign the value found in sub option
case "${sub_opt_id}" in
"25")
URL=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
URL=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
CONTROLLER_DISCOVERED=1
;;
"26")
PROV_CODE=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
PROV_CODE=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
CONTROLLER_DISCOVERED=1
;;
"27")
RETRY_MIN_INTERVAL=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
RETRY_MIN_INTERVAL=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
CONTROLLER_DISCOVERED=1
;;
"28")
RETRY_INTERVAL_MUL=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
RETRY_INTERVAL_MUL=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
CONTROLLER_DISCOVERED=1
;;
"29")
ENDPOINT_ID=$(echo -n $sub_opt_val | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
ENDPOINT_ID=$(echo -n "${sub_opt_val}" | sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' | xargs printf && echo '')
CONTROLLER_DISCOVERED=1
;;
esac
@@ -131,7 +131,7 @@ get_vivsoi() {
sub_data_len=$((sub_data_len - sub_opt_end))
# fetch next sub option hex string
sub_data=${sub_data:${sub_opt_end}:${sub_data_len}}
sub_data=${sub_data:"${sub_opt_end}":"${sub_data_len}"}
done
# move ahead data to next enterprise id
@@ -146,7 +146,7 @@ get_access_role()
lan_proto="$(uci -q get network.lan.proto)"
if [ "${lan_proto}" == "dhcp" ]; then
if [ "${lan_proto}" = "dhcp" ]; then
mode="extender"
else
mode="full_access"
@@ -174,7 +174,7 @@ config_get_bool enable_obuspa global enabled 1
config_get wan_intf global interface
config_get_bool dhcp_discovery global dhcp_discovery 1
if [ "$enable_obuspa" = "0" ] || [ "$dhcp_discovery" = "0" ]; then
if [ "${enable_obuspa}" -eq 0 ] || [ "${dhcp_discovery}" -eq 0 ]; then
return 0
fi
@@ -190,9 +190,9 @@ if [ -z "${wan_intf}" ]; then
fi
fi
if [ "${wan_intf}" == "${INTERFACE}" ]; then
if [ "${wan_intf}" = "${INTERFACE}" ]; then
if [ -n "$opt125" ]; then
len=$(printf "$opt125"|wc -c)
len=$(echo -n "${opt125}"|wc -c)
get_vivsoi "$opt125" "$len"
fi
@@ -228,10 +228,10 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
;;
*)
# This is an FQDN, perform DNS query
nslookup $URL > /tmp/fqdn_ip
nslookup -type=ptr $URL > /tmp/fqdn_ptr
nslookup -type=srv $URL > /tmp/fqdn_srv
nslookup -type=txt $URL > /tmp/fqdn_srv
nslookup "${URL}" > /tmp/fqdn_ip
nslookup -type=ptr "${URL}" > /tmp/fqdn_ptr
nslookup -type=srv "${URL}" > /tmp/fqdn_srv
nslookup -type=txt "${URL}" > /tmp/fqdn_srv
# TODO extend to collect information from dns-sd records
;;
@@ -247,16 +247,16 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
fi
fi
if [ "${proto}" == "mqtt" ] || [ "${proto}" == "mqtts" ]; then
if [ "${proto}" = "mqtt" ] || [ "${proto}" = "mqtts" ]; then
offered_proto="MQTT"
if [ "${proto}" == "mqtt" ]; then
if [ "${proto}" = "mqtt" ]; then
mtp_encrypt="TCP/IP"
else
mtp_encrypt="TLS"
fi
elif [ "${proto}" == "ws" ] || [ "${proto}" == "wss" ]; then
elif [ "${proto}" = "ws" ] || [ "${proto}" = "wss" ]; then
offered_proto="WebSocket"
if [ "${proto}" == "wss" ]; then
if [ "${proto}" = "wss" ]; then
mtp_encrypt="1"
else
mtp_encrypt="0"
@@ -265,7 +265,7 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
controllers=$(uci -q show obuspa | grep "=controller" | cut -d'=' -f1 | cut -d'.' -f2)
for controller in $controllers; do
dhcp_disc=$(uci -q get obuspa.$controller.dhcp_discovered)
dhcp_disc=$(uci -q get obuspa."${controller}".dhcp_discovered)
if [ "${dhcp_disc}" -eq 1 ]; then
dhcp_controller="${controller}"
break
@@ -273,27 +273,27 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
done
if [ -n "${dhcp_controller}" ]; then
cont_proto="$(uci -q get obuspa.$dhcp_controller.Protocol)"
if [ "${cont_proto}" == "MQTT" ]; then
dhcp_mqtt="$(uci -q get obuspa.$dhcp_controller.mqtt)"
cont_proto=$(uci -q get obuspa."${dhcp_controller}".Protocol)
if [ "${cont_proto}" = "MQTT" ]; then
dhcp_mqtt=$(uci -q get obuspa."${dhcp_controller}".mqtt)
mtps=$(uci -q show obuspa | grep "=mtp" | cut -d'=' -f1 | cut -d'.' -f2)
for mtp in $mtps; do
mtp_mqtt="$(uci -q get obuspa.$mtp.mqtt)"
if [ "${mtp_mqtt}" == "${dhcp_mqtt}" ]; then
mtp_mqtt=$(uci -q get obuspa."${mtp}".mqtt)
if [ "${mtp_mqtt}" = "${dhcp_mqtt}" ]; then
dhcp_mtp="${mtp}"
break
fi
done
elif [ "${cont_proto}" == "WebSocket" ]; then
cont_port="$(uci -q get obuspa.$dhcp_controller.Port)"
cont_encr="$(uci -q get obuspa.$dhcp_controller.EnableEncryption)"
elif [ "${cont_proto}" = "WebSocket" ]; then
cont_port=$(uci -q get obuspa."${dhcp_controller}".Port)
cont_encr=$(uci -q get obuspa."${dhcp_controller}".EnableEncryption)
mtps=$(uci -q show obuspa | grep "=mtp" | cut -d'=' -f1 | cut -d'.' -f2)
for mtp in $mtps; do
mtp_port="$(uci -q get obuspa.$mtp.Port)"
mtp_encr="$(uci -q get obuspa.$mtp.EnableEncryption)"
if [ "${mtp_port}" == "${cont_port}" ] && [ "${mtp_encr}" == "${cont_encr}" ]; then
mtp_port=$(uci -q get obuspa."${mtp}".Port)
mtp_encr=$(uci -q get obuspa."${mtp}".EnableEncryption)
if [ "${mtp_port}" = "${cont_port}" ] && [ "${mtp_encr}" = "${cont_encr}" ]; then
dhcp_mtp="${mtp}"
break
fi
@@ -306,43 +306,43 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
if [ -n "${dhcp_controller}" ]; then
## Handling of controller section
ct_endpoint=$(uci -q get obuspa.$dhcp_controller.EndpointID)
ct_proto=$(uci -q get obuspa.$dhcp_controller.Protocol)
ct_prov=$(uci -q get obuspa.$dhcp_controller.ProvisioningCode)
ct_endpoint=$(uci -q get obuspa."${dhcp_controller}".EndpointID)
ct_proto=$(uci -q get obuspa."${dhcp_controller}".Protocol)
ct_prov=$(uci -q get obuspa."${dhcp_controller}".ProvisioningCode)
if [ "${ct_proto}" = "MQTT" ]; then
ct_topic=$(uci -q get obuspa.$dhcp_controller.Topic)
ct_topic=$(uci -q get obuspa."${dhcp_controller}".Topic)
else
ct_topic=$(uci -q get obuspa.$dhcp_controller.Path)
ct_topic=$(uci -q get obuspa."${dhcp_controller}".Path)
fi
if [ -n "${ENDPOINT_ID}" ] && [ "${ct_endpoint}" != "${ENDPOINT_ID}" ]; then
uci -q set obuspa.$dhcp_controller.EndpointID="${ENDPOINT_ID}"
uci -q set obuspa."${dhcp_controller}".EndpointID="${ENDPOINT_ID}"
uci_change=1
fi
if [ -n "${offered_proto}" ] && [ "${ct_proto}" != "${offered_proto}" ]; then
uci -q set obuspa.$dhcp_controller.Protocol="${offered_proto}"
uci -q set obuspa."${dhcp_controller}".Protocol="${offered_proto}"
if [ "${offered_proto}" != "MQTT" ]; then
uci -q set obuspa.$dhcp_controller.mqtt=""
uci -q set obuspa.$dhcp_controller.Topic=""
uci -q set obuspa.$dhcp_controller.Host="${ip}"
uci -q set obuspa.$dhcp_controller.Port="${port}"
uci -q set obuspa.$dhcp_controller.Path="${ct_topic}"
uci -q set obuspa.$dhcp_controller.EnableEncryption="${mtp_encrypt}"
uci -q delete obuspa."${dhcp_controller}".mqtt
uci -q delete obuspa."${dhcp_controller}".Topic
uci -q set obuspa."${dhcp_controller}".Host="${ip}"
uci -q set obuspa."${dhcp_controller}".Port="${port}"
uci -q set obuspa."${dhcp_controller}".Path="${ct_topic}"
uci -q set obuspa."${dhcp_controller}".EnableEncryption="${mtp_encrypt}"
else
uci -q set obuspa.$dhcp_controller.EnableEncryption=""
uci -q set obuspa.$dhcp_controller.Path=""
uci -q set obuspa.$dhcp_controller.Host=""
uci -q set obuspa.$dhcp_controller.Port=""
uci -q delete obuspa."${dhcp_controller}".EnableEncryption
uci -q delete obuspa."${dhcp_controller}".Path
uci -q delete obuspa."${dhcp_controller}".Host
uci -q delete obuspa."${dhcp_controller}".Port
if [ -z "${dhcp_mqtt}" ]; then
uci -q set obuspa.$dhcp_controller.mqtt='dhcpmqtt'
uci -q set obuspa."${dhcp_controller}".mqtt='dhcpmqtt'
else
uci -q set obuspa.$dhcp_controller.mqtt="${dhcp_mqtt}"
uci -q set obuspa."${dhcp_controller}".mqtt="${dhcp_mqtt}"
fi
uci -q set obuspa.$dhcp_controller.Topic="${ct_topic}"
uci -q set obuspa."${dhcp_controller}".Topic="${ct_topic}"
fi
proto_changed=1
@@ -355,38 +355,38 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
protocol="${offered_proto}"
fi
if [ "${protocol}" == "MQTT" ]; then
uci -q set obuspa.$dhcp_controller.Topic="${topic}"
if [ "${protocol}" = "MQTT" ]; then
uci -q set obuspa."${dhcp_controller}".Topic="${topic}"
else
uci -q set obuspa.$dhcp_controller.Path="${topic}"
uci -q set obuspa."${dhcp_controller}".Path="${topic}"
fi
uci_change=1
fi
if [ -n "${PROV_CODE}" ] && [ "${ct_prov}" != "${PROV_CODE}" ]; then
uci -q set obuspa.$dhcp_controller.ProvisioningCode="${PROV_CODE}"
uci -q set obuspa."${dhcp_controller}".ProvisioningCode="${PROV_CODE}"
uci_change=1
fi
if [ "${proto_changed}" -eq 1 ]; then
if [ "${offered_proto}" == "WebSocket" ]; then
if [ "${offered_proto}" = "WebSocket" ]; then
if [ -n "${dhcp_mqtt}" ]; then
uci -q del obuspa.$dhcp_mqtt
uci -q delete obuspa."${dhcp_mqtt}"
fi
if [ -z "${dhcp_mtp}" ]; then
sec=$(uci -q add obuspa mtp)
uci -q rename obuspa."${sec}"='dhcpmtp'
dhcp_mtp="dhcpmtp"
uci -q set obuspa.$dhcp_mtp.Enable='1'
uci -q set obuspa."${dhcp_mtp}".Enable='1'
fi
uci -q set obuspa.$dhcp_mtp.mqtt=''
uci -q set obuspa.$dhcp_mtp.ResponseTopicConfigured=''
uci -q set obuspa.$dhcp_mtp.Protocol='WebSocket'
uci -q set obuspa.$dhcp_mtp.Port="${port}"
uci -q set obuspa.$dhcp_mtp.EnableEncryption="${mtp_encrypt}"
uci -q set obuspa."${dhcp_mtp}".mqtt=''
uci -q set obuspa."${dhcp_mtp}".ResponseTopicConfigured=''
uci -q set obuspa."${dhcp_mtp}".Protocol='WebSocket'
uci -q set obuspa."${dhcp_mtp}".Port="${port}"
uci -q set obuspa."${dhcp_mtp}".EnableEncryption="${mtp_encrypt}"
uci_change=1
else
@@ -397,78 +397,78 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
sec=$(uci -q add obuspa mqtt)
uci -q rename obuspa."${sec}"='dhcpmqtt'
dhcp_mqtt="dhcpmqtt"
uci -q set obuspa.$dhcp_mqtt.Enable='1'
uci -q set obuspa.$dhcp_mqtt.Username="${user}"
uci -q set obuspa.$dhcp_mqtt.Password="${pass}"
uci -q set obuspa."${dhcp_mqtt}".Enable='1'
uci -q set obuspa."${dhcp_mqtt}".Username="${user}"
uci -q set obuspa."${dhcp_mqtt}".Password="${pass}"
fi
uci -q set obuspa.$dhcp_mqtt.BrokerAddress="${ip}"
uci -q set obuspa.$dhcp_mqtt.BrokerPort="${port}"
uci -q set obuspa.$dhcp_mqtt.TransportProtocol="${mtp_encrypt}"
uci -q set obuspa.$dhcp_mqtt.ProtocolVersion='5.0'
uci -q set obuspa."${dhcp_mqtt}".BrokerAddress="${ip}"
uci -q set obuspa."${dhcp_mqtt}".BrokerPort="${port}"
uci -q set obuspa."${dhcp_mqtt}".TransportProtocol="${mtp_encrypt}"
uci -q set obuspa."${dhcp_mqtt}".ProtocolVersion='5.0'
if [ -z "${dhcp_mtp}" ]; then
sec=$(uci -q add obuspa mtp)
uci -q rename obuspa."${sec}"='dhcpmtp'
dhcp_mtp="dhcpmtp"
uci -q set obuspa.$dhcp_mtp.Enable='1'
uci -q set obuspa."${dhcp_mtp}".Enable='1'
fi
agent_topic=$(get_agent_topic)
uci -q set obuspa.$dhcp_mtp.Port=""
uci -q set obuspa.$dhcp_mtp.EnableEncryption=""
uci -q set obuspa.$dhcp_mtp.Protocol='MQTT'
uci -q set obuspa.$dhcp_mtp.ResponseTopicConfigured="${agent_topic}"
uci -q set obuspa.$dhcp_mtp.mqtt="${dhcp_mqtt}"
uci -q delete obuspa."${dhcp_mtp}".Port
uci -q delete obuspa."${dhcp_mtp}".EnableEncryption
uci -q set obuspa."${dhcp_mtp}".Protocol='MQTT'
uci -q set obuspa."${dhcp_mtp}".ResponseTopicConfigured="${agent_topic}"
uci -q set obuspa."${dhcp_mtp}".mqtt="${dhcp_mqtt}"
uci_change=1
fi
else
if [ "${ct_proto}" == "WebSocket" ]; then
conf_ip="$(uci -q get obuspa.$dhcp_controller.Host)"
conf_port="$(uci -q get obuspa.$dhcp_mtp.Port)"
conf_encr="$(uci -q get obuspa.$dhcp_mtp.EnableEncryption)"
if [ "${ct_proto}" = "WebSocket" ]; then
conf_ip="$(uci -q get obuspa."${dhcp_controller}".Host)"
conf_port="$(uci -q get obuspa."${dhcp_mtp}".Port)"
conf_encr="$(uci -q get obuspa."${dhcp_mtp}".EnableEncryption)"
if [ -n "${ip}" ] && [ "${conf_ip}" != "${ip}" ]; then
uci -q set obuspa.$dhcp_controller.Host="${ip}"
uci -q set obuspa."${dhcp_controller}".Host="${ip}"
uci_change=1
fi
if [ -n "${port}" ] && [ "${conf_port}" != "${port}" ]; then
uci -q set obuspa.$dhcp_mtp.Port="${port}"
uci -q set obuspa.$dhcp_controller.Port="${port}"
uci -q set obuspa."${dhcp_mtp}".Port="${port}"
uci -q set obuspa."${dhcp_controller}".Port="${port}"
uci_change=1
fi
if [ -n "${mtp_encrypt}" ] && [ "${conf_encr}" != "${mtp_encrypt}" ]; then
uci -q set obuspa.$dhcp_mtp.EnableEncryption="${mtp_encrypt}"
uci -q set obuspa.$dhcp_controller.EnableEncryption="${mtp_encrypt}"
uci -q set obuspa."${dhcp_mtp}".EnableEncryption="${mtp_encrypt}"
uci -q set obuspa."${dhcp_controller}".EnableEncryption="${mtp_encrypt}"
uci_change=1
fi
else
conf_ip="$(uci -q get obuspa.$dhcp_mqtt.BrokerAddress)"
conf_port="$(uci -q get obuspa.$dhcp_mqtt.BrokerPort)"
conf_encr="$(uci -q get obuspa.$dhcp_mqtt.TransportProtocol)"
conf_ip=$(uci -q get obuspa."${dhcp_mqtt}".BrokerAddress)
conf_port=$(uci -q get obuspa."${dhcp_mqtt}".BrokerPort)
conf_encr=$(uci -q get obuspa."${dhcp_mqtt}".TransportProtocol)
if [ -n "${port}" ] && [ "${conf_port}" != "${port}" ]; then
uci -q set obuspa.$dhcp_mqtt.BrokerPort="${port}"
uci -q set obuspa."${dhcp_mqtt}".BrokerPort="${port}"
uci_change=1
fi
if [ -n "${mtp_encrypt}" ] && [ "${conf_encr}" != "${mtp_encrypt}" ]; then
uci -q set obuspa.$dhcp_mqtt.TransportProtocol="${mtp_encrypt}"
uci -q set obuspa."${dhcp_mqtt}".TransportProtocol="${mtp_encrypt}"
uci_change=1
fi
if [ -n "${ip}" ] && [ "${conf_ip}" != "${ip}" ]; then
uci -q set obuspa.$dhcp_mqtt.BrokerAddress="${ip}"
uci -q set obuspa."${dhcp_mqtt}".BrokerAddress="${ip}"
uci_change=1
fi
fi
fi
else
uci -q del obuspa.dhcpmtp
uci -q del obuspa.dhcpmqtt
uci -q delete obuspa.dhcpmtp
uci -q delete obuspa.dhcpmqtt
sec=$(uci -q add obuspa controller)
uci -q rename obuspa."${sec}"='dhcpcontroller'
@@ -480,7 +480,7 @@ if [ "${wan_intf}" == "${INTERFACE}" ]; then
uci -q set obuspa.dhcpcontroller.Enable='1'
if [ -n "${offered_proto}" ]; then
if [ "${offered_proto}" == "MQTT" ]; then
if [ "${offered_proto}" = "MQTT" ]; then
user="$(uci -q get obuspa.global.username)"
pass="$(uci -q get obuspa.global.password)"

View File

@@ -1,8 +1,8 @@
Index: obuspa-10.0.0.1/src/core/device_controller.c
Index: obuspa-10.0.5.0/src/core/device_controller.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/device_controller.c
+++ obuspa-10.0.0.1/src/core/device_controller.c
@@ -4211,6 +4211,14 @@ int ProcessControllerAdded(int cont_inst
--- obuspa-10.0.5.0.orig/src/core/device_controller.c
+++ obuspa-10.0.5.0/src/core/device_controller.c
@@ -4223,6 +4223,14 @@ int ProcessControllerAdded(int cont_inst
goto exit;
}
@@ -17,7 +17,7 @@ Index: obuspa-10.0.0.1/src/core/device_controller.c
// Exit if unable to get the object instance numbers present in this controller's MTP table
USP_SNPRINTF(path, sizeof(path), "%s.%d.MTP", device_cont_root, cont_instance);
err = DATA_MODEL_GetInstances(path, &iv);
@@ -4252,14 +4260,6 @@ int ProcessControllerAdded(int cont_inst
@@ -4264,14 +4272,6 @@ int ProcessControllerAdded(int cont_inst
DEVICE_MQTT_UpdateControllerTopics();
#endif

View File

@@ -1,7 +1,7 @@
Index: obuspa-10.0.0.1/src/core/bdc_exec.c
Index: obuspa-10.0.4.0/src/core/bdc_exec.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/bdc_exec.c
+++ obuspa-10.0.0.1/src/core/bdc_exec.c
--- obuspa-10.0.4.0.orig/src/core/bdc_exec.c
+++ obuspa-10.0.4.0/src/core/bdc_exec.c
@@ -549,10 +549,25 @@ int StartSendingReport(bdc_connection_t
// Set the list of headers
@@ -30,10 +30,10 @@ Index: obuspa-10.0.0.1/src/core/bdc_exec.c
bc->headers = curl_slist_append(bc->headers, "Content-Encoding: gzip");
}
Index: obuspa-10.0.0.1/src/core/bdc_exec.h
Index: obuspa-10.0.4.0/src/core/bdc_exec.h
===================================================================
--- obuspa-10.0.0.1.orig/src/core/bdc_exec.h
+++ obuspa-10.0.0.1/src/core/bdc_exec.h
--- obuspa-10.0.4.0.orig/src/core/bdc_exec.h
+++ obuspa-10.0.4.0/src/core/bdc_exec.h
@@ -54,6 +54,8 @@ void BDC_EXEC_ScheduleExit(void);
#define BDC_FLAG_PUT 0x00000001 // If set, HTTP PUT should be used instead of HTTP POST when sending the report to the BDC server
#define BDC_FLAG_GZIP 0x00000002 // If set, the reports contants are Gzipped
@@ -45,10 +45,10 @@ Index: obuspa-10.0.0.1/src/core/bdc_exec.h
+#define BDC_FLAG_HEADER_PER_ROW 0x00000020 // If set, report format in header would be csv ParameterPerRow
+#define BDC_FLAG_HEADER_PER_COL 0x00000040 // If set, report format in header would be csv ParameterPerColumn
#endif
Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
Index: obuspa-10.0.4.0/src/core/device_bulkdata.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/device_bulkdata.c
+++ obuspa-10.0.0.1/src/core/device_bulkdata.c
--- obuspa-10.0.4.0.orig/src/core/device_bulkdata.c
+++ obuspa-10.0.4.0/src/core/device_bulkdata.c
@@ -71,8 +71,12 @@
//------------------------------------------------------------------------------
@@ -95,7 +95,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
int Validate_BulkDataHTTPMethod(dm_req_t *req, char *value);
@@ -247,7 +259,8 @@ bulkdata_profile_t *bulkdata_find_free_p
bulkdata_profile_t *bulkdata_find_profile(int profile_id);
int bulkdata_calc_report_map(bulkdata_profile_t *bp, kv_vector_t *report_map);
int bulkdata_calc_report_map(bulkdata_profile_t *bp, kv_vector_t *report_map, combined_role_t *combined_role);
int bulkdata_reduce_to_alt_name(char *spec, char *path, char *alt_name, char *out_buf, int buf_len);
-char *bulkdata_generate_json_report(bulkdata_profile_t *bp, char *report_timestamp);
+char *bulkdata_generate_json_report(bulkdata_profile_t *bp, char *report_timestamp, char *report_format);
@@ -103,16 +103,16 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
unsigned char *bulkdata_compress_report(profile_ctrl_params_t *ctrl, char *input_buf, int input_len, int *p_output_len);
int bulkdata_schedule_sending_http_report(profile_ctrl_params_t *ctrl, bulkdata_profile_t *bp, unsigned char *json_report, int report_len);
int bulkdata_start_profile(bulkdata_profile_t *bp);
@@ -262,6 +275,8 @@ char *bulkdata_platform_calc_uri_query_s
int bulkdata_platform_get_param_refs(int profile_id, param_ref_vector_t *param_refs);
void bulkdata_expand_param_ref(param_ref_entry_t *pr, group_get_vector_t *ggv);
@@ -263,6 +276,8 @@ int bulkdata_platform_get_param_refs(int
int bulkdata_platform_calc_combined_role(int instance, combined_role_t **bulkdata_role, combined_role_t *combined_role, int *cont_instance);
void bulkdata_expand_param_ref(param_ref_entry_t *pr, group_get_vector_t *ggv, combined_role_t *combined_role);
void bulkdata_append_to_result_map(param_ref_entry_t *pr, group_get_vector_t *ggv, kv_vector_t *report_map);
+void append_string_to_target(char *str, char **output);
+char *csv_encode(const char *str);
int GetAuto_BulkDataController(dm_req_t *req, char *buf, int len);
#ifdef ENABLE_MQTT
int Validate_BulkDataMqttReference(dm_req_t *req, char *value);
void bulkdata_process_profile_mqtt(bulkdata_profile_t *bp);
@@ -299,7 +314,7 @@ int DEVICE_BULKDATA_Init(void)
@@ -301,7 +316,7 @@ int DEVICE_BULKDATA_Init(void)
err |= USP_REGISTER_VendorParam_ReadOnly("Device.BulkData.Status", Get_BulkDataGlobalStatus, DM_STRING);
err |= USP_REGISTER_Param_Constant("Device.BulkData.MinReportingInterval", BULKDATA_MINIMUM_REPORTING_INTERVAL_STR, DM_UINT);
err |= USP_REGISTER_Param_SupportedList("Device.BulkData.Protocols", bdc_protocols, NUM_ELEM(bdc_protocols));
@@ -121,7 +121,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
err |= USP_REGISTER_Param_Constant("Device.BulkData.ParameterWildCardSupported", "true", DM_BOOL);
err |= USP_REGISTER_Param_Constant("Device.BulkData.MaxNumberOfProfiles", BULKDATA_MAX_PROFILES_STR, DM_INT);
err |= USP_REGISTER_Param_Constant("Device.BulkData.MaxNumberOfParameterReferences", "-1", DM_INT);
@@ -314,7 +329,7 @@ int DEVICE_BULKDATA_Init(void)
@@ -316,7 +331,7 @@ int DEVICE_BULKDATA_Init(void)
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.Name", "", NULL, NULL, DM_STRING);
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.NumberOfRetainedFailedReports", "0", Validate_NumberOfRetainedFailedReports, NULL, DM_INT);
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.Protocol", BULKDATA_PROTOCOL_HTTP, Validate_BulkDataProtocol, NULL, DM_STRING);
@@ -129,8 +129,8 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
+ err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.EncodingType", BULKDATA_ENCODING_TYPE_JSON, Validate_BulkDataEncodingType, NULL, DM_STRING);
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.ReportingInterval", "86400", Validate_BulkDataReportingInterval, NotifyChange_BulkDataReportingInterval, DM_UINT);
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.TimeReference", UNKNOWN_TIME_STR, NULL, NotifyChange_BulkDataTimeReference, DM_DATETIME);
@@ -326,9 +341,16 @@ int DEVICE_BULKDATA_Init(void)
err |= USP_REGISTER_DBParam_ReadOnlyAuto("Device.BulkData.Profile.{i}.Controller", GetAuto_BulkDataController, DM_STRING);
@@ -329,9 +344,16 @@ int DEVICE_BULKDATA_Init(void)
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.Parameter.{i}.Reference", "", Validate_BulkDataReference, NULL, DM_STRING);
// Device.BulkData.Profile.{i}.JSONEncoding
@@ -148,7 +148,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
// Device.BulkData.Profile.{i}.HTTP
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.HTTP.URL", "", NULL, NotifyChange_BulkDataURL, DM_STRING);
err |= USP_REGISTER_DBParam_ReadWrite("Device.BulkData.Profile.{i}.HTTP.Username", "", NULL, NULL, DM_STRING);
@@ -614,9 +636,10 @@ int Validate_BulkDataProtocol(dm_req_t *
@@ -687,9 +709,10 @@ int Validate_BulkDataProtocol(dm_req_t *
int Validate_BulkDataEncodingType(dm_req_t *req, char *value)
{
// Exit if trying to set a value outside of the range we accept
@@ -162,7 +162,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
return USP_ERR_INVALID_VALUE;
}
@@ -720,9 +743,36 @@ int Validate_BulkDataReference(dm_req_t
@@ -793,9 +816,36 @@ int Validate_BulkDataReference(dm_req_t
int Validate_BulkDataReportFormat(dm_req_t *req, char *value)
{
// Exit if trying to set a value outside of the range we accept
@@ -201,7 +201,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
return USP_ERR_INVALID_VALUE;
}
@@ -2053,6 +2103,14 @@ int bulkdata_platform_get_profile_contro
@@ -2151,6 +2201,14 @@ int bulkdata_platform_get_profile_contro
return err;
}
@@ -216,7 +216,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
// Exit if unable to get ReportTimestamp
USP_SNPRINTF(path, sizeof(path), "Device.BulkData.Profile.%d.JSONEncoding.ReportTimestamp", bp->profile_id);
err = DATA_MODEL_GetParameterValue(path, ctrl_params->report_timestamp, sizeof(ctrl_params->report_timestamp), 0);
@@ -2061,6 +2119,54 @@ int bulkdata_platform_get_profile_contro
@@ -2159,6 +2217,54 @@ int bulkdata_platform_get_profile_contro
return err;
}
@@ -271,7 +271,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
#ifdef ENABLE_MQTT
{
char protocol[32];
@@ -2334,7 +2440,7 @@ void bulkdata_process_profile_http(bulkd
@@ -2492,7 +2598,7 @@ void bulkdata_process_profile_http(bulkd
{
int err;
report_t *cur_report;
@@ -280,7 +280,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
profile_ctrl_params_t ctrl;
unsigned char *compressed_report;
int compressed_len;
@@ -2373,10 +2479,23 @@ void bulkdata_process_profile_http(bulkd
@@ -2541,26 +2647,39 @@ void bulkdata_process_profile_http(bulkd
}
// Exit if unable to generate the report
@@ -308,7 +308,9 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
return;
}
@@ -2385,14 +2504,14 @@ void bulkdata_process_profile_http(bulkd
// Print out the JSON report, if debugging is enabled
- USP_LOG_Info("\nBULK DATA: %sing at time %s, to url=%s", ctrl.method, iso8601_cur_time(buf, sizeof(buf)), ctrl.url);
+ USP_LOG_Info("BULK DATA: %sing at time %s, to url=%s", ctrl.method, iso8601_cur_time(buf, sizeof(buf)), ctrl.url);
USP_LOG_Info("BULK DATA: using compression method=%s", ctrl.compression);
if (enable_protocol_trace)
{
@@ -327,7 +329,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
}
// NOTE: From this point on, only the compressed_report exists
@@ -2422,8 +2541,15 @@ void bulkdata_process_profile_usp_event(
@@ -2590,8 +2709,15 @@ void bulkdata_process_profile_usp_event(
kv_vector_t event_args;
kv_pair_t kv;
report_t *cur_report;
@@ -341,11 +343,11 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
+ char escape_char[10];
+ char csv_format[20];
+ char row_timestamp[33];
// Exit if the MTP has not been connected to successfully after bootup
// This is to prevent BDC events being enqueued before the Boot! event is sent (the Boot! event is only sent after successfully connecting to the MTP).
@@ -2432,13 +2558,63 @@ void bulkdata_process_profile_usp_event(
goto exit;
combined_role_t *bulkdata_role;
combined_role_t combined_role;
int cont_instance;
@@ -2610,13 +2736,63 @@ void bulkdata_process_profile_usp_event(
return;
}
- // Exit if unable to get ReportTimestamp
@@ -415,7 +417,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
// When sending via USP events, only one report is ever sent in each USP event
// So ensure all retained reports are removed. NOTE: Clearing the reports here is only necessary when switching protocol from HTTP to USP event, and where HTTP had some unsent reports
@@ -2456,11 +2632,17 @@ void bulkdata_process_profile_usp_event(
@@ -2634,11 +2810,17 @@ void bulkdata_process_profile_usp_event(
}
bp->num_retained_reports = 1;
@@ -436,7 +438,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
return;
}
@@ -2468,15 +2650,15 @@ void bulkdata_process_profile_usp_event(
@@ -2646,15 +2828,15 @@ void bulkdata_process_profile_usp_event(
// Construct event_args manually to avoid the overhead of a malloc and copy of the report in KV_VECTOR_Add()
kv.key = "Data";
@@ -446,7 +448,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
event_args.num_entries = 1;
USP_SNPRINTF(path, sizeof(path), "Device.BulkData.Profile.%d.Push!", bp->profile_id);
DEVICE_SUBSCRIPTION_ProcessAllEventCompleteSubscriptions(path, &event_args);
DEVICE_SUBSCRIPTION_ProcessAllEventCompleteSubscriptions(path, &event_args, cont_instance);
- // Free the report. No need to free the event_args as json_report is the only thing dynamically allocated in it
- free(json_report); // The report is not allocated via USP_MALLOC
@@ -455,7 +457,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
// 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
@@ -2548,11 +2730,24 @@ void bulkdata_process_profile_mqtt(bulkd
@@ -2736,15 +2918,28 @@ void bulkdata_process_profile_mqtt(bulkd
}
// Exit if unable to generate the report
@@ -485,7 +487,21 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
}
// Print out the JSON report, if debugging is enabled
@@ -2763,7 +2958,7 @@ int bulkdata_reduce_to_alt_name(char *sp
- USP_LOG_Debug("\nBULK DATA: Sending at time %s to MQTT topic %s", iso8601_cur_time(buf, sizeof(buf)), ctrl.mqtt_publish_topic);
+ USP_LOG_Debug("BULK DATA: Sending at time %s to MQTT topic %s", iso8601_cur_time(buf, sizeof(buf)), ctrl.mqtt_publish_topic);
if (enable_protocol_trace)
{
USP_LOG_String(kLogLevel_Info, kLogType_Protocol, report);
@@ -2939,7 +3134,7 @@ int bulkdata_reduce_to_alt_name(char *sp
/*********************************************************************//**
**
-** bulkdata_generate_json_report
+** bulkdata_generate_json_name_value_pair_report
**
** Generates a JSON name-value pair format report
** NOTE: The report contains all retained failed reports, as well as the current report
@@ -2951,7 +3146,7 @@ int bulkdata_reduce_to_alt_name(char *sp
** \return pointer to NULL terminated dynamically allocated buffer containing the serialized report to send
**
**************************************************************************/
@@ -494,7 +510,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
{
JsonNode *top; // top of report
JsonNode *array; // array of reports (retained + current)
@@ -2868,6 +3063,483 @@ char *bulkdata_generate_json_report(bulk
@@ -3056,6 +3251,483 @@ char *bulkdata_generate_json_report(bulk
return result;
}
@@ -978,7 +994,7 @@ Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
/*********************************************************************//**
**
** bulkdata_compress_report
@@ -3071,6 +3743,20 @@ int bulkdata_schedule_sending_http_repor
@@ -3259,6 +3931,20 @@ int bulkdata_schedule_sending_http_repor
flags |= BDC_FLAG_DATE_HEADER;
}

View File

@@ -1,7 +1,7 @@
Index: obuspa-10.0.0.1/src/core/expr_vector.c
Index: obuspa-10.0.5.0/src/core/expr_vector.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/expr_vector.c
+++ obuspa-10.0.0.1/src/core/expr_vector.c
--- obuspa-10.0.5.0.orig/src/core/expr_vector.c
+++ obuspa-10.0.5.0/src/core/expr_vector.c
@@ -59,6 +59,7 @@ char *expr_op_2_str[kExprOp_Max] =
"<", // kExprOp_LessThan
">", // kExprOp_GreaterThan
@@ -10,7 +10,7 @@ Index: obuspa-10.0.0.1/src/core/expr_vector.c
};
@@ -483,6 +484,15 @@ char *SplitOnOperator(char *buf, expr_op
@@ -487,6 +488,15 @@ char *SplitOnOperator(char *buf, expr_op
*op = '\0';
return &op[2];
}
@@ -26,10 +26,10 @@ Index: obuspa-10.0.0.1/src/core/expr_vector.c
// Exit if found the "<" operator
op = strchr(buf, '<');
Index: obuspa-10.0.0.1/src/core/path_resolver.c
Index: obuspa-10.0.5.0/src/core/path_resolver.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/path_resolver.c
+++ obuspa-10.0.0.1/src/core/path_resolver.c
--- obuspa-10.0.5.0.orig/src/core/path_resolver.c
+++ obuspa-10.0.5.0/src/core/path_resolver.c
@@ -1088,7 +1088,7 @@ int ResolveUniqueKey(char *resolved, cha
char temp[MAX_DM_PATH];
bool is_match;
@@ -38,7 +38,7 @@ Index: obuspa-10.0.0.1/src/core/path_resolver.c
+ expr_op_t valid_ops[] = {kExprOp_Equal, kExprOp_NotEqual, kExprOp_LessThanOrEqual, kExprOp_GreaterThanOrEqual, kExprOp_LessThan, kExprOp_GreaterThan, kExprOp_Contains};
// Exit if unable to find the end of the unique key
p = strchr(unresolved, ']');
p = TEXT_UTILS_StrStr(unresolved, "]");
@@ -1754,6 +1754,67 @@ int DoUniqueKeysMatch(int index, search_
}
USP_ASSERT(gge->value != NULL); // GROUP_GET_VECTOR_GetValues() should have set an error message if the vendor hook didn't set a value for the parameter
@@ -107,10 +107,10 @@ Index: obuspa-10.0.0.1/src/core/path_resolver.c
// Determine the function to call to perform the comparison
if (type_flags & (DM_INT | DM_UINT | DM_ULONG | DM_LONG | DM_DECIMAL))
{
Index: obuspa-10.0.0.1/src/include/usp_api.h
Index: obuspa-10.0.5.0/src/include/usp_api.h
===================================================================
--- obuspa-10.0.0.1.orig/src/include/usp_api.h
+++ obuspa-10.0.0.1/src/include/usp_api.h
--- obuspa-10.0.5.0.orig/src/include/usp_api.h
+++ obuspa-10.0.5.0/src/include/usp_api.h
@@ -106,6 +106,7 @@ typedef enum
kExprOp_LessThan, // '<'
kExprOp_GreaterThan, // '>'

View File

@@ -1,40 +1,40 @@
Index: obuspa-10.0.0.2/src/core/device.h
Index: obuspa-10.0.5.0/src/core/device.h
===================================================================
--- obuspa-10.0.0.2.orig/src/core/device.h
+++ obuspa-10.0.0.2/src/core/device.h
@@ -305,6 +305,8 @@ void DEVICE_CTRUST_ApplyPermissionsToSub
--- obuspa-10.0.5.0.orig/src/core/device.h
+++ obuspa-10.0.5.0/src/core/device.h
@@ -311,6 +311,9 @@ int DEVICE_CTRUST_InstSelToRoleInstance(
char *DEVICE_CTRUST_InstSelToPermTarget(int role_index, void *is, int *perm_instance);
int DEVICE_CTRUST_SetRoleParameter(int instance, char *param_name, char *new_value);
int DEVICE_CTRUST_SetPermissionParameter(int instance1, int instance2, char *param_name, char *new_value);
+
+bool DEVICE_CTRUST_IsControllerSecured(void);
+
int DEVICE_CTRUST_DumpPermissionSelectors(int role_instance, char *path);
int DEVICE_REQUEST_Init(void);
int DEVICE_REQUEST_Add(char *path, char *command_key, int *instance);
void DEVICE_REQUEST_OperationComplete(int instance, int err_code, char *err_msg, kv_vector_t *output_args);
Index: obuspa-10.0.0.2/src/core/device_ctrust.c
Index: obuspa-10.0.5.0/src/core/device_ctrust.c
===================================================================
--- obuspa-10.0.0.2.orig/src/core/device_ctrust.c
+++ obuspa-10.0.0.2/src/core/device_ctrust.c
@@ -235,6 +235,7 @@ credential_t *FindCredentialByCertInstan
--- obuspa-10.0.5.0.orig/src/core/device_ctrust.c
+++ obuspa-10.0.5.0/src/core/device_ctrust.c
@@ -246,6 +246,7 @@ credential_t *FindCredentialByCertInstan
int Get_CredentialRole(dm_req_t *req, char *buf, int len);
int Get_CredentialCertificate(dm_req_t *req, char *buf, int len);
int Get_CredentialNumEntries(dm_req_t *req, char *buf, int len);
+int Validate_SecuredRoles(dm_req_t *req, char *value);
void ApplySearchExpressionPermissions(char *path, inst_sel_t *sel);
bool ValidateDataModelPathSegment(char *segment, bool is_last, char *path);
@@ -293,6 +294,9 @@ int DEVICE_CTRUST_Init(void)
// Create a timer which will be used to apply all modified permissions to the data model, after processing a USP Message
SYNC_TIMER_Add(ApplyModifiedPermissions, 0, END_OF_TIME);
#ifndef REMOVE_DEVICE_SECURITY
int InitChallengeTable();
@@ -354,6 +355,10 @@ int DEVICE_CTRUST_Init(void)
challenge_response_input_args, NUM_ELEM(challenge_response_input_args),
NULL, 0);
#endif
+
+ // Register Device.LocalAgent.ControllerTrust.SecuredRoles parameter
+ err |= USP_REGISTER_DBParam_ReadWrite(DEVICE_CTRUST_ROOT ".SecuredRoles", "", Validate_SecuredRoles, NULL, DM_STRING);
+
// Exit if any errors occurred
if (err != USP_ERR_OK)
{
@@ -2908,3 +2913,139 @@ exit:
// Register parameters implemented by this component
// Device.LocalAgent.ControllerTrust.Role.{i}
err |= USP_REGISTER_Object(DEVICE_ROLE_ROOT, ValidateAdd_CTrustRole, NULL, Notify_CTrustRoleAdded,
@@ -3533,3 +3537,139 @@ exit:
return err;
}
#endif // REMOVE_DEVICE_SECURITY

View File

@@ -1,8 +1,8 @@
Index: obuspa-10.0.0.2/src/core/cli_server.c
Index: obuspa-10.0.7.0/src/core/cli_server.c
===================================================================
--- obuspa-10.0.0.2.orig/src/core/cli_server.c
+++ obuspa-10.0.0.2/src/core/cli_server.c
@@ -724,10 +724,6 @@ int ExecuteCli_Get(str_vector_t *args)
--- obuspa-10.0.7.0.orig/src/core/cli_server.c
+++ obuspa-10.0.7.0/src/core/cli_server.c
@@ -726,10 +726,6 @@ int ExecuteCli_Get(str_vector_t *args)
USP_ASSERT(gge->value != NULL);
SendCliResponse("%s => %s\n", gge->path, gge->value);
}
@@ -13,11 +13,11 @@ Index: obuspa-10.0.0.2/src/core/cli_server.c
}
GROUP_GET_VECTOR_Destroy(&ggv);
Index: obuspa-10.0.0.2/src/core/data_model.c
Index: obuspa-10.0.7.0/src/core/data_model.c
===================================================================
--- obuspa-10.0.0.2.orig/src/core/data_model.c
+++ obuspa-10.0.0.2/src/core/data_model.c
@@ -1321,7 +1321,7 @@ int DATA_MODEL_NotifyInstanceAdded(char
--- obuspa-10.0.7.0.orig/src/core/data_model.c
+++ obuspa-10.0.7.0/src/core/data_model.c
@@ -1398,7 +1398,7 @@ int DATA_MODEL_NotifyInstanceAdded(char
// Exit if instance already exists - nothing to do
if (exists)
{
@@ -26,7 +26,7 @@ Index: obuspa-10.0.0.2/src/core/data_model.c
return USP_ERR_CREATION_FAILURE;
}
@@ -1409,7 +1409,7 @@ int DATA_MODEL_NotifyInstanceDeleted(cha
@@ -1486,7 +1486,7 @@ int DATA_MODEL_NotifyInstanceDeleted(cha
// Exit if instance does not exist - nothing to do
if (exists == false)
{
@@ -35,11 +35,11 @@ Index: obuspa-10.0.0.2/src/core/data_model.c
return USP_ERR_OBJECT_DOES_NOT_EXIST;
}
diff --git a/src/core/mqtt.c b/src/core/mqtt.c
index 388697a..444b4da 100644
--- a/src/core/mqtt.c
+++ b/src/core/mqtt.c
@@ -4020,7 +4020,7 @@ void MessageV5Callback(struct mosquitto *mosq, void *userdata, const struct mosq
Index: obuspa-10.0.7.0/src/core/mqtt.c
===================================================================
--- obuspa-10.0.7.0.orig/src/core/mqtt.c
+++ obuspa-10.0.7.0/src/core/mqtt.c
@@ -4070,7 +4070,7 @@ void MessageV5Callback(struct mosquitto
if (mosquitto_property_read_string(props, RESPONSE_TOPIC,
&response_info_ptr, false) == NULL)
{

View File

@@ -4,11 +4,11 @@ Date: Wed Apr 30 17:18:27 2025 +0530
1001-use-datamodel-caching.patch
diff --git a/src/core/cli_server.c b/src/core/cli_server.c
index da61c6f..abac7cb 100644
--- a/src/core/cli_server.c
+++ b/src/core/cli_server.c
@@ -511,6 +511,7 @@ int CLI_SERVER_ExecuteCliCommand(char *cmd_line)
Index: obuspa-10.0.7.0/src/core/cli_server.c
===================================================================
--- obuspa-10.0.7.0.orig/src/core/cli_server.c
+++ obuspa-10.0.7.0/src/core/cli_server.c
@@ -513,6 +513,7 @@ int CLI_SERVER_ExecuteCliCommand(char *c
SendCliResponse("WARNING: Discarding unused args: %s\n", args.vector[cli_cmd->max_args+1]);
}
@@ -16,7 +16,7 @@ index da61c6f..abac7cb 100644
// Process command
err = cli_cmd->exec_cmd(&args);
print_help = false;
@@ -670,6 +671,11 @@ int ExecuteCli_Version(str_vector_t *args)
@@ -672,6 +673,11 @@ int ExecuteCli_Version(str_vector_t *arg
int ExecuteCli_Get(str_vector_t *args)
{
combined_role_t *combined_role;
@@ -28,22 +28,22 @@ index da61c6f..abac7cb 100644
#ifndef REMOVE_USP_BROKER
char *arg1;
diff --git a/src/core/data_model.h b/src/core/data_model.h
index 7564127..2736d7c 100755
--- a/src/core/data_model.h
+++ b/src/core/data_model.h
@@ -405,5 +405,6 @@ int DM_PRIV_ReRegister_DBParam_Default(char *path, char *value);
Index: obuspa-10.0.7.0/src/core/data_model.h
===================================================================
--- obuspa-10.0.7.0.orig/src/core/data_model.h
+++ obuspa-10.0.7.0/src/core/data_model.h
@@ -417,5 +417,6 @@ int DM_PRIV_ReRegister_DBParam_Default(c
bool DM_PRIV_IsChildNodeOf(dm_node_t *node, dm_node_t *parent_node);
void DM_PRIV_GetAllEventsAndCommands(dm_node_t *node, str_vector_t *events, str_vector_t *commands);
+int vendor_create_dm_cache(char *paths[], int num_paths);
#endif
diff --git a/src/core/handle_get.c b/src/core/handle_get.c
index d9d3e9e..c263978 100644
--- a/src/core/handle_get.c
+++ b/src/core/handle_get.c
@@ -129,6 +129,7 @@ void MSG_HANDLER_HandleGet(Usp__Msg *usp, char *controller_endpoint, mtp_conn_t
Index: obuspa-10.0.7.0/src/core/handle_get.c
===================================================================
--- obuspa-10.0.7.0.orig/src/core/handle_get.c
+++ obuspa-10.0.7.0/src/core/handle_get.c
@@ -129,6 +129,7 @@ void MSG_HANDLER_HandleGet(Usp__Msg *usp
goto exit;
}
@@ -51,11 +51,11 @@ index d9d3e9e..c263978 100644
// Calculate the number of hierarchical levels to traverse in the data model when performing partial path resolution
// NOTE: protocol buffer has depth as an unsigned quantity, but internally we use a signed number, so limit range to that of a signed number
depth = usp->body->request->get->max_depth;
diff --git a/src/core/msg_handler.c b/src/core/msg_handler.c
index 647591d..b7498d8 100755
--- a/src/core/msg_handler.c
+++ b/src/core/msg_handler.c
@@ -863,6 +863,8 @@ int HandleUspMessage(Usp__Msg *usp, char *endpoint_id, mtp_conn_t *mtpc)
Index: obuspa-10.0.7.0/src/core/msg_handler.c
===================================================================
--- obuspa-10.0.7.0.orig/src/core/msg_handler.c
+++ obuspa-10.0.7.0/src/core/msg_handler.c
@@ -987,6 +987,8 @@ int HandleUspMessage(Usp__Msg *usp, char
MSG_HANDLER_UspMsgTypeToString(usp->header->msg_type),
iso8601_cur_time(buf, sizeof(buf)) );

View File

@@ -1,8 +1,8 @@
Index: obuspa-10.0.0.1/src/core/device_bulkdata.c
Index: obuspa-10.0.4.0/src/core/device_bulkdata.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/device_bulkdata.c
+++ obuspa-10.0.0.1/src/core/device_bulkdata.c
@@ -375,6 +375,8 @@ int DEVICE_BULKDATA_Init(void)
--- obuspa-10.0.4.0.orig/src/core/device_bulkdata.c
+++ obuspa-10.0.4.0/src/core/device_bulkdata.c
@@ -378,6 +378,8 @@ int DEVICE_BULKDATA_Init(void)
// 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);

View File

@@ -1,8 +1,8 @@
Index: obuspa-10.0.0.2/src/core/data_model.c
Index: obuspa-10.0.7.0/src/core/data_model.c
===================================================================
--- obuspa-10.0.0.2.orig/src/core/data_model.c
+++ obuspa-10.0.0.2/src/core/data_model.c
@@ -5347,7 +5347,7 @@ int RegisterDefaultControllerTrust(void)
--- obuspa-10.0.7.0.orig/src/core/data_model.c
+++ obuspa-10.0.7.0/src/core/data_model.c
@@ -5519,7 +5519,7 @@ int RegisterDefaultControllerTrust(void)
int err = USP_ERR_OK;
// Register 'Full Access' role

View File

@@ -1,8 +1,8 @@
Index: obuspa-10.0.0.2/src/core/device.h
Index: obuspa-10.0.6.0/src/core/device.h
===================================================================
--- obuspa-10.0.0.2.orig/src/core/device.h
+++ obuspa-10.0.0.2/src/core/device.h
@@ -346,6 +346,10 @@ void DEVICE_CONTROLLER_SetInheritedRole(
--- obuspa-10.0.6.0.orig/src/core/device.h
+++ obuspa-10.0.6.0/src/core/device.h
@@ -355,6 +355,10 @@ void DEVICE_CONTROLLER_SetInheritedRole(
int DEVICE_CONTROLLER_CountEnabledWebsockClientConnections(void);
#endif
@@ -13,11 +13,11 @@ Index: obuspa-10.0.0.2/src/core/device.h
#ifndef REMOVE_USP_BROKER
int DEVICE_SUBSCRIPTION_RouteNotification(Usp__Msg *usp, int instance, char *subscribed_path);
bool DEVICE_SUBSCRIPTION_MarkVendorLayerSubs(int broker_instance, subs_notify_t notify_type, char *path, int group_id);
Index: obuspa-10.0.0.2/src/core/device_controller.c
Index: obuspa-10.0.6.0/src/core/device_controller.c
===================================================================
--- obuspa-10.0.0.2.orig/src/core/device_controller.c
+++ obuspa-10.0.0.2/src/core/device_controller.c
@@ -968,6 +968,78 @@ int DEVICE_CONTROLLER_QueueBinaryMessage
--- obuspa-10.0.6.0.orig/src/core/device_controller.c
+++ obuspa-10.0.6.0/src/core/device_controller.c
@@ -969,6 +969,78 @@ int DEVICE_CONTROLLER_QueueBinaryMessage
return USP_ERR_OK;
}
@@ -96,11 +96,11 @@ Index: obuspa-10.0.0.2/src/core/device_controller.c
/*********************************************************************//**
**
** DEVICE_CONTROLLER_IsMTPConfigured
Index: obuspa-10.0.0.2/src/core/msg_handler.c
Index: obuspa-10.0.6.0/src/core/msg_handler.c
===================================================================
--- obuspa-10.0.0.2.orig/src/core/msg_handler.c
+++ obuspa-10.0.0.2/src/core/msg_handler.c
@@ -1220,6 +1220,15 @@ int ValidateUspRecord(UspRecord__Record
--- obuspa-10.0.6.0.orig/src/core/msg_handler.c
+++ obuspa-10.0.6.0/src/core/msg_handler.c
@@ -1344,6 +1344,15 @@ int ValidateUspRecord(UspRecord__Record
usp_service_instance = USP_BROKER_GetUspServiceInstance(rec->from_id, 0);
#endif

View File

@@ -1,8 +1,8 @@
Index: obuspa-10.0.0.1/src/core/mqtt.c
Index: obuspa-10.0.6.0/src/core/mqtt.c
===================================================================
--- obuspa-10.0.0.1.orig/src/core/mqtt.c
+++ obuspa-10.0.0.1/src/core/mqtt.c
@@ -259,6 +259,8 @@ void MqttSubscriptionDestroy(mqtt_subscr
--- obuspa-10.0.6.0.orig/src/core/mqtt.c
+++ obuspa-10.0.6.0/src/core/mqtt.c
@@ -265,6 +265,8 @@ void SaveMqttPublishErrMsg(const char *f
#define DEFINE_MQTT_TrustCertVerifyCallbackIndex(index) \
int MQTT_TrustCertVerifyCallback_##index (int preverify_ok, X509_STORE_CTX *x509_ctx) \
{\
@@ -11,7 +11,7 @@ Index: obuspa-10.0.0.1/src/core/mqtt.c
return DEVICE_SECURITY_TrustCertVerifyCallbackWithCertChain(preverify_ok, x509_ctx, &mqtt_clients[index].cert_chain);\
}
@@ -269,6 +271,11 @@ DEFINE_MQTT_TrustCertVerifyCallbackIndex
@@ -275,6 +277,11 @@ DEFINE_MQTT_TrustCertVerifyCallbackIndex
DEFINE_MQTT_TrustCertVerifyCallbackIndex(2);
DEFINE_MQTT_TrustCertVerifyCallbackIndex(3);
DEFINE_MQTT_TrustCertVerifyCallbackIndex(4);
@@ -23,7 +23,7 @@ Index: obuspa-10.0.0.1/src/core/mqtt.c
// Add more, with incrementing indexes here, if you change MAX_MQTT_CLIENTS
//------------------------------------------------------------------------------------
@@ -279,10 +286,15 @@ ssl_verify_callback_t* mqtt_verify_callb
@@ -285,10 +292,15 @@ ssl_verify_callback_t* mqtt_verify_callb
MQTT_TrustCertVerifyCallbackIndex(2),
MQTT_TrustCertVerifyCallbackIndex(3),
MQTT_TrustCertVerifyCallbackIndex(4),

View File

@@ -1,7 +1,7 @@
diff --git a/src/core/mqtt.c b/src/core/mqtt.c
index 70978501b1..96119fe080 100644
--- a/src/core/mqtt.c
+++ b/src/core/mqtt.c
Index: obuspa-10.0.7.0/src/core/mqtt.c
===================================================================
--- obuspa-10.0.7.0.orig/src/core/mqtt.c
+++ obuspa-10.0.7.0/src/core/mqtt.c
@@ -53,6 +53,7 @@
#include <openssl/bio.h>
#include <openssl/err.h>
@@ -10,7 +10,7 @@ index 70978501b1..96119fe080 100644
#include <mosquitto.h>
#include "mqtt.h"
@@ -201,8 +202,9 @@ int EnableMosquitto(mqtt_client_t *client);
@@ -206,8 +207,9 @@ int EnableMosquitto(mqtt_client_t *clien
void SetupCallbacks(mqtt_client_t *client);
void QueueUspConnectRecord_MQTT(mqtt_client_t *client, mtp_send_item_t *msi, char *controller_topic, time_t expiry_time);
int SendQueueHead(mqtt_client_t *client);
@@ -21,7 +21,7 @@ index 70978501b1..96119fe080 100644
int ConnectSetEncryption(mqtt_client_t *client);
void ConnectCallback(struct mosquitto *mosq, void *userdata, int result);
void ConnectV5Callback(struct mosquitto *mosq, void *userdata, int result, int flags, const mosquitto_property *props);
@@ -245,7 +247,7 @@ void HandleMqttReconnect(mqtt_client_t *client);
@@ -250,7 +252,7 @@ void HandleMqttReconnect(mqtt_client_t *
void HandleMqttReconnectAfterDisconnect(mqtt_client_t *client);
void HandleMqttDisconnect(mqtt_client_t *client);
void DisconnectIfAllSubscriptionsFailed(mqtt_client_t *client);
@@ -30,7 +30,7 @@ index 70978501b1..96119fe080 100644
void RemoveMqttQueueItem(mqtt_client_t *client, mqtt_send_item_t *queued_msg);
void RemoveExpiredMqttMessages(mqtt_client_t *client);
void ParseSubscribeTopicsFromConnack(mqtt_client_t *client, mosquitto_property *prop);
@@ -2350,6 +2352,143 @@ int SendQueueHead(mqtt_client_t *client)
@@ -2380,6 +2382,143 @@ int SendQueueHead(mqtt_client_t *client)
return err;
}
@@ -174,7 +174,7 @@ index 70978501b1..96119fe080 100644
/*********************************************************************//**
**
** IsMqttBrokerUp
@@ -2364,109 +2503,92 @@ int SendQueueHead(mqtt_client_t *client)
@@ -2394,109 +2533,92 @@ int SendQueueHead(mqtt_client_t *client)
** \return true if the MQTT Broker is up, false otherwise
**
**************************************************************************/
@@ -343,7 +343,7 @@ index 70978501b1..96119fe080 100644
}
return result;
@@ -2487,18 +2609,20 @@ void Connect(mqtt_client_t *client)
@@ -2517,18 +2639,20 @@ void Connect(mqtt_client_t *client)
{
int err = USP_ERR_OK;
bool is_up;
@@ -367,7 +367,7 @@ index 70978501b1..96119fe080 100644
// Exit if failed to connect
if (err != USP_ERR_OK)
@@ -2531,7 +2655,7 @@ exit:
@@ -2561,7 +2685,7 @@ exit:
** \return USP_ERR_INTERNAL_ERROR if failed to connect (and should retry)
**
**************************************************************************/
@@ -376,7 +376,7 @@ index 70978501b1..96119fe080 100644
{
int version;
mosquitto_property *proplist = NULL;
@@ -2601,19 +2725,19 @@ int PerformMqttClientConnect(mqtt_client_t *client)
@@ -2631,19 +2755,19 @@ int PerformMqttClientConnect(mqtt_client
// We do this to prevent the data model thread from potentially being blocked, whilst the connect call is taking place
OS_UTILS_UnlockMutex(&mqtt_access_mutex);

View File

@@ -97,15 +97,13 @@ packet_capture_launch() {
fi
if [ -n "${interface}" ]; then
intf=$(ifstatus "${interface}" | jq ".l3_device")
intf=$(ifstatus "${interface}" | jsonfilter -e '$.l3_device')
if [ -z "${intf}" ]; then
# Error
packet_capture_error "Error_Internal" "${proto}"
return
fi
intf=$(eval echo "${intf}")
fi
cmd="timeout ${duration} tcpdump -w ${filename}"

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=parental-control
PKG_VERSION:=1.3.1
PKG_VERSION:=1.3.2
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:=b1e5b3f81f08271bdaf9cb4bda8a7696a27be3c6
PKG_SOURCE_VERSION:=7ae6eaa6cc946ed05693bc84c61edbb16b1727bd
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -48,7 +48,7 @@ configure_fw_rules() {
hw_nat -! > /dev/null 2>&1
fi
if which conntrack > /dev/null 2>&1; then
conntrack -F > /dev/null 2>&1
flush_conntrack_for_hosts
fi
# this is for urlfilter daemon

View File

@@ -551,6 +551,62 @@ remove_internet_schedule_rules() {
fi
}
# Global array for resolved IPs
URLFILTER_IPS=""
# Resolve hostname or MAC to IP from lease_file
get_host_ip() {
local host="$1"
local ip
local lease_file="/tmp/dhcp.leases"
[ -f "$lease_file" ] || lease_file="/etc/parentalcontrol/dhcp.leases"
[ -f "$lease_file" ] || { log "Error: get_host_ip(): No DHCP lease file found."; return 1; }
# try DHCP lease lookup
ip="$(awk -v h="$host" '
{
mac=$2; ipaddr=$3; name=$4
if (h == name || h == mac) { print ipaddr; exit }
}' "$lease_file")"
[ -n "$ip" ] && URLFILTER_IPS="$URLFILTER_IPS $ip"
}
# Process each profile section
resolve_profile_hosts() {
local section="$1"
local hostlist
config_get hostlist "$section" host
[ -z "$hostlist" ] && return
for h in $hostlist; do
get_host_ip "$h"
done
}
# Main function to collect IPs and delete conntrack entries
flush_conntrack_for_hosts() {
URLFILTER_IPS=""
local count max
config_foreach resolve_profile_hosts profile
URLFILTER_IPS="$(echo "$URLFILTER_IPS" | tr ' ' '\n' | sort -u | xargs)"
for ip in $URLFILTER_IPS; do
count=0
max=1000
while conntrack -D -s "$ip" >/dev/null 2>&1; do
count=$((count+1))
if [ $count -ge $max ]; then
log "Warning: Forced to stop conntrack delete after $max deletions for $ip (possible loop)"
break
fi
done
done
}
OVERRIDE_JSON="/etc/parentalcontrol/urlbundle_override.json"
DM_PLUGIN_PATH="/usr/share/bbfdm/micro_services/parentalcontrol/urlbundle_override.json"

View File

@@ -39,9 +39,6 @@ define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/usr/lib/security
$(INSTALL_BIN) $(PKG_BUILD_DIR)/pam_passwdqc.so $(1)/usr/lib/security/
$(INSTALL_DIR) $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/passwdqc.uci_default $(1)/etc/uci-defaults/99-add_passwdqc_pam
endef
$(eval $(call BuildPackage,$(PKG_NAME)))

View File

@@ -1,19 +0,0 @@
#!/bin/sh
CONFIG_FILE="/etc/pam.d/common-password"
# for some reason setting to 8 makes passwdqc accept minimum 12 letter password with this configuration
# if we set it to 12 then we need atleast 16 characters and so on
# passphrase = 0 means no space separated words
# rest can be figured out from passwdqc man page
MODULE_LINE="password requisite pam_passwdqc.so min=disabled,disabled,disabled,disabled,8 max=20 passphrase=0 retry=3 enforce=everyone"
# Ensure the file exists before modifying
[ -f "$CONFIG_FILE" ] || exit 0
# Check if pam_passwdqc is already in the file
if ! grep -q "pam_passwdqc.so" "$CONFIG_FILE"; then
# Insert before pam_unix.so
sed -i "/pam_unix.so/ i\\$MODULE_LINE" "$CONFIG_FILE"
fi
exit 0

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=periodicstats
PKG_VERSION:=1.5.18
PKG_VERSION:=1.6.0
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/periodicstats.git
PKG_SOURCE_VERSION:=2772d77bd477adfdf513499fda11397107996d21
PKG_SOURCE_VERSION:=63c65f55d00442f5bc1f5a3100abf94e52cd0075
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -1,60 +0,0 @@
#
# Copyright (C) 2019 iopsys
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=peripheral_manager
PKG_VERSION:=1.0.6
PKG_RELEASE:=1
PKG_SOURCE_VERSION:=21522c2003b8c61904acc61ff97e54fc9b0c3c92
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/peripheral-manager
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_RELEASE)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=GPLv2
PKG_LICENSE_FILES:=LICENSE
# support parallel build
PKG_BUILD_PARALLEL:=1
# run install target when cross compiling. basically, make install DESTDIR=$(PKG_INSTALL_DIR)
# this way we don't need to pick out the resulting files from the build dir.
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
define Package/peripheral_manager
CATEGORY:=Utilities
TITLE:=Application deamon for handling of peripheral
URL:=
DEPENDS:=+libuci +libubus +libblobmsg-json
endef
define Package/peripheral_manager/description
Application handling peripheral
endef
CMAKE_OPTIONS += \
-DCMAKE_BUILD_TYPE:String="Release" \
define Package/peripheral_manager/install
$(CP) ./files/* $(1)/
$(INSTALL_DIR) $(1)/etc/
$(INSTALL_DIR) $(1)/etc/init.d/
$(INSTALL_DIR) $(1)/sbin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/peripheral_manager $(1)/sbin/
# $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpio_test $(1)/sbin/
endef
$(eval $(call BuildPackage,peripheral_manager))

View File

@@ -1,62 +0,0 @@
#!/bin/sh /etc/rc.common
START=20
USE_PROCD=1
setled() {
local enable
local brightness
config_get_bool enable $1 enable 1
config_get brightness $1 brightness 100
ubus call led.$1 set "{\"enable\":$enable,\"brightness\":$brightness}"
}
start_service() {
local enable
config_load leds
config_foreach setled led
config_get_bool enable leds enable 1
if [ "$enable" == "0" ]; then
ubus call leds set '{"state" : "alloff"}'
else
ubus call leds set '{"state" : "normal"}'
fi
}
boot() {
local led ledname
ubus list led* >/dev/null || sleep 1
ubus list led* >/dev/null || sleep 1
[ -f /etc/config/leds ] || touch /etc/config/leds
if ! uci -q get leds.leds >/dev/null; then
uci set leds.leds=leds
uci set leds.leds.enable=1
fi
for led in $(ubus list led.*); do
ledname=${led:4}
case $ledname in
*phy*) continue ;;
esac
if ! uci -q get leds.$ledname >/dev/null; then
uci set leds.$ledname=led
uci set leds.$ledname.enable=1
fi
done
uci commit leds
start
}
service_triggers()
{
procd_add_reload_trigger "leds"
}

View File

@@ -1,25 +0,0 @@
#!/bin/sh /etc/rc.common
START=12
STOP=89
USE_PROCD=1
NAME=peripheral_manager
PROG=/sbin/peripheral_manager
start_service() {
procd_open_instance
procd_set_param command "$PROG" -f
procd_set_param respawn
procd_close_instance
}
service_running() {
ubus -t 2 wait_for led.status
ubus call led.status set '{"state":"notice"}'
ubus -t 2 wait_for buttons
}
stop_service() {
ubus call leds set '{"state":"alloff"}'
}

View File

@@ -1,19 +0,0 @@
#!/bin/sh
usage () {
echo "Usage: ledctl [normal|test|allon|alloff|production]"
exit 1
}
[ $# -ne 1 ] && usage
ledstate=$(echo $1 | tr 'A-Z' 'a-z')
case $ledstate in
normal|test|allon|alloff|production)
ubus call leds set "{\"state\" : \"$ledstate\"}"
;;
*)
usage
;;
esac

View File

@@ -114,6 +114,7 @@ hw_init_all() {
export TMP_HW_QUEUE_LIST=""
echo clear > /proc/ifc_debug
echo reinit > /proc/ifc_debug
echo 'set mode 0 2' 2> /dev/null > /proc/tc3162/fe_acnt_mapping # Accounter #2 is used for meter #0, so we need re-assign IP flow accounting mode (mode 0) to #2.
for tc in $(seq 0 7); do
rm -rf "/tmp/qos/dscp_values_${tc}_4"
@@ -434,6 +435,4 @@ hw_commit_all() {
/userfs/bin/ifc add vip pbit $pbit
done
fi
hw_nat -! > /dev/null 2>&1
}

View File

@@ -98,7 +98,7 @@ handle_policer() {
# Configure policer based on UCI subtree 'qos.policer'
configure_policer() {
# initialize ratelimit params
/userfs/bin/femgr ratelimit set rx_mode 1 2
/userfs/bin/femgr ratelimit set rx_mode 1 2 0
/userfs/bin/qdmamgr_wan set general_rx_init enable trtcm 8 125
for intf in $(jsonfilter -i /etc/board.json -e @.network.lan.ports[*] -e @.network.lan.device -e @.network.wan.device | xargs); do

View File

@@ -22,10 +22,6 @@ ip_rule_get_converted_tos() {
echo $con_tos
}
flush_hw_nat() {
hw_nat -! > /dev/null 2>&1
}
configure_qos() {
# queue configuration is being done after shaper configuration,
# If port shapingrate configuration on DISC device is called after queue configuration then
@@ -37,9 +33,8 @@ configure_qos() {
configure_policer
configure_classify
if [ -f "/tmp/qos/classify.ebtables" ]; then
sh /tmp/qos/classify.ebtables
sh /tmp/qos/classify.ebtables
fi
flush_hw_nat
}
reload_qos() {
@@ -70,7 +65,6 @@ reload_qos() {
;;
esac
hw_commit_all
flush_hw_nat
}
reload_qos_service() {

View File

@@ -42,7 +42,7 @@ handle_shaper() {
# Configure shaper based on options saved to UCI tree 'qos.shaper'
configure_shaper() {
# initialize ratelimit params
/userfs/bin/femgr ratelimit set rx_mode 0 2
/userfs/bin/femgr ratelimit set rx_mode 0 2 0
/userfs/bin/qdmamgr_lan set general_rx_init enable trtcm 8 125
# Delete existing shaper

View File

@@ -14,13 +14,11 @@ PREV_LINKSPEED=$(cat ${LINKSPEED_FILE} 2>/dev/null)
[ -z "${PREV_LINKSPEED}" ] && PREV_LINKSPEED=0
if [ $((LINKSPEED)) -ne $((PREV_LINKSPEED)) -a $((LINKSPEED)) -ne 0 ]; then
if [ $((LINKSPEED)) -ge 100 ]; then
if [ $((LINKSPEED)) -ge 10000 ]; then
/userfs/bin/qosrule discpline Rate uplink-bandwidth $((LINKSPEED*1000*999/1000))
else
/userfs/bin/qosrule discpline Rate uplink-bandwidth $((LINKSPEED*1000*990/1000))
/userfs/bin/qosrule discpline Rate uplink-bandwidth $((LINKSPEED*1000))
fi
mkdir -p "/tmp/qos"
echo ${LINKSPEED} > ${LINKSPEED_FILE}
hw_nat -! > /dev/null 2>&1
fi

View File

@@ -5,8 +5,8 @@ PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/bellard/quickjs.git
PKG_SOURCE_DATE:=2022-03-06
PKG_SOURCE_VERSION:=2788d71e823b522b178db3b3660ce93689534e6d
PKG_SOURCE_DATE:=2025-07-09
PKG_SOURCE_VERSION:=1fdc768fdc8571300755cdd3e4654ce99c0255ce
PKG_MIRROR_HASH:=skip
PKG_LICENSE:=MIT
@@ -31,15 +31,30 @@ define Package/quickjs/description
endef
MAKE_FLAGS = \
prefix=/usr \
CONFIG_SMALL=y \
PREFIX=/usr \
EXTRA_LIBS="-latomic" \
CROSS_PREFIX="$(TARGET_CROSS)"
define Build/Compile
# The upstream Makefile uses the same CFLAGS for host and target builds,
# which breaks cross-compilation. We work around this by first building
# the host tools ('host-qjsc', 'unicode_gen') with the host compiler
# and flags.
# We still pass MAKE_FLAGS so the upstream Makefile knows we're cross-compiling.
CFLAGS="$(HOST_CFLAGS)" \
LDFLAGS="$(HOST_LDFLAGS)" \
$(MAKE) -C $(PKG_BUILD_DIR) \
$(MAKE_FLAGS) \
host-qjsc unicode_gen
# Then we proceed with the default build process for the target binaries.
# Make should not rebuild the host tools as they are already up-to-date.
$(call Build/Compile/Default)
endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/lib/quickjs
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/quickjs/libquickjs.a $(1)/usr/lib/
$(CP) $(PKG_INSTALL_DIR)/usr/lib/quickjs/libquickjs.lto.a $(1)/usr/lib/
$(INSTALL_DIR) $(1)/usr/include/quickjs
$(CP) $(PKG_INSTALL_DIR)/usr/include/quickjs/quickjs.h $(1)/usr/include/quickjs/
$(CP) $(PKG_INSTALL_DIR)/usr/include/quickjs/quickjs-libc.h $(1)/usr/include/quickjs/

View File

@@ -1,87 +0,0 @@
diff --git a/Makefile b/Makefile
index 49b1f6f..2c96eae 100644
--- a/Makefile
+++ b/Makefile
@@ -33,6 +33,8 @@ CONFIG_LTO=y
#CONFIG_WERROR=y
# force 32 bit build for some utilities
#CONFIG_M32=y
+# build with -Os instead of -O2
+#CONFIG_SMALL=y
ifdef CONFIG_DARWIN
# use clang instead of gcc
@@ -52,6 +54,13 @@ CONFIG_BIGNUM=y
OBJDIR=.obj
+CFLAGS_ENV:=$(CFLAGS)
+LDFLAGS_ENV:=$(LDFLAGS)
+
+HOST_BUILD=
+CFLAGS=$(if $(HOST_BUILD),,$(CFLAGS_ENV))
+LDFLAGS=$(if $(HOST_BUILD),,$(LDFLAGS_ENV))
+
ifdef CONFIG_WIN32
ifdef CONFIG_M32
CROSS_PREFIX=i686-w64-mingw32-
@@ -66,7 +75,7 @@ endif
ifdef CONFIG_CLANG
HOST_CC=clang
CC=$(CROSS_PREFIX)clang
- CFLAGS=-g -Wall -MMD -MF $(OBJDIR)/$(@F).d
+ CFLAGS += -g -Wall -MMD -MF $(OBJDIR)/$(@F).d
CFLAGS += -Wextra
CFLAGS += -Wno-sign-compare
CFLAGS += -Wno-missing-field-initializers
@@ -87,7 +96,7 @@ ifdef CONFIG_CLANG
else
HOST_CC=gcc
CC=$(CROSS_PREFIX)gcc
- CFLAGS=-g -Wall -MMD -MF $(OBJDIR)/$(@F).d
+ CFLAGS += -g -Wall -MMD -MF $(OBJDIR)/$(@F).d
CFLAGS += -Wno-array-bounds -Wno-format-truncation
ifdef CONFIG_LTO
AR=$(CROSS_PREFIX)gcc-ar
@@ -110,9 +119,13 @@ endif
CFLAGS+=$(DEFINES)
CFLAGS_DEBUG=$(CFLAGS) -O0
CFLAGS_SMALL=$(CFLAGS) -Os
+ifdef CONFIG_SMALL
+CFLAGS_OPT=$(CFLAGS) -Os
+else
CFLAGS_OPT=$(CFLAGS) -O2
+endif
CFLAGS_NOLTO:=$(CFLAGS_OPT)
-LDFLAGS=-g
+LDFLAGS+=-g
ifdef CONFIG_LTO
CFLAGS_SMALL+=-flto
CFLAGS_OPT+=-flto
@@ -195,6 +208,8 @@ qjsc$(EXE): $(OBJDIR)/qjsc.o $(QJS_LIB_OBJS)
ifneq ($(CROSS_PREFIX),)
+$(QJSC): HOST_BUILD=1
+
$(QJSC): $(OBJDIR)/qjsc.host.o \
$(patsubst %.o, %.host.o, $(QJS_LIB_OBJS))
$(HOST_CC) $(LDFLAGS) -o $@ $^ $(HOST_LIBS)
@@ -262,6 +277,8 @@ run-test262-32: $(patsubst %.o, %.m32.o, $(OBJDIR)/run-test262.o $(QJS_LIB_OBJS)
$(OBJDIR)/%.o: %.c | $(OBJDIR)
$(CC) $(CFLAGS_OPT) -c -o $@ $<
+$(OBJDIR)/%.host.o: HOST_BUILD=1
+
$(OBJDIR)/%.host.o: %.c | $(OBJDIR)
$(HOST_CC) $(CFLAGS_OPT) -c -o $@ $<
@@ -286,6 +303,8 @@ $(OBJDIR)/%.check.o: %.c | $(OBJDIR)
regexp_test: libregexp.c libunicode.c cutils.c
$(CC) $(LDFLAGS) $(CFLAGS) -DTEST -o $@ libregexp.c libunicode.c cutils.c $(LIBS)
+unicode_gen: HOST_BUILD=1
+
unicode_gen: $(OBJDIR)/unicode_gen.host.o $(OBJDIR)/cutils.host.o libunicode.c unicode_gen_def.h
$(HOST_CC) $(LDFLAGS) $(CFLAGS) -o $@ $(OBJDIR)/unicode_gen.host.o $(OBJDIR)/cutils.host.o

View File

@@ -1,15 +1,12 @@
diff --git a/quickjs-libc.c b/quickjs-libc.c
index e180dd0..76182d2 100644
index 54a7a15..a64c4d6 100644
--- a/quickjs-libc.c
+++ b/quickjs-libc.c
@@ -358,12 +358,89 @@ fail:
@@ -385,12 +385,86 @@ fail:
return JS_EXCEPTION;
}
+// For reading files that are not seekable, per second answer from stackoverflow:
+// https://stackoverflow.com/questions/14002954/c-programming-how-to-read-the-whole-file-contents-into-a-buffer
+
+#define READALL_CHUNK 10*1024
+#define READALL_CHUNK (10*1024)
+
+static int readall(FILE *f, JSContext *ctx, uint8_t **dataptr, size_t *sizeptr)
+{
@@ -90,10 +87,10 @@ index e180dd0..76182d2 100644
size_t buf_len;
- long lret;
+ long lret = 0;
f = fopen(filename, "rb");
if (!f)
@@ -371,7 +448,7 @@ uint8_t *js_load_file(JSContext *ctx, size_t *pbuf_len, const char *filename)
@@ -398,7 +472,7 @@ uint8_t *js_load_file(JSContext *ctx, size_t *pbuf_len, const char *filename)
if (fseek(f, 0, SEEK_END) < 0)
goto fail;
lret = ftell(f);
@@ -102,7 +99,7 @@ index e180dd0..76182d2 100644
goto fail;
/* XXX: on Linux, ftell() return LONG_MAX for directories */
if (lret == LONG_MAX) {
@@ -387,13 +464,19 @@ uint8_t *js_load_file(JSContext *ctx, size_t *pbuf_len, const char *filename)
@@ -414,13 +488,19 @@ uint8_t *js_load_file(JSContext *ctx, size_t *pbuf_len, const char *filename)
buf = malloc(buf_len + 1);
if (!buf)
goto fail;

View File

@@ -1,106 +0,0 @@
diff --git a/quickjs.c b/quickjs.c
index 7916013..3936eec 100644
--- a/quickjs.c
+++ b/quickjs.c
@@ -67,6 +67,16 @@
#define CONFIG_PRINTF_RNDN
#endif
+#ifdef CONFIG_PRINTF_RNDN
+#if !defined(FE_DOWNWARD) || !defined(FE_UPWARD)
+#ifdef CONFIG_BIGNUM
+#define CONFIG_DTOA_LIBBF
+#else
+#error "CONFIG_BIGNUM required if printf is RNDN and there is no fenv support"
+#endif
+#endif
+#endif
+
/* define to include Atomics.* operations which depend on the OS
threads */
#if !defined(EMSCRIPTEN)
@@ -11299,6 +11309,11 @@ static char *i64toa(char *buf_end, int64_t n, unsigned int base)
return q;
}
+/* maximum buffer size for js_dtoa */
+#define JS_DTOA_BUF_SIZE 128
+
+#ifndef CONFIG_DTOA_LIBBF
+
/* buf1 contains the printf result */
static void js_ecvt1(double d, int n_digits, int *decpt, int *sign, char *buf,
int rounding_mode, char *buf1, int buf1_size)
@@ -11318,9 +11333,6 @@ static void js_ecvt1(double d, int n_digits, int *decpt, int *sign, char *buf,
*decpt = atoi(buf1 + n_digits + 2 + (n_digits > 1)) + 1;
}
-/* maximum buffer size for js_dtoa */
-#define JS_DTOA_BUF_SIZE 128
-
/* needed because ecvt usually limits the number of digits to
17. Return the number of digits. */
static int js_ecvt(double d, int n_digits, int *decpt, int *sign, char *buf,
@@ -11429,6 +11441,8 @@ static void js_fcvt(char *buf, int buf_size, double d, int n_digits)
js_fcvt1(buf, buf_size, d, n_digits, rounding_mode);
}
+#endif /* CONFIG_DTOA_LIBBF */
+
/* radix != 10 is only supported with flags = JS_DTOA_VAR_FORMAT */
/* use as many digits as necessary */
#define JS_DTOA_VAR_FORMAT (0 << 0)
@@ -11442,8 +11456,10 @@ static void js_fcvt(char *buf, int buf_size, double d, int n_digits)
/* XXX: slow and maybe not fully correct. Use libbf when it is fast enough.
XXX: radix != 10 is only supported for small integers
*/
-static void js_dtoa1(char *buf, double d, int radix, int n_digits, int flags)
+static JSValue js_dtoa(JSContext *ctx,
+ double d, int radix, int n_digits, int flags)
{
+ char buf[JS_DTOA_BUF_SIZE];
char *q;
if (!isfinite(d)) {
@@ -11465,6 +11481,25 @@ static void js_dtoa1(char *buf, double d, int radix, int n_digits, int flags)
ptr = i64toa(buf1 + sizeof(buf1), i64, radix);
strcpy(buf, ptr);
} else {
+#ifdef CONFIG_DTOA_LIBBF
+ bf_flags_t bf_flags;
+ generic_conv:
+ bf_flags = BF_RNDNA;
+ switch (flags & 3) {
+ case JS_DTOA_VAR_FORMAT:
+ bf_flags |= BF_FTOA_FORMAT_FREE_MIN;
+ break;
+ case JS_DTOA_FIXED_FORMAT:
+ bf_flags |= BF_FTOA_FORMAT_FIXED;
+ break;
+ case JS_DTOA_FRAC_FORMAT:
+ bf_flags |= BF_FTOA_FORMAT_FRAC;
+ break;
+ }
+ if (flags & JS_DTOA_FORCE_EXP)
+ bf_flags |= BF_FTOA_FORCE_EXP;
+ return js_ftoa(ctx, JS_NewFloat64(ctx, d), radix, n_digits, bf_flags);
+#else /* CONFIG_DTOA_LIBBF */
if (d == 0.0)
d = 0.0; /* convert -0 to 0 */
if (flags == JS_DTOA_FRAC_FORMAT) {
@@ -11528,14 +11563,8 @@ static void js_dtoa1(char *buf, double d, int radix, int n_digits, int flags)
sprintf(q, "%d", p);
}
}
+#endif /* CONFIG_DTOA_LIBBF */
}
-}
-
-static JSValue js_dtoa(JSContext *ctx,
- double d, int radix, int n_digits, int flags)
-{
- char buf[JS_DTOA_BUF_SIZE];
- js_dtoa1(buf, d, radix, n_digits, flags);
return JS_NewString(ctx, buf);
}

View File

@@ -1,7 +1,7 @@
if PACKAGE_sshmngr
choice
prompt "Select backend for SSH management"
default SSHMNGR_BACKEND_OPENSSH
default SSHMNGR_BACKEND_OPENSSH_PAM
depends on PACKAGE_sshmngr
help
Select which backend daemon to use for SSH

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sshmngr
PKG_VERSION:=1.0.6
PKG_VERSION:=1.1.1
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/sshmngr.git
PKG_SOURCE_VERSION:=0c7d58a51d6f5eb4ad33e03630206bbb4e559779
PKG_SOURCE_VERSION:=dc0e3933231680aec844d587d49fefbc0cc7f8d7
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif

View File

@@ -5,11 +5,11 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sulu-base
PKG_VERSION:=5.1.2
PKG_VERSION:=5.1.1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/websdk/sulu.git
PKG_SOURCE_VERSION:=6ee43863415b54c312a56e113a7a91d5ae25df28
PKG_SOURCE_VERSION:=08195779cbc2d1d7410cb324b9e35692b0579a7e
PKG_MIRROR_HASH:=skip
SULU_MOD:=core

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sulu-builder
PKG_VERSION:=5.1.2
PKG_VERSION:=5.1.1
PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/websdk/sulu-builder.git
PKG_SOURCE_VERSION:=cca6a777e46584c888a1a06fafa75f7a063b803d
PKG_SOURCE_VERSION:=7f646ecf643967f4b4b2c545a31bbef0514b34bc
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 +userinterface +obuspa +sulu-vendorext
DEPENDS:=+mosquitto-auth-shadow +usermngr +userinterface +obuspa
DEPENDS+=+@OBUSPA_LOCAL_MQTT_LISTENER
EXTRA_DEPENDS:=nginx
endef
@@ -98,12 +98,8 @@ define Package/sulu/install/Default
$(INSTALL_DIR) $(1)/sulu/
$(INSTALL_DIR) $(1)/etc/sulu
$(INSTALL_DATA) ./files/maintenance.html $(1)/sulu/
$(LN) /tmp/sulu $(1)/sulu/connection
$(INSTALL_BIN) ./files/etc/sulu/sulu.sh $(1)/etc/sulu/
$(INSTALL_DATA) ./files/etc/sulu/nginx.locations $(1)/etc/sulu/
$(INSTALL_BIN) ./files/etc/sulu/sulu_watcher.sh $(1)/etc/sulu/
$(INSTALL_DIR) $(1)/etc/users/roles
$(INSTALL_DATA) ./files/etc/users/roles/*.json $(1)/etc/users/roles/
@@ -113,8 +109,6 @@ define Package/sulu/install/Default
ifneq ($(CONFIG_SULU_DEFAULT_UI)$(CONFIG_SULU_BUILDER_DEFAULT_UI),)
$(INSTALL_DATA) ./files/etc/uci-defaults/41-make-sulu-default-ui $(1)/etc/uci-defaults/
endif
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/etc/init.d/sulu $(1)/etc/init.d/
endef
define Package/sulu/install/Post

View File

@@ -1,15 +0,0 @@
#!/bin/sh /etc/rc.common
START=9
STOP=01
USE_PROCD=1
PROG=/etc/sulu/sulu_watcher.sh
start_service()
{
procd_open_instance "sulu"
procd_set_param command ${PROG}
procd_close_instance "sulu"
}

View File

@@ -8,10 +8,6 @@ location /sitemap.xml {
return 200 "User-agent: *\nDisallow: /\n";
}
location /maintenance.html {
internal;
}
location /wss {
proxy_pass_request_headers on;
proxy_cache off;
@@ -50,10 +46,7 @@ location / {
add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,Content-Type,Range' always;
add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range' always;
}
if (!-f $document_root/connection/ready) {
return 503;
}
add_header Cache-Control 'no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0';
add_header Pragma 'no-cache';
expires 0;
}

View File

@@ -1,29 +0,0 @@
#!/bin/sh
if ! command -v obuspa >/dev/null 2>&1; then
exit 0
fi
USP_PATH="/tmp/sulu/"
log() {
logger -t sulu_watcher "$*"
}
wait_for_obuspa() {
while true; do
ENDPOINTID="$(obuspa -c get Device.LocalAgent.EndpointID |grep Device.|awk '{print $3}')"
sleep 2
if [ -n "${ENDPOINTID}" ]; then
break;
fi
done
}
mark_usp_ready() {
mkdir -p "${USP_PATH}"
touch ${USP_PATH}/ready
}
wait_for_obuspa
mark_usp_ready

View File

@@ -51,7 +51,6 @@ add_sulu_userinterface_uci()
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 _nginx_error_page '503 /maintenance.html'
uci_set userinterface _sulu_s protocol 'HTTPS'
uci_add_list userinterface _sulu_s role 'admin'
uci_add_list userinterface _sulu_s role 'user'

View File

@@ -6,7 +6,554 @@
"permission": [
{
"object": "Device.",
"perm": ["PERMIT_ALL"]
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Reboot()",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.SelfTestDiagnostics()",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.FactoryReset()",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DeviceInfo.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Time.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.UPnP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Bridging.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Ethernet.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DHCPv4.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DHCPv4.Server.Pool.{i}.StaticAddress.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DHCPv6.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Hosts.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.{BBF_VENDOR_PREFIX}ParentalControl.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.{BBF_VENDOR_PREFIX}OpenVPN.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.NAT.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Firewall.",
"perm": [
"PERMIT_GET",
"PERMIT_OBJ_INFO",
"PERMIT_SET",
"PERMIT_SUBS_VAL_CHANGE"
]
},
{
"object": "Device.Firewall.DMZ.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.PPP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Routing.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.IEEE1905.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.InterfaceStack.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DynamicDNS.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LANConfigSecurity.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Security.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.RouterAdvertisement.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Services.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.UserInterface.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.PeriodicStatistics.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.SoftwareModules.",
"perm": ["PERMIT_NONE"]
},
{
"object": "Device.Users.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LocalAgent.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LocalAgent.Subscription.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.WiFi.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DNS.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.IP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.SSH.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LEDs.LED.{i}.CycleElement.{i}.Brightness",
"perm": ["PERMIT_GET", "PERMIT_SET", "PERMIT_GET_INST"]
}
]
}

View File

@@ -2,11 +2,533 @@
"tr181": {
"name": "user",
"instance": 5,
"secure_role": true,
"permission": [
{
"object": "Device.",
"perm": ["PERMIT_ALL"]
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Reboot()",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.SelfTestDiagnostics()",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.FactoryReset()",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DeviceInfo.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Time.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.UPnP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Bridging.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Ethernet.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DHCPv4.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DHCPv4.Server.Pool.{i}.StaticAddress.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DHCPv6.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Hosts.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.{BBF_VENDOR_PREFIX}ParentalControl.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.{BBF_VENDOR_PREFIX}OpenVPN.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.NAT.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Firewall.",
"perm": [
"PERMIT_GET",
"PERMIT_OBJ_INFO",
"PERMIT_SET",
"PERMIT_SUBS_VAL_CHANGE"
]
},
{
"object": "Device.Firewall.DMZ.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.PPP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Routing.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.IEEE1905.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.InterfaceStack.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DynamicDNS.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LANConfigSecurity.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Security.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.RouterAdvertisement.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.Services.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.UserInterface.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.PeriodicStatistics.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.SoftwareModules.",
"perm": ["PERMIT_NONE"]
},
{
"object": "Device.Users.User.",
"perm": ["PERMIT_NONE"]
},
{
"object": "Device.LocalAgent.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.LocalAgent.Subscription.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.WiFi.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.DNS.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_ADD",
"PERMIT_DEL",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.IP.",
"perm": [
"PERMIT_GET",
"PERMIT_GET_INST",
"PERMIT_OBJ_INFO",
"PERMIT_CMD_INFO",
"PERMIT_SET",
"PERMIT_OPER",
"PERMIT_SUBS_VAL_CHANGE",
"PERMIT_SUBS_OBJ_ADD",
"PERMIT_SUBS_OBJ_DEL",
"PERMIT_SUBS_EVT_OPER_COMP"
]
},
{
"object": "Device.SSH.",
"perm": ["PERMIT_NONE"]
},
{
"object": "Device.LEDs.LED.{i}.CycleElement.{i}.Brightness",
"perm": ["PERMIT_GET", "PERMIT_SET", "PERMIT_GET_INST"]
}
]
}

View File

@@ -1,248 +0,0 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Router Interface Loading...</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family:
-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu,
sans-serif;
background: linear-gradient(135deg, #3399ff 0%, #012669 100%);
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
color: #fff;
}
.container {
text-align: center;
padding: 2rem;
background: rgba(255, 255, 255, 0.1);
border-radius: 20px;
backdrop-filter: blur(10px);
box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
max-width: 400px;
width: 90%;
}
.spinner {
width: 60px;
height: 60px;
margin: 0 auto 2rem;
position: relative;
}
.spinner::before,
.spinner::after {
content: "";
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
border-radius: 50%;
border: 3px solid transparent;
border-top-color: #fff;
animation: spin 1.5s ease-in-out infinite;
}
.spinner::after {
animation-delay: 0.15s;
border-top-color: rgba(255, 255, 255, 0.5);
}
@keyframes spin {
0% {
transform: rotate(0deg);
}
100% {
transform: rotate(360deg);
}
}
h1 {
font-size: 1.8rem;
margin-bottom: 1rem;
font-weight: 600;
}
p {
font-size: 1rem;
opacity: 0.9;
line-height: 1.5;
margin-bottom: 1rem;
}
.status {
font-size: 0.9rem;
opacity: 0.8;
margin-top: 1.5rem;
display: flex;
align-items: center;
justify-content: center;
gap: 0.5rem;
}
.status-dot {
width: 8px;
height: 8px;
background: #fff;
border-radius: 50%;
animation: pulse 1.5s ease-in-out infinite;
}
@keyframes pulse {
0%,
100% {
opacity: 0.3;
}
50% {
opacity: 1;
}
}
.retry-count {
font-size: 0.85rem;
opacity: 0.7;
margin-top: 0.5rem;
}
.error-message {
background: rgba(255, 59, 48, 0.2);
border: 1px solid rgba(255, 59, 48, 0.5);
padding: 0.75rem;
border-radius: 8px;
margin-top: 1rem;
font-size: 0.9rem;
display: none;
}
</style>
</head>
<body>
<div class="container">
<div class="spinner"></div>
<h1>Router Starting Up</h1>
<p>
The web interface is initializing. You'll be redirected automatically
once it's ready.
</p>
<div class="status">
<span class="status-dot"></span>
<span id="statusText">Checking availability...</span>
</div>
<div class="retry-count" id="retryCount"></div>
<div class="error-message" id="errorMessage"></div>
</div>
<script>
let retryCount = 0;
let checkInterval = 2000; // Start with 2 seconds
let maxInterval = 10000; // Max 10 seconds between checks
let consecutiveFailures = 0;
let maxConsecutiveFailures = 100; // Stop after 100 consecutive failures (~8-10 minutes)
function updateStatus(message) {
document.getElementById("statusText").textContent = message;
}
function updateRetryCount() {
retryCount++;
const retryElement = document.getElementById("retryCount");
retryElement.textContent = `Attempt ${retryCount}`;
}
function showError(message) {
const errorElement = document.getElementById("errorMessage");
errorElement.textContent = message;
errorElement.style.display = "block";
}
async function checkAvailability() {
updateRetryCount();
updateStatus("Connecting to router...");
try {
// Try to fetch the index page
const response = await fetch("/index.html", {
method: "HEAD", // Use HEAD to minimize bandwidth
cache: "no-cache",
mode: "no-cors", // Allow checking even with CORS restrictions
});
// If we get any response (even 404), the server is responding
// For a router, we typically want to redirect on 200 or 304
if (response.ok || response.status === 304) {
updateStatus("Router ready! Redirecting...");
consecutiveFailures = 0;
// Small delay for user feedback
setTimeout(() => {
window.location.reload();
}, 500);
return true;
} else if (response.status !== 503) {
// Server is responding but page not ready yet
updateStatus(`Server responding (${response.status}), waiting...`);
consecutiveFailures = 0;
}
} catch (error) {
// Network error - server not reachable
consecutiveFailures++;
if (consecutiveFailures > maxConsecutiveFailures) {
updateStatus("Connection timeout");
showError(
"Unable to connect to router. Please check your connection and refresh this page.",
);
return true; // Stop checking
}
updateStatus("Router not ready yet...");
// Implement exponential backoff
if (consecutiveFailures > 5) {
checkInterval = Math.min(checkInterval * 1.2, maxInterval);
}
}
return false;
}
async function startChecking() {
// Initial check
const isReady = await checkAvailability();
if (isReady) return;
// Continue checking
const intervalId = setInterval(async () => {
const isReady = await checkAvailability();
if (isReady) {
clearInterval(intervalId);
}
}, checkInterval);
}
// Start checking when page loads
window.addEventListener("DOMContentLoaded", () => {
// Small initial delay to show the UI
setTimeout(startChecking, 500);
});
// Also try to check if user clicks anywhere on the page
document.addEventListener("click", () => {
checkAvailability();
});
</script>
</body>
</html>

View File

@@ -5,11 +5,11 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sulu-theme-genexis
PKG_VERSION:=5.1.2
PKG_VERSION:=5.1.1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/gnx/sulu-theme-genexis
PKG_SOURCE_VERSION:=bf58defd238eaf4d9e42df68942df2c8f7c4f136
PKG_SOURCE_VERSION:=69b72c2e589a3f73db3cb219ee7f59ab40b1bf48
PKG_MIRROR_HASH:=skip
include ../sulu-builder/sulu.mk

View File

@@ -1,39 +0,0 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=sulu-vendorext
PKG_VERSION:=0.0.1
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=none
include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/sulu-vendorext
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Adds sulu-vendorext extensions
endef
define Build/Compile
endef
define Package/sulu-vendorext/install
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_CWMP.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_extra_info.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_guest_wifi_5.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_mesh.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_voip.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_wan.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_guest_wifi_2_4.json $(1) sysmngr
$(BBFDM_INSTALL_MS_PLUGIN) ./extn/X_GENEXIS_EU_firewall.json $(1) firewallmngr
$(CP) ./files/* $(1)/
endef
$(eval $(call BuildPackage,sulu-vendorext))

View File

@@ -1,140 +0,0 @@
{
"Device.DeviceInfo.X_GENEXIS_EU.": {
"type": "object",
"version": "1.00",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"is_primary_node": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": false,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "routeragent"
},
"option": {
"name": "is_master"
}
}
}
]
},
"meshmode": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "ubus",
"ubus": {
"object": "meshmode",
"method": "status",
"key": "mode"
}
},
{
"rpc": "set",
"type": "ubus",
"ubus": {
"object": "meshmode",
"method": "change_meshmode",
"args": {
"mode": "@Value"
}
}
}
]
},
"wizardHasBeenUsed": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "settings"
},
"option": {
"name": "wizard_executed"
}
}
}
]
},
"LocalTimeZone": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "system",
"section": {
"name": "@system[0]"
},
"option": {
"name": "timezone"
}
}
}
]
},
"LocalTimeZoneName": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "system",
"section": {
"name": "@system[0]"
},
"option": {
"name": "zonename"
}
}
}
]
}
}
}

View File

@@ -1,182 +0,0 @@
{
"Device.DeviceInfo.X_GENEXIS_EU.CWMPManagementServer.": {
"type": "object",
"protocols": [
"usp"
],
"access": false,
"array": false,
"dependency": "file:/etc/config/cwmp",
"EnableCWMP": {
"type": "boolean",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "cpe"
},
"option": {
"name": "enable"
}
}
}
]
},
"log_to_console": {
"type": "boolean",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "cpe"
},
"option": {
"name": "log_to_console"
}
}
}
]
}
},
"Device.DeviceInfo.X_GENEXIS_EU.CWMPManagementServer.acs.": {
"type": "object",
"version": "2.15",
"protocols": [
"usp"
],
"access": false,
"array": false,
"dependency": "file:/etc/config/cwmp",
"url": {
"type": "string",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "acs"
},
"option": {
"name": "url"
}
}
}
]
},
"userid": {
"type": "string",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "acs"
},
"option": {
"name": "userid"
}
}
}
]
},
"password": {
"type": "string",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "acs"
},
"option": {
"name": "passwd"
}
}
}
]
},
"periodic_interval_enable": {
"type": "boolean",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "acs"
},
"option": {
"name": "periodic_inform_enable"
}
}
}
]
},
"periodic_inform_interval": {
"type": "int",
"version": "2.15",
"read": true,
"write": true,
"protocols": [
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "cwmp",
"section": {
"name": "acs"
},
"option": {
"name": "periodic_inform_interval"
}
}
}
]
}
}
}

View File

@@ -1,180 +0,0 @@
{
"Device.DeviceInfo.X_GENEXIS_EU.external_info.": {
"type": "object",
"version": "1.00",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"support_link": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "support_link"
}
}
}
]
},
"faq_link": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "faq_link"
}
}
}
]
},
"contact_link": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "contact_link"
}
}
}
]
},
"contact_phone": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "contact_phone"
}
}
}
]
},
"contact_times": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "contact_times"
}
}
}
]
},
"livechat_link": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "livechat_link"
}
}
}
]
},
"extra_info": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "heimgard",
"section": {
"name": "help_support"
},
"option": {
"name": "extra_info"
}
}
}
]
}
}
}

View File

@@ -1,723 +0,0 @@
{
"Device.Firewall.X_GENEXIS_EU.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"Mode": {
"type": "string",
"enumerations": [
"Low",
"low",
"Medium",
"medium",
"High",
"high",
"Custom",
"custom"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"rpc": "get",
"type": "ubus",
"ubus": {
"object": "firewall_mode",
"method": "get",
"key": "mode"
}
},
{
"rpc": "set",
"type": "ubus",
"ubus": {
"object": "firewall_mode",
"method": "set",
"args": {
"mode": "@Value"
}
}
}
]
},
"Input": {
"type": "string",
"enumerations": [
"ACCEPT",
"REJECT",
"DROP"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"name": "@defaults[0]"
},
"option": {
"name": "input"
}
}
}
]
},
"Forward": {
"type": "string",
"enumerations": [
"ACCEPT",
"REJECT",
"DROP"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"name": "@defaults[0]"
},
"option": {
"name": "forward"
}
}
}
]
},
"Output": {
"type": "string",
"enumerations": [
"ACCEPT",
"REJECT",
"DROP"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"name": "@defaults[0]"
},
"option": {
"name": "output"
}
}
}
]
},
"Drop_invalid": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"name": "@defaults[0]"
},
"option": {
"name": "drop_invalid"
}
}
}
]
},
"Synflood_protect": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"name": "@defaults[0]"
},
"option": {
"name": "synflood_protect"
}
}
}
]
},
"ZoneNumberOfEntries": {
"type": "unsignedInt",
"protocols": [
"cwmp",
"usp"
],
"read": true,
"write": false,
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone"
},
"option": {
"name": "@Count"
}
}
}
]
},
"Device.Firewall.X_GENEXIS_EU.Zone.{i}.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": true,
"array": true,
"mapping": {
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone"
},
"dmmapfile": "dmmap_firewall"
}
},
"Name": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "name"
}
}
}
]
},
"Network": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"list": {
"datatype": "string"
},
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "network"
}
}
}
]
},
"Masq": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "masq"
}
}
}
]
},
"Masq_src": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"list": {
"datatype": "string"
},
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "masq_src"
}
}
}
]
},
"Masq_dest": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"list": {
"datatype": "string"
},
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "masq_dest"
}
}
}
]
},
"Masq_allow_invalid": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "masq_allow_invalid"
}
}
}
]
},
"Mtu_fix": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"description": "MSS clamping",
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "mtu_fix"
}
}
}
]
},
"Input": {
"type": "string",
"enumerations": [
"ACCEPT",
"REJECT",
"DROP"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "input"
}
}
}
]
},
"Forward": {
"type": "string",
"enumerations": [
"ACCEPT",
"REJECT",
"DROP"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "forward"
}
}
}
]
},
"Output": {
"type": "string",
"enumerations": [
"ACCEPT",
"REJECT",
"DROP"
],
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "output"
}
}
}
]
},
"Family": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "family"
}
}
}
]
},
"Log": {
"type": "unsignedInt",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "unsignedInt",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "log"
}
}
}
]
},
"Device": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"list": {
"datatype": "string"
},
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "device"
}
}
}
]
},
"Subnet": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"list": {
"datatype": "string"
},
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "subnet"
}
}
}
]
},
"Auto_helper": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "zone",
"index": "@i-1"
},
"option": {
"name": "auto_helper"
}
}
}
]
}
},
"ForwardingNumberOfEntries": {
"type": "unsignedInt",
"protocols": [
"cwmp",
"usp"
],
"read": true,
"write": false,
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "forwarding"
},
"option": {
"name": "@Count"
}
}
}
]
},
"Device.Firewall.X_GENEXIS_EU.Forwarding.{i}.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": true,
"array": true,
"mapping": {
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "forwarding"
},
"dmmapfile": "dmmap_firewall"
}
},
"Src": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "forwarding",
"index": "@i-1"
},
"option": {
"name": "src"
}
}
}
]
},
"Dest": {
"type": "string",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "firewall",
"section": {
"type": "forwarding",
"index": "@i-1"
},
"option": {
"name": "dest"
}
}
}
]
}
}
}
}

View File

@@ -1,168 +0,0 @@
{
"Device.DeviceInfo.X_GENEXIS_EU.guest2.": {
"type": "object",
"version": "1.00",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"ssid": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "ssid"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "ssid"
}
}
}
]
},
"encryption": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "encryption"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "encryption"
}
}
}
]
},
"key": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "key"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "key"
}
}
}
]
},
"enabled": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "enabled"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest2"
},
"option": {
"name": "enabled"
}
}
}
]
}
}
}

View File

@@ -1,167 +0,0 @@
{
"Device.DeviceInfo.X_GENEXIS_EU.guest5.": {
"type": "object",
"version": "1.00",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"ssid": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "ssid"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "ssid"
}
}
}
]
},
"encryption": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "encryption"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "encryption"
}
}
}
]
},
"key": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "key"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "key"
}
}
}
]
},
"enabled": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "enabled"
}
}
},
{
"rpc": "set",
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "guest5"
},
"option": {
"name": "enabled"
}
}
}
]
}
}
}

View File

@@ -1,416 +0,0 @@
{
"Device.DeviceInfo.X_GENEXIS_EU_mesh.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": false,
"array": false,
"meshmode": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"rpc": "get",
"type": "ubus",
"ubus": {
"object": "meshmode",
"method": "status",
"key": "mode"
}
},
{
"rpc": "set",
"type": "ubus",
"ubus": {
"object": "meshmode",
"method": "change_meshmode",
"args": {
"mode": "@Value"
}
}
}
]
},
"easymesh_controller_enabled": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"default": true,
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "controller"
},
"option": {
"name": "enabled"
}
}
}
]
},
"enable_sta_steer": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "@sta_steering[0]"
},
"option": {
"name": "enable_sta_steer"
}
}
}
]
},
"use_bcn_metrics": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "@sta_steering[0]"
},
"option": {
"name": "use_bcn_metrics"
}
}
}
]
},
"sta_steering_enabled": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"name": "@sta_steering[0]"
},
"option": {
"name": "enabled"
}
}
}
]
},
"ApNumberOfEntries": {
"type": "unsignedInt",
"protocols": [
"cwmp",
"usp"
],
"read": true,
"write": false,
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap"
},
"option": {
"name": "@Count"
}
}
}
]
},
"Device.DeviceInfo.X_GENEXIS_EU_mesh.ap.{i}.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": true,
"array": true,
"mapping": {
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap"
},
"dmmapfile": "dmmap_mapcontroller"
}
},
"ssid": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "ssid"
}
}
}
]
},
"band": {
"type": "unsignedInt",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"enumerations": [
"2",
"5",
"6"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "band"
}
}
}
]
},
"encryption": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"enumerations": [
"sae",
"sae+aes",
"psk2",
"psk2+aes",
"sae-mixed",
"sae-mixed+aes",
"none",
"psk-mixed",
"psk-mixed+aes",
"psk",
"psk+aes"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "encryption"
}
}
}
]
},
"key": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "key"
}
}
}
]
},
"vid": {
"type": "unsignedInt",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "vid"
}
}
}
]
},
"ap_type": {
"type": "string",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"enumerations": [
"fronthaul",
"backhaul",
"combined"
],
"datatype": "string",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "type"
}
}
}
]
},
"builtin": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "builtin"
}
}
}
]
},
"enabled": {
"type": "boolean",
"version": "1.00",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"default": true,
"mapping": [
{
"type": "uci",
"uci": {
"file": "mapcontroller",
"section": {
"type": "ap",
"index": "@{i-1}"
},
"option": {
"name": "enabled"
}
}
}
]
}
}
}
}

Some files were not shown because too many files have changed in this diff Show More