473,669 Members | 2,492 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ASP.NET Network Security

I have a network drive that I need to give my asp.net program access
to. I am not allowed to use the regulat aspnet user account. Is there
any way I can create a user account or use mine within the program to
gain access to this drive?
Nov 18 '05 #1
3 1064
There are a couple of ways to handle this.

Easiest: Give ASP.NET rights. You cannot do this and it is not a wise idea
regardless, as it opens a security hole.

Easy, but a bit time consuming: Create a .NET assembly that uses Component
Services and place in COM+. You can then assign a user that the component
works under. This is simple as long as it does not depend on other
assemblies, as you may end up putting them in the GAC to make it work. If
assemblies, like your app, call on the COM+ assembly, you are fine.

Harder: Set up an identity for the thread that accesses the directory.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

*************** *************** *************** *************** **********
Think Outside the Box!
*************** *************** *************** *************** **********
"Michael" <cm********@yah oo.com> wrote in message
news:7e******** *************** *@posting.googl e.com...
I have a network drive that I need to give my asp.net program access
to. I am not allowed to use the regulat aspnet user account. Is there
any way I can create a user account or use mine within the program to
gain access to this drive?

Nov 18 '05 #2
Rak
Use impersonation to run the application under a different use

http://msdn.microsoft.com/library/de...personation.as
Nov 18 '05 #3
You are in the wrong newsgroup to start with. There is a group--
aspnet.security . Anyway look at this article and you should have everything
you need. I recently implemented Network access security architecture with
Mirrored Account. Be sure to check all the requirements.

http://msdn.microsoft.com/library/de...SecNetch08.asp

Prodip

"Michael" <cm********@yah oo.com> wrote in message
news:7e******** *************** *@posting.googl e.com...
I have a network drive that I need to give my asp.net program access
to. I am not allowed to use the regulat aspnet user account. Is there
any way I can create a user account or use mine within the program to
gain access to this drive?

Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
3642
by: Robert Tarantino | last post by:
Hello, I am trying to find a way to create a scheduled task or service that will copy my local profile folders under "Documents and settings" to a network drive. This would allow me to restore my settings if my profile became tampered with or corrupt. Is there any sample code available out there? -Robert
3
7210
by: Stanley J, Mroczek | last post by:
My disk was replaced and i reload all my software. I think that i named my computer best-si-01 instead of BEST-SI-01 and thats my error? Login failed for user 'NT AUTHORITY\NETWORK SERVICE'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details:...
4
1940
by: Boris | last post by:
I observe the following strange behavior of my application. Let say we have managed application MyApp.exe which depend on a few assemblies MyAssembly1.dll, MyAssembly2.dll and MyAssembly3.dll. The assemblies I mentione have strong names. I build the exe and all assemblies on my computer and install assemblies to GAC. I run MyApp.exe, test it and everything is OK. Then I copy all executable files (exe and dll) to our network server.
5
3104
by: Dave Kolb | last post by:
Is there any other solution for an ASPNET application to access network resources other than running as SYSTEM, using delegation (a nightmare to get to work) or the COM+ solution? I cannot seem to impersonate a user and obtain network credentials using the DuplicateTokenEx call with appropriate parameters even though the call seems to not fail. I check my identity has changed but can only still do local commands. I would consider...
3
6549
by: Uday Deo | last post by:
Hi everyone, My coworker has a simple desktop app created in VB.NET. He compiled it and posted on the network drive. When we try to run it from it's network location, it generates unhandled exception error. When we run it from local machine it runs fine. Two things I want to get clarified. 1. Does VB.NET requires any specific namespace to be imported to run the exe over network?
5
13293
by: Mitchell S. Honnert | last post by:
Is there a way, given the full path of a folder on a network, that one can programatically tell if you have Read access to that folder? I have an application where the user is able to select a number of search folders using the standard dialog control. There shouldn't be an issue with the search folder being on a local drive or a network drive. But if you don't have Read access to the folder, there's trouble. The user can see the...
2
8038
by: Jerad Rose | last post by:
I have a fairly simple C# console app which copies files from a network folder to a local folder. When the app resides on my local C: drive, it runs just fine. However, when the app resides on a network drive, copying the same files from the same source drive and to the same destination drive, it gives me the following exception: System.Security.SecurityException: Request for the permission of type...
2
2418
by: Michael | last post by:
We have an ASP.NET 2.0 web application running on a Windows 2003 domain controller. Part of that application needs to read and write files from and to a network share ( living on a MAC Xserveraid) on the same network segment. I mapped a drive on the server to that share. When mapping the drive, I could enter access credentials for the shares (an account from the Mac side that does not exist in the windows domain). Using Windows Explorer,...
6
2962
by: tendim | last post by:
G'day group. Currently our organization us using VB6 based applications, and I am trying to push forward and migrate some of the smaller things to VB.NET, eventually migrating all applications from VB6 and other legacy languages/systems (Pure VBScript, DataEase, etc.) over to .NET. Currently, *all* user data is stored on network shares. When a user logs in to a workstation, their home drive is mounted from one share, all of their...
1
7865
by: shriil | last post by:
Hi I am facing a problem with regard to opening of Access Databases, resident on pcs of my office network connected thru LAN, from my machine on the network. The folders in which these databases reside are in full share mode and the folders are accessible. All the network machines including mine have Windows XP SP2 OS and Access 2002. All the versions are registered. Whenever I am double clicking an Access Database on the network, the...
0
8465
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8383
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8895
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8658
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6210
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5682
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4386
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2032
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1788
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.