FpOpenIdBundle icon indicating copy to clipboard operation
FpOpenIdBundle copied to clipboard

Need explanation as to what route 'fp_openid_security_check' is

Open dotstormz opened this issue 13 years ago • 4 comments

Hi,

I am attempting to implement openid with FOSUserBundle.

In the finishOpenIdLoginAction() method in the SecurityController the finishOpenIdLogin.html.twig template creation is obvious, however the 'fp_openid_security_check' route upon success is not explained anywhere. Is this just meant to post back to itself, or is there some code missing from the documentation for this route?

Thanks in advance@

dotstormz avatar Jan 28 '13 07:01 dotstormz

You would come to finishOpenIdLoginAction only when you have AuthenticatedException. The exception was thrown while processing openid provider response.

  • It could be OpenIdAuthenticationCanceledException if the user canceled login at provider side.
  • Some other exceptions could be thrown from UserProvider if it failed.

You would like to recover second types of errors (those come from UserProvider). So you have to create a user. After you can ask security to check auth credentinals one more time, and be able to finish the auth successfully. The result of success auth: you have SecurityContenxt populated with OpenIdToken token

makasim avatar Jan 28 '13 08:01 makasim

Can you give an example of this check in the documentation?

dotstormz avatar Feb 04 '13 09:02 dotstormz

for example... how is RecoveredFailureRelyingParty::RECOVERED_QUERY_PARAMETER => 1 used?

dotstormz avatar Feb 04 '13 09:02 dotstormz

Can you give an example of this check in the documentation?

good idea.

for example... how is RecoveredFailureRelyingParty::RECOVERED_QUERY_PARAMETER => 1 used?

I dont think it should be explained. It is more like internals and for basic usage it is enough to tell what should you return. It is possible to look at the class RecoveredFailureRelyingParty if someone want to dive in.

makasim avatar Feb 04 '13 10:02 makasim