プロジェクト

全般

プロフィール

Bug(バグ) #1153

Failed to fetch mobile UID in registration (登録時に携帯電話個体識別番号の取得に失敗する)

Kousuke Ebiharaほぼ14年前に追加. ほぼ14年前に更新.

ステータス:
Fixed(完了)
優先度:
Normal(通常)
担当者:
対象バージョン:
開始日:
2010-06-07
期日:
進捗率:

100%

3.6 で発生するか:
Unknown (未調査)
3.8 で発生するか:
Unknown (未調査)

説明

Overview (現象)

Failed to fetch mobile UID in registration

登録時に携帯電話個体識別番号の取得に失敗する

Causes (原因)

I added changes, that is for not using CSRF token to add support non-authenticated registration, in 15b753c94d814a77ff3d2845df96f0c9c7962654.

Before these changes, the "_csrf_token" entry is in "auth" request parameter (that is an array for bind to opAuthRegisterForm). After these changes, as a result, that "auth" is an empty array (by depending on an authentication plugin).

Post-validators are not running when a binded value is an empty, so opAuthRegisterForm::validateMobileUID(), is a post-validator of opAuthRegisterForm, is not called. Fetching mobile UID is in this method, so fetching mobile UID is failed after that changes.

However, this issues are not in master branch at 1849103f1d87a30720cb (when this issue was found). Because b1bd42e951adb4cb8b66865257fc5949f3fbd267 fixed this issue by adding consider of empty "auth" parameter on binding to opAuthRegisterForm.

15b753c94d814a77ff3d2845df96f0c9c7962654 にて、登録処理を認証状態でおこなわないようにする変更を加えた際に、その障害となる CSRF 対策用トークンの使用をしないように変更をおこなった。

この変更以前には、 auth というリクエストパラメータ(opAuthRegisterForm にバインドされる配列)に _csrf_token というエントリが格納されていたが、この変更によって、(認証プラグインによっては) auth は結果的に空配列となるようになった。

空配列の場合はフォームに登録されたポストバリデータは走らないので、 opAuthRegisterForm のポストバリデータである opAuthRegisterForm::validateMobileUID() はコールされないことになる。携帯電話個体識別番号の取得はこのメソッドでおこなっているため、この変更以降には携帯電話個体識別番号の取得がおこなわれないという状態になっていた。

ただし、本件は、問題発覚時点での master ( 1849103f1d87a30720cb ) では発生しない。これは b1bd42e951adb4cb8b66865257fc5949f3fbd267 において、 opAuthRegisterForm へのバインドをおこなう際に auth パラメータが空配列であった場合の考慮が加えられているためである。

Way to fix (修正内容)

This issue has been already fixed in b1bd42e951adb4cb8b66865257fc5949f3fbd267.

b1bd42e951adb4cb8b66865257fc5949f3fbd267 で修正済みである(このチケットでの対応として、本問題の検証用のユニットテストを追加した)

関係しているリビジョン

リビジョン 73dfc645 (差分)
Kousuke Ebiharaほぼ14年前に追加

fixed that failed to fetch mobile UID in registration (fixes #1153)

Actually, it have been fixed in b1bd42e951adb4cb8b66865257fc5949f3fbd267.
This issue was found after fixed that commit. This commit adds unit test for this issue.

履歴

#1 Kousuke Ebiharaほぼ14年前に更新

  • ステータスAccepted(着手) から Pending Review(レビュー待ち) に変更
  • 進捗率0 から 50 に変更

更新履歴 73dfc6458743b8d4b310aef6cf8d3ce5cef21b9d で適用されました。

#2 Kousuke Ebiharaほぼ14年前に更新

  • 題名Failed to fetch mobile UID in registration から Failed to fetch mobile UID in registration (登録時に携帯電話個体識別番号の取得に失敗する) に変更

#3 Kousuke Ebiharaほぼ14年前に更新

  • ステータスPending Review(レビュー待ち) から Fixed(完了) に変更
  • 進捗率50 から 100 に変更

他の形式にエクスポート: Atom PDF