-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sharing dialog returns duplicate entries #6807
Comments
Hi, We can reproduce creating local accounts. Steps to reproduce:
|
@nickvergessen wasnt there a fix about numerical usernames recently? |
We have the same issue, but with slightly different config:
The suggested workaround from the first post seems to work for us, but if it would be fixed upstream, it would be nice. |
This problem seems to be solved with Nextcloud 13. :-) 👍 |
thansk for the feedback! |
Steps to reproduce
Expected behaviour
Sharing dialog should display unique users/contacts.
Actual behaviour
Sharing dialog returns some duplicate users/contacts entries.
Server configuration
Operating system: Debian 8
Web server: Apache 2.4
Database: Postgresql 9.4
PHP version: php 5.6
Nextcloud version: 12.0.3
Are you using external storage, if yes which one: no
Are you using encryption: no
Are you using an external user-backend, if yes which one: LDAP
We looked at the source code and we found a issue when using numeric/integer values for 'uid'.
An array of users, groups and contacts is created on every search. Before it is shown to the enduser, the array values are compared in search of duplicated entries. The function "hasUserInResult" isn't working properly when the uid attribute from AD/LDAP is a integer. The problem seems to be that PHP is type casting the LDAP attribute 'uid' from string to integer.
File: /var/www/nextcloud/apps/files_sharing/lib/Controller/ShareesAPIController.php
Example Code to simulate the issue:
Workaround:
The text was updated successfully, but these errors were encountered: