. * * * The author of this software is Mashape, Inc. * For any question or feedback please contact us at: support@mashape.com * */ class AuthUtil { public static function generateAuthenticationHeader($publicKey, $privateKey) { $uuid = uniqid(); $hash = hash_hmac("sha1", $uuid, $privateKey); $header = "X-Mashape-Authorization: " . base64_encode($publicKey . ":" . $hash . $uuid) . "\r\n"; return $header; } } ?>