dn missing in attributes ?
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 35/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- php
調査の方向性
まず modules/ldap/src/Auth/Process/AttributeAddUsersGroups.php の229行目から始め、続いて、前にある ldap:AttributeAddFromLDAP 設定とレポート内の AttributeAddUsersGroups 設定を比較します。2つの authproc 呼び出しを使って警告を再現し、それらの間で渡される属性を調べます。DN ベースのグループ検索で missing-key warning が発生せず、期待されるグループが返されれば完了です。
索引モデルが issue の本文から書いたものです。
説明
I've got a simple authproc that calls ldap:AttributeAddUsersGroups to get the user's group information. Our LDAP is OpenLDAP that has groups with both groupOfNames and posixGroup objectclasses. So we have both uniqueMember and memberuid attributes our groups.
If I call that authproc like this - it works, the uid is used and matches the memberUid attribute:
50 => [
'class' => 'ldap:AttributeAddUsersGroups',
'authsource' => 'ldap',
'ldap.product' => 'OpenLDAP',
'search.base' => [
'ou=Groups,dc=mycompany,dc=com',
],
'attribute.dn' => 'dn',
'attribute.return' => 'cn',
'attribute.groups' => 'groups',
'attribute.username' => 'uid',
'attribute.memberOf' => 'memberuid',
'timeout' => 30,
],
However if I call it like this:
50 => [
'class' => 'ldap:AttributeAddUsersGroups',
'authsource' => 'ldap',
'ldap.product' => 'OpenLDAP',
'search.base' => [
'ou=Groups,dc=mycompany,dc=com',
],
'attribute.dn' => 'dn',
'attribute.return' => 'cn',
'attribute.groups' => 'groups',
'attribute.username' => 'dn',
'attribute.memberOf' => 'uniquemember',
'timeout' => 30,
],
I get an error telling me 'dn' is not found in the attributes array. So, I added another authproc call to ldap:AttributeAddFromLDAP to go specifically grab 'dn' for the user. To my knowledge 'dn' is always returned by LDAP searches, but I figured let's try this:
40 => [
'class' => 'ldap:AttributeAddFromLDAP',
'authsource' => 'ldap',
'attributes' => ['dn'],
'attribute.policy' => 'add',
'search.filter' => '(cn=%cn%)',
],
Which itself works without error, but I still get the following on the very next call to 'ldap:AttributeAddUsersGroups' :
SimpleSAML\Error\Exception: Warning - Undefined array key "dn" at /usr/local/install/simplesamlphp/modules/ldap/src/Auth/Process/AttributeAddUsersGroups.php:229
I can't find where or if 'dn' is somehow being filtered out but the attribute is definitely being returned by a search.
We'd like to switch to using the DN where we can but this has been a roadblock I can't figure out.
- 主要言語
- PHP
- スター
- 5
- フォーク
- 14
- PR マージ指標
- 30日以内にマージされた PR はありません
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
simplesamlphp/simplesamlphp-module-ldap のほかの issue
-
難易度 5/5 1週間以上 初心者へのやさしさ 30/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
simplesamlphp/simplesamlphp-module-ldap#66 · コメント 11 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
simplesamlphp/simplesamlphp-module-ldap#3 · コメント 3 件 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 45/100
simplesamlphp/simplesamlphp-module-ldap#2 · コメント 1 件 ·
simplesamlphp/simplesamlphp-module-ldap の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
pluginsGLPI/datainjection#673 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
octobercms/october#6130 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
getgrav/grav-plugin-form#656 ·
-
customer-support needs-triage Platform(Default)
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
sync-en
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100