ServerPermissionSet ServerPermissionSet ServerPermissionSet Class

Definition

The ServerPermissionSet object represents a set of server permissions.

public ref class ServerPermissionSet sealed : Microsoft::SqlServer::Management::Smo::PermissionSetBase
public sealed class ServerPermissionSet : Microsoft.SqlServer.Management.Smo.PermissionSetBase
Public NotInheritable Class ServerPermissionSet
Inherits PermissionSetBase
Inheritance
ServerPermissionSetServerPermissionSetServerPermissionSet

Examples

Granting, Revoking, and Denying Permissions

Remarks

Server permissions are required when you grant, deny, or revoke server-level permissions on an instance of SQL Server. The ServerPermissionSet object is required to specify the set of permissions that apply to the Grant method, the Deny method, and the Revoke method of the Server object.

Thread Safety

Any public static (Shared in Microsoft Visual Basic) members of this type are safe for multithreaded operations. Any instance members are not guaranteed to be thread safe.

Constructors

ServerPermissionSet() ServerPermissionSet() ServerPermissionSet()

Initializes a new instance of the ServerPermissionSet class.

ServerPermissionSet(ServerPermission) ServerPermissionSet(ServerPermission) ServerPermissionSet(ServerPermission)

Initializes a new instance of the ServerPermissionSet class based on the specified permission.

ServerPermissionSet(ServerPermissionSet) ServerPermissionSet(ServerPermissionSet) ServerPermissionSet(ServerPermissionSet)

Initializes a new instance of the ServerPermissionSet class based on the specified set of permissions.

ServerPermissionSet(ServerPermission[]) ServerPermissionSet(ServerPermission[]) ServerPermissionSet(ServerPermission[])

Initializes a new instance of the ServerPermissionSet class based on the specified set of permissions.

Properties

AdministerBulkOperations AdministerBulkOperations AdministerBulkOperations

Gets or sets the Boolean property value that specifies whether to include the ADMINISTER BULK OPERATIONS (ADBO) permission in the permission set. This permission lets the grantee perform bulk insert operations on the instance of SQL Server, such as importing data by using the bcp command, using the BULK INSERT statement, or using the INSERT…SELECT * FROM OPENROWSET(BULK…) statement.

AlterAnyAvailabilityGroup AlterAnyAvailabilityGroup AlterAnyAvailabilityGroup

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY AVAILABILITY GROUP permission in the permission set. This permission lets the grantee create, alter, or drop any availability group on the instance of SQL Server.

AlterAnyConnection AlterAnyConnection AlterAnyConnection

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY CONNECTION (ALCO) permission in the permission set. This permission lets the grantee create, alter, or drop any connection on the instance of SQL Server.

AlterAnyCredential AlterAnyCredential AlterAnyCredential

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY CREDENTIAL (ALCD) permission in the permission set. This permission lets the grantee create, alter, or drop any credential on the instance of SQL Server.

AlterAnyDatabase AlterAnyDatabase AlterAnyDatabase

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY DATABASE (ALDB) permission in the permission set. This permission lets the grantee create, alter, or drop any database on the instance of SQL Server.

AlterAnyEndpoint AlterAnyEndpoint AlterAnyEndpoint

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY ENDPOINT (ALHE) permission in the permission set. This permission lets the grantee create, alter, or drop any endpoint on the instance of SQL Server.

AlterAnyEventNotification AlterAnyEventNotification AlterAnyEventNotification

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY EVENT NOTIFICATION (ALES) permission in the permission set. This permission lets the grantee to create, alter, or drop any event notification on the instance of SQL Server.

AlterAnyEventSession AlterAnyEventSession AlterAnyEventSession

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY EVENT SESSION permission in the permission set. This permission lets the grantee create, alter, or drop any event session on the instance of SQL Server.

AlterAnyLinkedServer AlterAnyLinkedServer AlterAnyLinkedServer

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY LINKED SERVER (ALLS) permission in the permission set. This permission lets the grantee create, alter, or drop any linked server on the instance of SQL Server.

AlterAnyLogin AlterAnyLogin AlterAnyLogin

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY LOGIN (ALLG) permission in the permission set. This permission lets the grantee create, alter, or drop any login on the instance of SQL Server.

