ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Read HTML code from HTTPS url

Hello everyone, is it possible to read the HTML content code of a web page that has an url in HTTPS without using IWEBBROWSER2 ??

For example with ActiveX .NET?
Thank you

0 Kudos
Message 1 of 12
(7,602 Views)

Use the HTTP client found in the  "Data Communication" -> "Protocols" palette.

 

https.png

0 Kudos
Message 2 of 12
(7,560 Views)

@deceased wrote:

Use the HTTP client found in the  "Data Communication" -> "Protocols" palette.

 

https.png


You'd probably need a lot more code (from the Security palette) then that to set up the SSL connection. AFAIK, SSL+HTTP=HTTPS.

 

I've used stunnel in the past, so the problem doesn't need to be solved in LabVIEW anymore. Stunnel will route the shhtp data to http data.

0 Kudos
Message 3 of 12
(7,548 Views)

Worked fine for me visiting the HTTPS of amazon.com. Body contained the full HTML/Javacript.

The header did include the HSTS request, but at that point I already had the body.

 

If you try to visit the HTTP version, it only returns a 301 permanent redirect header (pointing to the HTTPS version) and no Body.

 

0xDEAD

0 Kudos
Message 4 of 12
(7,533 Views)

Hi deceased, I tried with the example above (http post) but it does not work, the html code returned in the body is encoded and therefore illegible.

 url : https://www.amazon.com

Error.png

 

 

0 Kudos
Message 5 of 12
(7,523 Views)

@wiebe@CARYA 

OK, thanks for the reply :), would you have an example code?

0 Kudos
Message 6 of 12
(7,519 Views)

@NicolaRE77 wrote:

@wiebe@CARYA 

OK, thanks for the reply :), would you have an example code?


Not really. I actually have no idea how that would work from LabVIEW. I saw that the HTTP interface has SSL options, but I have no idea what should be wired to what VI...

 

When I used stunnel, my application actually was the HTTP server. I used .NET for that, and figured I'd better outsource the SSL part.

0 Kudos
Message 7 of 12
(7,502 Views)

ok, I think there is this, but where do I find all these certificates and api key?
Is not the client_certificate alone enough?

 

Error.png

Message 8 of 12
(7,491 Views)
Is it possible that no one has exploited an HTTP + SSL communication? SOS
0 Kudos
Message 9 of 12
(7,443 Views)

wiebe@CARYA wrote:

 


You'd probably need a lot more code (from the Security palette) then that to set up the SSL connection. AFAIK, SSL+HTTP=HTTPS.


Nope. The HTTP VIs do unlike what their name might suggest, also support the HTTPS protocol. As long as you try to connect to a HTTPS server with valid certificate signed by one of the well known certification authorities, they should simply work. If you try to access a server with self signed certificate you have to setup your own certification store with the correct certificate which the HTTP VIs only expose a very simple and not always workable method for.

Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
Message 10 of 12
(7,433 Views)