Re: [LEDE-DEV] [PATCH 1/2] firmware-utils: mkdapimg2: Fix potential buffer overflow

2018-04-24 Thread Hauke Mehrtens
On 04/23/2018 01:22 AM, Rosen Penev wrote: > If GCC is built with stack smashing protection enabled (SSP), it errors when > compiling lzma-loader. > > Switching to strncpy seems to be an easy way to fix this. It's probably > better to use snprintf or strlcpy but the latter is not available for g

Re: [LEDE-DEV] [PATCH 1/2] firmware-utils: mkdapimg2: Fix potential buffer overflow

2018-04-23 Thread Arjen de Korte
Citeren Rosen Penev : If GCC is built with stack smashing protection enabled (SSP), it errors when compiling lzma-loader. Switching to strncpy seems to be an easy way to fix this. It's probably better to use snprintf or strlcpy but the latter is not available for glibc systems. This see

[LEDE-DEV] [PATCH 1/2] firmware-utils: mkdapimg2: Fix potential buffer overflow

2018-04-22 Thread Rosen Penev
If GCC is built with stack smashing protection enabled (SSP), it errors when compiling lzma-loader. Switching to strncpy seems to be an easy way to fix this. It's probably better to use snprintf or strlcpy but the latter is not available for glibc systems. Output of crash below: *** buffer ove