Use secrets.choice and 600,000 iterations for WAMP-CRA keygen helper

オープン
#1,633 コメント 8 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@oberstet がすでに取り組んでいます。

2024年4月3日 から。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
python

調査の方向性

autobahn/wamp/auth.py の 494 行目と 604 行目付近を読み、次に WAMP-CRA のキー生成ヘルパーとその呼び出し元をたどってください。Issue のタイトルにある 600,000 回の反復と、本文にある 10,000 回以上という最小値の整合を取り、合意された安全な乱数と反復回数のデフォルト値がヘルパーを壊すことなく反映された時点で作業完了とみなしてください。

索引モデルが issue の本文から書いたものです。

説明

bug wamp

I've got some suggestions which may be useful and can help make it more secure.

  1. The "random.choice()" used here may be considered vulnerable because the "random" module is not suitable for cryptographic operations as it is not cryptographically secure.
    Adopting "os.urandom" or functions from the 'secrets' module may be a feasible solution.
  2. The default iteration for pbkdf2 should be at least 10000, while the current default iteration here is only 1000.
    You can increase the iteration to at least 10000 to fix it.
主要言語
Python
スター
2.5k
フォーク
766
平均マージ
12時間 40分
マージ済み PR(30日)
20

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

crossbario/autobahn-python のほかの issue

crossbario/autobahn-python の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。