IAlgorithmConstraints.Permits Method

Definition

Overloads

Permits(ICollection<CryptoPrimitive>, IKey)

Determines whether a key is granted permission for the specified cryptographic primitives.

Permits(ICollection<CryptoPrimitive>, String, AlgorithmParameters)

Determines whether an algorithm is granted permission for the specified cryptographic primitives.

Permits(ICollection<CryptoPrimitive>, String, IKey, AlgorithmParameters)

Determines whether an algorithm and the corresponding key are granted permission for the specified cryptographic primitives.

Permits(ICollection<CryptoPrimitive>, IKey)

Determines whether a key is granted permission for the specified cryptographic primitives.

[Android.Runtime.Register("permits", "(Ljava/util/Set;Ljava/security/Key;)Z", "GetPermits_Ljava_util_Set_Ljava_security_Key_Handler:Java.Security.IAlgorithmConstraintsInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=24)]
public bool Permits (System.Collections.Generic.ICollection<Java.Security.CryptoPrimitive>? primitives, Java.Security.IKey? key);
[<Android.Runtime.Register("permits", "(Ljava/util/Set;Ljava/security/Key;)Z", "GetPermits_Ljava_util_Set_Ljava_security_Key_Handler:Java.Security.IAlgorithmConstraintsInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=24)>]
abstract member Permits : System.Collections.Generic.ICollection<Java.Security.CryptoPrimitive> * Java.Security.IKey -> bool

Parameters

primitives
ICollection<CryptoPrimitive>

a set of cryptographic primitives

key
IKey

the key

Returns

true if the key can be used for all of the specified cryptographic primitives

Attributes

Remarks

Determines whether a key is granted permission for the specified cryptographic primitives.

This method is usually used to check key size and key usage.

Java documentation for java.security.AlgorithmConstraints.permits(java.util.Set<java.security.CryptoPrimitive>, java.security.Key).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Permits(ICollection<CryptoPrimitive>, String, AlgorithmParameters)

Determines whether an algorithm is granted permission for the specified cryptographic primitives.

[Android.Runtime.Register("permits", "(Ljava/util/Set;Ljava/lang/String;Ljava/security/AlgorithmParameters;)Z", "GetPermits_Ljava_util_Set_Ljava_lang_String_Ljava_security_AlgorithmParameters_Handler:Java.Security.IAlgorithmConstraintsInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=24)]
public bool Permits (System.Collections.Generic.ICollection<Java.Security.CryptoPrimitive>? primitives, string? algorithm, Java.Security.AlgorithmParameters? parameters);
[<Android.Runtime.Register("permits", "(Ljava/util/Set;Ljava/lang/String;Ljava/security/AlgorithmParameters;)Z", "GetPermits_Ljava_util_Set_Ljava_lang_String_Ljava_security_AlgorithmParameters_Handler:Java.Security.IAlgorithmConstraintsInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=24)>]
abstract member Permits : System.Collections.Generic.ICollection<Java.Security.CryptoPrimitive> * string * Java.Security.AlgorithmParameters -> bool

Parameters

primitives
ICollection<CryptoPrimitive>

a set of cryptographic primitives

algorithm
String

the algorithm name

parameters
AlgorithmParameters

the algorithm parameters, or null if no additional parameters

Returns

true if the algorithm is permitted and can be used for all of the specified cryptographic primitives

Attributes

Remarks

Determines whether an algorithm is granted permission for the specified cryptographic primitives.

Java documentation for java.security.AlgorithmConstraints.permits(java.util.Set<java.security.CryptoPrimitive>, java.lang.String, java.security.AlgorithmParameters).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Permits(ICollection<CryptoPrimitive>, String, IKey, AlgorithmParameters)

Determines whether an algorithm and the corresponding key are granted permission for the specified cryptographic primitives.

[Android.Runtime.Register("permits", "(Ljava/util/Set;Ljava/lang/String;Ljava/security/Key;Ljava/security/AlgorithmParameters;)Z", "GetPermits_Ljava_util_Set_Ljava_lang_String_Ljava_security_Key_Ljava_security_AlgorithmParameters_Handler:Java.Security.IAlgorithmConstraintsInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=24)]
public bool Permits (System.Collections.Generic.ICollection<Java.Security.CryptoPrimitive>? primitives, string? algorithm, Java.Security.IKey? key, Java.Security.AlgorithmParameters? parameters);
[<Android.Runtime.Register("permits", "(Ljava/util/Set;Ljava/lang/String;Ljava/security/Key;Ljava/security/AlgorithmParameters;)Z", "GetPermits_Ljava_util_Set_Ljava_lang_String_Ljava_security_Key_Ljava_security_AlgorithmParameters_Handler:Java.Security.IAlgorithmConstraintsInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=24)>]
abstract member Permits : System.Collections.Generic.ICollection<Java.Security.CryptoPrimitive> * string * Java.Security.IKey * Java.Security.AlgorithmParameters -> bool

Parameters

primitives
ICollection<CryptoPrimitive>

a set of cryptographic primitives

algorithm
String

the algorithm name

key
IKey

the key

parameters
AlgorithmParameters

the algorithm parameters, or null if no additional parameters

Returns

true if the key and the algorithm can be used for all of the specified cryptographic primitives

Attributes

Remarks

Determines whether an algorithm and the corresponding key are granted permission for the specified cryptographic primitives.

Java documentation for java.security.AlgorithmConstraints.permits(java.util.Set<java.security.CryptoPrimitive>, java.lang.String, java.security.Key, java.security.AlgorithmParameters).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to