[Bug 15351] New: latest 1.36.0 `sh -i` without tty segfaults
bugzilla at busybox.net
bugzilla at busybox.net
Fri Feb 24 05:36:06 UTC 2023
https://bugs.busybox.net/show_bug.cgi?id=15351
Bug ID: 15351
Summary: latest 1.36.0 `sh -i` without tty segfaults
Product: Busybox
Version: unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: major
Priority: P5
Component: Other
Assignee: unassigned at busybox.net
Reporter: logoerthiner1 at 163.com
CC: busybox-cvs at busybox.net
Target Milestone: ---
A quick way to check whether a busybox version has this bug:
```
user@~ $ docker pull busybox
Using default tag: latest
latest: Pulling from library/busybox
Digest: sha256:7b3ccabffc97de872a30dfd234fd972a66d247c8cfc69b0550f276481852627c
Status: Image is up to date for busybox:latest
docker.io/library/busybox:latest
user@~ $ docker run -ti --rm busybox sh
/ #
/ # cat | sh -i
Segmentation fault (core dumped)
[1]+ Stopped (tty input) cat | sh -i
/ # fg
cat | sh -i
```
This bug appears both in my manually compiled version and in docker shipped
version, so it is not related to specific compiler or configs.
It seems that `sh -i` assumes stdin is a tty and will segfault when it is not.
This bug does not appear in 1.35.0 but shows in 1.36.0 .
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the busybox-cvs
mailing list