php-src/sapi/phpdbg
Niels Dossche 0f21cbc57c Fix GH-10715: phpdbg heap buffer overflow -- by misuse of the option "--run"
Fixes GH-10715

When a string starting with a NUL character is passed to
phpdbg_vprint(), the vasprintf() will return that 0 characters have been
printed. This causes msglen == 0. When phpdbg_process_print() is called
with a message of length 0, the -1 to check for '\n' will perform an out
of bounds read. Since nothing is printed anyway for msglen == 0, it
seems best to just skip the printing routine for this case.

Closes GH-10720.
2023-02-27 19:47:55 +00:00
..
tests Fix GH-10715: phpdbg heap buffer overflow -- by misuse of the option "--run" 2023-02-27 19:47:55 +00:00
.gdbinit
.phpdbginit Trim trailing whitespace in source code files 2018-10-13 14:17:28 +02:00
config.m4 replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
config.w32 replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
create-test.php Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
CREDITS
Makefile.frag Drop test-phpdbg and clean-phpdbg targets 2021-05-14 12:20:00 +02:00
phpdbg_arginfo.h Improve class entry generation 2021-02-16 13:09:56 +01:00
phpdbg_bp.c Fix null pointer dereference of param 2022-12-30 06:53:28 +00:00
phpdbg_bp.h remove specialized printing from phpdbg (#7156) 2021-06-17 14:22:33 +02:00
phpdbg_break.c replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg_break.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_btree.c Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_btree.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_cmd.c Fixed some spaces used instead of tabs 2021-06-29 11:30:26 +02:00
phpdbg_cmd.h remove specialized printing from phpdbg (#7156) 2021-06-17 14:22:33 +02:00
phpdbg_frame.c remove specialized printing from phpdbg (#7156) 2021-06-17 14:22:33 +02:00
phpdbg_frame.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_help.c replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg_help.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_info.c remove specialized printing from phpdbg (#7156) 2021-06-17 14:22:33 +02:00
phpdbg_info.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_io.c ditch remote 2021-06-13 21:08:35 +02:00
phpdbg_io.h ditch remote 2021-06-13 21:08:35 +02:00
phpdbg_lexer.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_lexer.l PHPDBG: fix bug parsing 3-word opcodes 2021-04-22 10:11:26 +02:00
phpdbg_list.c ditch remote 2021-06-13 21:08:35 +02:00
phpdbg_list.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_out.c Fix GH-10715: phpdbg heap buffer overflow -- by misuse of the option "--run" 2023-02-27 19:47:55 +00:00
phpdbg_out.h remove specialized printing from phpdbg (#7156) 2021-06-17 14:22:33 +02:00
phpdbg_parser.y ditch remote 2021-06-13 21:08:35 +02:00
phpdbg_print.c replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg_print.h replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg_prompt.c Fix undefined behaviour in phpdbg_load_module_or_extension 2022-12-23 13:55:50 +00:00
phpdbg_prompt.h drop phpdbg web helper extension and wait command (#7144) 2021-06-13 14:02:11 +02:00
phpdbg_set.c replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg_set.h replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg_sigsafe.c Replace zend_bool uses with bool 2021-01-15 12:33:06 +01:00
phpdbg_sigsafe.h Replace zend_bool uses with bool 2021-01-15 12:33:06 +01:00
phpdbg_utils.c Fix phpdbg segmentation fault in case of malformed input 2023-01-17 14:12:49 +00:00
phpdbg_utils.h remove specialized printing from phpdbg (#7156) 2021-06-17 14:22:33 +02:00
phpdbg_watch.c ditch remote 2021-06-13 21:08:35 +02:00
phpdbg_watch.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_win.c Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg_win.h Update http->https in license (#6945) 2021-05-06 12:16:35 +02:00
phpdbg.1.in replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg.c Fix GH-9710: phpdbg memory leaks by option "-h" 2023-01-08 16:07:00 +00:00
phpdbg.h replace phpdbg custom opcode dumper with O+ dump (#7227) 2021-07-13 15:32:14 +02:00
phpdbg.init.d Trim trailing whitespace in source code files 2018-10-13 14:17:28 +02:00
phpdbg.stub.php Enable class entry generation for sapi extensions 2021-02-14 12:03:48 +01:00
test.php Apply tidy formatting 2020-02-03 13:41:31 +01:00
web-bootstrap.php Rename non-existing site phpdbg.com to localhost 2019-02-19 20:21:20 +01:00