Difference between revisions of "S/KEY Authentication"

From ArchWiki
Jump to: navigation, search
(Created S/KEY page)
(http -> https://aur.archlinux.org)
Line 6: Line 6:
== Install opie ==
== Install opie ==
From [http://aur.archlinux.org/packages.php aur], install following packages:
From [https://aur.archlinux.org/packages.php aur], install following packages:
  * libpam-opie
  * libpam-opie
  * opie-client
  * opie-client

Revision as of 17:36, 24 March 2012

This guide shows you how you can enable S/KEY one-time password authentication on your Arch.

WARNING! Do following actions on secure connection from a secure computer. A chain is as strong as its weakest link.

Install opie

From aur, install following packages:

* libpam-opie
* opie-client
* opie-server

(As of today 2010-05-17 packages does not seem to support x86_64 but there is posted a fix on comments of opie-client)

Config pam module

In /etc/pam.d tweak config files for wanted logins. I tweaked sshd and sudo. Do the following to selected files:

auth  required  pam_unix.so
change to (note order)-->
auth sufficient pam_unix.so
auth sufficient pam_opie.so

If you want to use SSH, change ChallengeResponseAuthentication to yes in /etc/ssh/sshd_config

Create an OTP key

As your user (no root), run:

# opiepasswd -c

After entering a passphrase you get your OTP key:

ID busk OTP key is 499 fe6839

Get yourself some passwords

# opiekey -n 20 499 fe6839

OR alternative way for Java-enabled mobile phone owners: Get VeJotp, It's free and you can generate passwords on the run.

Now, when you ssh to your box, hit Enter to the password prompt and you will be prompted for onetime password.

This guide is based on [1]