<div dir="ltr">If you help me I will be ready to complete this task, but you should be prepared to answer many questions ;)<div><br></div><div><br></div><div>Denis.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-03-20 17:12 GMT+03:00 Corinne Krych <span dir="ltr"><<a href="mailto:corinnekrych@gmail.com" target="_blank">corinnekrych@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Denis<br>
<br>
Taking a closer look, VK.com implement the “client credential grant” OAuth2 flow.<br>
We don’t support it yet in ag-ios-oauth2 but there is a JIRA ticket for it [1] and [2] for its demo (planned for 2.4.0 release - end of May).<br>
<br>
Here is a short explantion of the Oauth2 grant flow (extracted from one of my blog):<br>
Four different flows are part of the spec, you can group them in two different families:<br>
- 3-legged flow: where end-user need to grant permission. The _implicit grant_ is for browser-based app not capable of keeping tokens secure. The _authorization code grant_ which generates an access and (optionally a refresh token) is for client capable of keeping secret.<br>
- 2-legged flow: where the credentials are given to the app. The key difference, compared to 3 legged-flow, is that the consumer is not requesting access to any user data. Instead, it is creating an account with the service provider with no previous data in it at all, therefore the grant flow can be skipped.<br>
<br>
Here is the challenge: would you like to do the PR for this jira?<br>
I’ll be glad to help you to implement client credential grant for aerogear-ios-oauth2 lib.<br>
<br>
++<br>
Corinne<br>
[1] <a href="https://issues.jboss.org/browse/AGIOS-191" target="_blank">https://issues.jboss.org/browse/AGIOS-191</a><br>
[2] <a href="https://issues.jboss.org/browse/AGIOS-196" target="_blank">https://issues.jboss.org/browse/AGIOS-196</a><br>
<div class="HOEnZb"><div class="h5"><br>
> On 20 Mar 2015, at 14:24, Corinne Krych <<a href="mailto:corinnekrych@gmail.com">corinnekrych@gmail.com</a>> wrote:<br>
><br>
> Hello Denis,<br>
><br>
> I’ve just submitted a PR to support web view, but you still need a custom URL for it[1].<br>
><br>
> Googling around I found:<br>
> <a href="https://vk.com/dev/ios_sdk" target="_blank">https://vk.com/dev/ios_sdk</a><br>
> <a href="https://github.com/VKCOM/vk-ios-sdk" target="_blank">https://github.com/VKCOM/vk-ios-sdk</a><br>
> It seems VK is using same convention that Facebook: Enter vk+APP_ID for the custom url<br>
><br>
> ++<br>
> Corinne<br>
> [1] <a href="https://github.com/aerogear/aerogear-ios-oauth2/pull/25" target="_blank">https://github.com/aerogear/aerogear-ios-oauth2/pull/25</a><br>
><br>
>> On 20 Mar 2015, at 09:39, Денис Карпенко <<a href="mailto:banddk1@gmail.com">banddk1@gmail.com</a>> wrote:<br>
>><br>
>> Thank you Summers and Corinne,<br>
>> Safari opens URL and I suppose it can be problem ) However I'll try to make something with WebView)<br>
>><br>
>> Denis.<br>
>><br>
>> 2015-03-19 22:29 GMT+03:00 Corinne Krych <<a href="mailto:corinnekrych@gmail.com">corinnekrych@gmail.com</a>>:<br>
>> It's worth investigating on UIWebView indeed, i'll give a go tomorrow as i'm working on AGIOS-414 provide webview option.<br>
>> ++<br>
>> Corinne<br>
>><br>
>> On Thursday, March 19, 2015, Summers Pittman <<a href="mailto:supittma@redhat.com">supittma@redhat.com</a>> wrote:<br>
>> On Android the webview dialog checks the address before it makes the request and if it matches the redirect will forward the codes back to the application. Perhaps you could use something similar for the other platforms?<br>
>><br>
>> On Thu, Mar 19, 2015 at 12:59 PM, Денис Карпенко <<a href="mailto:banddk1@gmail.com">banddk1@gmail.com</a>> wrote:<br>
>> Hello everyone,<br>
>> I am trying to add special config for VK in OAuth2 library, but I get stuck in a rut. VK doesn't allow make redirect URI without ( http:// or https://) so I can't send authorization token into application using URL schemes( because I need use something like "applicationName://". Did anyone encounter a similar problem ? How can I solve this problem?<br>
>><br>
>> P.S VK also doesn't have refresh tokens. VK begins to to irritate me :)<br>
>><br>
>> Denis.<br>
>><br>
>> _______________________________________________<br>
>> aerogear-dev mailing list<br>
>> <a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
>> <a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
>><br>
>><br>
>> _______________________________________________<br>
>> aerogear-dev mailing list<br>
>> <a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
>> <a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
>><br>
>> _______________________________________________<br>
>> aerogear-dev mailing list<br>
>> <a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
>> <a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br>
><br>
<br>
<br>
_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a></div></div></blockquote></div><br></div>