Page 1 of 1

how to check auth

Posted: Sat Apr 15, 2017 5:54 am
by terminus
hi

I'm want to check http auth switch (for example netgear, see screenshot), but dont know how do it.
and, yes, i'm know about plugins check_http with options -a, and check_basic_auth, its not for me

I think, its really by web transaction, but not understand syntax

any ideas ?

Image

Re: how to check auth

Posted: Sun Apr 16, 2017 8:50 pm
by tacolover101
as it's not basic auth you won't be able to use the built in process with check_http. but, what you could do is append the headers it's sending as user & pass to the processing page of that form, and see if that redirects properly. then just have it check that page.

i.e. http://192.168.1.1/netgear/index.html is where your screenshot is from, let's say the process page is http://192.168.1.1/netgear/process.php - append your fields from the form and try checking that URL (this will vary based on the form) - http://192.168.1.1/netgear/process.php? ... rd=netgear

otherwise, might be something at https://exchange.nagios.org - or if not, write your own custom one. :D

Re: how to check auth

Posted: Mon Apr 17, 2017 9:48 am
by mcapra
Thanks @tacolover101!

Another option aside from writing the request headers and POST fields would be Selenium, though this would be quite heavy for such a simple use case:
https://assets.nagios.com/downloads/nag ... ios-XI.pdf