Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Login form has no hooks #2436
I spent a little time looking around to see how one might go about implementing a plugin to provide multi-factor authentication (as requested in #2434) or OpenID login (I have a WordPress plugin that consumes OpenID), for example. In the process, I could not find any way for plugins to add fields on the login form.
Perhaps YOURLS doesn't need quite as many hooks as WordPress has, but I do think at least one injection point (below username & password, but above the submit button) would be useful. A plugin implementing two-factor auth would add a field there asking for the TOTP code (for example); a plugin implementing OpenID as a consumer would add, say, "or" and a field for the user's OpenID URL.
Per usual, before I actually get into any code, I'd like to flesh out exactly what hooks are appropriate. We can copy WordPress's hook name
Left to my own devices, I'd implement the first two (
Completely open to add as many hooks as needed, if needed, anywhere. Regarding the login form,