I’m trying to write a small plugin that will do some bespoke authentication/authorisation.
I’ve managed to extend ‘hudson.security.SecurityRealm’ and can now successfully write a simple authenticator plugin.
My issue is that there is an MFA step which requires notifying the user of a two digit code (microsoft authenticator app).
So while I’m in the ‘authenticate(Authentication authentication)’ method I wan to alert the user.
I though at first about adding some ajax to the ‘loginLink.jelly’
But then I realised that Jenkins has the two notification icons near the login link (the warning, and info icons).
How can I notify the user in real time? Is there a mechanism for this I can just use already?