Page MenuHomeVyOS Platform

login: removing and re-adding a user keeps the home directory but changes the UID, thus SSH keys no longer work
Closed, ResolvedPublicBUG

Description

cpo@LR1.wue3:/home$ ls -al
total 16
drwxr-xr-x 1 root root  4096 Dec 29 09:23 .
drwxr-xr-x 1 root root  4096 Dec 29 09:27 ..
drwxr-xr-x 4 1002 users 4096 Dec 29 09:23 cpo
drwxr-xr-x 3 vyos users 4096 Dec 29 09:26 vyos
cpo@LR1.wue3:/home$ id
uid=1004(cpo) gid=100(users) groups=100(users),4(adm),6(disk),27(sudo),30(dip),102(vyattacfg),114(_kea),116(frrvty),117(frr)

After deleting the cpo user account and working with the "new" added vyos account, I can see that after rebooting in the previously saved configuration (which had the cpo user but not vyos will re-add the cpo user but keep the old homedir with its previous owner UID.

Details

Version
1.4.0-rc1
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Event Timeline

c-po claimed this task.
dmbaturin renamed this task from login: removing and re-adding a user keeps the home directory but UID will change, thus SSH keys no longer work to login: removing and re-adding a user keeps the home directory but changes the UID, thus SSH keys no longer work.May 11 2024, 5:59 PM