-
Notifications
You must be signed in to change notification settings - Fork 30
Open
Description
Hi, I'm experiencing a buffer overflow when I try to query some Quake1 servers while asking for server rules.
Basic query (works):
$ qstat -qs 109.228.169.24:26003
ADDRESS PLAYERS MAP RESPONSE TIME NAME
109.228.169.24:26003 0/8 0/0 intro 121 / 0 QRF_COOP
Server rules query (do not work):
qstat -R -qs 109.228.169.24:26003
ADDRESS PLAYERS MAP RESPONSE TIME NAME
*** buffer overflow detected ***: qstat terminated
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x78c4e)[0x7f47ea648c4e]
/lib/x86_64-linux-gnu/libc.so.6(__fortify_fail+0x5c)[0x7f47ea6e8e8c]
/lib/x86_64-linux-gnu/libc.so.6(+0x116e80)[0x7f47ea6e6e80]
qstat[0x40ceae]
qstat[0x40e97a]
qstat[0x40eb1d]
qstat[0x41f6ab]
qstat[0x402333]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0)[0x7f47ea5f0a40]
qstat[0x403829]
======= Memory map: ========
00400000-00445000 r-xp 00000000 fc:02 219994 /usr/bin/qstat
00645000-00646000 r--p 00045000 fc:02 219994 /usr/bin/qstat
00646000-0064c000 rw-p 00046000 fc:02 219994 /usr/bin/qstat
0064c000-0065a000 rw-p 00000000 00:00 0
00a82000-00aa3000 rw-p 00000000 00:00 0 [heap]
7f47ea138000-7f47ea14e000 r-xp 00000000 fc:02 6030633 /lib/x86_64-linux-gnu/libgcc_s.so.1
7f47ea14e000-7f47ea34d000 ---p 00016000 fc:02 6030633 /lib/x86_64-linux-gnu/libgcc_s.so.1
7f47ea34d000-7f47ea34e000 rw-p 00015000 fc:02 6030633 /lib/x86_64-linux-gnu/libgcc_s.so.1
7f47ea34f000-7f47ea5d0000 rw-p 00000000 00:00 0
7f47ea5d0000-7f47ea790000 r-xp 00000000 fc:02 6030624 /lib/x86_64-linux-gnu/libc-2.21.so
7f47ea790000-7f47ea990000 ---p 001c0000 fc:02 6030624 /lib/x86_64-linux-gnu/libc-2.21.so
7f47ea990000-7f47ea994000 r--p 001c0000 fc:02 6030624 /lib/x86_64-linux-gnu/libc-2.21.so
7f47ea994000-7f47ea996000 rw-p 001c4000 fc:02 6030624 /lib/x86_64-linux-gnu/libc-2.21.so
7f47ea996000-7f47ea99a000 rw-p 00000000 00:00 0
7f47ea9a0000-7f47ea9c4000 r-xp 00000000 fc:02 6030594 /lib/x86_64-linux-gnu/ld-2.21.so
7f47eabbf000-7f47eabc3000 rw-p 00000000 00:00 0
7f47eabc3000-7f47eabc4000 r--p 00023000 fc:02 6030594 /lib/x86_64-linux-gnu/ld-2.21.so
7f47eabc4000-7f47eabc5000 rw-p 00024000 fc:02 6030594 /lib/x86_64-linux-gnu/ld-2.21.so
7f47eabc5000-7f47eabc7000 rw-p 00000000 00:00 0
7f47eabc7000-7f47eabc9000 rw-p 00000000 00:00 0
7ffe87c75000-7ffe87c96000 rw-p 00000000 00:00 0 [stack]
7ffe87da8000-7ffe87daa000 r--p 00000000 00:00 0 [vvar]
7ffe87daa000-7ffe87dac000 r-xp 00000000 00:00 0 [vdso]
ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall]
Abandon
It fails while trying an strcpy in send_rule_request_packet function in qstat.c.
You can experiment with server 109.228.169.24:26003 but probably anyone from this list:
This was tested on the last revision of the master branch.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
