Re: Pass credentials from Win app to Web app
- From: "Joe Kaplan" <joseph.e.kaplan@xxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 5 Feb 2008 08:55:05 -0600
Are you wanting to authenticate the user in the web app against SQL as well?
If so, you might consider using HttpWebRequest to "screen scrape" the login
process to your web app and get a login cookie for the user. Then, try to
find a way to pass that cookie to IE so that it will be provided to the
server by the browser control. That will make it look to the web app on the
server as if the user has already logged in.
I'm not sure if there is a way to pass cookies to use into the browser
control or not, but hopefully there is.
If not, you might need to create some sort of custom login mechanism via a
query string that performs the login and do some of the heavy lifting
yourself to implement the credentials collection and login process in an
HttpModule or Global.asax event handler instead of the normal login form
page.
Joe K.
--
Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--
"Eric" <Eric@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:AA166328-9A09-43C5-9C0F-1364790FED23@xxxxxxxxxxxxxxxx
I'm using ASP.net Authentication and Authorization (Sql provider against
standard aspnetdb) in my VB.net Windows App to handle users, roles, etc.
This works great.
Within my win app, using the .net web browser control, I want to launch a
url (in our intranet, ASP.Net hosted in IIS6, Win Srv 2003 R2), but I
don't
want the user to have to go through the forms login process again, since
they've already been authenticated by my win app.
Is their a way to pass the user's credentials from the win app to the web
app? Perhaps in some sort of encrypted query string? Is their a method
similar to using windows security with web services, such as:
myProxy.Credentials = System.Net.CredentialCache.DefaultCredentials ?
Thanks!
.
- Prev by Date: Re: Authentication, Singal Sign On and AD
- Next by Date: S4U Kerberos for calling WCF services
- Previous by thread: Re: Authentication, Singal Sign On and AD
- Next by thread: S4U Kerberos for calling WCF services
- Index(es):
Relevant Pages
|