Hello,
I m stuck at getting response from this url:
https://www.themoviedb.org/authenticate/request_token?redirect_to=http://www.google.com
as in Android we cant access header of webview & can i know why https://api.themoviedb.org/3/authentication/token/validate_with_login is strongly discouraged?
Please help ASAP
Thank you
Non podes atopar unha película ou serie? Inicia sesión para creala.
Queres valorar ou engadir o elemento a unha listaxe?
Non es membro?
Resposta de Travis Bell
no 16 de xaneiro do 2018 ás 1:27PM
Hi @Faiyyaz17,
Validating with your login exposes your username and password over the air. Even though you can SSL, it's still not that secure since it's a GET method with query parameters.
There's no way to access the response headers from a webview?
Resposta de Chris Krueger
no 17 de xaneiro do 2018 ás 7:06AM
You can access the response with WebView.
Build and load your auhorization URI. For example in version 3:
Instantiate WebView and set a WebViewClient. Handle your URI in shouldOverrideUrlLoading. You don't need a matcher if you have only one URI redirection. Check the approve parameter and handle the response request token.
I strongly recommend Chrome Custo mTab for auhentification. Chrome Custom Tabs give apps more control over their web experience, and make transitions between native and web content more seamless without having to resort to a WebView.
Here is a good explanation:
This GitHub project helps for your implemenation:
Another GitHub OAuth sample: