2

After the user's authorization, i'm redirected back to my application with authorization code, but when i asked for access grant in exchange of authorization code i'm getting connection timeout error. Facebook is not responding

AccessGrant accessGrant =auth2Operations.exchangeForAccess(code, "my redirect url", null);

please help me. Thanks in advance.

laaposto
  • 11,835
  • 15
  • 54
  • 71
rrk
  • 21
  • 2
  • Are you using the same redirect URL as in the first step of the authentication, i.e., in user's authorization? – Rafa Romero Jul 17 '14 at 10:38
  • 2
    No, i didn't at first but now i corrected it by having same url, and also i have added the proxy url and port, Now its working... System.setProperty("http.proxyHost","192.168.2.41"); System.setProperty("http.proxyPort", "3128"); – rrk Jul 18 '14 at 05:30

1 Answers1

0

You should use the same URLCallback in all the steps of oAuth authentication process. If not, you will receive an error from Facebook

Rafa Romero
  • 2,667
  • 5
  • 25
  • 51
  • Please have a look at this http://stackoverflow.com/questions/24817775/error-when-creating-bean-for-connection-repository-in-spring-social-facebook-con – rrk Jul 18 '14 at 07:11