Webinject

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.
Locked
delboy1966
Posts: 98
Joined: Thu Oct 22, 2015 5:26 am

Webinject

Post by delboy1966 »

Sorry for posting this here, but I can't find a forum of the WebInject plugin.

Was wondering if anyone had any luck using this to test login to an ASP page?
The ASP passes a __VIEWSTATE variable to maintain state between requests which has to be sent back in the post request with the login details.
I have used exactly as specified in the examples on the WebInject site: http://www.webinject.org/manual.html#sessid
But my posted URL has the __VIEWSTATE variable empty from the http.log

Or is there something else I can use to test logins to ASP pages that require the __VIEWSTATE variable passing back?

Thanks
Tony
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Webinject

Post by mcapra »

delboy1966 wrote:I can't find a forum of the WebInject plugin.
WebInject is sort of lacking in the err....continuous development and community engagement departments.
delboy1966 wrote:Or is there something else I can use to test logins to ASP pages that require the __VIEWSTATE variable passing back?
If you don't mind setting up a separate machine for a Selenium server, you should be able to follow this Nagios XI documentation for integrating Selenium almost to the letter and have it work with Nagios Core:
https://assets.nagios.com/downloads/nag ... ios-XI.pdf

Page 10 onwards is Nagios XI specific stuff, but it's just setting up a command and service definition.

Fair warning, Selenium is a bit heavy for what most people (in my experience) need in terms of web-based checks. But it will get the job done.
Former Nagios employee
https://www.mcapra.com/
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: Webinject

Post by dwhitfield »

Thanks @mcapra!

The forum link on the webinject page appears to be dead. However, there is an email address you might try if Selenium isn't an option for you: [email protected]
delboy1966
Posts: 98
Joined: Thu Oct 22, 2015 5:26 am

Re: Webinject

Post by delboy1966 »

This forum never ceases to come up with a solution.

Implemented selenium, not a problem installing it as we already have java installed on our Nagios nodes.
Works a treat if I record firefox logging in and then pressing the logout button. If it wasn't able to login then the logout button wouldn't exist so the check fails as it should.

Thanks again guys.

Tony
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: Webinject

Post by dwhitfield »

delboy1966 wrote: Implemented selenium, not a problem installing it as we already have java installed on our Nagios nodes.
Great news @delboy1966!

I did want to point something out for anyone else that happens upon this forum thread in the future. Installing Selenium on an *XI* server is 100% ***NOT*** supported. Core is all over the place because of distribution repos and people compiling it on toasters (ok, I haven't actually seen that), but XI has a pretty strict install criteria so that we can get those machines up and running quickly.

Also worth mentioning: we do also over Core support contracts. There are similar rules about getting things as stock as possible with those: https://www.nagios.com/services/nagios- ... ort-plans/
Locked