Bug#919605: grub-fstest: segmentation fault with a very long value for '-n' option

s3v c0llapsed at yahoo.it
Thu Jan 17 21:26:35 GMT 2019


Package: grub-common
Severity: normal

Dear maintainer,
passing a very long value to grub-fstest command with '-n" option causes a
segmentation fault.

  $ foo="0"; for i in {1..6000}; foo="$foo$i"; done
  $ grub-fstest -n $foo
  Segmentation fault

Similarly:

  $ echo "$foo" > foofile
  $ grub-fstest -n $(cat foofile)
  Segmentation fault

A more verbose output from tty1:

  $ grub-fstest -n $foo
  [ 2897.594543] grub-fstest[29069]: segfault at 0 ip 00005598771051db
  sp 00007ffe657517a0 error 4 in grub-fstest[559877104000+7b000]
  [ 2897.596081] Code: 05 71 c3 0d 00 01 31 c0 e9 72 fe ff ff 66 90 31 d2 48 8d
  74 24 08 48 89 df e8 41 e2 05 00 48 8b 54 24 08 48 89 05 85 dc 0c 00 <80> 3a
  73 0f 85 42 fe ff ff 48 c1 e0 09 48 89 05 71 dc 0c 00 31 c0
  Segmentation fault


Kind regards.



-- System Information:
Debian Release: buster/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 4.19.0-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=it_IT.UTF-8, LC_CTYPE=it_IT.UTF-8 (charmap=UTF-8), LANGUAGE=en_US
(charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)



More information about the Pkg-grub-devel mailing list