quilkin
asked on
Supressing SQL Failure Audit
Hi
Our app starts by opening a database which has mixed-mode authentication. When a user starts the app we try a 'trusted connection' to SQL in case the user has Windows authentication enabled. If that fails, we show a login dialog for the user to add their SQL credentials, in order to gain access.
So far so good, but the failed test for the trusted connection always results in a 'FailureAudit' (event 18456) in the Windows App Event Log. How can I supress these? I know that login errors can be supressed altogether but this would also supress 'real' failed logins.
The connection string for the first connection attempt is simply
"server=pcname\instancenam e;database =dbname;Tr usted_Conn ection=Yes "; is there a better way that would suppress the Failure Audit?
I guess we could keep an entry in the registry or ini file so that the app would 'know' next time not to try the trusted connection, but that could lead to further problems if the user is given a Windows login later.
Any ideas?
Our app starts by opening a database which has mixed-mode authentication. When a user starts the app we try a 'trusted connection' to SQL in case the user has Windows authentication enabled. If that fails, we show a login dialog for the user to add their SQL credentials, in order to gain access.
So far so good, but the failed test for the trusted connection always results in a 'FailureAudit' (event 18456) in the Windows App Event Log. How can I supress these? I know that login errors can be supressed altogether but this would also supress 'real' failed logins.
The connection string for the first connection attempt is simply
"server=pcname\instancenam
I guess we could keep an entry in the registry or ini file so that the app would 'know' next time not to try the trusted connection, but that could lead to further problems if the user is given a Windows login later.
Any ideas?
Why don't you use the SQL Connection? You will have less headache with SQL connection in you coding and more stable.
ASKER
Different users have different views on this. MS recommends Windows authentication. One reason we use it is because it gives users the option of using all Windows password security (e.g. forced changes every period, etc) without re-inventing it all. It's not an option to change it now.
By the way this issue only crops up in SQL2005, our app used MSDE before and never had this problem reported.
By the way this issue only crops up in SQL2005, our app used MSDE before and never had this problem reported.
Don't know if this forum apply to you or not?
https://www.experts-exchange.com/questions/20903608/event-viewer-security-failure-audit.html
https://www.experts-exchange.com/questions/20903608/event-viewer-security-failure-audit.html
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.