Compare commits

...

753 Commits

Author SHA1 Message Date
Amin Ben Romdhane
d4a631f0cb sysmngr: Added support for DeviceInfo.MemoryStatus.MemoryMonitor. Object 2024-11-15 16:04:38 +01:00
Janusz Dziedzic
c0208dab2e libwifi: 7.7.8 2024-11-13 10:27:05 +00:00
Mohd Husaam Mehdi
8dca6b8e44 bridgemngr: fix vendor extension macro usage 2024-11-12 16:16:59 +05:30
Mohd Husaam Mehdi
4b1a7859aa bridgemngr: add VLANFiltering bbfdm vendor extension as json 2024-11-12 15:50:20 +05:30
Vivek Kumar Dutta
6f28d90916 wifidmd: Align BackhaulMediaType value for self node 2024-11-12 15:31:41 +05:30
Jakob Olsson
285e24455d hostmngr: 1.2.9 2024-11-11 09:38:27 +01:00
Amin Ben Romdhane
d0c26b4bb7 sysmngr: Update the handling of process Instances 2024-11-08 15:19:28 +01:00
Amin Ben Romdhane
a71d90d2c7 wifidmd: 1.0.12 2024-11-08 15:12:55 +01:00
Vivek Kumar Dutta
78e1468f51 obuspa: Fix instance update in cached dm 2024-11-07 17:42:59 +05:30
Vivek Kumar Dutta
9a1e1dbd1a icmwp: optimize notification handling 2024-11-07 17:00:36 +05:30
Vivek Kumar Dutta
3ef21188b1 sysmngr: 1.0.1 2024-11-07 15:09:06 +05:30
Vivek Kumar Dutta
65daa6c56a bulkdata: Fix segfault with sub-task 2024-11-07 10:04:42 +05:30
Janusz Dziedzic
eb63f5d74f libwifi: 7.7.7 2024-11-06 17:56:00 +00:00
Amin Ben Romdhane
7da09349ec icwmp: Align with sysmngr 2024-11-06 15:18:41 +01:00
Amin Ben Romdhane
b2a28a12f6 bbfdm: Align with sysmngr 2024-11-06 15:11:23 +01:00
Amin Ben Romdhane
0fe5d2a232 logmngr: Align with sysmngr 2024-11-06 15:10:15 +01:00
Amin Ben Romdhane
b50f9946bb sysmngr: new package to manage DeviceInfo Object 2024-11-06 15:08:28 +01:00
Filip Matusiak
bf28778432 map-controller: 6.1.2.7 2024-11-06 10:19:07 +01:00
Amin Ben Romdhane
d6dad64328 bbfdm: 1.12.20 2024-11-06 10:01:33 +01:00
Filip Matusiak
46003fddd5 map-controller: 6.1.2.6 2024-11-05 16:49:13 +01:00
Vivek Kumar Dutta
2e7fc5fa14 bbfdm: prepone microservice startup
- Prepone dm microservice startup to avoid usp schema registration race
  condition
2024-11-05 18:51:18 +05:30
Jakob Olsson
7fb9b397ef decollector: 6.1.0.3 2024-11-05 13:39:46 +01:00
Vivek Kumar Dutta
cbe66d6c96 wifidmd: Update deprecated MultiAPDevice parameters 2024-11-05 18:06:59 +05:30
Amin Ben Romdhane
57d477c1da bbfdm: 1.12.18 2024-11-04 15:20:24 +01:00
Vivek Kumar Dutta
8e774faa3e self-diagnostics: 1.0.11 2024-11-04 12:29:14 +00:00
Vivek Kumar Dutta
6129323ca3 icwmp: Fix rpc event list after reboot 2024-11-04 17:40:48 +05:30
Vivek Kumar Dutta
6d6ecdfe92 obuspa: Fix probable segfault 2024-11-04 10:27:20 +05:30
Jakob Olsson
b66ae8d605 map-agent: 6.2.1.11 2024-10-31 14:15:27 +01:00
Jakob Olsson
ed97af82b5 map-controller: 6.1.2.5 2024-10-31 14:14:49 +01:00
Marina Maslova
464f037768 map-agent: add fixed interface names for proprietary mediatek driver 2024-10-30 15:18:53 +00:00
Janusz Dziedzic
024442da10 libwifi: skip probe-req events by default 2024-10-30 14:57:29 +00:00
Vivek Kumar Dutta
b0049df366 self-diagnostics: 1.0.10
- Print report_dir along with report_file
- Stop verbose logging of exec_cmds to prevent syslog overflow
- Increased timeouts of wifi diagnotics scripts
- Added report_dir in error output, if failed to generate tar
2024-10-30 13:35:21 +00:00
Jakob Olsson
7115c1734e map-agent: 6.2.1.10 2024-10-30 13:08:44 +01:00
Anjan Chanda
9b93ffef76 ieee1905: 8.6.1 2024-10-30 09:26:29 +01:00
Janusz Dziedzic
225b89ab4f wifimngr: 17.4.4 2024-10-30 07:51:07 +00:00
Janusz Dziedzic
d4464bf430 libwifi: 7.7.6 2024-10-30 07:47:47 +00:00
Marina Maslova
50731e00ef libwifi: use mtk module for proprietary mediatek driver on an7581 2024-10-30 07:47:25 +00:00
Amin Ben Romdhane
f9d3d22c14 bbfdm: 1.12.17
- Improve bbf.config handler for external config change
- Removed deprecated DeviceInfo.Processor. object
2024-10-29 12:33:52 +00:00
Anjan Chanda
607f3c5334 ieee1905: 8.6.0 2024-10-29 09:48:36 +01:00
Janusz Dziedzic
925c58aeaa libwifi: 7.7.5 2024-10-29 07:57:52 +00:00
Suvendhu Hansa
447acf3b27 bulkdata: unified DM with bulkdata daemon 2024-10-29 04:58:01 +00:00
Rahul Thakur
5bff6c3854 mcastmngr: remove unnecessary log 2024-10-29 10:25:53 +05:30
Andreas Gnau
70f4086ecc iop: Remove license_report
A CycloneDX SBOM is generated by the OpenWrt build system. It the same
license information as the license report. Remove the license report
script.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-10-28 13:57:29 +00:00
Vivek Kumar Dutta
b3bafdbba9 bbfdm: 1.12.16
- Add support for DeviceInfo.MaxNumberOfActivateTimeWindows
- Add support for DeviceInfo.HostName
- Generate error if plugin failed to installed
2024-10-28 08:54:36 +05:30
Yalu Zhang
5788d7d284 dectmngr-3.7.1: Add a new RPC to release call(s) on an extension
voicemngr-1.2.1: Change the RPC to dectmngr for releasing call(s) on a DECT extension
2024-10-25 17:23:52 +02:00
Jakob Olsson
a0c226d6ea map-controller: 6.1.2.4 2024-10-25 13:54:44 +02:00
Jakob Olsson
921657f464 map-controller: 6.1.2.3 2024-10-25 11:52:02 +02:00
Anjan Chanda
217ee3fa77 wifimngr: 17.4.3 2024-10-24 16:42:19 +02:00
Anjan Chanda
0aef613006 libwifi: 7.7.4 2024-10-24 16:41:29 +02:00
Markus Gothe
63e2bb8f6d ieee1905: 8.5.9 2024-10-24 16:13:29 +02:00
Markus Gothe
ea0059a932 hostmngr: 1.2.8 2024-10-24 15:50:32 +02:00
Jakob Olsson
a95a6d804a map-controller: 6.1.2.2 2024-10-24 14:23:21 +02:00
Jakob Olsson
3fbdd08037 map-agent: 6.2.1.9 2024-10-24 12:49:42 +02:00
Vivek Kumar Dutta
e04040c4ea bbfdm: 1.12.15 2024-10-24 14:50:11 +05:30
Jakob Olsson
20a85cce5f map-agent: 6.2.1.8 2024-10-24 09:44:04 +02:00
Vivek Kumar Dutta
2be7a59ff0 obuspa: Switch to WakeUp event for re-connections 2024-10-24 13:06:28 +05:30
Yalu Zhang
3102c0f981 dectmngr: add voicemngr in the dependency of Makefile 2024-10-24 09:25:44 +02:00
Vivek Kumar Dutta
8693a8f2c9 icwmp: Align with DeviceInfo.Reboots. 2024-10-24 12:22:09 +05:30
Amin Ben Romdhane
9bc4656525 bbfdm: Added support for Device.DeviceInfo.Reboots. object 2024-10-24 12:03:47 +05:30
Suvendhu Hansa
544000177c icwmp: Option to backup RPC in persistent storage 2024-10-24 11:31:46 +05:30
Strhuan Blomquist
2b1dbf7e36 iopsys-analytics: core watcher to fix modelname 2024-10-23 14:20:11 +00:00
Mohd Husaam Mehdi
641ec8a9eb urlfilter: fix crash on cleanup of dns answer struct 2024-10-23 10:16:39 +00:00
Janusz Dziedzic
c18929dbae libwifi: 7.7.3 2024-10-23 07:34:05 +00:00
Yalu Zhang
a592f34216 dectmngr-3.7.0: Add a new RPC to stop ringing on all incoming calls on an extension
voicemngr-1.2.0: Change the RPC to dectmngr for stopping ringing on an extension
2024-10-22 14:35:36 +02:00
Markus Gothe
4e2adf77cb mcastmngr: Implement L2 stats over UBUS.
Implement support for L2 mcast stats over UBUS.
2024-10-22 05:06:52 +00:00
Vivek Kumar Dutta
9fba09f00a bbfdm: Optimize event handling 2024-10-22 10:09:02 +05:30
Markus Gothe
12d377b3bd mcastmngr: 1.2.7 2024-10-21 17:07:34 +02:00
Rahul Thakur
cd1f81c8d9 update package logmngr
* fix uci defaults
* 37f9eef make protocol writable
2024-10-21 09:58:06 +00:00
Amin Ben Romdhane
f6774fd554 ieee1905: 8.5.8 2024-10-21 10:45:32 +02:00
Amin Ben Romdhane
ea248061f3 mcastmngr: 1.2.6 2024-10-21 10:44:12 +02:00
Amin Ben Romdhane
1e2894dd46 netmngr: 1.0.5 2024-10-21 10:43:05 +02:00
Vivek Kumar Dutta
92b607bd0e obuspa: reduce IPC cost for get calls 2024-10-18 18:34:08 +05:30
Mohd Husaam Mehdi
b766ea958a urlfilter: show Deny in bbfdm when no access policy set for filter 2024-10-18 06:45:37 +00:00
Markus Gothe
a7074db9f8 mcastmngr: Support hybrid proxying/snooping.
Support running mcproxy and snooping simultanous.
2024-10-17 16:19:04 +02:00
Janusz Dziedzic
5c819b2018 libwifi: 7.7.2 2024-10-17 12:57:25 +00:00
Janusz Dziedzic
c526df5143 libwifi: 7.7.1 2024-10-17 09:27:57 +00:00
Rahul Thakur
31ed2ae746 update package logmngr
*5e7c684 Fix data model params
* d23dcdf logmngr: add README
2024-10-17 14:31:30 +05:30
Rahul Thakur
702065eb3d update package dnsmngr
* fb49088 fix DNS.SD.Advertise.{i}.TransportProtocol
* b7115a9 Device.DNS.SD.Advertise.{i}.Interface doesn't show a correct reference value
* 94964b4 Device.DNS.SD.Advertise.{i}.InstanceName value is always shown as empty value
* bf29f7b Device.DNS.SD.Advertise.{i}.Alias default value is empty and remains empty even after setting it
2024-10-17 14:29:11 +05:30
Janusz Dziedzic
c418266af6 wifimngr: 17.4.2 2024-10-16 09:24:22 +00:00
Janusz Dziedzic
9c8d80d763 libwifi: 7.7.0 2024-10-16 08:03:15 +00:00
Vivek Kumar Dutta
007a8cb8bf icwmp: Use async task for diagnostics 2024-10-16 12:23:39 +05:30
Vivek Kumar Dutta
2fc7d55d6c bbfdm: 1.12.12 2024-10-16 12:22:26 +05:30
Vivek Kumar Dutta
b3bdcea137 obuspa: Fix miss-configs caused by uci update 2024-10-15 17:40:58 +05:30
Vivek Kumar Dutta
4673347125 obuspa: workaround to skip false warning on Download operation 2024-10-15 16:05:10 +05:30
Vivek Kumar Dutta
f827f9f408 bbfdm: 1.12.11 2024-10-15 14:30:44 +05:30
Vivek Kumar Dutta
6a8aed5d3f bbfdm: Schedule reboots on firmware AutoActivate 2024-10-15 14:11:05 +05:30
Janusz Dziedzic
5e54477cd1 libwifi: 7.6.9 2024-10-15 05:40:20 +00:00
Amin Ben Romdhane
ba9fcda886 obuspa: delete dmcaching exclude objects 2024-10-14 18:20:10 +02:00
Amin Ben Romdhane
c848d93316 hostmngr: 1.2.7 2024-10-14 18:17:13 +02:00
Amin Ben Romdhane
d00c8f1ea0 bbfdm: 1.12.9 2024-10-14 18:16:20 +02:00
Mohd Mehdi
9788a135aa urlfilter: ParentalControl datamodel 2024-10-14 10:10:12 +00:00
Jakob Olsson
899e6b1417 map-agent: 6.2.1.7 2024-10-11 09:04:35 +02:00
Mohd Husaam Mehdi
6f7f14b241 urlfilter: transform into ParentalControl bbf extension
* config file has been renamed from urlfilter to parentalcontrol
* along with urlfiltering, shell scripts handle internet_access
  and bedtime blocking support, which have been added as
  separate sections for better mapping to the bbf data model
  extension
* uci-default script has been added to handle migration from
  previous to new format
2024-10-11 12:18:26 +05:30
Vivek Kumar Dutta
cc0d1b5910 firewallmngr: 1.0.6 2024-10-10 17:10:29 +05:30
Vivek Kumar Dutta
0b6cd8154b ddnsmngr: 1.0.9 2024-10-10 16:47:42 +05:30
Vivek Kumar Dutta
c4cae5d6b4 bridgemngr: 1.0.6 2024-10-10 16:45:16 +05:30
Vivek Kumar Dutta
f58959842b dhcpmngr: 1.0.4 2024-10-10 16:44:50 +05:30
Vivek Kumar Dutta
b813c155bc sshmngr: 1.0.5 2024-10-10 16:42:50 +05:30
Vivek Kumar Dutta
98e53ae941 logmngr: 1.0.3 2024-10-10 16:02:51 +05:30
Vivek Kumar Dutta
4d993266b3 bbfdm: move VendorLogFile to logmngr 2024-10-10 14:30:41 +05:30
Suvendhu Hansa
8da27926a1 icwmp: 9.8.16
- External script to handle '2 Vendor Log File'
- Align with VendorLogFile
2024-10-10 12:49:49 +05:30
Suvendhu Hansa
7fae7acc91 logmngr: 1.0.2
- Added prefix with rotated log filename to distinguish
  with actual log files
- Fix compression value
- Moved VendorLogFiles datamodel from bbfdm to logmngr
2024-10-10 04:10:22 +00:00
Suvendhu Hansa
47708d34df self-diagnostics: Align with VendorLogFiles update 2024-10-10 09:20:43 +05:30
Markus Gothe
ab322f1194 timemngr: commit time UCI config. 2024-10-09 16:08:32 +02:00
Amin Ben Romdhane
aab45b16b0 Added libbbfdm-ubus and dm-service as dependencies for all microservices 2024-10-09 09:54:16 +02:00
Jakob Olsson
586920d8a8 map-agent: 6.2.1.6 2024-10-08 12:58:33 +02:00
Rahul Thakur
ac8a1c69ae update package dnsmngr
* 055de29 add support for dns.sd.advertise
2024-10-08 14:01:57 +05:30
Vivek Kumar Dutta
604cd52a79 bbfdm: Support to set list of references with json plugins 2024-10-08 12:52:38 +05:30
Jakob Olsson
37109a8531 decollector: 6.1.0.2 2024-10-04 14:11:21 +02:00
Jakob Olsson
136db7b085 map-agent: 6.2.1.5 2024-10-04 12:32:33 +02:00
Jakob Olsson
c177d59b7b map-agent: 6.2.1.4 2024-10-03 14:03:58 +02:00
Vivek Kumar Dutta
fa9611f4f5 usbmngr: 1.0.5 2024-10-03 16:38:54 +05:30
Jakob Olsson
859e2958c0 map-agent: 6.2.1.3 2024-10-03 12:10:25 +02:00
Vivek Kumar Dutta
0dda22833d obuspa: skip db override 2024-10-02 20:43:48 +05:30
Yalu Zhang
ccb40910e2 libvoice-broadcom-1.0.15: Change the mechanism of DECT simulation by not calling Broadcom APIs 2024-10-02 16:51:21 +02:00
Janusz Dziedzic
eddaa9233c libwifi: 7.6.8 2024-10-02 13:00:08 +00:00
Piotr Kubik
a09f5a3ba6 iop: update_feed_branches: Remove script
It was used to update branches of feeds according to the commit hashes
in feeds.conf. Mostly used when doing release branches for the
first time. We do it manually now, so it is not needed anymore.
2024-10-02 13:44:30 +02:00
Jakob Olsson
ed78a58455 map-agent: 6.2.1.2 2024-10-02 11:01:20 +02:00
Amin Ben Romdhane
b130d50bb3 tr104: 1.0.34 2024-10-02 10:08:31 +02:00
Vivek Kumar Dutta
7ab286753d obuspa: 9.0.0.6
- Added back firewall hook to force re-connect mqtt client on firewall reload
- Added wait for apply handler
2024-10-01 16:29:14 +05:30
Vivek Kumar Dutta
bc6aadb0ed tr104: added missing required NumberOfEntires parameters 2024-10-01 16:21:45 +05:30
Vivek Kumar Dutta
fd9c8b0922 icwmp: Fix GPN fault with multi-instances 2024-10-01 16:17:15 +05:30
Vivek Kumar Dutta
2c9b9cadfe icwmp: 9.8.14 2024-09-30 19:18:41 +05:30
Vivek Kumar Dutta
fb1ac0994d obuspa: multiple fixes
- remove workaround to ForceReconnect over MQTT with firewall hook
- removed schema reloader from obuspa
2024-09-30 18:56:07 +05:30
Janusz Dziedzic
5ba8e293eb libwifi: 7.6.7 2024-09-30 07:45:45 +00:00
Janusz Dziedzic
801ed0eb9f libwifi: 7.6.6 2024-09-27 16:34:33 +00:00
Rahul Thakur
54503f98d4 urlfilter: fix connection flush on firewall reload 2024-09-27 11:54:45 +00:00
Janusz Dziedzic
903ff637e7 libwifi: 7.6.5 2024-09-27 08:41:26 +00:00
Vivek Kumar Dutta
82ef5f6b6e wifidmd: Align with dump2 output 2024-09-26 16:10:24 +05:30
Anjan Chanda
398f09a1ce decollector: 6.1.0.1 2024-09-26 11:42:45 +02:00
Jakob Olsson
f29de07d0d map-agent: 6.2.1.1 2024-09-26 10:50:54 +02:00
Janusz Dziedzic
8524f719c1 wifimngr: 17.4.1 2024-09-26 05:57:13 +00:00
Janusz Dziedzic
0a73e686f5 libwifi: 7.6.4 2024-09-26 05:56:06 +00:00
Vivek Kumar Dutta
615b3d0507 obuspa: Fix transaction commit/abort calls 2024-09-25 20:06:17 +05:30
Vivek Kumar Dutta
4df8574fb6 stunc: 1.4.5 2024-09-25 10:34:08 +00:00
Vivek Kumar Dutta
e39d51a37b obuspa: Fix disconnection after set 2024-09-25 10:34:08 +00:00
Vivek Kumar Dutta
598b5c8e4a timemngr: Updated loglevel 2024-09-25 10:34:08 +00:00
Janusz Dziedzic
135e31a3e2 wifimngr: 17.4.0 2024-09-25 10:24:42 +00:00
Janusz Dziedzic
8e4810baa1 libwifi: 7.6.3 2024-09-25 10:23:28 +00:00
Vivek Kumar Dutta
acd0a7ba24 bbfdm: 1.12.6 2024-09-24 18:58:26 +05:30
Vivek Kumar Dutta
032bb6bf2e usermngr: 1.2.19 2024-09-24 18:57:19 +05:30
Vivek Kumar Dutta
083bcd79f9 bulkdata: 2.1.12 2024-09-24 18:47:00 +05:30
Vivek Kumar Dutta
30a7c285b1 xmppc: 2.2.12 2024-09-24 18:41:25 +05:30
Vivek Kumar Dutta
5d03bbfd20 obuspa: updated default instance cache time to 10 mins 2024-09-24 18:28:41 +05:30
Vivek Kumar Dutta
1a167f8854 stunc: 1.4.4 2024-09-24 17:20:44 +05:30
Vivek Kumar Dutta
06b6b64d4c periodicstats: 1.5.13 2024-09-24 17:15:56 +05:30
Vivek Kumar Dutta
26999d2381 wifidmd: 1.0.9 2024-09-24 17:06:33 +05:30
Vivek Kumar Dutta
9fba0888eb packet-capture-diagnostics: 1.0.2 2024-09-24 17:05:37 +05:30
Vivek Kumar Dutta
1ce4ba836f udpecho: 2.2.4 2024-09-24 17:03:26 +05:30
Vivek Kumar Dutta
6493720c11 userinterface: 1.1.6 2024-09-24 16:58:49 +05:30
Piotr Kubik
dd0dec6ac4 iop: genconfig_wrap: Move script to main repo 2024-09-24 09:38:44 +02:00
Vivek Kumar Dutta
cbfc98d85e obuspa: Integrate v9.0.0 Ibis release 2024-09-23 19:35:36 +05:30
Jakob Olsson
086763919a map-agent: 6.2.1.0 2024-09-23 14:55:12 +02:00
Jakob Olsson
62cbccd274 map-controller: 6.1.2.1 2024-09-23 14:52:23 +02:00
Piotr Kubik
b0a8549453 iop: ssh_upgrade: Move script to main repo 2024-09-23 14:04:49 +02:00
Vivek Kumar Dutta
757ab29b57 twamp: 1.4.7 2024-09-23 10:52:36 +05:30
Vivek Kumar Dutta
82eb62a9e1 icwmp: Fix static analysis errors 2024-09-23 10:26:35 +05:30
Vivek Kumar Dutta
66bed5a044 netmngr: 1.0.4 2024-09-20 19:39:53 +05:30
Amin Ben Romdhane
12449bf471 tr471: 1.0.6 2024-09-20 15:51:24 +02:00
Amin Ben Romdhane
5c4f315083 tr143: 1.0.7 2024-09-20 15:50:22 +02:00
Amin Ben Romdhane
0a88793328 timemngr: 1.1.2 2024-09-20 15:48:51 +02:00
Amin Ben Romdhane
4ea26f9bec bbfdm: 1.12.5 2024-09-20 15:47:43 +02:00
Jakob Olsson
85542591d0 ieee1905: 8.5.7 2024-09-20 15:30:01 +02:00
Jakob Olsson
91ef8ff9a2 map-agent: 6.2.0.3 2024-09-20 15:00:50 +02:00
Yalu Zhang
13aa279c39 dectmngr-3.6.9: Send flash hook event before receiving the called number for the second outgoing call
libvoice-d2-1.1.14: Don't report DTMF events detected by DSP for DECT
2024-09-20 14:16:47 +02:00
Janusz Dziedzic
eadb87d369 libwifi: 7.6.2 2024-09-20 08:33:26 +00:00
Jakob Olsson
f250bc3c79 decollector: 6.1.0.0 2024-09-19 15:03:56 +02:00
Jakob Olsson
eaaf653b0f map-agent: 6.2.0.2 2024-09-18 17:20:06 +02:00
Jakob Olsson
4a30355aab decollector: 6.0.1.2 2024-09-18 16:30:59 +02:00
Vivek Kumar Dutta
2abd075e59 obuspa: Fix probable segfault 2024-09-18 18:57:43 +05:30
Jakob Olsson
aec10de11f map-agent: 6.2.0.1 2024-09-18 12:41:14 +02:00
Jakob Olsson
50e53a5b15 Revert "mapagent: qualcomm: disable hidden bh"
This reverts commit 5fd9145a27.
2024-09-18 11:14:00 +02:00
Janusz Dziedzic
6a89907ddb libwifi: 7.6.1 2024-09-18 05:29:55 +00:00
Vivek Kumar Dutta
3dae593802 swmodd: Fix DuStateChange timer 2024-09-17 19:42:25 +05:30
Amin Ben Romdhane
5b2d26a839 Revert "tr143: 1.0.7"
This reverts commit 3efb822b6e.
2024-09-17 15:27:29 +02:00
Andreas Gnau
3fa318c58f libvoice-broadcom: Add dependency to bcm963xx-voice
Voice-part of BCM SDK is required to build libvoice-broadcom.
2024-09-17 12:54:30 +00:00
Rahul Thakur
7dab64d1e0 update package libdsl
* 20875ec clean up dsl
* setup prepare section for local dev
* update git source url to new source for repo
2024-09-17 10:54:27 +00:00
Vivek Kumar Dutta
99d1900c79 xmppc: Support re-connection with max_keepalive_fails option 2024-09-17 14:31:44 +05:30
Janusz Dziedzic
16bffe35f7 libwifi: 7.6.0 2024-09-16 15:39:39 +00:00
Amin Ben Romdhane
3efb822b6e tr143: 1.0.7 2024-09-16 15:33:37 +02:00
Amin Ben Romdhane
a3463ec253 netmngr: 1.0.3 2024-09-16 15:01:04 +02:00
Amin Ben Romdhane
a76e7d641d bbfdm: 1.12.4 2024-09-16 15:00:04 +02:00
Vivek Kumar Dutta
ab75eaa19d dslmngr: 1.2.8 2024-09-16 17:30:57 +05:30
Mikhail Kshevetskiy
2d50afe767 voicemngr: add missed dependency for libopenssl
Building of voicemngr for airoha target results in failure due to missed deps on libcrypto.so.3
and libssl.so.3.
This patch fix the issue.

PS: other targets was NOT tested.
2024-09-16 08:25:29 +00:00
Suvendhu Hansa
916ea44e1d bbfdm: Added Device.Schedules. DM object 2024-09-16 04:50:39 +00:00
Vivek Kumar Dutta
59bbbd822e dslmngr: added missing required dm parameters 2024-09-16 10:10:37 +05:30
Vivek Kumar Dutta
8b67c32fd8 netmngr: Added missing required dm parameters 2024-09-16 10:07:38 +05:30
Vivek Kumar Dutta
0852b1c635 icwmp: 9.8.12 2024-09-16 10:05:24 +05:30
Janusz Dziedzic
38f0ec2180 libwifi: 7.5.9 2024-09-13 10:50:43 +00:00
Vivek Kumar Dutta
67567aeed5 userinterface: fix rpcd script 2024-09-12 14:30:03 +00:00
Vivek Kumar Dutta
5315408948 sshmngr: Fix rpcd scripts 2024-09-12 14:30:03 +00:00
Vivek Kumar Dutta
5f255090f5 self-diagnostics: Fix rpcd scripts 2024-09-12 14:30:03 +00:00
Vivek Kumar Dutta
2e8a62001e ddnsmngr: Fixed rpcd scripts 2024-09-12 14:30:03 +00:00
Vivek Kumar Dutta
52add3fc14 bbfdm: 1.12.2
- Fix rpcd bbf.secure script
- Fix validation for empty datamodel parameter reference
2024-09-12 14:30:03 +00:00
Vivek Kumar Dutta
964a1008fd mcastmngr: probable fix for rpcd crash 2024-09-12 18:06:36 +05:30
Janusz Dziedzic
5fd9145a27 mapagent: qualcomm: disable hidden bh
Signed-off-by: Janusz Dziedzic <janusz.dziedzic@iopsys.eu>
2024-09-12 08:47:12 +00:00
Janusz Dziedzic
988717574c wifimngr: 17.3.9 2024-09-11 16:32:02 +00:00
Janusz Dziedzic
23ea6da091 libwifi: 7.5.8 2024-09-11 14:14:27 +00:00
Jakob Olsson
927442fb89 map-controller: 6.1.2.0 2024-09-11 15:27:12 +02:00
Jakob Olsson
4db0f00c26 map-agent: 6.2.0.0 2024-09-11 15:26:29 +02:00
Janusz Dziedzic
c710784038 libwifi: 7.5.7 2024-09-11 09:57:47 +00:00
Janusz Dziedzic
5072d9025a libwifi: 7.5.6 2024-09-10 17:00:26 +00:00
Andreas Gnau
b5a963c1bf iop: cfe_upgrade: Remove
CFE is no longer. Remove the script. In the future, we might integrate
U-Boot upgrade into iopupgrade.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-09-10 17:06:20 +02:00
Andreas Gnau
608b4a2b8a iop: taas: Remove
TAAS infrastructure no longer exists. Remove it.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-09-10 17:06:20 +02:00
Andreas Gnau
ae5a982dc4 iop: annexconfig: Remove
This script has been broken for several years and DSL as a techology is
not that common anymore. Remove it.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-09-10 17:06:20 +02:00
Vivek Kumar Dutta
3ec6b54d46 bbfdm: delay start datamodel services
datamodel services moved down in startup sequence to avoid race conditions
2024-09-10 18:54:55 +05:30
Vivek Kumar Dutta
6a34e2da97 timemngr: run cron job to apply dst 2024-09-10 16:14:52 +05:30
Vivek Kumar Dutta
627a4c4ad6 Revert "timemngr: uci option for day light saving time"
This reverts commit b74c2d2d17.
2024-09-10 16:04:30 +05:30
Lwithwma Brahma
abbab7118c mcastmngr: correct stats output
Corrected the read_mcast_stats function, to display
"ubus call mcast stats" correct output for multiple iptv bridges

Test:
"ubus call mcast stats" showing correct output for both single and multiple bridge.
2024-09-10 09:59:40 +00:00
Amin Ben Romdhane
31e6887d42 bbfdm: add dm-service daemon 2024-09-10 11:48:09 +02:00
Janusz Dziedzic
fc37507afb libwifi: 7.5.5 2024-09-10 07:06:33 +00:00
Vivek Kumar Dutta
e160b6795a tr143: Fix datatype of parameters 2024-09-09 18:36:24 +05:30
Markus Gothe
5ace2f5cc9 mcastmngr: 1.2.4 2024-09-09 11:20:58 +02:00
Mohd Husaam Mehdi
0e54c37963 mcastmngr: fix mcast stats shows 0.0.0.0 for group
Fixes mcast stats showing 0.0.0.0 for group address.
2024-09-08 12:32:36 +00:00
Vivek Kumar Dutta
e9e118fa12 icwmp: Fix memory leak 2024-09-06 22:00:39 +05:30
Vivek Kumar Dutta
9af1de3b43 bbfdm: Use usp proto for AddObj/DelObj events 2024-09-06 21:55:51 +05:30
Suvendhu Hansa
b74c2d2d17 timemngr: uci option for day light saving time 2024-09-06 21:49:23 +05:30
Janusz Dziedzic
ee779c0fd8 libwifi: assume mediatek = mac80211 2024-09-06 12:22:27 +00:00
Rahul Thakur
36fb5d5343 mcastmngr: handle multiple filters for mcproxy
the library script that converts uci to mcproxy config is generating
incorrect config for filtering ip addresses which leads to mcproxy
not even starting when multiple filters are defined.

this commit fixes the above described issue.
2024-09-06 10:30:00 +00:00
Janusz Dziedzic
0d2f443da0 wifimngr: 17.3.8 2024-09-05 19:39:50 +00:00
Vivek Kumar Dutta
5dc696f7e6 bbfdm: updated max registration objects 2024-09-04 19:55:55 +05:30
Vivek Kumar Dutta
6ae56f6737 obuspa: updated max instance depth 2024-09-04 19:54:54 +05:30
Janusz Dziedzic
76af31b457 wifimngr: 17.3.7 2024-09-04 12:30:03 +00:00
Vivek Kumar Dutta
7838b7b5c3 icwmp: datatype validation in set rpc 2024-09-04 11:51:05 +05:30
Vivek Kumar Dutta
f98664f398 bbfdm: datatype validation on set request 2024-09-04 11:40:20 +05:30
Vivek Kumar Dutta
89b1584816 fluent-bit: Switch to build from release 2024-09-03 17:50:41 +05:30
Vivek Kumar Dutta
da0234f66b decollector: fix assoc/disassoc event syntax 2024-09-02 19:13:29 +05:30
Vivek Kumar Dutta
45af6700f5 bbfdm: respawn microservices 2024-09-02 19:10:12 +05:30
Vivek Kumar Dutta
c60bc158a4 obuspa: fix probable segfault in event handling 2024-09-02 19:06:14 +05:30
Vivek Kumar Dutta
b2895d8908 obuspc: Fix compilation errors 2024-09-02 14:14:48 +05:30
Markus Gothe
eb10bd6b6b obuspa: add InterfaceSetting to dmcaching_exclude.json 2024-09-02 06:34:06 +00:00
Amin Ben Romdhane
af0a111b81 bbfdm: 1.11.1 2024-08-30 17:52:41 +02:00
Janusz Dziedzic
fc9e35c18f libwifi: 7.5.4 2024-08-30 08:30:25 +00:00
Vivek Kumar Dutta
7d619a85b3 netmngr: Fix instance navigation 2024-08-30 12:55:05 +05:30
Amin Ben Romdhane
ded9e8d248 timemngr: 1.1.0 2024-08-29 12:14:25 +02:00
Amin Ben Romdhane
4b5a232a9e bbfdm: Introduce a new libbbfdm-ubus library 2024-08-29 12:12:58 +02:00
Mohd Husaam Mehdi
bbe85d77a3 dhcpmngr: handle the case when unbound is used instead of dnsmasq 2024-08-29 15:34:18 +05:30
Mohd Husaam Mehdi
172581b794 dnsmngr: add logic to select and handle unbound backend 2024-08-29 15:33:50 +05:30
Anjan Chanda
2b965738cb decollector: 6.0.1.0 2024-08-29 11:51:37 +02:00
Mohd Husaam Mehdi
47fe2abfe0 dnsmngr: add unbound as selectable backend
* add dependencies for different backends in dhcpmngr and
  dnsmngr
* use CFLAG to indicate to data model code which backend is being
  used currently
* add uci-defaults script to set leasetrigger if unbound is dns
  backend
2024-08-29 09:06:15 +00:00
Vivek Kumar Dutta
5068f2ae2d fluent-bit: updated HASH 2024-08-29 14:25:40 +05:30
Janusz Dziedzic
479df88a67 map-agent: 6.1.1.12 2024-08-29 06:44:09 +00:00
Suvendhu Hansa
be93ce6e1e obuspa: expose mqtt and stomp datamodel for cwmp 2024-08-29 06:36:17 +00:00
Janusz Dziedzic
f41f010aa9 map-controller: 6.1.1.8 2024-08-29 06:30:15 +00:00
Yalu Zhang
72aa9ac89a Update packages libvoice-d2 and voicemngr
Generate RTP events for DTMF pressed on a DECT handset
2024-08-28 15:33:09 +02:00
Anjan Chanda
77a4bee249 ieee1905: 8.5.6 2024-08-28 15:22:43 +02:00
Janusz Dziedzic
54bd79427e wifimngr: 17.3.6 2024-08-28 11:04:57 +00:00
Filip Matusiak
1d773de3ca map-controller: 6.1.1.7 2024-08-28 10:24:22 +02:00
Jakob Olsson
791881dd85 map-agent: 6.1.1.11 2024-08-27 16:45:27 +02:00
Janusz Dziedzic
fc7c6e123d wifimngr: 17.3.5 2024-08-26 14:45:29 +00:00
Janusz Dziedzic
e3af6258f5 Revert "map-agent: disable mlo for extender and 6GHz"
This reverts commit 45bb27cff4.
2024-08-26 14:43:46 +00:00
Piotr Kubik
0bf9cc31d0 dectmngr 3.6.9: Fix a build error for strtol() after OpenWrt version uplift 2024-08-26 07:53:43 +00:00
Suvendhu Hansa
c3a0c839a8 obuspa: Run USPAgent as datamodel micro-service 2024-08-26 11:39:23 +05:30
Suvendhu Hansa
4b84c570b5 Fix e2e session configuration 2024-08-23 20:11:06 +05:30
Markus Gothe
57a8f7e98a update package libethernet
* libethernet: Improve counter logic for Airoha.
2024-08-23 12:48:52 +02:00
Andreas Gnau
0483212986 iopsys-analytics: Do not set hostname
* f448cfe9264 Revert "uci-defaults: Add hostname script"

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-08-22 17:24:07 +02:00
Janusz Dziedzic
96ad10a2b0 wifimngr: 17.3.4 2024-08-22 12:33:57 +00:00
Janusz Dziedzic
a7fbef8753 libwifi: 7.5.3 2024-08-22 12:32:56 +00:00
Marek Puzyniak
1443111081 map-agent: 6.1.1.10 2024-08-21 14:22:09 +00:00
Amin Ben Romdhane
9c78c6e78d bbfdm: 1.10.4 2024-08-20 12:56:15 +02:00
Amin Ben Romdhane
0aa3452fdb tr143: 1.0.5 2024-08-20 12:52:51 +02:00
Amin Ben Romdhane
2ca261f10d tr471: 1.0.5 2024-08-20 12:52:17 +02:00
Amin Ben Romdhane
bbe62b4c7b udpecho: 2.2.3 2024-08-20 12:51:54 +02:00
Amin Ben Romdhane
fd08ddde07 twamp: 1.4.6 2024-08-20 12:51:26 +02:00
Amin Ben Romdhane
6020c2d64b netmngr: 1.0.0 2024-08-20 12:50:30 +02:00
Vivek Kumar Dutta
012efefbad obuspa: enable SessionMode uci config 2024-08-20 12:38:33 +05:30
Vivek Kumar Dutta
a18d9af782 obuspa: Integrate obuspa v8.0.8 2024-08-20 10:25:45 +05:30
Vivek Kumar Dutta
5bc6d6aaa9 obuspa: Fix parsing of event data 2024-08-19 22:34:38 +05:30
Vivek Kumar Dutta
bedb6b8afb bbfdm: Update event schema to align 2024-08-19 22:06:21 +05:30
Filip Matusiak
3eeb24fea8 map-controller: 6.1.1.6 2024-08-19 13:34:13 +00:00
Filip Matusiak
645d6d9beb map-controller: config: steering intervals 2024-08-19 13:34:13 +00:00
Vivek Kumar Dutta
20cf6d1654 bbfdm: fix setting empty value for json plugin 2024-08-19 16:54:03 +05:30
Vivek Kumar Dutta
5bbab3b822 icwmp: align with bbfdm 2024-08-17 13:43:27 +00:00
Vivek Kumar Dutta
0a73c8150b obuspa: use bbf.config in place of transactions 2024-08-17 13:43:27 +00:00
Amin Ben Romdhane
8619514bdb bbfdm: Remove transaction APIs 2024-08-17 13:43:27 +00:00
Yalu Zhang
1ad9254588 dectmngr-3.6.8: Change the reset procedures for DCX81 chip 2024-08-16 16:00:22 +02:00
Mohd Husaam Mehdi
2bff75633e dnsmngr: add compile time option for enabling DNS.SD support 2024-08-16 18:12:50 +05:30
Rahul Thakur
fa9bfb428e logmngr: implement fail2ban for ssh
* handle both openssh and dropbear for fail2ban
2024-08-16 12:21:30 +00:00
Rahul Thakur
ab2766f79b logmngr: integrate fail2ban 2024-08-16 12:21:30 +00:00
Markus Gothe
bcdb31c830 qosmngr: Solve issue with L3 HW NAT for DSCP.
When doing classification on DSCP values we need
to ensure that the values are correctly hashed
for the L3 HW NAT, otherwise identical flows
with different DSCP values will end up with
the same QoS priority and queue.
2024-08-16 11:37:32 +02:00
Markus Gothe
32203771f6 qosmngr: Handle L3 flows with different p-bits correctly.
The L3 HW NAT will match the flows based on an IP header 5-tuple.
However if we are doing classification based on p-bits at the
same time and we want to use this for QoS we need to make sure
to add a VIP packet matcher to send this info to the PPE for
hashing the flow.
2024-08-15 16:51:48 +02:00
Sukru Senli
2ff18658c9 netmode: Add README 2024-08-13 11:57:32 +02:00
Rahul Thakur
29979d3559 urlfilter: update regex
* update regex handling
* simplify iptables rules to setup nfq into single rule
* update makefile to not compile urlfilter as a kernel module
2024-08-13 06:10:08 +00:00
Vivek Kumar Dutta
7e56b7eca4 dnsmngr: align with bbfdm 2024-08-13 10:35:19 +05:30
Suvendhu Hansa
7d7c89d24f icwmp: apply non-critical services immediately 2024-08-08 14:55:48 +00:00
Jakob Olsson
07701b459b map-agent: 6.1.1.9 2024-08-08 16:41:52 +02:00
Vivek Kumar Dutta
6c6d1eae5f icwmp: Align with bbfdm 2024-08-08 10:30:55 +05:30
Vivek Kumar Dutta
58a91d6a7d bbfdm: 1.10.0
- Optimize CPU usages
- Remove support to delete all instances at once
2024-08-08 10:28:25 +05:30
Yalu Zhang
b033b53958 dectmngr 3.6.7: Fix building errors in pipeline job api_test due to libgpiod APIs 2024-08-06 15:41:29 +02:00
Jakob Olsson
f5df102fd9 map-agent: 6.1.1.8 2024-08-06 15:01:29 +02:00
Rahul Thakur
d1f16dc432 logmngr: add logrotate support
* add support for logrotate functionality to logmngr
2024-08-06 08:43:32 +00:00
Jakob Olsson
0884ecd15e libdpp: 2.1.1 2024-08-06 10:33:24 +02:00
Vivek Kumar Dutta
787570e7c7 sulu: updated readme 2024-08-05 14:46:14 +05:30
Vivek Kumar Dutta
33387c8e40 sulu: updated readme 2024-08-05 14:14:14 +05:30
Vivek Kumar Dutta
1b63c05762 sulu: readme update 2024-08-05 13:46:36 +05:30
Vivek Kumar Dutta
c816ee7358 sulu: readme update 2024-08-05 12:53:53 +05:30
Markus Gothe
71c92846d2 update package ebtables-extensions
* 35fb79f9 ebt_vlantranslation: Fix check for tag.
2024-08-03 08:00:48 +02:00
Mohd Husaam Mehdi
fdf005fd8f logmngr: update data model implementation
update to use correct data type for FilePath param and add
DM_REFERENCE flag to VendorLogFile param
2024-08-02 07:12:28 +00:00
Vivek Kumar Dutta
ddac1730e6 bbfdm: fix setting list of datamodel references 2024-08-01 16:39:13 +05:30
Vivek Kumar Dutta
c5e76fe6d4 icwmp: Fix enable/disable of ManagementServer from USP 2024-08-01 16:22:21 +05:30
Vivek Kumar Dutta
eb7df8993c sulu: doc update on how to add sulu user 2024-08-01 16:14:22 +05:30
Vivek Kumar Dutta
0c0e09fb2d timemngr: 1.0.22 2024-08-01 10:31:21 +05:30
Markus Gothe
834921f50b Integrate obuspa 8.0.1.9. 2024-07-31 18:55:22 +02:00
Amin Ben Romdhane
f161417d64 self-diagnostics: 1.0.8 2024-07-31 17:38:13 +02:00
Amin Ben Romdhane
98689253d0 swmodd: 2.5.16 2024-07-31 15:35:53 +02:00
Amin Ben Romdhane
2be2045403 usermngr: 1.2.18 2024-07-31 15:34:55 +02:00
Amin Ben Romdhane
332793e0a8 periodicstats: 1.5.12 2024-07-31 15:34:02 +02:00
Amin Ben Romdhane
736f77087e packet-capture-diagnostics: 1.0.1 2024-07-31 15:32:53 +02:00
Amin Ben Romdhane
274d25094d tr471: 1.0.4 2024-07-31 15:31:55 +02:00
Amin Ben Romdhane
636249c142 tr143: 1.0.4 2024-07-31 15:31:07 +02:00
Amin Ben Romdhane
7bf598573b bbfdm: 1.9.15 2024-07-31 15:30:06 +02:00
Amin Ben Romdhane
09588fe45e wifidmd: 1.0.8 2024-07-31 15:29:14 +02:00
Amin Ben Romdhane
3f95d1f3f1 dnsmngr: 1.0.7 2024-07-31 15:27:01 +02:00
Vivek Kumar Dutta
87425e5db9 wifidmd: Fix ChannelScanRequest() without ChannelList 2024-07-30 19:12:27 +05:30
Suvendhu Hansa
a7f1342ad7 bulkdata: Fix status value 2024-07-30 19:09:16 +05:30
Vivek Kumar Dutta
680c4b8f2a self-diagnostics: updated netstat command to collect all 2024-07-30 07:27:47 +00:00
Vivek Kumar Dutta
c897647054 icwmp: fix random 9005 error with GPN 2024-07-30 12:30:05 +05:30
Mohd Husaam Mehdi
d4715fd1ad bbfdm: merge activeport.c into ip.c 2024-07-29 19:54:54 +05:30
Vivek Kumar Dutta
8c2a7cfeac bbfdm: Fix segfault while loading json plugin 2024-07-27 18:26:15 +05:30
Amit Kumar
b898b5761b urlfilter: added delete of ebtables rule on stop 2024-07-26 11:43:29 +00:00
Mohd Husaam Mehdi
c298b611d2 bbfdm: remove active-port package
implementation has been moved to libbfdm, so json based micro
service is not needed anymore for Device.IP.ActivePort
2024-07-26 17:12:09 +05:30
Vivek Kumar Dutta
b43fd6a3c0 timemngr: use stratum level for status 2024-07-26 17:04:16 +05:30
Suvendhu Hansa
53fc9f5782 icwmp: wait for clock sync before first inform 2024-07-26 11:24:16 +00:00
Janusz Dziedzic
7e975f95b5 map-agent: 6.1.1.7 2024-07-25 11:41:44 +00:00
Mohd Husaam Mehdi
3ee64793cc logmngr: add support for Device.Syslog. datamodel object 2024-07-25 16:51:28 +05:30
Janusz Dziedzic
45bb27cff4 map-agent: disable mlo for extender and 6GHz
Temporary workaround for QCA crash
2024-07-25 10:00:23 +00:00
Amit Kumar
b15d45731e urlfilter: handled DNS received over TCP
* Added iptables rule to handle DNS packet received over TCP
* Added ebtables rule with skiplog to avoid DNS packet accelration

urlfilter: updated commit hash in Makefile
2024-07-25 05:59:58 +00:00
Amit Kumar
f043b4e0d9 firewallmngr: updated commit hash
* updated commit hash for changes for Device.Firewall.Type.
2024-07-25 10:52:34 +05:30
Vivek Kumar Dutta
328bc26684 tr471: fix datatype for IPLayerCapSupportedControlProtocolVersion 2024-07-25 09:49:15 +05:30
Markus Gothe
7a06a9e479 ebtables: Use --concurrent to avoid race conditions.
Add --concurrent to missing places.
2024-07-24 20:01:05 +02:00
Vivek Kumar Dutta
77f50aaa16 icwmp: Fix 503 error on CR when path defined 2024-07-24 12:12:35 +05:30
Vivek Kumar Dutta
ca646f8243 tr471: Fix default values 2024-07-23 16:47:42 +05:30
Vivek Kumar Dutta
b7efd787cb swmodd: Fix RequestedState cwmp parameter 2024-07-23 16:22:48 +05:30
Rahul Thakur
91e9278cba logmngr: add logread and default uci config
* all logging packages have a custom implmentation for logread,
  which is a command that can be invoked to view the logs. Hence,
  it makes sense for logmngr to have a logread to accompany it
  as well. Support for the same is added via this commit.
* the approach is simplistic and follows syslog-ng with the
  slight enhancement of reading the logfile from logmngr uci
* support to generate default uci config for logmngr which is
  to write logs to /var/log/messages
2024-07-23 10:32:18 +00:00
Vivek Kumar Dutta
1b1598273d usbmngr: added missing required dm params 2024-07-22 19:57:28 +05:30
Vivek Kumar Dutta
272b7fce34 ieee1905: remove unsupported datamodel parameters 2024-07-22 14:53:23 +05:30
Vivek Kumar Dutta
72f0044f1a dslmngr: Fix validation error on DestinationAddress 2024-07-22 14:48:15 +05:30
Vivek Kumar Dutta
a22a2c4386 icwmp: Allow configuration of cwmp params from USP 2024-07-22 12:30:46 +05:30
Vivek Kumar Dutta
a7a3352bca icwmp: increased diagnostics timer to 60 sec 2024-07-21 09:58:17 +05:30
Vivek Kumar Dutta
38e12b5b95 bbfdm: Added FriendlyName in DeviceInfo 2024-07-19 16:01:50 +05:30
Rahul Thakur
10f3015d32 logmngr: remote uci option file_path
* this is a bit of an overkill and not needed. Instead, we can use
option file to have full path to file including file name.

example: /var/log/messages

* other formatting errors and remove unused function in syslog-ng
2024-07-18 15:48:51 +05:30
Rahul Thakur
3e14637e3d logmngr: add support for syslog-ng backend
- add lib script to convert logmngr uci to syslog-ng.conf
- update makefile to install proper lib file
- fix couple of minor bugs found in fluent-bit.sh
- fix fluent-bit makefile to download code from git
2024-07-18 07:09:41 +00:00
Suvendhu Hansa
a03c7f0681 xmppc: Added LastChangeDate and TLSEstablished DM 2024-07-18 09:20:41 +05:30
Vivek Kumar Dutta
2053e3281f wifidmd: Added MLDUnit in SSID 2024-07-18 09:17:22 +05:30
Vivek Kumar Dutta
625fd2a488 bbfdm: 1.9.11 2024-07-16 21:24:12 +05:30
Vivek Kumar Dutta
99178dacd1 swmodd: Fix race condition in DUStateChange event 2024-07-16 19:54:03 +05:30
Mohd Mehdi
947fe9ef99 bbfdm: add support for Device.IP.ActivePort
active-port sub-package added, which installs:

* JSON datamodel plugin for ActivePort data model object
* daemon that implements active-port ubus call
2024-07-16 14:10:37 +00:00
Vivek Kumar Dutta
d99da1039b tr143: Added required missing usp parameters 2024-07-16 19:27:51 +05:30
Anjan Chanda
94e507b607 libwifi: 7.5.2 2024-07-16 15:38:31 +02:00
Rahul Thakur
eb7fe9572d logmngr: add package
* add logmngr pkg makefile
* add logmngr lib file for fluent-bit as backend
* add logmngr init file
2024-07-15 12:51:45 +00:00
Rahul Thakur
4f9dae3d0e fluent-bit: make functional
* make the fluent-bit functional on target with iowrt
* resolve crash with file output plugin
* setup init file
* setup default conf file - no logging
2024-07-15 12:51:45 +00:00
Anjan Chanda
dc650533f4 ieee1905: 8.5.0 2024-07-15 14:00:49 +02:00
Anjan Chanda
6521b012b3 wifimngr: 17.3.3 2024-07-15 13:59:56 +02:00
Janusz Dziedzic
c75fb703d2 wifimngr: 17.3.2 2024-07-15 11:43:37 +00:00
Janusz Dziedzic
ab250abfdb libwifi: 7.5.1 2024-07-15 11:43:37 +00:00
Rahul Thakur
37111f2233 update package libethernet
* d94e302 libethernet: removed unwanted code in rmon stats
* a82181d libethernet: corrected bcm rmonstats
* be00aa9 econet: Handle unbound HSGMII LAN interfaces.
2024-07-15 16:32:24 +05:30
Rahul Thakur
c4fa5713a2 update package qosmngr
* f6b77d1 Removed unsupported App and Flow parameters
2024-07-15 16:29:39 +05:30
Vivek Kumar Dutta
657b2c7b65 bbfdm: Fix add/del object notification with operate cmd 2024-07-15 11:57:22 +05:30
Vivek Kumar Dutta
b702ff6564 swmodd: Fix duplicate parameters in DUStateChange! 2024-07-15 11:55:18 +05:30
Vivek Kumar Dutta
fb1dc90367 icwmp: optimized InstanceAlias handling 2024-07-13 13:13:38 +05:30
Vivek Kumar Dutta
e57b39b430 bbfdm: Move support for InstanceAlias to cwmp 2024-07-13 13:11:36 +05:30
Vivek Kumar Dutta
cc0e87a0cd tr104: Removed unsupported NumberOfEntries 2024-07-12 12:38:58 +05:30
Vivek Kumar Dutta
dd5bc10c72 wifidmd: Removed unsupported NumberOfEntries parameters 2024-07-12 12:35:08 +05:30
Vivek Kumar Dutta
092c7d139b obuspa: Exception handling for NumberOfEntries registration 2024-07-12 12:32:37 +05:30
Anjan Chanda
137114d62a wifimngr: 17.3.1 2024-07-11 16:14:25 +02:00
Vivek Kumar Dutta
01f88ce2a8 wifidmd: added missing EndPointProfileNumberOfEntries 2024-07-11 18:43:51 +05:30
Vivek Kumar Dutta
243aba8c51 obuspa: re-apply connack clienid persistency 2024-07-11 18:31:26 +05:30
Vivek Kumar Dutta
5211e526ec obuspa: Updated default InheritedRole to UntrustedRole 2024-07-11 11:41:04 +05:30
Vivek Kumar Dutta
c5483f81db obuspa: Integrate v8.0.5 2024-07-10 12:32:12 +00:00
Vivek Kumar Dutta
d8f4afdca5 bbfdm: dm scripts moved to utilities 2024-07-10 18:00:14 +05:30
Mohd Husaam Mehdi
6ef90dcd9d qosmngr: add ebtable handling for loopback (lo) interface
If interface is loopback then we add the rule to nat table's
output chain instead of broute tables BROUTING chain
2024-07-10 04:38:31 +00:00
Strhuan Blomquist
9eb14ac309 fixing #14792 collectd iterates on that queue and tries to write this data to the endpoint. If writing was successful, the data is removed from the queue otherwise data doesn't get removed and collectd will eat all of the memory-. *this fixes that by limiting how much we are allowed to store. 2024-07-09 13:00:00 +00:00
Marek Puzyniak
949b5db030 map-agent: 6.1.1.6 2024-07-09 10:35:33 +00:00
Vivek Kumar Dutta
f42c062c08 firewallmngr: move helper scripts from bbfdm 2024-07-09 06:26:04 +00:00
Vivek Kumar Dutta
42e23d0162 bbfdm: cleanup and update
- move firewall related scripts to firewallmngr
- removed old unused uci-default scripts
2024-07-09 11:47:11 +05:30
Amit Kumar
8794818492 ipt-trigger: updated commit hash
update code of ipt-trigger for correction of condition
for out_trigger function
2024-07-09 11:03:39 +05:30
Anjan Chanda
412c88fb33 wifimngr: 17.3.0 2024-07-05 16:09:37 +02:00
Anjan Chanda
855d29af0c libwifi: 7.5.0 2024-07-05 16:09:17 +02:00
Jakob Olsson
f9757c7f7a map-agent: 6.1.1.5 2024-07-05 15:13:20 +02:00
Jakob Olsson
74eea33f1d map-controller: 6.1.1.5 2024-07-05 15:12:10 +02:00
Vivek Kumar Dutta
0e9146a5c5 obuspa: fix segfault in reboot/reset 2024-07-04 17:47:07 +05:30
Janusz Dziedzic
895c05669b libwifi: 7.4.76 2024-07-01 14:34:22 +00:00
Markus Gothe
7cd7719f9b mcastmngr: Fix L2 snooping hotplug events. 2024-07-01 11:25:06 +00:00
Vivek Kumar Dutta
c76e6142c2 bbfdm: fix update notification with operate commands 2024-07-01 14:52:25 +05:30
Suvendhu Hansa
dc63e6da74 obuspa: persist client id from connack message 2024-07-01 09:09:17 +00:00
Vivek Kumar Dutta
affb07b513 icwmpd: improve error handling in firmware upgrade 2024-06-28 13:34:18 +05:30
Janusz Dziedzic
4ea324f493 libwifi: 7.4.75 2024-06-27 15:21:58 +00:00
Wenpeng Song
156acb308d libvoice-broadcom 1.0.14 :
Update incoming codec for DTMF payload type
2024-06-27 09:56:42 +00:00
Rahul Thakur
e9237858b1 update package qosmngr
* c4db530 qosmngr: Add documentation for VLAN and Pbit translation config
2024-06-20 15:11:01 +05:30
Rahul Thakur
42cf056d57 update package ethmngr
* 2d35e86 Data Model: Add MACVLAN document
2024-06-20 15:09:01 +05:30
Markus Gothe
a16bde6dae remove easy-qos: Deprecated and not used any longer. 2024-06-20 10:55:49 +02:00
Rohit Topno
8b24b648c7 qosmngr: update Makefile for tr-181 vendor extension VLAN ID translation 2024-06-20 11:51:07 +05:30
Vivek Kumar Dutta
df9f5f97af swmodd: Use mounted /container path 2024-06-19 11:36:22 +05:30
Rahul Thakur
8766ee44d6 update package ebtables-extensions
* d3de8b0 fix compilation
2024-06-18 15:13:32 +05:30
Rahul Thakur
1ab0c5b13d update package ebtables-extensions
* 14ceb14 Merge branch 'update-vlanxlate-header' into 'devel'
* afde550 dscp2pbit: fix matching on internally create VLAN headers.
* 5eea71f Merge branch 'update-vlantranslation' into 'devel'
* 1d6d9f5 vlantranslation: Add TPID and tagging support.
2024-06-18 09:15:11 +00:00
Vivek Kumar Dutta
90dfcd0ad3 swmodd: 2.5.11
Update default bundle root to '/container', swmodd only starts if
'/container' mounted and accessible.
Mounting of persistent storage to '/container' is out of scope of swmodd.
2024-06-17 18:27:55 +05:30
Erik Karlsson
72e4b4f0cb usp-js: depend on OBUSPA_ENABLE_TEST_CONTROLLER_LOCAL
This avoids the need for duplicating local MQTT broker setup.
2024-06-17 14:53:23 +05:30
Erik Karlsson
633519ac3a obuspa: split up OBUSPA_ENABLE_TEST_CONTROLLER configuration
A separate OBUSPA_ENABLE_TEST_CONTROLLER_LOCAL configuration is added
which can be used by for example usp-js to accomplish local MQTT
broker setup but without compromising security by enabling remote
access. Appropriate dependencies are also added. In addition
unnecessary uci_load commands and misspelled and unnecessary
require_certificates mosquitto option are removed.
2024-06-17 14:41:59 +05:30
Filip Matusiak
7b4db3d325 decollector: 6.0.0.13 2024-06-13 14:43:42 +02:00
Jakob Olsson
305dd1d6a2 map-agent: 6.1.1.4 2024-06-13 13:24:23 +02:00
Jakob Olsson
5a4eb4d297 map-agent: map_genconfig: if mld is disabled clean mld_ids 2024-06-13 12:21:23 +02:00
Janusz Dziedzic
8f81c1c4c3 libwifi: 7.4.74 2024-06-13 09:24:05 +00:00
Suvendhu Hansa
5d6ae3fc2d obuspa: mqtt retry params runtime update 2024-06-13 14:09:52 +05:30
Vivek Kumar Dutta
faf133212e tr104: align with dm_data structure 2024-06-13 13:27:43 +05:30
Rahul Thakur
3c170edee3 update package qosmngr
* bcf8f36 qosmngr: Add documentation for dscp2pbit mapping configuration
2024-06-13 13:12:18 +05:30
Vivek Kumar Dutta
736885c999 bbfdm: 1.9.4 2024-06-12 20:52:36 +05:30
Vivek Kumar Dutta
b9d8faff99 tr104: 1.0.30 2024-06-12 20:46:24 +05:30
Jakob Olsson
74fec650f6 map-agent: 6.1.1.3 2024-06-12 15:30:09 +02:00
Jakob Olsson
c24ffb6b7c map-controller: 6.1.1.4 2024-06-12 15:25:39 +02:00
Filip Matusiak
280c4e2592 decollector: 6.0.0.12 2024-06-12 15:09:19 +02:00
nevadita.chatterjee
88b31df121 mapcontroller: 6.1.1.3 2024-06-12 17:58:51 +05:30
Mohd Husaam Mehdi
fdd67171bd bridgemngr: add support for ProviderBridge using bridge-vlan 2024-06-12 11:39:36 +00:00
Mohd Husaam Mehdi
826d023608 bridgemngr: add bridge-vlan backend
* add support for compile time flag BRIDGEMNGR_BRIDGE_VLAN
* if this flag is set data model code will use bridge-vlan
  sections to implement vlans on bridges
* if this flag is not set (default), then the data model code
  will use driver level vlans (8021q sections) as always
2024-06-12 11:39:36 +00:00
Vivek Kumar Dutta
925f6217ce usbmngr: 1.0.3 2024-06-12 16:06:54 +05:30
Vivek Kumar Dutta
7c12473940 bbfdm: removed deprecated APIs 2024-06-12 16:06:54 +05:30
Vivek Kumar Dutta
44315a3d75 userinterface: 1.1.4 2024-06-12 16:06:54 +05:30
Rahul Thakur
ebcbc1b2b5 update package libqos
* 6a72e35 libqos: fix log spam for bcm targets
2024-06-12 14:34:20 +05:30
Vivek Kumar Dutta
1fb471872f ddnsmngr: 1.0.7 2024-06-12 10:32:06 +05:30
Vivek Kumar Dutta
5a890b32dc firewallmngr: 1.0.3 2024-06-12 10:28:03 +05:30
Vivek Kumar Dutta
8cc10e6634 dslmngr: 1.2.5 2024-06-12 10:25:38 +05:30
Vivek Kumar Dutta
11f68bdac7 icwmp: 9.7.18 2024-06-12 10:16:30 +05:30
Vivek Kumar Dutta
6751b6667b xmppc: 2.2.9 2024-06-12 10:13:04 +05:30
Anjan Chanda
7b1786d7fe ieee1905: 8.4.6 2024-06-11 15:44:18 +02:00
Yalu Zhang
04fb442a7a libvoice-d2_1.1.12: Fix a bug that the RTCP packets are sent to the wrong port 2024-06-11 15:41:45 +02:00
Marek Puzyniak
0e4f81b7f4 decollector: 6.0.0.11 2024-06-11 08:06:44 +00:00
Vivek Kumar Dutta
b7e0196aa7 firewallmngr: align with bbfdm apis 2024-06-11 10:38:09 +05:30
Amit Kumar
2fdfb8900d mcastmngr: Handled max multicast snoop entry
* removed +2 logic as multicast snoop entry handled in mcproxy
 with logic to exclude count of reserve mcast ip address subnet
2024-06-11 04:57:27 +00:00
Vivek Kumar Dutta
251a9925d2 tr104: align with bbfdm api 2024-06-10 18:43:27 +05:30
Vivek Kumar Dutta
59e8c4d89f ieee1905: align with dm_data datamodel structure 2024-06-10 17:43:57 +05:30
Vivek Kumar Dutta
49930e3f6a icwmp: align with dm_data structure 2024-06-10 17:24:41 +05:30
Vivek Kumar Dutta
4021324465 twamp: align with datamodel api 2024-06-10 17:20:21 +05:30
Marina Maslova
b6930a2056 qosmngr: airoha: fix bw overwrite in case of reload and shaping 2024-06-10 11:07:45 +00:00
Vivek Kumar Dutta
1821af8963 sulu: added cyclonedx sbom 2024-06-10 12:55:30 +05:30
Vivek Kumar Dutta
f33d9e7d53 ethmngr: align with bbfdm datamodel APIs 2024-06-10 12:30:47 +05:30
Vivek Kumar Dutta
879e38773b qosmngr: align with dm_data structure 2024-06-10 12:27:20 +05:30
Vivek Kumar Dutta
c4d0b985e3 sshmngr: align with dm_data structure 2024-06-10 12:16:44 +05:30
Vivek Kumar Dutta
6a8c438907 bridgemngr: align with dm_data structure 2024-06-10 12:11:32 +05:30
Rohit Topno
0e38151087 qosmngr: Support for VLAN ID and p-bit translation 2024-06-10 08:45:29 +05:30
Vivek Kumar Dutta
3766d14b0c swmodd: 2.5.10 2024-06-08 22:56:34 +05:30
Vivek Kumar Dutta
9fcfe8f85d usbmngr: 1.0.2 2024-06-08 22:49:19 +05:30
Amin Ben Romdhane
6c7c2e456c bbfdm: 1.9.2 2024-06-08 12:03:39 +02:00
Amin Ben Romdhane
23fb6bc837 bbfdm: 1.9.1 2024-06-07 16:55:24 +02:00
Yalu Zhang
191bab4b36 libvoice-1.1.11: Play call waiting tone when type II caller ID generation is complete 2024-06-07 16:46:45 +02:00
Janusz Dziedzic
3f9665531b libwifi: 7.4.73 2024-06-07 12:59:13 +00:00
Janusz Dziedzic
3535170fa1 wifimngr: 17.2.8 2024-06-06 17:36:34 +00:00
Markus Gothe
2129df6d5f qosmngr: add support for l3 interfaces
* this commit adds support to use l3 interfaces
  in classification rules.
2024-06-06 04:14:38 +00:00
Janusz Dziedzic
f6fdaafe42 libwifi: 7.4.72 2024-06-05 10:09:08 +00:00
Suvendhu Hansa
b2d07e6e30 ssdpd: align with dm_data 2024-06-05 10:04:32 +00:00
Rohit Topno
1ae6eb33e9 R#14453 - Integrate DSCP2P-bit support in qosmngr and TR181 2024-06-05 10:01:00 +00:00
nevadita.chatterjee
f0d9a40f59 decollector: 6.0.0.10 2024-06-05 12:50:39 +05:30
Vivek Kumar Dutta
4ef5f5427d obuspa: Fix segfault with invalid UDS 2024-06-05 12:34:18 +05:30
Vivek Kumar Dutta
7ac03aa9d0 swmodd: fix compilation 2024-06-05 10:03:40 +05:30
Janusz Dziedzic
07c69b34ea libwifi: 7.4.71 2024-06-04 17:47:02 +00:00
Vivek Kumar Dutta
d2c3cda897 swmodd: config option to select swmodd-cgroups 2024-06-04 22:32:48 +05:30
Vivek Kumar Dutta
8456cf37e3 dhcpmngr: 1.0.2 2024-06-04 22:20:55 +05:30
Vivek Kumar Dutta
2f1d7d5f6c timemngr: 1.0.20 2024-06-04 22:10:02 +05:30
Vivek Kumar Dutta
6e87362a85 icwmp: 9.7.16 2024-06-04 19:21:49 +05:30
Amin Ben Romdhane
36de4ee5a2 bbfdm: bbf.config with C code 2024-06-04 19:05:29 +05:30
Vivek Kumar Dutta
63b6ff0f27 bbfdm: 1.8.27
- Optimized micro-service registrations
- Removed instance saving for ProcessStatus
2024-06-04 17:42:43 +05:30
Vivek Kumar Dutta
78e9f55363 xmppc: align with dm_data structure 2024-06-04 16:58:26 +05:30
Vivek Kumar Dutta
9845ba6d83 usermngr: align with bbfdm api 2024-06-04 16:53:16 +05:30
Vivek Kumar Dutta
d0c1e957f9 wifidmd: 1.0.3 2024-06-04 16:42:38 +05:30
Vivek Kumar Dutta
8c4a5584b9 ddnsmngr: use dm_data structure for multi-instance objects 2024-06-04 16:15:47 +05:30
Vivek Kumar Dutta
0100fa1c93 hostmngr: align with bbfdm api 2024-06-04 15:43:46 +05:30
Jakob Olsson
38118de339 map-agent: introduce config option that passes PERSIST_CONTROLLER CLFLAG 2024-06-04 11:57:25 +02:00
Jakob Olsson
95b9097a3e map-agent: 6.1.1.2 2024-06-04 11:57:25 +02:00
Jakob Olsson
8765ea2733 map-controller: 6.1.1.2 2024-06-04 11:57:25 +02:00
Jakob Olsson
b3f019ed98 map-agent: map_genconfig: don't modify mapcontroller enabled unconditionally 2024-06-04 11:57:25 +02:00
Vivek Kumar Dutta
bd92591b7b fluentbit: 1.0.0 2024-06-04 14:31:27 +05:30
Janusz Dziedzic
e6178dfa65 libwifi: 7.4.70 2024-06-04 05:19:44 +00:00
Arne Jonsson
2412a29226 treewide: change name of package dependency from bcmkernel to bcm963xx-bsp 2024-06-03 15:58:49 +02:00
Filip Matusiak
c80b487052 map-agent: 6.1.1.1 2024-06-03 15:48:34 +02:00
Anjan Chanda
4ca4047418 wifimngr: 17.2.7 2024-06-03 14:27:39 +02:00
Anjan Chanda
c30151607a libwifi: 7.4.69 2024-06-03 14:26:54 +02:00
Anjan Chanda
6df48c0f7f wifimngr: 17.2.5 2024-05-31 14:06:12 +02:00
Jakob Olsson
d67c459153 map-controller: 6.1.1.1 2024-05-30 16:05:35 +02:00
Amin Ben Romdhane
47f5aade80 wifidmd: 1.0.2 2024-05-30 15:38:42 +02:00
Suvendhu Hansa
e06e1db9b0 obuspa: Added config options for vendor extensions 2024-05-30 12:24:44 +00:00
Vivek Kumar Dutta
6bfc426e63 userinterface: 1.1.3 2024-05-30 17:26:39 +05:30
Markus Gothe
04be1d3efd qosmngr: Add option to match on ICMP/ICMPv6 type. 2024-05-30 11:53:41 +00:00
Vivek Kumar Dutta
4b57a9dcd5 tr143: added license file 2024-05-30 17:06:15 +05:30
Vivek Kumar Dutta
0a065403d5 tr471: added license file 2024-05-30 16:46:24 +05:30
Vivek Kumar Dutta
0b598ddfb1 wifidmd: Updated license 2024-05-30 16:02:11 +05:30
Suvendhu Hansa
b5ef7c7278 obuspa: send WakeUp event on ifup 2024-05-30 10:02:16 +00:00
Vivek Kumar Dutta
8ed348342c obuspa: Use WakeUp! event with interface updates 2024-05-30 15:30:29 +05:30
Suvendhu Hansa
aeb966b798 obuspa: Fix dhcp opt125 for controller discovery 2024-05-30 09:47:42 +00:00
Vivek Kumar Dutta
0d9ca4aa94 tr104: align with datamodel reference API 2024-05-30 15:13:43 +05:30
Marina Maslova
3529860fd2 qosmngr: Dynamically allocate uplink bandwidth on Airoha.
In order for the QoS engine to know how much bandwidth
the uplink has got we need to set this with 'qosrule'
every time the uplink changes. Otherwise SP scheduling
will fail.

This fix takes into account when ae_wan is used by ethernet,
fiber and when PON is used as the uplink.
2024-05-30 08:26:38 +00:00
Amin Ben Romdhane
a03ee39fd7 bbfdm: 1.8.26 2024-05-30 09:51:58 +02:00
Amin Ben Romdhane
dca448d139 wifidmd: WiFi Data Model Package 2024-05-30 09:44:01 +02:00
Janusz Dziedzic
8947c5b8c7 wifimngr: 17.2.4 2024-05-29 15:32:57 +00:00
Janusz Dziedzic
572570b0f1 libwifi: 7.4.68 2024-05-29 15:31:47 +00:00
Jakob Olsson
95d200bf3d map-controller: config: remove per-mld encryption 2024-05-29 13:34:34 +02:00
Jakob Olsson
3f58dd2dd2 map-agent: 6.1.1.0 2024-05-29 13:34:14 +02:00
Jakob Olsson
c60672a710 Revert "map-controller: config: add compat APs"
This reverts commit 6fb7284483.
2024-05-29 13:33:06 +02:00
Jakob Olsson
16b6469277 map-controller: 6.1.1.0 2024-05-29 13:33:06 +02:00
Vivek Kumar Dutta
cf18df1a94 icwmp: retries in deviceID get 2024-05-29 16:59:39 +05:30
Janusz Dziedzic
ce6766ba9f wifimngr: 17.2.3 2024-05-28 14:55:25 +00:00
Janusz Dziedzic
0f517dd0e7 libwifi: 7.4.67 2024-05-28 14:54:23 +00:00
Vivek Kumar Dutta
d3be3f9c4f bbfdm: move IEEE1905 DM to ieee1905 2024-05-28 15:20:22 +05:30
Suvendhu Hansa
efd1537a07 ieee1905: Added TR181 IEEE1905 datamodel micro-service 2024-05-28 09:23:51 +00:00
Amin Ben Romdhane
33c9290916 bbfdm: 1.8.24 2024-05-27 18:08:46 +02:00
Amin Ben Romdhane
853c6a8452 udpecho: run udpecho as micro-service 2024-05-27 15:31:27 +00:00
Vivek Kumar Dutta
5526fdb02c obuspa: reduce value change timer to 15s 2024-05-27 18:57:36 +05:30
Vivek Kumar Dutta
df05c3a3d6 ssdpd: added libbbfdm-api dependency 2024-05-24 19:55:54 +05:30
Vivek Kumar Dutta
40d414f791 swmodd: align with datamodel reference api 2024-05-24 18:33:21 +05:30
Vivek Kumar Dutta
0cf8492eab usbmngr: 1.0.1 2024-05-24 18:28:37 +05:30
Vivek Kumar Dutta
4619bf1722 mcastmngr: 1.2.3 2024-05-24 18:27:19 +05:30
Vivek Kumar Dutta
6c52598bfb hostmngr: align with datamodel reference api 2024-05-24 18:24:53 +05:30
Vivek Kumar Dutta
69330c5799 qosmngr: 1.0.11 2024-05-24 18:23:11 +05:30
Vivek Kumar Dutta
67781c7f18 tr143: updated default values for traceroute 2024-05-24 18:19:45 +05:30
Vivek Kumar Dutta
482ddb50e8 icwmp: 9.7.14 2024-05-24 18:16:39 +05:30
Vivek Kumar Dutta
6b937f3248 sshmngr: 1.0.2 2024-05-24 18:12:50 +05:30
Vivek Kumar Dutta
04ddc46cd5 timemngr: align with bbfdm reference api 2024-05-24 18:10:06 +05:30
Vivek Kumar Dutta
51ce00eebe periodicstats: 1.5.11 2024-05-24 18:03:27 +05:30
Vivek Kumar Dutta
611c1414dc icwmp: fault tolerance for gpn/gpv 2024-05-24 18:00:53 +05:30
Vivek Kumar Dutta
5ad1bea18b ddnsmngr: Align with bbfdm reference api 2024-05-24 17:54:59 +05:30
Vivek Kumar Dutta
57339f81be firewallmngr: Align with datamodel reference API 2024-05-24 17:53:05 +05:30
Vivek Kumar Dutta
82762ede0d dnsmngr: Align with datamodel reference API 2024-05-24 17:50:56 +05:30
Vivek Kumar Dutta
4e324f3d18 dhcpmngr: align with datamodel reference api 2024-05-24 17:48:52 +05:30
Vivek Kumar Dutta
8ab10fb3a1 bbfdm: move UPnP datamodel to ssdpd 2024-05-24 17:40:41 +05:30
Suvendhu Hansa
f9a9543726 ssdpd: added Device.UPnP. datamodel 2024-05-24 11:36:17 +00:00
Jakob Olsson
62223cebfd map-controller: 6.1.0.1 2024-05-24 10:37:23 +02:00
Jakob Olsson
6104c14cfd map-agent: 6.1.0.1 2024-05-24 10:36:52 +02:00
Jakob Olsson
6fb7284483 map-controller: config: add compat APs 2024-05-24 10:18:46 +02:00
Anjan Chanda
7c373c2edb decollector: 6.0.0.9 2024-05-24 10:15:49 +02:00
Vivek Kumar Dutta
82390070c1 bbfdm: moved SelfTestDiagnostisc to self-diagnostics 2024-05-24 13:07:38 +05:30
Suvendhu Hansa
c5bfa7332a self-diagnostics: Added datamodel plugin 2024-05-24 12:23:14 +05:30
Vivek Kumar Dutta
e0e9dffee8 bbfdm: moved PacketCaptureDiagnostics 2024-05-24 11:40:31 +05:30
Suvendhu Hansa
b5cfd5410e packet-capture-diagnostics: 1.0.0 2024-05-24 10:56:47 +05:30
Jakob Olsson
7b0e49753e map-controller: config: handle mld and non-mld ap in same section 2024-05-23 16:36:57 +02:00
Jakob Olsson
6a04e6e29a map-controller: 6.1.0.0 2024-05-23 16:35:58 +02:00
Jakob Olsson
9b2ca1bf90 map-agent: 6.1.0.0 2024-05-23 16:35:04 +02:00
Vivek Kumar Dutta
2f2089e114 userinterface: 1.1.2 2024-05-23 18:18:29 +05:30
Vivek Kumar Dutta
b78a542d28 obuspa: move admin and user role to sulu 2024-05-23 12:38:21 +00:00
Vivek Kumar Dutta
08ce89a394 sulu: Use static roles and UserInterface 2024-05-23 12:38:21 +00:00
Janusz Dziedzic
e4416db22b map-agent: 6.0.1.0 2024-05-23 10:38:18 +00:00
Janusz Dziedzic
b5e195499a map-agent: disable island prevention for QCA/MLD
Disable it before real fix.
This allow execute wifi command to recover.

Signed-off-by: Janusz Dziedzic <janusz.dziedzic@iopsys.eu>
2024-05-23 10:36:26 +00:00
Anjan Chanda
eb1d8deeff decollector: 6.0.0.8 2024-05-23 10:08:06 +02:00
Vivek Kumar Dutta
cb37cc60b9 userinterface: Support AllowedRole 2024-05-23 12:53:55 +05:30
Suvendhu Hansa
83277d8a0c usermngr: added static roles 2024-05-23 11:44:31 +05:30
Rahul Thakur
e28f1a653c qosmngr: fix qos reload
* applicable only for linux target
* fix reload to setup qos properly and not overwrite queue on
  reload
* fixed l2 classification broken in reload
2024-05-23 03:37:23 +00:00
Jakob Olsson
c23c0248e1 ieee1905: add dep to libwifiutils 2024-05-22 17:32:48 +02:00
Jakob Olsson
82c064d4d9 ieee1905: 8.4.1 2024-05-22 17:21:17 +02:00
Amin Ben Romdhane
5dc2d1ea7b bbfdm: 1.8.20 2024-05-22 17:10:07 +02:00
Janusz Dziedzic
f072dc5ba3 wifimngr: 17.2.2 2024-05-22 08:50:06 +00:00
Janusz Dziedzic
370af9b5fa libwifi: 7.4.66 2024-05-22 08:50:06 +00:00
Strhuan Blomquist
aff71647aa Update Makefile 2024-05-22 08:33:58 +00:00
Marina Maslova
b6ffbdae70 libqos: 7.2.107 2024-05-21 18:55:24 +04:00
Anjan Chanda
214c588bc1 csmngr: 1.0.2 2024-05-21 13:49:56 +02:00
Rahul Thakur
da91ccda1c ebtables-extensions, qosmngr: fix dependencies
* fix dependencies for the ebtables-extensions and qosmngr packages
* ebtables-extensions should not have dependency on ebtables-legacy
* qosmngr should have dependency on ebtables-legacy for non-brcm targets
* for brcm targets, ebtables from brcm sdk is used
2024-05-21 11:29:54 +00:00
Vivek Kumar Dutta
1d64b9e958 swmodd: Support to define additional eu capabilities 2024-05-21 14:09:25 +05:30
Rahul Thakur
bbe507c740 update package ebtables-extensions
* a23a70f Merge branch 'fix_compilation' into 'devel'
* 824ba7a fix compilation for broadcom target
2024-05-20 16:35:25 +00:00
Amin Ben Romdhane
c36da1cf8e bbfdm: 1.8.19 2024-05-20 14:47:26 +02:00
Amin Ben Romdhane
54172e7065 dnsmngr: 1.0.5 2024-05-20 10:54:58 +02:00
Amin Ben Romdhane
5a145b69f8 tr471: Fix typo 2024-05-18 23:05:32 +02:00
Amin Ben Romdhane
20d861bd21 tr143: Fix typo 2024-05-18 23:05:01 +02:00
Amin Ben Romdhane
dc2ba58371 bbfdm: 1.8.18 2024-05-18 22:49:28 +02:00
Amin Ben Romdhane
e800a445ae tr471: 1.0.0 2024-05-18 22:06:29 +02:00
Amin Ben Romdhane
eadfc0feb3 tr143: 1.0.0 2024-05-18 22:03:49 +02:00
Vivek Kumar Dutta
bf5a6f6c3b bbfdm: bbfdm.mk option to override ubus object name 2024-05-18 21:47:18 +02:00
Vivek Kumar Dutta
4862dec4d9 obuspa: static tr181 role definitions 2024-05-17 19:34:35 +05:30
Vivek Kumar Dutta
56960ef0c0 usermngr: define static tr181 roles 2024-05-17 19:33:26 +05:30
Anjan Chanda
3d5c8467c2 decollector: 6.0.0.7 2024-05-17 15:28:07 +02:00
Rahul Thakur
3fb8a697a0 ebtables-extension: setup repo 2024-05-17 15:09:21 +05:30
Rahul Thakur
c165587b54 ipt-trigger: setup package repo 2024-05-17 12:31:16 +05:30
Janusz Dziedzic
e661570fbd map-agent: 6.0.0.9 2024-05-16 14:29:09 +00:00
Anjan Chanda
28ff0a01df libwifi: 7.4.65 2024-05-16 14:55:01 +02:00
Markus Gothe
86075ea908 Initial addition of ebtables-extensions package. 2024-05-16 11:47:35 +00:00
Amin Ben Romdhane
9ed638eb6b bridgemngr: 1.0.2 2024-05-16 11:50:32 +02:00
Amin Ben Romdhane
4054f8d273 bbfdm: 1.8.17 2024-05-16 11:49:37 +02:00
Jakob Olsson
d44a9e2634 map-agent: 6.0.0.8 2024-05-16 09:58:02 +02:00
Jakob Olsson
e0cdb4020d map-controller: 6.0.0.7 2024-05-16 09:57:24 +02:00
Rahul Thakur
74dadc162f qosmngr: fix lan queue priority for linux target
The lan queue were getting setup in wrong order for SP scheduling,
this commit fixes the order.
2024-05-16 11:39:54 +05:30
Amin Ben Romdhane
e53c25807f bbfdm: 1.8.16 2024-05-15 17:05:33 +02:00
Yalu Zhang
ca64bded7c Update packages voicemngr, libvoice-broadcom and libvoice-d2
Support dynamic DTMF payload type.
2024-05-15 16:41:27 +02:00
Markus Gothe
0709b46a63 mcastmngr: Airoha multicast snooping needs to be toggled to work.
We need to flush the mdb entries when configuring multicast
snooping on Airoha.

This commit fixes a bug where blocking multicast snooping doesn't
work.
2024-05-15 12:02:37 +00:00
Marek Puzyniak
e3be97f48e decollector: 6.0.0.2 2024-05-15 10:35:41 +00:00
Marek Puzyniak
82f0db990f libwifi: 7.4.64 2024-05-15 09:50:42 +00:00
Rahul Thakur
b2d17c0704 Update package urlfilter
* ebf8afb Allow setting URL in Blacklist/Whitelist URL
2024-05-15 09:19:21 +00:00
Vivek Kumar Dutta
47fd6bd077 obuspa: Integrate v8.0.1 2024-05-15 11:22:36 +05:30
Amin Ben Romdhane
8837dc7a6c bridgemngr: 1.0.1 2024-05-14 17:57:02 +02:00
Amin Ben Romdhane
e35f05d037 bbfdm: 1.8.15 2024-05-14 17:20:09 +02:00
Jakob Olsson
5b3d595030 map-controller: 6.0.0.6 2024-05-14 17:00:30 +02:00
Jakob Olsson
dfa9e7357e map-agent: 6.0.0.7 2024-05-14 16:44:57 +02:00
Amin Ben Romdhane
1a63ffbe5a bridgemngr: Bridge datamodel package 2024-05-14 13:22:47 +00:00
Filip Matusiak
5238b0776a map-controller: 6.0.0.5 2024-05-14 09:35:42 +02:00
Vivek Kumar Dutta
28cfda6b96 Revert "obuspa: Integrate v8.0.1"
This reverts commit eeae93881d.
2024-05-14 11:43:08 +05:30
Vivek Kumar Dutta
eeae93881d obuspa: Integrate v8.0.1 2024-05-14 05:27:01 +00:00
Jakob Olsson
5ef2db2754 map-agent: 6.0.0.6 2024-05-13 17:19:56 +02:00
Vivek Kumar Dutta
d3a1612294 obuspa: fixes for downgrade 2024-05-13 10:17:40 +00:00
Mohd Husaam Mehdi
ee619a99a6 firewallmngr: add package Makefile
* add Makefile that adds Device.Firewall. and Device.NAT. tr181
  data model objects as a micro service
* add CONFIG_FIREWALLMNGR_PORT_TRIGGER option, which, when enabled
  includes support for Device.NAT.PortTrigger. object and selects
  appropriate kmod dependencies, and is enabled by default
* copy port-trigger scripts to firewallmngr, as it might be
  archived in future
2024-05-13 14:15:44 +05:30
Rahul Thakur
31c4944988 Update package sshmngr
* cleanup repo
2024-05-10 14:49:50 +05:30
Rahul Thakur
94aeedd9b0 Update package dhcpmngr
* cf8ef8c dhcpmngr: add dhcp related definitions from bbfdm
2024-05-10 14:45:51 +05:30
Vivek Kumar Dutta
3fbe2bd73b bbfdm: move USB dm to usbmngr 2024-05-10 14:05:59 +05:30
Vivek Kumar Dutta
ff6f46dbd2 usbmngr: USB datamodel package 2024-05-10 12:58:20 +05:30
Vivek Kumar Dutta
dc312da663 periodicstats: Added missing reqruired parameters 2024-05-09 10:33:06 +05:30
Vivek Kumar Dutta
c0b8538dfe bbfdm: move legacy time dm to timemngr 2024-05-09 09:04:43 +05:30
Vivek Kumar Dutta
9935c43076 timemngr: config option for legacy time datamodel 2024-05-09 09:00:44 +05:30
Amin Ben Romdhane
0b5b7d4984 bbfdm: 1.8.12 2024-05-08 15:19:32 +02:00
Anjan Chanda
23387f0fcc csmngr: 1.0.1 2024-05-08 14:38:31 +02:00
Anjan Chanda
afe7a13e3c Revert "csmngr: 1.0.1"
This reverts commit 5eb7f17b84.
2024-05-08 14:36:37 +02:00
Anjan Chanda
5eb7f17b84 csmngr: 1.0.1 2024-05-08 14:35:04 +02:00
Mohd Husaam Mehdi
9b7b0184c8 dhcpmngr: add dhcpmngr package to iopsys feed
* add Makefile
* move udhcpc.user.d script used for remaining dhcp lease time to
  this package
2024-05-08 12:33:41 +00:00
Mohd Husaam Mehdi
3f64f35b50 bbfdm: remove script used for providing remaining dhcp leasetime
* remove shell script that used to save dhcp lease start time and
  lease duration so that remaining lease time could be calculated
  (reverts bce42023b1)
2024-05-08 12:31:26 +00:00
Jakob Olsson
58e0b0556a map-agent: 6.0.0.5 2024-05-08 14:15:43 +02:00
Jakob Olsson
0f69d96b8f map-controller: add config option to enable probe requests on ubus 2024-05-08 14:15:43 +02:00
Jakob Olsson
3cc7151326 map-controller: 6.0.0.4 2024-05-08 14:15:43 +02:00
Vivek Kumar Dutta
4191852fcb obuspa: Update log level 2024-05-08 15:18:13 +05:30
Vivek Kumar Dutta
e049486b44 tr104: 1.0.27 2024-05-08 09:13:54 +05:30
Janusz Dziedzic
5fc945c32e libwifi: 7.4.63 2024-05-07 08:47:50 +00:00
Janusz Dziedzic
a021f7984e map-agent: allow to disable mlo
just set fw_setenve disable_mlo 1
2024-05-07 05:10:19 +00:00
Markus Gothe
9a3fbe874e hostmngr: Don't try to resolve IP-adresses in firewall.
Using iptables --list without -n takes a long time
on some configurations during boot up which is a problem.

This commit resolves this by not trying resolve hostnames
as it is not necessary for the functionality.

It also splits up the check in two: one for IPv4 and one
for IPv6 to make the logic more robust and fail-safe.
2024-05-06 15:14:18 +00:00
Vivek Kumar Dutta
b1b86e7093 bbfdm: updated PossibleChannels 2024-05-06 16:51:00 +05:30
Anjan Chanda
5ea3018b02 csmngr: 1.0.0 2024-05-05 16:33:45 +02:00
Roman Azarenko
3f336a21f4 iopsys-analytics: updates to icwmp configuration and core-watcher 2024-05-03 15:46:42 +02:00
Jakob Olsson
ac28911137 map-agent: 6.0.0.4 2024-05-03 13:11:44 +02:00
Jakob Olsson
c04d6e5414 map-controller: config: add 2.4ghz to the default mld 2024-05-03 12:02:16 +02:00
Niall McGee
0745ab63cf swmodd: Get lxc-container state from lxc-info 2024-05-02 13:19:43 +00:00
Mohd Husaam Mehdi
bce42023b1 bbfdm: add udhcpc.user.d script to store dhcp lease start time
DCHP lease start time is needed to calculate remaining lease time
which is needed for Device.DHCPv4.Client.{i}.LeaseTimeRemaining.

Earlier this was being provided via interface.status, but that was
leading to unnecessary hotplug events for interface data update so
it had to be removed from there.

Add the logic in udhcpc.user.d script separate from netifd as
there does not seem to be a need in netifd for this information.
2024-05-01 23:27:16 +05:30
Anjan Chanda
b852055460 wifimngr: 17.2.1 2024-04-30 13:01:05 +02:00
Tomas Bucek
f1acd2b4b1 Fix all_interfaces option in qosmngr 2024-04-29 10:17:27 +00:00
Jakob Olsson
77c62b3059 map-controller: 6.0.0.3 2024-04-26 11:52:34 +02:00
Amin Ben Romdhane
206305fa40 bbfdm: 1.8.9 2024-04-26 00:00:10 +02:00
Anjan Chanda
9a7f798933 decollector: 6.0.0.1 2024-04-25 19:11:01 +02:00
Anjan Chanda
3cabbb6919 wifimngr: 17.2.0 2024-04-25 15:55:11 +02:00
Anjan Chanda
ab0645fe4c libwifi: 7.4.62 2024-04-25 15:54:32 +02:00
Vivek Kumar Dutta
60adf6e369 self-diagnostics: Updated bbfdm microservices 2024-04-25 17:55:01 +05:30
Wenpeng Song
5ca12a752e voicemngr 1.1.12, libvoice-d2 1.1.10, libvoice-broadcom 1.0.12
- voicemngr: Support dtmf relay mode synchronization   
 - libvoice: Support DTMF relay mode configuration
2024-04-25 12:14:40 +00:00
Vivek Kumar Dutta
5fe6420620 icwmp: 9.7.12 2024-04-25 17:19:42 +05:30
Jakob Olsson
fd5ae2b847 map-agent: 6.0.0.3 2024-04-25 13:17:59 +02:00
Jakob Olsson
d1f3854b99 Map-controller: 6.0.0.2 2024-04-25 12:15:45 +02:00
Jakob Olsson
f444ba6651 map-agent: 6.0.0.2 2024-04-25 12:01:56 +02:00
Erik Karlsson
2214fd99e8 mcastmngr: handle multiple upstream interface sections
Do not overwrite mcast configuration if there are multiple interface
sections referring to the same upstream device such as wan/wan6
2024-04-25 10:53:43 +02:00
Markus Gothe
35c5d54a76 urlfilter: Add SKIPLOG target for HTTPS over IPv6.
Add same logic as on HTTPS over IPv4.
The traffic needs to go to the SKIPLOG target to avoid
acceleration breaking things.
2024-04-25 06:51:31 +00:00
Vivek Kumar Dutta
4fd6d70b71 bbfdm: 1.8.8 2024-04-25 11:31:18 +05:30
Markus Gothe
f67d771ea4 ebtables: Use --concurrent to avoid race conditions.
On GenXOS we've for some time used this to avoid running
into issues with reloading scripts at the same time.

Adding the same functionality to feeds/iopsys.
2024-04-25 05:48:52 +00:00
Vivek Kumar Dutta
0fc5cc4442 periodicstats: optimize dm api usages 2024-04-25 08:38:43 +05:30
Vivek Kumar Dutta
9b1d5753eb icwmp: error logs for gpn rpc 2024-04-25 08:15:54 +05:30
Andreas Gnau
34d5a178ae voicemngr: Don't error for non-existing bcm-toolchain.mk
When compiling for other platforms than Broadcom, the broadcom feed with
its packages does not exist, so ignore the error if the file does not
exist.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-04-24 17:05:42 +02:00
Andreas Gnau
6cfb68796e voicemngr: Move bcm-toolchain.mk include
Move bcm-toolchain.mk to further to the top so that the appending to
TARGET_CFLAGS with -Wall -Werror in this file is done properly and not
overridden.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-04-24 17:05:42 +02:00
Andreas Gnau
dcdf4e82e5 voicmngr: Do not set flags for BCM explicitly
Do not set CFLAGS and others explicitly for BCM, the ones set by
bcm-toolchain.mk since feeds/broadcom commit 3191be5482a8 (bcmkernel:
toolchain: Set more flags and tools, 2024-04-17) are sufficient.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-04-24 17:05:42 +02:00
Andreas Gnau
9f3e2ae06d voicemngr: Do not disable CheckDependencies
CheckDependencies failed because DT_RUNPATH had not been set. Since
commit 084691a29a (voicemngr: Do not manually specify BCM lib paths,
2024-03-25) we do set a proper RUNPATH, so we can re-enable dependency
checking.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-04-24 17:05:42 +02:00
Andreas Gnau
0793dccefa libpicoevent-bcm: Do not set custom TARGET_CFLAGS
This is no longer necessary since feeds/broadcom commit 3191be5482a8
(bcmkernel: toolchain: Set more flags and tools, 2024-04-17).

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-04-24 17:05:42 +02:00
Amin Ben Romdhane
5d7350279b bbfdm: 1.8.7 2024-04-24 16:11:20 +02:00
Vivek Kumar Dutta
44d242d4aa tr104: 1.0.26 2024-04-24 19:32:49 +05:30
Jakob Olsson
bae25db654 mapcontroller: config: update default ssid of MLD link interface 2024-04-24 15:43:56 +02:00
Jakob Olsson
a66aacb48d map-controller: 6.0.0.1 2024-04-24 15:06:04 +02:00
Mohd Husaam Mehdi
b7d861466a sshmngr: deprecate sshmngr uci
* sshmngr uci is deprecated and so are the library functions
  related to managing that uci, sshmngr will directly interact
  with the backend uci now
* a compile time flag is introduced which tells sshmngr code
  whether dropbear backend is being used or not
2024-04-24 17:43:34 +05:30
Jakob Olsson
f17c3d4763 map-controller: config: create additional interfaces that are placed in mld 2024-04-24 12:38:34 +02:00
Vivek Kumar Dutta
3ed8832a85 obuspa: use bbf.config for service restart 2024-04-24 16:02:09 +05:30
Vivek Kumar Dutta
11f8d68cc3 icwmp: use bbf.config for service restart 2024-04-24 16:00:30 +05:30
Vivek Kumar Dutta
52551d7357 bbfdm: 1.8.6 2024-04-24 15:57:28 +05:30
Suvendhu Hansa
9d777db805 periodicstats: Support CalculationMode 2024-04-24 09:39:17 +00:00
Janusz Dziedzic
1f3c68ad79 map-agent: 6.0.0.1 2024-04-24 08:54:56 +00:00
Amin Ben Romdhane
34be7d88b0 bbfdm: 1.8.5 2024-04-23 19:17:18 +02:00
Amin Ben Romdhane
62dc2e55d5 mcastmngr: 1.2.2 2024-04-23 17:35:35 +02:00
Amin Ben Romdhane
492579a5d1 bbfdm: 1.8.4 2024-04-23 17:16:34 +02:00
Jakob Olsson
025ce42f56 multi-ap: bump EASYMESH_VERSION to 6 2024-04-23 14:45:16 +02:00
Jakob Olsson
6fef055c62 map-controller: config: configure mld by default 2024-04-23 14:45:16 +02:00
Jakob Olsson
eae6b6b8eb map-agent: map_genconfig: set mlo and mlo_capable in wireless for qca 2024-04-23 14:45:16 +02:00
Vivek Kumar Dutta
23d4e3cf18 icwmp: support to use ca-bundle 2024-04-23 17:50:26 +05:30
Vivek Kumar Dutta
41bcbe55b9 obuspa: enabled debug logs 2024-04-23 17:47:02 +05:30
Vivek Kumar Dutta
63e9af8cc2 obuspa: removed ca-certificates dependency 2024-04-23 17:45:18 +05:30
Vivek Kumar Dutta
40ef251948 Revert "obuspa: option to use system ca-bundle"
This reverts commit 8a759a67e4.
2024-04-23 17:42:23 +05:30
Janusz Dziedzic
ad7d90c070 wifimngr: 17.1.2 2024-04-23 11:30:01 +00:00
Janusz Dziedzic
3b165d9e2f libeasy: 7.4.5 2024-04-23 11:29:02 +00:00
Janusz Dziedzic
190e3cb3a0 libwifi: 7.4.60 2024-04-23 10:39:16 +00:00
Vivek Kumar Dutta
8a759a67e4 obuspa: option to use system ca-bundle 2024-04-23 09:09:22 +05:30
Piotr Kubik
d6edbf4e57 iop: Remove legacy update_package
Replaced by 'set-feed-rev'
2024-04-22 17:06:29 +00:00
Piotr Kubik
c8ab92f6dc iop: Remove legacy commands and files
refs #14205
2024-04-22 17:06:29 +00:00
Jakob Olsson
6e2209f6e0 map-controller: 6.0.0.0 2024-04-22 17:38:02 +02:00
Jakob Olsson
fadc9ffcf4 map-agent: 6.0.0.0 2024-04-22 17:38:02 +02:00
Jakob Olsson
10b627f68c ieee1905: 8.4.0 2024-04-22 17:35:16 +02:00
Janusz Dziedzic
34e29aaf84 wifimngr: 17.1.1 2024-04-22 12:38:05 +00:00
Vivek Kumar Dutta
016dbef779 rulengd: enabled extended regex for pattern matching 2024-04-22 16:56:08 +05:30
Mohd Husaam Mehdi
d95dae7282 sshmngr: remove json_object_get call for memory leak fix 2024-04-22 07:22:02 +00:00
Mohd Husaam Mehdi
b274be6adc dnsmngr: remove json_object_get call to fix memory leak 2024-04-22 12:48:03 +05:30
Vivek Kumar Dutta
975008a951 bbfdm: move UserInterface datamodel 2024-04-20 13:25:53 +05:30
Vivek Kumar Dutta
893c292150 userinterface: nginx backend for http access 2024-04-20 13:03:43 +05:30
Amin Ben Romdhane
3857f5d3ee bbfdm: 1.8.2 2024-04-19 15:51:59 +02:00
Janusz Dziedzic
e09277cdc2 map-agent: 4.6.0.4 2024-04-19 12:02:25 +00:00
Yalu Zhang
37c24c0625 libvoicd-d2-1.1.9: Support remote_loss_rate in RTP statistics 2024-04-19 10:44:46 +02:00
Markus Gothe
354d7e8c22 qosmngr: Fix filtering on TOS field for non-Broadcom platforms. 2024-04-18 19:59:57 +02:00
Yalu Zhang
2409d8f4e0 dectmngr-3.6.6: set DECT reset GPIO pin from dectmngr instead of in init script
The reason is that sysfs for GPIO pins have been deprecated on the newer versions
of Linux kernel.
2024-04-18 13:47:51 +02:00
Mohd Husaam Mehdi
df0e96d9ac sshmngr: avoid losing some backend changes on sshmngr restart
if backend uci is changed then restarting sshmngr can lead to
those changes being lost, try to preserve some of the changes

the following behaviour has been tested:

* if an extra option is set in backend UCI which is not set in
  sshmngr UCI for the same section, it will stay as it is
* manually added section in backend is not over-written
* sshmngr managed sections are properly added/modified/deleted
* option BbfSection is introduced which can be set to 0 to prevent
  sshmngr from modifying a backend section

the above works except for first boot (then sshmngr will override
backend UCI)
2024-04-18 16:35:50 +05:30
Mohd Husaam Mehdi
fae8008269 qosmngr: use bbf_get_reference_param api call
adm_entry_get_reference_param does not seem to work in micro
service mode so use bbf_get_reference_param instead
2024-04-17 15:22:02 +05:30
Vivek Kumar Dutta
a6a3599455 bbfdm: remove tools dependency from build dir 2024-04-17 12:20:44 +05:30
Amin Ben Romdhane
86983e9c9c ponmngr: Fix datamodel json plugin 2024-04-17 04:00:04 +00:00
Vivek Kumar Dutta
b2c5d21322 ponmngr: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
161c89060e udpecho: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
d14dbe80c9 twamp: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
c7a08a2f04 obuspa: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
b104b1997a usermngr: user bbf micro-service as datamodel handler 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
06ac5624ab urlfilter: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
7572e4eb1e tr104: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
eb34cb7cb2 timemngr: fix migration script 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
6fc3ff4750 swmodd: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
cbed9517bc port-trigger: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
2ca9158f15 periodicstats: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
5b77f36ae4 mcastmngr: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
289d805bdc hostmngr: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
ed159425a5 dnsmngr: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
f701de6e47 qosmngr: align with bbfdm 2024-04-17 03:58:46 +00:00
Vivek Kumar Dutta
8f159de428 sshmngr: align with bbfdm microservice install APIs 2024-04-17 03:58:46 +00:00
Anjan Chanda
54aa763d01 ieee1905: 8.3.19 2024-04-16 19:15:57 +02:00
Filip Matusiak
df39cf1e4f map-controller: 4.7.0.4 2024-04-16 13:48:42 +00:00
Vivek Kumar Dutta
3a74eb3d86 ethmngr: align with bbfdm plugin install API 2024-04-16 09:46:58 +00:00
Suvendhu Hansa
46603ce0f2 xmppc: 2.2.7 2024-04-16 08:56:06 +00:00
Vivek Kumar Dutta
3c6f3ab3bf bbfdm: generate error if plugin missing 2024-04-16 11:47:30 +05:30
Vivek Kumar Dutta
02761cabac dslmngr: 1.2.4 2024-04-16 11:33:18 +05:30
Vivek Kumar Dutta
72ff019c46 bbfdm: fix the plugin path in uci-default script 2024-04-16 11:20:18 +05:30
Janusz Dziedzic
f2256e36a1 libwifi: 7.4.59 2024-04-15 18:02:17 +00:00
Wenpeng Song
0772483396 libvoice-d2-1.1.7:
Update UK call progress tones according to SIN350
2024-04-15 14:58:29 +00:00
Yalu Zhang
4956969ef5 libvoice-d2-1.1.7: Reduce source jitter in receiving RTP/RTCP packets 2024-04-15 16:09:59 +02:00
Vivek Kumar Dutta
ed6901fe74 stunc: Align with bbfdm 2024-04-15 19:22:02 +05:30
Vivek Kumar Dutta
f981f1ea39 xmppc: align with bbfdm 2024-04-15 19:22:02 +05:30
Vivek Kumar Dutta
04bc5acf53 icwmp: Align with bbfdm 2024-04-15 19:22:02 +05:30
Vivek Kumar Dutta
35c49cb4b7 ddnsmngr: 1.0.4 2024-04-15 19:22:02 +05:30
Vivek Kumar Dutta
bcd4ad4c24 bulkdata: added datamodel validation 2024-04-15 19:22:02 +05:30
Vivek Kumar Dutta
c3f99c0914 bbfdm: 1.8.0
- New set of APIs to handle plugin installation
- Auto-generate datamodel micro-service plugin to minimize errors
- Added compaction of json datamodel plugin
- Added validation of json plugin while installing
- datamodel service name used in process name and in logging
2024-04-15 19:22:02 +05:30
Vivek Kumar Dutta
67a85ccf49 tr104: 1.0.24 2024-04-15 12:31:02 +05:30
Vivek Kumar Dutta
7df3657de8 periodicstats: Fix reload handler 2024-04-15 12:00:33 +05:30
Vivek Kumar Dutta
0d4b589f86 bbfdm: 1.7.29
- Moved IGMP and MLD vendor extensions to mcastmngr
- Moved Time vendor extensions to timemngr
2024-04-15 11:53:57 +05:30
Vivek Kumar Dutta
fb608ea6ff icwmp: Fix linker for ManageableDevice 2024-04-15 11:50:19 +05:30
Suvendhu Hansa
3b05ec8666 timemngr: added vendor extensions from bbfdm 2024-04-15 11:45:09 +05:30
Anjan Chanda
9463798787 decollector: 4.4.0.5 2024-04-12 16:49:05 +02:00
Janusz Dziedzic
92f1e90079 libwifi: 7.4.58 2024-04-12 11:04:10 +00:00
Wenpeng Song
8b60cb2457 libvoice-broadcom-1.0.11:
- Avoid race conditions between DTMF and FLASH simulation on DECT handsets   
 - Support Poland by adding VRG_COUNTRY_POLAND
2024-04-12 09:04:48 +00:00
Anjan Chanda
0527428f6c ieee1905: 8.3.15 2024-04-11 16:08:50 +02:00
Jakob Olsson
508ff7d041 libwifi: 7.4.57 2024-04-11 15:42:37 +02:00
Vivek Kumar Dutta
53cdb49ba8 obuspa: remove usages of netmode 2024-04-11 16:36:36 +05:30
Vivek Kumar Dutta
cdb76b1c18 obuspc: remove usages of netmode 2024-04-11 16:34:59 +05:30
Filip Matusiak
8ed6bd1bfc map-controller: 4.7.0.3 2024-04-10 14:38:15 +02:00
Jakob Olsson
028efc13c9 map-agent: config: enable island prevention 2024-04-10 14:11:57 +02:00
Anjan Chanda
115234d93b csmngr: 0.0.8 2024-04-10 09:29:25 +02:00
Anjan Chanda
34afbc348d wifimngr: 17.1.0 2024-04-10 09:25:40 +02:00
Anjan Chanda
8842b7e8b8 libwifi: 7.4.56 2024-04-10 09:24:29 +02:00
Mohd Husaam Mehdi
b10d8e0ec6 ponmngr: add Device.XPON. bbf object as a micro service
add Device.XPON. object as a bbf micro service instead of a plugin
as is done currently
2024-04-09 16:16:23 +05:30
Mohd Husaam Mehdi
1ec66d5732 mcastmngr: add IGMP and MLD vendor extensions as micro service
move IGMP and MLD vendor extensions from bbfdm to mcastmngr and
add them as a bbfdm micro service
2024-04-09 08:55:22 +00:00
Andreas Gnau
084691a29a voicemngr: Do not manually specify BCM lib paths
Do not explicitly specify BCM libary search paths. All binaries have a
correct RUNPATH set via feeds/broadcom/bcmkernel/bcm-toolchain.mk and
the Makefile has been updated to respect LDFLAGS. Setting LD_LIBARY_PATH
and specifiying custome library search paths is thus no longer
necessary.

Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
2024-04-09 10:06:47 +02:00
Amin Ben Romdhane
d083dc041e ethmngr: 2.1.6 2024-04-09 09:39:36 +02:00
Amin Ben Romdhane
c0c30ca012 bbfdm: 1.7.28 2024-04-09 09:38:37 +02:00
Markus Gothe
65fbf9958d mcastmngr: Fix typo in Broadcom snooping. 2024-04-09 03:52:52 +00:00
Janusz Dziedzic
c0a6739981 sshmngr: set MaxAuthTries=10
Signed-off-by: Janusz Dziedzic <janusz.dziedzic@iopsys.eu>
2024-04-09 03:50:46 +00:00
Yalu Zhang
81fdef1991 voicemngr-1.1.10: Fix a misleading log message 2024-04-08 16:13:00 +02:00
Janusz Dziedzic
dc0dbb29ff wifimngr: 17.0.17 2024-04-08 07:07:53 +00:00
Vivek Kumar Dutta
aa98c2fff5 bbfdm: move Device.QoS. to qosmngr 2024-04-06 12:53:39 +05:30
Vivek Kumar Dutta
5c935f03fe bbfdm: removed deprecated bbfdm_services.sh script
bbfdm_services.sh script had dependency on init script of package, which adds
the datamodel microserice.

This functionality now optimized and provided with 'bbfdm.mk' compile time
helper utility's 'BbfdmInstallMicroServiceInputFile' function.
2024-04-05 18:15:06 +05:30
Mohd Mehdi
b44e25c8ee sshmngr: remove bbfdm_add_service call from init script 2024-04-05 12:44:47 +00:00
Mohd Husaam Mehdi
822f5624b1 qosmngr: remove bbfdm_add_service call from init script 2024-04-05 17:22:25 +05:30
Vivek Kumar Dutta
60f2fdd7cb sulu: 3.1.59 2024-04-05 15:18:06 +05:30
Mohd Husaam Mehdi
6518f92be7 qosmngr: move Device.QoS. from bbfdm to qosmngr
qos.c and qos.h are now added as a bbfdm micro service
2024-04-05 12:47:08 +05:30
292 changed files with 10241 additions and 7802 deletions

View File

@@ -1,6 +1,4 @@
config BBF_VENDOR_LIST
string "Vendor List"
default "iopsys"
if PACKAGE_bbfdmd
config BBF_VENDOR_PREFIX
string "Vendor Prefix"
@@ -10,14 +8,7 @@ config BBF_OBFUSCATION_KEY
string "Obfuscation key"
default "371d530c95a17d1ca223a29b7a6cdc97e1135c1e0959b51106cca91a0b148b5e42742d372a359760742803f2a44bd88fca67ccdcfaeed26d02ce3b6049cb1e04"
config BBF_TR143
bool "Enable TR-143 Data Model Support"
default y
config BBF_TR471
bool "Enable TR-471 Data Model Support"
default y
config BBF_MAX_OBJECT_INSTANCES
int "Maximum number of instances per object"
default 255
endif

View File

@@ -5,14 +5,14 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=bbfdm
PKG_VERSION:=1.7.25
PKG_VERSION:=1.12.21
USE_LOCAL:=0
ifneq ($(USE_LOCAL),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/bbfdm.git
PKG_SOURCE_VERSION:=d852b8fefa0eb07a7cb9850fa0688d8c94e005a9
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_VERSION:=062c13e83387e3ad37d6caaffd47cf57a1db7c7f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -32,33 +32,64 @@ define Package/libbbfdm-api
ABI_VERSION:=1.0
endef
define Package/libbbfdm
define Package/libbbfdm-ubus
SECTION:=utils
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:=Library for broadband forum data model support
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libbbfdm-api \
+BBF_TR471:obudpst +libopenssl
TITLE:=BBF datamodel ubus library, provides API to expose datamodel over ubus
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libbbfdm-api
endef
define Package/bbfdmd
SECTION:=utils
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:=Datamodel ubus backend
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libbbfdm-api +libbbfdm
TITLE:=Datamodel ubus backend to expose core tree
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libbbfdm-api +libopenssl +libbbfdm-ubus +bbf_configmngr
endef
define Package/libbbfdm/config
source "$(SOURCE)/Config_bbfdm.in"
define Package/dm-service
SECTION:=utils
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
endef
define Package/bbf_configmngr
SECTION:=utils
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:= BBF Config Manager
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json
endef
define Package/bbfdmd/config
source "$(SOURCE)/Config_bbfdmd.in"
endef
define Package/bbf_configmngr/config
source "$(SOURCE)/bbf_configmngr.in"
endef
define Package/libbbfdm-api/description
Library contains the API(UCI, UBUS, JSON, CLI and Browse) of libbbfdm
endef
define Package/libbbfdm/description
Library contains the data model tree. It includes TR181, TR143 data models
define Package/libbbfdm-ubus/description
Library contains the APIs to expose data model over ubus
endef
define Package/bbfdmd/description
Daemon to expose Datamodel core tree
endef
define Package/dm-service/description
Daemon to expose Datamodel micro-service tree
endef
define Package/bbf_configmngr/description
Daemon for handling bbf reload services via ubus bbf.config
endef
ifeq ($(USE_LOCAL),1)
@@ -68,93 +99,97 @@ endef
endif
CMAKE_OPTIONS += \
-DBBF_TR181=ON
-DBBF_WIFI_DATAELEMENTS=ON
ifeq ($(CONFIG_BBF_TR143),y)
CMAKE_OPTIONS += \
-DBBF_TR143=ON
endif
ifeq ($(CONFIG_BBF_TR471),y)
CMAKE_OPTIONS += \
-DBBF_TR471=ON
endif
CMAKE_OPTIONS += \
-DBBF_VENDOR_LIST:String="$(CONFIG_BBF_VENDOR_LIST)" \
-DBBF_VENDOR_PREFIX:String="$(CONFIG_BBF_VENDOR_PREFIX)" \
-DBBF_MAX_OBJECT_INSTANCES:Integer=$(CONFIG_BBF_MAX_OBJECT_INSTANCES)
ifeq ($(CONFIG_PACKAGE_bbfdmd),y)
CMAKE_OPTIONS += \
-DBBF_MAX_OBJECT_INSTANCES:Integer=$(CONFIG_BBF_MAX_OBJECT_INSTANCES) \
-DBBFDMD_MAX_MSG_LEN:Integer=10485760
endif
define Package/libbbfdm-api/install
$(INSTALL_DIR) $(1)/lib
$(CP) $(PKG_BUILD_DIR)/libbbfdm-api/libbbfdm-api.so $(1)/lib/
$(INSTALL_DIR) $(1)/usr/libexec/rpcd
$(CP) $(PKG_BUILD_DIR)/libbbfdm-api/scripts/bbf.secure $(1)/usr/libexec/rpcd/bbf.secure
$(INSTALL_DIR) $(1)/etc/bbfdm
echo "$(CONFIG_BBF_OBFUSCATION_KEY)" > $(1)/etc/bbfdm/.secure_hash
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/libexec/rpcd/bbf.secure $(1)/usr/libexec/rpcd/bbf.secure
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/libexec/rpcd/bbf.diag $(1)/usr/libexec/rpcd/bbf.diag
$(INSTALL_DIR) $(1)/usr/share/bbfdm/scripts/
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/share/bbfdm/scripts/bbf_api $(1)/usr/share/bbfdm/scripts/
$(INSTALL_DIR) $(1)/etc/bbfdm/certificates
echo "$(CONFIG_BBF_OBFUSCATION_KEY)" > $(1)/etc/bbfdm/.secure_hash
endef
define Package/libbbfdm/install
define Package/libbbfdm-ubus/install
$(INSTALL_DIR) $(1)/lib
$(INSTALL_DIR) $(1)/etc/bbfdm
$(INSTALL_DIR) $(1)/etc/bbfdm/dmmap
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_DIR) $(1)/lib/upgrade/keep.d
$(CP) $(PKG_BUILD_DIR)/libbbfdm/libbbfdm.so $(1)/lib/
$(INSTALL_DATA) ./files/lib/upgrade/keep.d/bbf $(1)/lib/upgrade/keep.d/bbf
$(INSTALL_BIN) ./files/etc/uci-defaults/95-portmap-firewall $(1)/etc/uci-defaults/95-portmap-firewall
$(INSTALL_BIN) ./files/etc/uci-defaults/97-firewall-service $(1)/etc/uci-defaults/97-firewall-service
$(INSTALL_BIN) ./files/etc/uci-defaults/99-link-core-plugins $(1)/etc/uci-defaults/99-link-core-plugins
$(INSTALL_BIN) ./files/etc/uci-defaults/90-remove-nonexisting-microservices $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/91-fix-bbfdmd-enabled-option $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/firewall.portmap $(1)/etc/firewall.portmap
$(INSTALL_BIN) ./files/etc/firewall.service $(1)/etc/firewall.service
ifeq ($(findstring iopsys,$(CONFIG_BBF_VENDOR_LIST)),iopsys)
$(call BbfdmInstallPlugin,$(1),$(PKG_BUILD_DIR)/libbbfdm/dmtree/vendor/iopsys/libbbfdm_iopsys_ext.so)
endif
ifeq ($(CONFIG_BBF_TR143),y)
$(INSTALL_DIR) $(1)/usr/share/bbfdm
$(INSTALL_DIR) $(1)/usr/libexec/rpcd
$(CP) $(PKG_BUILD_DIR)/libbbfdm/scripts/* $(1)/usr/share/bbfdm
$(LN) /usr/share/bbfdm/bbf.diag $(1)/usr/libexec/rpcd/bbf.diag
endif
endef
define Package/libbbfdm/prerm
#!/bin/sh
rm -rf /etc/bbfdm/dmmap/*
exit 0
$(CP) $(PKG_BUILD_DIR)/libbbfdm-ubus/libbbfdm-ubus.so $(1)/lib/
endef
define Package/bbfdmd/install
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/etc/hotplug.d/iface
$(INSTALL_DIR) $(1)/etc/bbfdm/dmmap
$(INSTALL_DIR) $(1)/usr/share/bbfdm
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DIR) $(1)/etc/bbfdm
$(INSTALL_CONF) ./files/etc/config/bbfdm $(1)/etc/config/bbfdm
$(INSTALL_CONF) ./files/etc/config/schedules $(1)/etc/config/schedules
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/bbfdmd/ubus/bbfdmd $(1)/usr/sbin/
$(INSTALL_DATA) ./files/etc/bbfdm/input.json $(1)/etc/bbfdm/
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/etc/init.d/bbfdmd $(1)/etc/init.d/bbfdmd
$(INSTALL_CONF) ./files/etc/config/bbfdm $(1)/etc/config/bbfdm
$(INSTALL_BIN) ./files/etc/bbfdm/bbfdm_services.sh $(1)/etc/bbfdm/
$(INSTALL_DIR) $(1)/etc/hotplug.d/iface
$(INSTALL_BIN) ./files/etc/hotplug.d/iface/85-bbfdm-sysctl $(1)/etc/hotplug.d/iface/85-bbfdm-sysctl
$(INSTALL_DIR) $(1)/lib/upgrade/keep.d
$(INSTALL_DATA) ./files/lib/upgrade/keep.d/bbf $(1)/lib/upgrade/keep.d/bbf
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_BIN) ./files/etc/uci-defaults/91-fix-bbfdmd-enabled-option $(1)/etc/uci-defaults/
endef
define Package/dm-service/install
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/etc/init.d/bbfdm.services $(1)/etc/init.d/
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/dm-service/dm-service $(1)/usr/sbin/
endef
define Package/bbf_configmngr/install
$(INSTALL_DIR) $(1)/etc/init.d
ifeq ($(CONFIG_BBF_CONFIGMNGR_C_BACKEND),y)
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/utilities/bbf_configd $(1)/usr/sbin/
$(INSTALL_BIN) ./files/etc/init.d/bbf_configd $(1)/etc/init.d/bbf_configd
$(INSTALL_DIR) $(1)/usr/share/bbfdm/scripts
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/share/bbfdm/scripts/bbf_config_notify.sh $(1)/usr/share/bbfdm/scripts/
endif
ifeq ($(CONFIG_BBF_CONFIGMNGR_SCRIPT_BACKEND),y)
$(INSTALL_DIR) $(1)/usr/libexec/rpcd
$(CP) $(PKG_BUILD_DIR)/utilities/files/usr/libexec/rpcd/bbf.config $(1)/usr/libexec/rpcd/bbf.config
endif
endef
define Package/bbfdmd/prerm
#!/bin/sh
rm -rf /etc/bbfdm/dmmap/*
exit 0
endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/include
$(INSTALL_DIR) $(1)/usr/include/libbbfdm-api
$(INSTALL_DIR) $(1)/usr/include/libbbfdm-ubus
$(INSTALL_DATA) $(PKG_BUILD_DIR)/libbbfdm-api/*.h $(1)/usr/include/libbbfdm-api/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/libbbfdm-ubus/bbfdm-ubus.h $(1)/usr/include/libbbfdm-ubus/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/libbbfdm-api/include/*.h $(1)/usr/include/
$(CP) $(PKG_BUILD_DIR)/libbbfdm-api/libbbfdm-api.so $(1)/usr/lib
$(CP) $(PKG_BUILD_DIR)/libbbfdm-ubus/libbbfdm-ubus.so $(1)/usr/lib
endef
$(eval $(call BuildPackage,bbf_configmngr))
$(eval $(call BuildPackage,libbbfdm-api))
$(eval $(call BuildPackage,libbbfdm))
$(eval $(call BuildPackage,libbbfdm-ubus))
$(eval $(call BuildPackage,bbfdmd))
$(eval $(call BuildPackage,dm-service))

View File

@@ -8,8 +8,6 @@ bbfdm provides few compile time configuration options and compile time help util
| ----------------------- | ------------- | ----------- |
| CONFIG_BBF_VENDOR_LIST | List of vendor extension directories | iopsys |
| CONFIG_BBF_VENDOR_PREFIX | Prefix for Vendor extension datamodel objects/parameters | X_IOPSYS_EU_ |
| CONFIG_BBF_TR143 | Enable/Add TR-143 Data Model Support | y |
| CONFIG_BBF_TR471 | Enable/Add TR-471 Data Model Support | y |
| CONFIG_BBF_MAX_OBJECT_INSTANCES | Maximum number of instances per object | 255 |
| BBF_OBFUSCATION_KEY | Hash used to encode/decode in `bbf.secure` object | 371d530c95a17d1ca223a29b7a6cdc97e1135c1e0959b51106cca91a0b148b5e42742d372a359760742803f2a44bd88fca67ccdcfaeed26d02ce3b6049cb1e04 |
@@ -38,77 +36,3 @@ $ echo -n "Sup3rS3cur3Passw0rd" | sha512sum
bbfdm provides a helper utility [bbfdm.mk](./bbfdm.mk) to install datamodel plugins in bbfdm core or in microservice directory.
### Install datamodel DotSO/JSON plugin in bbfdm core
Utility to install the DotSO/JSON plugin in bbfdm core plugin path
```bash
# inputs:
# $1 => package install directory
# $2 => Plugin artifact
```
Example:
```make
define Package/$(PKG_NAME)/install
$(call BbfdmInstallPlugin,$(1),./files/etc/bbfdm/json/CWMPManagementServer.json)
endef
```
### Install datamodel DotSO/JSON plugin in bbfdm core with priority
Its now possible to overwrite/remove core datamodel with plugin, so, if some datamodel objects/parameters are present in more than one plugin, order in which they loaded into memory becomes crucial, this Utility help to configure a priority order in which they gets loaded in memory.
```bash
# inputs:
# $1 => package install directory
# $2 => Priority of the installed plugin
# $3 => Plugin artifact
```
Example:
```make
define Package/$(PKG_NAME)/install
$(call BbfdmInstallPluginWithPriority,$(1),01,$(PKG_BUILD_DIR)/bbf_plugin/bulkdata.json)
endef
```
> Note: Last loaded plugin gets the highest priority
### Install plugin into micro-service directory
Utility to install the plugin in datamodel microservice directory, ex. user wants to run a datamodel micro-service, it required to install the DotSO/JSON plugin into a non bbf core directory, this utility helps in installing the DotSO/JSON plugin in mentioned directory.
```bash
# inputs:
# $1 => package install directory with micro-service directory
# $2 => Plugin artifact
```
Example:
```make
define Package/$(PKG_NAME)/install
$(call BbfdmInstallPluginInMicroservice,$(1)/etc/bulkdata,$(PKG_BUILD_DIR)/bbf_plugin/bulkdata.json)
endef
```
### Install datamodel micro-service input file
Utility to install the datamodel plugin input file into the bbfdm micro-service directory, so that bbfdm auto start the datamodel micro-service before main bbfdm process.
```bash
# inputs:
# $1 => package install directory
# $2 => Microservice input.json path
```
Example:
```make
define Package/$(PKG_NAME)/install
$(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/bulkdata/input.json)
endef
```

19
bbfdm/bbf_configmngr.in Normal file
View File

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

View File

@@ -2,56 +2,113 @@
# Copyright (C) 2023 IOPSYS
#
# Utility to install the plugin in bbfdm core path
# inputs:
# $1 => package install directory
# $2 => Plugin artifact
#
# Example:
# $(call BbfdmInstallPlugin,$(1),./files/etc/bbfdm/json/CWMPManagementServer.json)
#
define BbfdmInstallPlugin
$(INSTALL_DIR) $(1)/etc/bbfdm/plugins
$(INSTALL_DATA) $(2) $(1)/etc/bbfdm/plugins/
endef
BBFDM_BASE_DM_PATH=/usr/share/bbfdm
BBFDM_INPUT_PATH=/etc/bbfdm/micro_services
BBFDM_DIR:=$(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
# Utility to install the plugin in bbfdm core path with priority
# inputs:
# $1 => package install directory
# $2 => Priority of the installed plugin
# $3 => Plugin artifact
#
# Example:
# $(call BbfdmInstallPluginWithPriority,$(1),01,$(PKG_BUILD_DIR)/bbf_plugin/bulkdata.json)
#
define BbfdmInstallPluginWithPriority
$(INSTALL_DIR) $(1)/etc/bbfdm/plugins
$(INSTALL_DATA) $(3) $(1)/etc/bbfdm/plugins/$(2)_$(shell basename ${3})
endef
#BBFDM_VERSION:=$(shell grep -oP '(?<=^PKG_VERSION:=).*' ${BBFDM_DIR}/Makefile)
#BBFDM_TOOLS:=$(BUILD_DIR)/bbfdm-$(BBFDM_VERSION)/tools
# Utility to install the plugin in datamodel microservice directory
# inputs:
# $1 => package install directory with micro-service directory
# $2 => Plugin artifact
# Utility to install the plugin in bbfdm core path with priority.
# Its now possible to overwrite/remove core datamodel with plugin, so, if some
# datamodel objects/parameters are present in more than one plugin, order in
# which they loaded into memory becomes crucial, this Utility help to configure
# a priority order in which they gets loaded in memory.
#
# ARGS:
# $1 => Plugin artifact
# $2 => package install directory
# $3 => Priority of the installed plugin (Optional)
#
# Note:
# - Last loaded plugin gets the highest priority
#
# Example:
# $(call BbfdmInstallPluginInMicroservice,$(1)/etc/bulkdata,$(PKG_BUILD_DIR)/bbf_plugin/bulkdata.json)
# BBFDM_INSTALL_CORE_PLUGIN ./files/etc/bbfdm/json/CWMPManagementServer.json $(1)
#
# Example to install plugin with priority:
# BBFDM_INSTALL_CORE_PLUGIN ./files/etc/bbfdm/json/CWMPManagementServer.json $(1) 01
#
BBFDM_INSTALL_CORE_PLUGIN:=$(BBFDM_DIR)/tools/bbfdm.sh -p
# Utility to install the micro-service datamodel
# Use Case:
# user wants to run a datamodel micro-service, it required to install the
# DotSO/JSON plugin into a bbf shared directory, this utility helps in
# installing the DotSO/JSON plugin in bbfdm shared directory, and auto-generate
# input file for the micro-service
#
# ARGS:
# $1 => DotSo or Json plugin with complete path
# $2 => package install directory
# $3 => service name
#
# Note:
# - There could be only one main plugin file, so its bind to PKG_NAME
# - Micro-service input.json will be auto generated with this call
# - Use -u (optional argument) to overwrite ubus object name
#
# Example:
# BBFDM_INSTALL_MS_DM $(PKG_BUILD_DIR)/libcwmp.so $(1) $(PKG_NAME)
#
BBFDM_INSTALL_MS_DM:=$(BBFDM_DIR)/tools/bbfdm.sh -m
# Utility to install a plugins in datamodel micro-service
#
# ARGS:
# $1 => DotSo or Json plugin with complete path
# $2 => package install directory
# $3 => service name
#
# Note:
# - Use the service_name/PKG_NAME of the service in which this has to run
#
# Example:
# BBFDM_INSTALL_MS_PLUGIN $(PKG_BUILD_DIR)/libxmpp.so $(1) icwmp
#
BBFDM_INSTALL_MS_PLUGIN:=$(BBFDM_DIR)/tools/bbfdm.sh -m -p
# Utility to install the helper scripts in default bbfdm script path
#
# Use Case:
# User want to install some script for running diagnostics
#
# ARGS:
# $1 => Script with complete path
# $2 => package install directory
#
# Note:
# - Use with -d option to install script in bbf.diag directory
#
# Example:
# BBFDM_INSTALL_SCRIPT $(PKG_BUILD_DIR)/download $(1)
# BBFDM_INSTALL_SCRIPT -d $(PKG_BUILD_DIR)/ipping $(1)
#
BBFDM_INSTALL_SCRIPT:=$(BBFDM_DIR)/tools/bbfdm.sh -s
# Deprecated functions errors
define BbfdmInstallPluginInMicroservice
$(warning # BbfdmInstallPluginInMicroservice function is deprecated, use BBFDM_INSTALL_MS_PLUGIN macro #)
$(INSTALL_DIR) $(1)
$(INSTALL_DATA) $(2) $(1)/
endef
# Utility to install the datamodel plugin input file
# inputs:
# $1 => package install directory
# $2 => Microservice input.json path
#
# Example:
# $(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/bulkdata/input.json)
#
define BbfdmInstallMicroServiceInputFile
$(warning # function BbfdmInstallMicroServiceInputFile deprecated, input file auto generated with BBFDM_INSTALL_MS_DM #)
$(INSTALL_DIR) $(1)/etc/bbfdm/micro_services
$(INSTALL_DATA) $(2) $(1)/etc/bbfdm/micro_services/$(PKG_NAME).json
endef
define BbfdmInstallPlugin
$(warning # function BbfdmInstallPlugin deprecated, use BBFDM_INSTALL_CORE_PLUGIN macro #)
$(INSTALL_DIR) $(1)/etc/bbfdm/plugins
$(INSTALL_DATA) $(2) $(1)/etc/bbfdm/plugins/
endef
define BbfdmInstallPluginWithPriority
$(warning # fucntion BbfdmInstallPluginWithPriority deprecated, use BBFDM_INSTALL_CORE_PLUGIN #)
$(INSTALL_DIR) $(1)/etc/bbfdm/plugins
$(INSTALL_DATA) $(3) $(1)/etc/bbfdm/plugins/$(2)_$(shell basename ${3})
endef

View File

@@ -1,48 +0,0 @@
#!/bin/sh
BBFDMD="/usr/sbin/bbfdmd"
bbfdm_add_service()
{
local name path
name="${1}"
path="${2}"
if [ -z "${name}" -o -z "$path" ]; then
return 0;
fi
ubus call service add "{'name':'bbfdm.services','instances':{'$name':{'command':['$BBFDMD','-m','$path']}}}"
echo "Use of bbfdm_add_service deprecated, please use bbfdm micro_service uci"
}
bbfdm_stop_service()
{
local name
name="${1}"
if [ -z "${name}" ]; then
return 0;
fi
if ubus call service list '{"name":"bbfdm.services"}' |grep -q "bbfdm.$name"; then
ubus call service delete "{'name':'bbfdm.services','instance':'bbfdm.$name'}"
fi
}
usages()
{
echo "Usages $0: <OPTIONS>..."
echo
echo " -h show help"
echo " -k micro-service name to stop"
echo
}
while getopts "s:k:h" opts; do
case "$opts" in
h) usages; exit 0;;
k) bbfdm_stop_service "${OPTARG}";;
esac
done

View File

@@ -1,28 +0,0 @@
{
"daemon": {
"config": {
},
"input": {
"type": "DotSo",
"name": "/lib/libbbfdm.so",
"plugin_dir": "/etc/bbfdm/plugins"
},
"output": {
"type": "UBUS",
"name": "bbfdm"
}
},
"cli": {
"config": {
"proto": "both",
"instance_mode": 0
},
"input": {
"type": "UBUS",
"name": "bbfdm"
},
"output": {
"type": "CLI"
}
}
}

View File

@@ -1,11 +1,8 @@
config bbfdmd 'bbfdmd'
option enable '1'
option loglevel '1'
option refresh_time '120'
option transaction_timeout '30'
option subprocess_level '2'
option debug '0'
option loglevel '3'
config micro_services 'micro_services'
option enable '1'
option enable_core '0'
option enable_respawn '1'

View File

@@ -0,0 +1,2 @@
config global 'global'
option enable '1'

View File

@@ -0,0 +1,36 @@
#!/bin/sh /etc/rc.common
START=80
STOP=10
USE_PROCD=1
PROG=/usr/sbin/bbf_configd
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()
{
create_needed_directories
procd_open_instance "bbf_configd"
procd_set_param command ${PROG}
#procd_append_param command -ddd
procd_set_param respawn
procd_close_instance "bbf_configd"
}
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
done
}

View File

@@ -0,0 +1,109 @@
#!/bin/sh /etc/rc.common
START=60
STOP=8
USE_PROCD=1
PROG=/usr/sbin/dm-service
BBFDM_MICROSERVICE_DIR="/etc/bbfdm/micro_services"
. /usr/share/libubox/jshn.sh
log() {
echo "${@}"|logger -t bbfdmd.services -p info
}
validate_bbfdm_micro_service_section()
{
uci_validate_section bbfdm micro_services "micro_services" \
'enable:bool:true' \
'enable_core:bool:false'
}
_add_microservice()
{
local name path loglevel
local enable enable_core
# Check enable from micro-service
path="${1}"
enable_core="${2}"
name="$(basename ${path})"
name="${name//.json}"
json_load_file "${path}"
json_select daemon
json_get_var enable enable 1
if [ "${enable}" -eq "0" ]; then
log "datamodel micro-service ${name} not enabled"
return 0
fi
json_select config
json_get_var loglevel loglevel 3
procd_open_instance "${name}"
procd_set_param command ${PROG}
procd_append_param command -m "${name}"
procd_append_param command -l "${loglevel}"
if [ "${enable_core}" -eq "1" ]; then
procd_set_param limits core="unlimited"
procd_set_param stdout 1
procd_set_param stderr 1
fi
procd_set_param respawn
procd_close_instance "${name}"
}
configure_bbfdm_micro_services()
{
local enable enable_core
config_load bbfdm
validate_bbfdm_micro_service_section || {
log "Validation of micro_service section failed"
return 1;
}
[ "${enable}" -eq "0" ] && return 0
if [ -d "${BBFDM_MICROSERVICE_DIR}" ]; then
FILES="$(ls -1 ${BBFDM_MICROSERVICE_DIR}/*.json)"
for file in $FILES;
do
[ -e "$file" ] || continue
_add_microservice $file "${enable_core}"
done
fi
}
_start_single_service()
{
local service file
service="${1}"
if [ -d "${BBFDM_MICROSERVICE_DIR}" ]; then
file="$(ls -1 ${BBFDM_MICROSERVICE_DIR}/${service}.json)"
[ -e "$file" ] || return
_add_microservice $file "0"
fi
}
start_service()
{
if [ -n "${1}" ]; then
_start_single_service "${1}"
else
configure_bbfdm_micro_services
fi
}

View File

@@ -1,15 +1,11 @@
#!/bin/sh /etc/rc.common
START=65
START=97
STOP=10
USE_PROCD=1
PROG=/usr/sbin/bbfdmd
BBFDM_JSON_INPUT="/etc/bbfdm/input.json"
BBFDM_MICROSERVICE_DIR="/etc/bbfdm/micro_services"
BBFDM_TEMP_DIR="/tmp/bbfdm"
. /usr/share/libubox/jshn.sh
log() {
@@ -20,102 +16,13 @@ validate_bbfdm_bbfdmd_section()
{
uci_validate_section bbfdm bbfdmd "bbfdmd" \
'enable:bool:true' \
'sock:string' \
'debug:bool:false' \
'loglevel:uinteger:1' \
'refresh_time:uinteger:0' \
'transaction_timeout:uinteger:30' \
'subprocess_level:uinteger'
}
validate_bbfdm_micro_service_section()
{
uci_validate_section bbfdm micro_services "micro_services" \
'enable:bool:true' \
'enable_core:bool:false' \
'enable_respawn:bool:true'
}
bbfdm_add_micro_service()
{
local name path cmd
local enable enable_core enable_respawn
validate_bbfdm_micro_service_section || {
log "Validation of micro_service section failed"
return 1;
}
[ "${enable}" -eq "0" ] && return 0
path="${1}"
name="$(basename ${path})"
name="${name//.json}"
json_init
json_add_string name "bbfdm.services"
json_add_object "instances"
json_add_object "${name}"
json_add_array "command"
json_add_string "" "${PROG}"
json_add_string "" "-m"
json_add_string "" "${path}"
json_close_array
if [ "${enable_core}" -eq "1" ]; then
json_add_object "limits"
json_add_string "core" "unlimited"
json_close_object
json_add_boolean "stdout" 1
json_add_boolean "stderr" 1
fi
if [ "${enable_respawn}" -eq "1" ]; then
json_add_array "respawn"
json_add_string "" "3600"
json_add_string "" "5"
json_add_string "" "5"
json_close_array
fi
json_close_object
json_close_object
cmd="$(json_dump)"
ubus call service add "${cmd}"
}
_add_microservice()
{
local enable loglevel input_json name
name="${1}"
input_json="$(jq -r '.daemon.input.name' ${name})"
if [ -f "${input_json}" ]; then
bbfdm_add_micro_service "${name}"
else
log "Input json [${input_json}] does not defined/present"
fi
}
configure_bbfdm_micro_services()
{
if [ -d "${BBFDM_MICROSERVICE_DIR}" ]; then
FILES="$(ls -1 ${BBFDM_MICROSERVICE_DIR}/*.json)"
for service in $FILES;
do
[ -e "$service" ] || continue
_add_microservice $service
done
fi
ubus call service state '{"name":"bbfdm.services", "spawn":true}'
'loglevel:uinteger:3'
}
configure_bbfdmd()
{
local enable debug sock
local enable debug
local jlog jrefresh jtimeout jlevel
config_load bbfdm
@@ -126,38 +33,23 @@ configure_bbfdmd()
[ "${enable}" -eq 0 ] && return 0
if [ -f "${BBFDM_JSON_INPUT}" ]; then
echo "$(jq --arg log ${loglevel} --arg tran ${transaction_timeout} --arg refresh ${refresh_time} --arg level ${subprocess_level} '.daemon.config += {"loglevel": $log, "refresh_time": $refresh, "transaction_timeout": $tran, "subprocess_level": $level}' ${BBFDM_JSON_INPUT})" > "${BBFDM_TEMP_DIR}/input.json"
fi
procd_set_param command ${PROG}
procd_append_param command -l "${loglevel}"
if [ "${debug}" -eq 1 ]; then
procd_set_param stdout 1
procd_set_param stderr 1
fi
if [ -f "${sock}" ]; then
procd_append_param command -s "${sock}"
fi
}
start_service()
{
mkdir -p ${BBFDM_TEMP_DIR}
configure_bbfdm_micro_services
procd_open_instance "bbfdm"
configure_bbfdmd
procd_set_param respawn
procd_close_instance "bbfdm"
}
stop_service()
{
ubus call service delete '{"name":"bbfdm.services"}'
}
service_triggers()
{
procd_add_reload_trigger "bbfdm"

View File

@@ -1,18 +0,0 @@
#!/bin/sh
. /lib/functions.sh
remove_nonexisting_microservice() {
local input_json
config_get input_json "$1" input_json ""
if [ -z "${input_json}" ]; then
uci_remove bbfdm "${1}"
fi
}
config_load bbfdm
config_foreach remove_nonexisting_microservice "micro_service"
exit 0

View File

@@ -1,18 +0,0 @@
#!/bin/sh
UNIFIED_PATH="/etc/bbfdm/plugins/"
# Link JSON plugins
for f in `ls -1 /etc/bbfdm/json/*.json`; do
echo "# BBFDM JSON plugin ${f} not aligned #"
ln -s ${f} "${UNIFIED_PATH}"
done
# Link DotSo plugins
for f in `ls -1 /usr/lib/bbfdm/*.so`; do
echo "# BBFDM DotSO plugin ${f} not aligned #"
ln -s ${f} "${UNIFIED_PATH}"
done
exit 0

174
bbfdm/tools/bbfdm.sh Executable file
View File

@@ -0,0 +1,174 @@
#!/bin/bash
BBFDM_BASE_DM_PATH="usr/share/bbfdm"
BBFDM_INPUT_PATH="etc/bbfdm/micro_services"
INPUT_TEMPLATE='{"daemon":{"enable":"1","service_name":"template","config":{"loglevel":"3"}}}'
OUT_NAME=""
MICRO_SERVICE=0
SCRIPT=0
DIAG=0
PLUGIN=0
DEST=""
TOOLS="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
SRC=""
while getopts ":mpsdu:" opt; do
case ${opt} in
m)
MICRO_SERVICE=1
;;
p)
PLUGIN=1
;;
s)
SCRIPT=1
;;
d)
DIAG=1
;;
u)
OUT_NAME="${OPTARG}"
;;
?)
echo "Invalid option: ${OPTARG}"
exit 1
;;
esac
done
shift $((OPTIND-1))
SRC="${1}"
shift
DEST="${1}"
shift
DATA="${1}"
install_bin() {
if ! install -m0755 ${1} ${2}; then
echo "Failed to install bin ${1} => ${2}"
exit 1
fi
}
install_dir() {
if ! install -d -m0755 ${1}; then
echo "Failed to create directory ${1}"
exit 1
fi
}
install_data() {
if ! install -m0644 ${1} ${2}; then
echo "Failed to install ${1} => ${2}"
exit 1
fi
}
# Installing datamodel
bbfdm_install_dm()
{
local src dest minfile
src="$1"
dest="$2"
minfile=""
if [ -z ${src} ] || [ -z "${dest}" ] || [ -z "${TOOLS}" ]; then
echo "Invalid input option for install dm $@"
exit 1
fi
if [ ! -f "${src}" ]; then
echo "File $src does not exists..."
exit 1
fi
if [ "${src##*.}" = "json" ]; then
echo "Compacting BBFDM JSON file"
minfile=$(mktemp)
jq -c 'del(..|.description?)' ${src} > ${minfile}
src=${minfile}
if dpkg -s python3-jsonschema >/dev/null 2>&1; then
echo "Verifying bbfdm Datamodel JSON file"
if ! ${TOOLS}/validate_plugins.py ${src}; then
echo "Validation of the plugin failed ${src}"
exit 1
fi
else
echo "## Install python3-jsonschema to verify datamodel plugins"
fi
fi
install_bin ${src} ${dest}
if [ -f "${minfile}" ]; then
rm ${minfile}
fi
}
bbfdm_generate_input()
{
local dest ser
dest_dir=${1}
ser=${2}
dest=${dest_dir}/${ser}.json
if [ -n "${OUT_NAME}" ]; then
echo ${INPUT_TEMPLATE} | jq --arg service "${ser}" --arg OUT "${OUT_NAME}" '.daemon |= (.service_name = $service |.output.name = $OUT)' > ${dest}
else
echo ${INPUT_TEMPLATE} | jq --arg service "${ser}" '.daemon.service_name = $service' > ${dest}
fi
chmod 466 ${dest}
}
if [ -z "$SRC" ] || [ -z "${DEST}" ] ; then
echo "# BBFDM Null value in src[${SRC}], dest[${DEST}]"
exit 1
fi
if [ "${SCRIPT}" -eq "1" ]; then
if [ "${DIAG}" -eq "1" ]; then
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/scripts/bbf_diag
install_bin ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/scripts/bbf_diag/
else
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/scripts
install_bin ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/scripts/
fi
exit 0
fi
if [ "${MICRO_SERVICE}" -eq "1" ]; then
if [ -z "${DATA}" ]; then
echo "# service_name[${DATA}] not provided"
exit 1
fi
if [ "${PLUGIN}" -ne "1" ]; then
extn="$(basename ${SRC})"
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services/${DATA}.${extn##*.}
# main micro-service datamodel plugin, create an input file as well
install_dir ${DEST}/${BBFDM_INPUT_PATH}
bbfdm_generate_input ${DEST}/${BBFDM_INPUT_PATH}/ ${DATA}
else
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services/${DATA}
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/micro_services/${DATA}/$(basename ${SRC})
fi
else
if [ "${PLUGIN}" -eq "1" ]; then
priority="${DATA:-0}"
install_dir ${DEST}/${BBFDM_BASE_DM_PATH}/plugins
if [ "${priority}" -gt "0" ]; then
# install with priority if defined
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/plugins/${priority}_$(basename ${SRC})
else
bbfdm_install_dm ${SRC} ${DEST}/${BBFDM_BASE_DM_PATH}/plugins/$(basename ${SRC})
fi
fi
fi

330
bbfdm/tools/validate_plugins.py Executable file
View File

@@ -0,0 +1,330 @@
#!/usr/bin/python3
# Copyright (C) 2024 iopsys Software Solutions AB
# Author: Amin Ben Romdhane <amin.benromdhane@iopsys.eu>
import sys
import json
from jsonschema import validate
JSON_PLUGIN_VERSION = 0
obj_schema = {
"definitions": {
"type_t": {
"type": "string",
"enum": [
"object"
]
},
"map_type_t": {
"type": "string",
"enum": [
"uci",
"ubus"
]
},
"protocols_t": {
"type": "string",
"enum": [
"cwmp",
"usp"
]
}
},
"type" : "object",
"properties" : {
"type" : {"$ref": "#/definitions/type_t"},
"version" : {"type": "string"},
"protocols" : {"type" : "array", "items" : {"$ref": "#/definitions/protocols_t"}},
"uniqueKeys" : {"type" : "array"},
"access" : {"type" : "boolean"},
"array" : {"type" : "boolean"},
"mapping" : {"type" : "object", "properties" : {
"type" : {"$ref": "#/definitions/map_type_t"},
"uci" : {"type" : "object", "properties" : {
"file" : {"type": "string"},
"section" : {"type": "object", "properties" : {
"type" : {"type": "string"}
}
},
"dmmapfile" : {"type": "string"}
}
},
"ubus" : {"type" : "object", "properties" : {
"object" : {"type": "string"},
"method" : {"type": "string"},
"args" : {"type": "object"},
"key" : {"type": "string"}
}
}
}
}
},
"required": [
"type",
"protocols",
"array",
"access"
]
}
obj_schema_v1 = {
"definitions": {
"type_t": {
"type": "string",
"enum": [
"object"
]
},
"map_type_t": {
"type": "string",
"enum": [
"uci",
"ubus"
]
},
"protocols_t": {
"type": "string",
"enum": [
"cwmp",
"usp",
"none"
]
}
},
"type" : "object",
"properties" : {
"type" : {"$ref": "#/definitions/type_t"},
"version" : {"type": "string"},
"protocols" : {"type" : "array", "items" : {"$ref": "#/definitions/protocols_t"}},
"uniqueKeys" : {"type" : "array"},
"access" : {"type" : "boolean"},
"array" : {"type" : "boolean"},
"mapping" : {"type" : "array", "items" : {
"type" : "object", "properties" : {
"type" : {"$ref": "#/definitions/map_type_t"},
"uci" : {"type" : "object", "properties" : {
"file" : {"type": "string"},
"section" : {"type": "object", "properties" : {
"type" : {"type": "string"}
}
},
"dmmapfile" : {"type": "string"}
}
},
"ubus" : {"type" : "object", "properties" : {
"object" : {"type": "string"},
"method" : {"type": "string"},
"args" : {"type": "object"},
"key" : {"type": "string"}
}
}
}
}
}
},
"required": [
"type",
"protocols",
"array",
"access"
]
}
param_schema = {
"definitions": {
"type_t": {
"type": "string",
"enum": [
"string",
"unsignedInt",
"unsignedLong",
"int",
"long",
"boolean",
"dateTime",
"hexBinary",
"base64",
"decimal"
]
},
"map_type_t": {
"type": "string",
"enum": [
"uci",
"ubus",
"procfs",
"sysfs",
"json",
"uci_sec"
]
},
"protocols_t": {
"type": "string",
"enum": [
"cwmp",
"usp",
"none"
]
}
},
"type" : "object",
"properties" : {
"type" : {"$ref": "#/definitions/type_t"},
"protocols" : {"type" : "array", "items" : {"$ref": "#/definitions/protocols_t"}},
"read" : {"type" : "boolean"},
"write" : {"type" : "boolean"},
"mapping" : {"type" : "array", "items" : {"type": "object", "properties" : {
"type" : {"$ref": "#/definitions/map_type_t"},
"uci" : {"type" : "object", "properties" : {
"file" : {"type": "string"},
"section" : {"type": "object", "properties" : {
"type" : {"type": "string"},
"index" : {"type": "string"}
}
},
"option" : {"type": "object", "properties" : {
"name" : {"type": "string"} }
}
}
},
"ubus" : {"type" : "object", "properties" : {
"object" : {"type": "string"},
"method" : {"type": "string"},
"args" : {"type": "object"},
"key" : {"type": "string"}
}
},
"procfs" : {"type" : "object", "properties" : {
"file" : {"type": "string"}
}
},
"sysfs" : {"type" : "object", "properties" : {
"file" : {"type": "string"}
}
}
}
}
}
},
"required": [
"type",
"protocols",
"read",
"write"
]
}
event_schema = {
"definitions": {
"type_t": {
"type": "string",
"enum": [
"event"
]
},
"protocols_t": {
"type": "string",
"enum": [
"usp"
]
}
},
"type" : "object",
"properties" : {
"type" : {"$ref": "#/definitions/type_t"},
"version" : {"type": "string"},
"protocols" : {"type" : "array", "items" : {"$ref": "#/definitions/protocols_t"}}
},
"required": [
"type",
"protocols"
]
}
command_schema = {
"definitions": {
"type_t": {
"type": "string",
"enum": [
"command"
]
},
"protocols_t": {
"type": "string",
"enum": [
"usp"
]
}
},
"type" : "object",
"properties" : {
"type" : {"$ref": "#/definitions/type_t"},
"async" : {"type" : "boolean"},
"protocols" : {"type" : "array", "items" : {"$ref": "#/definitions/protocols_t"}},
"input" : {"type" : "object"},
"output" : {"type" : "object"}
},
"required": [
"type",
"async",
"protocols"
]
}
def print_validate_json_usage():
print("Usage: " + sys.argv[0] + " <dm json file>")
print("Examples:")
print(" - " + sys.argv[0] + " datamodel.json")
print(" ==> Validate the json file")
print("")
exit(1)
def parse_value( key , value ):
if key.endswith('.') and not key.startswith('Device.'):
print(key + " is not a valid path")
exit(1)
if key.endswith('.') and (JSON_PLUGIN_VERSION == 1 or JSON_PLUGIN_VERSION == 2):
__schema = obj_schema_v1
elif key.endswith('.'):
__schema = obj_schema
elif key.endswith('!'):
__schema = event_schema
elif key.endswith('()'):
__schema = command_schema
else:
__schema = param_schema
validate(instance = value, schema = __schema)
for k, v in value.items():
if k != "list" and k != "mapping" and k != "input" and k != "output" and isinstance(v, dict):
parse_value(k, v)
### main ###
if len(sys.argv) < 2:
print_validate_json_usage()
json_file = open(sys.argv[1], "r", encoding='utf-8')
try:
json_data = json.loads(json_file.read())
except ValueError:
print(sys.argv[1] + " file has a wrong JSON format!!!!!")
exit(1)
for __key, __value in json_data.items():
if __key == "json_plugin_version":
if not isinstance(__value, int) or __value not in [0, 1, 2]:
raise ValueError("Invalid value for json_plugin_version")
JSON_PLUGIN_VERSION = __value
continue
parse_value(__key , __value)
print("JSON File is Valid")

17
bridgemngr/Config.in Normal file
View File

@@ -0,0 +1,17 @@
if PACKAGE_bridgemngr
menu "Configuration"
config BRIDGEMNGR_BRIDGE_VLAN
bool "Use bridge-vlan backend"
help
Set this option to use bridge-vlan as backend for VLAN objects.
config BRIDGEMNGR_BRIDGE_VENDOR_EXT
bool "Use bridge BBF vendor extensions"
default y
help
Set this option to use bridge BBF vendor extensions.
endmenu
endif

63
bridgemngr/Makefile Normal file
View File

@@ -0,0 +1,63 @@
#
# Copyright (C) 2020-2024 iopsys
#
include $(TOPDIR)/rules.mk
PKG_NAME:=bridgemngr
PKG_VERSION:=1.0.7
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:=4f22b4a4270c8d9b94b9de6f5cbe2a1dd86a3027
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
PKG_LICENSE:=GPL-2.0-only
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include ../bbfdm/bbfdm.mk
define Package/bridgemngr
CATEGORY:=Utilities
TITLE:=Bridge Manager
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef
define Package/bridgemngr/description
Package to add Device.Bridging. data model support.
endef
define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
MAKE_PATH:=src
TARGET_CFLAGS += -DBBF_VENDOR_PREFIX=\\\"$(CONFIG_BBF_VENDOR_PREFIX)\\\"
ifeq ($(CONFIG_BRIDGEMNGR_BRIDGE_VLAN),y)
TARGET_CFLAGS += -DBRIDGE_VLAN_BACKEND
endif
define Package/bridgemngr/install
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libbridgemngr.so $(1) $(PKG_NAME)
ifeq ($(CONFIG_BRIDGEMNGR_BRIDGE_VENDOR_EXT), y)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/src/libbridgeext.so $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_PLUGIN) ./files/VLAN_Filtering_Extension.json $(1) $(PKG_NAME)
endif
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) ~/git/bridgemngr/* $(PKG_BUILD_DIR)/
endef
endif
$(eval $(call BuildPackage,bridgemngr))

View File

@@ -0,0 +1,31 @@
{
"json_plugin_version": 2,
"Device.Bridging.Bridge.{i}.": {
"type": "object",
"protocols": [
"cwmp",
"usp"
],
"access": true,
"array": true,
"{BBF_VENDOR_PREFIX}VLANFiltering": {
"type": "boolean",
"read": true,
"write": true,
"protocols": [
"cwmp",
"usp"
],
"datatype": "boolean",
"description": "Enable or disable VLAN Filtering on this bridge.",
"mapping": [
{
"data": "@Parent",
"type": "uci_sec",
"key": "vlan_filtering"
}
]
}
}
}

View File

@@ -7,13 +7,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=bulkdata
PKG_VERSION:=2.1.9
PKG_VERSION:=2.1.14
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/bulkdata.git
PKG_SOURCE_VERSION:=e472e90feec31d9f318ea8c732ab564002e25db1
PKG_SOURCE_VERSION:=93c9e87cb9f8f635cece1473cff6f67cff9ff7c0
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -24,12 +24,17 @@ PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/$(PKG_NAME)
define Package/bulkdata
SECTION:=utils
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:=BBF BulkData Collection
DEPENDS:=+libubus +libuci +libubox +libjson-c +libcurl +libblobmsg-json +zlib
DEPENDS:=+ubus +libuci +libubox +libjson-c +libcurl +libblobmsg-json +zlib
DEPENDS+=+libbbfdm-api +libbbfdm-ubus
endef
define Package/bulkdata/description
BulkData daemon for TR069 with bbfdm backend.
endef
TARGET_CFLAGS += \
@@ -42,18 +47,13 @@ define Build/Prepare
endef
endif
define Package/$(PKG_NAME)/install
define Package/bulkdata/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/etc/bulkdata
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_BIN) $(PKG_BUILD_DIR)/bulkdatad $(1)/usr/sbin/
$(INSTALL_DATA) ./files/etc/config/bulkdata $(1)/etc/config/
$(INSTALL_BIN) ./files/etc/init.d/bulkdatad $(1)/etc/init.d/
$(INSTALL_DATA) ./files/etc/uci-defaults/95-bulkdata-translation-options $(1)/etc/uci-defaults/
$(call BbfdmInstallPluginInMicroservice,$(1)/etc/bulkdata,$(PKG_BUILD_DIR)/bbf_plugin/bulkdata.json)
$(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/bulkdata/input.json)
endef
$(eval $(call BuildPackage,$(PKG_NAME)))
$(eval $(call BuildPackage,bulkdata))

View File

@@ -1,17 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "JSON",
"name": "/etc/bulkdata/bulkdata.json"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"object": "BulkData",
"root_obj": "bbfdm"
}
}
}

View File

@@ -7,25 +7,24 @@ USE_PROCD=1
PROG="/usr/sbin/bulkdatad"
start_service() {
local enable
config_load bulkdata
config_get_bool enable bulkdata enable 1
[ "$enable" -eq "1" ] && {
procd_open_instance "bulkdata"
procd_set_param command "$PROG"
procd_set_param respawn
procd_close_instance "bulkdata"
}
procd_open_instance "bulkdata"
procd_set_param command "$PROG"
procd_set_param respawn
procd_close_instance "bulkdata"
}
reload_service() {
stop
start
ret=$(ubus call service list '{"name":"bulkdatad"}' | jsonfilter -qe '@.bulkdatad.instances.bulkdata.running')
if [ "$ret" != "true" ]; then
stop
start
else
ubus send bulkdata.reload
fi
return 0
}
service_triggers()
{
service_triggers() {
procd_add_reload_trigger bulkdata
}

View File

@@ -1,75 +0,0 @@
#!/bin/sh
. /lib/functions.sh
PROFILE_COUNT=1
get_next_count()
{
local config="$1"
local default_name="${2}"
local count=${3}
local found=0
if [ -z "$count" ]; then
count=1
fi
while [ "${found}" -ne 1 ]; do
uci -q get "${config}"."${default_name}"_${count} >/dev/null
if [ "$?" -eq 0 ]; then
count=$((count + 1))
else
found=1;
fi
done
echo "${default_name}_${count}"
}
translate_profile_id_to_profile_name() {
local section="${1}"
local profile_id="${2}"
local profile_name="${3}"
local curr_profile_id
config_get curr_profile_id "${section}" profile_id
[ -n "${curr_profile_id}" ] || return
[ "${curr_profile_id}" != "${profile_id}" ] && return
uci -q set bulkdata."${section}".profile_name="${profile_name}"
uci -q set bulkdata."${section}".profile_id=""
}
update_profile_sections() {
local section="${1}"
local default="${2}"
local profile_name
config_get profile_id "${section}" profile_id
[ -n "${profile_id}" ] || return
case "${section}" in
"cfg"*)
profile_name="$(get_next_count bulkdata "${default}" ${PROFILE_COUNT})"
uci_rename bulkdata "${section}" "${profile_name}"
;;
esac
PROFILE_COUNT=$((PROFILE_COUNT + 1))
[ -n "$profile_name" ] && section="${profile_name}"
uci -q set bulkdata."${section}".profile_id=""
config_foreach translate_profile_id_to_profile_name profile_parameter "${profile_id}" "${profile_name}"
config_foreach translate_profile_id_to_profile_name profile_http_request_uri_parameter "${profile_id}" "${profile_name}"
}
config_load bulkdata
config_foreach update_profile_sections profile profile
uci commit bulkdata
exit 0

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=csmngr
PKG_VERSION:=0.0.5
PKG_VERSION:=1.0.2
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=dcdaba75b85bf8758c34d3ae4a1be0ba09359331
PKG_SOURCE_VERSION:=5e50fe388fff29b08d895c1c580152cccfa290ad
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/csmngr.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ddnsmngr
PKG_VERSION:=1.0.3
PKG_VERSION:=1.0.9
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/ddnsmngr.git
PKG_SOURCE_VERSION:=d0d37df44644ef2c1a0b11d3a4f92dc694ae1010
PKG_SOURCE_VERSION:=5144e73fad92d23ae706894a4357436c3fe89355
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -28,7 +28,8 @@ define Package/$(PKG_NAME)
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:=Dynamic DNS manager
DEPENDS:=+libbbfdm-api +DDNSMNGR_BACKEND_DDNSSCRIPT:ddns-scripts +DDNSMNGR_BACKEND_INADYN:inadyn
DEPENDS:=+DDNSMNGR_BACKEND_DDNSSCRIPT:ddns-scripts +DDNSMNGR_BACKEND_INADYN:inadyn
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
MENU:=1
endef
@@ -49,17 +50,13 @@ endef
endif
define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/etc/ddnsmngr
$(INSTALL_DIR) $(1)/etc/ddnsmngr/ddns
$(INSTALL_DIR) $(1)/etc/ddnsmngr/servers
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/lib/ddnsmngr
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_DIR) $(1)/usr/libexec/rpcd
$(call BbfdmInstallPluginInMicroservice,$(1)/etc/ddnsmngr,$(PKG_BUILD_DIR)/src/libddnsmngr.so)
$(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/ddnsmngr/input.json)
$(INSTALL_DATA) ./files/etc/config/ddnsmngr $(1)/etc/config/ddnsmngr
$(INSTALL_BIN) ./files/etc/uci-defaults/01-ddns-config-migrate $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/init.d/ddnsmngr $(1)/etc/init.d/ddnsmngr
@@ -74,6 +71,7 @@ ifeq ($(CONFIG_DDNSMNGR_BACKEND_INADYN),y)
$(INSTALL_DATA) $(PKG_BUILD_DIR)/files/inadyn/server/* $(1)/etc/ddnsmngr/servers
$(INSTALL_BIN) $(PKG_BUILD_DIR)/files/inadyn/usr/libexec/rpcd/ddnsmngr $(1)/usr/libexec/rpcd/ddnsmngr
endif
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libddnsmngr.so $(1) $(PKG_NAME)
endef

View File

@@ -1,17 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "DotSo",
"name": "/etc/ddnsmngr/libddnsmngr.so"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"object": "DynamicDNS",
"root_obj": "bbfdm"
}
}
}

View File

@@ -2,6 +2,6 @@ menu "Configuration"
config DECOLLECTOR_EASYMESH_VERSION
int "Support Easymesh version"
default 4
default 6
endmenu

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=decollector
PKG_VERSION:=4.4.0.1
PKG_VERSION:=6.1.0.3
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=a42af441d0efc315714305d6b944e6b09a29b64d
PKG_SOURCE_VERSION:=005a48c7a40c3fcf89d031fda0e109a25431b20e
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.6.5
PKG_VERSION:=3.7.1
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/dectmngr.git
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=192e74db2082e3f89f6defe9d752d752b0b09079
PKG_SOURCE_VERSION:=daf66f6f2098a343fefb304e7ce9440f55ea1cd1
PKG_MIRROR_HASH:=skip
endif
@@ -28,7 +28,7 @@ include $(INCLUDE_DIR)/package.mk
define Package/$(PKG_NAME)
CATEGORY:=Utilities
TITLE:=DECT Manager
DEPENDS:= +libubox +ubus +uci +libxml2 +libjson-c +gpiod-tools
DEPENDS:= +libubox +ubus +uci +libxml2 +libjson-c +gpiod-tools +voicemngr
endef
define Package/$(PKG_NAME)/description

View File

@@ -11,8 +11,6 @@ LOG_PATH=/var/log/dectmngr
DB_PATH=/etc/dect
DCX81_UART_DT_ALIAS=/proc/device-tree/aliases/dcx81-uart
DECT_GPIO="$(gpiofind DCX81_RSTN | cut -d ' ' -f 2 2>/dev/null)"
# Ask dectmngr to exit nicely and wait for it to clean up, which is a slow process.
stop_and_wait_dectmngr() {
dect_pid=$(pidof $PROG)
@@ -64,8 +62,6 @@ start_service() {
dcx81_uart_device=/dev/ttyH0
fi
[ -n "$DECT_GPIO" ] && echo 1 > /sys/class/gpio/gpio${DECT_GPIO}/value
rfpi=$(db -q get hw.board.dect_rfpi)
[ -n "$rfpi" -a ${#rfpi} -eq 14 ] && opt_ext="$opt_ext -rfpi $rfpi"
@@ -112,7 +108,6 @@ start_service() {
stop_service() {
has_dect || return 0
[ -n "$DECT_GPIO" ] && echo 0 > /sys/class/gpio/gpio${DECT_GPIO}/value
stop_and_wait_dectmngr
}
@@ -126,11 +121,6 @@ service_triggers() {
}
boot() {
[ -n "$DECT_GPIO" ] && {
echo ${DECT_GPIO} > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio${DECT_GPIO}/direction
}
[ ! -d $LOG_PATH ] && mkdir -p $LOG_PATH
[ ! -d $DB_PATH ] && mkdir -p $DB_PATH
start

57
dhcpmngr/Makefile Normal file
View File

@@ -0,0 +1,57 @@
#
# Copyright (C) 2024 IOPSYS Software Solutions AB
#
include $(TOPDIR)/rules.mk
PKG_NAME:=dhcpmngr
PKG_VERSION:=1.0.4
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/dhcpmngr.git
PKG_SOURCE_VERSION:=2a517188211849bcc324a9f9727eeb34d076c032
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include ../bbfdm/bbfdm.mk
MAKE_PATH:=src
define Package/dhcpmngr
SECTION:=net
CATEGORY:=Network
TITLE:=Package to add Device.DHCPv4 and v6 data model support.
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +odhcpd
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
DEPENDS+=+DNSMNGR_DNS_SD:umdns
DEPENDS+=+DNSMNGR_BACKEND_DNSMASQ:dnsmasq
endef
define Package/dhcpmngr/description
Package to add Device.DHCPv4. and Device.DHCPv6. data model support.
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/dhcpmngr/* $(PKG_BUILD_DIR)/
endef
endif
define Package/dhcpmngr/install
$(INSTALL_DIR) $(1)/etc/udhcpc.user.d
$(INSTALL_BIN) ./files/etc/udhcpc.user.d/udhcpc_lease_start_time.user $(1)/etc/udhcpc.user.d/udhcpc_lease_start_time.user
ifeq ($(CONFIG_DNSMNGR_BACKEND_UNBOUND),y)
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_DATA) ./files/etc/uci-defaults/unbound.odhcpd.uci_default $(1)/etc/uci-defaults/16-set-unbound-as-odhcpd-leasetrigger
endif
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libdhcpmngr.so $(1) $(PKG_NAME)
endef
$(eval $(call BuildPackage,dhcpmngr))

View File

@@ -0,0 +1,18 @@
#!/bin/sh
# update odhcpd uci to use unbound's script as leasetrigger
uci -q get dhcp.odhcpd >/dev/null 2>&1 && {
maindhcp="$(uci -q get dhcp.odhcpd.maindhcp)"
# if odhcpd is the main dhcp
[ "$maindhcp" = "1" ] || [ "$maindhcp" = "true" ] || [ "$maindhcp" = "on" ] && {
# if unbound daemon and unbound script file is present
[ -e /usr/lib/unbound/odhcpd.sh ] && [ -e /usr/sbin/unbound ] && {
# then set unbound script as leasetrigger in dhcp UCI
uci -q set dhcp.odhcpd.leasetrigger='/usr/lib/unbound/odhcpd.sh'
uci commit dhcp
}
}
}
exit 0

View File

@@ -0,0 +1,14 @@
#!/bin/sh
leasestarttime="$(awk -F'.' '{print $1}' /proc/uptime 2> /dev/null)"
target_file=/tmp/dhcp_client_info
target_str="$INTERFACE $lease $leasestarttime"
# if this interface is present in file, then replace it
if grep -q "$INTERFACE" "$target_file" 2> /dev/null; then
# replace the whole line if pattern matches
sed -i "/${INTERFACE}/c\\${target_str}" "$target_file"
else
# interface info was not present, append it to the file
echo "$target_str" >> "$target_file"
fi

30
dnsmngr/Config.in Normal file
View File

@@ -0,0 +1,30 @@
if PACKAGE_dnsmngr
menu "Configuration"
config DNSMNGR_DNS_SD
bool "Include Device.DNS.SD. TR-181 support"
default y
help
Set this option to include support for TR-181 DNS.SD. object.
choice
prompt "Select backend for DNS management"
default DNSMNGR_BACKEND_DNSMASQ
depends on PACKAGE_dnsmngr
help
Select which backend daemon to use for DNS
config DNSMNGR_BACKEND_DNSMASQ
bool "Use dnsmasq for dns and dhcp"
help
Enable this option to use dnsmasq + odhcpd for dns and dhcp.
config DNSMNGR_BACKEND_UNBOUND
bool "Use unbound with odhcpd-full for dns and dhcp"
help
Enable this option to use unbound + odhcpd for dns and dhcp.
endchoice
endmenu
endif

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=dnsmngr
PKG_VERSION:=1.0.3
PKG_VERSION:=1.0.12
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/dnsmngr.git
PKG_SOURCE_VERSION:=347070e096b98946ba660791e3c78d1646adc54a
PKG_SOURCE_VERSION:=fb49088ddb498980e2c91f03aea10bd502caeca1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -27,24 +27,48 @@ MAKE_PATH:=src
define Package/dnsmngr
SECTION:=net
CATEGORY:=Network
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +libbbfdm-api +dnsmasq +umdns
TITLE:=Package to add Device.DNS. datamodel support
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +odhcpd
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
DEPENDS+=+DNSMNGR_DNS_SD:umdns
DEPENDS+=+DNSMNGR_BACKEND_DNSMASQ:dnsmasq
DEPENDS+=+DNSMNGR_BACKEND_UNBOUND:unbound-daemon +DNSMNGR_BACKEND_UNBOUND:unbound-control
TITLE:=Package to configure DNS backend and TR-181 support
endef
define Package/dnsmngr/description
Package to add Device.DNS. datamodel support.
Package to configure DNS backend and TR-181 support.
endef
define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(CONFIG_DNSMNGR_DNS_SD),y)
define Build/Compile
$(call Build/Compile/Default,all)
endef
else
define Build/Compile
$(call Build/Compile/Default,dns)
endef
endif
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/dnsmngr/* $(PKG_BUILD_DIR)/
endef
endif
ifeq ($(CONFIG_DNSMNGR_BACKEND_DNSMASQ),y)
TARGET_CFLAGS += -DDNSMASQ_BACKEND
endif
define Package/dnsmngr/install
$(INSTALL_DIR) $(1)/etc/dnsmngr
$(CP) $(PKG_BUILD_DIR)/src/libdnsmngr.so $(1)/etc/dnsmngr
$(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/dnsmngr/input.json)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libdnsmngr.so $(1) $(PKG_NAME)
$(BBFDM_INSTALL_SCRIPT) -d $(PKG_BUILD_DIR)/scripts/nslookup $(1)
ifeq ($(CONFIG_DNSMNGR_DNS_SD),y)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/src/libdns_sd.so $(1) $(PKG_NAME)
endif
endef
$(eval $(call BuildPackage,dnsmngr))

View File

@@ -1,17 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "DotSo",
"name": "/etc/dnsmngr/libdnsmngr.so"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"object": "DNS",
"root_obj": "bbfdm"
}
}
}

View File

@@ -8,13 +8,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=dslmngr
PKG_VERSION:=1.2.3
PKG_VERSION:=1.2.8
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=6009d4cdabc2fb6827a1dd6096a96e720e97750b
PKG_SOURCE_URL:=https://dev.iopsys.eu/hal/dslmngr.git
PKG_SOURCE_VERSION:=5340cb31f759301f5aca3fd848fc3a63b0b4663f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MAINTAINER:=Rahul Thakur <rahul.thakur@iopsys.eu>
PKG_MIRROR_HASH:=skip
@@ -40,7 +40,8 @@ define Package/dslmngr
SECTION:=utils
CATEGORY:=Utilities
TITLE:=XDSL status and configration utility
DEPENDS:=+libdsl +libuci +libubox +ubus +libpthread +libnl-genl +libeasy +libbbfdm-api
DEPENDS:=+libdsl +libuci +libubox +ubus +libpthread +libnl-genl +libeasy
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef
define Package/dslmngr/description
@@ -77,7 +78,7 @@ ifeq ($(CONFIG_TARGET_brcmbca),y)
endif
$(INSTALL_DIR) $(1)/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/dslmngr $(1)/sbin/
$(CP) $(PKG_BUILD_DIR)/libbbfdsl.so $(1)/etc/dsl/
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/libbbfdsl.so $(1) $(PKG_NAME)
endef
$(eval $(call BuildPackage,dslmngr))

View File

@@ -211,8 +211,8 @@ create_ptm_devices() {
prioritize_arp()
{
ebtables -t nat -D POSTROUTING -j mark --mark-or 0x7 -p ARP >/dev/null
ebtables -t nat -A POSTROUTING -j mark --mark-or 0x7 -p ARP >/dev/null
ebtables --concurrent -t nat -D POSTROUTING -j mark --mark-or 0x7 -p ARP >/dev/null
ebtables --concurrent -t nat -A POSTROUTING -j mark --mark-or 0x7 -p ARP >/dev/null
}
xtm_remove_devices() {

View File

@@ -1,17 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "DotSo",
"name": "/etc/dsl/libbbfdsl.so"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"root_obj": "bbfdm",
"multiple_objects": ["DSL","PTM","ATM","FAST"]
}
}
}

View File

@@ -1,47 +0,0 @@
#
# Copyright (C) 2019 iopsys Software Solutions AB
#
# This is free software, licensed under the GNU General Public License v2.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=easy-qos
PKG_VERSION:=1.1
PKG_RELEASE:=0
PKG_LICENSE:=GPLv2
PKG_LICENSE_FILES:=none
include $(INCLUDE_DIR)/package.mk
define Package/easy-qos
SECTION:=net
CATEGORY:=Network
TITLE:=Easy QoS
DEPENDS:=@(TARGET_brcmbca||TARGET_airoha)
endef
define Package/easy-qos/description
This package contains Easy QoS utility
endef
define Build/Prepare
mkdir -p $(PKG_BUILD_DIR)
$(CP) ./files/* $(PKG_BUILD_DIR)/
endef
define Build/Compile
endef
define Package/easy-qos/install
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(CP) ./files/etc/config/easy_qos $(1)/etc/config/
$(CP) ./files/etc/init.d/easy_qos.iptables $(1)/etc/init.d/easy_qos
$(CP) ./files/etc/uci-defaults/* $(1)/etc/uci-defaults/
$(CP) ./files/etc/firewall.easyqos $(1)/etc/firewall.easyqos
endef
$(eval $(call BuildPackage,easy-qos))

View File

@@ -1 +0,0 @@
/etc/init.d/easy_qos reload

View File

@@ -1,140 +0,0 @@
#!/bin/sh /etc/rc.common
START=99
USE_PROCD=1
log() {
echo "${@}"|logger -t easy_qos.ebtable -p debug
}
exec_log() {
${@}
if [ "${?}" -ne 0 ]; then
log "Failed to create ${@}";
fi
}
get_priority() {
local prio=$(echo $1|tr 'A-Z' 'a-z');
case "${prio}" in
"lowest")
echo 0;;
"low")
echo 1;;
"besteffort")
echo 2;;
"normal")
echo 3;;
"video")
echo 4;;
"medium")
echo 5;;
"high")
echo 6;;
"highest")
echo 7;;
esac
}
validate_rule_section()
{
uci_validate_section easy_qos rule "${1}" \
'priority:string' \
'macaddr:string' \
'proto:string:none' \
'port:list(uinteger)' \
'comment:string:none'
}
# Clear existing rules before applying new rules
clear_existing_rules() {
local rule=$(ebtables -t broute -L BROUTING|grep -m 1 mark)
while [ -n "${rule}" ]; do
exec_log ebtables -t broute -D BROUTING ${rule}
rule=$(ebtables -t broute -L BROUTING|grep -m 1 mark)
done
}
create_rule() {
local protocol=$1; shift
local mac=$1; shift
local mark="0x$1"; shift
local forward_port=$1;
local cmd="";
local protocol_number
cmd="-j mark --mark-or ${mark}";
if [ -n "${forward_port}" ]; then
cmd="--ip-destination-port ${forward_port} ${cmd}";
fi
case "${protocol}" in
"tcp")
protocol_number=6;;
"udp")
protocol_number=17;;
"dccp")
protocol_number=33;;
"sctp")
protocol_number=132;;
*)
log "Protocol ${protocol} not supported in ebtables"
return;;
esac
cmd="--ip-proto ${protocol_number} $cmd"
cmd="-p ip $cmd"
cmd="-s ${mac} $cmd"
exec_log ebtables -t broute -A BROUTING ${cmd}
}
manage_rule() {
local cfg="$1"
local priority macaddr proto port comment prio_num protocol
validate_rule_section "${1}" || {
log "Validation of section failed"
return 1;
}
protocol=$(echo ${proto}|tr 'A-Z' 'a-z')
prio_num=$(get_priority ${priority})
if [ -n "${macaddr}" -a -n "${prio_num}" ]; then
for p in ${port}; do
if [ "${protocol}" == "none" -o "${protocol}" == "tcpudp" ]; then
create_rule tcp ${macaddr} ${prio_num} ${p}
create_rule udp ${macaddr} ${prio_num} ${p}
else
create_rule ${protocol} ${macaddr} ${prio_num} ${p}
fi
done
# Create rule for all ports if port is not mentioned in uci
if [ -z "${port}" ]; then
if [ "${protocol}" == "none" -o "${protocol}" == "tcpudp" ]; then
create_rule tcp ${macaddr} ${prio_num}
create_rule udp ${macaddr} ${prio_num}
else
create_rule ${protocol} ${macaddr} ${prio_num}
fi
fi
fi
}
reload_service() {
# Do not apply rules if ebtables is not present in system
[ -x /usr/sbin/ebtables ] || return;
clear_existing_rules
config_load easy_qos
config_foreach manage_rule rule
}
start_service() {
reload_service
}
service_triggers() {
procd_add_reload_trigger "easy_qos"
}

View File

@@ -1,186 +0,0 @@
#!/bin/sh /etc/rc.common
. /usr/share/libubox/jshn.sh
START=99
USE_PROCD=1
CLIENT_LIST="/tmp/easy_qos_client.list"
log() {
echo "${@}"|logger -t easy_qos -p debug
}
exec_log() {
${@}
if [ "${?}" -ne 0 ]; then
log "Failed to create ${@}";
fi
}
get_priority() {
local prio=$(echo $1|tr 'A-Z' 'a-z');
case "${prio}" in
"lowest")
echo 0;;
"low")
echo 1;;
"besteffort")
echo 2;;
"normal")
echo 3;;
"video")
echo 4;;
"medium")
echo 5;;
"high")
echo 6;;
"highest")
echo 7;;
esac
}
clean_client_entries() {
[ -f ${CLIENT_LIST} ] && rm ${CLIENT_LIST}
}
map_client_entries() {
local clients ip mac host
json_load "$(ubus call router.network 'clients')"
json_get_keys keys
for key in ${keys};
do
json_select ${key}
json_get_vars ipaddr macaddr hostname
clients="${macaddr} ${ipaddr} ${hostname};${clients}"
json_select ..
done
json_init
# json_add_array "clients"
IFS=";"
for client in ${clients};
do
macaddr=$(echo ${client} | cut -d" " -f1)
json_add_object "${macaddr//:/_}"
json_add_string "ip" "$(echo ${client} | cut -d" " -f2)"
json_add_string "macaddr" "$(echo ${client} | cut -d" " -f1)"
json_add_string "host" "$(echo ${client} | cut -d" " -f3)"
json_close_object
done
IFS=' '
echo `json_dump` > ${CLIENT_LIST}
json_cleanup
}
# Find the IP of a corresponding mac from arp table
get_ipaddress() {
local clients ip mac host
json_load "$(cat ${CLIENT_LIST})"
json_get_keys keys
# jshn seems a bit iffy on having : in key, replace by _
json_select "${1//:/_}" 2 > /dev/null
json_get_var ip ip
echo "$ip"
}
validate_rule_section()
{
uci_validate_section easy_qos rule "${1}" \
'priority:string' \
'macaddr:string' \
'proto:string:none' \
'port:list(uinteger)' \
'comment:string:none'
}
# Clear existing rules before applying new rules
clear_existing_rules() {
local rule=$(iptables -t mangle -S PREROUTING | grep -m 1 MARK |sed 's/-A/-D/1')
while [ -n "${rule}" ]; do
exec_log iptables -t mangle ${rule}
rule=$(iptables -t mangle -S PREROUTING | grep -m 1 MARK |sed 's/-A/-D/1')
done
}
check_and_create() {
iptables -t mangle -C PREROUTING ${@} 2>/dev/null
# Create rule if not exists
if [ ${?} -ne 0 ]; then
exec_log iptables -t mangle -A PREROUTING ${@}
else
log "Rule exists for ${@}"
fi
}
create_rule() {
local proto=$1; shift
local src_ip=$1; shift
local mark="0x$1/0x$1"; shift
local ports=$1;
local cmd="";
cmd="-j MARK --set-xmark ${mark}";
if [ -n "${ports}" ]; then
cmd="--match multiport --dports ${ports} ${cmd}";
fi
if [ "${proto}" == "icmp" ]; then
cmd="-p icmp -m icmp --icmp-type 8 $cmd"
elif [ "${proto}" == "all" ]; then
cmd="-p all $cmd"
else
cmd="-p ${proto} -m ${proto} $cmd"
fi
cmd="-s ${src_ip} $cmd"
check_and_create ${cmd}
}
manage_rule() {
local cfg="$1"
local priority macaddr proto port comment prio_num ip port_list
validate_rule_section "${1}" || {
log "Validation of section failed"
return 1;
}
prio_num=$(get_priority ${priority})
ip=$(get_ipaddress ${macaddr})
port_list=$(echo ${port}|sed 's/ /,/g')
if [ -n "${ip}" -a -n "${prio_num}" ]; then
if [ "${proto}" == "none" -o "${proto}" == "tcpudp" ]; then
create_rule tcp ${ip} ${prio_num} ${port_list}
create_rule udp ${ip} ${prio_num} ${port_list}
else
create_rule ${proto} ${ip} ${prio_num} ${port_list}
fi
fi
}
reload_service() {
clear_existing_rules
map_client_entries
config_load easy_qos
config_foreach manage_rule rule
clean_client_entries
}
start_service() {
reload_service
echo "Easy QoS installed">/dev/console;
}
service_triggers() {
procd_add_reload_trigger "easy_qos"
}

View File

@@ -1,8 +0,0 @@
# Add firewall include
uci -q batch <<-EOT
delete firewall.easyqos
set firewall.easyqos=include
set firewall.easyqos.path=/etc/firewall.easyqos
set firewall.easyqos.reload=1
commit firewall
EOT

View File

@@ -0,0 +1,80 @@
#
# Copyright (C) 2024 IOPSYS Software Solutions AB
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=ebtables-extensions
PKG_VERSION:=1.0.4
PKG_LICENSE:=GPL-2.0
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=35fb79f95c47d90e3791c7e126048b451f078f24
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/ebtables-extensions.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
include $(INCLUDE_DIR)/package.mk
define KernelPackage/vlantranslation
SUBMENU:=Other modules
TITLE:=Kernel module for ebtables VLAN translation
FILES:=$(PKG_BUILD_DIR)/src/ebt_vlantranslation.ko
DEPENDS+=+kmod-ebtables
AUTOLOAD:=$(call AutoLoad,30,ebt_vlantranslation,1)
KCONFIG:=
endef
define KernelPackage/dscp2pbit
SUBMENU:=Other modules
TITLE:=Kernel module for DSCP-to-Pbit mapping
DEPENDS+=+kmod-ebtables
FILES:=$(PKG_BUILD_DIR)/src/ebt_dscp2pbit.ko
AUTOLOAD:=$(call AutoLoad,30,ebt_dscp2pbit,1)
KCONFIG:=
endef
define KernelPackage/vlantranslation/description
Kernel module to enable VLAN translation for ebtables
endef
define KernelPackage/dscp2pbit/description
Kernel module to enableDSCP-to-Pbit mapping for ebtables
endef
ifeq ($(CONFIG_TARGET_brcmbca),y)
include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
endif
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ./src/* $(PKG_BUILD_DIR)/
$(CP) $(PKG_BUILD_DIR)/src/ebt_vlantranslation.h $(LINUX_DIR)/include/uapi/linux/netfilter_bridge/
$(CP) $(PKG_BUILD_DIR)/src/ebt_dscp2pbit.h $(LINUX_DIR)/include/uapi/linux/netfilter_bridge/
endef
else
define Build/Prepare
$(Build/Prepare/Default)
$(CP) $(PKG_BUILD_DIR)/src/ebt_vlantranslation.h $(LINUX_DIR)/include/uapi/linux/netfilter_bridge/
$(CP) $(PKG_BUILD_DIR)/src/ebt_dscp2pbit.h $(LINUX_DIR)/include/uapi/linux/netfilter_bridge/
endef
endif
define Build/InstallDev
$(INSTALL_DIR) $(1)/include/uapi/linux/netfilter_bridge/
$(CP) $(PKG_BUILD_DIR)/src/ebt_vlantranslation.h $(1)/include/uapi/linux/netfilter_bridge/
$(CP) $(PKG_BUILD_DIR)/src/ebt_dscp2pbit.h $(1)/include/uapi/linux/netfilter_bridge/
endef
KERNEL_MAKE_FLAGS += -I$(LINUX_DIR)/include
define Build/Compile
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/src" modules
endef
$(eval $(call KernelPackage,vlantranslation))
$(eval $(call KernelPackage,dscp2pbit))

View File

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ethmngr
PKG_VERSION:=2.1.5
PKG_VERSION:=2.1.9
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=53d31f7027f759a36f47c026c50eaee2888619cc
PKG_SOURCE_URL:=https://dev.iopsys.eu/hal/ethmngr.git
PKG_SOURCE_VERSION:=2d35e86cc8dfd7ef4e0d8579f5d314e90faadc90
PKG_MAINTAINER:=Rahul Thakur <rahul.thakur@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip
@@ -27,7 +27,8 @@ define Package/ethmngr
SECTION:=utils
CATEGORY:=Utilities
TITLE:=Ethernet status and configration utility
DEPENDS:=+(TARGET_brcmbca||TARGET_airoha||TARGET_ipq95xx||TARGET_ipq53xx||TARGET_mediatek):libethernet +libuci +libubox +ubus +libpthread +libnl-genl +libeasy +libbbfdm-api
DEPENDS:=+(TARGET_brcmbca||TARGET_airoha||TARGET_ipq95xx||TARGET_ipq53xx||TARGET_mediatek):libethernet +libuci +libubox +ubus +libpthread +libnl-genl +libeasy
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef
define Package/ethmngr/description
@@ -69,9 +70,10 @@ ifneq ($(CONFIG_TARGET_brcmbca)$(CONFIG_TARGET_airoha)$(CONFIG_TARGET_ipq95xx)$(
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/ethmngr $(1)/usr/sbin/
endif
$(CP) $(PKG_BUILD_DIR)/libbbfethernet.so $(1)/etc/ethmngr
$(CP) $(PKG_BUILD_DIR)/libbbfethernetmacvlan.so $(1)/etc/ethmngr/plugins
$(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/bbfdm/micro_services/ethernet.json)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/libbbfethernet.so $(1) $(PKG_NAME)
ifeq ($(CONFIG_TR181_VENDOR_EXTENSIONS_MACVLAN),y)
$(BBFDM_INSTALL_MS_PLUGIN) $(PKG_BUILD_DIR)/libbbfethernetmacvlan.so $(1) $(PKG_NAME)
endif
endef
$(eval $(call BuildPackage,ethmngr))

View File

@@ -1,18 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "DotSo",
"name": "/etc/ethmngr/libbbfethernet.so",
"plugin_dir": "/etc/ethmngr/plugins"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"object": "Ethernet",
"root_obj": "bbfdm"
}
}
}

12
firewallmngr/Config.in Normal file
View File

@@ -0,0 +1,12 @@
if PACKAGE_firewallmngr
menu "Configuration"
config FIREWALLMNGR_PORT_TRIGGER
bool "Include Device.NAT.PortTrigger"
default y
help
Set this option to include support for PortTrigger object.
endmenu
endif

75
firewallmngr/Makefile Normal file
View File

@@ -0,0 +1,75 @@
#
# Copyright (C) 2024 IOPSYS Software Solutions AB
#
include $(TOPDIR)/rules.mk
PKG_NAME:=firewallmngr
PKG_VERSION:=1.0.6
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/firewallmngr.git
PKG_SOURCE_VERSION:=2cac05871f7a8d93c144157c5f3f129deecf1a29
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include ../bbfdm/bbfdm.mk
MAKE_PATH:=src
define Package/firewallmngr
SECTION:=net
CATEGORY:=Network
TITLE:=Package to add Device.Firewall and Device.NAT. data model support.
DEPENDS:=+libuci +libubox +libubus +libblobmsg-json +libjson-c +firewall
DEPENDS+=+FIREWALLMNGR_PORT_TRIGGER:kmod-ipt-trigger +FIREWALLMNGR_PORT_TRIGGER:kmod-ip6t-trigger
DEPENDS+=+FIREWALLMNGR_PORT_TRIGGER:iptables-mod-nfqueue
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef
define Package/firewallmngr/description
Package to add Device.Firewall. and Device.NAT. data model support.
endef
define Package/$(PKG_NAME)/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/firewallmngr/* $(PKG_BUILD_DIR)/
endef
endif
ifeq ($(CONFIG_FIREWALLMNGR_PORT_TRIGGER),y)
TARGET_CFLAGS += -DINCLUDE_PORT_TRIGGER
endif
define Package/firewallmngr/install
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DIR) $(1)/etc/uci-defaults
ifeq ($(CONFIG_FIREWALLMNGR_PORT_TRIGGER),y)
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/lib/port-trigger
$(INSTALL_BIN) ./files/port-trigger/etc/init.d/port-trigger $(1)/etc/init.d/
$(INSTALL_DATA) ./files/port-trigger/etc/config/port-trigger $(1)/etc/config/
$(INSTALL_DATA) ./files/port-trigger/lib/port-trigger/port_trigger.sh $(1)/lib/port-trigger/
endif
$(INSTALL_BIN) ./files/firewall.portmap $(1)/etc/
$(INSTALL_DATA) ./files/etc/uci-defaults/95-portmap-firewall $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/firewall.service $(1)/etc/
$(INSTALL_DATA) ./files/etc/uci-defaults/97-firewall-service $(1)/etc/uci-defaults/
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/libfirewallmngr.so $(1) $(PKG_NAME)
endef
$(eval $(call BuildPackage,firewallmngr))

View File

@@ -0,0 +1 @@
#port trigger uci file

View File

@@ -0,0 +1,21 @@
#!/bin/sh /etc/rc.common
START=65
STOP=20
USE_PROCD=1
. /lib/port-trigger/port_trigger.sh
start_service() {
port_trigger_handling
}
service_triggers()
{
procd_add_reload_trigger firewall
procd_add_reload_trigger port-trigger
}
reload_service() {
start
}

View File

@@ -0,0 +1,157 @@
#!/bin/sh
. /lib/functions.sh
process_port_trigger() {
local rule_id="$1"
local is_enabled=""
local duration=""
local trigger_dport=""
local trigger_dport_end=""
local protocol=""
local interface=""
local open_dport=""
local open_dport_end=""
local open_protocol=""
local ptg_id=""
local IP_RULE=""
local IP6_RULE=""
local IP_RULE_FWD=""
get_port_trigger() {
local ptg_name
config_get ptg_name "$1" "name"
if [ "$ptg_name" == "$2" ]; then
ptg_id="$1"
return
fi
}
ptg_id=""
config_get name "$rule_id" "port_trigger"
config_foreach get_port_trigger "port_trigger" "$name"
[ -z "$ptg_id" ] && return
is_enabled=$(uci -q get port-trigger."$ptg_id".enable)
if [ -z "$is_enabled" ] || [ "$is_enabled" = "0" ]; then
return
fi
protocol=$(uci -q get port-trigger."$ptg_id".protocol)
[ -z "$protocol" ] && return
if [ "$protocol" = "UDP" ] || [ "$protocol" = "udp" ]; then
IP_RULE="$IP_RULE -p udp"
IP6_RULE="$IP6_RULE -p udp"
IP_RULE_FWD="$IP_RULE_FWD -p udp"
elif [ "$protocol" = "TCP" ] || [ "$protocol" = "tcp" ]; then
IP_RULE="$IP_RULE -p tcp"
IP6_RULE="$IP6_RULE -p tcp"
IP_RULE_FWD="$IP_RULE_FWD -p tcp"
else
return
fi
trigger_dport=$(uci -q get port-trigger."$ptg_id".port)
[ -z "$trigger_dport" ] && return
IP_RULE="$IP_RULE --dport $trigger_dport"
IP6_RULE="$IP6_RULE --dport $trigger_dport"
trigger_dport_end=$(uci -q get port-trigger."$ptg_id".end_port_range)
if [ -n "$trigger_dport_end" ]; then
IP_RULE="$IP_RULE:$trigger_dport"
IP6_RULE="$IP6_RULE:$trigger_dport"
fi
config_get open_protocol "$rule_id" "protocol"
if [ "$open_protocol" = "UDP" ] || [ "$open_protocol" = "udp" ]; then
IP_RULE="$IP_RULE -j TRIGGER --trigger-type out --trigger-proto udp"
IP6_RULE="$IP6_RULE -j TRIGGER --trigger-type out --trigger-proto udp"
elif [ "$open_protocol" = "TCP" ] || [ "$open_protocol" = "tcp" ]; then
IP_RULE="$IP_RULE -j TRIGGER --trigger-type out --trigger-proto tcp"
IP6_RULE="$IP6_RULE -j TRIGGER --trigger-type out --trigger-proto tcp"
else
return
fi
config_get open_dport "$rule_id" "port"
[ -z "$open_dport" ] && return
IP_RULE="$IP_RULE --trigger-match $open_dport"
IP6_RULE="$IP6_RULE --trigger-match $open_dport"
IP_RULE_FWD="$IP_RULE_FWD --dport $open_dport"
config_get open_dport_end "$rule_id" "end_port_range"
if [ -z "$open_dport_end" ]; then
IP_RULE="$IP_RULE --trigger-relate $open_dport"
IP6_RULE="$IP6_RULE --trigger-relate $open_dport"
else
IP_RULE="$IP_RULE-$open_dport_end --trigger-relate $open_dport-$open_dport_end"
IP6_RULE="$IP6_RULE-$open_dport_end --trigger-relate $open_dport-$open_dport_end"
IP_RULE_FWD="$IP_RULE_FWD:$open_dport_end"
fi
duration=$(uci -q get port-trigger."$ptg_id".auto_disable_duration)
if [ -n "$duration" ]; then
IP_RULE="$IP_RULE --trigger-timeout $duration"
IP6_RULE="$IP6_RULE --trigger-timeout $duration"
fi
interface=$(uci -q get port-trigger."$ptg_id".src)
[ -z "$interface" ] && return
device=$(uci -q get network.$interface.device)
IP_RULE_1="iptables -w -t nat -A prerouting_porttrigger -i $device $IP_RULE"
echo "$IP_RULE_1">>/tmp/port_trigger_iptables
IP_RULE_1="ip6tables -w -t nat -A prerouting_porttrigger -i $device $IP6_RULE"
echo "$IP_RULE_1">>/tmp/port_trigger_ip6tables
if [ -n "$duration" ]; then
echo "iptables -w -t filter -A forwarding_wan_porttrigger $IP_RULE_FWD -j TRIGGER --trigger-type in --trigger-timeout $duration">>/tmp/port_trigger_iptables
echo "ip6tables -w -t filter -A forwarding_wan_porttrigger $IP_RULE_FWD -j TRIGGER --trigger-type in --trigger-timeout $duration">>/tmp/port_trigger_ip6tables
echo "iptables -w -t nat -A prerouting_wan_porttrigger $IP_RULE_FWD -j TRIGGER --trigger-type dnat --trigger-timeout $duration">>/tmp/port_trigger_iptables
else
echo "iptables -w -t filter -A forwarding_wan_porttrigger $IP_RULE_FWD -j TRIGGER --trigger-type in">>/tmp/port_trigger_iptables
echo "ip6tables -w -t filter -A forwarding_wan_porttrigger $IP_RULE_FWD -j TRIGGER --trigger-type in">>/tmp/port_trigger_ip6tables
echo "iptables -w -t nat -A prerouting_wan_porttrigger $IP_RULE_FWD -j TRIGGER --trigger-type dnat">>/tmp/port_trigger_iptables
fi
}
port_trigger_handling() {
rm /tmp/port_trigger_iptables 2> /dev/null
rm /tmp/port_trigger_ip6tables 2> /dev/null
touch /tmp/port_trigger_iptables
touch /tmp/port_trigger_ip6tables
echo "iptables -w -t nat -F prerouting_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
echo "iptables -w -t filter -F forwarding_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
echo "iptables -w -t nat -F prerouting_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
echo "ip6tables -w -t nat -F prerouting_porttrigger 2> /dev/null">>/tmp/port_trigger_ip6tables
echo "ip6tables -w -t filter -F forwarding_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_ip6tables
echo "iptables -w -t nat -N prerouting_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
ret=$?
[ $ret -eq 0 ] && echo "iptables -w -t nat -I PREROUTING -j prerouting_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
echo "iptables -w -t filter -N forwarding_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
ret=$?
[ $ret -eq 0 ] && echo "iptables -w -t filter -I forwarding_wan_rule -j forwarding_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
echo "iptables -w -t nat -N prerouting_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
ret=$?
[ $ret -eq 0 ] && echo "iptables -w -t nat -I prerouting_wan_rule -j prerouting_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_iptables
echo "ip6tables -w -t nat -N prerouting_porttrigger 2> /dev/null">>/tmp/port_trigger_ip6tables
ret=$?
[ $ret -eq 0 ] && echo "ip6tables -w -t nat -I PREROUTING -j prerouting_porttrigger 2> /dev/null">>/tmp/port_trigger_ip6tables
echo "ip6tables -w -t filter -N forwarding_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_ip6tables
ret=$?
[ $ret -eq 0 ] && echo "ip6tables -w -t filter -I forwarding_wan_rule -j forwarding_wan_porttrigger 2> /dev/null">>/tmp/port_trigger_ip6tables
# Load /etc/config/port-trigger UCI file
config_load port-trigger
config_foreach process_port_trigger rule
sh /tmp/port_trigger_iptables
sh /tmp/port_trigger_ip6tables
}

175
fluent-bit/Makefile Normal file
View File

@@ -0,0 +1,175 @@
#
# Copyright (C) 2024 IOPSYS
#
include $(TOPDIR)/rules.mk
PKG_NAME:=fluent-bit
PKG_VERSION:=3.1.0
PKG_RELEASE:=$(AUTORELEASE)
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE:=$(PKG_NAME)-v$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/fluent/fluent-bit/archive/v$(PKG_VERSION)
PKG_HASH:=7a49e110cf3050b6c29c911063494b8081f3c743274d1d95e52562d0476ba1eb
endif
PKG_LICENSE:=Apache-2.0
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
define Package/fluent-bit
CATEGORY:=Utilities
DEPENDS:= +libyaml +libopenssl +libcurl +libatomic +musl-fts +flex +bison
TITLE:=Fluent-Bit
URL:=https://fluentbit.io/
endef
define Package/fluent-bit/description
Fluent Bit is a super fast, lightweight, and highly scalable logging and metrics processor and forwarder.
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ./fluent-bit/* $(PKG_BUILD_DIR)/
endef
endif
# General options
TARGET_LDFLAGS +=-lfts -latomic
CMAKE_OPTIONS+= \
-DFLB_RELEASE=Yes \
-DFLB_SMALL=No \
-DEXCLUDE_FROM_ALL=true \
-DFLB_SHARED_LIBS=Yes \
-DFLB_DEBUG=Yes \
-DFLB_ALL=No \
-DFLB_JEMALLOC=No \
-DFLB_EXAMPLES=No \
-DFLB_CHUNK_TRACE=No \
-DFLB_BACKTRACE=No \
-DFLB_WASM=No \
-DFLB_LUAJIT=No
# In plugins
CMAKE_OPTIONS += \
-DFLB_IN_SYSLOG=Yes \
-DFLB_IN_CPU=Yes \
-DFLB_IN_MEM=Yes \
-DFLB_IN_DISK=Yes \
-DFLB_IN_EXEC=Yes \
-DFLB_IN_HEAD=Yes \
-DFLB_IN_FORWARD=No \
-DFLB_IN_KMSG=No \
-DFLB_IN_PROC=No \
-DFLB_IN_RANDOM=No \
-DFLB_IN_SERIAL=No \
-DFLB_IN_MQTT=No \
-DFLB_IN_STDIN=No \
-DFLB_IN_SYSTEMD=No \
-DFLB_IN_TAIL=No \
-DFLB_IN_TCP=No \
-DFLB_IN_THERMAL=No \
-DFLB_IN_UDP=No \
-DFLB_IN_DOCKER=No \
-DFLB_IN_EXEC_WASI=No \
-DFLB_IN_EVENT_TYPE=No \
-DFLB_IN_FLUENTBIT_METRICS=No \
-DFLB_IN_KUBERNETES_EVENTS=No \
-DFLB_IN_KAFKA=No \
-DFLB_IN_LIB=No \
-DFLB_IN_SYSTEMD=No \
-DFLB_IN_DUMMY=No \
-DFLB_IN_NETIF=No \
-DFLB_IN_COLLECTD=No \
-DFLB_IN_PROMETHEUS_SCRAPE=No \
-DFLB_IN_STATSD=No \
-DFLB_IN_STORAGE_BACKLOG=No \
-DFLB_IN_PODMAN_METRICS=No \
-DFLB_IN_OPENTELEMETRY=No \
-DFLB_IN_ELASTICSEARCH=No \
-DFLB_IN_CALYPTIA_FLEET=No \
-DFLB_IN_SPLUNK=No
-DFLB_IN_HEALTH=No \
-DFLB_IN_WINLOG=No \
-DFLB_IN_WINEVTLOG=No
# Filter options
CMAKE_OPTIONS +=
-DFLB_FILTER_AWS=No \
-DFLB_FILTER_ECS=No \
-DFLB_FILTER_KUBERNETES=No \
-DFLB_FILTER_LUA=No \
-DFLB_FILTER_NEST=No \
-DFLB_FILTER_RECORD_MODIFIER=No \
-DFLB_FILTER_THROTTLE=No \
-DFLB_FILTER_TYPE_CONVERTER=No \
-DFLB_FILTER_WASM=No \
-DFLB_FILTER_TENSORFLOW=No \
-DFLB_FILTER_GEOIP2=No \
-DFLB_FILTER_NIGHTFALL=No
# out plugins
CMAKE_OPTIONS += \
-DFLB_OUT_EXIT=Yes \
-DFLB_OUT_FORWARD=Yes \
-DFLB_OUT_HTTP=Yes \
-DFLB_OUT_NATS=Yes \
-DFLB_OUT_TCP=Yes \
-DFLB_OUT_UDP=Yes \
-DFLB_OUT_FILE=Yes \
-DFLB_OUT_STDOUT=Yes \
-DFLB_OUT_SYSLOG=Yes \
-DFLB_OUT_NULL=Yes \
-DFLB_OUT_PLOT=No \
-DFLB_OUT_AZURE=No \
-DFLB_OUT_AZURE_BLOB=No \
-DFLB_OUT_AZURE_LOGS_INGESTION=No \
-DFLB_OUT_AZURE_KUSTO=No \
-DFLB_OUT_BIGQUERY=No \
-DFLB_OUT_CALYPTIA=No \
-DFLB_OUT_COUNTER=No \
-DFLB_OUT_DATADOG=No \
-DFLB_OUT_ES=No \
-DFLB_OUT_GELF=No \
-DFLB_OUT_INFLUXDB=No \
-DFLB_OUT_NRLOGS=No \
-DFLB_OUT_OPENSEARCH=No \
-DFLB_OUT_TD=No \
-DFLB_OUT_SKYWALKING=No \
-DFLB_OUT_SLACK=No \
-DFLB_OUT_SPLUNK=No \
-DFLB_OUT_STACKDRIVER=No \
-DFLB_OUT_LIB=No \
-DFLB_OUT_FLOWCOUNTER=No \
-DFLB_OUT_LOGDNA=No \
-DFLB_OUT_LOKI=No \
-DFLB_OUT_KAFKA=No \
-DFLB_OUT_KAFKA_REST=No \
-DFLB_OUT_CLOUDWATCH_LOGS=No \
-DFLB_OUT_KINESIS_FIREHOSE=No \
-DFLB_OUT_KINESIS_STREAMS=No \
-DFLB_OUT_OPENTELEMETRY=No \
-DFLB_OUT_PROMETHEUS_EXPORTER=No \
-DFLB_OUT_PROMETHEUS_REMOTE_WRITE=No \
-DFLB_OUT_S3=No \
-DFLB_OUT_VIVO_EXPORTER=No \
-DFLB_OUT_WEBSOCKET=No \
-DFLB_OUT_ORACLE_LOG_ANALYTICS=No \
-DFLB_OUT_CHRONICLE=No \
-DFLB_OUT_PGSQL=No
define Package/fluent-bit/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_DIR) $(1)/etc/fluent-bit
$(INSTALL_BIN) $(PKG_BUILD_DIR)/bin/fluent-bit $(1)/usr/sbin/
$(INSTALL_DATA) ./files/fluent-bit.conf $(1)/etc/fluent-bit/fluent-bit.conf
$(INSTALL_DATA) $(PKG_BUILD_DIR)/conf/parsers.conf $(1)/etc/fluent-bit/parsers.conf
endef
$(eval $(call BuildPackage,fluent-bit))

View File

@@ -0,0 +1,15 @@
[SERVICE]
flush 3
daemon Off
log_level info
parsers_file /etc/fluent-bit/parsers.conf
[INPUT]
name syslog
tag syslog
path /dev/log
[OUTPUT]
name null
match *

View File

@@ -0,0 +1,14 @@
diff --git a/plugins/out_file/file.c b/plugins/out_file/file.c
index 2e47c9666..42ace24c6 100644
--- a/plugins/out_file/file.c
+++ b/plugins/out_file/file.c
@@ -45,6 +45,9 @@
#define NEWLINE "\n"
#endif
+#undef PATH_MAX
+#define PATH_MAX 256
+
struct flb_file_conf {
const char *out_path;
const char *out_file;

View File

@@ -0,0 +1,45 @@
diff --git a/plugins/out_file/file.c b/plugins/out_file/file.c
index 2e47c9666..95d28e438 100644
--- a/plugins/out_file/file.c
+++ b/plugins/out_file/file.c
@@ -27,6 +27,7 @@
#include <msgpack.h>
#include <stdio.h>
+#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
@@ -55,6 +56,7 @@ struct flb_file_conf {
int csv_column_names;
int mkdir;
struct flb_output_instance *ins;
+ char hostname[256];
};
static char *check_delimiter(const char *str)
@@ -141,6 +143,9 @@ static int cb_file_init(struct flb_output_instance *ins,
}
}
+ if (gethostname(ctx->hostname, sizeof(ctx->hostname)) != 0)
+ snprintf(ctx->hostname, sizeof(ctx->hostname), "%s", "localhost");
+
tmp = flb_output_get_property("delimiter", ins);
ret_str = check_delimiter(tmp);
if (ret_str != NULL) {
@@ -233,12 +238,8 @@ static int template_output_write(struct flb_file_conf *ctx,
int i;
msgpack_object_kv *kv;
- /*
- * Right now we treat "{time}" specially and fill the placeholder
- * with the metadata timestamp (formatted as float).
- */
- if (!strncmp(key, "time", size)) {
- fprintf(fp, "%f", flb_time_to_double(tm));
+ if (!strncmp(key, "hostname", size)) {
+ fprintf(fp, "%s", ctx->hostname);
return 0;
}

View File

@@ -28,7 +28,7 @@ define KernelPackage/$(PKG_NAME)
FILES:=$(PKG_BUILD_DIR)/$(PKG_NAME).$(LINUX_KMOD_SUFFIX)
KCONFIG:=CONFIG_PACKAGE_kmod-gryphon-led-kernel-module=y
AUTOLOAD:=$(call AutoLoad,60,$(PKG_NAME))
DEPENDS:= +(TARGET_brcmbca):bcmkernel
DEPENDS:= +(TARGET_brcmbca):bcm963xx-bsp
PKG_LICENSE:=GPLv2
PKG_LICENSE_URL:=
endef

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=hostmngr
PKG_VERSION:=1.2.3
PKG_VERSION:=1.2.9
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=b4990b384461f2d1ff75a122a7fa5d9276f211bb
PKG_SOURCE_VERSION:=27b2d7c3ef0ccb4e2c30f790f2b51881b6884d9c
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
@@ -22,7 +22,7 @@ PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/hostmngr
SECTION:=utils
@@ -31,9 +31,8 @@ define Package/hostmngr
DEPENDS= +libubox +libuci +libubus +ubus +libeasy +libnl-genl \
+libjson-c +libblobmsg-json +libnfnetlink +libmnl \
+libnetfilter-conntrack \
+HOSTMNGR_PLATFORM_HAS_WIFI:libwifi +libbbfdm-api \
+libwifiutils
+HOSTMNGR_PLATFORM_HAS_WIFI:libwifi +libwifiutils
DEPENDS+= +libbbfdm-api +libbbfdm-ubus +dm-service
endef
define Package/hostmngr/config
@@ -60,11 +59,10 @@ MAKE_PATH:=src
define Package/hostmngr/install
$(CP) ./files/etc $(1)/
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_DIR) $(1)/etc/hostmngr/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/hostmngr $(1)/usr/sbin/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/bbf_plugin/libhostmngr.so $(1)/etc/hostmngr/
$(INSTALL_DIR) $(1)/usr/share/hostmngr
$(INSTALL_DATA) ./files/scripts/hosts_acl.sh $(1)/usr/share/hostmngr/
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/src/bbf_plugin/libhostmngr.so $(1) $(PKG_NAME)
endef
ifeq ($(LOCAL_DEV),1)

View File

@@ -1,18 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "DotSo",
"name": "/etc/hostmngr/libhostmngr.so"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"object": "Hosts",
"root_obj": "bbfdm"
}
}
}

View File

@@ -277,11 +277,15 @@ touch $ACL_FILE
echo "iptables -w -F hosts_forward" >> $ACL_FILE
echo "ip6tables -w -F hosts_forward" >> $ACL_FILE
hosts_forward=$(iptables -t filter --list | grep hosts_forward)
if [ -z "$hosts_forward" ]; then
hosts_ipv4_forward=$(iptables -t filter --list -n | grep hosts_forward)
if [ -z "$hosts_ipv4_forward" ]; then
echo "iptables -w -t filter -N hosts_forward" >> $ACL_FILE
ret=$?
[ $ret -eq 0 ] && echo "iptables -w -t filter -I FORWARD -j hosts_forward" >> $ACL_FILE
fi
hosts_ipv6_forward=$(ip6tables -t filter --list -n | grep hosts_forward)
if [ -z "$hosts_ipv6_forward" ]; then
echo "ip6tables -w -t filter -N hosts_forward" >> $ACL_FILE
ret=$?
[ $ret -eq 0 ] && echo "ip6tables -w -t filter -I FORWARD -j hosts_forward" >> $ACL_FILE

10
icwmp/Config.in Normal file
View File

@@ -0,0 +1,10 @@
menu "Configuration"
config ICWMP_MGMT_FROM_USP
bool "Support configuration of ManagementServer from USP"
default y
config ICWMP_BACKUP_EVENTS
bool "Create backup of session events to persistent storage after each successful session"
default y
endmenu

View File

@@ -8,14 +8,14 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=icwmp
PKG_VERSION:=9.7.4
PKG_VERSION:=9.8.22
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://dev.iopsys.eu/bbf/icwmp.git
PKG_SOURCE_VERSION:=1a5ed79a014ff3e9633b70b310bf3f21dea6f036
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_VERSION:=2eeb0990616df846da55a154d2fed05c828d168f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
@@ -31,9 +31,27 @@ define Package/icwmp
CATEGORY:=Utilities
SUBMENU:=TRx69
TITLE:=TR069 CWMP client
DEPENDS:=+libuci +libubox +libblobmsg-json +libubus +libjson-c +libcurl +mxml +libuuid +libbbfdm-api +libopenssl
DEPENDS:=+libuci +libubox +libblobmsg-json +libubus +libjson-c +libcurl +mxml +libuuid +libopenssl
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
MENU:=1
endef
define Package/icwmp/description
TR069 client implementation with bbfdm backend for TR181 support
endef
define Package/icwmp/config
source "$(SOURCE)/Config.in"
endef
ifeq ($(CONFIG_ICWMP_MGMT_FROM_USP),y)
EXTRA_CFLAGS += -DCWMP_DUAL_SUPPORT=BBFDM_BOTH
endif
ifeq ($(CONFIG_ICWMP_BACKUP_EVENTS),y)
EXTRA_CFLAGS += -DPERSIST_BACKUP_SESSION_EVENTS
endif
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ~/git/icwmp/* $(PKG_BUILD_DIR)/
@@ -48,20 +66,20 @@ define Package/icwmp/install
$(INSTALL_DIR) $(1)/etc/uci-defaults
$(INSTALL_DIR) $(1)/lib/upgrade/keep.d
$(INSTALL_DIR) $(1)/etc/udhcpc.user.d
$(INSTALL_DIR) $(1)/etc/icwmpd/plugins
$(INSTALL_BIN) $(PKG_BUILD_DIR)/icwmpd $(1)/usr/sbin/icwmpd
$(INSTALL_DATA) ./files/etc/config/cwmp $(1)/etc/config/cwmp
$(INSTALL_BIN) ./files/etc/firewall.cwmp $(1)/etc/firewall.cwmp
$(INSTALL_BIN) ./files/etc/init.d/icwmpd $(1)/etc/init.d/icwmpd
$(INSTALL_BIN) ./files/etc/uci-defaults/85-cwmp-set-userid $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/90-cwmpfirewall $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/uci-defaults/95-set-random-inform-time $(1)/etc/uci-defaults/
$(INSTALL_BIN) ./files/etc/icwmpd/vendor_log.sh $(1)/etc/icwmpd/vendor_log.sh
$(INSTALL_BIN) ./files/etc/icwmpd/firewall.cwmp $(1)/etc/icwmpd/firewall.cwmp
$(INSTALL_BIN) ./files/etc/icwmpd/critical_services.json $(1)/etc/icwmpd/critical_services.json
$(INSTALL_DATA) ./files/lib/upgrade/keep.d/icwmp $(1)/lib/upgrade/keep.d/icwmp
$(INSTALL_BIN) ./files/etc/udhcpc.user.d/udhcpc_icwmp_opt125.user $(1)/etc/udhcpc.user.d/udhcpc_icwmp_opt125.user
$(INSTALL_BIN) ./files/etc/udhcpc.user.d/udhcpc_icwmp_opt43.user $(1)/etc/udhcpc.user.d/udhcpc_icwmp_opt43.user
$(call BbfdmInstallPluginInMicroservice,$(1)/etc/icwmpd,$(PKG_BUILD_DIR)/libcwmpdm.so)
$(call BbfdmInstallPluginInMicroservice,$(1)/etc/icwmpd/plugins,./files/etc/bbfdm/json/CWMPManagementServer.json)
$(call BbfdmInstallMicroServiceInputFile,$(1),./files/etc/icwmpd/input.json)
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/libcwmpdm.so $(1) $(PKG_NAME)
$(BBFDM_INSTALL_MS_PLUGIN) ./files/etc/bbfdm/json/CWMPManagementServer.json $(1) $(PKG_NAME)
endef
$(eval $(call BuildPackage,icwmp))

View File

@@ -5,7 +5,7 @@ config acs 'acs'
option periodic_inform_interval '1800'
option periodic_inform_time '0001-01-01T00:00:00Z'
option dhcp_discovery 'enable'
option ssl_capath "/etc/ssl/certs"
#option ssl_capath "/etc/icwmpd/ca.pem"
# compression possible configs: GZIP, Deflate, Disabled
option compression 'Disabled'
#­ possible configs interval :[1:65535]
@@ -41,6 +41,7 @@ config cpe 'cpe'
option active_notif_throttle '0'
option disable_gatewayinfo '0'
option fw_upgrade_keep_settings '1'
option clock_sync_timeout '128'
config lwn 'lwn'
option enable '0'

View File

@@ -0,0 +1,11 @@
{
"services_list": [
"firewall",
"network",
"dhcp",
"stunc",
"xmpp",
"wireless",
"time"
]
}

View File

@@ -6,7 +6,7 @@ log() {
}
get_firewall_zone() {
zone="$(uci show firewall|grep network|grep ${1}|cut -d. -f 2)"
zone="$(uci show firewall|grep network|grep -w ${1}|cut -d. -f 2)"
zone="${zone:-wan}" # defaults to wan zone
echo "$zone"
}

View File

@@ -1,18 +0,0 @@
{
"daemon": {
"config": {
"loglevel": "1"
},
"input": {
"type": "DotSo",
"name": "/etc/icwmpd/libcwmpdm.so",
"plugin_dir": "/etc/icwmpd/plugins/"
},
"output": {
"type": "UBUS",
"parent_dm": "Device.",
"multiple_objects": [ "ManagementServer", "XMPP" , "CWMPManagementServer"],
"root_obj": "bbfdm"
}
}
}

View File

@@ -0,0 +1,29 @@
#!/bin/sh
# This script handles '2 Vendor Log File' of Download RPC
# Vendors can replace this file if they need to collect more logs
VENDOR_LOG_FILE="/tmp/icwmp/2_vendor_log"
ret=""
if [ -n "$(which logread)" ]; then
mkdir -p /tmp/icwmp
logread > "${VENDOR_LOG_FILE}"
arch_file="${VENDOR_LOG_FILE}.tar"
if [ -f "${arch_file}" ]; then
rm -f ${arch_file}
fi
if [ -f "${VENDOR_LOG_FILE}" ]; then
tar -cf "${arch_file}" "${VENDOR_LOG_FILE}" 2> /dev/null
if [ -f "${arch_file}" ]; then
ret="${arch_file}"
fi
rm -rf "${VENDOR_LOG_FILE}"
fi
fi
echo "${ret}"

View File

@@ -17,7 +17,15 @@ log() {
}
regenerate_ssl_link() {
local cert_dir="${1%/}"
local cert_dir
cert_dir="${1%/}"
if [ -f "${cert_dir}" ]; then
return 0
fi
# do not generate the c_rehash if its system default cert path
# ca-certificate package already generates c_rehash on compilation
[ ! -d "${cert_dir}" ] || [ "${cert_dir}" = "/etc/ssl/certs" ] && return 0
generate_links() {
@@ -26,14 +34,15 @@ regenerate_ssl_link() {
for cfile in ${files}; do
if [ -f "${cfile}" ]; then
rehash="$(openssl x509 -hash -noout -in "${cfile}")"
[ -f "${cert_dir}/${rehash}.0" ] || \
if [ ! -f "${cert_dir}/${rehash}.0" ]; then
log "Generating c_rehash for ${cfile}=>${rehash}.0"
ln -s "${cfile}" "${cert_dir}/${rehash}.0"
fi
fi
done
}
generate_links "pem"
generate_links "crt"
}
enable_dhcp_option43() {

View File

@@ -3,7 +3,7 @@
uci -q batch <<-EOT
delete firewall.cwmp
set firewall.cwmp=include
set firewall.cwmp.path=/etc/firewall.cwmp
set firewall.cwmp.path=/etc/icwmpd/firewall.cwmp
set firewall.cwmp.reload=1
commit firewall
EOT

View File

@@ -21,6 +21,9 @@ config IEEE1905_WIFI_EASYMESH
config IEEE1905_CMDU_FRAGMENT_TLV_BOUNDARY
bool "Fragment large CMDU frame at TLV boundary instead of octet boundary"
config IEEE1905_BUILD_TR181_PLUGIN
bool "Build TR-181 mapping module (responsible for Device.IEEE1905.)"
endmenu
endif

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ieee1905
PKG_VERSION:=8.3.12
PKG_VERSION:=8.6.1
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=4f94b73ac3e9472bbcd84c6c8f91118aa6ca9f6b
PKG_SOURCE_VERSION:=5f7e6e30cbda36e431ecb7150d7494bce0c26f6f
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
@@ -22,6 +22,7 @@ PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
include $(TOPDIR)/feeds/iopsys/bbfdm/bbfdm.mk
define Package/ieee1905/Default
@@ -38,7 +39,7 @@ define Package/libieee1905
$(call Package/ieee1905/Default)
TITLE:=libieee1905.so (library for CMDU and TLV handling)
DEPENDS= +libubox +libuci +libubus +libeasy +libnl-genl \
+libjson-c +libblobmsg-json
+libjson-c +libblobmsg-json +libwifiutils
endef
define Package/ieee1905
@@ -46,7 +47,9 @@ define Package/ieee1905
TITLE:=ieee1905d (daemon implementing 1905.1 and provides cli)
DEPENDS= +libubox +libuci +libubus +libeasy +libnl-genl \
+libjson-c +libblobmsg-json +ubus +libpthread \
+libieee1905 +IEEE1905_PLATFORM_HAS_WIFI:libwifi
+libieee1905 +IEEE1905_PLATFORM_HAS_WIFI:libwifi \
+libwifiutils
DEPENDS+=+libbbfdm-api +libbbfdm-ubus +dm-service
endef
include $(wildcard plugins/*.mk)
@@ -94,6 +97,7 @@ TARGET_CFLAGS += -DEXTENSION_ALLOWED
endif
TARGET_CFLAGS += -DHAS_UBUS
TARGET_CFLAGS += -DBUILD_TR181_PLUGIN
MAKE_FLAGS += \
extmod_subdirs="$(patsubst %,extensions/%,$(plugins))"
@@ -107,6 +111,7 @@ define Package/ieee1905/install
$(INSTALL_DIR) $(1)/usr/lib/ieee1905
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/ieee1905d $(1)/usr/sbin/
$(BBFDM_INSTALL_MS_DM) $(PKG_BUILD_DIR)/tr181/ieee1905dm.so $(1) $(PKG_NAME)
endef
define Package/libieee1905/install

View File

@@ -12,7 +12,7 @@ define Package/ieee1905-map-plugin/config
config MULTIAP_EASYMESH_VERSION
int "Easymesh version"
default 4
default 6
config MULTIAP_DYNAMIC_CNTLR_SYNC_CONFIG
bool "Sync configuration between dynamic controllers in the network"

View File

@@ -1,335 +0,0 @@
############
# Generic #
##########
# Build #
CONFIG_BUILD_LOG=y
CONFIG_CCACHE=y
CONFIG_DEBUG=y
CONFIG_DEVEL=y
# CONFIG_USE_SSTRIP is not set
CONFIG_USE_STRIP=y
# CONFIG_SIGNED_PACKAGES is not set
CONFIG_JSON_CYCLONEDX_SBOM=y
CONFIG_INCLUDE_CONFIG=y
# Image #
CONFIG_TARGET_CUSTOMER="IOPSYS"
CONFIG_TARGET_ROOTFS_TARGZ=y
# Although UBIFS and EXT4 images work on all non-secure-boot devices,
# squashfs is the only officially supported rootfs filesystem.
# A writable rootfs is useful for developping an debugging preinit code.
# CONFIG_TARGET_ROOTFS_UBIFS is not set
# CONFIG_TARGET_ROOTFS_EXT4FS is not set
# /etc/banner and /etc/device_info #
CONFIG_IMAGEOPT=y
CONFIG_VERSIONOPT=y
CONFIG_VERSION_MANUFACTURER="IOPSYS"
CONFIG_VERSION_MANUFACTURER_URL="https://iopsys.eu/"
CONFIG_VERSION_DIST="IOWRT"
# OpenWrt is given by CONFIG_VERSION_NUMBER which we do not want to override.
# disabling CONFIG_VERSION_FILENAMES will hide the OpenWrt version from the image filename
# CONFIG_VERSION_FILENAMES is not set
# CONFIG_VERSION_CODE is set to the IOWRT version instead by the genconfig-script and
# CONFIG_VERSION_CODE_FILENAMES will put it into the image filename.
CONFIG_VERSION_CODE_FILENAMES=y
CONFIG_VERSION_HOME_URL="https://iopsys.eu"
CONFIG_VERSION_BUG_URL="https://iopsys.eu"
CONFIG_VERSION_SUPPORT_URL="https://iopsys.eu"
# /lib/preinit #
CONFIG_PREINITOPT=y
# CONFIG_TARGET_PREINIT_SUPPRESS_STDERR is not set
CONFIG_TARGET_PREINIT_DISABLE_FAILSAFE=y
CONFIG_TARGET_PREINIT_TIMEOUT=1
# CONFIG_TARGET_PREINIT_SHOW_NETMSG is not set
# CONFIG_TARGET_PREINIT_SUPPRESS_FAILSAFE_NETMSG is not set
CONFIG_TARGET_PREINIT_IFNAME=""
CONFIG_TARGET_PREINIT_IP=""
CONFIG_TARGET_PREINIT_NETMASK=""
CONFIG_TARGET_PREINIT_BROADCAST=""
# Mirror #
CONFIG_LOCALMIRROR="https://download.iopsys.eu/iopsys/mirror/"
##################
# IOWRT Add-ons #
################
# EasySoC HAL #
CONFIG_PACKAGE_qosmngr=y
CONFIG_PACKAGE_libwifiutils=y
CONFIG_PACKAGE_wifimngr=y
# Multi-AP #
CONFIG_PACKAGE_ieee1905=y
CONFIG_IEEE1905_CMDU_SA_IS_ALMAC=y
CONFIG_PACKAGE_ieee1905-topology-plugin=y
CONFIG_PACKAGE_decollector=y
CONFIG_PACKAGE_map-agent=y
CONFIG_PACKAGE_map-controller=y
# Network #
CONFIG_PACKAGE_hostmngr=y
CONFIG_PACKAGE_netmode=y
CONFIG_PACKAGE_urlfilter=y
# System #
CONFIG_PACKAGE_imonitor=m
CONFIG_PACKAGE_questd=y
CONFIG_PACKAGE_rulengd=y
CONFIG_PACKAGE_usermngr=y
# TR-x69 #
CONFIG_PACKAGE_libbbfdm=y
CONFIG_PACKAGE_bbfdmd=y
CONFIG_PACKAGE_icwmp=y
CONFIG_PACKAGE_obuspa=y
CONFIG_PACKAGE_bulkdata=y
CONFIG_PACKAGE_periodicstats=y
CONFIG_PACKAGE_stunc=y
CONFIG_PACKAGE_swmodd=y
CONFIG_PACKAGE_twamp=y
CONFIG_PACKAGE_udpecho-client=y
CONFIG_PACKAGE_udpecho-server=y
CONFIG_PACKAGE_userinterface=y
CONFIG_PACKAGE_xmppc=y
CONFIG_PACKAGE_timemngr=y
CONFIG_PACKAGE_self-diagnostics=y
# WebGUI #
CONFIG_PACKAGE_sulu=y
############
# Network #
##########
# Protocols #
CONFIG_PACKAGE_6in4=y
CONFIG_PACKAGE_6rd=y
CONFIG_PACKAGE_6to4=y
CONFIG_PACKAGE_chat=y
CONFIG_PACKAGE_comgt=y
CONFIG_PACKAGE_comgt-directip=y
CONFIG_PACKAGE_comgt-ncm=y
CONFIG_PACKAGE_ds-lite=y
CONFIG_PACKAGE_firewall=y
# CONFIG_PACKAGE_firewall4 is not set
CONFIG_PACKAGE_gre=y
CONFIG_PACKAGE_map=y
CONFIG_PACKAGE_ntfs-3g=y
CONFIG_PACKAGE_ntpd=y
CONFIG_PACKAGE_odhcp6c=y
CONFIG_PACKAGE_odhcpd=y
CONFIG_PACKAGE_ppp-mod-pppoa=y
CONFIG_PACKAGE_ppp-mod-pppoe=y
CONFIG_PACKAGE_ppp-mod-pppol2tp=y
CONFIG_PACKAGE_ppp-mod-pptp=y
CONFIG_PACKAGE_ppp-multilink=y
# CONFIG_PACKAGE_ppp is not set
CONFIG_PACKAGE_relayd=y
CONFIG_PACKAGE_umbim=y
CONFIG_PACKAGE_uqmi=y
CONFIG_PACKAGE_wwan=y
CONFIG_PACKAGE_xl2tpd=y
# Services #
CONFIG_PACKAGE_atftpd=y
CONFIG_PACKAGE_ddns-scripts=y
CONFIG_PACKAGE_dnsmasq=y
CONFIG_PACKAGE_ssdpd=y
CONFIG_PACKAGE_miniupnpd-iptables=y
CONFIG_PACKAGE_mosquitto-client-ssl=y
CONFIG_PACKAGE_mosquitto-ssl=y
CONFIG_PACKAGE_nginx=y
CONFIG_PACKAGE_openvpn-easy-rsa=y
CONFIG_PACKAGE_openvpn-openssl=y
CONFIG_OPENVPN_openssl_ENABLE_IPROUTE2=y
# CONFIG_PACKAGE_qos-scripts is not set
CONFIG_PACKAGE_rdnssd=y
CONFIG_PACKAGE_vsftpd-tls=y
# Tools and Utilities #
CONFIG_PACKAGE_curl=y
CONFIG_PACKAGE_libcurl=y
CONFIG_LIBCURL_CRYPTO_AUTH=y
# CONFIG_LIBCURL_MBEDTLS is not set
CONFIG_LIBCURL_OPENSSL=y
CONFIG_PACKAGE_ethtool=y
CONFIG_PACKAGE_ip-bridge=y
CONFIG_PACKAGE_ip-full=y
CONFIG_PACKAGE_iperf3=y
CONFIG_PACKAGE_ipset=y
CONFIG_PACKAGE_ip6tables-zz-legacy=y
CONFIG_PACKAGE_iptables-zz-legacy=y
CONFIG_PACKAGE_iptables-mod-conntrack-extra=y
CONFIG_PACKAGE_iptables-mod-extra=y
CONFIG_PACKAGE_iptables-mod-filter=y
CONFIG_PACKAGE_iptables-mod-ipmark=y
CONFIG_PACKAGE_iptables-mod-ipopt=y
CONFIG_PACKAGE_iptables-mod-nflog=y
CONFIG_PACKAGE_iptables-mod-nfqueue=y
CONFIG_PACKAGE_iputils-arping=y
CONFIG_PACKAGE_iputils-ping=y
CONFIG_PACKAGE_ndisc6=y
CONFIG_PACKAGE_rdisc6=y
CONFIG_PACKAGE_resolveip=y
CONFIG_PACKAGE_socat=y
CONFIG_PACKAGE_tcpdump=y
CONFIG_PACKAGE_traceroute6=y
############
# System #
##########
CONFIG_PACKAGE_at=y
CONFIG_PACKAGE_ca-certificates=y
CONFIG_PACKAGE_crun=y
CONFIG_PACKAGE_getopt=y
CONFIG_PACKAGE_gpiod-tools=y
# CONFIG_PACKAGE_iwatchdog is not set
CONFIG_PACKAGE_jq=y
CONFIG_PACKAGE_libcap-bin=y
CONFIG_PACKAGE_libustream-openssl=y
# CONFIG_PACKAGE_libustream-wolfssl is not set
CONFIG_PACKAGE_lscpu=y
CONFIG_PACKAGE_nand-utils=y
CONFIG_PACKAGE_openssl-util=y
CONFIG_OPENSSL_WITH_COMPRESSION=y
CONFIG_PACKAGE_procd-ujail=m
CONFIG_PACKAGE_quota=y
CONFIG_PACKAGE_rpcd=y
CONFIG_PACKAGE_rpcd-mod-rpcsys=y
CONFIG_PACKAGE_rpcd-mod-rrdns=y
CONFIG_PACKAGE_strace=y
CONFIG_PACKAGE_terminfo=y
CONFIG_PACKAGE_uledd=y
# The urandom-seed package is very strange. It seeds urandom with urandom...
# Disable it. Most SoCs nowadays has HW random generators anyway.
# CONFIG_PACKAGE_urandom-seed is not set
# CONFIG_PACKAGE_urngd is not set
CONFIG_PACKAGE_usb-modeswitch=y
CONFIG_PACKAGE_uuidgen=y
CONFIG_PACKAGE_zoneinfo-core=y
CONFIG_PACKAGE_zoneinfo-europe=y
################
# LuCI WebGUI #
##############
# BEGIN: luci-nginx metapackage with some changes
# We do not want libiwinfo-lua on non-WiFi targets, but it is already
# depended on by other luci-packages, so no need to take it in explicitly
CONFIG_PACKAGE_luci-mod-admin-full=y
CONFIG_PACKAGE_luci-app-firewall=y
CONFIG_PACKAGE_luci-app-opkg=y
CONFIG_PACKAGE_luci-proto-ppp=y
CONFIG_PACKAGE_luci-proto-ipv6=y
# CONFIG_LUCI_JSMIN is not set
# CONFIG_LUCI_CSSTIDY is not set
CONFIG_PACKAGE_luci-mod-dashboard=y
CONFIG_PACKAGE_luci-theme-openwrt-2020=y
CONFIG_PACKAGE_nginx-mod-luci=y
############
# BusyBox #
##########
CONFIG_BUSYBOX_CUSTOM=y
CONFIG_BUSYBOX_CONFIG_ADDUSER=y
CONFIG_BUSYBOX_CONFIG_ASH_IDLE_TIMEOUT=y
CONFIG_BUSYBOX_CONFIG_ASH_RANDOM_SUPPORT=y
CONFIG_BUSYBOX_CONFIG_CTTYHACK=y
CONFIG_BUSYBOX_CONFIG_DELUSER=y
CONFIG_BUSYBOX_CONFIG_FEATURE_UDHCP_8021Q=y
CONFIG_BUSYBOX_CONFIG_FIRST_SYSTEM_ID=100
# CONFIG_BUSYBOX_CONFIG_HTTPD is not set
# CONFIG_BUSYBOX_CONFIG_INSMOD is not set
# CONFIG_BUSYBOX_CONFIG_MODINFO is not set
# CONFIG_BUSYBOX_CONFIG_MODPROBE is not set
CONFIG_BUSYBOX_CONFIG_FEATURE_MODPROBE_BLACKLIST=y
CONFIG_BUSYBOX_CONFIG_FEATURE_CHECK_TAINTED_MODULE=y
CONFIG_BUSYBOX_CONFIG_FEATURE_MODUTILS_ALIAS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_MODUTILS_SYMBOLS=y
CONFIG_BUSYBOX_CONFIG_DEFAULT_MODULES_DIR="/lib/modules"
CONFIG_BUSYBOX_CONFIG_DEFAULT_DEPMOD_FILE="modules.dep"
# CONFIG_BUSYBOX_CONFIG_IP is not set
CONFIG_BUSYBOX_CONFIG_LAST_SYSTEM_ID=999
CONFIG_BUSYBOX_CONFIG_LOGIN=y
# CONFIG_BUSYBOX_CONFIG_LSMOD is not set
CONFIG_BUSYBOX_CONFIG_LSPCI=y
CONFIG_BUSYBOX_CONFIG_LSUSB=y
CONFIG_BUSYBOX_CONFIG_MICROCOM=y
# CONFIG_BUSYBOX_CONFIG_RMMOD is not set
CONFIG_BUSYBOX_CONFIG_STTY=y
CONFIG_BUSYBOX_CONFIG_TFTP=y
CONFIG_BUSYBOX_CONFIG_FEATURE_CHECK_TAINTED_MODULE=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_AUTH_MD5=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_BASIC_AUTH=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_CGI=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_CONFIG_WITH_SCRIPT_INTERPR=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_ENCODE_URL_STR=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_ERROR_PAGES=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_GZIP=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_PROXY=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_RANGES=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_SETUID=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_SET_REMOTE_PORT_TO_ENV=y
CONFIG_BUSYBOX_CONFIG_FEATURE_HTTPD_USE_SENDFILE=y
CONFIG_BUSYBOX_CONFIG_FEATURE_LSMOD_PRETTY_2_6_OUTPUT=y
# CONFIG_BUSYBOX_CONFIG_FEATURE_NOLOGIN is not set
CONFIG_BUSYBOX_CONFIG_FEATURE_SECURETTY=y
# CONFIG_BUSYBOX_CONFIG_FEATURE_TFTP_BLOCKSIZE is not set
CONFIG_BUSYBOX_CONFIG_FEATURE_TFTP_GET=y
CONFIG_BUSYBOX_CONFIG_FEATURE_TFTP_PUT=y
# CONFIG_BUSYBOX_CONFIG_WGET is not set
# CONFIG_BUSYBOX_CONFIG_LOGIN_SCRIPTS is not set
# CONFIG_BUSYBOX_CONFIG_LOGIN_SESSION_AS_CHILD is not set
# CONFIG_BUSYBOX_CONFIG_PAM is not set
# CONFIG_BUSYBOX_CONFIG_TFTP_DEBUG is not set
# CONFIG_BUSYBOX_CONFIG_NTPD is not set
CONFIG_BUSYBOX_CONFIG_MOUNTPOINT=y
CONFIG_BUSYBOX_CONFIG_RUN_PARTS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_RUN_PARTS_LONG_OPTIONS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_RUN_PARTS_FANCY=y
CONFIG_BUSYBOX_CONFIG_FEATURE_GZIP_LEVELS=y
CONFIG_BUSYBOX_CONFIG_GZIP_FAST=2
CONFIG_BUSYBOX_CONFIG_FEATURE_FANCY_SLEEP=y
CONFIG_BUSYBOX_CONFIG_FEATURE_FLOAT_SLEEP=y
CONFIG_BUSYBOX_CONFIG_FLOAT_DURATION=y
CONFIG_BUSYBOX_CONFIG_USLEEP=y
CONFIG_BUSYBOX_CONFIG_REALPATH=y
CONFIG_BUSYBOX_CONFIG_TTY=y
CONFIG_BUSYBOX_CONFIG_BLOCKDEV=y
CONFIG_BUSYBOX_CONFIG_PARTPROBE=y
CONFIG_BUSYBOX_CONFIG_LFS=y
CONFIG_BUSYBOX_CONFIG_FDISK=y
CONFIG_BUSYBOX_CONFIG_FDISK_SUPPORT_LARGE_DISKS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_FDISK_WRITABLE=y
CONFIG_BUSYBOX_CONFIG_FEATURE_GPT_LABEL=y
CONFIG_BUSYBOX_CONFIG_FEATURE_FDISK_ADVANCED=y
CONFIG_BUSYBOX_CONFIG_IONICE=y
CONFIG_BUSYBOX_CONFIG_RENICE=y
CONFIG_BUSYBOX_CONFIG_FEATURE_VOLUMEID_BTRFS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_VOLUMEID_F2FS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_VOLUMEID_LINUXSWAP=y
CONFIG_BUSYBOX_CONFIG_FEATURE_VOLUMEID_SQUASHFS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_VOLUMEID_UBIFS=y
CONFIG_BUSYBOX_CONFIG_TIMEOUT=y
CONFIG_BUSYBOX_CONFIG_NOHUP=y
CONFIG_BUSYBOX_CONFIG_FEATURE_DEFAULT_PASSWD_ALGO="sha512"
# CONFIG_BUSYBOX_CONFIG_ARPING is not set
# CONFIG_BUSYBOX_CONFIG_PING is not set
# CONFIG_BUSYBOX_CONFIG_PING6 is not set
# CONFIG_BUSYBOX_CONFIG_FEATURE_FANCY_PING is not set

View File

@@ -33,10 +33,10 @@ _iop()
prev="${COMP_WORDS[COMP_CWORD-1]}"
iopcmds="bootstrap cfe_upgrade cfe_upgrade_latest extract_core \
feeds_update feeds_update-legacy genconfig genconfig-legacy \
feeds_update genconfig \
generate_tarballs install_key \
scp_changes setup_host ssh_install_key status \
update_package update_feed_branches ssh_upgrade smoketest"
ssh_upgrade smoketest"
if [ $COMP_CWORD -eq 1 ] ; then

View File

@@ -1,72 +0,0 @@
#!/bin/bash
function disable_add_config () {
local COPTION="$1"
HAVE_OPTION=`grep $COPTION .config | wc -l`
HAVE_OPTION_DISABLED=`grep "# $COPTION" .config | wc -l`
if [ "$HAVE_OPTION" = "1" ]
then
if [ "$HAVE_OPTION_DISABLED" = "0" ]
then
sed -i -e "s,$COPTION=y,# $COPTION is not set,g" .config
fi
else
echo "# $COPTION is not set" >> .config
fi
}
function enable_option () {
local COPTION="$1"
# cat .config| grep DSL
sed -i -e "s,# $COPTION is not set,$COPTION=y,g" .config
# cat .config| grep DSL
}
function annexconfig {
v() {
[ "$VERBOSE" -ge 1 ] && echo "$@"
}
local ANNEX="$1"
disable_add_config CONFIG_TARGET_NO_DSL
disable_add_config CONFIG_TARGET_DSL_ANNEX_A
disable_add_config CONFIG_TARGET_DSL_ANNEX_B
disable_add_config CONFIG_TARGET_DSL_ANNEX_C
disable_add_config CONFIG_TARGET_DSL_SADSL
disable_add_config CONFIG_TARGET_DSL_GFAST
if [ "$ANNEX" = "no" ]
then
echo "No DSL"
enable_option CONFIG_TARGET_NO_DSL
elif [ "$ANNEX" = "a" ]
then
echo "Annex A"
enable_option CONFIG_TARGET_DSL_ANNEX_A
elif [ "$ANNEX" = "b" ]
then
echo "Annex B"
enable_option CONFIG_TARGET_DSL_ANNEX_B
elif [ "$ANNEX" = "c" ]
then
echo "Annex C"
enable_option CONFIG_TARGET_DSL_ANNEX_C
elif [ "$ANNEX" = "sadsl" ]
then
echo "sadsl"
enable_option CONFIG_TARGET_DSL_SADSL
elif [ "$ANNEX" = "gfast" ]
then
echo "G.fast"
enable_option CONFIG_TARGET_DSL_GFAST
else
echo "Only option no,a,b,c,sadsl,gfast supported"
fi
}
register_command "annexconfig" "Select configuration annex"

View File

@@ -1,42 +0,0 @@
# this is a developer helper script to install firmware on a remote host running in CFE mode
function usage {
echo "usage: $0 cfe_upgrade <host> <file>"
}
function cfe_upgrade {
if [ -z "$1" ] ; then
usage
echo "Error: host required"
exit 1
fi
if [ -z "$2" ] ; then
usage
echo "Error: firmware filename required"
exit 1
fi
if [ ! -e $2 ] ; then
usage
echo "Error: firmware file does not exist"
exit 1
fi
IMAGE=`basename $2`
echo "CFE upgrade host: $1 with file $IMAGE"
[ "$2" ] && [ -e "$2" ] && curl -i -F filedata=@$2 http://$1/upload.cgi && echo "upgrade done!"
}
register_command "cfe_upgrade" "<host> <file> Install firmware on remote host in CFE mode"
function cfe_upgrade_latest {
if [ -z "$1" ] ; then
echo "usage: $0 cfe_upgrade_latest <host>"
echo "Error: host required"
exit 1
fi
{ cd `dirname $0`
IMAGE=`ls -Art bin/*/*.w | tail -n1`
[ "$IMAGE" ] && [ -e "$IMAGE" ] && ./iop cfe_upgrade $1 $IMAGE
}
}
register_command "cfe_upgrade_latest" "<host> Install latest firmware on remote host in CFE mode"

View File

@@ -1,88 +0,0 @@
#!/bin/bash
function feeds_update-legacy {
heads=1
developer=0
override=1
force=1
function update_failure {
if [ $force == 1 ]; then
echo "WARNING: Failed to update feed(s). Forced update, proceeding anyway." >&2
else
echo "ERROR: Failed to update feed(s). Omit -F to proceed anyway." >&2
exit 1
fi
}
while getopts "inFh" opt; do
case $opt in
i)
heads=0
;;
n)
override=0
;;
F)
force=0
;;
h|\?)
echo "Usage: ./iop feeds_update-legacy [-i] [-n] [-F] [-h]"
echo
echo "OPTIONS:"
echo " -i - Only update index. Do not change HEAD in feeds."
echo " -n - Do not replace core packages with iopsys versions."
echo " -F - Do not force update if there are inaccessible feeds."
echo " -h - Display this help message and exit."
exit 1
;;
esac
done
git remote -v | grep -qE '(git@|ssh://)' && developer=1
cp .config .genconfig_config_bak
if [ $heads == 1 ]; then
if [ $developer == 1 ]; then
./scripts/feeds update -g || update_failure
else
./scripts/feeds update || update_failure
fi
fi
./scripts/feeds update -ai || exit 1
# replace core packages with iopsys versions
if [ $override == 1 ]; then
./scripts/feeds install -f -p openwrt_core -a || exit 1
./scripts/feeds install -f -p qualcomm -a || exit 1
fi
(
echo '# DO NOT EDIT. Autogenerated file by ./iop feeds_update'
echo 'FEED_DEVICES_DIRS:='
find feeds -type f -name .is-feed-devices-dir -printf 'FEED_DEVICES_DIRS+=$(TOPDIR)/%h\n'
) > target/linux/feed-devices/feed-devices-list.mk || exit 1
# targets need to be installed explicitly
for target in $(ls ./feeds/targets); do
./scripts/feeds install -f -p targets $target || exit 1
done
# install all packages
./scripts/feeds install -a || exit 1
# remove broken symlinks ( for packages that are no longer in the feed )
find -L package/feeds -maxdepth 2 -type l -delete || exit 1
cp .genconfig_config_bak .config
make defconfig || exit 1
# record when we last run this script
touch tmp/.iop_bootstrap || exit 1
# always return true
exit 0
}
register_command "feeds_update-legacy" "Update feeds to point to commit hashes from feeds.conf - legacy mode"

View File

@@ -1,535 +0,0 @@
#!/bin/bash
function genconfig-legacy {
export CLEAN=0
export DIRTY="--dirty"
export IMPORT=1
export SRCTREEOVERR=0
export FILEDIR="files/"
CURRENT_CONFIG_FILE=".current_config_file"
export CONFIGPATH="package/feeds/iopsys/iop"
CUSTPATH="customerconfigs"
export CUSTCONF="customerconfigs/customers"
export VERBOSE=0
export DEVELOPER=0
target="bogus"
target_config_path=""
brcmbca_feed="target/linux/feeds/brcmbca"
airoha_feed="target/linux/feeds/airoha"
x86_feed="target/linux/feeds/x86"
armsr_feed="target/linux/feeds/armsr"
mediatek_feed="target/linux/feeds/mediatek"
qualcomm_ipq95xx_feed="target/linux/feeds/ipq95xx"
qualcomm_ipq53xx_feed="target/linux/feeds/ipq53xx"
Red='\033[0;31m' # Red
Color_Off='\033[0m' # Text Reset
Yellow='\033[0;33m' # Yellow
function find_last {
egrep "^[ #]*${1}[ =]" $2 | tail -n1
}
function is_new {
for opt in $conf_warned
do
if [ "$opt" == "$1" ]
then
return 1
fi
done
# option not found return true
return 0
}
function verify_config {
local conf_opt
local conf_org
local conf_new
while read -r line
do
conf_opt=$(echo $line | grep "^[ #]*CONFIG_" | sed 's|.*\(CONFIG_[^ =]*\)[ =].*|\1|')
if [ -n "${conf_opt}" ]
then
conf_org=$(find_last ${conf_opt} .genconfig.config)
conf_new=$(find_last ${conf_opt} .config)
if [ "$conf_org" != "$conf_new" ]
then
if is_new $conf_opt
then
echo -e "config option [${Red}$conf_opt${Color_Off}] is not set correctly in .config"
echo -e "got value [${Yellow}$conf_new${Color_Off}] but wanted [${Yellow}$conf_org${Color_Off}]"
echo "This is a real problem somebody needs to investigate"
echo ""
conf_warned="$conf_warned $conf_opt"
fi
else
true
# for debug to see all options
#echo -e "wanted [$conf_org] got [$conf_new]"
fi
fi
done < .genconfig.config
}
# Takes a board name and returns the target name in global var $target
set_target() {
local profile=$1
[ -n "$profile" ] || return
if [ -n "$TARGET" -a -d "./target/linux/feeds/$TARGET" ]; then
local targetpath="./target/linux/feeds/$TARGET"
local profiles=
local pfound=0
if [ -e "$targetpath/genconfig" ]; then
profiles=$(cd $targetpath; ./genconfig)
for p in $profiles; do
if [ $p == $profile ]; then
pfound=1
break
fi
done
fi
if [ $pfound -eq 1 ]; then
target="$(echo $TARGET | tr '-' '_')"
target_config_path="$targetpath/config"
fi
return
fi
[ -e $brcmbca_feed/genconfig ] &&
brcmbca=$(cd $brcmbca_feed; ./genconfig)
[ -e $airoha_feed/genconfig ] &&
airoha=$(cd $airoha_feed; ./genconfig)
[ -e $x86_feed/genconfig ] &&
x86=$(cd $x86_feed; ./genconfig)
[ -e $armsr_feed/genconfig ] &&
armsr=$(cd $armsr_feed; ./genconfig)
[ -e $mediatek_feed/genconfig ] &&
mediatek=$(cd $mediatek_feed; ./genconfig)
[ -e $qualcomm_ipq95xx_feed/genconfig ] &&
ipq95xx=$(cd $qualcomm_ipq95xx_feed; ./genconfig)
[ -e $qualcomm_ipq53xx_feed/genconfig ] &&
ipq53xx=$(cd $qualcomm_ipq53xx_feed; ./genconfig)
if [ "$profile" == "LIST" ]; then
for list in brcmbca airoha x86 armsr mediatek ipq95xx ipq53xx; do
echo "$list based boards:"
a=$(echo "${!list}" | sort)
for b in $a; do
echo -e "\t$b"
done
done
return
fi
for p in $airoha; do
if [ $p == $profile ]; then
target="airoha"
target_config_path="$airoha_feed/config"
return
fi
done
for p in $x86; do
if [ $p == $profile ]; then
target="x86"
target_config_path="$x86_feed/config"
return
fi
done
for p in $armsr; do
if [ $p == $profile ]; then
target="armsr"
target_config_path="$armsr_feed/config"
return
fi
done
for p in $mediatek; do
if [ $p == $profile ]; then
target="mediatek"
target_config_path="$mediatek_feed/config"
return
fi
done
for p in $ipq95xx; do
if [ $p == $profile ]; then
target="ipq95xx"
target_config_path="$qualcomm_ipq95xx_feed/config"
return
fi
done
for p in $ipq53xx; do
if [ $p == $profile ]; then
target="ipq53xx"
target_config_path="$qualcomm_ipq53xx_feed/config"
return
fi
done
for p in $brcmbca; do
if [ $p == $profile ]; then
target="brcmbca"
target_config_path="$brcmbca_feed/config"
return
fi
done
}
git remote -v | grep -qE '(git@|ssh://)' && {
DEVELOPER=1
}
v() {
[ "$VERBOSE" -ge 1 ] && echo "$@"
}
usage() {
echo
echo 1>&2 "Usage: $0 genconfig-legacy [ OPTIONS ] < Board_Type > [ Customer [customer2 ]...]"
echo
echo -e " -c|--clean\t\tRemove all files under ./files and import from config "
echo -e " -D|--no-dirty\t\tIgnore dirty tree"
echo -e " -v|--verbose\t\tVerbose"
echo -e " -n|--no-update\tDo NOT! Update customer config before applying"
echo -e " -t|--target\t\tExplicitly specify the linux target to build the board profile from"
echo -e " -s|--override\t\tEnable 'Package source tree override'"
echo -e " -S|--brcmsingle\tForce build of bcmkernel to use only one thread"
echo -e " -h|--help\t\tShow this message"
echo -e " -l|--list [customer]\tList all Customers or all boards for one customer"
echo -e " -a|--list-all\t\tList all Customers and their board types"
echo -e " -b|--boards\t\tList all board types"
echo
echo "Example ./iop genconfig-legacy eg400 OPERATORX"
echo "(if no customerconfig is chosen, iopsys config will be used)"
echo
exit 0
}
list_customers()
{
local ALL="$1"
local CUSTOMER="$2"
if [ "$CUSTOMER" -a -d "$CUSTCONF/$CUSTOMER" ]; then
local boards="$(ls -1 "$CUSTCONF/$CUSTOMER" | grep -v common)"
if [ "$boards" ]; then
echo "$CUSTOMER has following boards:"
for board in $boards; do
echo -e "\t$board"
done
else
echo "No boards found for $CUSTOMER"
fi
elif [ "$CUSTOMER" ]; then
echo "No customer called $CUSTOMER"
exit 1
elif [ -d $CUSTCONF ]; then
local customers="$(ls -1 $CUSTCONF)"
if [ "$customers" -a "$ALL" == 1 ]; then
for customer in $customers; do
echo $customer
local boards="$(ls -1 $CUSTCONF/$customer | grep -v common)"
if [ "$boards" ]; then
for board in $boards; do
echo -e "\t$board"
done
else
echo "has no boards"
fi
done
elif [ "$customers" ]; then
echo -e "$customers"
else
echo "no customers found"
fi
else
echo "No $CUSTCONF folder found"
fi
exit 0
}
generate_config()
{
DIFFFILE="$1"
MASTERFILE="$2"
while read p; do
v "$p"
sed -r -i "$p" $MASTERFILE
done < $DIFFFILE
}
setup_dirs()
{
git remote -v | grep -q http || {
CUSTBRANCH="$(git rev-parse --abbrev-ref HEAD)"
if git ls-remote $CUSTREPO -q 2>/dev/null; then
if [ ! -d "$CUSTPATH" ]; then
echo "Cloning $CUSTBRANCH branch of $CUSTREPO"
git clone -b "$CUSTBRANCH" "$CUSTREPO" "$CUSTPATH" 2>/dev/null || {
DEFBRANCH="$(git remote show $CUSTREPO | grep 'HEAD branch' | cut -d' ' -f5)"
echo "$CUSTBRANCH branch is not found, cloning $DEFBRANCH branch of $CUSTREPO"
git clone "$CUSTREPO" "$CUSTPATH"
}
elif [ $IMPORT -eq 1 ]; then
cd $CUSTPATH
echo "Checking out $CUSTBRANCH branch in $CUSTPATH"
git checkout "$CUSTBRANCH" 2>/dev/null || {
DEFBRANCH="$(git symbolic-ref refs/remotes/origin/HEAD | cut -d '/' -f4)"
echo "Checking out $CUSTBRANCH branch has failed, using $DEFBRANCH branch in $CUSTPATH"
}
v "git pull"
git pull
cd - >/dev/null #go back
fi
else
echo "You do not have access to $CUSTREPO"
fi
}
if [ ! -d "$FILEDIR" ]; then
mkdir -p $FILEDIR
elif [ -d "$FILEDIR" -a $CLEAN -eq 1 ]; then
v "rm -rf $FILEDIR*"
rm -rf $FILEDIR*
fi
}
get_subtarget_for_device() {
readonly target="$1"
readonly device="$2"
readonly targetinfo_file="tmp/info/.targetinfo-feeds_$target"
readonly target_profile_line="Target-Profile: DEVICE_$device"
# We want to know after which Target: $target/$subtarget line
# our $target_profile_line appears
# This is a crude way to "parse" the file using shell 🤯
# 1. grep for both lines with line number output
# 2. grep again to determine the device profile line that we looked for
# but output one context line before as well to determine corresponding subtarget line
# 4. Use head and sed to extract the subtarget
grep "^Target: $target/\|^$target_profile_line" "$targetinfo_file" \
| grep -E -B1 "^$target_profile_line" \
| head -n1 \
| sed -E "s|^Target: $target/||"
}
create_and_copy_files()
{
local BOARDTYPE=$1
shift
local CUSTOMERS=$@
# Validate seleced board and customers
set_target $BOARDTYPE
if [ $target == "bogus" ]; then
echo "Hardware profile does not exist"
exit 1
elif [ -n "$CUSTOMERS" ]; then
for CUSTOMER in $CUSTOMERS; do
if [ ! -d "$CUSTCONF/$CUSTOMER/" ]; then
echo "Customer profile for '$CUSTOMER' does not exist"
exit 1
elif [ ! -d "$CUSTCONF/$CUSTOMER/$BOARDTYPE/" ]; then
echo "'$BOARDTYPE' board profile does not exist for customer '$CUSTOMER'"
if [ -f "$CUSTCONF/$CUSTOMER/common/common.diff" ]; then
echo "Common profile configuration will be used"
else
exit 1
fi
fi
done
fi
# Generate base config
rm -f .config
v "Config $BOARDTYPE selected"
v "cp $CONFIGPATH/config .config"
cp $CONFIGPATH/config .config
if [ -f $target_config_path/config ]; then
cat $target_config_path/config >> .config
echo "" >> .config
fi
if [ -f $target_config_path/$BOARDTYPE/config ]; then
cat $target_config_path/$BOARDTYPE/config >> .config
echo "" >> .config
fi
# hack to support custom-devices until we have deprecated this genconfig-script...
local custom_found=false
local used_config_file
for config_file in feeds/*/devices/$target/config/$BOARDTYPE/config; do
if [ "$custom_found" = "true" ]; then
echo
echo "Error was found!"
echo "Please use only one path."
echo "Two instances of $target/config/$BOARDTYPE exists:"
echo "Path 1: $used_config_file"
echo "Path 2: $config_file"
return 1
fi
if [ -f "$config_file" ]; then
cat "$config_file" >> .config
echo "" >> .config
custom_found=true
used_config_file=$config_file
fi
done
# Special handling for targets which use TARGET_DEVICES
case "$target" in
airoha | mediatek | brcmbca | ipq95xx | ipq53xx)
# This assumes the device name to be unique within one target,
# which is a fair assumption to make.
local subtarget="$(get_subtarget_for_device "${target/_/-}" "$BOARDTYPE")"
if [ -z "$subtarget" ]; then
echo "Error determining subtarget for $target / ${BOARDTYPE}"
return 1
fi
echo "CONFIG_TARGET_${target}=y" >> .config
echo "CONFIG_TARGET_${target}_${subtarget}=y" >> .config
echo "CONFIG_TARGET_DEVICE_${target}_${subtarget}_DEVICE_${BOARDTYPE}=y" >> .config
echo "CONFIG_TARGET_MULTI_PROFILE=y" >> .config
echo "CONFIG_TARGET_PER_DEVICE_ROOTFS=y" >> .config
;;
*)
echo "CONFIG_TARGET_${target}=y" >> .config
echo "CONFIG_TARGET_${target}_${BOARDTYPE}=y" >> .config
;;
esac
echo "$CUSTOMERS $BOARDTYPE" > $CURRENT_CONFIG_FILE
# Add customerconfig diff if a customer is selected
if [ -n "$CUSTOMERS" ]; then
for CUSTOMER in $CUSTOMERS; do
if [ -d "$CUSTCONF/$CUSTOMER/common/fs" ]; then
v "cp -ar $CUSTCONF/$CUSTOMER/common/fs/* $FILEDIR"
cp -ar $CUSTCONF/$CUSTOMER/common/fs/* $FILEDIR
fi
if [ -d "$CUSTCONF/$CUSTOMER/$BOARDTYPE/fs" ]; then
v "cp -ar $CUSTCONF/$CUSTOMER/$BOARDTYPE/fs/* $FILEDIR"
cp -ar $CUSTCONF/$CUSTOMER/$BOARDTYPE/fs/* $FILEDIR
fi
if [ -e "$CUSTCONF/$CUSTOMER/common/common.diff" ]; then
v "Apply $CUSTCONF/$CUSTOMER/common/common.diff"
cat $CUSTCONF/$CUSTOMER/common/common.diff >> .config
echo "" >> .config
fi
if [ -e "$CUSTCONF/$CUSTOMER/$BOARDTYPE/$BOARDTYPE.diff" ]; then
v "Apply $CUSTCONF/$CUSTOMER/$BOARDTYPE/$BOARDTYPE.diff"
cat $CUSTCONF/$CUSTOMER/$BOARDTYPE/$BOARDTYPE.diff >> .config
echo "" >> .config
fi
done
fi
# Set target version
local git_version
if ! git_version="$(git describe --always $DIRTY --tags --match '[0-9].*.*' --match '[0-9][0-9].*.*')"; then
echo "ERROR: Failed getting version via git describe, exiting." >&2
return 1
fi
local version="${git_version,,}${CUSTOMERS:+-${CUSTOMERS// /}}"
local version_lower="${version,,}"
echo "CONFIG_TARGET_VERSION=\"${version_lower}\"" >> .config
echo "CONFIG_VERSION_CODE=\"${version_lower}\"" >> .config
echo "CONFIG_VERSION_PRODUCT=\"$BOARDTYPE"\" >> .config
# Enable Package source tree override if selected
[ $SRCTREEOVERR -eq 1 ] && echo CONFIG_SRC_TREE_OVERRIDE=y >> .config
# developer mode selected ?
echo "CONFIG_DEVEL=y" >>.config
if [ $DEVELOPER -eq 1 ]; then
# rewrite url to clone with ssh instead of http
echo "CONFIG_GITMIRROR_REWRITE=y" >>.config
else
echo "# CONFIG_GITMIRROR_REWRITE is not set" >>.config
fi
if [ -n "$BRCM_MAX_JOBS" ]
then
echo "CONFIG_BRCM_MAX_JOBS=\"1\"" >>.config
fi
# Force regeneration of kernel Makefile
# Needed to disable kmods for iopsys-brcm targets
touch package/kernel/linux/Makefile
# we need to signal to bradcom SDK that we have changed the board id
# currently boardparms.c and boardparms_voice.c is the only place that is depending on boardid name
# so just touch that file.
[ -d ./build_dir ] && find build_dir/ -name "boardparms*c" -print0 2>/dev/null | xargs -0 touch 2>/dev/null
# Store generated config
cp .config .genconfig.config
# Set default values based on selected parameters
v "$(make defconfig 2>&1)"
echo Set version to $(grep -w CONFIG_TARGET_VERSION .config | cut -d'=' -f2 | tr -d '"')
# Clean base-file package to force rebuild when changing profile
v "$(make package/base-files/clean 2>&1)"
verify_config
}
####### main #####
if [ ! -e tmp/.iop_bootstrap ]; then
echo "You have not installed feeds. Running genconfig in this state would create a non functional configuration."
echo "Run: iop feeds_update"
exit 1
fi
if [ $# -eq 0 ]; then
echo Current profile:
cat $CURRENT_CONFIG_FILE
echo "Try ./iop genconfig-legacy -h' to get instructions if you want to change current config"
exit 0
else
while [ -n "$1" ]; do
case "$1" in
-c|--clean) export CLEAN=1;;
-D|--no-dirty) export DIRTY="";;
-n|--no-update) export IMPORT=0;;
-v|--verbose) export VERBOSE="$(($VERBOSE + 1))";;
-t|--target) export TARGET="$2"; shift;;
-p|--profile) export PROFILE="$2"; shift;;
-r|--repo) export CUSTREPO="$2"; shift;;
-s|--override) export SRCTREEOVERR=1;;
-S|--brcmsingel) export BRCM_MAX_JOBS=1;;
-h|--help) usage;;
-l|--list) list_customers 0 $2;;
-a|--list-all)list_customers 1;;
-b|--boards)set_target LIST;exit 0;;
-*)
echo "Invalid option: $1 "
echo "Try -h or --help for more information."
exit 1
;;
*) break;;
esac
shift;
done
CUSTREPO="${CUSTREPO:-git@dev.iopsys.eu:consumer/iopsys.git}"
setup_dirs
create_and_copy_files "$@" || exit 1
fi
}
register_command "genconfig-legacy" "Generate configuration for board and customer - legacy mode"

View File

@@ -1,503 +0,0 @@
#!/bin/bash
function genconfig_min-legacy {
export CLEAN=0
export DIRTY="--dirty"
export SRCTREEOVERR=0
export FILEDIR="files/"
CURRENT_CONFIG_FILE=".current_config_file"
export CONFIGPATH="package/feeds/iopsys/iop"
CUSTPATH="customerconfigs"
export CUSTCONF="customerconfigs/customers"
export VERBOSE=0
export DEVELOPER=0
target="bogus"
target_config_path=""
brcmbca_feed="target/linux/feeds/brcmbca"
airoha_feed="target/linux/feeds/airoha"
x86_feed="target/linux/feeds/x86"
armsr_feed="target/linux/feeds/armsr"
mediatek_feed="target/linux/feeds/mediatek"
qualcomm_ipq95xx_feed="target/linux/feeds/ipq95xx"
qualcomm_ipq53xx_feed="target/linux/feeds/ipq53xx"
Red='\033[0;31m' # Red
Color_Off='\033[0m' # Text Reset
Yellow='\033[0;33m' # Yellow
function find_last {
egrep "^[ #]*${1}[ =]" $2 | tail -n1
}
function is_new {
for opt in $conf_warned
do
if [ "$opt" == "$1" ]
then
return 1
fi
done
# option not found return true
return 0
}
function verify_config {
local conf_opt
local conf_org
local conf_new
while read -r line
do
conf_opt=$(echo $line | grep "^[ #]*CONFIG_" | sed 's|.*\(CONFIG_[^ =]*\)[ =].*|\1|')
if [ -n "${conf_opt}" ]
then
conf_org=$(find_last ${conf_opt} .genconfig.config)
conf_new=$(find_last ${conf_opt} .config)
if [ "$conf_org" != "$conf_new" ]
then
if is_new $conf_opt
then
echo -e "config option [${Red}$conf_opt${Color_Off}] is not set correctly in .config"
echo -e "got value [${Yellow}$conf_new${Color_Off}] but wanted [${Yellow}$conf_org${Color_Off}]"
echo "This is a real problem somebody needs to investigate"
echo ""
conf_warned="$conf_warned $conf_opt"
fi
else
true
# for debug to see all options
#echo -e "wanted [$conf_org] got [$conf_new]"
fi
fi
done < .genconfig.config
}
# Takes a board name and returns the target name in global var $target
set_target() {
local profile=$1
[ -n "$profile" ] || return
if [ -n "$TARGET" -a -d "./target/linux/feeds/$TARGET" ]; then
local targetpath="./target/linux/feeds/$TARGET"
local profiles=
local pfound=0
if [ -e "$targetpath/genconfig" ]; then
profiles=$(cd $targetpath; ./genconfig)
for p in $profiles; do
if [ $p == $profile ]; then
pfound=1
break
fi
done
fi
if [ $pfound -eq 1 ]; then
target="$(echo $TARGET | tr '-' '_')"
target_config_path="$targetpath/config"
fi
return
fi
[ -e $brcmbca_feed/genconfig ] &&
brcmbca=$(cd $brcmbca_feed; ./genconfig)
[ -e $airoha_feed/genconfig ] &&
airoha=$(cd $airoha_feed; ./genconfig)
[ -e $x86_feed/genconfig ] &&
x86=$(cd $x86_feed; ./genconfig)
[ -e $armsr_feed/genconfig ] &&
armsr=$(cd $armsr_feed; ./genconfig)
[ -e $mediatek_feed/genconfig ] &&
mediatek=$(cd $mediatek_feed; ./genconfig)
[ -e $qualcomm_ipq95xx_feed/genconfig ] &&
ipq95xx=$(cd $qualcomm_ipq95xx_feed; ./genconfig)
[ -e $qualcomm_ipq53xx_feed/genconfig ] &&
ipq53xx=$(cd $qualcomm_ipq53xx_feed; ./genconfig)
if [ "$profile" == "LIST" ]; then
for list in brcmbca airoha x86 armsr mediatek ipq95xx ipq53xx; do
echo "$list based boards:"
a=$(echo "${!list}" | sort)
for b in $a; do
echo -e "\t$b"
done
done
return
fi
for p in $airoha; do
if [ $p == $profile ]; then
target="airoha"
target_config_path="$airoha_feed/config"
return
fi
done
for p in $x86; do
if [ $p == $profile ]; then
target="x86"
target_config_path="$x86_feed/config"
return
fi
done
for p in $armsr; do
if [ $p == $profile ]; then
target="armsr"
target_config_path="$armsr_feed/config"
return
fi
done
for p in $mediatek; do
if [ $p == $profile ]; then
target="mediatek"
target_config_path="$mediatek_feed/config"
return
fi
done
for p in $ipq95xx; do
if [ $p == $profile ]; then
target="ipq95xx"
target_config_path="$qualcomm_ipq95xx_feed/config"
return
fi
done
for p in $ipq53xx; do
if [ $p == $profile ]; then
target="ipq53xx"
target_config_path="$qualcomm_ipq53xx_feed/config"
return
fi
done
for p in $brcmbca; do
if [ $p == $profile ]; then
target="brcmbca"
target_config_path="$brcmbca_feed/config"
return
fi
done
}
git remote -v | grep -qE '(git@|ssh://)' && {
DEVELOPER=1
}
v() {
[ "$VERBOSE" -ge 1 ] && echo "$@"
}
usage() {
echo
echo 1>&2 "Usage: $0 genconfig_min-legacy [ OPTIONS ] < Board_Type > [ Customer [customer2 ]...]"
echo
echo -e " -c|--clean\t\tRemove all files under ./files and import from config "
echo -e " -D|--no-dirty\t\tIgnore dirty tree"
echo -e " -v|--verbose\t\tVerbose"
echo -e " -n|--no-update\tDo NOT! Update customer config before applying"
echo -e " -t|--target\t\tExplicitly specify the linux target to build the board profile from"
echo -e " -s|--override\t\tEnable 'Package source tree override'"
echo -e " -S|--brcmsingle\tForce build of bcmkernel to use only one thread"
echo -e " -h|--help\t\tShow this message"
echo -e " -l|--list [customer]\tList all Customers or all boards for one customer"
echo -e " -a|--list-all\t\tList all Customers and their board types"
echo -e " -b|--boards\t\tList all board types"
echo
echo "Example ./iop genconfig_min-legacy eg400 OPERATORX"
echo "(if no customerconfig is chosen, iopsys config will be used)"
echo
exit 0
}
list_customers()
{
local ALL="$1"
local CUSTOMER="$2"
if [ "$CUSTOMER" -a -d "$CUSTCONF/$CUSTOMER" ]; then
local boards="$(ls -1 "$CUSTCONF/$CUSTOMER" | grep -v common )"
if [ "$boards" ]; then
echo "$CUSTOMER has following boards:"
for board in $boards; do
echo -e "\t$board"
done
else
echo "No boards found for $CUSTOMER"
fi
elif [ "$CUSTOMER" ]; then
echo "No customer called $CUSTOMER"
exit 1
elif [ -d $CUSTCONF ]; then
local customers="$(ls -1 $CUSTCONF)"
if [ "$customers" -a "$ALL" == 1 ]; then
for customer in $customers; do
echo $customer
local boards="$(ls -1 $CUSTCONF/$customer | grep -v common )"
if [ "$boards" ]; then
for board in $boards; do
echo -e "\t$board"
done
else
echo "has no boards"
fi
done
elif [ "$customers" ]; then
echo -e "$customers"
else
echo "no customers found"
fi
else
echo "No $CUSTCONF folder found"
fi
exit 0
}
generate_config()
{
DIFFFILE="$1"
MASTERFILE="$2"
while read p; do
v "$p"
sed -r -i "$p" $MASTERFILE
done < $DIFFFILE
}
setup_dirs()
{
if [ ! -d "$FILEDIR" ]; then
mkdir -p $FILEDIR
elif [ -d "$FILEDIR" -a $CLEAN -eq 1 ]; then
v "rm -rf $FILEDIR*"
rm -rf $FILEDIR*
fi
}
get_subtarget_for_device() {
readonly target="$1"
readonly device="$2"
readonly targetinfo_file="tmp/info/.targetinfo-feeds_$target"
readonly target_profile_line="Target-Profile: DEVICE_$device"
# We want to know after which Target: $target/$subtarget line
# our $target_profile_line appears
# This is a crude way to "parse" the file using shell 🤯
# 1. grep for both lines with line number output
# 2. grep again to determine the device profile line that we looked for
# but output one context line before as well to determine corresponding subtarget line
# 4. Use head and sed to extract the subtarget
grep "^Target: $target/\|^$target_profile_line" "$targetinfo_file" \
| grep -E -B1 "^$target_profile_line" \
| head -n1 \
| sed -E "s|^Target: $target/||"
}
create_and_copy_files()
{
local BOARDTYPE=$1
shift
local CUSTOMERS=$@
# Validate seleced board and customers
set_target $BOARDTYPE
if [ $target == "bogus" ]; then
echo "Hardware profile does not exist"
exit 1
elif [ -n "$CUSTOMERS" ]; then
for CUSTOMER in $CUSTOMERS; do
if [ ! -d "$CUSTCONF/$CUSTOMER/" ]; then
echo "Customer profile for '$CUSTOMER' does not exist"
exit 1
elif [ ! -d "$CUSTCONF/$CUSTOMER/$BOARDTYPE/" ]; then
echo "'$BOARDTYPE' board profile does not exist for customer '$CUSTOMER'"
if [ -f "$CUSTCONF/$CUSTOMER/common/common.diff" ]; then
echo "Common profile configuration will be used"
else
exit 1
fi
fi
done
fi
# Generate base config
rm -f .config
v "Config $BOARDTYPE selected"
v "cp $CONFIGPATH/config .config"
cp $CONFIGPATH/config .config
if [ -f $target_config_path/config ]; then
cat $target_config_path/config >> .config
echo "" >> .config
fi
if [ -f $target_config_path/$BOARDTYPE/config ]; then
cat $target_config_path/$BOARDTYPE/config >> .config
echo "" >> .config
fi
# hack to support custom-devices until we have deprecated this genconfig-script...
local custom_found=false
local used_config_file
for config_file in feeds/*/devices/$target/config/$BOARDTYPE/config; do
if [ "$custom_found" = "true" ]; then
echo
echo "Error was found!"
echo "Please use only one path."
echo "Two instances of $target/config/$BOARDTYPE exists:"
echo "Path 1: $used_config_file"
echo "Path 2: $config_file"
return 1
fi
if [ -f "$config_file" ]; then
cat "$config_file" >> .config
echo "" >> .config
custom_found=true
used_config_file=$config_file
fi
done
# Special handling for targets which use TARGET_DEVICES
case "$target" in
airoha | mediatek | brcmbca | ipq95xx | ipq53xx)
# This assumes the device name to be unique within one target,
# which is a fair assumption to make.
local subtarget="$(get_subtarget_for_device "${target/_/-}" "$BOARDTYPE")"
if [ -z "$subtarget" ]; then
echo "Error determining subtarget for $target / ${BOARDTYPE}"
return 1
fi
echo "CONFIG_TARGET_${target}=y" >> .config
echo "CONFIG_TARGET_${target}_${subtarget}=y" >> .config
echo "CONFIG_TARGET_DEVICE_${target}_${subtarget}_DEVICE_${BOARDTYPE}=y" >> .config
echo "CONFIG_TARGET_MULTI_PROFILE=y" >> .config
echo "CONFIG_TARGET_PER_DEVICE_ROOTFS=y" >> .config
;;
*)
echo "CONFIG_TARGET_${target}=y" >> .config
echo "CONFIG_TARGET_${target}_${BOARDTYPE}=y" >> .config
;;
esac
echo "$CUSTOMERS $BOARDTYPE" > $CURRENT_CONFIG_FILE
# Add customerconfig diff if a customer is selected
if [ -n "$CUSTOMERS" ]; then
for CUSTOMER in $CUSTOMERS; do
if [ -d "$CUSTCONF/$CUSTOMER/common/fs" ]; then
v "cp -ar $CUSTCONF/$CUSTOMER/common/fs/* $FILEDIR"
cp -ar $CUSTCONF/$CUSTOMER/common/fs/* $FILEDIR
fi
if [ -d "$CUSTCONF/$CUSTOMER/$BOARDTYPE/fs" ]; then
v "cp -ar $CUSTCONF/$CUSTOMER/$BOARDTYPE/fs/* $FILEDIR"
cp -ar $CUSTCONF/$CUSTOMER/$BOARDTYPE/fs/* $FILEDIR
fi
if [ -e "$CUSTCONF/$CUSTOMER/common/common.diff" ]; then
v "Apply $CUSTCONF/$CUSTOMER/common/common.diff"
cat $CUSTCONF/$CUSTOMER/common/common.diff >> .config
echo "" >> .config
fi
if [ -e "$CUSTCONF/$CUSTOMER/$BOARDTYPE/$BOARDTYPE.diff" ]; then
v "Apply $CUSTCONF/$CUSTOMER/$BOARDTYPE/$BOARDTYPE.diff"
cat $CUSTCONF/$CUSTOMER/$BOARDTYPE/$BOARDTYPE.diff >> .config
echo "" >> .config
fi
done
fi
# Set target version
local git_version
if ! git_version="$(git describe --always $DIRTY --tags --match '[0-9].*.*' --match '[0-9][0-9].*.*')"; then
echo "ERROR: Failed getting version via git describe, exiting." >&2
return 1
fi
local version="${git_version,,}${CUSTOMERS:+-${CUSTOMERS// /}}"
local version_lower="${version,,}"
echo "CONFIG_TARGET_VERSION=\"${version_lower}\"" >> .config
echo "CONFIG_VERSION_CODE=\"${version_lower}\"" >> .config
echo "CONFIG_VERSION_PRODUCT=\"$BOARDTYPE"\" >> .config
# Enable Package source tree override if selected
[ $SRCTREEOVERR -eq 1 ] && echo CONFIG_SRC_TREE_OVERRIDE=y >> .config
# developer mode selected ?
echo "CONFIG_DEVEL=y" >>.config
if [ -n "$BRCM_MAX_JOBS" ]
then
echo "CONFIG_BRCM_MAX_JOBS=\"1\"" >>.config
fi
# Force regeneration of kernel Makefile
# Needed to disable kmods for iopsys-brcm targets
touch package/kernel/linux/Makefile
# we need to signal to bradcom SDK that we have changed the board id
# currently boardparms.c and boardparms_voice.c is the only place that is depending on boardid name
# so just touch that file.
[ -d ./build_dir ] && find build_dir/ -name "boardparms*c" -print0 2>/dev/null | xargs -0 touch 2>/dev/null
# Store generated config
cp .config .genconfig.config
# Set default values based on selected parameters
v "$(make defconfig 2>&1)"
echo Set version to $(grep -w CONFIG_TARGET_VERSION .config | cut -d'=' -f2 | tr -d '"')
# Clean base-file package to force rebuild when changing profile
v "$(make package/base-files/clean 2>&1)"
verify_config
}
####### main #####
if [ ! -e tmp/.iop_bootstrap ]; then
echo "You have not installed feeds. Running genconfig in this state would create a non functional configuration."
echo "Run: iop feeds_update"
exit 1
fi
if [ $# -eq 0 ]; then
echo Current profile:
cat $CURRENT_CONFIG_FILE
echo "Try ./iop genconfig_min-legacy -h' to get instructions if you want to change current config"
exit 0
else
while [ -n "$1" ]; do
case "$1" in
-c|--clean) export CLEAN=1;;
-D|--no-dirty) export DIRTY="";;
-n|--no-update) export IMPORT=0;;
-v|--verbose) export VERBOSE="$(($VERBOSE + 1))";;
-t|--target) export TARGET="$2"; shift;;
-p|--profile) export PROFILE="$2"; shift;;
-r|--repo) export CUSTREPO="$2"; shift;;
-s|--override) export SRCTREEOVERR=1;;
-S|--brcmsingel) export BRCM_MAX_JOBS=1;;
-h|--help) usage;;
-l|--list) list_customers 0 $2;;
-a|--list-all)list_customers 1;;
-b|--boards)set_target LIST;exit 0;;
-*)
echo "Invalid option: $1 "
echo "Try -h or --help for more information."
exit 1
;;
*) break;;
esac
shift;
done
CUSTREPO="${CUSTREPO:-git@dev.iopsys.eu:consumer/iopsys.git}"
setup_dirs
create_and_copy_files "$@"
fi
}
register_command "genconfig_min-legacy" "Generate configuration for customer with manual board configuration - legacy mode"

View File

@@ -1,29 +0,0 @@
#!/bin/bash
# Function to convert parameters to lowercase
function to_lowercase {
local params=()
for param in "$@"; do
params+=("$(tr '[:upper:]' '[:lower:]' <<< "$param")")
done
echo "${params[@]}"
}
function genconfig {
target_script="./scripts/gen_config.py"
# First convert all to lowercase
args=$(to_lowercase "$@")
# Check if an option is provided
if [[ ${args[0]} == -* ]]; then
# Convert options for target script
if [[ ${args[0]} == "-b" || ${args[0]} == "--boards" ]]; then
args=("--list")
fi
fi
${target_script} ${args[@]}
}
register_command "genconfig" "Generate configuration for board and customer"

View File

@@ -1,283 +0,0 @@
# this is a developer helper script to install firmware on a remote host with SSH
function upd_usage {
echo "usage: $0 ssh_upgrade [-t <host>] [-f <file>] [opts] "
echo ""
echo " Default host is 192.168.1.1"
echo " Default firmware file is the latest one (last.{itb,pkgtb})"
echo " Default is to not keep configuration"
echo "opts:"
echo ""
echo " -i Interactive use, allows to select firmware file"
echo " -n Do not do the final reboot of the target board"
echo " -c Keep configuration"
echo " -x Force install even if firmware is not for this board"
echo " -b Force install of bootloader regardless of version installed"
}
function set_config_string {
eval $(grep $1 .config)
}
function upd_ask_ok {
echo "Will continue with the following settings:"
echo "-----------------------------------------"
printf "%20s: %s\n" "Firmware file" "$upd_fw_base"
printf "%20s: %s\n" "Host IP" "$upd_host"
printf "%20s: " "Reboot"
if [ "$upd_noreboot" == "0" ]; then printf "Yes\n"; else printf "No\n"; fi
printf "%20s: " "Keep config"
if [ "$upd_keepconf" == "1" ]; then printf "Yes\n"; else printf "No\n"; fi
printf "%20s: " "Force bootloader"
if [ "$upd_forceboot" == "1" ]; then printf "Yes\n"; else printf "No\n"; fi
printf "%20s: " "Force image upgrade"
if [ "$upd_forceimage" == "1" ]; then printf "Yes\n"; else printf "No\n"; fi
echo "-----------------------------------------"
echo -n "Continue? [Y/n/q]:"
read answer
case $answer in
n | N)
return 1
;;
q | Q)
exit 1
;;
y | Y | *)
return 0
;;
esac
}
function upd_select_file {
dialog --keep-tite --title "To select a file, use TAB/ARROW to highlight then press SPACEBAR -> RETURN" \
--fselect "${upd_fw:-bin/targets/$CONFIG_TARGET_BOARD/$CONFIG_TARGET_SUBTARGET/}" \
$((lines - 10)) $((cols - 5)) \
2>$tempfile
new_file=$(cat $tempfile)
if [ -n "$new_file" ]; then
upd_fw="$new_file"
upd_fw_base=$(basename $upd_fw)
fi
}
function upd_select_target {
dialog --keep-tite --title "Input the hostname/IP of the target board" \
--inputbox "Name/IP" \
$((lines - 10)) $((cols - 5)) \
"$upd_host" \
2>$tempfile
new_file=$(cat $tempfile)
if [ -n "$new_file" ]; then
upd_host="$new_file"
fi
}
function upd_select_reboot {
dialog --keep-tite --radiolist "Should the board reboot after download finished" \
$((lines - 5)) $((cols - 5)) $((lines - 5 - 5)) \
"Reboot" "Restart board after done" $(if [ "$upd_noreboot" == "0" ]; then echo "ON"; else echo "OFF"; fi) \
"No reboot" "Continue running old system" $(if [ "$upd_noreboot" == "1" ]; then echo "ON"; else echo "OFF"; fi) \
2>$tempfile
res=$(cat $tempfile)
case $res in
"No reboot")
upd_noreboot=1
;;
"Reboot")
upd_noreboot=0
;;
esac
}
function upd_select_config {
dialog --keep-tite --radiolist "Should the configuration be kept" \
$((lines - 5)) $((cols - 5)) $((lines - 5 - 5)) \
"Keep" "Keep the config from old system" $(if [ "$upd_keepconf" == "1" ]; then echo "ON"; else echo "OFF"; fi) \
"Default" "Use default config for new system" $(if [ "$upd_keepconf" == "0" ]; then echo "ON"; else echo "OFF"; fi) \
2>$tempfile
res=$(cat $tempfile)
case $res in
"Keep")
upd_keepconf=1
;;
"Default")
upd_keepconf=0
;;
esac
}
function upd_select_forceboot {
dialog --keep-tite --radiolist "Should the boot loader be updated regardless of the version installed" \
$((lines - 5)) $((cols - 5)) $((lines - 5 - 5)) \
"Force" "Always update boot loader" $(if [ "$upd_forceboot" == "1" ]; then echo "ON"; else echo "OFF"; fi) \
"Version check" "Only upgrade if version is newer" $(if [ "$upd_forceboot" == "0" ]; then echo "ON"; else echo "OFF"; fi) \
2>$tempfile
res=$(cat $tempfile)
case $res in
"Force")
upd_forceboot=1
;;
"Version check")
upd_forceboot=0
;;
esac
}
function upd_select_forceimage {
dialog --keep-tite --radiolist "Should the image be stored in flash even if sanity checks would reject it" \
$((lines - 5)) $((cols - 5)) $((lines - 5 - 5)) \
"Force" "Disable sanity check and force use of image (dangerous)" $(if [ "$upd_forceimage" == "1" ]; then echo "ON"; else echo "OFF"; fi) \
"Only compatible" "Normal checks apply" $(if [ "$upd_forceimage" == "0" ]; then echo "ON"; else echo "OFF"; fi) \
2>$tempfile
res=$(cat $tempfile)
case $res in
"Force")
upd_forceimage=1
;;
"Only compatible")
upd_forceimage=0
;;
esac
}
function upd_select {
dialog --keep-tite --ok-label "Select" --cancel-label "Done" --menu "Select item to change" \
$((lines - 5)) $((cols - 5)) $((lines - 5 - 5)) \
"Firmware file" "$upd_fw_base" \
"Host IP" "$upd_host" \
"Reboot" $(if [ "$upd_noreboot" == "0" ]; then printf "Yes\n"; else printf "No\n"; fi) \
"Keep config" $(if [ "$upd_keepconf" == "1" ]; then printf "Yes\n"; else printf "No\n"; fi) \
"Force bootloader" $(if [ "$upd_forceboot" == "1" ]; then printf "Yes\n"; else printf "No\n"; fi) \
"Force image upgrade" $(if [ "$upd_forceimage" == "1" ]; then printf "Yes\n"; else printf "No\n"; fi) \
2>$tempfile
case $(cat $tempfile) in
"Firmware file")
upd_select_file
;;
"Host IP")
upd_select_target
;;
"Reboot")
upd_select_reboot
;;
"Keep config")
upd_select_config
;;
"Force bootloader")
upd_select_forceboot
;;
"Force image upgrade")
upd_select_forceimage
;;
*)
return
;;
esac
upd_select
}
function upd_select_start {
lines=$(tput lines)
cols=$(tput cols)
tempfile="$(mktemp)"
trap "rm -f $tempfile" 0 1 2 5 15
upd_select
}
function ssh_upgrade {
upd_noreboot=0
upd_forceboot=0
upd_keepconf=0
upd_forceimage=0
upd_fw_base=""
upd_fw=""
upd_host="192.168.1.1"
do_dialog=0
while getopts "f:hnxt:icb" opt; do
case $opt in
n)
upd_noreboot=1
;;
x)
upd_forceimage=1
;;
b)
upd_forceboot=1
;;
c)
upd_keepconf=1
;;
v)
verbose=$OPTARG
;;
f)
upd_fw=$OPTARG
;;
t)
upd_host=$OPTARG
;;
i)
do_dialog=1
;;
h)
upd_usage
exit 1
;;
\?)
echo "Invalid option: -$OPTARG" >&2
exit 1
;;
esac
done
if [ -z "$upd_fw" ]; then
set_config_string CONFIG_TARGET_BOARD
set_config_string CONFIG_TARGET_SUBTARGET
upd_fw="$(realpath -q --canonicalize-existing --relative-to=. "bin/targets/$CONFIG_TARGET_BOARD/$CONFIG_TARGET_SUBTARGET/"last.{pkgtb,itb})"
if [ -z "$upd_fw" ] && [ $do_dialog -eq 0 ]; then
echo "Could not find image. Check that last.{itb,pkgtb} exists or specify an image using -f <image> or -i (interactive)." >&2
return 1
fi
fi
upd_fw_base="$(basename "$upd_fw")"
[ $do_dialog -eq 1 ] && upd_select_start
if ! upd_ask_ok; then
upd_select_start
if ! upd_ask_ok; then
exit 1
fi
fi
if [ ! -f $upd_fw ]; then
echo "Firmware file $firmware does not exist."
exit 1
fi
extra_args=""
[ $upd_noreboot -eq 1 ] && extra_args="$extra_args --no-reboot"
[ $upd_forceimage -eq 1 ] && extra_args="$extra_args --force"
[ $upd_keepconf -eq 0 ] && extra_args="$extra_args -n"
[ $upd_forceboot -eq 1 ] && extra_args="$extra_args --force-loader-upgrade"
pv "$upd_fw" |
ssh \
-o ConnectTimeout=60 \
-o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null \
root@"$upd_host" \
sh -c "cat > '/tmp/$upd_fw_base' && (set -x && sysupgrade -v $extra_args /tmp/$upd_fw_base)" ||
echo "Sysupgrade failed" >&2 && return 1
}
register_command "ssh_upgrade" "-t <host> -f <file> [opts] Install firmware on remote host with SSH"

View File

@@ -1,35 +0,0 @@
#!/bin/sh
function license_report {
LICDIR="/tmp/licenses-generator/"
LICBIN="${LICDIR}/bin"
dpkg -s python3 python3-requests python3-yaml python3-mako python3-six &> /dev/null
if [ $? -ne 0 ]
then
echo "Missing dependencies"
sudo apt-get update
sudo apt-get install python3 python3-requests python3-yaml python3-mako python3-six
else
echo "Dependecy check passed"
fi
if [ -d "$LICDIR" ]; then
### Take action if $DIR exists ###
echo "Creating json licences file and html formated report"
else
### Control will jump here if $DIR does NOT exists ###
echo "Error: licenses-generator not found. getting from iopsys repo"
git clone git@dev.iopsys.eu:iopsys/licenses-generator.git $LICDIR
fi
LICGET=`${LICBIN}/licenses-generator gen-License bin/`
echo $LICGET
${LICBIN}/licenses-generator gen-licrprt $LICGET
exit 0
}
register_command "license_report" "Generate a Licence report on latest build in json format and html under reports"

View File

@@ -1,89 +0,0 @@
# Shorthand command for doing a HIL runtime smoketest on the
# latest built image. Does the image boot up correctly?
# More info here:
# https://dev.iopsys.eu/iopsys/iopsys-taas
#--------------------------------------------------------------
function taas-init() {
local f
# Path to TaaS binarys. Try some likely ones.
if ! which taas-smoketest >/dev/null; then
PATH="${PATH}:${PWD}/../iopsys-taas/bin"
PATH="${PATH}:${PWD}/../taas/bin"
PATH="${PATH}:${HOME}/iopsys-taas/bin"
PATH="${PATH}:${HOME}/taas/bin"
PATH="${PATH}:${HOME}/bin"
PATH="${PATH}:/opt/iopsys-taas/bin"
PATH="${PATH}:/opt/taas/bin"
fi
if ! which taas-smoketest >/dev/null; then
echo "Error; TaaS is missing! Install it with:"
echo "git clone git@dev.iopsys.eu:iopsys/iopsys-taas.git ../iopsys-taas"
exit 1
fi
# Create a list of all images which might be of use.
for f in ${PWD}/bin/targets/iopsys-*/generic/last.*; do
[[ -s "$f" ]] && images+=("$f")
done
# Convert Iopsys target name to the TaaS product name format
# according to what is available in the remote lab for HIL.
# Also find a suitable image.
product=$(grep CONFIG_TARGET_PROFILE .config | \
tr -s "=\"" " " | cut -d " " -f 2) || exit
case "$product" in
smarthub3)
export product="SmartHub3a"
;;
dg400prime|eg400|ex600)
export product=$(echo -n "$product" | tr [[:lower:]] [[:upper:]])
;;
*)
echo "Unsupported target; skipping!"
exit 0
;;
esac
if [[ ${#images[@]} -eq 0 ]]; then
echo "No image found"
exit 1
fi
}
#--------------------------------------------------------------
function taas-smoketest {
declare -a images
taas-init || return
echo "Testing a $product with ${images[@]}..."
command taas-smoketest "${images[@]}" "$product" "$@"
}
#--------------------------------------------------------------
function taas-bootstrap {
declare -a images
if [[ -n "$1" ]]; then
taas-init || return
echo "Flashing $1..."
command taas-bootstrap "${images[@]}" "$@"
else
echo "Usage: ./iop taas-bootstrap dutX"
exit 1
fi
}
register_command "taas-bootstrap" "Write image to a remote lab device."
register_command "taas-smoketest" "Write image to a remote lab device and test it."

View File

@@ -1,61 +0,0 @@
#!/bin/sh
# Exported interface
function update_feed_branches {
local release="$1"
local ipath="$(pwd)"
local branch="$2"
local curbranch
[ -n "$release" ] || {
echo "Usage: ./update_feeds <RELEASE> <BRANCH>"
echo ""
echo "If you do not give a branch as argument,"
echo "<RELEASE> branch will be updated to commit"
echo "hash given in feeds.conf for each feed repo"
exit 1
}
if [ -n "$branch" ]; then
echo "Updating release branch $release to specific commit hash given in feeds.conf for each feed repo at branch $branch"
if git diff-index --quiet HEAD; then
curbranch=`git symbolic-ref HEAD 2>/dev/null`
curbranch=${curbranch##refs/heads/}
if [ -z $curbranch ]; then
curbranch=`git log -1 --pretty=format:"%H"`
fi
git checkout $branch || {
echo "couldn't checkout branch $branch"
exit 99
}
else
echo "You have unsaved changes."
exit 99
fi
else
echo "Updating release branch $release to specific commit hash given in feeds.conf for each feed repo"
fi
ifeeds="$(grep -r 'dev.iopsys.eu' feeds.conf | awk '{print$2}' | tr '\n' ' ')"
for f in $ifeeds; do
commith=$(grep $f feeds.conf | cut -d'^' -f2)
cd $ipath/feeds/$f
git branch -D $release 2>/dev/null
echo "$f: updating release branch $release to commit $commith"
git checkout $commith
git push origin :$release
git checkout -b $release
git push --set-upstream origin $release
cd $ipath
done
if [ -n "$branch" ]; then
echo "Release branch $release is updated to specific commit hash given in feeds.conf in in branch $branch for each feed repo"
git checkout $curbranch
else
echo "Release branch $release is updated to specific commit hash given in feeds.conf for each feed repo"
fi
}
register_command "update_feed_branches" "<release> [branch] Update branches in feeds from the current top level commit or specified top level branch"

View File

@@ -1,7 +0,0 @@
update_package() {
echo "update_package is no longer supported." >&2
echo "Its replacement is ./iop set-feed-rev." >&2
return 1
}
register_command "update_package" "No longer used command"

View File

@@ -4,7 +4,7 @@ PKG_NAME:=iopsys-analytics
PKG_RELEASE:=$(COMMITCOUNT)
PKG_LICENSE:=PROPRIETARY
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=1a749bdebd142a83ba0733f1644a6241403c9097
PKG_SOURCE_VERSION:=00189cea0a78b7a30dbfdd363b6d8e836437d1bc
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/iopsys-analytics.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip

View File

@@ -6,15 +6,24 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=ipt-trigger
PKG_VERSION:=1.0.0
PKG_VERSION:=1.0.2
PKG_LICENSE:=GPL-2.0
LOCAL_DEV:=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=4f3d4427403e0a9be7653c1b92907ae8ae5f21ae
PKG_SOURCE_URL:=https://dev.iopsys.eu/network/ipt-trigger.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_HASH:=skip
endif
include $(INCLUDE_DIR)/package.mk
define KernelPackage/ipt-trigger
SUBMENU:=Other modules
TITLE:=Kernel module for iptables port trigger
FILES:=$(PKG_BUILD_DIR)/ipv4/ipt_TRIGGER.ko
FILES:=$(PKG_BUILD_DIR)/src/ipv4/ipt_TRIGGER.ko
DEPENDS+=+kmod-nf-nat +xtables-legacy
AUTOLOAD:=$(call AutoLoad,30,ipt_TRIGGER,1)
KCONFIG:=
@@ -24,7 +33,7 @@ define KernelPackage/ip6t-trigger
SUBMENU:=Other modules
TITLE:=Kernel module for ip6tables port trigger
DEPENDS+=+kmod-nf-nat +xtables-legacy
FILES:=$(PKG_BUILD_DIR)/ipv6/ip6t_TRIGGER.ko
FILES:=$(PKG_BUILD_DIR)/src/ipv6/ip6t_TRIGGER.ko
AUTOLOAD:=$(call AutoLoad,30,ip6t_TRIGGER,1)
KCONFIG:=
endef
@@ -41,21 +50,28 @@ ifeq ($(CONFIG_TARGET_brcmbca),y)
include ../../broadcom/bcmkernel/bcm-kernel-toolchain.mk
endif
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ./src/* $(PKG_BUILD_DIR)/
$(CP) $(PKG_BUILD_DIR)/ipt_TRIGGER.h $(LINUX_DIR)/include/linux/netfilter_ipv4/
$(CP) -rf ./ipt-trigger/* $(PKG_BUILD_DIR)/
$(CP) ./ipt-trigger/include/ipt_TRIGGER.h $(LINUX_DIR)/include/linux/netfilter_ipv4/
endef
else
define Build/Prepare
$(Build/Prepare/Default)
$(CP) $(PKG_BUILD_DIR)/include/ipt_TRIGGER.h $(LINUX_DIR)/include/linux/netfilter_ipv4/
endef
endif
define Build/InstallDev
$(INSTALL_DIR) $(1)/include/linux/netfilter_ipv4
$(CP) $(PKG_BUILD_DIR)/ipt_TRIGGER.h $(1)/include/linux/netfilter_ipv4/
$(CP) $(PKG_BUILD_DIR)/include/ipt_TRIGGER.h $(1)/include/linux/netfilter_ipv4/
endef
KERNEL_MAKE_FLAGS += -I$(LINUX_DIR)/include
define Build/Compile
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/ipv4/" modules
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/ipv6/" modules
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/src/ipv4/" modules
$(KERNEL_MAKE) M="$(PKG_BUILD_DIR)/src/ipv6/" modules
endef
$(eval $(call KernelPackage,ipt-trigger))

View File

@@ -1,26 +0,0 @@
#ifndef _IPT_TRIGGER_H_target
#define _IPT_TRIGGER_H_target
#define TRIGGER_TIMEOUT 600 /* 600 secs */
enum ipt_trigger_type
{
IPT_TRIGGER_DNAT = 1,
IPT_TRIGGER_IN = 2,
IPT_TRIGGER_OUT = 3,
IPT_TRIGGER_REFRESH = 4
};
struct ipt_trigger_ports {
u_int16_t mport[2]; /* Related destination port range */
u_int16_t rport[2]; /* Port range to map related destination port range to */
};
struct ipt_trigger_info {
enum ipt_trigger_type type;
u_int16_t proto; /* Related protocol */
u_int16_t trigger_timeout; /* Auto disable duration */
struct ipt_trigger_ports ports;
};
#endif /*_IPT_TRIGGER_H_target*/

View File

@@ -1 +0,0 @@
obj-m +=ipt_TRIGGER.o

View File

@@ -1,407 +0,0 @@
/* Kernel module to match the port-ranges, trigger related port-ranges,
* and alters the destination to a local IP address.
*
* Copyright (C) 2003, CyberTAN Corporation
* All Rights Reserved.
*
* Description:
* This is kernel module for port-triggering.
*
* The module follows the Netfilter framework, called extended packet
* matching modules.
*/
#include <linux/types.h>
#include <linux/ip.h>
#include <linux/tcp.h>
#include <linux/timer.h>
#include <linux/module.h>
#include <linux/netfilter.h>
#include <linux/netdevice.h>
#include <linux/if.h>
#include <linux/inetdevice.h>
#include <linux/list.h>
#include <net/protocol.h>
#include <net/checksum.h>
#include <linux/spinlock.h>
#include <linux/netfilter_ipv4.h>
#include <linux/netfilter_ipv4/ip_tables.h>
#include <net/netfilter/nf_conntrack.h>
#include <net/netfilter/nf_conntrack_core.h>
#include <net/netfilter/nf_conntrack_tuple.h>
#include <net/netfilter/nf_nat.h>
#include <linux/netfilter_ipv4/ipt_TRIGGER.h>
/* This rwlock protects the main hash table, protocol/helper/expected
* registrations, conntrack timers*/
static DEFINE_SPINLOCK(nf_trigger_lock);
#define NF_IP_PRE_ROUTING 0
#define NF_IP_FORWARD 2
#define IPT_CONTINUE XT_CONTINUE
/***********************lock help**********************/
#define MUST_BE_READ_LOCKED(l)
#define MUST_BE_WRITE_LOCKED(l)
#define LOCK_BH(l) spin_lock_bh(l)
#define UNLOCK_BH(l) spin_unlock_bh(l)
#define ASSERT_READ_LOCK(x) MUST_BE_READ_LOCKED(&nf_trigger_lock)
#define ASSERT_WRITE_LOCK(x) MUST_BE_WRITE_LOCKED(&nf_trigger_lock)
/***********************list help**********************/
#define LIST_FIND(head, cmpfn, type, args...) \
({ \
const struct list_head *__i, *__j = NULL; \
\
ASSERT_READ_LOCK(head); \
list_for_each(__i, (head)) \
if (cmpfn((const type)__i , ## args)) { \
__j = __i; \
break; \
} \
(type)__j; \
})
static inline int
__list_cmp_same(const void *p1, const void *p2) { return p1 == p2; }
static inline void
list_prepend(struct list_head *head, void *new)
{
ASSERT_WRITE_LOCK(head);
list_add(new, head);
}
#define list_named_find(head, name) \
LIST_FIND(head, __list_cmp_name, void *, name)
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Netfilter Core Team <coreteam@netfilter.org>");
MODULE_DESCRIPTION("iptables trigger target module");
#if 0
#define DEBUGP printk
#else
#define DEBUGP(format, args...)
#endif
struct ipt_trigger {
struct list_head list; /* Trigger list */
struct timer_list timeout; /* Timer for list destroying */
u_int32_t srcip; /* Outgoing source address */
u_int32_t dstip; /* Outgoing destination address */
u_int16_t mproto; /* Trigger protocol */
u_int16_t rproto; /* Related protocol */
u_int16_t trigger_timeout; /* Auto disable duration */
struct ipt_trigger_ports ports; /* Trigger and related ports */
u_int8_t reply; /* Confirm a reply connection */
};
LIST_HEAD(ipt_trigger_list);
static void trigger_refresh(struct ipt_trigger *trig, unsigned long extra_jiffies)
{
DEBUGP("%s: \n", __FUNCTION__);
LOCK_BH(&nf_trigger_lock);
/* Need del_timer for race avoidance (may already be dying). */
if (del_timer(&trig->timeout)) {
trig->timeout.expires = jiffies + extra_jiffies;
add_timer(&trig->timeout);
}
UNLOCK_BH(&nf_trigger_lock);
}
static void __del_trigger(struct ipt_trigger *trig)
{
DEBUGP("%s: \n", __FUNCTION__);
MUST_BE_WRITE_LOCKED(&nf_trigger_lock);
/* delete from 'ipt_trigger_list' */
list_del(&trig->list);
kfree(trig);
}
static void trigger_timeout(struct timer_list *t)
{
struct ipt_trigger *trig = from_timer(trig, t, timeout);
DEBUGP("trigger list %p timed out\n", trig);
LOCK_BH(&nf_trigger_lock);
__del_trigger(trig);
UNLOCK_BH(&nf_trigger_lock);
}
static unsigned int
add_new_trigger(struct ipt_trigger *trig)
{
struct ipt_trigger *new = NULL;
DEBUGP("!!!!!!!!!!!! %s !!!!!!!!!!!\n", __FUNCTION__);
LOCK_BH(&nf_trigger_lock);
new = (struct ipt_trigger *)
kmalloc(sizeof(struct ipt_trigger), GFP_ATOMIC);
if (!new) {
UNLOCK_BH(&nf_trigger_lock);
DEBUGP("%s: OOM allocating trigger list\n", __FUNCTION__);
return -ENOMEM;
}
memset(new, 0, sizeof(*trig));
INIT_LIST_HEAD(&new->list);
memcpy(new, trig, sizeof(*trig));
/* add to global table of trigger */
list_prepend(&ipt_trigger_list, &new->list);
/* add and start timer if required */
timer_setup(&new->timeout, trigger_timeout, 0);
mod_timer(&new->timeout, jiffies + (trig->trigger_timeout * HZ));
UNLOCK_BH(&nf_trigger_lock);
return 0;
}
/*
* Service-Name OutBound InBound
* 1. TMD UDP:1000 TCP/UDP:2000..2010
* 2. WOKAO UDP:1000 TCP/UDP:3000..3010
* 3. net2phone-1 UDP:6801 TCP:30000..30000
* 4. net2phone-2 UDP:6801 UDP:30000..30000
*
* For supporting to use the same outgoing port to trigger different port rules,
* it should check the inbound protocol and port range value. If all conditions
* are matched, it is a same trigger item, else it needs to create a new one.
*/
static inline int trigger_out_matched(const struct ipt_trigger *i,
const u_int16_t proto, const u_int16_t dport, const struct ipt_trigger_info *info)
{
DEBUGP("%s: i=%p, proto= %d, dport=%d.\n", __FUNCTION__, i, proto, dport);
DEBUGP("%s: Got one, mproto= %d, mport[0..1]=%d, %d, ", __FUNCTION__,
i->mproto, i->ports.mport[0], i->ports.mport[1]);
DEBUGP("rproto= %d, rport[0..1]=%d, %d.\n",
i->rproto, i->ports.rport[0], i->ports.rport[1]);
return ((i->mproto == proto) &&
(i->ports.mport[0] <= dport) &&
(i->ports.mport[1] >= dport) &&
(i->rproto == info->proto) &&
(i->ports.rport[0] == info->ports.rport[0]) &&
(i->ports.rport[1] == info->ports.rport[1]));
}
static unsigned int
trigger_out(struct sk_buff *skb,
unsigned int hooknum,
const void *targinfo)
{
const struct ipt_trigger_info *info = targinfo;
struct ipt_trigger trig, *found;
const struct iphdr *iph = ip_hdr(skb);
struct tcphdr *tcph = (void *)iph + iph->ihl*4; /* Might be TCP, UDP */
DEBUGP("############# %s ############\n", __FUNCTION__);
/* Check if the trigger range has already existed in 'ipt_trigger_list'. */
found = LIST_FIND(&ipt_trigger_list, trigger_out_matched,
struct ipt_trigger *, iph->protocol, ntohs(tcph->dest), info);
if (found) {
/* Yeah, it exists. We need to update(delay) the destroying timer. */
trigger_refresh(found, info->trigger_timeout * HZ);
/* In order to allow multiple hosts use the same port range, we update
the 'saddr' after previous trigger has a reply connection. */
if (found->reply)
found->srcip = iph->saddr;
}
else {
/* Create new trigger */
memset(&trig, 0, sizeof(trig));
trig.srcip = iph->saddr;
trig.mproto = iph->protocol;
trig.rproto = info->proto;
trig.trigger_timeout = info->trigger_timeout;
memcpy(&trig.ports, &info->ports, sizeof(struct ipt_trigger_ports));
add_new_trigger(&trig); /* Add the new 'trig' to list 'ipt_trigger_list'. */
}
return IPT_CONTINUE; /* We don't block any packet. */
}
static inline int trigger_in_matched(const struct ipt_trigger *i,
const u_int16_t proto, const u_int16_t dport)
{
u_int16_t rproto = i->rproto;
DEBUGP("%s: i=%p, proto= %d, dport=%d.\n", __FUNCTION__, i, proto, dport);
DEBUGP("%s: Got one, rproto= %d, rport[0..1]=%d, %d.\n", __FUNCTION__,
i->rproto, i->ports.rport[0], i->ports.rport[1]);
if (!rproto)
rproto = proto;
return ((rproto == proto) && (i->ports.rport[0] <= dport)
&& (i->ports.rport[1] >= dport));
}
static unsigned int
trigger_in(struct sk_buff *skb,
unsigned int hooknum,
const void *targinfo)
{
const struct ipt_trigger_info *info = targinfo;
struct ipt_trigger *found;
const struct iphdr *iph = ip_hdr(skb);
struct tcphdr *tcph = (void *)iph + iph->ihl*4; /* Might be TCP, UDP */
/* Check if the trigger-ed range has already existed in 'ipt_trigger_list'. */
found = LIST_FIND(&ipt_trigger_list, trigger_in_matched,
struct ipt_trigger *, iph->protocol, ntohs(tcph->dest));
if (found) {
DEBUGP("############# %s ############\n", __FUNCTION__);
/* Yeah, it exists. We need to update(delay) the destroying timer. */
trigger_refresh(found, info->trigger_timeout * HZ);
return NF_ACCEPT; /* Accept it, or the imcoming packet could be
dropped in the FORWARD chain */
}
return IPT_CONTINUE; /* Our job is the interception. */
}
static unsigned int
trigger_dnat(struct sk_buff *skb,
unsigned int hooknum,
const void *targinfo)
{
struct ipt_trigger *found = NULL;
const struct iphdr *iph = ip_hdr(skb);
struct tcphdr *tcph = (void *)iph + iph->ihl*4; /* Might be TCP, UDP */
struct nf_conn *ct = NULL;
enum ip_conntrack_info ctinfo;
struct nf_nat_range2 newrange;
DEBUGP("############# %s ############%d\n", __FUNCTION__, __LINE__);
/* Check if the trigger-ed range has already existed in 'ipt_trigger_list'. */
found = LIST_FIND(&ipt_trigger_list, trigger_in_matched,
struct ipt_trigger *, iph->protocol, ntohs(tcph->dest));
if (found) {
DEBUGP("############# %s ############%d srcip:%d\n", __FUNCTION__, __LINE__, found->srcip);
}
if (!found || !found->srcip)
return IPT_CONTINUE; /* We don't block any packet. */
DEBUGP("############# %s ############\n", __FUNCTION__);
found->reply = 1; /* Confirm there has been a reply connection. */
ct = nf_ct_get(skb, &ctinfo);
DEBUGP("%s: got ", __FUNCTION__);
/* Alter the destination of imcoming packet. */
/* Transfer from original range. */
memset(&newrange.min_addr, 0, sizeof(newrange.min_addr));
memset(&newrange.max_addr, 0, sizeof(newrange.max_addr));
memset(&newrange.min_proto, 0, sizeof(newrange.min_proto));
memset(&newrange.max_proto, 0, sizeof(newrange.max_proto));
newrange.flags = NF_NAT_RANGE_MAP_IPS;
newrange.min_addr.ip = found->srcip;
newrange.max_addr.ip = found->srcip;
DEBUGP("%s: found->srcip = %x\n", __FUNCTION__, found->srcip);
/* Hand modified range to generic setup. */
return nf_nat_setup_info(ct, &newrange, NF_NAT_MANIP_DST);
}
static unsigned int
trigger_target(struct sk_buff *skb,
const struct xt_action_param *par)
{
const struct ipt_trigger_info *info = par->targinfo;
const struct iphdr *iph = ip_hdr(skb);
unsigned int hooknum = xt_hooknum(par);
DEBUGP("%s: type = %s\n", __FUNCTION__,
(info->type == IPT_TRIGGER_DNAT) ? "dnat" :
(info->type == IPT_TRIGGER_IN) ? "in" : "out");
/* The Port-trigger only supports TCP and UDP. */
if ((iph->protocol != IPPROTO_TCP) && (iph->protocol != IPPROTO_UDP))
return IPT_CONTINUE;
if (info->type == IPT_TRIGGER_OUT)
return trigger_out(skb, hooknum, info);
else if (info->type == IPT_TRIGGER_IN)
return trigger_in(skb, hooknum, info);
else if (info->type == IPT_TRIGGER_DNAT)
return trigger_dnat(skb, hooknum, info);
return IPT_CONTINUE;
}
static int
trigger_check(const struct xt_tgchk_param *par)
{
const struct ipt_trigger_info *info = par->targinfo;
if ((strcmp(par->table, "mangle") == 0)) {
DEBUGP("trigger_check: bad table `%s'.\n", par->table);
return -EINVAL;
}
if (par->hook_mask & ~((1 << NF_IP_PRE_ROUTING) | (1 << NF_IP_FORWARD))) {
DEBUGP("trigger_check: bad hooks %x.\n", par->hook_mask);
return -EINVAL;
}
if (info->proto) {
if (info->proto != IPPROTO_TCP && info->proto != IPPROTO_UDP) {
DEBUGP("trigger_check: bad proto %d.\n", info->proto);
return -EINVAL;
}
}
if (info->type == IPT_TRIGGER_OUT) {
if (!info->ports.mport[0] || !info->ports.rport[0]) {
DEBUGP("trigger_check: Try 'iptbles -j TRIGGER -h' for help.\n");
return -EINVAL;
}
}
return 0;
}
static struct xt_target redirect_reg = {
.name = "TRIGGER",
.family = NFPROTO_IPV4,
.target = trigger_target,
.targetsize = sizeof(struct ipt_trigger_info),
.checkentry = trigger_check,
.me = THIS_MODULE,
};
static int __init init(void)
{
return xt_register_target(&redirect_reg);
}
static void __exit fini(void)
{
xt_unregister_target(&redirect_reg);
}
module_init(init);
module_exit(fini);

View File

@@ -1 +0,0 @@
obj-m +=ip6t_TRIGGER.o

View File

@@ -1,429 +0,0 @@
/* Kernel module to match the port-ranges, trigger related port-ranges,
* and alters the destination to a local IPv6 address.
*
* Copyright (C) 2024, IOPSYS
* All Rights Reserved.
*
* Description:
* This is kernel module for port-triggering.
*
* The module follows the Netfilter framework, called extended packet
* matching modules.
*/
#include <linux/types.h>
#include <linux/tcp.h>
#include <linux/timer.h>
#include <linux/module.h>
#include <linux/netfilter.h>
#include <linux/netdevice.h>
#include <linux/if.h>
#include <linux/inetdevice.h>
#include <linux/list.h>
#include <net/protocol.h>
#include <net/checksum.h>
#include <linux/spinlock.h>
#include <linux/netfilter_ipv6.h>
#include <linux/netfilter_ipv6/ip6_tables.h>
#include <net/netfilter/nf_conntrack.h>
#include <net/netfilter/nf_conntrack_core.h>
#include <net/netfilter/nf_conntrack_tuple.h>
#include <net/netfilter/nf_nat.h>
#include <linux/netfilter_ipv4/ipt_TRIGGER.h>
/* This rwlock protects the main hash table, protocol/helper/expected
* registrations, conntrack timers*/
static DEFINE_SPINLOCK(nf_trigger_lock);
#define NF_IP_PRE_ROUTING 0
#define NF_IP_FORWARD 2
#define IPT_CONTINUE XT_CONTINUE
/***********************lock help**********************/
#define MUST_BE_READ_LOCKED(l)
#define MUST_BE_WRITE_LOCKED(l)
#define LOCK_BH(l) spin_lock_bh(l)
#define UNLOCK_BH(l) spin_unlock_bh(l)
#define ASSERT_READ_LOCK(x) MUST_BE_READ_LOCKED(&nf_trigger_lock)
#define ASSERT_WRITE_LOCK(x) MUST_BE_WRITE_LOCKED(&nf_trigger_lock)
/***********************list help**********************/
#define LIST_FIND(head, cmpfn, type, args...) \
({ \
const struct list_head *__i, *__j = NULL; \
\
ASSERT_READ_LOCK(head); \
list_for_each(__i, (head)) \
if (cmpfn((const type)__i , ## args)) { \
__j = __i; \
break; \
} \
(type)__j; \
})
static inline int
__list_cmp_same(const void *p1, const void *p2) { return p1 == p2; }
static inline void
list_prepend(struct list_head *head, void *new)
{
ASSERT_WRITE_LOCK(head);
list_add(new, head);
}
#define list_named_find(head, name) \
LIST_FIND(head, __list_cmp_name, void *, name)
MODULE_LICENSE("GPL");
MODULE_AUTHOR("IOPSYS Network Team");
MODULE_DESCRIPTION("iptables trigger target module");
#if 0
#define DEBUGP printk
#else
#define DEBUGP(format, args...)
#endif
struct ipt_trigger {
struct list_head list; /* Trigger list */
struct timer_list timeout; /* Timer for list destroying */
struct in6_addr srcip; /* Outgoing source address */
struct in6_addr dstip; /* Outgoing destination address */
u_int16_t mproto; /* Trigger protocol */
u_int16_t rproto; /* Related protocol */
u_int16_t trigger_timeout; /* Auto disable duration */
struct ipt_trigger_ports ports; /* Trigger and related ports */
u_int8_t reply; /* Confirm a reply connection */
};
LIST_HEAD(ipt_trigger_list);
static unsigned char *ipv6_header_get_L4_header_offset(const struct ipv6hdr *ip6h_p)
{
unsigned int ext_head_count = 8;
const struct ipv6_opt_hdr *ip_ext_p;
unsigned int payload_offset = 0;
char *tcpudp_hdr = NULL;
uint8_t nextHdr_p;
nextHdr_p = ip6h_p->nexthdr;
ip_ext_p = (const struct ipv6_opt_hdr *)(ip6h_p + 1);
payload_offset = sizeof(struct ipv6hdr);
do {
if ((nextHdr_p == IPPROTO_TCP) || (nextHdr_p == IPPROTO_UDP)) {
tcpudp_hdr = (unsigned char *)ip6h_p + payload_offset;
break;
}
payload_offset += (ip_ext_p->hdrlen + 1U) << 3U;
nextHdr_p = ip_ext_p->nexthdr;
ip_ext_p = (struct ipv6_opt_hdr *)((uint8_t *)ip6h_p + payload_offset);
ext_head_count--; /* at most 8 extension headers */
} while (ext_head_count);
return tcpudp_hdr;
}
static void trigger_refresh(struct ipt_trigger *trig, unsigned long extra_jiffies)
{
DEBUGP("%s: \n", __FUNCTION__);
LOCK_BH(&nf_trigger_lock);
/* Need del_timer for race avoidance (may already be dying). */
if (del_timer(&trig->timeout)) {
trig->timeout.expires = jiffies + extra_jiffies;
add_timer(&trig->timeout);
}
UNLOCK_BH(&nf_trigger_lock);
}
static void __del_trigger(struct ipt_trigger *trig)
{
DEBUGP("%s: \n", __FUNCTION__);
MUST_BE_WRITE_LOCKED(&nf_trigger_lock);
/* delete from 'ipt_trigger_list' */
list_del(&trig->list);
kfree(trig);
}
static void trigger_timeout(struct timer_list *t)
{
struct ipt_trigger *trig = from_timer(trig, t, timeout);
DEBUGP("trigger list %p timed out\n", trig);
LOCK_BH(&nf_trigger_lock);
__del_trigger(trig);
UNLOCK_BH(&nf_trigger_lock);
}
static unsigned int
add_new_trigger(struct ipt_trigger *trig)
{
struct ipt_trigger *new = NULL;
DEBUGP("!!!!!!!!!!!! %s !!!!!!!!!!!\n", __FUNCTION__);
LOCK_BH(&nf_trigger_lock);
new = (struct ipt_trigger *)
kmalloc(sizeof(struct ipt_trigger), GFP_ATOMIC);
if (!new) {
UNLOCK_BH(&nf_trigger_lock);
DEBUGP("%s: OOM allocating trigger list\n", __FUNCTION__);
return -ENOMEM;
}
memset(new, 0, sizeof(*trig));
INIT_LIST_HEAD(&new->list);
memcpy(new, trig, sizeof(*trig));
/* add to global table of trigger */
list_prepend(&ipt_trigger_list, &new->list);
/* add and start timer if required */
timer_setup(&new->timeout, trigger_timeout, 0);
mod_timer(&new->timeout, jiffies + (trig->trigger_timeout * HZ));
UNLOCK_BH(&nf_trigger_lock);
return 0;
}
/*
* Service-Name OutBound InBound
* 1. TMD UDP:1000 TCP/UDP:2000..2010
* 2. WOKAO UDP:1000 TCP/UDP:3000..3010
* 3. net2phone-1 UDP:6801 TCP:30000..30000
* 4. net2phone-2 UDP:6801 UDP:30000..30000
*
* For supporting to use the same outgoing port to trigger different port rules,
* it should check the inbound protocol and port range value. If all conditions
* are matched, it is a same trigger item, else it needs to create a new one.
*/
static inline int trigger_out_matched(const struct ipt_trigger *i,
const u_int16_t proto, const u_int16_t dport, const struct ipt_trigger_info *info)
{
DEBUGP("%s: i=%p, proto= %d, dport=%d.\n", __FUNCTION__, i, proto, dport);
DEBUGP("%s: Got one, mproto= %d, mport[0..1]=%d, %d, ", __FUNCTION__,
i->mproto, i->ports.mport[0], i->ports.mport[1]);
DEBUGP("rproto= %d, rport[0..1]=%d, %d.\n",
i->rproto, i->ports.rport[0], i->ports.rport[1]);
return ((i->mproto == proto) &&
(i->ports.mport[0] <= dport) &&
(i->ports.mport[1] >= dport) &&
(i->rproto == info->proto) &&
(i->ports.rport[0] == info->ports.rport[0]) &&
(i->ports.rport[1] == info->ports.rport[1]));
}
static unsigned int
trigger_out(struct sk_buff *skb,
unsigned int hooknum,
const void *targinfo)
{
const struct ipt_trigger_info *info = targinfo;
struct ipt_trigger trig, *found;
const struct ipv6hdr *ip6h = ipv6_hdr(skb);
struct tcphdr *tcph = (struct tcphdr*)ipv6_header_get_L4_header_offset(ip6h); /* Might be TCP, UDP */
DEBUGP("############# %s ############\n", __FUNCTION__);
/* Check if the trigger range has already existed in 'ipt_trigger_list'. */
found = LIST_FIND(&ipt_trigger_list, trigger_out_matched,
struct ipt_trigger *, ip6h->nexthdr, ntohs(tcph->dest), info);
if (found) {
/* Yeah, it exists. We need to update(delay) the destroying timer. */
trigger_refresh(found, info->trigger_timeout * HZ);
/* In order to allow multiple hosts use the same port range, we update
the 'saddr' after previous trigger has a reply connection. */
if (found->reply)
found->srcip = ip6h->saddr;
}
else {
/* Create new trigger */
memset(&trig, 0, sizeof(trig));
memcpy(&trig.srcip, &ip6h->saddr, sizeof(trig.srcip));
trig.mproto = ip6h->nexthdr;
trig.rproto = info->proto;
trig.trigger_timeout = info->trigger_timeout;
memcpy(&trig.ports, &info->ports, sizeof(struct ipt_trigger_ports));
add_new_trigger(&trig); /* Add the new 'trig' to list 'ipt_trigger_list'. */
}
return IPT_CONTINUE; /* We don't block any packet. */
}
static inline int trigger_in_matched(const struct ipt_trigger *i,
const u_int16_t proto, const u_int16_t dport)
{
u_int16_t rproto = i->rproto;
DEBUGP("%s: i=%p, proto= %d, dport=%d.\n", __FUNCTION__, i, proto, dport);
DEBUGP("%s: Got one, rproto= %d, rport[0..1]=%d, %d.\n", __FUNCTION__,
i->rproto, i->ports.rport[0], i->ports.rport[1]);
if (!rproto)
rproto = proto;
return ((rproto == proto) && (i->ports.rport[0] <= dport)
&& (i->ports.rport[1] >= dport));
}
static unsigned int
trigger_in(struct sk_buff *skb,
unsigned int hooknum,
const void *targinfo)
{
const struct ipt_trigger_info *info = targinfo;
struct ipt_trigger *found;
const struct ipv6hdr *ip6h = ipv6_hdr(skb);
struct tcphdr *tcph =(struct tcphdr*)ipv6_header_get_L4_header_offset(ip6h); /* Might be TCP, UDP */
/* Check if the trigger-ed range has already existed in 'ipt_trigger_list'. */
found = LIST_FIND(&ipt_trigger_list, trigger_in_matched,
struct ipt_trigger *, ip6h->nexthdr, ntohs(tcph->dest));
if (found) {
DEBUGP("############# %s ############\n", __FUNCTION__);
/* Yeah, it exists. We need to update(delay) the destroying timer. */
trigger_refresh(found, info->trigger_timeout * HZ);
return NF_ACCEPT; /* Accept it, or the imcoming packet could be
dropped in the FORWARD chain */
}
return IPT_CONTINUE; /* Our job is the interception. */
}
static unsigned int
trigger_dnat(struct sk_buff *skb,
unsigned int hooknum,
const void *targinfo)
{
struct ipt_trigger *found = NULL;
const struct ipv6hdr *ip6h = ipv6_hdr(skb);
struct tcphdr *tcph =(struct tcphdr*)ipv6_header_get_L4_header_offset(ip6h); /* Might be TCP, UDP */
struct nf_conn *ct = NULL;
enum ip_conntrack_info ctinfo;
struct nf_nat_range2 newrange;
/* Check if the trigger-ed range has already existed in 'ipt_trigger_list'. */
found = LIST_FIND(&ipt_trigger_list, trigger_in_matched,
struct ipt_trigger *, ip6h->nexthdr, ntohs(tcph->dest));
if (!found)
return IPT_CONTINUE; /* We don't block any packet. */
DEBUGP("############# %s ############\n", __FUNCTION__);
found->reply = 1; /* Confirm there has been a reply connection. */
ct = nf_ct_get(skb, &ctinfo);
DEBUGP("%s: got ", __FUNCTION__);
/* Alter the destination of imcoming packet. */
/* Transfer from original range. */
memset(&newrange.min_addr, 0, sizeof(newrange.min_addr));
memset(&newrange.max_addr, 0, sizeof(newrange.max_addr));
memset(&newrange.min_proto, 0, sizeof(newrange.min_proto));
memset(&newrange.max_proto, 0, sizeof(newrange.max_proto));
newrange.flags = NF_NAT_RANGE_MAP_IPS;
memcpy(&newrange.min_addr.ip, &found->srcip, sizeof(newrange.min_addr.ip));
memcpy(&newrange.max_addr.ip, &found->srcip, sizeof(newrange.max_addr.ip));
DEBUGP("%s: found->srcip = %x\n", __FUNCTION__, found->srcip);
/* Hand modified range to generic setup. */
return nf_nat_setup_info(ct, &newrange, NF_NAT_MANIP_DST);
}
static unsigned int
trigger_target(struct sk_buff *skb,
const struct xt_action_param *par)
{
const struct ipt_trigger_info *info = par->targinfo;
const struct ipv6hdr *ip6h = ipv6_hdr(skb);
unsigned int hooknum = xt_hooknum(par);
DEBUGP("%s: type = %s\n", __FUNCTION__,
(info->type == IPT_TRIGGER_DNAT) ? "dnat" :
(info->type == IPT_TRIGGER_IN) ? "in" : "out");
/* The Port-trigger only supports TCP and UDP. */
if ((ip6h->nexthdr != IPPROTO_TCP) && (ip6h->nexthdr != IPPROTO_UDP))
return IPT_CONTINUE;
if (info->type == IPT_TRIGGER_OUT)
return trigger_out(skb, hooknum, info);
else if (info->type == IPT_TRIGGER_IN)
return trigger_in(skb, hooknum, info);
else if (info->type == IPT_TRIGGER_DNAT)
return trigger_dnat(skb, hooknum, info);
return IPT_CONTINUE;
}
static int
trigger_check(const struct xt_tgchk_param *par)
{
const struct ipt_trigger_info *info = par->targinfo;
if ((strcmp(par->table, "mangle") == 0)) {
DEBUGP("trigger_check: bad table `%s'.\n", par->table);
return -EINVAL;
}
if (par->hook_mask & ~((1 << NF_IP_PRE_ROUTING) | (1 << NF_IP_FORWARD))) {
DEBUGP("trigger_check: bad hooks %x.\n", par->hook_mask);
return -EINVAL;
}
if (info->proto) {
if (info->proto != IPPROTO_TCP && info->proto != IPPROTO_UDP) {
DEBUGP("trigger_check: bad proto %d.\n", info->proto);
return -EINVAL;
}
}
if (info->type == IPT_TRIGGER_OUT) {
if (!info->ports.mport[0] || !info->ports.rport[0]) {
DEBUGP("trigger_check: Try 'iptbles -j TRIGGER -h' for help.\n");
return -EINVAL;
}
}
return 0;
}
static struct xt_target redirect_reg = {
.name = "TRIGGER",
.family = NFPROTO_IPV6,
.target = trigger_target,
.targetsize = sizeof(struct ipt_trigger_info),
.checkentry = trigger_check,
.me = THIS_MODULE,
};
static int __init init(void)
{
return xt_register_target(&redirect_reg);
}
static void __exit fini(void)
{
xt_unregister_target(&redirect_reg);
}
module_init(init);
module_exit(fini);

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libdpp
PKG_VERSION:=2.1.0
PKG_VERSION:=2.1.1
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=1f82436531d4bb094b0b74e99613e0dfc84eada3
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

@@ -5,13 +5,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libdsl
PKG_VERSION:=7.2.99
PKG_VERSION:=7.2.100
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=f9f3fcd0f4140540db5bd41059bcca7ded083024
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/libdsl.git
PKG_SOURCE_VERSION:=20875ec79fcc7c546c2f1253c867d6afbc8bff75
PKG_SOURCE_URL:=https://dev.iopsys.eu/hal/libdsl.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz
PKG_MIRROR_HASH:=skip
endif
@@ -27,6 +27,8 @@ ifeq ($(CONFIG_TARGET_brcmbca),y)
CONFIG_ID=$(SUBTARGET:bcm%=BCM%)
CHIP_ID=$(CONFIG_ID:BCM9%=%)
TARGET_CFLAGS +=-DIOPSYS_BROADCOM -DCHIP_$(CHIP_ID) -DCONFIG_$(CONFIG_ID) \
-I$(STAGING_DIR)/usr/include/bcm963xx/bcmdrivers/broadcom/include/bcm963xx \
-I$(STAGING_DIR)/usr/include/bcm963xx/shared/opensource/include/bcm963xx \
-I$(STAGING_DIR)/usr/include/bcm963xx/bcmdrivers/opensource/include/bcm963xx \
-I$(STAGING_DIR)/usr/include/bcm963xx/userspace/public/include
else ifeq ($(CONFIG_TARGET_x86),y)
@@ -55,12 +57,19 @@ define Package/libdsl
SUBMENU:=IOPSYS HAL libs
MENU:=1
TITLE:= xDSL library (libdsl)
DEPENDS+=TARGET_brcmbca:bcm963xx-bsp
endef
define Package/libdsl/description
Library provides xDSL/GFAST HAL APIs
endef
ifeq ($(LOCAL_DEV),1)
define Build/Prepare
$(CP) -rf ./libdsl/* $(PKG_BUILD_DIR)/
endef
endif
define Package/libdsl/config
if PACKAGE_libdsl
config LIBDSL_DEBUG

View File

@@ -5,12 +5,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libeasy
PKG_VERSION:=7.4.4
PKG_VERSION:=7.4.5
LOCAL_DEV=0
ifneq ($(LOCAL_DEV),1)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=7a9e69c413c2d0b950a1a2e0f2964439fb797f48
PKG_SOURCE_VERSION:=67e6b91b8aca4c068a71f097f5f0576b47ec1d2e
PKG_SOURCE_URL:=https://dev.iopsys.eu/iopsys/libeasy.git
PKG_MAINTAINER:=Anjan Chanda <anjan.chanda@iopsys.eu>
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)_$(PKG_SOURCE_VERSION).tar.xz

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