CryptoConfig.AddOID(String, String[]) CryptoConfig.AddOID(String, String[]) CryptoConfig.AddOID(String, String[]) CryptoConfig.AddOID(String, String[]) Method

定义

将一组名称添加到要用于当前应用程序域的对象标识符 (OID) 映射。Adds a set of names to object identifier (OID) mappings to be used for the current application domain.

public:
 static void AddOID(System::String ^ oid, ... cli::array <System::String ^> ^ names);
[System.Security.SecurityCritical]
public static void AddOID (string oid, params string[] names);
static member AddOID : string * string[] -> unit
Public Shared Sub AddOID (oid As String, ParamArray names As String())

参数

oid
String String String String

要映射到的对象标识符 (OID)。The object identifier (OID) to map to.

names
String[]

要映射到该 OID 的名称的数组。An array of names to map to the OID.

异常

oidnames 参数为 nullThe oid or names parameter is null.

names 参数中的一个条目是空的或为 nullOne of the entries in the names parameter is empty or null.

注解

指定的映射优先于内置映射和 machine.config 文件中的映射。The specified mappings take precedence over the built-in mappings and the mappings in the machine.config file. 这些映射用于防止部分信任的代码使用受信任的加密操作。The mappings are used to prevent partially trust code from using trusted cryptographic operations.

安全性

SecurityCriticalAttribute
需要对直接调用方的完全信任。requires full trust for the immediate caller. 部分受信任的或透明的代码不能使用此成员。This member cannot be used by partially trusted or transparent code.

适用于