AlterAnyServerAudit AlterAnyServerAudit AlterAnyServerAudit

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY SERVER AUDIT permission in the permission set. This permission lets the grantee stop, start, or pause the instance of SQL Server.

AlterAnyServerRole AlterAnyServerRole AlterAnyServerRole

Gets or sets the Boolean property value that specifies whether to include the ALTER ANY SERVER ROLE permission in the permission set. This permission lets the grantee stop, start, or pause the instance of SQL Server.

AlterResources AlterResources AlterResources

Gets or sets the Boolean property value that specifies whether to include the ALTER RESOURCES (ALRS) permission in the permission set. This permission lets the grantee create, alter, or drop any resource on the instance of SQL Server.

AlterServerState AlterServerState AlterServerState

Gets or sets the Boolean property value that specifies whether to include the ALTER SERVER STATE (ALSS) permission in the permission set. This permission lets the grantee stop, start, or pause the instance of SQL Server.

AlterSettings AlterSettings AlterSettings

Gets or sets the Boolean property value that specifies whether to include the ALTER SETTINGS (ASLT) permission in the permission set. This permission lets the grantee alter any settings on the instance of SQL Server, such as the default database directory.

AlterTrace AlterTrace AlterTrace

Gets or sets the Boolean property value that specifies whether to include the ALTER TRACE (ALTR) permission in the permission set. This permission lets the grantee start, or stop trace runs or modify the trace options on the instance of SQL Server.

AuthenticateServer AuthenticateServer AuthenticateServer

Gets or sets the Boolean property value that specifies whether to include the AUTHENTICATE SERVER permission in the permission set. This permission lets the grantee authenticate with the instance of SQL Server.

ConnectAnyDatabase ConnectAnyDatabase ConnectAnyDatabase

Gets or sets the Boolean property value that specifies whether to include the CONNECT ANY DATABASE permission in the permission set. This permission lets the grantee connect to any database on the instance of SQL Server.

ConnectSql ConnectSql ConnectSql

Gets or sets the Boolean property value that specifies whether to include the CONNECT SQL (COSQ) permission in the permission set. This permission lets the grantee connect to the instance of SQL Server.

ControlServer ControlServer ControlServer

Gets or sets the Boolean property value that specifies whether to include the CONTROL SERVER (CL) permission in the permission set. This permission lets the grantee grant any permission on any securable on the instance of SQL Server.

CreateAnyDatabase CreateAnyDatabase CreateAnyDatabase

Gets or sets the Boolean property value that specifies whether to include the CREATE ANY DATABASE (CRDB) permission in the permission set. This permission lets the grantee create, alter, or drop any database on the instance of SQL Server.

CreateAvailabilityGroup CreateAvailabilityGroup CreateAvailabilityGroup

Gets or sets the Boolean property value that specifies whether to include the CREATE AVAILABILITY GROUP permission in the permission set. This permission lets the grantee create, alter, or drop availability group on the instance of SQL Server.

CreateDdlEventNotification CreateDdlEventNotification CreateDdlEventNotification

Gets or sets the Boolean property value that specifies whether to include the CREATE DDL EVENT NOTIFICATION (CRDE) permission in the permission set. This permission lets the grantee create any DDL (Data Definition Language) event notification on the instance of SQL Server, such as the event that is raised when a database is created.

CreateEndpoint CreateEndpoint CreateEndpoint

Gets or sets the Boolean property value that specifies whether to include the CREATE ENDPOINT (CRHE) permission in the permission set. This permission lets the grantee create endpoints on the instance of SQL Server for SOAP, Transact-SQL, database mirroring, and Service Broker.

CreateServerRole CreateServerRole CreateServerRole

Gets or sets the Boolean property value that specifies whether to include the CREATE SERVER ROLE permission in the permission set. This permission lets the grantee create server role on the instance of SQL Server.

CreateTraceEventNotification CreateTraceEventNotification CreateTraceEventNotification

Gets or sets the Boolean property value that specifies whether to include the CREATE TRACE EVENT NOTIFICATION (CRTE) permission in the permission set. This permission lets the grantee create trace event notifications on the instance of SQL Server.

ExternalAccessAssembly ExternalAccessAssembly ExternalAccessAssembly

