c# - Login to ASP .NET MVC website under HTTPS using Windows Service -
i have administrative methods under asp .net mvc website under https.
so looks like
https://mysite.com/cms and there actions checkusers
my question is
can develop external windows service sign in website , execute methods?
i mean how technically (sign in , call methods?)
so tha chain that
windows service <---> call method checkusers() under https://mysite.com/cms <---> other https://site2.com
i need automate execution of methods , periodically windows service.
it question of possible communication between windows service , asp .net mvc. clue?
we've been using http://htmlunit.sourceforge.net/ sending requests third-party web sites. allows send requests, receive response/status code/etc. basically, small gui-less browser evaluates htmkl, javascript, etc.
(it's java lib, either google .net port or use converter convert java assembly .net assembly - see http://blog.stevensanderson.com/2010/03/30/using-htmlunit-on-net-for-headless-browser-automation/ guidance. we've used convertion approach).
if requirements less sophisticated, can use httpclient or webclient send simple requests , parse responses manually.
nb: in case you're going parse html manually, suggest use html afgility pack: right way parse html(mainly, because "fixes" invalid tags, errors, etc).
Comments
Post a Comment