This project has moved and is read-only. For the latest updates, please go here.

Parsing HTTPS Sites

Topics: Developer Forum
Nov 14, 2008 at 5:27 PM

I am using the FormsProcessor add to parse an HTTPS site. I am able to bypass the authentication step successfully. But I am not able to parse an actual URL from the site. The thing is that to access that URL I have to sign in first, then the site automatically forwards me to the URL I want. So how to do that programatically? Please help!!

I am using the default sample code:

FormProcessor p = new FormProcessor();

string userName = “********”;
string password = “********”;

Form form = p.GetForm("", "//form[@name='loginForm']", FormQueryModeEnum.Nested);

form["j_username"].SetAttributeValue("value", userName);
form["j_password"].SetAttributeValue("value", password);

HtmlDocument doc = p.SubmitForm(form);

string strBal = doc.DocumentNode.SelectSingleNode

strBal = System.Web.HttpUtility.HtmlDecode(strBal);
strBal = strBal.Substring(1).Trim();
Nov 21, 2008 at 5:35 PM
Edited Nov 25, 2008 at 5:48 PM
I am in a similar boat, but do not know where to begin.  I have a secure URL that needs a username/password to access.  There is no redirect, but as I said, I do not know where to begin.  If someone could point me in the right direction, I would apprecaite it.

When I go to the secure URL, I am redirected to a login page.  Once logged in correctly, I am sent back to the orignal secure URL.