Unable to bind when server is behind a proxy with AD authentication

Hej,

I am having same issue. And here is the log from the output:

Summary
Starting connected SonarLint engine for Loreal...
Create : C:\Users\julius.spudvilas\.sonarlint\plugins
Plugin cache: C:\Users\julius.spudvilas\.sonarlint\plugins
Create : C:\Users\julius.spudvilas\.sonarlint\plugins\_tmp
Load plugins
Load plugins (done) | time=0ms
No plugins loaded
[Warn - 11:14:01 AM] No storage for server 'Loreal'. Please update.
Connected SonarLint engine started for Loreal
Updating global storage of server Loreal, may take some time...
Create : C:\Users\julius.spudvilas\.sonarlint\plugins
Plugin cache: C:\Users\julius.spudvilas\.sonarlint\plugins
Create : C:\Users\julius.spudvilas\.sonarlint\plugins\_tmp
GET 200 STUFF.... | response time=311ms
Create : C:\Users\julius.spudvilas\.sonarlint\plugins
Plugin cache: C:\Users\julius.spudvilas\.sonarlint\plugins
Create : C:\Users\julius.spudvilas\.sonarlint\plugins\_tmp
Load plugins
Load plugins (done) | time=0ms
No plugins loaded
[Warn - 11:14:01 AM] No storage for server 'Loreal'. Please update.
Oct 28, 2019 11:14:01 AM org.eclipse.lsp4j.jsonrpc.RemoteEndpoint fallbackResponseError
SEVERE: Internal error: java.lang.IllegalStateException: Unable to parse server infos from: <!DOCTYPE html>
<html>
<head>
<title>Sign in ? Cloudflare Access</title>
<meta charset=...
java.util.concurrent.CompletionException: java.lang.IllegalStateException: Unable to parse server infos from: <!DOCTYPE html>
<html>
<head>
<title>Sign in ? Cloudflare Access</title>
<meta charset=...
at java.base/java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:314)
at java.base/java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:319)
at java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:645)
at java.base/java.util.concurrent.CompletableFuture$Completion.exec(CompletableFuture.java:479)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:177)
Caused by: java.lang.IllegalStateException: Unable to parse server infos from: <!DOCTYPE html>
<html>
<head>
<title>Sign in ? Cloudflare Access</title>
<meta charset=...
at org.sonarsource.sonarlint.core.container.connected.validate.ServerVersionAndStatusChecker.lambda$fetchServerInfos$1(ServerVersionAndStatusChecker.java:117)
at org.sonarsource.sonarlint.core.container.connected.SonarLintWsClient.processTimed(SonarLintWsClient.java:228)
at org.sonarsource.sonarlint.core.container.connected.validate.ServerVersionAndStatusChecker.fetchServerInfos(ServerVersionAndStatusChecker.java:101)
at org.sonarsource.sonarlint.core.container.connected.validate.ServerVersionAndStatusChecker.checkVersionAndStatus(ServerVersionAndStatusChecker.java:65)
at org.sonarsource.sonarlint.core.container.connected.validate.ServerVersionAndStatusChecker.checkVersionAndStatus(ServerVersionAndStatusChecker.java:55)
at org.sonarsource.sonarlint.core.container.connected.update.perform.GlobalStorageUpdateExecutor.update(GlobalStorageUpdateExecutor.java:77)
at org.sonarsource.sonarlint.core.container.connected.ConnectedContainer.update(ConnectedContainer.java:115)
at org.sonarsource.sonarlint.core.ConnectedSonarLintEngineImpl.lambda$update$1(ConnectedSonarLintEngineImpl.java:174)
at org.sonarsource.sonarlint.core.ConnectedSonarLintEngineImpl.runInConnectedContainer(ConnectedSonarLintEngineImpl.java:311)
at org.sonarsource.sonarlint.core.ConnectedSonarLintEngineImpl.lambda$update$2(ConnectedSonarLintEngineImpl.java:174)
at org.sonarsource.sonarlint.core.ConnectedSonarLintEngineImpl.withRwLock(ConnectedSonarLintEngineImpl.java:325)
at org.sonarsource.sonarlint.core.ConnectedSonarLintEngineImpl.update(ConnectedSonarLintEngineImpl.java:169)
at org.sonarlint.languageserver.SonarLintLanguageServer.updateServerStorage(SonarLintLanguageServer.java:271)
at org.sonarlint.languageserver.SonarLintLanguageServer.lambda$handleUpdateServerStorageCommand$2(SonarLintLanguageServer.java:262)
at java.base/java.util.HashMap.forEach(HashMap.java:1333)
at org.sonarlint.languageserver.ServerInfoCache.forEach(ServerInfoCache.java:85)
at org.sonarlint.languageserver.SonarLintLanguageServer.handleUpdateServerStorageCommand(SonarLintLanguageServer.java:257)
at org.sonarlint.languageserver.SonarLintLanguageServer.lambda$executeCommand$21(SonarLintLanguageServer.java:818)
at java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:642)
... 6 more
Caused by: com.google.protobuf.InvalidProtocolBufferException: Expect message object but got: "<!DOCTYPE"
at com.google.protobuf.util.JsonFormat$ParserImpl.mergeMessage(JsonFormat.java:1400)
at com.google.protobuf.util.JsonFormat$ParserImpl.merge(JsonFormat.java:1377)
at com.google.protobuf.util.JsonFormat$ParserImpl.merge(JsonFormat.java:1259)
at com.google.protobuf.util.JsonFormat$Parser.merge(JsonFormat.java:407)
at org.sonarsource.sonarlint.core.container.connected.validate.ServerVersionAndStatusChecker.lambda$fetchServerInfos$1(ServerVersionAndStatusChecker.java:114)
... 24 more
[Warn - 11:14:01 AM] Storage of server 'Loreal' requires an update
1 Like
SEVERE: Internal error: java.lang.IllegalStateException: Unable to parse server infos from: <!DOCTYPE html>
<html>
<head>
<title>Sign in ? Cloudflare Access</title>
<meta charset=...

Looks like SonarLint cannot reach your SonarQube instance.

I suggest that you double check that the server URL in your settings is correct and that you can actually reach the server at that URL with a Web browser.

By chance, is there a Web proxy between your development box and the server?

Hej,

OMG… ok there was some extra security access set up… not sure how to bypass that, we have to log in with our AD account to get to the actual URL of SonarQube. Log in info is then set in cookies so next time we get directly to the URL…

Need to see how that could be bypassed. Any suggestions are apprechiated.

I have checked it in more detail and yes in this case we do have our URL behind the CoudFlare protection that requires user to log in either with AD or one time code.

I am following up on this as i think the correct way is to update the CloudFlare access rules to let some of the apps to access the URL directly witht the token or smth.

Its not SonarLint issue though.

1 Like