tableau / TabPy

Execute Python code on the fly and display results in Tableau visualizations:
https://tableau.github.io/TabPy/
MIT License
1.56k stars 598 forks source link

Taby ssl error only on server environment #487

Closed tombender closed 3 years ago

tombender commented 3 years ago

Environment information:

Describe the issue Tabpy works perfectly fine in Tableau desktop but doesn't seem to work online on our server environment.

To Reproduce When we connect with our tabpy server in Tableau desktop including the credentials and check the require SSL box it says: 'Successfully connected to the analytics extension'. On our server I've enabled the option to connect to an analytics extension and given the exact same hostname, username, password and checked the require ssl box.

If I search https://our-domain.nl:9004 I come to the webpage which says tabpy was successfully deployed. The cert file is valid, we also use it on our Tableau server.

Snippet of the tabpy log: 2021-02-11,09:19:32 [WARNING] (iostream.py:iostream:1406): SSL Error on 10(our IP address, 47630): [SSL: TLSV1_ALERT_UNKNOWN_CA] tlsv1 alert unknown ca (_ssl.c:1123)

Screenshots tabpy_ss

Additional context I've also uploaded the certificate file in the dir /usr/local/share/ca-certificates/ for the tableau server to pick up the certificate.

If I missed to provide information, please let me know.

Many thanks in advance!

nmannheimer commented 3 years ago

Hey @tombender thanks for the report and good info, we'll take a look at this. Some quick questions: You mention online and Server, are you using a Tableau Server instance you're hosting on your own hardware, or Tableau Online (I assume Server based on the additional info)?

Also, just confirming it's the same cert you're using for Desktop, TabPy, and your Tableau Server?

tombender commented 3 years ago

Hi @nmannheimer Yes we are using Tableau Server and hosting it on our own vps. I understand Tableau Server and Tableau Online are different instances, sorry for the misunderstanding.

For Tabpy and Tableau server I can confirm we're using the exact same cert. I don't know what you mean with Tableau Desktop and the cert. Is it necessary to upload the cert in Tableau Desktop? Or is checking the require SSL box enough for Tabpy to get the cert configured in the config file?

0golovatyi commented 3 years ago

@tombender For Tableau Server to trust TabPy it needs to know to trust certificate issued for the host running TabPy. Some tips and tricks can be found at http://tabscifi.com/category/security/.

In short for self-signed cert it has to be installed as trusted on Tableau Server machine and for signer cert Tableau Server need to have at least root cert installed as trusted.

tombender commented 3 years ago

@0golovatyi I'll look into it and will let you guys know if it works!

tombender commented 3 years ago

Hi @0golovatyi @nmannheimer It works now!

I've had the right pair of cert and key but I missed the upload the root.cert and the RSADomainValidation.crt in the dir /usr/local/share/ca-certificates. I had mistaken the domain cert for the root cert in the previous upload in /usr/local/share/ca-certificates , so that was why it wasn't working.

For anyone else facing this issue follow the steps in this link: http://tabscifi.com/category/security/ (was already sent by @0golovatyi )

Thanks for the help and keep up the good work!

Liyakath84 commented 2 years ago

Hello Team,

I am having issues with connecting to tabpy from linux server.

Getting error message like "Plain HTTP request was sent to HTTPS".I made sure all the root,intermediate and tabpy extension server certificates are there but still no luck.

Please advise...

Thanks, Khader