LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

HTTP POST with Redirect not redirecting

Ok, this may be a dumb question so no yelling!

 

I am trying to use the HTTP lib (which I have successfully used many times in the past) to POST to an internally developed webserver.  If i POST via chrome like this:

 

https://lab4-mfg-110.lab4.{ICantTellYou}.com:9443/duv/response

 

i get this:

 

{"response":"I've got ya man!","status":"Success"}

All is good with the world!

 

 

\Now i try with labview like this:

http.png

 

and i get a header of:

 

HTTP/1.1 302 Found
Set-Cookie: session-id=000-4170299-4770407; Domain=.amazon.com; Expires=Tue, 01-Jan-2036 08:00:01 GMT; Path=/
Set-Cookie: session-id-time=2082787201l; Domain=.{cantSay}.com; Expires=Tue, 01-Jan-2036 08:00:01 GMT; Path=/
Set-Cookie: sso_rfp=d3e883917f77f70c; Path=/; Max-Age=604800; Secure; Expires=Mon, 16 Apr 2018 17:27:37 GMT; HttpOnly
Location: https://sentry.{cantSay}.com/SSO/redirect?response_type=id_token&client_id=lab4-mfg-110.lab4.{cantSay}.com%3A9443&redirect_uri=https%3A%2F%2Flab4-mfg-110.lab4.{cantSay}.com%3A9443%2Fduv%2Fresponse&scope=openid&nonce={cantSay}&sentry_handler_version=TomcatSSOFilter-1.1-1
Content-Type: text/plain;charset=UTF-8
Content-Length: 0
Date: Mon, 09 Apr 2018 17:27:37 GMT
Server: Server

 

and no Body!  I dont have a valid CA as of yet, and the body json is ignored by the server at the moment.  I have tried POST and GET and PUT with same results.

 

I believe it didn't correctly redirect due to the 302 error, or I am not handling it correctly.

 

My question is how do you handle redirects with the HTTP lib?

 

 

0 Kudos
Message 1 of 2
(3,132 Views)

I am not sure if this completely addresses your issue or if you are already aware of this, but there is a VI called Set HTTP Redirect VI

0 Kudos
Message 2 of 2
(3,078 Views)