<div class="gmail_quote">On Wed, Feb 17, 2010 at 3:17 AM, Alessandro Bottoni <span dir="ltr"><<a href="mailto:alexbottoni@yahoo.it">alexbottoni@yahoo.it</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

Il 16/02/2010 22:20, Marc Weber ha scritto:<br>
<div class="im">> Excerpts from Alessandro Bottoni's message of Tue Feb 16 10:46:26 +0100 2010:<br>
>> Hi All,<br>
>> I'm looking for a way (a module, a technique) to perform the usual<br>
>> (local) Linux-PAM authentication on a per-user basis. That is: I need to<br>
>> have a different authentication stack for each user of a Linux machine.<br>
> Maybe you should talk about the real problem you're trying to solve as<br>
> well. Maybe there is another simple solution to get your job done?<br>
<br>
</div>Hi Marc,<br>
well, actually, I'm trying to answer a quite strange request in the most<br>
elegant way I can.<br>
<br>
I have to configure a Ubuntu server in such a way that two different<br>
users will be able to authenticate in the following two different ways.<br>
<br>
1) A "local" user should be able to authenticate at the local/physical<br>
console using a two-factors scheme based on pam_usb (username, password<br>
and a USB flash memory). The USB flash memory will be used as a cheap ID<br>
token.<br>
<br>
2) A "remote" user should be able to authenticate via Internet (via<br>
telnet/ssh or even via VNC/NX) using a two-factors scheme based on<br>
pam_obc (username, password and a one-time password sent to the user's<br>
cellphone via SMS using sendEmail and a free email/SMS gateway). That<br>
is: the SIM of the cellphone will be used as a commodity ID token.<br>
<br>
(Both users will be sudoers and the root account will be disabled, as<br>
usual on Ubuntu)<br>
<br>
The customer explicitly asked for a two-factors (password plus physical<br>
element) strong authentication so SSH alone is not enough (at least, as<br>
long as I know). Before falling back to Aladdin's eToken, Yubico's<br>
Yubikey or RSA SecurID I would like to try a cheaper and more manageable<br>
solution based on COTS components (USB keys and GSM cellphones).<br>
<br>
To be honest, the "local" and "remote" user could be merged in a single<br>
"generic" profile. We just do not want to send the useless email/SMS<br>
message when the user authenticates locally using the USB key (and, of<br>
course, the system must not ask a remote user for his USB key).<br>
<br>
Maybe it is possible to user either pam_usb or pam_obc on the same user,<br>
playing with the order of the configuration lines in the common-auth<br>
file and/or with the "controls" ("requisite", "required", "sufficient",<br>
"optional", etc.). I did not try yet...<br>
<br>
Any suggestion?<br></blockquote><div><br>I may be missing something, but it seems to me that you can set /etc/pam.d/login to use pam_usb and then set /etc/pam.d/sshd to use radius or whatever method you'd like for remote access, correct?<br>

 </div></div>-- <br>Nick Owen<br>WiKID Systems, Inc.<br>404.962.8983<br><a href="http://www.wikidsystems.com">http://www.wikidsystems.com</a><br>Commercial/Open Source Two-Factor Authentication<br>