# Access is denied due to invalid credentials. Please check the authentication parameters

**URL:** <https://community.sonarsource.com/t/access-is-denied-due-to-invalid-credentials-please-check-the-authentication-parameters/94500>\
**Category:** SonarQube Server / Community Build\
**Tags:** dotnet\
**Created:** [June 22, 2023, 12:35pm UTC](https://community.sonarsource.com/t/access-is-denied-due-to-invalid-credentials-please-check-the-authentication-parameters/94500 "2023-06-22T12:35:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rbasniak](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rbasniak/32/46498_2.png) [@rbasniak](https://community.sonarsource.com/u/rbasniak)\
**Post date:** [June 22, 2023, 12:35pm UTC](https://community.sonarsource.com/t/access-is-denied-due-to-invalid-credentials-please-check-the-authentication-parameters/94500/1 "2023-06-22T12:35:51Z")

</div>

Hi,

I want to try SonarQube so I followed the installation steps and I have it running (v10.0.0.68432).

My project is a .NET Framework project, so I downloaded `sonar-scanner-msbuild-5.13.0.66756-net46`

Then I created a local project in Sonar and tried to analyse the project locally.

Sonar created a token and gave the command line to run the analysis:

`SonarScanner.MSBuild.exe begin /k:"test-project" /d:sonar.host.url="http://localhost:9000" /d:sonar.token="sqp_e3c63b69f79d19879f53f88ae62bfcb755746fe5"`

When I run this I get the following output:

`SonarScanner for MSBuild 5.13`  
`Using the .NET Framework version of the Scanner for MSBuild`  
`Pre-processing started`  
`Preparing working directories...`  
`Unauthorized: Access is denied due to invalid credentials. Please check the authentication parameters.`  
`Pre-processing failed. Exit code: 1`

I tried this using both Sonar on Docker and installed locally. I confirmed the token exists in Sonar. I also tried using a user token instead of a project token and I always get the same output.

How can I diagnose this?

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [June 23, 2023, 4:04pm UTC](https://community.sonarsource.com/t/access-is-denied-due-to-invalid-credentials-please-check-the-authentication-parameters/94500/2 "2023-06-23T16:04:35Z")

</div>

Hi,

Welcome to the community!

I’m going to assume you’ve already revoked and replaced the permissions token you just published to the internet. 😃

Regarding your question…

- The first thing I would try is removing the quotes. There are no spaces and no special characters, so they shouldn’t be needed, and I’m not confident they would be stripped automatically
- Next, if you’ve already validated that the token value is correct (no copy/paste flubs) then I would check that the user the token is from has rights to analyze the project.

If neither of those works, come back to us and… we’ll see what else we can figure out.

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![rbasniak](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rbasniak/32/46498_2.png) [@rbasniak](https://community.sonarsource.com/u/rbasniak)\
**Post date:** [July 11, 2023, 6:53pm UTC](https://community.sonarsource.com/t/access-is-denied-due-to-invalid-credentials-please-check-the-authentication-parameters/94500/3 "2023-07-11T18:53:54Z")

</div>

Hi, thanks for the reply. What actually happened is that I needed to unblock the downloaded zip of SonarQube. Since the zip file opened normally, I assumed that Windows didn’t block anything.
