KeyContainerPermissionAttribute Classe

Definizione

Attenzione

Code Access Security is not supported or honored by the runtime.

Consente di applicare azioni di sicurezza per KeyContainerPermission al codice usando la sicurezza dichiarativa. La classe non può essere ereditata.

public ref class KeyContainerPermissionAttribute sealed : System::Security::Permissions::CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
public sealed class KeyContainerPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public sealed class KeyContainerPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Runtime.InteropServices.ComVisible(true)]
[System.Serializable]
public sealed class KeyContainerPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
type KeyContainerPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type KeyContainerPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Runtime.InteropServices.ComVisible(true)>]
[<System.Serializable>]
type KeyContainerPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
Public NotInheritable Class KeyContainerPermissionAttribute
Inherits CodeAccessSecurityAttribute
Ereditarietà
Attributi

Commenti

Importante

Il codice parzialmente attendibile non è più supportato. Questo attributo non ha alcun effetto in .NET Core.

L'ambito della dichiarazione consentita dipende dal SecurityAction valore utilizzato.

Le informazioni di sicurezza dichiarate da un attributo di sicurezza vengono archiviate nei metadati della destinazione dell'attributo e accedono al sistema in fase di esecuzione. KeyContainerPermissionAttribute viene usato solo per la sicurezza dichiarativa. Per la sicurezza imperativa, usare la KeyContainerPermission classe .

Costruttori

KeyContainerPermissionAttribute(SecurityAction)

Inizializza una nuova istanza della classe KeyContainerPermissionAttribute con l'azione di protezione specificata.

Proprietà

Action

Ottiene o imposta un'azione di sicurezza.

(Ereditato da SecurityAttribute)
Flags

Ottiene o imposta le autorizzazioni per i contenitori di chiavi.

KeyContainerName

Ottiene o imposta il nome del contenitore di chiavi.

KeySpec

Ottiene o imposta la specifica delle chiavi.

KeyStore

Ottiene o imposta il nome dell'archivio delle chiavi.

ProviderName

Ottiene o imposta il nome del provider.

ProviderType

Ottiene o imposta il tipo di provider.

TypeId

Quando è implementata in una classe derivata, ottiene un identificatore univoco della classe Attribute.

(Ereditato da Attribute)
Unrestricted

Ottiene o imposta un valore che indica se esiste una dichiarazione di autorizzazione completa, ovvero senza restrizioni, alla risorsa protetta dall’attributo.

(Ereditato da SecurityAttribute)

Metodi

CreatePermission()

Crea e restituisce un nuovo oggetto KeyContainerPermission.

Equals(Object)

Restituisce un valore che indica se questa istanza è uguale a un oggetto specificato.

(Ereditato da Attribute)
GetHashCode()

Restituisce il codice hash per l'istanza.

(Ereditato da Attribute)
GetType()

Ottiene l'oggetto Type dell'istanza corrente.

(Ereditato da Object)
IsDefaultAttribute()

In caso di override in una classe derivata, indica se il valore di questa istanza è il valore predefinito per la classe derivata.

(Ereditato da Attribute)
Match(Object)

Quando è sottoposto a override in una classe derivata, restituisce un valore che indica se questa istanza equivale a un oggetto specificato.

(Ereditato da Attribute)
MemberwiseClone()

Crea una copia superficiale dell'oggetto Object corrente.

(Ereditato da Object)
ToString()

Restituisce una stringa che rappresenta l'oggetto corrente.

(Ereditato da Object)

Implementazioni dell'interfaccia esplicita

_Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)

Esegue il mapping di un set di nomi a un set corrispondente di ID dispatch.

(Ereditato da Attribute)
_Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)

Recupera le informazioni sul tipo relative a un oggetto, che possono essere usate per ottenere informazioni sul tipo relative a un'interfaccia.

(Ereditato da Attribute)
_Attribute.GetTypeInfoCount(UInt32)

Recupera il numero delle interfacce di informazioni sul tipo fornite da un oggetto (0 o 1).

(Ereditato da Attribute)
_Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)

Fornisce l'accesso a proprietà e metodi esposti da un oggetto.

(Ereditato da Attribute)

Si applica a

Vedi anche