Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > How to specify security access for assembly running in ASP.NET

Reply
Thread Tools

How to specify security access for assembly running in ASP.NET

 
 
Shimon Sim
Guest
Posts: n/a
 
      03-01-2006
How to specify security access for assembly running in ASP.NET?

FxCop requests it always and I always ignore it. I am thinking that this is
good thing to know how to do.

I usually need the same rights that asp.net process has. The dll needs to
write some files under directory - usually but some times not.

Thank

Shimon


 
Reply With Quote
 
 
 
 
Steven Cheng[MSFT]
Guest
Posts: n/a
 
      03-02-2006
Hi Shimon,

Welcome to the MSDN newsgroup.

As for the security access setting for .net assembly in ASP.NET web
application, it is divided into two parts:

1. By default, the .NET Code Access security (CAS) setting for ASP.NET
application is at "Full" trust level, so there is not limit for .net
security restriction on the managed code executing in ASP.NET applcation.
What we need to take care of is the raw windows OS level security. This
concern with the ASP.NET's process identity (or the impersonated account)
with those protected resource our ASP.NET application will access(such as
eventlog, registry, filesystem....).

2. Also, we can apply .net's code access security setting (policy) for the
code, assembly in our ASP.NET web application. This security is configured
and checked within the .net managed runtime, independent of the operating
system's security. Here are some msdn reference on applying .net CAS to
ASP.NET web application:

#Chapter 9 ĘC Using Code Access Security with ASP.NET
http://msdn.microsoft.com/library/de...us/dnnetsec/ht
ml/THCMCh09.asp

#How To: Use Code Access Security in ASP.NET 2.0
http://msdn.microsoft.com/library/de...us/dnpag2/html
/paght000017.asp

Hope this helps.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)







 
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
Error: "Please specify the assembly explicitly in the type name" while migrating web project 1.1 to 2.0 Lucky ASP .Net 1 05-19-2006 02:10 PM
Assembly acessing StrongNamed assembly getting "Access Denied" intermitently Chris Herring ASP .Net Security 0 05-04-2005 02:35 PM
Specify security access in JNLP Gerrit Hulleman Java 0 07-21-2004 08:01 AM
Referencing assembly from GAC using @assembly fails Brent ASP .Net 1 01-23-2004 08:23 PM
can a strongly named assembly reference a regular assembly? Prasanna Padmanabhan ASP .Net 1 11-19-2003 06:21 AM



Advertisments