X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FSecurity%2FOAuth1%2FOAuthUtil.php;h=06847eceb3002b76d387ad1c02de69187ac0989b;hb=302619a5de7e694acc2d6883af77fa9b051bb974;hp=bc30c800802491d46e90eb567bf833fab80214f9;hpb=0c8923aabdfc09447a4060a6781c76529db506a9;p=friendica.git diff --git a/src/Security/OAuth1/OAuthUtil.php b/src/Security/OAuth1/OAuthUtil.php index bc30c80080..06847eceb3 100644 --- a/src/Security/OAuth1/OAuthUtil.php +++ b/src/Security/OAuth1/OAuthUtil.php @@ -135,7 +135,7 @@ class OAuthUtil $value = isset($split[1]) ? OAuthUtil::urldecode_rfc3986($split[1]) : ''; if (isset($parsed_parameters[$parameter])) { - // We have already recieved parameter(s) with this name, so add to the list + // We have already received parameter(s) with this name, so add to the list // of parameters with this name if (is_scalar($parsed_parameters[$parameter])) { @@ -154,6 +154,8 @@ class OAuthUtil public static function build_http_query($params) { + // Parameters are sorted by name, using lexicographical byte value ordering. + // Ref: Spec: 9.1.1 (1) uksort($params, 'strcmp'); return http_build_query($params, '', null, PHP_QUERY_RFC3986); }