Minor: if input OTP is empty and password looks like OTP, now copies password to OTP in memory and treats password field as OTP. Will require patch in Enano trunk to work for html login.
--- a/plugins/yubikey/auth.php Thu Feb 26 01:13:25 2009 -0500
+++ b/plugins/yubikey/auth.php Thu Feb 26 01:19:45 2009 -0500
@@ -19,6 +19,12 @@
$auth_log_prefix = ( $level >= USER_LEVEL_CHPREF ) ? 'admin_' : '';
+ // Sort of a hack: if the password looks like an OTP and the OTP field is empty, use the password as the OTP
+ if ( empty($userdata['yubikey_otp']) && preg_match('/^[cbdefghijklnrtuv]{44}$/', $userdata['password'] ) )
+ {
+ $userdata['yubikey_otp'] = $userdata['password'];
+ }
+
if ( !empty($userdata['username']) )
{
// get flags