SqlClientPermission Class
Assembly: System.Data (in system.data.dll)
'Declaration <SerializableAttribute> _ Public NotInheritable Class SqlClientPermission Inherits DBDataPermission 'Usage Dim instance As SqlClientPermission
/** @attribute SerializableAttribute() */ public final class SqlClientPermission extends DBDataPermission
SerializableAttribute public final class SqlClientPermission extends DBDataPermission
Not applicable.
The IsUnrestricted property takes precedence over the AllowBlankPassword property. Therefore, if you set AllowBlankPassword to false, you must also set IsUnrestricted to false to prevent a user from making a connection using a blank password.
Note: |
|---|
| When using code access security permissions for ADO.NET, the correct pattern is to start with the most restrictive case (no permissions at all) and then add the specific permissions that are needed for the particular task that the code needs to perform. The opposite pattern, starting with all permissions and then denying a specific permission, is not secure, because there are many ways of expressing the same connection string. For example, if you start with all permissions and then attempt to deny the use of the connection string "server=someserver", the string "server=someserver.mycompany.com" would still be allowed. By always starting by granting no permissions at all, you reduce the chances that there are holes in the permission set. |
System.Security.CodeAccessPermission
System.Data.Common.DBDataPermission
System.Data.SqlClient.SqlClientPermission
Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.
Note: