|Summary:||User not shown at login screen in certain conditions|
|Product:||accountsservice||Reporter:||Felix Zhang <fezhang>|
|Component:||general||Assignee:||Matthias Clasen <mclasen>|
|Status:||RESOLVED FIXED||QA Contact:|
|Priority:||medium||CC:||marius.vollmer, rstrode, stefw, xwang, yfjiang|
|i915 platform:||i915 features:|
|Attachments:||A proposed patch.|
Description Felix Zhang 2018-06-13 05:43:02 UTC
The issue is found updating SUSE Linux Enterprise 11 SP4 to SLE 15, when some users are not shown in the user list of the login screen. Thanks to my colleague Xiaoguang Wang, he spotted that in /etc/passwd the missing users are listed after user "sshd", a user who has no entry in /etc/shadow. Seemingly from what I read, due to the "sshd" user created before the shadow file. A glance at the code shows that, when the accountsservice daemon loads users entry by entry from /etc/passwd, if the user found missing from /etc/shadow, it quits the iteration and ignores all /etc/passwd entries after this user. Which explains the issue above and doesn't seem quite right. Attached is a small patch to fix this issue, works fine on my machine.
Comment 1 Felix Zhang 2018-06-13 05:45:15 UTC
Created attachment 140142 [details] [review] A proposed patch.
Comment 2 Ray Strode [halfline] 2018-06-13 16:44:51 UTC