bassmaster187 / TeslaLogger

TeslaLogger is a self hosted data logger for your Tesla Model S/3/X/Y. Actually it supports RaspberryPi 3B, 3B+, 4B, Docker and Synology NAS.
https://www.teslalogger.de
GNU General Public License v3.0
519 stars 171 forks source link

Authentication Error - 403 Forbidden #823

Open cybercrez opened 2 years ago

cybercrez commented 2 years ago

Hello,

When i try to get the access token on debug with visual studio, i have an error 403 Forbidden.

Thank for help

Request

Method: POST, RequestUri: 'https://auth.tesla.com/oauth2/v3/authorize?client_id=ownerapi&code_challenge=MGYwZmMyYzdmMGJjMWU2YzQ2YWJjMzBhZGMyMWRjMzhmZjZiNjVhNDkxNDE3MTA0NWFlNzczNTlmYmU2MAAAAA%3d%3d&code_challenge_method=S256&redirect_uri=https%3a%2f%2fauth.tesla.com%2fvoid%2fcallback&response_type=code&scope=openid+email+offline_access&state=0dbjo8k2iupvbuepojb2', Version: 1.1, Content: System.Net.Http.FormUrlEncodedContent, Headers: { User-Agent: Mozilla/5.0 User-Agent: (Windows NT 10.0; Win64; x64) User-Agent: AppleWebKit/537.36 User-Agent: (KHTML, like Gecko) User-Agent: Chrome/93.0.4577.63 User-Agent: Safari/537.36 x-tesla-user-agent: TeslaApp/3.4.4-350/fad4a582e/android/8.1.0 Accept: text/html Accept: application/xhtml+xml Accept: application/xml; q=0.9 Accept: image/avif Accept: image/webp Accept: image/apng Accept: /; q=0.8 Accept: application/signed-exchange; v=b3; q=0.9 Connection: keep-alive Referer: https://auth.tesla.com/oauth2/v3/authorize?client_id=ownerapi&code_challenge=MGYwZmMyYzdmMGJjMWU2YzQ2YWJjMzBhZGMyMWRjMzhmZjZiNjVhNDkxNDE3MTA0NWFlNzczNTlmYmU2MAAAAA%3d%3d&code_challenge_method=S256&redirect_uri=https%3a%2f%2fauth.tesla.com%2fvoid%2fcallback&response_type=code&scope=openid+email+offline_access&state=0dbjo8k2iupvbuepojb2&login_hint=XXXXXXXXX%40XXXXXXXX.XXX Content-Type: application/x-www-form-urlencoded Content-Length: 161 } Content { _csrf=YLHL6ZIm-rxf1wyDocjnncrDBi2Ak-zwW8BI&_phase=authenticate&cancel=1&transaction_id=xZPXs3GF&_process=1&identity=XXXXXXXXX%40XXXXXXXX.XXX&credential=XXXXXXXXXXXXX }

Result

StatusCode: 403, ReasonPhrase: 'Forbidden', Version: 1.1, Content: System.Net.Http.StreamContent, Headers: { Mime-Version: 1.0 X-Reference-Error: 18.d2e24817.1653837394.1ec04a35 Connection: close Permissions-Policy: interest-cohort=() Date: Sun, 29 May 2022 15:16:34 GMT Server: AkamaiGHost Content-Length: 296 Content-Type: text/html Expires: Sun, 29 May 2022 15:16:34 GMT }

bassmaster187 commented 2 years ago

Are you trying to get an access token with email & password?

AlanLopez22 commented 2 years ago

I have the same issue, did you fix it? and yes I am using email and password