Settings for gdm3 are done in /usr/share/gdm/greeter.dconf-defaults.
Uncomment these 2 lines:
[org/gnome/login-screen]
disable-user-list=true
(Only un-commenting the 2nd line will crash your login: bugreport confirming it works for 18.04) and restart the login manager with
sudo dpkg-reconfigure gdm3
and reboot (or restart with sudo systemctl stop gdm and log out).
Make a backup 1st so in case something get messed up and you can not log in you can use tty3 to redo your changes. edit: this wont work; gdm also takes care of the tty sessions so tty3 is dead too... you will need to user a live session or grub rescue prompt.
Another way that works for 17.10 and 18.04 (from comment #7 by fprietog in the bug report):
Using root:
Create a file named /etc/dconf/profile/gdm with this contents:
user-db:user
system-db:gdm
Create a file named /etc/dconf/db/gdm.d/50-disable-user-list with this content:
[org/gnome/login-screen]
disable-user-list=true
Execute the command sudo dconf update
org/gnome/login-screen/disable-user-listbut that didn't help. – lonix May 17 '18 at 07:03