Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > Routing Userrights to another ASP.Net Webapplication

Reply
Thread Tools

Routing Userrights to another ASP.Net Webapplication

 
 
T. Beneke
Guest
Posts: n/a
 
      08-25-2008
I've got a ASP.Net Application, whos running on an IIS with integrated
security. This Application offers a download for documents who are not
hosted in the ASP.Net Application. It's hosted on a several SharePoint
Server and all servers are in the same domain. A User has access to both of
the Server.
I want to handle a request from the ASP.Net Application to the SharePoint
with the userrights (usercredential) of the current user.

Here is a samplesourcecode to explain:

Dim WC As New System.Net.WebClient
....
'WC.Credentials = CredentialCache.DefaultCredentials ' doesn't work
'WC.Credentials = CredentialCache.DefaultNetworkCredentials 'doesn't work
WC.Creddentials = New Net.NetworkCredential("mr.x", "password", "domain...")
' works fine!!! but in the current context I've got no password
Return WC.DownloadData("http://sampleserver/subdir/sample.pdf")
....

i need something like:
WC.Credentials = HttpContext.Current.User.Credentials 'this is only an
example it dosn't exist

Has anybody an idea?

Thanks
Thomas

 
Reply With Quote
 
 
 
 
Joe Kaplan
Guest
Posts: n/a
 
      08-25-2008
In order to make this type of scenario work, you need to implement Kerberos
delegation. If you are able to do that, then DefaultCredentials will work
ok.

Kerberos delegation can be a challenge to set up, but there are many
documents from Microsoft that explain how.

You probably won't change anything from a coding perspective. It is mostly
an act of configuration.

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
--
"T. Beneke" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I've got a ASP.Net Application, whos running on an IIS with integrated
> security. This Application offers a download for documents who are not
> hosted in the ASP.Net Application. It's hosted on a several SharePoint
> Server and all servers are in the same domain. A User has access to both
> of the Server.
> I want to handle a request from the ASP.Net Application to the SharePoint
> with the userrights (usercredential) of the current user.
>
> Here is a samplesourcecode to explain:
>
> Dim WC As New System.Net.WebClient
> ...
> 'WC.Credentials = CredentialCache.DefaultCredentials ' doesn't work
> 'WC.Credentials = CredentialCache.DefaultNetworkCredentials 'doesn't work
> WC.Creddentials = New Net.NetworkCredential("mr.x", "password",
> "domain...") ' works fine!!! but in the current context I've got no
> password
> Return WC.DownloadData("http://sampleserver/subdir/sample.pdf")
> ...
>
> i need something like:
> WC.Credentials = HttpContext.Current.User.Credentials 'this is only an
> example it dosn't exist
>
> Has anybody an idea?
>
> Thanks
> Thomas



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How Visalising pages from another Web application in my WebApplication jomu ASP .Net 2 12-19-2006 12:53 PM
Question about userrights ... =?Utf-8?B?c3QuZQ==?= MCSE 2 08-07-2006 09:27 AM
integrating new 3550 with routing into existing routing structure? joeblow Cisco 3 03-14-2005 08:50 AM
exchange routes between global IP routing table and VRF routing table zher Cisco 2 11-04-2004 11:28 PM
aspnet userrights - where? Mike Schwarz ASP .Net Security 1 04-16-2004 06:27 AM



Advertisments