/home/desid573/public_html/eway/pdd/lib/Cake/Network/Http
Edit: /home/desid573/public_html/eway/pdd/lib/Cake/Network/Http/BasicAuthentication.php (1903B)
request['header']['Authorization'] = static::_generateHeader($authInfo['user'], $authInfo['pass']);
}
}
/**
* Proxy Authentication
*
* @param HttpSocket $http Http socket instance.
* @param array &$proxyInfo Proxy info.
* @return void
* @see http://www.ietf.org/rfc/rfc2617.txt
*/
public static function proxyAuthentication(HttpSocket $http, &$proxyInfo) {
if (isset($proxyInfo['user'], $proxyInfo['pass'])) {
$http->request['header']['Proxy-Authorization'] = static::_generateHeader($proxyInfo['user'], $proxyInfo['pass']);
}
}
/**
* Generate basic [proxy] authentication header
*
* @param string $user Username.
* @param string $pass Password.
* @return string
*/
protected static function _generateHeader($user, $pass) {
return 'Basic ' . base64_encode($user . ':' . $pass);
}
}