X-Git-Url: https://git.cweiske.de/grauphel.git/blobdiff_plain/eb5c81dea5a60bc65d3ec607daf5ad81fd709928..2b5ff5d48b4ec80e0e0e18188689edefaeefe91d:/lib/oauth.php diff --git a/lib/oauth.php b/lib/oauth.php index 231a177..4a652fc 100644 --- a/lib/oauth.php +++ b/lib/oauth.php @@ -158,10 +158,18 @@ class OAuth */ public static function getProvider() { + $params = array(); //$_SERVER['REDIRECT_HTTP_AUTHORIZATION'] = $_SERVER['HTTP_AUTHORIZATION']; - //unset($_SERVER['HTTP_AUTHORIZATION']); - $params = array(); + if (isset($_SERVER['HTTP_AUTHORIZATION']) + && $_SERVER['HTTP_AUTHORIZATION'] == '' + ) { + //work around bug https://bugs.php.net/bug.php?id=68168 + //#68168: HTTP Basic auth and empty auth header reported + // as "signature_method_rejected" + $params['oauth_signature_method'] = OAUTH_SIG_METHOD_PLAINTEXT; + } + if (!isset($_SERVER['HTTP_AUTHORIZATION']) && isset($_SERVER['REDIRECT_HTTP_AUTHORIZATION']) ) {