views:

39

answers:

2

I'd like to deny access to query linked servers to a group of users. I've put them in a role and assigned certain permissions to object level permissions to the that group. I'm at a loss after searching BOL and 'net how to DENY access to linked servers.

EDIT:

I decided to break out profiler to verify exactly what SSMS is calling when displaying linked servers and ensure that a DENY was issued on that system view/SP. Turns out it calls sys.servers, but Sql Server doesn't honor the ACL on this system view -- It's does to other system views (ex: sys.dm_db_index_physical_stats).

+3  A: 

Afaik referencing a linked server is not controlled by access control lists (ACLs). In other words, you cannot GRANT/DENY/REVOKE permission to use a linked server. You can certainly control the permission to change a linked server via ALTER ANY LINKED SERVER permission.

This apparent lack of permission is because the linked servers are forwarding specific credentials to the remote server, controlled via the impersonation or the remote_logins settings associated with the linked server. The actual access control happens on the remote server, using the credentials associated with the linked server. So in order to deny a group of users access to the linked server, you need to deny that group access to the remote server on the remote server itself.

Remus Rusanu
Depending on your setup, I guess you could also attempt to use the login mapping feature. Typically, I would prefer integrated security and handle everything with proper permissions on actual users based on their actual identity.
Cade Roux
@Remus I was hoping there was a way to do this. I remember using a tool on Sql Server 200 that would alter permissions on system objects to prevent some users from being able to see the list of linked servers, but not the ability to query them. In this case they can't use integrated security for all linked server, however for some I can modify the settings. Thanks for the response.
Chad
A: 

The type of authentication is of importance. When you link the servers they have to be linked using Kerberos and then you can control the access on the linked server. Otherwise your group will always be authenticated on the credentials specified in the link.

bjorsig