allow an attribute to return more than one value - #19635
Conversation
|
thanks @blizzz |
|
Since #18469 was backported to stable8.1, this one is affected as well. I keep the fix as simple as possible for an easier backport. |
|
Ready for review. Since it touches the very core of the LDAP backend, there's not just one thing to test, but everything should work as it was used to. I am confident that it does… The one obvious thing this should fix is that only one (max. two) groups of an LDAP user were shown, when there should be more. Either users page or personal page. Because the original issue was a decision from 2012 which worked pretty well until #18469 was merged, that one needs to change. It's not a terribly huge, but fundamental change, we need to have it in 8.2 And because #18469 was backported to 8.1.x, we need a backport as well. @karlitschek please confirm. So, please test and review @MorrisJobke @PVince81 @davitol @GreenArchon or others |
|
@cmonteroluque this requires qa involvement - kind of critical respecting the time line |
|
@DeepDiver1975 agreed. Today's a holiday in Spain. Pinging @rperezb for early work tomorrow |
|
@blizzz Testing this PR I've found the following behaviour: {"reqId":"MCkuN6Pc16rF1NTxzIlL","remoteAddr":"XX.XXX.XXX.X8","app":"PHP","message":"ldap_read(): Search: Invalid DN syntax at /opt/owncloud/apps/user_ldap/lib/ldap.php#257","level":3,"time":"2015-10-13T10:33:03+00:00"} |
|
@davitol results from a diagnostic query, message is nasty, but all is good. |
allow an attribute to return more than one value
|
@karlitschek @cmonteroluque may I suggest to postpone the backport? I'd love to have @blizzz back on this once he did recover- THX |
|
makes sense imho |
|
yeah, agree |
With #18469 I have overseen that our result processing does always only accept on value per attribute. The relevant piece of code is from 2012. Ancient! Anyway, usually it is not a problem. There is just one DN, just one displayname to use and it is also ok to just one email address for instance. However with that PR we also cache the groups a user belongs to, if 'memberof' is present. And just one groups sucks :( This means that a user has maximum of one (maybe 2 with primary) group(s) shown.
Now I am fixing this, but it is not fully done yet. Open ToDos:
FYI @DeepDiver1975 @cmonteroluque
For the record, "changelog" about affected and relevant methods: