[Nasm-bugs] [Bug 3392846] New: Simple null pointer dereference in nasm (function parse_cmdline)

noreply-nasm at dev.nasm.us noreply-nasm at dev.nasm.us
Thu Mar 16 01:21:06 PDT 2023


            Bug ID: 3392846
           Summary: Simple null pointer dereference in nasm (function
           Product: NASM
           Version: 2.17 (development)
          Hardware: All
                OS: Linux
            Status: OPEN
          Severity: normal
          Priority: Medium
         Component: Assembler
          Assignee: nobody at nasm.us
          Reporter: youngseok.main at gmail.com
                CC: chang.seok.bae at intel.com, gorcunov at gmail.com,
                    hpa at zytor.com, nasm-bugs at nasm.us
     Obtained from: Built from git using configure

Hello, nasm developers.

Here is another NPD raised by parse_cmdline, found by fuzzing. The command
input is very simple in this case.

Command Input:
nasm --pragma

nasm: error: option `--pragma' requires an argument

Sanitizer Dump:
==26582==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc
0x5555556853dc bp 0x7fffffffe040 sp 0x7fffffffdf90 T0)
==26582==The signal is caused by a READ memory access.
==26582==Hint: address points to the zero page.
    #0 0x5555556853db in parse_cmdline asm/nasm.c:1492
    #1 0x555555681799 in main asm/nasm.c:554
    #2 0x7ffff6a48c86 in __libc_start_main
    #3 0x55555567f699 in _start

OS: Ubuntu 18.04
gcc: 7.5.0
nasm: 2.17rc0 (Git master branch, a916e4127b2eaa3bf40bddf3de9b0ceefc0d98a)

Note that we built nasm with sanitizers.

Thank you.

You are receiving this mail because:
You are watching all bug changes.
You are on the CC list for the bug.

More information about the Nasm-bugs mailing list