[OpenWrt-Devel] [PATCH v3 1/1] ramips: mt7621: use higher SPI clock speed on Mikrotik rbm11g and rbm33g

2020-06-03 Thread Tobias Schramm
Previously the dts were using a value determined by empirical testing, because of a spi driver/clock bug. The bug was fixed quite some time ago. 33 MHz is the default clock frequency used by RouterBOOT and thus safe. Signed-off-by: Tobias Schramm --- target/linux/ramips/dts

[OpenWrt-Devel] [PATCH v3 0/1] Increase SPI speed on Mikrotik rbm11g and rbm33g

2020-06-03 Thread Tobias Schramm
also verified that signal integrity is not an issue, the clock edges are still pretty good. v3 is just a rebase on an up-to-date OpenWrt tree due to moved files. Tobias Changelog: v2: - Remove m25p,fast-read from dts v3: - Rebase for renamed dts files Tobias Schramm (1): ramips: mt7621

[OpenWrt-Devel] [PATCH v2 0/1] Increase SPI speed on Mikrotik rbm11g and rbm33g

2020-04-09 Thread Tobias Schramm
also verified that signal integrity is not an issue, the clock edges are still pretty good. v2 removes the m25p,fast-read property from the dts since it is not required until 50 MHz. Tobias Changelog: v2: - Remove m25p,fast-read from dts Tobias Schramm (1): ramips: mt7621: use higher SPI

[OpenWrt-Devel] [PATCH v2 1/1] ramips: mt7621: use higher SPI clock speed on Mikrotik rbm11g and rbm33g

2020-04-09 Thread Tobias Schramm
Previously the dts were using a value determined by empirical testing, because of a spi driver/clock bug. The bug was fixed quite some time ago. 33 MHz is the default clock frequency used by RouterBOOT and thus safe. Signed-off-by: Tobias Schramm --- target/linux/ramips/dts

Re: [OpenWrt-Devel] [PATCH 1/1] ramips: mt7621: use higher SPI clock speed on Mikrotik rbm11g and rbm33g

