Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.databases.ms-sqlserver    |    Notorious Rube Goldberg contraption    |    19,505 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 17,777 of 19,505    |
|    Erland Sommarskog to Matthew Wells    |
|    Re: Windows Auth issue    |
|    11 Mar 10 23:13:14    |
      From: esquel@sommarskog.se              Matthew Wells (matthew.wells@firstbyte.net) writes:       > I have one machine with an application running that many users need to       > log in and out of quickly. Logging off the machine, logging in and       > restarting the app takes too long. Users already log into the       > application using their windows login and password which I check against       > the AD, then I build connections strings so SQL Server knows who is       > logged in - which I need for auditing. Using SQL authentication is not       > an option.       >       > Is it possible to make a connection string to SQL Server using Windows       > Authentication using a different windows user than the one logged into the       > machine?              No. You could use the RunAs functionality in Windows to impersonate the       user.              The other alternative is to have the Windows session being logged in by a       service user. This server would then do an EXECUTE AS LOGIN when connected       to SQL Server. Or use SET CONTEXT_INFO and then the context_info()       function, but that may require you to do changes to the SQL code.                     --       Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se              Links for SQL Server Books Online:       SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx       SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx       SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca