Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't login to account with login and password #505

Open
internetrvze opened this issue Apr 29, 2024 · 3 comments
Open

Can't login to account with login and password #505

internetrvze opened this issue Apr 29, 2024 · 3 comments

Comments

@internetrvze
Copy link

internetrvze commented Apr 29, 2024

При попытке войти в аккаунт ВК по логину паролю мне выбрасывает ошибку:

vk_api.exceptions.AuthError: Unknown API auth error

При этом с авторизацией по токену модуль работает штатно.

Окружение

OS: Windows 11 (23H2)
Python: 3.12.1
vk_api: 11.9.9
API: 5.131

Пример

from vk_api import VkApi

login = input('[-] Enter login: ')
password = input('[-] Enter password: ')

def auth():
    return input('[-] Enter 2FA code: '), True

session = VkApi(
    login, password, 
    auth_handler=auth,
    api_version='5.131', 
    app_id=2685278  # Ошибка происходит всегда, вне зависимости от установленного APP ID
)
session.auth()

api = session.get_api()
[-] Enter login: +71234567890
[-] Enter password: password
[-] Enter 2FA code: 816405
Traceback (most recent call last):
  File "C:\Users\rvze\Desktop\vk.py", line 15, in <module>
    session.auth()
  File "C:\Users\rvze\AppData\Local\Programs\Python\Python312\Lib\site-packages\vk_api\vk_api.py", line 187, in auth
    self._auth_cookies(reauth=reauth)
  File "C:\Users\rvze\AppData\Local\Programs\Python\Python312\Lib\site-packages\vk_api\vk_api.py", line 218, in _auth_cookies
    self._api_login()
  File "C:\Users\rvze\AppData\Local\Programs\Python\Python312\Lib\site-packages\vk_api\vk_api.py", line 516, in _api_login
    raise AuthError('Unknown API auth error')
vk_api.exceptions.AuthError: Unknown API auth error
@waslost0
Copy link
Contributor

@internetrvze Можешь попробовать мои изменения #506

@waslost0 waslost0 mentioned this issue May 14, 2024
@internetrvze
Copy link
Author

@internetrvze Можешь попробовать мои изменения #506

image

@M1h4n1k
Copy link

M1h4n1k commented May 29, 2024

Вот эта не работает?
https://github.com/M1h4n1k/vk_api_fix_auth

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants