Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
HTTP WARNING: Status line output matched "403" - HTTP/1.1 403 Forbidden - 381 bytes in 0.114 second response time |time=0.114195s;;;0.000000 size=381B;;;0
And I have checked the return code, which is '1'. As I'm using the 'expect 403', I would expect this to be 'OK'.
Is it possible to use check_http to give an 'OK' response when a 403 response code is received?
The Negate plugin allows for any standard plugin output to be reversed and is very useful with hosts or services that are expected to be in a Critical
or Warning state but you wish to show them as OK. This function can be used for the opposite effect (i.e. showing a CRITICAL state
when the actual state is OK)
Be sure to check out the Knowledgebase for helpful articles and solutions!
SSL initialized
GET /secure-page HTTP/1.1
User-Agent: check_http/v2.2.0 (nagios-plugins 2.2.0)
Connection: close
Host: example.com
Accept: */*
https://example.com:443/secure-page is 381 characters
STATUS: HTTP/1.1 403 Forbidden
**** HEADER ****
Content-Type: text/html; charset=iso-8859-1
Date: Tue, 21 Feb 2017 20:12:22 GMT
Vary: Accept-Encoding
Content-Length: 210
Connection: Close
**** CONTENT ****
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>403 Forbidden</title>
</head><body>
<h1>Forbidden</h1>
<p>You don't have permission to access /secure-page
on this server.</p>
</body></html>
Status line output matched "403" -
HTTP WARNING: Status line output matched "403" - HTTP/1.1 403 Forbidden - 381 bytes in 0.025 second response time |time=0.024534s;;;0.000000 size=381B;;;0
I thought that it wasn't correct behaviour as it's only started happening since I upgraded from plugins version 1.4.something.