-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot authenticate user from ZFC user table #3
Comments
I'm not sure off-hand what could cause this. There have been updates to zf-oauth2 and ZfcUser since I wrote and last used this module so something may have changed. When I get a chance I'll try setting up a new project myself and see if I can reproduce the issue you're having. |
Hi there, I think I got it. I can share skeleton project later so you can put in as an example if you want. Thank you for your time. |
i run this: added below json in body row data: I am getting this error : { how to remove the issue, please tell me |
Hi, just trying your module and have few quesions.
I set up Apigility, and oAuth2.
I can make POST to /oauth
{"grant_type":"password", "username":"testuser", "client_id":"testclient2", "password":"testpass" }
('testuser' is stored in oauth tables -
oauth_users
) and got response:{"access_token":"e59610ddeab7dd559bcea5e25e46092c7d8f25b1","expires_in":3600,"token_type":"Bearer","scope":null,"refresh_token":"10e6a1769bd133bb766bd87fdea5d86e51d4af1a"}
I believe oauth as is - is working.
I installed zfc user tested /user/login (sing up, login, logout - everything works)
Now I installed LdcZfcUserOAuth2 module, config it by instruction
'zf-oauth2' => array(
'storage' => 'ldc-zfc-user-oauth2-storage-pdo',
'db' => array(
'dsn' => 'mysql:dbname=mydevtest;host=localhost',
'username' => 'mydevtest',
'password' => 'pass',
),
in this step I must add also 'db' because without it I got error "...configuration ['zf-oauth2']['db'] for OAuth2 is missing..."
'auth_adapters' => array( 100 => 'ldc-zfc-user-oauth2-authentication-adapter-db' ),
After that I test POST to /oauth with user/pass combination from ZFCUser (user) table (created in step when testing ZFCUser's /user/login):
{"grant_type":"password", "username":"[email protected]", "client_id":"testclient2", "password":"password"}
and response is:
{"type":"http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html","title":"invalid_grant","status":401,"detail":"Invalid username and password combination"}
If i try user/pass from oauth table it works. It seems that it does NOT look for user/pass from ZFC user table..
Any idea/hint how to solve this?
Thnx
The text was updated successfully, but these errors were encountered: