Re: Bash regexp parsing would benefit from safe recursion limit

2022-03-30 Thread Steffen Nurpmeso
Chet Ramey wrote in : |On 3/30/22 11:16 AM, willi1337 bald wrote: |> Bash Version: 5.1 |> Patch Level: 16 |> Release Status: release |> |> Description: |> |> A deeply nested and incorrect regex expression can cause exhaustion of |> stack resources, which crashes the bash process. |

Re: Bash regexp parsing would benefit from safe recursion limit

2022-03-30 Thread Chet Ramey
On 3/30/22 11:16 AM, willi1337 bald wrote: > Bash Version: 5.1 > Patch Level: 16 > Release Status: release > > Description: > > A deeply nested and incorrect regex expression can cause exhaustion of > stack resources, which crashes the bash process. Bash doesn't use it's own regexp engine; it

Re: Bash regexp parsing would benefit from safe recursion limit

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022 at 7:47 PM Martin Schulte wrote: > Hello Willi! > > > Fix: > > Count the stack frames during recursive parsing and emit error before > stack > > resources are entirely consumed. > > What exactly should happen and what is the benefit of this solution? > i guess it wont

Re: Bash regexp parsing would benefit from safe recursion limit

2022-03-30 Thread Martin Schulte
Hello Willi! > Fix: > Count the stack frames during recursive parsing and emit error before stack > resources are entirely consumed. What exactly should happen and what is the benefit of this solution? BTW: I tried trap 'echo "Ohohoh..."; exit 1;' SIGSEGV but the signal wasn't caught (which

Bash regexp parsing would benefit from safe recursion limit

2022-03-30 Thread willi1337 bald
Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc Compilation CFLAGS: -g -O2 -Wno-parentheses -Wno-format-security uname output: Linux DESKTOP-0TQV3NS 5.10.60.1-microsoft-standard-WSL2 #1 SMP Wed Aug 25 23:20:18 UTC 2021 x86_64 x86_64

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 16:58 Greg Wooledge wrote: > On Wed, Mar 30, 2022 at 04:52:16PM +0200, Alex fxmbsw7 Ratchev wrote: > > cool mate i halfway understand but great peaceful explaintion :) > > The most important thing here is that zombies are mostly harmless. > They aren't using any memory or

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Greg Wooledge
On Wed, Mar 30, 2022 at 04:52:16PM +0200, Alex fxmbsw7 Ratchev wrote: > cool mate i halfway understand but great peaceful explaintion :) The most important thing here is that zombies are mostly harmless. They aren't using any memory or CPU. The only thing they're using is a PID, and the kernel

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 16:15 Chet Ramey wrote: > On 3/30/22 1:40 AM, Alex fxmbsw7 Ratchev wrote: > > i do > > > > wpa_supplicant -i"$if" -c<( printf %s\\n \ > > 'network={' "ssid=\"$ssid\"" "psk=\"$pass\"" '}' > > ) & > > { sleep 3 ; dhclient "$if" ; } & > > > > which is simply wpa_supplicant

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Chet Ramey
On 3/30/22 1:40 AM, Alex fxmbsw7 Ratchev wrote: > i do > > wpa_supplicant -i"$if" -c<( printf %s\\n \ > 'network={' "ssid=\"$ssid\"" "psk=\"$pass\"" '}' > ) & > { sleep 3 ; dhclient "$if" ; } & > > which is simply wpa_supplicant -iiface -c<( conf file printing ) > > it since years resuts in

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 13:53 Andreas Schwab wrote: > On Mär 30 2022, Greg Wooledge wrote: > > > If it turns out that wpa_supplicant is the parent, then that's the > > responsible party, and that's where you should send your bug reports. > > Processes don't know about process substitutions set up

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Andreas Schwab
On Mär 30 2022, Greg Wooledge wrote: > If it turns out that wpa_supplicant is the parent, then that's the > responsible party, and that's where you should send your bug reports. Processes don't know about process substitutions set up by the shell, thus they cannot be resposible for them. $

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Alex fxmbsw7 Ratchev
On Wed, Mar 30, 2022, 13:30 Greg Wooledge wrote: > On Wed, Mar 30, 2022 at 07:40:22AM +0200, Alex fxmbsw7 Ratchev wrote: > > i do > > > > wpa_supplicant -i"$if" -c<( printf %s\\n \ > > 'network={' "ssid=\"$ssid\"" "psk=\"$pass\"" '}' > > ) & > > { sleep 3 ; dhclient "$if" ; } & > > > > which is

Re: defuncted printf process when using wpa_supplicant

2022-03-30 Thread Greg Wooledge
On Wed, Mar 30, 2022 at 07:40:22AM +0200, Alex fxmbsw7 Ratchev wrote: > i do > > wpa_supplicant -i"$if" -c<( printf %s\\n \ > 'network={' "ssid=\"$ssid\"" "psk=\"$pass\"" '}' > ) & > { sleep 3 ; dhclient "$if" ; } & > > which is simply wpa_supplicant -iiface -c<( conf file printing ) > > it