bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bash 5.2.21 segfaults when I feed it garbage


From: Chet Ramey
Subject: Re: Bash 5.2.21 segfaults when I feed it garbage
Date: Mon, 15 Jan 2024 12:22:33 -0500
User-agent: Mozilla Thunderbird

On 1/14/24 7:24 PM, Grisha Levit wrote:

See also (even after the fix pushed today):

     bash -c '(( X=([))])'
     heap-use-after-free parse.y:2712:60 in shell_getc

     bash -c '(( X=([))]) ))'
     heap-use-after-free parse.y:2077:11 in parser_expanding_alias

Thanks. This is a different issue. In this case, the parser needs to treat
a string pushed by a failed attempt to parse `((' as an arithmetic command
(in which case we fall back and try to parse the text as a nested subshell)
the same as an alias and fix up the pushed string list.

Chet

--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]