2020-04-09 Thread Tobias Schramm
Hi, >> @@ -83,8 +83,8 @@ >> w25q128@0 { >> compatible = "jedec,spi-nor"; >> reg = <0>; >> - // XXX empiric value to obtain actual 10MHz SCK at the chip >> - spi-max-frequency = <3125000>; >> + m25p,fast-read; >> +

[OpenWrt-Devel] [PATCH 0/1] Increase SPI speed on Mikrotik rbm11g and rbm33g

2020-04-08 Thread Tobias Schramm
also verified that signal integrity is not an issue, the clock edges are still pretty good. Tobias Tobias Schramm (1): ramips: mt7621: use higher SPI clock speed on Mikrotik rbm11g and rbm33g target/linux/ramips/dts/mt7621_mikrotik_rbm11g.dts | 4 ++-- target/linux/ramips/dts

[OpenWrt-Devel] [PATCH 1/1] ramips: mt7621: use higher SPI clock speed on Mikrotik rbm11g and rbm33g

2020-04-08 Thread Tobias Schramm
Previously the dts were using a value determined by empirical testing, because of a spi driver/clock bug. The bug was fixed quite some time ago. 33 MHz is the default clock frequency used by RouterBOOT and thus safe. Signed-off-by: Tobias Schramm --- target/linux/ramips/dts

Re: [OpenWrt-Devel] [PATCH 1/3] ramips: mt7621: add LAN port mac address to rbm11g dts

2020-04-08 Thread Tobias Schramm
port@0 { status = "okay"; label = "lan"; + mtd-mac-address = <_config 0x0010>; + mtd-mac-address-increment = <2>; >>> >>> That doesn't make sense to me. >>> >>> gmac0 is configured to 0x10

Re: [OpenWrt-Devel] [PATCH 1/3] ramips: mt7621: add LAN port mac address to rbm11g dts

2020-04-08 Thread Tobias Schramm
Hi Adrian, >> port@0 { >> status = "okay"; >> label = "lan"; >> +mtd-mac-address = <_config 0x0010>; >> +mtd-mac-address-increment = <2>; > > That doesn't make sense to me. > > gmac0 is configured to

[OpenWrt-Devel] [PATCH 1/3] ramips: mt7621: add LAN port mac address to rbm11g dts

2020-04-08 Thread Tobias Schramm
This commit adds a mac address from the hard_config partition to LAN port of rbm11g. Signed-off-by: Tobias Schramm --- target/linux/ramips/dts/mt7621_mikrotik_rbm11g.dts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/target/linux/ramips/dts/mt7621_mikrotik_rbm11g.dts b/target/linux

[OpenWrt-Devel] [PATCH 3/3] ramips: mt7621: reenable rbm11g

2020-04-08 Thread Tobias Schramm
I have a rbm11g and can confirm that the LAN port is indeed switch port 0. Signed-off-by: Tobias Schramm --- target/linux/ramips/dts/mt7621_mikrotik_rbm11g.dts | 1 - target/linux/ramips/image/mt7621.mk| 1 - 2 files changed, 2 deletions(-) diff --git a/target/linux/ramips/dts

[OpenWrt-Devel] [PATCH 0/3] Clean up and reenable Mikrotik rbm11g

2020-04-08 Thread Tobias Schramm
e LAN port. Additionally the first two patches remove some differences between the rbm33g and rbm11g. Feel free to apply partially if you don't agree with one or both of the first two patches. Tobias Tobias Schramm (3): ramips: mt7621: add LAN port mac address to rbm11g dts ramips: mt7621: add

[OpenWrt-Devel] [PATCH 2/3] ramips: mt7621: add label mac address to rbm11g

2020-04-08 Thread Tobias Schramm
The rbm11g has a label with printed on mac address similar to the rbm33g. Signed-off-by: Tobias Schramm --- target/linux/ramips/mt7621/base-files/etc/board.d/02_network | 1 + 1 file changed, 1 insertion(+) diff --git a/target/linux/ramips/mt7621/base-files/etc/board.d/02_network b/target

Re: [OpenWrt-Devel] [PATCH v3 3/3] Add _safe variants for all attribute checking methods

2018-11-28 Thread Tobias Schramm
Hi, good catch. I've sent a v4 that addresses this issue. Regards Tobias ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel

[OpenWrt-Devel] [PATCH v4 0/3] libubox: Enhance robustness of blobmsg parsing

2018-11-28 Thread Tobias Schramm
, Tobias Schramm Changelog: v2: - Add documentation to attribute checking methods in blobmsg.h v3: - Inline attribute checking methods - Fix orthography v4: - Replace inappropriate use of 'NULL' with 'false' Tobias Schramm (3): Ensure blob_attr length check does not perform out of bounds reads

[OpenWrt-Devel] [PATCH v4 2/3] Replace use of blobmsg_check_attr by blobmsg_check_attr_safe

2018-11-28 Thread Tobias Schramm
blobmsg_check_attr_safe adds a length limit specifying the max offset from attr that can be read safely Signed-off-by: Tobias Schramm --- blobmsg.c | 24 ++-- blobmsg.h | 24 +++- 2 files changed, 41 insertions(+), 7 deletions(-) diff --git a/blobmsg.c

[OpenWrt-Devel] [PATCH v4 3/3] Add _safe variants for all attribute checking methods

2018-11-28 Thread Tobias Schramm
Signed-off-by: Tobias Schramm --- blobmsg.c | 12 ++-- blobmsg.h | 49 - 2 files changed, 58 insertions(+), 3 deletions(-) diff --git a/blobmsg.c b/blobmsg.c index 10f3801..13c83bc 100644 --- a/blobmsg.c +++ b/blobmsg.c @@ -75,13 +75,16

[OpenWrt-Devel] [PATCH v4 1/3] Ensure blob_attr length check does not perform out of bounds reads

2018-11-28 Thread Tobias Schramm
Before there might have been as little as one single byte left which would result in 3 bytes of blob_attr->id_len being out of bounds Signed-off-by: Tobias Schramm --- blob.h| 4 ++-- blobmsg.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blob.h b/blob.h in

Re: [OpenWrt-Devel] [PATCH v2 3/3] Add _safe variants for all attribute checking methods

2018-11-27 Thread Tobias Schramm
Hi, thanks for the feedback. I've sent a v3 that should implement all improvements you have pointed out. Regards, Tobias ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel

[OpenWrt-Devel] [PATCH v3 3/3] Add _safe variants for all attribute checking methods

2018-11-27 Thread Tobias Schramm
Signed-off-by: Tobias Schramm --- blobmsg.c | 12 ++-- blobmsg.h | 49 - 2 files changed, 58 insertions(+), 3 deletions(-) diff --git a/blobmsg.c b/blobmsg.c index 10f3801..4b142e9 100644 --- a/blobmsg.c +++ b/blobmsg.c @@ -75,13 +75,16

[OpenWrt-Devel] [PATCH v3 2/3] Replace use of blobmsg_check_attr by blobmsg_check_attr_safe

2018-11-27 Thread Tobias Schramm
blobmsg_check_attr_safe adds a length limit specifying the max offset from attr that can be read safely Signed-off-by: Tobias Schramm --- blobmsg.c | 24 ++-- blobmsg.h | 24 +++- 2 files changed, 41 insertions(+), 7 deletions(-) diff --git a/blobmsg.c

[OpenWrt-Devel] [PATCH v3 1/3] Ensure blob_attr length check does not perform out of bounds reads

2018-11-27 Thread Tobias Schramm
Before there might have been as little as one single byte left which would result in 3 bytes of blob_attr->id_len being out of bounds Signed-off-by: Tobias Schramm --- blob.h| 4 ++-- blobmsg.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blob.h b/blob.h in

[OpenWrt-Devel] [PATCH v3 0/3] libubox: Enhance robustness of blobmsg parsing

2018-11-27 Thread Tobias Schramm
, Tobias Schramm Changelog: v2: - Add documentation to attribute checking methods in blobmsg.h v3: - Inline attribute checking methods - Fix orthography Tobias Schramm (3): Ensure blob_attr length check does not perform out of bounds reads Replace use of blobmsg_check_attr

Re: [OpenWrt-Devel] [PATCH 2/3] Replace use of blobmsg_check_attr by blobmsg_check_attr_safe

2018-11-22 Thread Tobias Schramm
Hey, sorry for top posting. Using the Gmail App for Mailinglist posts might not be the best of ideas. In my code I'm trying to set a precedent for how the attribute checking methods should be used. My gerneral idea was to code that part defensively. Thus I call the _safe variants in my code. You

[OpenWrt-Devel] [PATCH v2 3/3] Add _safe variants for all attribute checking methods

2018-11-22 Thread Tobias Schramm
Signed-off-by: Tobias Schramm --- blobmsg.c | 15 --- blobmsg.h | 40 2 files changed, 52 insertions(+), 3 deletions(-) diff --git a/blobmsg.c b/blobmsg.c index dd4b506..97a9a0b 100644 --- a/blobmsg.c +++ b/blobmsg.c @@ -81,10 +81,14 @@ bool

[OpenWrt-Devel] [PATCH v2 2/3] Replace use of blobmsg_check_attr by blobmsg_check_attr_safe

2018-11-22 Thread Tobias Schramm
blobmsg_check_attr_safe adds a length limit specifying the max offset from attr that can be read safely Signed-off-by: Tobias Schramm --- blobmsg.c | 27 ++- blobmsg.h | 18 ++ 2 files changed, 40 insertions(+), 5 deletions(-) diff --git a/blobmsg.c b

[OpenWrt-Devel] [PATCH v2 1/3] Ensure blob_attr length check does not perform out of bounds reads

2018-11-22 Thread Tobias Schramm
Before there might have been as little as one single byte left which would result in 3 bytes of blob_attr->id_len being out of bounds Signed-off-by: Tobias Schramm --- blob.h| 4 ++-- blobmsg.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blob.h b/blob.h in

[OpenWrt-Devel] [PATCH v2 0/3] libubox: Enhance robustness of blobmsg parsing

2018-11-22 Thread Tobias Schramm
, Tobias Schramm Changelog: v2: - Add documentation to attribute checking methods in blobmsg.h Tobias Schramm (3): Ensure blob_attr length check does not perform out of bounds reads Replace use of blobmsg_check_attr by blobmsg_check_attr_safe Add _safe variants for all attribute checking methods

Re: [OpenWrt-Devel] [PATCH 0/3] libubox: Enhance robustness of blobmsg parsing

2018-11-22 Thread Tobias Schramm
True. I'll send a V2 with some documentation added. Am Fr., 23. Nov. 2018 um 05:11 Uhr schrieb Yousong Zhou : > > On Thu, 22 Nov 2018 at 10:00, Tobias Schramm wrote: > > > > Hi, > > > > this patch set makes parsing of blobmsg messages more robust against > >

Re: [OpenWrt-Devel] [PATCH 2/3] Replace use of blobmsg_check_attr by blobmsg_check_attr_safe

2018-11-22 Thread Tobias Schramm
at the implementation of __blob_for_each_attr and understand it first. Also I don't see any downsides to calling blobmsg_check_attr_safe over blobmsg_check_attr. Am Fr., 23. Nov. 2018 um 05:06 Uhr schrieb Yousong Zhou : > > On Thu, 22 Nov 2018 at 10:01, Tobias Schramm

Re: [OpenWrt-Devel] [PATCH 1/3] Ensure blob_attr length check does not perform out of bounds reads

2018-11-22 Thread Tobias Schramm
Hi, thanks for the feedback. While blob_pad_len does cover the size of struct blob_attr it will always read attr->id_len which might be out of bounds already. Thus we need to check that rem >= sizeof(struct blob_attr) before. Tobias ___ openwrt-devel

[OpenWrt-Devel] [PATCH 2/3] Replace use of blobmsg_check_attr by blobmsg_check_attr_safe

2018-11-21 Thread Tobias Schramm
blobmsg_check_attr_safe adds a length limit specifying the max offset from attr that can be read safely Signed-off-by: Tobias Schramm --- blobmsg.c | 27 ++- blobmsg.h | 2 ++ 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/blobmsg.c b/blobmsg.c index

[OpenWrt-Devel] [PATCH 1/3] Ensure blob_attr length check does not perform out of bounds reads

2018-11-21 Thread Tobias Schramm
Before there might have been as little as one single byte left which would result int 3 bytes of blob_attr->id_len being out of bounds Signed-off-by: Tobias Schramm --- blob.h| 4 ++-- blobmsg.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blob.h b/blob.h in

[OpenWrt-Devel] [PATCH 3/3] Add _safe variants for all attribute checking methods

2018-11-21 Thread Tobias Schramm
Signed-off-by: Tobias Schramm --- blobmsg.c | 15 --- blobmsg.h | 12 ++-- 2 files changed, 22 insertions(+), 5 deletions(-) diff --git a/blobmsg.c b/blobmsg.c index dd4b506..97a9a0b 100644 --- a/blobmsg.c +++ b/blobmsg.c @@ -81,10 +81,14 @@ bool blobmsg_check_attr_safe

[OpenWrt-Devel] [PATCH 0/3] libubox: Enhance robustness of blobmsg parsing

2018-11-21 Thread Tobias Schramm
, Tobias Schramm Tobias Schramm (3): Ensure blob_attr length check does not perform out of bounds reads Replace use of blobmsg_check_attr by blobmsg_check_attr_safe Add _safe variants for all attribute checking methods blob.h| 4 ++-- blobmsg.c | 42

[OpenWrt-Devel] [PATCH 1/1] uclient: update to latest git HEAD

2018-08-03 Thread Tobias Schramm
: Close ustream file handle only if allocated Signed-off-by: Tobias Schramm --- package/libs/uclient/Makefile | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/package/libs/uclient/Makefile b/package/libs/uclient/Makefile index 3eefa2e012..888fce3e2a 100644 --- a/package

[OpenWrt-Devel] [PATCH 0/1] uclient: update uclient to latest git HEAD

2018-08-03 Thread Tobias Schramm
patching for LEDE, please let me know if it isn't. Cheers, Tobias Tobias Schramm (1): uclient: update to latest git HEAD package/libs/uclient/Makefile | 8 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.18.0 ___ openwrt-devel mailing

[OpenWrt-Devel] [PATCH 1/1] uclient-http: Close ustream file handle only if allocated

2018-08-03 Thread Tobias Schramm
Since the connection setup in uclient_do_connect can fail before ustream_init_fd is called we must check the fd was actually allocated before closing it, else we would close STDIN. Signed-off-by: Tobias Schramm --- uclient-http.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff

[OpenWrt-Devel] [PATCH 0/1] uclient-http: Close ustream file handle only if allocated

2018-08-03 Thread Tobias Schramm
Hi, this patch fixes a bug in uclient that caused it to close STDIN if the connection setup failed very early on. Together with a small oversight in busybox this lead to quite an interesting bug in Freifunk Gluon: https://github.com/freifunk-gluon/gluon/issues/1496 Cheers, Tobias Tobias

[OpenWrt-Devel] mt7621: Full duplex spi data corruption

2018-05-02 Thread Tobias Schramm
Hi, I'm currently working on bringing OpenWRT support to the RouterBOARD RBM33G [1]. The device is based on the mt7621 SoC and has two spi nor-flash chips. The first chip is very small (512 kB) and connected to CS0. The second chip is a lot larger (16 MB) and connected to CS1. The mt7621-spi

[OpenWrt-Devel] [PATCH v3 6/7] uclient-utils: Handle memory allocation failure for url file name

2018-02-20 Thread Tobias Schramm
Add null pointer check to allocation of url filename Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/uclient-utils.c b/uclient-utils.c index a375eea..3eaf2d5 100644 --- a/uclient-utils.c +++ b/u

[OpenWrt-Devel] [PATCH v3 4/7] uclient-http: Implement error handling for header-sending

2018-02-20 Thread Tobias Schramm
Add some error handling for errors during assembly of headers Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 35 +++ 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/uclient-http.c b/uclient-http.c index 20b8a9a..1

[OpenWrt-Devel] [PATCH v3 0/7] uclient: Handle memory allocation failures

2018-02-20 Thread Tobias Schramm
of auth header functions Fix wrong goto in open_output_file Fix wrong patch subject Tobias Schramm (7): uclient-fetch: Check for nullpointer returned by uclient_get_url_filename uclient-http: basic auth: Handle memory allocation failure uclient-http: auth digest: Handle multiple possible

Re: [OpenWrt-Devel] [PATCH 5/6] uclient-utils: Handle memory allocation failure for url file name

2018-02-18 Thread Tobias Schramm
Yep Philip, you are right. That's a much nicer solution. I'll wait for some more feedback and do just that in v3. 2018-02-18 19:35 GMT+01:00 Philip Prindeville <monster_phi...@redfish-solutions.com>: > > >> On Feb 17, 2018, at 8:36 PM, Tobias Schramm <toblemi...@gmail.com>

[OpenWrt-Devel] [PATCH v2 7/7] uclient: Handle memory allocation failure for url

2018-02-18 Thread Tobias Schramm
Check ptr to url after allocation to prevent null pointer dereference Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/uclient.c b/uclient.c index 8862b55..1137168 100644 --- a/uclient.c +++ b/uclient.c @@ -59,6

[OpenWrt-Devel] [PATCH v2 6/7] uclient-utils: Handle memory allocation failure for url file name

2018-02-18 Thread Tobias Schramm
Add null pointer check to allocation of url filename Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-utils.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/uclient-utils.c b/uclient-utils.c index a375eea..9c4dd42 100644 --- a/uclient-utils.c

[OpenWrt-Devel] [PATCH v2 5/7] uclient-http: Handle memory allocation failure

2018-02-18 Thread Tobias Schramm
Add null pointer check to allocation of uclient_http struct Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/uclient-http.c b/uclient-http.c index 04f16a3..b6607f1 100644 --- a/uclient-http.c +++ b/uclient-

[OpenWrt-Devel] [PATCH v2 3/7] uclient-http: auth digest: Handle multiple possible memory allocation failures

2018-02-18 Thread Tobias Schramm
Add null pointer checks to allocation of buffers for authentication parameters Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 43 ++- 1 file changed, 34 insertions(+), 9 deletions(-) diff --git a/uclient-http.c b/uclient-

[OpenWrt-Devel] [PATCH v2 4/7] uclient-http: Implement error handling for header-sending

2018-02-18 Thread Tobias Schramm
Add some error handling for errors during assembly of headers Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 32 1 file changed, 20 insertions(+), 12 deletions(-) diff --git a/uclient-http.c b/uclient-http.c index 20b8a9a..0

[OpenWrt-Devel] [PATCH v2 2/7] uclient-http: basic auth: Handle memory allocation failure

2018-02-18 Thread Tobias Schramm
Allocation of the base64 buffer might fail, resulting in a null ptr being passed to base64_encode as a target buffer Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/uclient-http.c b/u

[OpenWrt-Devel] [PATCH v2 1/7] uclient-fetch: Check for nullpointer returned by uclient_get_url_filename

2018-02-18 Thread Tobias Schramm
uclient_get_url_filename may return a null ptr resulting in a null ptr dereference by fprintf and open Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-fetch.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/uclient-fetch.c b/uclient-fetch.c index 6961d94..3

[OpenWrt-Devel] [PATCH v2 0/7] uclient: Handle memory allocation failures

2018-02-18 Thread Tobias Schramm
Hi John, I've implemented the suggested improvements and performed some more reformatting to match the codestyle of uclient more closely. Regards Tobias Schramm Changes since v1: Fix codestyle Fix memory leak in uclient_http_add_auth_digest Honour return value of auth header functions Fix

[OpenWrt-Devel] [PATCH 6/6] uclient: Handle memory allocation failure for url

2018-02-17 Thread Tobias Schramm
Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/uclient.c b/uclient.c index 8862b55..dfbe26c 100644 --- a/uclient.c +++ b/uclient.c @@ -59,6 +59,9 @@ __uclient_get_url(const struct uclient_backend *b

[OpenWrt-Devel] [PATCH 5/6] uclient-utils: Handle memory allocation failure for url file name

2018-02-17 Thread Tobias Schramm
Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-utils.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/uclient-utils.c b/uclient-utils.c index a375eea..ee0f8e8 100644 --- a/uclient-utils.c +++ b/uclient-utils.c @@ -177,8 +177,12 @

[OpenWrt-Devel] [PATCH 4/6] uclient-http: Handle memory allocation failure

2018-02-17 Thread Tobias Schramm
Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/uclient-http.c b/uclient-http.c index 2a3cf5d..24f091e 100644 --- a/uclient-http.c +++ b/uclient-http.c @@ -944,6 +944,9 @@ static struct uclient *uclient_http_allo

[OpenWrt-Devel] [PATCH 0/6] uclient: Handle memory allocation failures

2018-02-17 Thread Tobias Schramm
Hi, this series of patches adds some code to handle memory allocation failures without crashing. Previously a lot of memory allocations were not checked for NULL ptrs resulting in nullpointer dereferences if (lib)uclient ran out of memory Regards Tobias Schramm Tobias Schramm (6): uclient

[OpenWrt-Devel] [PATCH 3/6] uclient-http: auth digest: Handle multiple possible memory allocation failures

2018-02-17 Thread Tobias Schramm
Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 41 - 1 file changed, 32 insertions(+), 9 deletions(-) diff --git a/uclient-http.c b/uclient-http.c index 36e051b..2a3cf5d 100644 --- a/uclient-http.c +++ b/uclient-http.c @@

[OpenWrt-Devel] [PATCH 1/6] uclient-fetch: Check for nullpointer returned by open_output_file

2018-02-17 Thread Tobias Schramm
Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-fetch.c | 5 + 1 file changed, 5 insertions(+) diff --git a/uclient-fetch.c b/uclient-fetch.c index 6961d94..46f9b3d 100644 --- a/uclient-fetch.c +++ b/uclient-fetch.c @@ -122,6 +122,11 @@ static int open_output_file(cons

[OpenWrt-Devel] [PATCH 2/6] uclient-http: basic auth: Handle memory allocation failure

2018-02-17 Thread Tobias Schramm
Signed-off-by: Tobias Schramm <toblemi...@gmail.com> --- uclient-http.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/uclient-http.c b/uclient-http.c index ef8de98..36e051b 100644 --- a/uclient-http.c +++ b/uclient-http.c @@ -299,7 +299,7 @@ stati

[OpenWrt-Devel] Reviewers for Ubiquiti Nanostation AC loco support

2018-02-02 Thread Tobias Schramm
Hi, I've recently added support for the Ubiquiti NanoStation AC loco to OpenWRT (https://github.com/openwrt/openwrt/pull/689). If any of the devs here have a NanoStation AC loco or can get their hands on one easily I'd greatly appreciate reviews to get support for this device merged in OpenWRT.