Skip to content

feat: Entra/Intune device authentication as a new peer-registration method#5977

Open
thvevirtue wants to merge 19 commits into
netbirdio:mainfrom
thvevirtue:feature/entra-device-auth
Open

feat: Entra/Intune device authentication as a new peer-registration method#5977
thvevirtue wants to merge 19 commits into
netbirdio:mainfrom
thvevirtue:feature/entra-device-auth

entra_device: address CodeRabbit review round 1

07bf8cf
Select commit
Loading
Failed to load commit list.
SonarQubeCloud / SonarCloud Code Analysis failed Apr 24, 2026 in 37s

Quality Gate failed

Failed conditions
10 New issues
2 Security Hotspots
10 New Code Smells (required ≤ 0)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

Annotations

Check warning on line 70 in tools/entra-test/enroll-tester/main.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This function has 121 lines of code, which is greater than the 100 authorized. Split it into smaller functions.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeOZB2kKYMmMBmRn&open=AZ2-IeOZB2kKYMmMBmRn&pullRequest=5977

Check warning on line 142 in management/server/integrations/entra_device/cert_validator.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Reduce this case clause number of lines from 16 to at most 10, for example by extracting code into methods.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeNuB2kKYMmMBmRd&open=AZ2-IeNuB2kKYMmMBmRd&pullRequest=5977

Check warning on line 61 in client/cmd/entra_enroll.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This function has 109 lines of code, which is greater than the 100 authorized. Split it into smaller functions.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeMXB2kKYMmMBmRZ&open=AZ2-IeMXB2kKYMmMBmRZ&pullRequest=5977

Check failure on line 51 in management/server/integrations/entra_device/cert_validator.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 22 to the 20 allowed.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeNuB2kKYMmMBmRe&open=AZ2-IeNuB2kKYMmMBmRe&pullRequest=5977

Check warning on line 78 in management/server/http/handler.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This function has 23 parameters, which is greater than the 7 authorized.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeMsB2kKYMmMBmRc&open=AZ2-IeMsB2kKYMmMBmRc&pullRequest=5977

Check failure on line 78 in management/server/http/handler.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 24 to the 20 allowed.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeMsB2kKYMmMBmRb&open=AZ2-IeMsB2kKYMmMBmRb&pullRequest=5977

Check warning on line 30 in management/server/entra_device_enroll.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

This function has 124 lines of code, which is greater than the 100 authorized. Split it into smaller functions.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeOHB2kKYMmMBmRj&open=AZ2-IeOHB2kKYMmMBmRj&pullRequest=5977

Check warning on line 0 in client/internal/profilemanager/config.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

File "config.go" has 751 lines, which is greater than 750 authorized. Split it into smaller files.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeH_B2kKYMmMBmRY&open=AZ2-IeH_B2kKYMmMBmRY&pullRequest=5977

Check failure on line 70 in tools/entra-test/enroll-tester/main.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 23 to the 20 allowed.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeOZB2kKYMmMBmRo&open=AZ2-IeOZB2kKYMmMBmRo&pullRequest=5977

Check failure on line 30 in management/server/entra_device_enroll.go

See this annotation in the file changed.

@sonarqubecloud sonarqubecloud / SonarCloud Code Analysis

Refactor this method to reduce its Cognitive Complexity from 42 to the 20 allowed.

See more on https://sonarcloud.io/project/issues?id=netbirdio_netbird&issues=AZ2-IeOHB2kKYMmMBmRk&open=AZ2-IeOHB2kKYMmMBmRk&pullRequest=5977