10 December 2012

Interesting Code Exception–UnwillingToPerform

I have recently been busy putting the finishing touches on a new web application for a client in Indiana.  During the course of the project, we discovered that we needed to write a custom membership provider that would use secure LDAP to authenticate users (the ActiveDirectoryMembershipProvider does not, surprisingly, support the client's environment setup). 

While developing the basic provider was relatively easy to complete (and used an Oracle LDAP provider we built previously), we ran into a series of challenges.  One challenge is now a support incident at Microsoft (more on that in a later blog).

However, during one of the debugging sessions, we noticed an "unspecified operation error occurred" exception being thrown.  Digging down, we discovered the reason code: "unwilling to perform"

image

I have never thought about putting that kind of reason in my code, but if Microsoft can do it, perhaps it's O.K. Smile

No comments: