Rocket.Chat.Android icon indicating copy to clipboard operation
Rocket.Chat.Android copied to clipboard

[QUESTION] Not able to connect to server

Open earlng opened this issue 8 years ago • 18 comments

Description

I am having trouble connecting to my self-hosted instance of RocketChat via the mobile Android App.

When I open the app, it prompts me for the server URL, which I provide. But after clicking "submit", it returns the error: "An error has occurred while checking your server version, please try again".

I am able to connect to the server from the same mobile phone via browser. I am also able to connect from the desktop and the RocketChat+ desktop program. I also checked with a colleague, and she is able to connect via the iPhone iOS app.

This server that I'm connecting to is using a GoDaddy SSL wildcard cert, with a PEM Phrase.

I had previously provisioned another RocketChat server (same version) with a LetsEncrypt SSL cert. I am able to connect to that server via the mobile app (or at least, I'm prompted for a login).

In both instances, the method of installation was roughly following this: https://rocket.chat/docs/installation/paas-deployments/aws/

I have also confirmed that the Nginx settings are correct.

Devices and Versions

Rocket Chat Version: 0.64.2 Android App Version: 2.1.1

earlng avatar May 21 '18 09:05 earlng

@earlng Can you share your server URL? And what version is it? If you wanna share in private with me: rafael.kellermann at rocket.chat.

rafaelks avatar May 21 '18 11:05 rafaelks

Hi @rafaelks, unfortunately, i'm not at liberty to share the URL of the server/grant you access. But I've mentioned that the rocketchat version is 0.64.2

earlng avatar May 22 '18 02:05 earlng

It's also a problem.

Rocket Chat Version: 0.64.2 Android App Version: 2.2

"An error has occurred while checking your server version, please try again"

perchibald avatar May 22 '18 12:05 perchibald

@perchibald What's your server URL?

rafaelks avatar May 22 '18 12:05 rafaelks

do I need to grant access?

perchibald avatar May 22 '18 13:05 perchibald

@perchibald I believe you're having issues to access because of your SSL:

screen shot 2018-05-22 at 10 13 49

rafaelks avatar May 22 '18 13:05 rafaelks

what's wrong with the certificate? in the browser works, in the native application on Linux works, and on Windows too

perchibald avatar May 22 '18 13:05 perchibald

@perchibald Your server is lacking the Intermediate Certificates configuration (or is misconfigured) (https://developer.android.com/training/articles/security-ssl#MissingCa)

https://knowledge.geotrust.com/support/knowledge-base/index?page=content&actp=CROSSLINK&id=SO17664 screen shot 2018-05-22 at 10 50 26 am

luciofm avatar May 22 '18 13:05 luciofm

@earlng I'm almost sure you have the same problem. If you could run https://www.sslchecker.com/sslchecker on your domain to check.

This is an example of a misconfigured host screen shot 2018-05-22 at 10 54 40 am And here what you should get for a host with the Intermediate Certificates configured screen shot 2018-05-22 at 10 54 55 am

You are able to connect via iPhone probably because iOS already trusts this intermediate certificate, and the web browser caches them. So if you ever accessed a url that uses the same certificate chain, it will work even with misconfigured hosts...

http://nginx.org/en/docs/http/configuring_https_servers.html#chains

luciofm avatar May 22 '18 13:05 luciofm

thanks guys! everything worked out))

perchibald avatar May 23 '18 05:05 perchibald

Yeap! We fixed our certs on our end, the vendor signed is now yes, and the Android app is now able to connect to server. Closing issue.

earlng avatar May 23 '18 05:05 earlng

HI, I am having the same problem connecting andriod app to

https://ebcweb.certissecurity.com

ksericpro avatar Sep 17 '18 15:09 ksericpro

We're also experiencing this issue on private server. Certificate is from Let's Encrypt and passes all SSL tests. Some Android versions seems to be working ok but e.g. mine gives the same error, "error checking while checking the server version". Android version 7.0, Rocket.chat client version 2.6.1 and server 0.69.2.

Rocket chat installed with dockerc-compose and located behind Nginx-proxy. Web version works fine.

myllymik-zz avatar Sep 25 '18 14:09 myllymik-zz

Fixed it in my case by removing

ssl_ecdh_curve secp384r1;

from nginx configuration. Not sure why this is issue for some Androids but looks like it is.

myllymik-zz avatar Sep 26 '18 05:09 myllymik-zz

i don't have this line in my Nginx configuration. ssl_ecdh_curve secp384r1;

how can i resolve the same problem?

mahdigholipoor avatar Oct 13 '18 19:10 mahdigholipoor

Have you checked from any included configuration files? In my case I found it out by simply disabling all ssl-related configuration parameters (except the critical ones, ie. cert paths etc.) and then re-enabling them one by one while reloading configuration every time and testing. Ended up with this line that broke it.

myllymik-zz avatar Oct 15 '18 04:10 myllymik-zz

@earlng How did you solve this? I got lost ROOT 1 missing at the last circle

elcolie avatar Feb 11 '19 03:02 elcolie

@earlng How did you solve this? I got lost ROOT 1 missing at the last circle

Same here, I have a feeling it's got something to do with ROOT_URL variable.

muganwas avatar Sep 10 '19 12:09 muganwas