Gets or sets the Boolean property value that specifies whether to include the EXTERNAL ACCESS (XA) permission in the permission set. This permission lets the grantee access external system resources such as assembly files, networks, environmental variables, and the registry.

ImpersonateAnyLogin ImpersonateAnyLogin ImpersonateAnyLogin

Gets or sets the Boolean property value that specifies whether to include the IMPERSONATE ANY LOGIN permission in the permission set. This permission lets the grantee impersonate any login on the instance of SQL Server.

SelectAllUserSecurables SelectAllUserSecurables SelectAllUserSecurables

Gets or sets the Boolean property value that specifies whether to include the SELECT ALL USER SECURABLES permission in the permission set. This permission lets the grantee select all user securables on the instance of SQL Server.

Shutdown Shutdown Shutdown

Gets or sets the Boolean property value that specifies whether to include the SHUTDOWN (SHDN) permission in the permission set. This permission lets the grantee stop the SQL Server service.

UnsafeAssembly UnsafeAssembly UnsafeAssembly

Gets or sets the Boolean property value that specifies whether to include the UNSAFE permission in the permission set. This permission allows the grantee unrestricted access to resources, both within and outside SQL Server, including calls to unmanaged code

ViewAnyDatabase ViewAnyDatabase ViewAnyDatabase

Gets or sets the Boolean property value that specifies whether to include the VIEW ANY DATABASE (VWDB) permission in the permission set. This permission lets the grantee view the definition (metadata) of any database on the instance of SQL Server.

ViewAnyDefinition ViewAnyDefinition ViewAnyDefinition

Gets or sets the Boolean property value that specifies whether to include the VIEW ANY DEFINITION (VWAD) permission in the permission set. This permission lets the grantee view the definition of any server that is securable on the instance of SQL Server.

ViewServerState ViewServerState ViewServerState

Gets or sets the Boolean property value that specifies whether to include the VIEW SERVER STATE (VWSS) permission in the permission set. This permission lets the grantee view the state of the instance of SQL Server.

Methods

Add(ServerPermission) Add(ServerPermission) Add(ServerPermission)

Returns a server permission set after adding a new server permission to the referenced permission set.

Add(ServerPermissionSet, ServerPermission) Add(ServerPermissionSet, ServerPermission) Add(ServerPermissionSet, ServerPermission)

Returns a server permission set after adding a new server permission to the specified permission set.

Equals(Object) Equals(Object) Equals(Object)

Determines whether the referenced server permission object is equal to a specified object.

GetHashCode() GetHashCode() GetHashCode()

Do not reference this member directly in your code. It supports the SQL Server infrastructure.

Remove(ServerPermission) Remove(ServerPermission) Remove(ServerPermission)

Removes a permission from the permission set.

Subtract(ServerPermissionSet, ServerPermission) Subtract(ServerPermissionSet, ServerPermission) Subtract(ServerPermissionSet, ServerPermission)

Returns a server permission set after subtracting a server permission from the specified permission set.

ToString() ToString() ToString()

Returns the string value that represents the specified PermissionSetBase object.

(Inherited from PermissionSetBase)

Operators

Addition(ServerPermissionSet, ServerPermission) Addition(ServerPermissionSet, ServerPermission) Addition(ServerPermissionSet, ServerPermission)

Creates a server permission set by performing an addition operation on a ServerPermission object and a ServerPermissionSet object.

Equality(ServerPermissionSet, ServerPermissionSet) Equality(ServerPermissionSet, ServerPermissionSet) Equality(ServerPermissionSet, ServerPermissionSet)

Determines whether two objects are equal by performing an equality operation on two ServerPermissionSet objects.

Inequality(ServerPermissionSet, ServerPermissionSet) Inequality(ServerPermissionSet, ServerPermissionSet) Inequality(ServerPermissionSet, ServerPermissionSet)

Determines whether two objects are unequal by performing an inequality operation on two ServerPermissionSet objects.

Subtraction(ServerPermissionSet, ServerPermission) Subtraction(ServerPermissionSet, ServerPermission) Subtraction(ServerPermissionSet, ServerPermission)

Creates a server permission set by performing a subtraction operation on a ServerPermission object and a ServerPermissionSet object.

Applies to