<PackageReference Include="System.Security.Permissions" Version="10.0.0-preview.2.25163.2" />

KeyContainerPermissionAttribute

Allows security actions for KeyContainerPermission to be applied to code using declarative security. This class cannot be inherited.
public KeyContainerPermissionFlags Flags { get; set; }

Gets or sets the key container permissions.

public string KeyContainerName { get; set; }

Gets or sets the name of the key container.

public int KeySpec { get; set; }

Gets or sets the key specification.

public string KeyStore { get; set; }

Gets or sets the name of the key store.

public string ProviderName { get; set; }

Gets or sets the provider name.

public int ProviderType { get; set; }

Gets or sets the provider type.

Initializes a new instance of the KeyContainerPermissionAttribute class with the specified security action.