# Desculpe, ocorreu um erro ao autorizar sua conta

**URL:** <https://meta.discourse.org/t/sorry-there-was-an-error-authorizing-your-account/112229>\
**Category:** SSO\
**Tags:** oauth2\
**Created:** [Março 21, 2019, 8:51am UTC](https://meta.discourse.org/t/sorry-there-was-an-error-authorizing-your-account/112229 "2019-03-21T08:51:24Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![Wurzelseppi](https://avatars.discourse-cdn.com/v4/letter/w/eada6e/32.png) [@Wurzelseppi](https://meta.discourse.org/u/Wurzelseppi)\
**Post date:** [Março 21, 2019, 8:51am UTC](https://meta.discourse.org/t/sorry-there-was-an-error-authorizing-your-account/112229/1 "2019-03-21T08:51:24Z")

</div>

Hi there,  
I´m working for a big company and I´m using an internal oauth2 provider in conjunction with this plugin. In a different business unit there is already another discourse instance running, where the same setup works. I analyzed their instance, and found almost nothing except a version difference of the plugin and of discourse itself.  
But first of all I´ll tell you what happens.  
I set up the plugin and configured everything according to documentation (the same as the other instance plus some settings, which aren´t available in the old version (0.2) of the plugin which they are using.

No I see the extra button in login screen and get forwarded to a login page (company) where I can type in my SSO account & pw…  
After pressing enter this screen appears:

 ![image](https://global.discourse-cdn.com/meta/original/3X/5/1/51d15ee0615cb3a067ccd363da84a58eeec44b8b.png)

The logs show this:

```
(oauth2_basic) Authentication failure! invalid_credentials: OAuth2::Error, invalid_client: Invalid authentication method for accessing this endpoint.
{"error_description":"Invalid authentication method for accessing this endpoint.","error":"invalid_client"}

```

I double checked the credentials and talked with the guys of web-eam support, and they said the authorization phase was succcessful (I got valid return parameters (code, iss, state) with the callback call)

Anyone knows how to approach this problem ?

My versions are:

Discourse: v2.3.0.beta5 +5  
oauth-basic plugin: 0.3

Many thanks in advance and greetings,

Wurzelseppi

---

_[View the full topic](https://meta.discourse.org/t/sorry-there-was-an-error-authorizing-your-account/112229)._
