implicitFlowUser not working
See original GitHub issue{ AuthError: Could not log in
at ImplicitFlowUser.run (file:///Users/andreisoroka/git/temp/node_modules/vk-io/lib/index.mjs:1704:17)
at processTicksAndRejections (internal/process/next_tick.js:81:5)
code: 'AUTHORIZATION_FAILED',
name: 'AuthError',
pageHtml: null }
What version of vk-io
are you using?
4.0.0-rc.15
What version of Node.js are you using?
11.11.0
What did you do?
Простая авторизация
import VK from "vk-io";
export default function getToken({login, password}) {
const vk = new VK({
appId: process.env.VK_APP_ID,
login,
password,
});
return vk.auth.implicitFlowUser().run()
}
Залез в код, поставил дебаг, и увидел что падает на странице “разрешить доступ приложению? да/нет” Откатился на версию 4.0.0-rc.7 (какую раньше использовал), все заработало. Итог: бага пришла с обновлением.
What did you expect to happen?
Получение токена
What was the actual result?
Ошибка авторизации
Если не получится воспроизвести, помогу)))
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:6 (3 by maintainers)
Top Results From Across the Web
IdentityServer/IdentityServer4 - Gitter
I have created identity server and deployed it in server. I generated a token from IS and used it to access my api...
Read more >How to use the vk-io.authErrors function in vk-io | Snyk
Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues...
Read more >oauth package - github.com/SevereCloud/vksdk/v2/api/oauth - Go ...
ImplicitFlowUser need to run methods directly from users devices. Access token received this way can not be used for server requests.
Read more >Identity Server 4 Custom Scheme - Stack Overflow
I have users that can authenticate into an SPA that uses the OIDC-Client js lib to interact with my identity server using the...
Read more >Implement stateless authentication like a pro using OAuth
That's why we rarely address problems related directly to ... This post is not meant to answer the “how does the login with...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Исправлено https://github.com/negezor/vk-io/commit/6827a029f86debdb0b883c85f08587c55c2d164a
Тоже ошибка при авторизации.
const script = $('script[type="text/javascript"][language="javascript"]').text();
возвращает пустую строку. хз почему, тег в html подходящий под селектор есть. Для себя сделал хотфикс: Заменилconst script = $('script[type="text/javascript"][language="javascript"]').text();
наconst script = $.html();