Skip to content

"AuthForbidden at /complete/battlenet-oauth2/ Your credentials aren't allowed" #1332

@jcugley

Description

@jcugley

Getting the error in the title:

AuthForbidden at /complete/battlenet-oauth2/
Your credentials aren't allowed

I've spent all day trying to figure it out and have come up with nothing 😭

This is the stack trace:

Request Method: GET
Request URL: http://127.0.0.1:8000/complete/battlenet-oauth2/?code=<codewashere>&state=<statewashere>

Django Version: 2.1.3
Python Version: 3.7.0
Installed Applications:
['django.contrib.admin',
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.messages',
 'django.contrib.sessions',
 'django.contrib.sites',
 'django.contrib.staticfiles',
 'django.contrib.humanize',
 'bootstrapform',
 'pinax.templates',
 'account',
 'pinax.eventlog',
 'pinax.webanalytics',
 'social_django',
 'myproject',
 'users',
 'myappname']
Installed Middleware:
('whitenoise.middleware.WhiteNoiseMiddleware',
 'django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.common.CommonMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware',
 'django.middleware.clickjacking.XFrameOptionsMiddleware',
 'account.middleware.ExpiredPasswordMiddleware',
 'account.middleware.LocaleMiddleware',
 'account.middleware.TimezoneMiddleware',
 'django.middleware.security.SecurityMiddleware',
 'social_django.middleware.SocialAuthExceptionMiddleware')



Traceback:

File "D:\Projects\myproject\venv\lib\site-packages\social_core\utils.py" in wrapper
  259.             return func(*args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_core\backends\oauth.py" in auth_complete
  401.             method=self.ACCESS_TOKEN_METHOD

File "D:\Projects\myproject\venv\lib\site-packages\social_core\backends\oauth.py" in request_access_token
  373.         return self.get_json(*args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_core\backends\base.py" in get_json
  238.         return self.request(url, *args, **kwargs).json()

File "D:\Projects\myproject\venv\lib\site-packages\social_core\backends\base.py" in request
  234.         response.raise_for_status()

File "D:\Projects\myproject\venv\lib\site-packages\requests\models.py" in raise_for_status
  940.             raise HTTPError(http_error_msg, response=self)

During handling of the above exception (401 Client Error: Unauthorized for url: https://us.battle.net/oauth/token), another exception occurred:

File "D:\Projects\myproject\venv\lib\site-packages\django\core\handlers\exception.py" in inner
  34.             response = get_response(request)

File "D:\Projects\myproject\venv\lib\site-packages\django\core\handlers\base.py" in _get_response
  126.                 response = self.process_exception_by_middleware(e, request)

File "D:\Projects\myproject\venv\lib\site-packages\django\core\handlers\base.py" in _get_response
  124.                 response = wrapped_callback(request, *callback_args, **callback_kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\django\views\decorators\cache.py" in _wrapped_view_func
  44.         response = view_func(request, *args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\django\views\decorators\csrf.py" in wrapped_view
  54.         return view_func(*args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_django\utils.py" in wrapper
  49.             return func(request, backend, *args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_django\views.py" in complete
  33.                        *args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_core\actions.py" in do_complete
  43.         user = backend.complete(user=user, *args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_core\backends\base.py" in complete
  40.         return self.auth_complete(*args, **kwargs)

File "D:\Projects\myproject\venv\lib\site-packages\social_core\utils.py" in wrapper
  264.                 raise AuthForbidden(args[0])

Exception Type: AuthForbidden at /complete/battlenet-oauth2/
Exception Value: Your credentials aren't allowed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions