xebialabs-community / xlr-rally-plugin

Rally plugin for XL Release
MIT License
0 stars 4 forks source link

Unable to connect to Rally using proxy #19

Open shashank-ssriva opened 4 years ago

shashank-ssriva commented 4 years ago

Hi,

We're getting the below issue while connecting to Rally via XL Release. There is a proxy server in between & XL Release is allowed to connect to Rally via this proxy.

But when we test the connection under shared configuration or run the task, it fails with the below error.

Executing create_rally_client() in RallyClientUtil class in RallyClientUtil.py

Executing create_client() in RallyClient class in RallyClient.py

Initializing RallyClient

Exception during execution: pyral.context.RallyRESTAPIError: 'Cannot connect to proxy.', error('Tunnel connection failed: 302 Moved Temporarily in <script> at line number 17

I've verified that I can connect to Rally using curl command via proxy. It is failing when we do it through XL Release.

[root@slflokydlxlrl01 ~]# curl https://rally1.rallydev.com -x http://xxxxxxx:8080 -v
* About to connect() to proxy xxxxxxx port 8080 (#0)
*   Trying 10.41.230.100... connected
* Connected to xxxxxxx (10.41.230.100) port 8080 (#0)
* Establish HTTP proxy tunnel to rally1.rallydev.com:443
> CONNECT rally1.rallydev.com:443 HTTP/1.1
> Host: rally1.rallydev.com:443
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.27.1 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Proxy-Connection: Keep-Alive
>
< HTTP/1.1 200 Connection established
< Date: Tue, 03 Nov 2020 16:51:39 GMT
< Proxy-Connection: Keep-Alive
< Via: 1.1 xxxxxxx.ad001.infoftps.com
<
* Proxy replied OK to CONNECT request
* Initializing NSS with certpath: sql:/etc/pki/nssdb
*   CAfile: /etc/pki/tls/certs/ca-bundle.crt
  CApath: none
* SSL connection using TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
* Server certificate:
*       subject: CN=rally1.rallydev.com,O=Broadcom Inc,L=San Jose,ST=California,C=US
*       start date: Jul 14 00:00:00 2019 GMT
*       expire date: Jul 11 12:00:00 2021 GMT
*       common name: rally1.rallydev.com
*       issuer: CN=DigiCert SHA2 Secure Server CA,O=DigiCert Inc,C=US
> GET / HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.27.1 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: rally1.rallydev.com
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Tue, 03 Nov 2020 16:51:41 GMT
< Content-Type: text/html; charset=UTF-8
< Transfer-Encoding: chunked
< Connection: keep-alive
< Set-Cookie: __cfduid=d77c37446ba15216b17becc77ee1abb871604422301; expires=Thu, 03-Dec-20 16:51:41 GMT; path=/; domain=.rallydev.com; HttpOnly; SameSite=Lax
< Expires: Thu, 01 Jan 1970 00:00:00 GMT
< X-XSS-Protection: 1; mode=block
< Vary: Accept-Encoding
< P3P: CP="NON DSP COR CURa PSAa PSDa OUR NOR BUS PUR COM NAV STA"
< Cache-Control: private,max-age=0,must-revalidate
< Strict-Transport-Security: max-age=31536000; includeSubDomains; preload;
< CF-Cache-Status: DYNAMIC
< cf-request-id: 06309e8ebd0000e2069706b000000001
< Expect-CT: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
< Set-Cookie: JSESSIONID=gi-app-011b3294ly8r7f1wwumlmuiux5m.gi-app-01;Path=/;Secure;HttpOnly
< Set-Cookie: SERVERID=62059b37ab960617b06614bff26831a65f566535; path=/
< Set-Cookie: __cflb=0H28vdwpVg78uW6v5MnF9yURaMpgG6Ywos6TXEeJQ6G; SameSite=Lax; path=/; expires=Wed, 04-Nov-20 15:51:41 GMT; HttpOnly
< Server: cloudflare
< CF-RAY: 5ec799f799c9e206-ORD
<
* Connection #0 to host xxxxxxx left intact
* Closing connection #0
<html><head><script type="text/javascript">var w=window,l=w.location,s=l.search,h=l.href.split('#')[1];w.location=h?'/'+(s?s+'&':'?')+'hash='+encodeURIComponent(h):'/slm/login.op'; // $NON-NLS-L$</script></head></html>[root@slflokydlxlrl01 ~]#
dbroker13 commented 4 years ago

Hey can you provide the plugin version and XLR version? Also are you using any sort of authorization for the proxy?

shashank-ssriva commented 4 years ago

Hey can you provide the plugin version and XLR version? Also are you using any sort of authorization for the proxy?

Hi David,

Here is the requested information.

Plugin version -xlr-rally-plugin-3.9.5.jar XL Release version - 8.5.0

dbroker13 commented 4 years ago

Okay. Also has this ever worked or is this a first time attempt and are you using any sort of authorization for the proxy?

shashank-ssriva commented 4 years ago

Okay. Also has this ever worked or is this a first time attempt and are you using any sort of authorization for the proxy?

This is our first ever attempt. Sorry, I didn't reply to your other question earlier. I had tried with both the proxies - with/without authentication.

dbroker13 commented 4 years ago

No issue are you using any other plugins that are going through this proxy?

shashank-ssriva commented 3 years ago

No issue are you using any other plugins that are going through this proxy?

I haven't tested any other plugin as we need to raise proxy requests for individual sources & destinations. I am able to hit the Rally URL when I use curl command on the terminal using the same proxy.

CC923329 commented 2 years ago

Hi, I am also facing same proxy issue. I have taken XLR-Rally-Plugin 3.12.0 , was working fine with XLR 10.0.3 version. However, when I have upgraded XLR to 10.1.10 version. It has started to give proxy error.

Can't connect to Rally Server.

pyral.context.RallyRESTAPIError: 'Cannot connect to proxy.', Failed to establish a new connection: [Errno 8] nodename nor servname provided, or not known

Please suggest.

Thanks