@hodyroff
Thanks again for the reply. I'll try to explain here and see what you think.
First off, this is a summary of a current / working scenario that allows for privacy and convenience.
Set the following options:
"Allow username autocompletion in share dialog" = Enabled
"Restrict users to only share with users in their groups" = Enabled
Result:
Now you can have groups of users that are restricted to auto-complete on usernames that are members of their group(s). This gives the end user the auto-complete convenience AND it restricts auto-complete from giving away usernames of other ownCloud users that are not members of the group(s). Great!
Comments:
The only problem at this point is that you can defeat this privacy measure by using the "share via link" feature. In this case all email addresses and usernames are exposed - it's not restricted to the users in your group(s). This is the issue that needs to be resolved.
Problem with current solution to resolve this issue (The GitHub link you brought to my attention):
By using the single option "Allow username autocompletion in share dialog" to globally disable auto-complete it breaks the scenario described above. i.e. If "Allow username autocompletion in share dialog" is disabled, in the scenario above you cannot use autocomplete - even for users in your own groups.
The result is that you lose a ton of convenience for sharing inside of ownCloud (not having to type in full usernames) to restrict email address auto-completion for the share via link.
I don't think this good.
A Better solution:
Add a new admin option that specifically handles email auto-complete for the "Share via Link" feature. The 2 mandatory options would be:
1). Global enable for auto-complete (the way it works now - the default)
2). Global disable auto-complete
and/or possibly a 3rd option - A sub-option under the existing "Allow users to share via link" option
3). Restrict email auto-complete to users in thier groups
--
Please let me know if this doesn't make sense. I know it's a lot of reading. Sorry about that!