Just to clarify: I want the users to self-register, but at the same time I want them to be created disabled / unable to actually access anything. So, I need to figure out where to do that and where to go from there, i.e.: redirect the users to some page that explains it.
And I have in-house developed TOTP registration components that can do webpage, etc. In fact they can do the whole thing start to end. And as Sphinx only does a part of it, I need to figure out where to plug in what I have to fill in the rest of the process. And it's really a three-fold issue:
- Get the secret and pass it to the component that does the webpage.
- Get the user redirected there to do the registration.
- Pass the result back to Sphinx.
With 1), I can see where to get it when the user has just been created, but then I may want to 2FA some specific operations later on, doing my own 2FA, so I need to be able to retrieve that secret at will, from outside of Sphinx. Where is it kept and how do I get to it? Is it / can it be encrypted? Why is there a list of those tokens in Sphinx, how can the same user have more than one?
With 2), I'm at a loss, because I cannot see any network interfaces from where the user creating happens and no way to redirect the browser anywhere. Again, as the user will actually be disabled at this moment, it should not be able to legally proceed anywhere further, but to the TOTP registration.
And with 3), again, how do I pass that back to Sphinx from outside? And would Sphinx do if the registration did not succeed and the user tries to login back? - my thinking is that any so far created artefacts should be cleared, so the user can repeat all this on the next round, without facing a situation where they cannot re-register, because the name already exists, but also cannot sign in, because of missing TOTP registration. And of course I do not want to flash this secret QR code over and over, I want the user to use it immediately, in a controlled fashion, or the whole thing should fail and self-destruct.
Does this make sense?
I'll be facing deep scrutiny from a pack of hungry Cerberuses for this solution, so I need to cover all my bases and know all details and answers...