Re: Monocultures are bad [Was: Re: [PATCH] build: Extract trusted-firmware-a.mk]

2020-10-12 Thread Andre Heider
On 12/10/2020 22:16, Hauke Mehrtens wrote: On 10/12/20 8:45 PM, Tomasz Maciej Nowak wrote: Hi. W dniu 12.10.2020 o 16:32, Andre Heider pisze: On 12/10/2020 12:21, Petr Štetiar wrote: Hauke Mehrtens [2020-10-11 20:41:21]: Hi,    (I've expressed this already in my initial review[1] which

Re: Monocultures are bad [Was: Re: [PATCH] build: Extract trusted-firmware-a.mk]

2020-10-12 Thread Andre Heider
On 12/10/2020 20:45, Tomasz Maciej Nowak wrote: Hi. W dniu 12.10.2020 o 16:32, Andre Heider pisze: On 12/10/2020 12:21, Petr Štetiar wrote: Hauke Mehrtens [2020-10-11 20:41:21]: Hi,   (I've expressed this already in my initial review[1] which was not addressed    and pushed anyway.)

Re: Monocultures are bad [Was: Re: [PATCH] build: Extract trusted-firmware-a.mk]

2020-10-12 Thread Hauke Mehrtens
On 10/12/20 8:45 PM, Tomasz Maciej Nowak wrote: Hi. W dniu 12.10.2020 o 16:32, Andre Heider pisze: On 12/10/2020 12:21, Petr Štetiar wrote: Hauke Mehrtens [2020-10-11 20:41:21]: Hi,   (I've expressed this already in my initial review[1] which was not addressed    and pushed anyway.)

Re: Monocultures are bad [Was: Re: [PATCH] build: Extract trusted-firmware-a.mk]

2020-10-12 Thread Tomasz Maciej Nowak
Hi. W dniu 12.10.2020 o 16:32, Andre Heider pisze: > On 12/10/2020 12:21, Petr Štetiar wrote: >> Hauke Mehrtens [2020-10-11 20:41:21]: >> >> Hi, >> >>   (I've expressed this already in my initial review[1] which was not >> addressed >>    and pushed anyway.) >> >>> +TFA_MAKE_FLAGS += \ >>> +

[PATCH mdnsd] cache: cache_record_find: fix buffer overflow

2020-10-12 Thread Petr Štetiar
Fixes following buffer overflow: ERROR: AddressSanitizer: global-buffer-overflow on address 0x007338b8 at pc 0x004db339 bp 0x7ffe370e6140 sp 0x7ffe370e6138 READ of size 8 at 0x007338b8 thread T0 #0 0x4db338 in cache_record_find mdnsd/cache.c:197:17 #1 0x4d74b4 in

Re: Monocultures are bad [Was: Re: [PATCH] build: Extract trusted-firmware-a.mk]

2020-10-12 Thread Andre Heider
On 12/10/2020 12:21, Petr Štetiar wrote: Hauke Mehrtens [2020-10-11 20:41:21]: Hi, (I've expressed this already in my initial review[1] which was not addressed and pushed anyway.) +TFA_MAKE_FLAGS += \ +

Re: hostapd: add additional network section to wpa_supplicant

2020-10-12 Thread Daniel Golle
On Mon, Oct 12, 2020 at 03:22:27PM +0200, Florian Eckert wrote: > Hello Community, > > I have a openwrt system in mobile use. > That means I have a hostapd running as an access point for clients and at > the same time a wpa_supplicant running to another access point as uplink. > So the router is

hostapd: add additional network section to wpa_supplicant

2020-10-12 Thread Florian Eckert
Hello Community, I have a openwrt system in mobile use. That means I have a hostapd running as an access point for clients and at the same time a wpa_supplicant running to another access point as uplink. So the router is client and access point at the same time on one radio. My problem is

[PATCH cgi-io 00/12] fixes and improvements

2020-10-12 Thread Petr Štetiar
Hi, this patch series adds the basic building blocks of automatic CI unit testing, fuzzing and fixing all discovered issues. Cheers, Petr Petr Štetiar (12): Fix warnings reported by clang-10 static analyzer Fix possible NULL dereference Fix clang compiler errors Refactor utility

[PATCH cgi-io 05/12] Add fuzzing of multipart_parser

2020-10-12 Thread Petr Štetiar
LibFuzzer is in-process, coverage-guided, evolutionary fuzzing engine. LibFuzzer is linked with the library under test, and feeds fuzzed inputs to the library via a specific fuzzing entrypoint (aka "target function"); the fuzzer then tracks which areas of the code are reached, and generates

[PATCH cgi-io 04/12] Refactor utility functions into static library

2020-10-12 Thread Petr Štetiar
For reusability during testing. Signed-off-by: Petr Štetiar --- CMakeLists.txt | 7 +- main.c | 270 +-- util.c | 276 + util.h | 11 ++ 4 files changed, 293 insertions(+), 271

[PATCH cgi-io 02/12] Fix possible NULL dereference

2020-10-12 Thread Petr Štetiar
Fixes following issue as reported by GCC-10 static analyzer: multipart_parser.c: In function ‘multipart_parser_init’: multipart_parser.c:88:22: error: dereference of possibly-NULL ‘p’ [CWE-690] [-Werror=analyzer-possible-null-dereference] 88 | p->boundary_length = strlen(boundary);

[PATCH cgi-io 01/12] Fix warnings reported by clang-10 static analyzer

2020-10-12 Thread Petr Štetiar
Fixes following warnings: testing/include/libubox/blobmsg.h:222:67: warning: Null pointer passed to 1st parameter expecting 'nonnull' return blobmsg_add_field(buf, BLOBMSG_TYPE_STRING, name, string, strlen(string) + 1);

[PATCH cgi-io 08/12] Add .gitignore

2020-10-12 Thread Petr Štetiar
And ignore the `build` dir used by CMake. Signed-off-by: Petr Štetiar --- .gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index ..567609b1234a --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@

[PATCH cgi-io 11/12] tests: add cgi-io built with clang sanitizers

2020-10-12 Thread Petr Štetiar
Will be used later for testing. Signed-off-by: Petr Štetiar --- CMakeLists.txt | 15 ++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index ae37f1f68cfa..acf68086a801 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,7 +19,8 @@

[PATCH cgi-io 12/12] tests: add cram based unit tests

2020-10-12 Thread Petr Štetiar
For the start with cgi-exec testing. Signed-off-by: Petr Štetiar --- tests/CMakeLists.txt | 2 ++ tests/cram/CMakeLists.txt | 25 ++ tests/cram/test-cases/cgi-exec-01.txt | 1 + tests/cram/test-cases/cgi-exec-02.txt | 1 +

[PATCH cgi-io 09/12] Add initial GitLab CI support

2020-10-12 Thread Petr Štetiar
Uses currently proof-of-concept openwrt-ci[1] in order to: * improve the quality of the codebase in various areas * decrease code review time and help merging contributions faster * get automagic feedback loop on various platforms and tools - out of tree build with OpenWrt SDK on following

[PATCH cgi-io 10/12] Disable session ACLs during unit testing

2020-10-12 Thread Petr Štetiar
Otherwise we would need to setup ubus infrastructure etc. Signed-off-by: Petr Štetiar --- CMakeLists.txt | 1 + main.c | 12 +--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b60d08e96e3c..ae37f1f68cfa 100644 ---

[PATCH cgi-io 07/12] Fix off-by-one in postdecode_fields

2020-10-12 Thread Petr Štetiar
Fixes following error found by fuzzer: ERROR: AddressSanitizer: SEGV on unknown address 0x60c00012 (pc 0x0054f64f bp 0x0008 sp 0x7ffe4fc2c120 T0) The signal is caused by a READ memory access. #0 0x54f64f in postdecode_fields cgi-io/util.c:93:7 #1 0x54f382 in

[PATCH cgi-io 06/12] Add fuzzing of utility functions

2020-10-12 Thread Petr Štetiar
Thus increase fuzzing coverage. Signed-off-by: Petr Štetiar --- tests/CMakeLists.txt | 1 + tests/fuzz/CMakeLists.txt | 18 .../58668e7669fd564d99db5d581fcdb6a5618440b5 | 1 + .../5ba93c9db0cff93f52b521d7420e43f6eda2784f | Bin 0 -> 1

[PATCH cgi-io 03/12] Fix clang compiler errors

2020-10-12 Thread Petr Štetiar
Fixes following errors as reported by clang compilers: cgi-io/src/main.c:723:12: error: unused variable 'post' [-Werror,-Wunused-variable] autochar *post = postdecode(fields, 4); ^ cgi-io/src/main.c:814:12: error: unused variable 'post' [-Werror,-Wunused-variable]

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Bas Mevissen
On 2020-10-12 12:46, Daniel Golle wrote: On Mon, Oct 12, 2020 at 11:59:17AM +0200, Bas Mevissen wrote: On 2020-10-12 11:40, Bjørn Mork wrote: > Bas Mevissen writes: > > > Nice work, but does it make sense to add a device that is already > > EOL'ed by the manufacturer? I guess the installed

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Daniel Golle
On Mon, Oct 12, 2020 at 11:59:17AM +0200, Bas Mevissen wrote: > On 2020-10-12 11:40, Bjørn Mork wrote: > > Bas Mevissen writes: > > > > > Nice work, but does it make sense to add a device that is already > > > EOL'ed by the manufacturer? I guess the installed base is also rather > > > small. > >

Monocultures are bad [Was: Re: [PATCH] build: Extract trusted-firmware-a.mk]

2020-10-12 Thread Petr Štetiar
Hauke Mehrtens [2020-10-11 20:41:21]: Hi, (I've expressed this already in my initial review[1] which was not addressed and pushed anyway.) > +TFA_MAKE_FLAGS += \ > + > CROSS_CM3=$(STAGING_DIR_IMAGE)/$(LINARO_NAME)-$(LINARO_RELEASE).$(LINARO_VERSION)/bin/arm-linux-gnueabi- > \

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Bjørn Mork
Bas Mevissen writes: >> In addition, >> - each supported device serves as a template and example for >>similar devices, simplifying support for other products. > > It is not really an unique product. It looks like it was (just) > created to be a showcase at CES2016. This argument works

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Bas Mevissen
On 2020-10-12 11:40, Bjørn Mork wrote: Bas Mevissen writes: Nice work, but does it make sense to add a device that is already EOL'ed by the manufacturer? I guess the installed base is also rather small. Definitely! IMHO, it should me enough that there is one user with enough interest to

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Bjørn Mork
Bas Mevissen writes: > Nice work, but does it make sense to add a device that is already > EOL'ed by the manufacturer? I guess the installed base is also rather > small. Definitely! IMHO, it should me enough that there is one user with enough interest to actually do the work, submit it and -

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Bas Mevissen
On 2020-10-12 01:09, Paul Fertser wrote: From: Gary Cooper Device hardware: https://deviwiki.com/wiki/TP-LINK_AD7200_(Talon) The Talon AD7200 is basically an Archer C2600 with larger flash, a third PCIe lane and an 802.11ad radio. It comes in a different housing reminiscent of the Archers

Re: A proposal of https certificate assignment system for luci

2020-10-12 Thread Bas Mevissen
On 2020-10-11 00:58, Michael Richardson wrote: Bas Mevissen wrote: > A security conscious user/administrator would install a router without any > untrusted computers connected to the LAN side and setup the device properly > before allowing others to connect. The WAN side

hotplug.d script to unload ssh key/cert to usb device, and/or initialize password from usb

2020-10-12 Thread abnoeh
it was originally part of Re: A proposal of https certificate assignment system for luci thread but this derailed too much from there. Nice idea to be able to auto-load the config including key material. Might be very useful for larger installs. Nice idea to save SSH server keys as well. That

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Robert Marko
On Mon, 12 Oct 2020 at 10:08, Paul Fertser wrote: > > Hey Robert, > > On Mon, Oct 12, 2020 at 09:52:07AM +0200, Robert Marko wrote: > > Paul, where did you get the 802.11ad support code for OpenWrt? > > I just forwarded Gary's commit to the mailing list as somehow the > subscription confirmation

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Paul Fertser
Hey Robert, On Mon, Oct 12, 2020 at 09:52:07AM +0200, Robert Marko wrote: > Paul, where did you get the 802.11ad support code for OpenWrt? I just forwarded Gary's commit to the mailing list as somehow the subscription confirmation mail doesn't get through to him. That said, the commit doesn't

Re: ipq806x: add support for TP-Link Talon AD7200

2020-10-12 Thread Robert Marko
On Mon, 12 Oct 2020 at 01:21, Ansuel Smith wrote: > > > > > From: Gary Cooper > > > > Device hardware: https://deviwiki.com/wiki/TP-LINK_AD7200_(Talon) > > > > The Talon AD7200 is basically an Archer C2600 with larger flash, a third > > PCIe lane and an 802.11ad radio. It comes in a different