[comment]: # translation:outdated

[comment]: # aside:1

[comment]: # ({55e035dc-c8ce81a4})
# MFA 对象

以下内容是关于 `mfa` 接口。

[comment]: # ({/55e035dc-c8ce81a4})

[comment]: # ({264055a6-fcc631a5})
### MFA

MFA（多因素认证）对象具有以下属性。

|属性|[类型](/manual/api/reference_commentary#data-types)|说明|
|--|--|------|
|mfaid|ID|MFA 方法的 ID。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- *只读*<br>- *更新操作时*必填|
|type|integer|MFA 方法的类型。<br><br>可能的值：<br>1 - TOTP（基于时间的一次性密码）；<br>2 - Duo Universal Prompt。|
|name|string|MFA 方法的唯一名称。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- *创建操作时*必填|
|hash\_function|integer|用于生成 TOTP 代码的哈希函数类型。<br><br>可能的值：<br>1 - SHA-1；<br>2 - SHA-256；<br>3 - SHA-512。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- 当 `type` 设置为 “TOTP” 时，*必填*|
|code\_length|integer|验证码长度。<br><br>可能的值：<br>6 - 6 位长度；<br>8 - 8 位长度。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- 当 `type` 设置为 “TOTP” 时，*必填*|
|api\_hostname|string|Duo 认证服务提供的 API 主机名。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- 当 `type` 设置为 “Duo Universal Prompt” 时，*必填*|
|clientid|string|Duo 认证服务提供的客户端 ID。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- 当 `type` 设置为 “Duo Universal Prompt” 时，*必填*|
|client\_secret|string|Duo 认证服务提供的客户端密钥。<br><br>[属性行为](/manual/api/reference_commentary#property-behavior)：<br>- *只写*<br>- 当 `type` 设置为 “Duo Universal Prompt” 时，*必填*|

[comment]: # ({/264055a6-fcc631a5})
