server-client-python icon indicating copy to clipboard operation
server-client-python copied to clipboard

HTTPS proxy support

Open alireza18878 opened this issue 1 year ago • 5 comments

Describe the bug Tableauserverclient does not support proxy over HTTPS (it supports proxy over HTTP, but not HTTPS).

Versions Details of your environment, including:

  • Tableau Server version (or note if using Tableau Online): N/A
  • Python version: 3.5
  • TSC library version: 0.15

To Reproduce When trying to use tableauserverclient with a HTTPS proxy, I get error 403 Forbidden since the library is not able to communicate over HTTPS proxy.

Results Error 403 Forbidden, caused by proxy error.

Can you please let me know if the newer versions of tableauserverclient support HTTPS proxy?

alireza18878 avatar Sep 13 '23 13:09 alireza18878

Yes, I believe it was introduced in v22?

jacalata avatar Sep 14 '23 02:09 jacalata

Yes, I believe it was introduced in v22?

Thank you @jacalata. I suppose you were referring to v0.22 right?

alireza18878 avatar Sep 14 '23 14:09 alireza18878

Yes, she was referring to v0.22, meaning that was the version where proxy support was introduced. I would suggest trying the latest version of TSC and see what your results are.

bcantoni avatar Sep 14 '23 18:09 bcantoni

Out of curiosity, you meant http option or http_proxy support ? as this is the 0.23 changelog https://fburl.com/padmojhu (I didn't see much from 0.22 changelog, I maybe wrong tho) and seems it is for supporting http option ?

HsiehYuho avatar Sep 15 '23 02:09 HsiehYuho

Not sure what you meant to link but that's an fb internal URL.

The http_option allows you to pass in any set of proxy values - what you set here flows through as a parameter to the requests.send call. e.g

    my_proxies = {
        'http': 'http://10.10.1.10:3128',
        **'https': 'http://10.10.1.10:1080',**
    }
    server = TSC.Server(server_url, use_server_version=True, http_options={"verify": use_ssl, "proxies": my_proxies})

jacalata avatar Sep 25 '23 19:09 jacalata