Project

General

Profile

Actions

Bug(バグ) #1574

open

同梱されている OAuth.php が古いので差し替える

Added by Naoya Tozuka over 14 years ago. Updated almost 13 years ago.

Status:
New(新規)
Priority:
Normal(通常)
Assignee:
-
Target version:
Start date:
2010-09-09
Due date:
% Done:

0%

Estimated time:
3.6 で発生するか:
Yes
3.8 で発生するか:

Description

OpenPNE3で使われている、http://oauth.googlecode.com/svn/code/php/OAuth.php で配布されているphp版OAuthクラスの過去の実装において、クエリパラメータのソート順がOAuth仕様に沿っていない為、最新の OAuth.php(少なくともこの問題について修正が施された2010/6/12以降のもの)に差し替えるのが適当と思われます。

背景

OAuth Signatureの生成時のクエリパラメータのソート順について、仕様書(http://oauth.net/core/1.0/#signing_process 参照)では

Parameters are sorted by name, using lexicographical byte value ordering. If two or more parameters share the same name, they are sorted by their value.

と定義されています。

同じパラメータ名を使うものが複数ある場合のソート順について、古いOAuth.phpではこの仕様に対し、パラメータの値を「値順(数値なら小さい順)」でソートする実装となっています。
2010/06/12以降のOAuth.phpでは、パラメータの値を(パラメータ名のソート同様)辞書順でソートするように修正されています。(誤解を生みやすい仕様記述かと思いますが、最新版で採用されているこの実装が正しいようです)
http://code.google.com/p/oauth/issues/detail?id=164

このため、古い OAuth.php を利用する場合、正しくないsignatureを生成してしまったり、正しいsignatureを正しくないとしてしまう可能性があります。

Actions #1

Updated by Naoya Tozuka over 14 years ago

  • Assignee deleted (Kousuke Ebihara)
Actions #2

Updated by Kousuke Ebihara over 14 years ago

  • Target version set to OpenPNE 3.6beta6
Actions #3

Updated by Kousuke Ebihara over 14 years ago

  • Target version changed from OpenPNE 3.6beta6 to OpenPNE 3.7.0
Actions #4

Updated by Shouta Kashiwagi almost 13 years ago

  • Target version changed from OpenPNE 3.7.0 to 252
Actions #5

Updated by Shouta Kashiwagi almost 13 years ago

  • Target version changed from 252 to OpenPNE 3.8.x
Actions

Also available in: Atom PDF