Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

--TEST-- Bug #73203 (passing additional_parameters causes mail to fail) --DESCRIPTION-- We..

Decoded Output download

--TEST--
Bug #73203 (passing additional_parameters causes mail to fail)
--DESCRIPTION--
We're not really interested in testing mail() here, but it is currently the
only function besides mb_send_mail() which allows to call php_escape_shell_cmd()
with an empty string. Therefore we don't check the resulting email, but only
verify that the call succeeds.
--INI--
sendmail_path={MAIL:bug73203.eml}
mail.add_x_header = Off
--FILE--
<?php
var_dump(
    mail('[email protected]', 'subject', 'message', 'From: [email protected]', '')
);
?>
--EXPECT--
bool(true)
--CLEAN--
<?php
unlink('bug73203.eml');
?>

Did this file decode correctly?

Original Code

--TEST--
Bug #73203 (passing additional_parameters causes mail to fail)
--DESCRIPTION--
We're not really interested in testing mail() here, but it is currently the
only function besides mb_send_mail() which allows to call php_escape_shell_cmd()
with an empty string. Therefore we don't check the resulting email, but only
verify that the call succeeds.
--INI--
sendmail_path={MAIL:bug73203.eml}
mail.add_x_header = Off
--FILE--
<?php
var_dump(
    mail('[email protected]', 'subject', 'message', 'From: [email protected]', '')
);
?>
--EXPECT--
bool(true)
--CLEAN--
<?php
unlink('bug73203.eml');
?>

Function Calls

mail 1

Variables

None

Stats

MD5 e9a068bae8d4a1e0ab0174b2f4ac3536
Eval Count 0
Decode Time 88 ms