I created a little POC[1] for using the YubiKey[2] two factor authentication with statusnet (got a YubiKey recently for my bday :) It's very manual plugin right now, but I've ran into some obstacles that I want to discuss before changing anything in core to get the hooks that I may need.
The tabs for the login and settings pages seem to be full now, so adding a another to each would be ugly. But for my plugin I'm not sure where these things should go. I could have another page just for Yubi auth. Alternatively I could add a hook (not sure where) to the login for any auth, if a user has a yubi key set then grab them and redirect (similar to how OpenID is working). This ultimately may be the best approach as to cover all Auth plugins (so openid/twitter/etc can have 2 factor auth too) For adding content to pages the showContent (the actual inner content) doesnt have a hook (lib/action.php:609), maybe for performance reasons. I've done and seen people use showXXXFormData to append/prepend data to a settings page/registration page/etc. So is this the right way to do things? or should we globally over ride the Action::showContent to insert ourselves (if you want to get into a <form> this wont work). Or maybe both in some cases where you need to prepend a form and or add a whole new section to a page. You can see my initial code on using both here: http://github.com/erichelgeson/Yubikey-Statusnet-Plugin/blob/master/sn-new-events.patch Thanks, -Eric [1] http://github.com/erichelgeson/Yubikey-Statusnet-Plugin [2] http://www.yubico.com/ _______________________________________________ StatusNet-dev mailing list StatusNet-dev@lists.status.net http://lists.status.net/mailman/listinfo/statusnet-dev