[Nagiosplug-devel] [ nagiosplug-Bugs-913633 ] check_http does not send port in Host field of GET request

SourceForge.net noreply at sourceforge.net
Tue Nov 23 07:13:14 CET 2004


Bugs item #913633, was opened at 2004-03-10 09:28
Message generated for change (Comment added) made by mattkent
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=913633&group_id=29880

Category: None
Group: v1.3.0 beta3
Status: Open
Resolution: Fixed
Priority: 5
Submitted By: Ben Johnson (darkstar101)
Assigned to: Matthew Kent (mattkent)
Summary: check_http does not send port in Host field of GET request

Initial Comment:

I need the port reflected in the Host: field of the GET
request. Siteminder uses this info in applying security
authorizations.

here's my check_http version: check_http
(nagios-plugins 1.3.1) 1.24.2.4


Here's ngrep sniffs showing the request to the web
server from check_http and links.

$ check_http -H msp21754 -p 61616 -u /

T 10.163.68.117:49879 -> 10.163.180.47:61616 [AP]
  GET / HTTP/1.0..Host: msp21754..User-Agent:
check_http/1.24.2.4 (nagios-plugins ).


$ links --source http://msp21754:61616/
T 10.163.68.117:49866 -> 10.163.180.47:61616 [AP]
  GET / HTTP/1.1..Host: msp21754:61616..User-Agent:
ELinks (0.4.2; Linux; )..Referer:
http://msp21754:61616/..Accept: */*..Accept-Encoding:
bzip2, gzip..Accept-Charset: us-ascii, ISO-8859-1,
ISO-8859-2, ISO-8859-3, ISO-8859-4, ISO-8895-5,
ISO-8859-6, ISO-8859-7, ISO-88
  59-8, ISO-8895-9, ISO-8859-10, ISO-8859-13,
ISO-8859-14, ISO-8859-15, ISO-8859-16, windows-1250, window
  s-1251, windows-1252, windows-1256, windows-1257,
cp437, cp737, cp850, cp852, cp866, x-cp866-u, x-mac, 
  x-mac-ce, x-kam-cs, koi8-r, koi8-u, koi8-ru,
TCVN-5712, VISCII, utf-8..Accept-Language: en..Connection:
   Keep-Alive....                                     
                                                  



I can work around the problem by specifying the IP to
connect to with -I and putting host:IP in the -H parameter:

$check_http -I 10.163.180.47 -H msp21754:61616 -p 61616
-u /

T 10.163.68.117:49894 -> 10.163.180.47:61616 [AP]
  GET / HTTP/1.0..Host: msp21754:61616..User-Agent:
check_http/1.24.2.4 (nagios-plugins )....             
                                                      
                         


----------------------------------------------------------------------

>Comment By: Matthew Kent (mattkent)
Date: 2004-11-23 07:12

Message:
Logged In: YES 
user_id=983566

Yeah that's a good idea, didn't occur to me. I'll work on
this tonight.

----------------------------------------------------------------------

Comment By: Karl DeBisschop (kdebisschop)
Date: 2004-11-23 03:00

Message:
Logged In: YES 
user_id=1671

of course if our behaviour does not comply with the
standadrd, we probably should make some sort of change.

Or starting with your reasoning, maybe we could have -H
msp21754:61616 also set the port?




----------------------------------------------------------------------

Comment By: Matthew Kent (mattkent)
Date: 2004-11-20 13:37

Message:
Logged In: YES 
user_id=983566

I know it seems silly to have to specify the port twice, but
the way it functions currently best fits the description of
the flags. Plus I'd rather let the user send whatever host
header they'd like instead of forcefully appending a port.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=913633&group_id=29880




More information about the Devel mailing list