Authenticating to Upsource site impossible, hub ok
Hey,
I have a strange problem with accessing the Upsource site. Upsource is on a separate pc in the network, behind a reverse proxy on IIS8.
I can go to the hub and log-in/-out at https://192.168.11.172/hub either from the Upsource pc or any other pc in the network.
But if I go to the site itself https://192.168.11.172 (regardless of from which pc) I will be asked to log-in (if not already logged in) and then the site goes into endless cycle of refreshes with
Uncaught (in promise) Error: Auth Timeout
message in the console.
The only error message in the Upsource logs I can see is this:
[2017-06-27 13:35:08,015] [Upsource Error] [2017-06-27 13:35:08,012] WARN - oxy.jetty.WebSocketProxySocket - SERVER 154 *** onWebSocketError on server
[2017-06-27 13:35:08,016] [Upsource Error] java.net.SocketTimeoutException: Timeout on Read
[2017-06-27 13:35:08,016] [Upsource Error] at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onReadTimeout(AbstractWebSocketConnection.java:588)
[2017-06-27 13:35:08,016] [Upsource Error] at org.eclipse.jetty.io.AbstractConnection.onFillInterestedFailed(AbstractConnection.java:168)
[2017-06-27 13:35:08,016] [Upsource Error] at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onFillInterestedFailed(AbstractWebSocketConnection.java:534)
[2017-06-27 13:35:08,017] [Upsource Error] at org.eclipse.jetty.io.AbstractConnection$ReadCallback.failed(AbstractConnection.java:279)
[2017-06-27 13:35:08,017] [Upsource Error] at org.eclipse.jetty.io.FillInterest.onFail(FillInterest.java:125)
[2017-06-27 13:35:08,017] [Upsource Error] at org.eclipse.jetty.io.AbstractEndPoint.onIdleExpired(AbstractEndPoint.java:167)
[2017-06-27 13:35:08,017] [Upsource Error] at org.eclipse.jetty.io.IdleTimeout.checkIdleTimeout(IdleTimeout.java:166)
[2017-06-27 13:35:08,017] [Upsource Error] at org.eclipse.jetty.io.IdleTimeout$1.run(IdleTimeout.java:50)
[2017-06-27 13:35:08,018] [Upsource Error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[2017-06-27 13:35:08,018] [Upsource Error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[2017-06-27 13:35:08,018] [Upsource Error] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
[2017-06-27 13:35:08,018] [Upsource Error] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
[2017-06-27 13:35:08,018] [Upsource Error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
[2017-06-27 13:35:08,019] [Upsource Error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
Do you have any idea what could be the problem? I can send you all my logs just tell me where to.
Best regards,
Bartosz
Please sign in to leave a comment.
Hi Bartosz,
A few question in order to get a better understanding of your issue:
* Is it IIS8 IP address 192.168.11.172?
* Do you run standalone Hub instance?
Hi Artem,
Yes, IIS is under this address. The reverse proxy was configured the way you suggest here.
No, it's not a standalone hub.
Hey, would you like to see the logs? Do you have any hints for me?
I frankly made no progress since I wrote here. Would it be better if I use the standalone hub instead?
Best regards,
Bartosz
Let's check IIS configuration file - `ApplicationHost.config`.
Hey, this is the content of that file:
Hey,
I would like to come back to this discussion because I still have problems with Upsource.
I tried clear installattion of version 2017.2 with external hub.
First I installed the external hub and configured the IIS 8 reverse proxy. I created admin account and I'm able to log in to the hub from the server itself and from remote pc by going to the hub's url.
Then I tried installing Upsource, and wanted to point it to the external hub. At this point of the setup I get an error:
(BTW, the above string appears as pasted in a bubble next to the external hub url edit field; It's not rendered as html.)
Any ideas how to proceed?
It seems the above problem was caused by a missing rewrite rule in IIS.
At the external hub verification step the configurator connects to /api/hub/bundle-service... to verify the connection.
Because the external hub and the Upsource itself are on the same server I needed a rule that would re-route hub requests to hub service and the call to /api/hub... got caught in there.
Now the routing is sorted out and there's another problem.
For now the IIS rev-proxy is using self-signed certificate.
I used powershell New-SelfSignedCertificates to create the self signed cert with SAN entry for the rev-proxy's external IP address.
I also exported this certificate and keystore and imported these to the hub.
However during hub connection test I get this error:
The IP in there is the rev-proxy external IP that I added as SAN.
What do you propose I could do now?
There is a section in Hub administration called "Trusted SSL Certificates" - https://<your_upsource_url_here>/hub/certificates
Try adding your self-signed certificate there.
Done that. Same error.
I suspect the problem might be in the way powershell New-SelfSignedCertificate adds SAN entries.
They are added as DNS Name= and maybe they should be added as IP.n=
I recreated the certificate using OpenSSL and added the rev-proxy external IP as DNS Name entry and IP Address entry and this time it worked.
Now to the next problem...
When I click the 'Verify' button a pop-up window is created. In this popup window I can see that I'm logged in to the hub as admin but anyway there's 404 error and the hub is not verified.
I checked the failed request logs regarding the rewrite rules and there's nothing terribly wrong (mostly status 200, some 307).
Any ideas what to do with that one?
Hi Bartosz,
I just faced with the similar issue and resolved it by enabling guest account. Do you have guest account enabled or disabled?