# HG changeset patch # User Dan # Date 1236009411 18000 # Node ID 65965da01c41b2863afc783bb9a9d0cf0e69846f # Parent 032ca892b9a21a628a958d18812000de672276b6 If yubikey_reg_require_otp is 1, opening login window now auto-opens Yubikey prompt diff -r 032ca892b9a2 -r 65965da01c41 plugins/yubikey/corelib.php --- a/plugins/yubikey/corelib.php Sun Mar 01 21:45:44 2009 -0500 +++ b/plugins/yubikey/corelib.php Mon Mar 02 10:56:51 2009 -0500 @@ -177,5 +177,7 @@ $template->add_header(''); $template->add_header(''); + // config option for all users have yubikey + $template->add_header(''); } diff -r 032ca892b9a2 -r 65965da01c41 plugins/yubikey/yubikey.js --- a/plugins/yubikey/yubikey.js Sun Mar 01 21:45:44 2009 -0500 +++ b/plugins/yubikey/yubikey.js Mon Mar 02 10:56:51 2009 -0500 @@ -252,6 +252,13 @@ $('#messageBoxButtons input:button:first').focus(); $('#ajax_login_field_captcha').focus(); }); + if ( window.yk_reg_require_otp ) + { + setTimeout(function() + { + yk_mb_init(yk_login_validate_reqs); + }, 750); + } tr.appendChild(td); table.appendChild(tr); }