<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: http get requests by commandline in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618414#M925441</link>
    <description>Hello Bill,&lt;BR /&gt;&lt;BR /&gt;If you want to get, say, a page that is protected by a password, use WGET, like that:&lt;BR /&gt;&lt;BR /&gt;wget --http-user bill --http-passwd mypassword URL&lt;BR /&gt;&lt;BR /&gt;That does the job nicely and you don't have to deal with obscure echo commands. :)&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Paga&lt;BR /&gt;</description>
    <pubDate>Fri, 23 Nov 2001 02:51:11 GMT</pubDate>
    <dc:creator>Marco Paganini</dc:creator>
    <dc:date>2001-11-23T02:51:11Z</dc:date>
    <item>
      <title>http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618406#M925433</link>
      <description>How do I formulate http requests for a httpd?&lt;BR /&gt;&lt;BR /&gt;A password will be asked, so I'll have to give input, but in either case, it'd be nice to get some response anyway....&lt;BR /&gt;&lt;BR /&gt;pereal:root&amp;gt; telnet pereal 4242&lt;BR /&gt;Trying...&lt;BR /&gt;Connected to pereal.guinness.ie.&lt;BR /&gt;Escape character is '^]'.&lt;BR /&gt;HTTP/1.0&lt;BR /&gt;HTTP/1.0 505 OK&lt;BR /&gt;MIME-Version: 1.0&lt;BR /&gt;Server: HP-ChaiServer/3.0&lt;BR /&gt;Date: Wed, 21 Nov 2001 16:37:46 GMT&lt;BR /&gt;Connection: close&lt;BR /&gt;Content-length: 100&lt;BR /&gt;Content-Type: text/html&lt;BR /&gt;Connection: close&lt;BR /&gt;&lt;BR /&gt;&lt;TITLE&gt;Request Not Implemented&lt;/TITLE&gt;&lt;P&gt;&lt;B&gt;Cannot process request, not implemen&lt;BR /&gt;ted at server.&lt;/B&gt;&lt;/P&gt;&lt;P&gt;Unknown HTTP actionConnection closed by foreign host.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Nov 2001 16:41:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618406#M925433</guid>
      <dc:creator>Bill McNAMARA_1</dc:creator>
      <dc:date>2001-11-21T16:41:14Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618407#M925434</link>
      <description>just to add I've an apache 1.3.19 server on port 80, that just entering GET will o/p the index.html file.&lt;BR /&gt;&lt;BR /&gt;On the Chai Server, a GET returns:&lt;BR /&gt;GET&lt;BR /&gt;HTTP/1.0 400 Unintelligible request line: GET&lt;BR /&gt;MIME-Version: 1.0&lt;BR /&gt;Server: HP-ChaiServer/3.0&lt;BR /&gt;Date: Wed, 21 Nov 2001 16:44:03 GMT&lt;BR /&gt;Connection: close&lt;BR /&gt;Content-length: 97&lt;BR /&gt;Content-Type: text/html&lt;BR /&gt;Connection: close&lt;BR /&gt;&lt;BR /&gt;&lt;TITLE&gt;Bad Request&lt;/TITLE&gt;&lt;P&gt;&lt;B&gt;Bad request, cannot process. Unintelligible requ&lt;BR /&gt;est line: GET&lt;/B&gt;Connection closed by foreign host.           &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Nov 2001 16:43:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618407#M925434</guid>
      <dc:creator>Bill McNAMARA_1</dc:creator>
      <dc:date>2001-11-21T16:43:45Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618408#M925435</link>
      <description>Try:&lt;BR /&gt;&lt;BR /&gt;$ echo "GET /\n" | telnet &lt;HOSTNAME&gt; &lt;PORT&gt;&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Steve&lt;/PORT&gt;&lt;/HOSTNAME&gt;</description>
      <pubDate>Wed, 21 Nov 2001 16:47:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618408#M925435</guid>
      <dc:creator>Steven Gillard_2</dc:creator>
      <dc:date>2001-11-21T16:47:18Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618409#M925436</link>
      <description>pereal:root&amp;gt; echo "GET /\n" | telnet pereal 4242&lt;BR /&gt;Trying...&lt;BR /&gt;Connected to pereal.guinness.ie.&lt;BR /&gt;Escape character is '^]'.&lt;BR /&gt;HTTP/1.0 400 Unintelligible request line: GET /   &lt;BR /&gt;&lt;BR /&gt;Just to mention, it will ask me for a password in a prompt box before loading a page, but I guess that must be loaded from within the homepage...&lt;BR /&gt;Later,&lt;BR /&gt;Bill</description>
      <pubDate>Wed, 21 Nov 2001 16:52:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618409#M925436</guid>
      <dc:creator>Bill McNAMARA_1</dc:creator>
      <dc:date>2001-11-21T16:52:57Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618410#M925437</link>
      <description>You can use the old:&lt;BR /&gt;print HTTP string | telnet machine 80&lt;BR /&gt;(For HTTP string - look at the RFC!)&lt;BR /&gt;&lt;BR /&gt;But it's not always the best way - you could code it using netcat or expect...&lt;BR /&gt;&lt;BR /&gt;Or, you can download snarf from the porting centre and use that (best way :-)&lt;BR /&gt;&lt;BR /&gt;dave</description>
      <pubDate>Wed, 21 Nov 2001 16:54:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618410#M925437</guid>
      <dc:creator>David Lodge</dc:creator>
      <dc:date>2001-11-21T16:54:22Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618411#M925438</link>
      <description>hmmm that works on my Apache server.  Perhaps try conforming to the RFC :&lt;BR /&gt;&lt;BR /&gt;$ echo "GET / HTTP/1.0\n" | telnet &lt;HOST&gt; &lt;PORT&gt;&lt;BR /&gt;&lt;BR /&gt;For the password stuff, if its just using basic authentication, you can include the encrypted user name and password in an Authorization header, eg:&lt;BR /&gt;&lt;BR /&gt;echo "GET / HTTP/1.0\nAuthorization: Basic &lt;ENCRYPTED string=""&gt;\n"  | telnet &lt;HOST&gt; &lt;PORT&gt;&lt;BR /&gt;&lt;BR /&gt;From memory, the encryption is simply a base64 encoding of the username:password - check the HTTP RFC to be sure.  Not so easy to generate from the shell, but theres always perl :)&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Steve&lt;/PORT&gt;&lt;/HOST&gt;&lt;/ENCRYPTED&gt;&lt;/PORT&gt;&lt;/HOST&gt;</description>
      <pubDate>Wed, 21 Nov 2001 17:06:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618411#M925438</guid>
      <dc:creator>Steven Gillard_2</dc:creator>
      <dc:date>2001-11-21T17:06:00Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618412#M925439</link>
      <description>sorry David, you should have got a 10 for the snarf reference...&lt;BR /&gt;&lt;BR /&gt;it allows authentication from commandline..&lt;BR /&gt;&lt;BR /&gt;pereal:root&amp;gt; ./snarf -v ocmpadm:ocmpadm@pereal:4242&lt;BR /&gt;http://luser:passwd@pereal:4242 (unknown size)&lt;BR /&gt;index.html                [\]       0K&lt;BR /&gt;609 bytes transferred in 0.00 sec (1392.78k/sec)  &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;and:&lt;BR /&gt;&lt;BR /&gt;pereal:root&amp;gt; ./snarf -v pereal:80&lt;BR /&gt;HTTP/1.1 200 OK&lt;BR /&gt;Date: Wed, 21 Nov 2001 17:11:34 GMT&lt;BR /&gt;Server: Apache/1.3.19 (Unix) ApacheJServ/1.1.1 PHP/4.0.4pl1&lt;BR /&gt;Last-Modified: Mon, 22 Oct 2001 11:15:57 GMT&lt;BR /&gt;ETag: "8470-692-3bd3ffed"&lt;BR /&gt;Accept-Ranges: bytes&lt;BR /&gt;Content-Length: 1682&lt;BR /&gt;Connection: close&lt;BR /&gt;Content-Type: text/html&lt;BR /&gt;&lt;BR /&gt;http://pereal:80 (1K)&lt;BR /&gt;index.html                [########################]       1K | 5401.39K/s&lt;BR /&gt;1682 bytes transferred in 0.00 sec (2841.61k/sec)             &lt;BR /&gt;&lt;BR /&gt;Later,&lt;BR /&gt;Bill&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 21 Nov 2001 17:11:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618412#M925439</guid>
      <dc:creator>Bill McNAMARA_1</dc:creator>
      <dc:date>2001-11-21T17:11:21Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618413#M925440</link>
      <description>pereal:root&amp;gt; ....... GFkbQ==\n" | telnet pereal 4242&lt;BR /&gt;Trying...&lt;BR /&gt;Connected to pereal.guinness.ie.&lt;BR /&gt;Escape character is '^]'.&lt;BR /&gt;HTTP/1.0 500 OK&lt;BR /&gt;MIME-Version: 1.0&lt;BR /&gt;Server: HP-ChaiServer/3.0&lt;BR /&gt;Date: Wed, 21 Nov 2001 17:15:14 GMT&lt;BR /&gt;Connection: close&lt;BR /&gt;Content-length: 108&lt;BR /&gt;Content-Type: text/html&lt;BR /&gt;Connection: close&lt;BR /&gt;&lt;BR /&gt;&lt;TITLE&gt;Internal Server Error&lt;/TITLE&gt;&lt;P&gt;&lt;B&gt;Could not process request due to inter&lt;BR /&gt;nal server error.&lt;/B&gt;&lt;/P&gt;&lt;P&gt;Connection closed by foreign host.&lt;/P&gt;</description>
      <pubDate>Wed, 21 Nov 2001 17:15:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618413#M925440</guid>
      <dc:creator>Bill McNAMARA_1</dc:creator>
      <dc:date>2001-11-21T17:15:53Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618414#M925441</link>
      <description>Hello Bill,&lt;BR /&gt;&lt;BR /&gt;If you want to get, say, a page that is protected by a password, use WGET, like that:&lt;BR /&gt;&lt;BR /&gt;wget --http-user bill --http-passwd mypassword URL&lt;BR /&gt;&lt;BR /&gt;That does the job nicely and you don't have to deal with obscure echo commands. :)&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Paga&lt;BR /&gt;</description>
      <pubDate>Fri, 23 Nov 2001 02:51:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618414#M925441</guid>
      <dc:creator>Marco Paganini</dc:creator>
      <dc:date>2001-11-23T02:51:11Z</dc:date>
    </item>
    <item>
      <title>Re: http get requests by commandline</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618415#M925442</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Don't forget the good old lynx. :) A combination of either -dump or -source as well as -auth should be sufficient for your specified needs.&lt;BR /&gt;&lt;BR /&gt;To get HTML source:&lt;BR /&gt;&lt;BR /&gt;# lynx -auth=userid:passwd -source &lt;A href="http://host.domain/your.url" target="_blank"&gt;http://host.domain/your.url&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;To get HTML output:&lt;BR /&gt;&lt;BR /&gt;# lynx -auth=userid:passwd -dump &lt;A href="http://host.domain/your.url" target="_blank"&gt;http://host.domain/your.url&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Hope this helps. Regards.&lt;BR /&gt;&lt;BR /&gt;Steven Sim Kok Leong&lt;BR /&gt;Brainbench MVP for Unix Admin&lt;BR /&gt;&lt;A href="http://www.brainbench.com" target="_blank"&gt;http://www.brainbench.com&lt;/A&gt;</description>
      <pubDate>Fri, 23 Nov 2001 03:45:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/http-get-requests-by-commandline/m-p/2618415#M925442</guid>
      <dc:creator>Steven Sim Kok Leong</dc:creator>
      <dc:date>2001-11-23T03:45:37Z</dc:date>
    </item>
  </channel>
</rss>

