formapro / FpOpenIdBundle

Symfony2 OpenID security extension
53 stars 31 forks source link

2.1 branch #15

Closed quba closed 12 years ago

quba commented 12 years ago

Should I wait or fork it and do it on my own?

makasim commented 12 years ago

There is a working branch for 2.1: https://github.com/arnaud-lb/FpOpenIdBundle/tree/factories-bc-break . Is it what you need?

If there will be any other changes for 2,1 I will create a branch 2.1.

quba commented 12 years ago

Ok, sorry. I didn't see it earlier.

One other thing. Im not really satisfied with the way how this bundle handles login. Generally after successfully authentication we should redirect to the login_check route with openid_approvedset to true. But there are still errors, so as far as I know people are manually setting new token to the security context and then redirect for example to the homepage.

Couldn't it by done like nic fosfacebook bundle? So we have another section in firewall and it really looks nice. And we have no problems with redirects to specific places after login (example: trying to get to path (for example /profile) which requires ROLE_USER. Symfony redirects me to the login page and after successful login, symfony redirects me automaticly to the /profile path).

Im quite new in symfony, so now I can only suggest some things. I dont know if this proposed solution is right. Sorry for this "little" offtopic.

            form_login:
                provider: fos_userbundle
                login_path: /login
                default_target_path: homepage
            fos_facebook:
                login_path: /login
                check_path: /facebook/login_check
                default_target_path: homepage
                provider: my_fos_facebook_provider
makasim commented 12 years ago

I don`t like the way the bundle work either (:. I want to redesign the bundle but any of my attempts I like so it stays as is.

About redirections: It should work as you want if you use workflow from the manual but as you said it led you to errors. Yes it is not working if you set the token manually in approve action.

There is a section called openid (like fos_facebook) in secured_area. as far as I know you can configure there all that stuff.