Cannot catch impersonation exception if bad usr or pwd in web.conf

W

Wim VH

I use impersonation in the web.config file. This works fine... however, when
a username and/or password is provided that are not valid on the system, an
exception is raised (which is normal!) BUT it seems there is no way to chatch
this exception.

It tried using the Application_OnError in the global.asax, but it isn't
called.

The exception I see in the "default" window of aps.net is "Could not create
Windows user token from the credentials specified in the config file. Error
from the operating system 'Logon failure: unknown user name or bad password".

This is correct, however I would like to show a page (if needen, it might be
in another web app that doesn't use impersonation) where I can tell something
like "go to you web admin and refer to item xy in the user manual of product
z".

Is this possible
 

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,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top