php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #80213 imap_mail_compose() segfaults on certain $bodies
Submitted: 2020-10-10 11:59 UTC Modified: 2020-10-10 11:59 UTC
From: cmb@php.net Assigned: cmb (profile)
Status: Closed Package: IMAP related
PHP Version: 7.3Git-2020-10-10 (Git) OS: *
Private report: No CVE-ID: None
 [2020-10-10 11:59 UTC] cmb@php.net
Description:
------------
The 'type.parameters' and 'disposition' elements of a body are
supposed to hold associative arrays.  Passing non associative
arrays leads to a segfault.


Test script:
---------------
<?php
$envelope = [];
$body = [[
    'type.parameters' => ['param'],
    'disposition' => ['disp'],
], [
    'type.parameters' => ['param'],
    'disposition' => ['disp'],
]];
imap_mail_compose($envelope, $body);
echo "done\n";
?>


Expected result:
----------------
done


Actual result:
--------------
segfault


Patches

Add a Patch

Pull Requests

Pull requests:

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-10-10 11:59 UTC] cmb@php.net
-Assigned To: +Assigned To: cmb
 [2020-10-10 14:52 UTC] cmb@php.net
The following pull request has been associated:

Patch Name: Fix #80213: imap_mail_compose() segfaults on certain $bodies
On GitHub:  https://github.com/php/php-src/pull/6315
Patch:      https://github.com/php/php-src/pull/6315.patch
 [2020-10-10 17:21 UTC] cmb@php.net
Automatic comment on behalf of cmbecker69@gmx.de
Revision: http://git.php.net/?p=php-src.git;a=commit;h=8bee0fbd37c8eee0a17abe4a0afd69ad9ac7105a
Log: Fix #80213: imap_mail_compose() segfaults on certain $bodies
 [2020-10-10 17:21 UTC] cmb@php.net
-Status: Assigned +Status: Closed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 15:01:28 2024 UTC