[php-src] PR #12783: Add blacklisted command line flags for sendline via mail()

From: Date: Sat, 25 Nov 2023 13:21:57 +0000
Subject: [php-src] PR #12783: Add blacklisted command line flags for sendline via mail()
Groups: php.git-pulls 
Request: Send a blank email to git-pulls+get-24317@lists.php.net to get a copy of this message
Pull Request: https://github.com/php/php-src/pull/12783 Author: TCGeek As discussed, here are the changes I recommend to disable command line flags being passed into the $additional_params for mail(). * Edited both dev and prod php.ini files. * Added function to remove blacklisted commands from user input in mail.c * Added additional if statement to verify that allow_additional_sendmail_flags is off to enforce blacklist * Declared new php_mail_disable_flags function in php_mail.h * Added global INI value for mail.allow_additional_sendmail_flags in main.c * Defined allow_additional_sendmail_flags as boolean in php_globals.c * Added allow test case in mail_blacklist_allowed.phpt * Added disallow test case in mail_blacklist_disallowed.phpt Tested on local instance, everything functions as intended.

« previous php.git-pulls (#24317) next »