Impersonation is a process whereby an application assumes another identity or security context during execution.
Questions tagged [impersonation]
1522 questions
7
votes
1 answer
Set up impersonation with ASP.NET
for a first understanding, I have created a very simple project which tries to count the number of files in two directories. User1 is not allowed to access Directory2 and User2 is not allowed to access Directory1. Due to impersonation I should get…

Carsten Franke
- 1,649
- 2
- 13
- 30
7
votes
2 answers
ASP.NET CORE 1.0, Impersonation
I'm writing an Intranet application. Target framework in project.json is dnx451.
That's my publishing command:
dnu publish --runtime dnx-clr-win-x86.1.0.0-rc1-update1 --no-source
Database Connection…

Dani
- 971
- 12
- 31
7
votes
2 answers
why does windows authentication / impersonation fail on asp.net application with iis 7.5 / windows 7 /
I'm troubleshooting why I can't get past the login dialog on an ASP.Net site configured for Windows Authentication and Impersonation.
I have an ASP.Net 2.0 application and I'm trying to deploy it on Windows 7 with IIS 7.5. I've created a new site,…

unknown
- 193
- 1
- 2
- 7
7
votes
3 answers
Admin service: log user into desktop, spawn a process that can interact with the desktop
I'm having a difficult time getting a very specific use case to work. The application in question has two components: a Windows service, which needs to run in a privileged context outside of the desktop (i.e. to accept connections while a user is…

joelc
- 2,687
- 5
- 40
- 60
7
votes
1 answer
Execute query to linked server as another user
I'd like to execute a query which uses linked server as a specific user. However, not even a simple example works.
When I opem SSMS as user "domain\user", connect to "serverA" and run following code:
EXECUTE ('SELECT col FROM…

dpelisek
- 884
- 3
- 13
- 22
7
votes
5 answers
Not passing Credentials to WCF Service resulting in a 401
I'm tearing my hair out on this one, I have a WCF service that I can call through the browser and it works fine, when I call it from the web application with the below method I get a (401) Unauthorized error. And the service does not get called. …

Joshy
- 657
- 8
- 20
7
votes
6 answers
Why does Windows not allow WinSock to be started while impersonating another user
Using my own program or others I can't get winsock to run when calling if the process is created with CreateProcessWithLogonW or CreateProcessAsUserW. It returns this error when I create the socket:
WSAEPROVIDERFAILEDINIT 10106
Service provider…

Christopher Tarquini
- 11,176
- 16
- 55
- 73
7
votes
2 answers
Entity Framework 5 - Implementing SQL Server "Execute As User"
I am writing a database application using Visual Studio 2012 with Entity Framework 5 and SQL Server 2008. I would like Entity Framework to impersonate a SQL Server user (i.e. user without a login). I have created a new constructor for the DB…

HydroPowerDeveloper
- 3,302
- 7
- 31
- 38
7
votes
2 answers
Impersonate a user
We are developing a C# .NET windows service.
Our service is running under the system account, and we are trying to impersonate the logged in user USER.
The impersonation works ok, i.e. when calling…

user844541
- 2,868
- 5
- 32
- 60
7
votes
3 answers
Reading hidden share in C#
So I have a small C# app that needs to periodically check the contents of directories on multiple machines on the network. I thought I could just read \hostname\C$ as a directory path, but with the normal Directory class there doesn't seem to be a…

C Hogg
- 1,001
- 10
- 15
7
votes
1 answer
SharePoint 2013 / IIS 7.5 Impersonation/Delegation/Double Hop
Ok, I have spent about 15 hours trying to resolve this problem and I have finally been resigned to posting here to try to get it resolved. I know this post is very long but I have done all the normal things that I'm going to be told to try so I…

user456151
- 71
- 1
- 3
7
votes
2 answers
get Current user context
I've got problems with running a powershellscript from different locations (c# application, webservice...).
I think it is a user context problem, so now I'm trying to find out under which user context powershell script is running.
Is there any…

HW90
- 1,953
- 2
- 21
- 45
7
votes
1 answer
Adding jobs to a specific user's PrintQueue
I have an application that does some central file generation based on user requests. What I want to be able to do with it once the files are created is to place them in that user's print queue ( in this organisation there is a central print queue so…

glenatron
- 11,018
- 13
- 64
- 112
7
votes
4 answers
Impersonation in IIS 7.0
I have a website that works correctly under IIS 6.0: It authenticates users with windows credentials, and then when talking to the service that hits the DB, it passes the credentials.
In IIS 7.0, the same config settings do not pass the credentials,…

Esteban Araya
- 29,284
- 24
- 107
- 141
6
votes
2 answers
Impersonating a user on Mac OS X
On Windows it is possible to have a service that allows clients running in a user context to connect to it using sockets or pipes, and then impersonate the connecting user in order to act on behalf of that user, for instance to access files that…

villintehaspam
- 8,540
- 6
- 45
- 76