Impersonation not working...

M

Mike

Hi all,

Hopefully someone will be able to help with this issue. I have an
ASP.Net application that is trying to extract frames from .avi
and .wmv files to create thumbnails. The media files are out on a
server and the .avi files work when I set the filename property of the
MediaDet object but when I try to do that with the .wmv file I get an
error thrown at me. The files all sit in the same directory and are
processed in the same loop of code. I'm using impersonation and the
Windows Identity shows that the impersonated user is being used before
the code tries to set the filename property.

I decided to Audit the directory on the server and also check the
windows Identity before the setting of the filename property on the
MediaDet object. For the .avi and .wmv files the Windows Identity is
as follows...

{System.Security.Principal.WindowsIdentity}
AuthenticationType: "Kerberos"
Groups: {System.Security.Principal.IdentityReferenceCollection}
ImpersonationLevel: Impersonation {3}
IsAnonymous: False
IsAuthenticated: True
IsGuest: False
IsSystem: False
Name: "MYDOMAIN\MYUSER"
Owner: {System.Security.Principal.SecurityIdentifier}
Token: 1252
User: {System.Security.Principal.SecurityIdentifier}

....as you can see the user name is "MYUSER" which is who I'm
impersonating in the web config file. Now when the error is thrown the
Security log ends up with 2 entries...

Security Error 1:
Logon attempt by: MICROSOFT_AUTHENTICATION_PACKAGE_V1_0
Logon account: ASPNET
Source Workstation: WORKSTATIONNAME
Error Code: 0xC000006A

Security Error 2:
Logon Failure:
Reason: Unknown user name or bad password
User Name: ASPNET
Domain: DOMAINNAME
Logon Type: 3
Logon Process: NtLmSsp
Authentication Package: NTLM
Workstation Name: WORKSTATIONNAME
Caller User Name: -
Caller Domain: -
Caller Logon ID: -
Caller Process ID: -
Transited Services: -
Source Network Address: 10.0.0.26
Source Port: 0

....So why on earth is the ASPNET account being used for the .wmv file
and not the MYUSER user. It's like impersonation gets used for
the .avi files but not for the .wmv file. Very very weird.

Does anyone have any ideas? Thanks in advance for any help.


Cheers,


Mike Gorgone

Senior Software Engineer

PictureU
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,061
Latest member
KetonaraKeto

Latest Threads

Top