Jeff Layton writes:
cifscreds add is more or less equivalent to a command like this:
$ keyctl add logon cifs:a:ip_address 'username:password' @s
There seems to be a general problem with adding keys (@s) to the default
"session" keyring. Adding user type keys (@u) works.
$ keyctl add logon description data @s
does not add anything to the _uid_ses:UID keyring, which is automatically
created after login.
Interestingly, when a new session keyring is added, then it works:
[root@client ~]# su - zmrzlinka
[zmrzlinka@client ~]$ keyctl show
Session Keyring
1037083570 --alswrv 1001 -1 keyring: _uid_ses.1001
578017679 --alswrv 1001 -1 \_ keyring: _uid.1001
[zmrzlinka@client ~]$ cifscreds add toillet
Password:
[zmrzlinka@client ~]$ keyctl show
Session Keyring
1037083570 --alswrv 1001 -1 keyring: _uid_ses.1001
578017679 --alswrv 1001 -1 \_ keyring: _uid.1001
[zmrzlinka@client ~]$ keyctl session new-session
Joined session keyring: 871855811
[zmrzlinka@client ~]$ keyctl show
Session Keyring
871855811 --alswrv 1001 100 keyring: new-session
[zmrzlinka@client ~]$ cifscreds add toillet
Password:
[zmrzlinka@client ~]$ keyctl show
Session Keyring
871855811 --alswrv 1001 100 keyring: new-session
244698182 ----sw-v 1001 100 \_ logon: cifs:a:192.168.1.3
Milan
--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html