3

Is there a way to download a web page in a fashion similar to curl/wget, but via Firefox/Chrome instead? I'm using GNU/Linux. I want to be able to do this exclusively from the command line, so that I can automate my tests.

I want to setup a test bed for various TLS configurations that should be completely automated. For this I need to be able to access secure webpages from the command line. I am already using curl/wget/openssl from the command line, but I also want to ensure that the Firefox/Chrome browsers too perform as expected, as the various validations that are performed by these browsers might be more involved/restrictive than that of the other tools.

Thanks in advance.

  • 1
    You may end up having to write something like a selenium test and launch that – Eric Renouf Jun 14 '17 at 11:38
  • Ok, I will have to look into this. Hopefully is a simple test, I only want to load an URL, and see if the SSL connection was properly established and the certificate and hostname and so on were verified, and the content was downloaded successfully. – CosminB Jun 14 '17 at 11:42
2

Use the new headless chrome:

Need Chrome 59+ (no Windows)

$ chrome --headless --disable-gpu --dump-dom https://www.example/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.