change in behavior starting with bash-4.3_p14 and $@ in [[...]]

2014-08-12 Thread Mike Frysinger
simple enough code: foo=(0 0 0); [[ -z ${foo[@]#0} ]]; echo $? with bash-4.3_p13 and older, this would show 0. starting with bash-4.3_p14, this now shows 1. i can't tell from the thread whether this was intentional: https://lists.gnu.org/archive/html/help-bash/2014-04/msg4.html -mike signa

Re: Feature request - ganged file test switches

2014-08-12 Thread Chet Ramey
On 8/9/14, 7:07 AM, Steve Simmons wrote: > Advance apologies if this has already been discussed and rejected. It hasn't. > It would be nice to have ganged file test switches. As an example, to test > that a directory exists and is properly accessible one could do > > if [[ -d foo ]] && [[ -r

Re: Potential vulnerabilities in BASH 4.3

2014-08-12 Thread Chet Ramey
> > bash-4.3.tar\bash-4.3\lib\sh\unicode.c: > > *line 87: *strcpy (charsetbuf, locale); > > Thanks for the report. This is a potential vulnerability if the value of > the LC_CTYPE variable is longer than 40 characters. I should have added that this is only a problem on systems that don't have an

Re: Segmentation fault bash 4.3.022

2014-08-12 Thread Chet Ramey
> $ bash-4.3.22 -c 'shopt -s lastpipe; trap -- "printf x" ERR; true | { true | > false; }' > xxSegmentation fault > > $ ./bash -c 'shopt -s lastpipe; trap -- "printf x" ERR; true | { true | > false; }' > xx./bash: wait_for: No record of process 7954 > x Yeah, it will take a little longer to sup

Re: Segmentation fault bash 4.3.022

2014-08-12 Thread Greg Wooledge
On Tue, Aug 12, 2014 at 09:15:04AM -0400, Chet Ramey wrote: > On 8/11/14, 2:21 PM, lolilolicon wrote: > > The following code segfaults when run by bash 4.3.022 > > > > set -E > > shopt -s lastpipe > > trap -- 'true' ERR > > true | { true | false; } > > Here's a patch for those who would l

Re: Segmentation fault bash 4.3.022

2014-08-12 Thread Chet Ramey
On 8/11/14, 2:21 PM, lolilolicon wrote: > Sorry for the unhelpful title, but I can't find a one that isn't > longer than the body of the mail. > > The following code segfaults when run by bash 4.3.022 > > set -E > shopt -s lastpipe > trap -- 'true' ERR > true | { true | false; } > > This

Re: Potential vulnerabilities in BASH 4.3

2014-08-12 Thread Chet Ramey
On 8/11/14, 3:07 PM, Hádrian R wrote: > Hi, I'm Hádrien Romero Soria - @Kaiwaiata​​, I am a 16 year old boy, > passionate about computer security, since more than 8h searching and > finding various possible vulnerabilities in source code of bash.. > I will tell you one vulnerability now, if they tr