github / github/codeql

False negative: py/ldap-injection misses taint flow for ldap3 `extend.standard.paged_search`

オープン
#21,738 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
CodeQL
スター
10.1k
フォーク
2.1k
平均マージ
2日 15時間
マージ済み PR(30日)
141

説明

`py/ldap-injection` reports taint for `ldap3.Connection.search(...)`, but misses equivalent taint flow in:
`conn.extend.standard.paged_search(search_base=..., search_filter=...)`

```python
from flask import Flask, request
import ldap3
app = Flask(__name__)
@app.route("/paged")
def paged():
dn = "dc={}".format(request.args["dc"])
filt = "(user={})".format(request.args["username"])
conn = ldap3.Connection(ldap3.Server("ldap://127.0.0.1"), user=dn, auto_bind=True)
conn.extend.standard.paged_search(search_base=dn, search_filter=filt) # no alert
```

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

Start with the py/ldap-injection query and compare how ldap3.Connection.search(...) models taint flow with the conn.extend.standard.paged_search(...) call shown here. The work is done when taint reaching search_base and search_filter through this API is reported equivalently to the existing search flow.

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

評価

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

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

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