473,408 Members | 2,535 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Impersonation problem

Hi All,

I have created a User 'TestUser' and allow them to read/write permission on a file system in a machine. Whenever I logged in with the credential with TestUser then I can create/delete/access that file system. I have another machine where I have hosted a web service and used .net impersonation and passed the credential of TestUser to that web service. When I tried to create a file on that machine then it shows the error Access Denied. And If I used Administrator credential or another user's credential to create the file then it does not show any error and creates the files successfully. I do not understand what is the problem. Would you please let me know the solution?
Mar 9 '09 #1
3 1253
PRR
750 Expert 512MB
@pankajprakash
As far as i can see, the "TestUser" does not have rights on your webservice machine...use an account the has access rights .. and make sure you use impersonation....
Mar 10 '09 #2
Thanks for your replay. I have created an independent user account TestUser and allow him to loggin to that another machine (suppose MachineA). He can create/delete/access that particular file/folder on that machine. Now I had a web service on another machine (suppose MachineB). I had used impersonation with that TestUser credential. When I go to the impersonation function it return true, however when that web service create a file on MachineA it occours the error Access denied. I am still not able to understand the problem.
Mar 10 '09 #3
PRR
750 Expert 512MB
Thats due to worker threads in asp.net and web service... check this...for more info...
Or you could do this
Expand|Select|Wrap|Line Numbers
  1. <authentication mode="Windows" />
  2. <identity impersonate="true" />
  3.  
Turn off anonymous access in iis for this to work...
Mar 11 '09 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Chris | last post by:
Hello all, Here is my problem. I have a windows service (C#) that is supposed to move files from/to the local drive to/from a UNC share (\\domainserver\share). The service is running on a Win3k...
12
by: Anil Krishnamurthy | last post by:
We have an ASP.NET application that uses COM objects through Interop. The web application requires access to network and database resources and hence, needs to impersonate a domain account. The...
1
by: techfuzz | last post by:
I'm posting my problem experience and solution I found here for other ASP.NET developers. I have a web application that uses Forms Authentication with Active Directory to control access. In...
8
by: Anthony Munter | last post by:
I have a web application with impersonate=”true” in Web.config and on my own logon page I allow the user to either - specify a userid/password for the app to impersonate when calling legacy...
3
by: Jake Smythe | last post by:
Hello, I have some code that impersonates a user upon launching of the application. We now have the need to run some command line items. The impersonation doesn't seem to pass to the commands...
11
by: Phil | last post by:
Hi, I've currently setup a local user as described in: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnne...
0
by: velvet.graham | last post by:
I'm having a difficult time with impersonation. I've created an impersonation class. Here is the code below: ******Impersonation Class Code********* Imports System Imports System.Web.Security...
4
by: David Cablalero | last post by:
I have a windows service which every night checks a SQL Server database for some data and business rules. The application can access different DBs with the same structure, to tell the service which...
8
by: Marco Mechelli | last post by:
Hello, i'm facing with the following problem while using the Job API during an impersonation. I have a main process that needs to do the following: 1. Creates a new Job Object that will be...
0
by: Brian | last post by:
Greetings! I'm trying to find a good place to call SqlCacheDependency.Start() and I'm running into some issues. I know this isn't a SQL forum, but this seems more like an ASP.NET lifetime...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development projectplanning, coding, testing,...
0
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...

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.