$re = '/auth-sender:\h+(.+)\h*\R*/u';
$str = ' Received: from mail pickup service by fakeserver.m2w.com with Microsoft
SMTPSVC; Tue, 3 Dec 2019 14:36:35 -0800
auth-sender: santaana@fakeemail.com
Received: from 217.165.33.125 unverified ([217.165.33.125]) by
mmmeb08oc.m2w.com with M2W SMTP Server;
Tue, 03 Dec 2019 14:36:34 -0800
Date: Wed, 04 Dec 2019 02:32:18 +0400
From: "Coordinador MLV" <santaana@fakeemail.com>
To: <8736c321fd7cc61b92396b4f275614c7@fakeemail.comm>';
preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0);
// Print the entire match result
var_dump($matches);
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for PHP, please visit: http://php.net/manual/en/ref.pcre.php