Win32_EncryptableVolume 类的 GetKeyProtectorType 方法

Win32_EncryptableVolume 类的 GetKeyProtectorType 方法指示给定密钥保护程序的类型。

语法

uint32 GetKeyProtectorType(
  [in]  string VolumeKeyProtectorID,
  [out] uint32 KeyProtectorType
);

参数

VolumeKeyProtectorID [in]

类型: 字符串

用于管理加密卷密钥保护程序的唯一字符串标识符。

KeyProtectorType [out]

类型: uint32

一个无符号整数,指定密钥保护程序的类型。

含义
0
未知或其他保护程序类型
1
受信任的平台模块 (TPM)
2
外部键
3
数字密码
4
TPM 和 PIN
5
TPM 和启动密钥
6
TPM 和 PIN 以及启动密钥
7
公钥
8
通行短语
9
TPM 证书
10
CryptoAPI 下一代 (CNG) 保护器

 

返回值

类型: uint32

此方法返回以下代码之一,如果失败,则返回另一个错误代码。

返回代码/值 说明
S_OK
0 (0x0)
方法成功。
E_INVALIDARG
2147942487 (0x80070057)
VolumeKeyProtectorID 参数不引用有效的 KeyProtectorType
FVE_E_NOT_ACTIVATED
2150694920 (0x80310008)
未在卷上启用 BitLocker。 添加密钥保护程序以启用 BitLocker。

 

备注

托管对象格式 (MOF) 文件包含 Windows Management Instrumentation (WMI) 类的定义。 MOF 文件未作为 Windows SDK 的一部分安装。 使用 服务器管理器添加关联角色时,它们安装在服务器上。 有关 MOF 文件的详细信息,请参阅 托管对象格式 (MOF)

要求

要求
最低受支持的客户端
Windows Vista 企业版,Windows Vista 旗舰版 [仅限桌面应用]
最低受支持的服务器
Windows Server 2008 [仅限桌面应用]
命名空间
Root\CIMV2\Security\MicrosoftVolumeEncryption
MOF
Win32_encryptablevolume.mof

另请参阅

Win32_EncryptableVolume