I
I
Infactum2014-02-01 18:35:00
JavaScript
Infactum, 2014-02-01 18:35:00

OAuth VK and passportjs

I'm trying to make authorization via OAuth vkontakte for my application on nodejs.
I am using the passportjs module and passport-vkontakte.
It seems to be a very simple example: the code completely repeats help , APP_ID and APP_SECRET copied from the settings of the newly created application. When I try to login I get:

{"error":"invalid_request","error_description":"Security Error"}

I suggested that it could be in the "Site Addresses" settings in the properties of the vk application. Tried different variations. Now it looks like http://localhost:3000/auth/vkontakte/callback.
What could be the gap?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
mirror13, 2015-03-26
@mirror13

I was helped by updating the session in VK: https://vk.com/topic-17680044_30635058

Y
Yaroslav, 2014-02-01
@frantic

You do not understand the essence of OAuth2 authorization. You need your application to be accessible from the outside. Since it will receive requests from the social network. The contact doesn't know where he is http://localhost:300...
Here more about OAuth2
www.itlessons.info/php/auth-with-oauth2-in-vk-mail...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question