Forum Discussion
Angelo
Nimbostratus
Jan 30, 2013custom monitoring
Hi
I need to make a custom monitor that retieves a index page and tries to login to the page is this even possible...
THank you
Angelo Amoojee
11 Replies
- What_Lies_Bene1
Cirrostratus
Hey Angelo. It could be but that depends on the authentication method. If it's a forms based login then it's not possible (I don't think) but if it's HTTP Auth or NTLM then it's possible. - Angelo
Nimbostratus
it's form based login. i confirmed with the web developer.. - Kevin_Stewart
Employee
A form-based login is usually just a POST method with a urlencoded payload:
==================
POST /index.php HTTP/1.1
Host: www.example.com
username=bob&password=mypassword
==================
Which equates to this single line string:
POST /index.php HTTP/1.1\r\nHost: www.example.com\r\n\r\n\r\nusername=bob&password=mypassword
The trick then is to figure out how your login page works and if there are subsequent messages after a successful login. If you capture the server side HTTP dialog you should see all of this. Then it's relatively simple to craft a cURL script in an external monitor, or if the login is simple, directly in the HTTP monitor in the GUI. - What_Lies_Bene1
Cirrostratus
Thanks Kevin. I'll note that for the future! Cheers - Arie
Altostratus
Doesn't the log-in require SSL?
- What_Lies_Bene1
Cirrostratus
That shouldn't matter. - Kevin_Stewart
Employee
If you're re-encrypting to the back end server, you should have a server SSL profile applied to the virtual server. The underlying HTTP dialog won't change though. - Arie
Altostratus
Posted By What Lies Beneath on 02/01/2013 07:44 AM
That shouldn't matter.It might matter - depends on the monitor config.
- What_Lies_Bene1
Cirrostratus
Arie, as long as the appropriate monitor (http or https) is configured what's the difference? - Arie
Altostratus
Exactly - as long as it's configured properly. However, generally there are different pools for 80 and 443 and you can't use the same monitor. Since I wasn't sure Angelo was aware of that I figured I'd point it out.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects