SCM

[#1010682] Allow for user mapping when using Integrated Security

View Trackers | Feature Requests | Download .csv | Monitor

Date:
2009-08-03 22:47
Priority:
3
State:
Open
Submitted by:
Adam Ruth (adamowski)
Assigned to:
Nobody (None)
Category:
Group:
Resolution:
None
 
Summary:
Allow for user mapping when using Integrated Security

Detailed description
When using Integrated Security with version 8.4 it is possible to log in as a database user other than the currently logged on OS user (assuming that the proper pg_ident.conf entries.)

All that is required is to pass in a User ID during authentication other than the OS user name. I made a one line patch to the sources for 2.0.6 to do this for my environment. I'm not sure how this would work with earlier versions, it may need some version checking added.

I don't know the proper syntax for patches (I'm a patch virgin :-), but since it's just one line, I'll put it here.

File: NpgsqlConnectionStringBuilder.cs line 393 in UserName:get

if (_integrated_security && _username == string.Empty) // added the test for user name empty

If the User ID is set in the connection string, then the user name isn't taken from WindowsIdentity.




Followup

No Followups Have Been Posted

Attached Files:

Changes:

No Changes Have Been Made to This Item

Powered By FusionForge