Uh oh!
There was an error while loading. Please reload this page.
Support LDAP dns longer than 255 characters - #29523
Conversation
Uh oh!
There was an error while loading. Please reload this page.
come-nc
commented
Nov 2, 2021
Note to self: we should look into which kind of hash fits the best what we need here. There are uuid v5, and other hash algorithm, unicity and performance should be compared to select the best fit. |
come-nc
commented
Nov 2, 2021
Related bug ticket: #2213 |
blizzz
commented
Nov 16, 2021
/rebase |
blizzz
left a comment
There was a problem hiding this comment.
In the first Migration class, the final state of the table should be reflected for new installations. Not necessary to run the while migration history on a new install. So you can add the columns and alter the index in Version1010Date20200630192842.
The new Version1130Date20211102154716 is of course required and looks good as is, with the one remark I left there.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
blizzz
commented
Nov 16, 2021
@nickvergessen what do you think about its backportability? |
blizzz
commented
Nov 16, 2021
…while at changing DB it might be worth to add a simple index on directory_uuid, too, since this also may be used as sole WHERE column in queries. |
Uh oh!
There was an error while loading. Please reload this page.
come-nc
commented
Nov 18, 2021
Done in bb6906d |
come-nc
commented
Nov 18, 2021
Done in c1ff024 |
Adds an ldap_full_dn column to store the dn, and only store a sha256 hash in the ldap_dn which is shorter and can be indexed without trouble. Migration still needs to be implemented. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
We cannot set ldap_dn_hash column as notnull because it is empty for existing users before postSchemaChange is called Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This is to ensure new installations do not need to go through migration history. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
The documentation says it can return false, and even if that is highly unlikely for sha256, better safe than sorry. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
fd43e4e to
a359047Compare| @@ -0,0 +1,146 @@ | |||
| <?php | |||
skjnldsv
commented
Dec 9, 2021
/backport to stable23 |
skjnldsv
commented
Dec 9, 2021
/backport to stable22 |
skjnldsv
commented
Dec 9, 2021
/backport to stable21 |
skjnldsv
commented
Dec 9, 2021
/backport to stable20 |
CarlSchwan
commented
Dec 9, 2021
Sorry for remembering that 2 minutes too late, but I think this is missing a version bump. Otherwise the migration won't run in our development instances. |
The backport to stable20 failed. Please do this backport manually. |
The backport to stable22 failed. Please do this backport manually. |
The backport to stable23 failed. Please do this backport manually. |
The backport to stable21 failed. Please do this backport manually. |
skjnldsv
commented
Dec 10, 2021
@come-nc please do the backports manually :( |
Adds an
ldap_full_dncolumn to store the dn, and only store a sha256 hash in theldap_dnwhich is shorter and can be indexed without trouble.Migration still needs to be implemented.
Signed-off-by: Côme Chilliet come.chilliet@nextcloud.com