1# IUserAuthInterface 2 3 4## 概述 5 6声明用户认证驱动的API接口。 7 8**起始版本:** 4.1 9 10**相关模块:**[HdfUserAuth](_hdf_user_auth_v12.md) 11 12 13## 汇总 14 15 16### Public 成员函数 17 18| 名称 | 描述 | 19| -------- | -------- | 20| [Init](#init) () | 初始化用户认证驱动缓存信息,用于用户认证框架进程启动时初始化信息。 | 21| [AddExecutor](#addexecutor) ([in] struct [ExecutorRegisterInfo](_executor_register_info_v12.md) info, [out] unsigned long index, [out] unsigned char[] publicKey, [out] unsigned long[] templateIds) | 添加认证执行器来获取认证能力,用于各认证基础服务如口令认证服务等将认证能力对接到用户认证框架。 | 22| [DeleteExecutor](#deleteexecutor) ([in] unsigned long index) | 删除执行器,用于清理失效的执行器信息。 | 23| [OpenSession](#opensession) ([in] int userId, [out] unsigned char[] challenge) | 开启一个认证凭据管理会话,用于在请求管理用户认证凭据前获取有效挑战值。 | 24| [CloseSession](#closesession) ([in] int userId) | 关闭认证凭据管理会话,完成用户认证凭据管理请求处理后,调用该接口使原挑战值失效。 | 25| [BeginEnrollment](#beginenrollment) ([in] int userId, [in] unsigned char[] authToken, [in] struct [EnrollParam](_enroll_param_v12.md) param, [out] struct [ScheduleInfo](_schedule_info_v12.md) info) | 开始注册用户认证凭据。当注册凭据类型为口令且该用户已经注册了口令凭据时,将会更新口令凭据。 | 26| [UpdateEnrollmentResult](#updateenrollmentresult) ([in] int userId, [in] unsigned char[] scheduleResult, [out] struct [EnrollResultInfo](_enroll_result_info_v12.md) info) | 更新用户凭据注册结果,完成凭据注册。 | 27| [CancelEnrollment](#cancelenrollment) ([in] int userId) | 取消注册请求。 | 28| [DeleteCredential](#deletecredential) ([in] int userId, [in] unsigned long credentialId, [in] unsigned char[] authToken, [out] struct [CredentialInfo](_credential_info_v12.md) info) | 删除用户凭据信息。 | 29| [GetCredential](#getcredential) ([in] int userId, [in] enum [AuthType](_hdf_user_auth_v12.md#authtype) authType, [out] struct [CredentialInfo](_credential_info_v12.md)[] infos) | 查询用户凭据信息。 | 30| [GetUserInfo](#getuserinfo) ([in] int userId, [out] unsigned long secureUid, [out] enum [PinSubType](_hdf_user_auth_v12.md#pinsubtype) pinSubType, [out] struct [EnrolledInfo](_enrolled_info_v12.md)[] infos) | 查询用户认证相关信息。 | 31| [DeleteUser](#deleteuser) ([in] int userId, [in] unsigned char[] authToken, [out] struct [CredentialInfo](_credential_info_v12.md)[] deletedInfos) | 删除用户口令认证凭据,在用户IAM系统内删除该用户,该请求由用户触发。 | 32| [EnforceDeleteUser](#enforcedeleteuser) ([in] int userId, [out] struct [CredentialInfo](_credential_info_v12.md)[] deletedInfos) | 强制删除用户,该请求由系统内管理用户的模块触发。 | 33| [BeginAuthentication](#beginauthentication) ([in] unsigned long contextId, [in] struct [AuthSolution](_auth_solution_v12.md) param, [out] struct [ScheduleInfo](_schedule_info_v12.md)[] scheduleInfos) | 开始认证用户,并生成认证方案。 | 34| [UpdateAuthenticationResult](#updateauthenticationresult) ([in] unsigned long contextId, [in] unsigned char[] scheduleResult, [out] struct [AuthResultInfo](_auth_result_info_v12.md) info) | 更新认证结果,评估认证方案的认证结果。 | 35| [CancelAuthentication](#cancelauthentication) ([in] unsigned long contextId) | 取消用户认证请求。 | 36| [BeginIdentification](#beginidentification) ([in] unsigned long contextId, [in] enum [AuthType](_hdf_user_auth_v12.md#authtype) authType, [in] unsigned char[] challenge, [in] unsigned int executorSensorHint, [out] struct [ScheduleInfo](_schedule_info_v12.md) scheduleInfo) | 开始用户身份识别,并生成识别方案。 | 37| [UpdateIdentificationResult](#updateidentificationresult) ([in] unsigned long contextId, [in] unsigned char[] scheduleResult, [out] struct [IdentifyResultInfo](_identify_result_info_v12.md) info) | 更新用户身份识别结果,生成身份识别方案的结果。 | 38| [CancelIdentification](#cancelidentification) ([in] unsigned long contextId) | 取消用户身份识别请求。 | 39| [GetAuthTrustLevel](#getauthtrustlevel) ([in] int userId, [in] enum [AuthType](_hdf_user_auth_v12.md#authtype) authType, [out] unsigned int authTrustLevel) | 获取当前认证类型的认证结果可信等级。 | 40| [GetValidSolution](#getvalidsolution) ([in] int userId, [in] enum [AuthType](_hdf_user_auth_v12.md#authtype)[] authTypes, [in] unsigned int authTrustLevel, [out] enum [AuthType](_hdf_user_auth_v12.md#authtype)[] validTypes) | 获取指定认证结果可信等级下有效的认证方式。 | 41| [BeginEnrollmentV1_1](#beginenrollmentv1_1) ([in] int userId, [in] unsigned char[] authToken, [in] struct [EnrollParam](_enroll_param_v12.md) param, [out] struct [ScheduleInfoV1_1](_schedule_info_v1__1_v12.md) info) | 开始注册用户认证凭据。当注册凭据类型为口令且该用户已经注册了口令凭据时,将会更新口令凭据。 | 42| [BeginAuthenticationV1_1](#beginauthenticationv1_1) ([in] unsigned long contextId, [in] struct [AuthSolution](_auth_solution_v12.md) param, [out] struct [ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)[] scheduleInfos) | 开始认证用户,并生成认证方案。 | 43| [BeginIdentificationV1_1](#beginidentificationv1_1) ([in] unsigned long contextId, [in] enum [AuthType](_hdf_user_auth_v12.md#authtype) authType, [in] unsigned char[] challenge, [in] unsigned int executorSensorHint, [out] struct [ScheduleInfoV1_1](_schedule_info_v1__1_v12.md) scheduleInfo) | 开始用户身份识别,并生成识别方案。 | 44| [GetAllUserInfo](#getalluserinfo) ([out] [UserInfo](_user_info_v12.md)[] userInfos) | 获取所有用户信息。 | 45| [GetAllExtUserInfo](#getallextuserinfo) ([out] [ExtUserInfo](_ext_user_info_v12.md)[] userInfos) | 获取所有用户信息。 | 46| [BeginAuthenticationV1_2](#beginauthenticationv1_2) ([in] unsigned long contextId, [in] struct [AuthSolutionV1_2](_auth_solution_v1__2_v12.md) param, [out] struct [ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)[] scheduleInfos) | 开始认证用户,并生成认证方案。 | 47| [BeginEnrollmentV1_2](#beginenrollmentv1_2) ([in] int userId, [in] unsigned char[] authToken, [in] struct [EnrollParamV1_2](_enroll_param_v1__2_v12.md) param, [out] struct [ScheduleInfoV1_1](_schedule_info_v1__1_v12.md) info) | 开始注册用户认证凭据。当注册凭据类型为口令且该用户已经注册了口令凭据时,将会更新口令凭据。 | 48 49 50## 成员函数说明 51 52 53### AddExecutor() 54 55``` 56IUserAuthInterface::AddExecutor ([in] struct ExecutorRegisterInfo info, [out] unsigned long index, [out] unsigned char[] publicKey, [out] unsigned long[] templateIds ) 57``` 58 59**描述** 60 61 62添加认证执行器来获取认证能力,用于各认证基础服务如口令认证服务等将认证能力对接到用户认证框架。 63 64**参数:** 65 66| 名称 | 描述 | 67| -------- | -------- | 68| info | 执行器注册信息[ExecutorRegisterInfo](_executor_register_info_v12.md)。 | 69| index | 用户认证框架的执行器索引。 | 70| publicKey | 用户认证框架公钥。 | 71| templateIds | 该执行器已注册的模版ID列表。 | 72 73**返回:** 74 750 表示操作成功。 76 77非0 表示操作失败。 78 79 80### BeginAuthentication() 81 82``` 83IUserAuthInterface::BeginAuthentication ([in] unsigned long contextId, [in] struct AuthSolution param, [out] struct ScheduleInfo[] scheduleInfos ) 84``` 85 86**描述** 87 88 89开始认证用户,并生成认证方案。 90 91**参数:** 92 93| 名称 | 描述 | 94| -------- | -------- | 95| contextId | 上下文索引。 | 96| param | 认证方案[AuthSolution](_auth_solution_v12.md)。 | 97| scheduleInfos | 调度信息[ScheduleInfo](_schedule_info_v12.md)。 | 98 99**返回:** 100 1010 表示操作成功。 102 103非0 表示操作失败。 104 105 106### BeginAuthenticationV1_1() 107 108``` 109IUserAuthInterface::BeginAuthenticationV1_1 ([in] unsigned long contextId, [in] struct AuthSolution param, [out] struct ScheduleInfoV1_1[] scheduleInfos ) 110``` 111 112**描述** 113 114 115开始认证用户,并生成认证方案。 116 117**参数:** 118 119| 名称 | 描述 | 120| -------- | -------- | 121| contextId | 上下文索引。 | 122| param | 认证方案[AuthSolution](_auth_solution_v12.md)。 | 123| scheduleInfos | 调度信息[ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)。 | 124 125**返回:** 126 1270 表示操作成功。 128 129非0 表示操作失败。 130 131 132### BeginAuthenticationV1_2() 133 134``` 135IUserAuthInterface::BeginAuthenticationV1_2 ([in] unsigned long contextId, [in] struct AuthSolutionV1_2 param, [out] struct ScheduleInfoV1_1[] scheduleInfos ) 136``` 137 138**描述** 139 140 141开始认证用户,并生成认证方案。 142 143**参数:** 144 145| 名称 | 描述 | 146| -------- | -------- | 147| contextId | 上下文索引。 | 148| param | 认证方案[AuthSolutionV1_2](_auth_solution_v1__2_v12.md)。 | 149| scheduleInfos | 调度信息[ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)。 | 150 151**返回:** 152 1530 表示操作成功。 154 155非0 表示操作失败。 156 157 158### BeginEnrollment() 159 160``` 161IUserAuthInterface::BeginEnrollment ([in] int userId, [in] unsigned char[] authToken, [in] struct EnrollParam param, [out] struct ScheduleInfo info ) 162``` 163 164**描述** 165 166 167开始注册用户认证凭据。当注册凭据类型为口令且该用户已经注册了口令凭据时,将会更新口令凭据。 168 169**参数:** 170 171| 名称 | 描述 | 172| -------- | -------- | 173| userId | 用户ID。 | 174| authToken | 用户口令认证令牌。 | 175| param | 注册凭据参数[EnrollParam](_enroll_param_v12.md)。 | 176| info | 调度信息[ScheduleInfo](_schedule_info_v12.md)。 | 177 178**返回:** 179 1800 表示操作成功。 181 182非0 表示操作失败。 183 184 185### BeginEnrollmentV1_1() 186 187``` 188IUserAuthInterface::BeginEnrollmentV1_1 ([in] int userId, [in] unsigned char[] authToken, [in] struct EnrollParam param, [out] struct ScheduleInfoV1_1 info ) 189``` 190 191**描述** 192 193 194开始注册用户认证凭据。当注册凭据类型为口令且该用户已经注册了口令凭据时,将会更新口令凭据。 195 196**参数:** 197 198| 名称 | 描述 | 199| -------- | -------- | 200| userId | 用户ID。 | 201| authToken | 用户口令认证令牌。 | 202| param | 注册凭据参数[EnrollParam](_enroll_param_v12.md)。 | 203| info | 调度信息[ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)。 | 204 205**返回:** 206 2070 表示操作成功。 208 209非0 表示操作失败。 210 211 212### BeginEnrollmentV1_2() 213 214``` 215IUserAuthInterface::BeginEnrollmentV1_2 ([in] int userId, [in] unsigned char[] authToken, [in] struct EnrollParamV1_2 param, [out] struct ScheduleInfoV1_1 info ) 216``` 217 218**描述** 219 220 221开始注册用户认证凭据。当注册凭据类型为口令且该用户已经注册了口令凭据时,将会更新口令凭据。 222 223**参数:** 224 225| 名称 | 描述 | 226| -------- | -------- | 227| userId | 用户ID。 | 228| authToken | 用户口令认证令牌。 | 229| param | 注册凭据参数[EnrollParamV1_2](_enroll_param_v1__2_v12.md)。 | 230| info | 调度信息[ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)。 | 231 232**返回:** 233 2340 表示操作成功。 235 236非0 表示操作失败。 237 238 239### BeginIdentification() 240 241``` 242IUserAuthInterface::BeginIdentification ([in] unsigned long contextId, [in] enum AuthType authType, [in] unsigned char[] challenge, [in] unsigned int executorSensorHint, [out] struct ScheduleInfo scheduleInfo ) 243``` 244 245**描述** 246 247 248开始用户身份识别,并生成识别方案。 249 250**参数:** 251 252| 名称 | 描述 | 253| -------- | -------- | 254| contextId | 上下文索引。 | 255| authType | 用户身份识别类型[AuthType](_hdf_user_auth_v12.md#authtype)。 | 256| challenge | 随机挑战值,用于生成用户身份识别令牌,防止重放。 | 257| executorSensorHint | 执行器传感器提示,用于找到对应认证方式的传感器。 | 258| scheduleInfo | 调度信息[ScheduleInfo](_schedule_info_v12.md)。 | 259 260**返回:** 261 2620 表示操作成功。 263 264非0 表示操作失败。 265 266 267### BeginIdentificationV1_1() 268 269``` 270IUserAuthInterface::BeginIdentificationV1_1 ([in] unsigned long contextId, [in] enum AuthType authType, [in] unsigned char[] challenge, [in] unsigned int executorSensorHint, [out] struct ScheduleInfoV1_1 scheduleInfo ) 271``` 272 273**描述** 274 275 276开始用户身份识别,并生成识别方案。 277 278**参数:** 279 280| 名称 | 描述 | 281| -------- | -------- | 282| contextId | 上下文索引。 | 283| authType | 用户身份识别类型[AuthType](_hdf_user_auth_v12.md#authtype)。 | 284| challenge | 随机挑战值,用于生成用户身份识别令牌,防止重放。 | 285| executorSensorHint | 执行器传感器提示,用于找到对应认证方式的传感器,取值不为0。 | 286| scheduleInfo | 调度信息[ScheduleInfoV1_1](_schedule_info_v1__1_v12.md)。 | 287 288**返回:** 289 2900 表示操作成功。 291 292非0 表示操作失败。 293 294 295### CancelAuthentication() 296 297``` 298IUserAuthInterface::CancelAuthentication ([in] unsigned long contextId) 299``` 300 301**描述** 302 303 304取消用户认证请求。 305 306**参数:** 307 308| 名称 | 描述 | 309| -------- | -------- | 310| contextId | 上下文索引。 | 311 312**返回:** 313 3140 表示操作成功。 315 316非0 表示操作失败。 317 318 319### CancelEnrollment() 320 321``` 322IUserAuthInterface::CancelEnrollment ([in] int userId) 323``` 324 325**描述** 326 327 328取消注册请求。 329 330**参数:** 331 332| 名称 | 描述 | 333| -------- | -------- | 334| userId | 用户ID。 | 335 336**返回:** 337 3380 表示操作成功。 339 340非0 表示操作失败。 341 342 343### CancelIdentification() 344 345``` 346IUserAuthInterface::CancelIdentification ([in] unsigned long contextId) 347``` 348 349**描述** 350 351 352取消用户身份识别请求。 353 354**参数:** 355 356| 名称 | 描述 | 357| -------- | -------- | 358| contextId | 上下文索引。 | 359 360**返回:** 361 3620 表示操作成功。 363 364非0 表示操作失败。 365 366 367### CloseSession() 368 369``` 370IUserAuthInterface::CloseSession ([in] int userId) 371``` 372 373**描述** 374 375 376关闭认证凭据管理会话,完成用户认证凭据管理请求处理后,调用该接口使原挑战值失效。 377 378**参数:** 379 380| 名称 | 描述 | 381| -------- | -------- | 382| userId | 用户ID。 | 383 384**返回:** 385 3860 表示操作成功。 387 388非0 表示操作失败。 389 390 391### DeleteCredential() 392 393``` 394IUserAuthInterface::DeleteCredential ([in] int userId, [in] unsigned long credentialId, [in] unsigned char[] authToken, [out] struct CredentialInfo info ) 395``` 396 397**描述** 398 399 400删除用户凭据信息。 401 402**参数:** 403 404| 名称 | 描述 | 405| -------- | -------- | 406| userId | 用户ID。 | 407| credentialId | 凭据ID。 | 408| authToken | 用户口令认证令牌。 | 409| info | 删除的凭据信息[CredentialInfo](_credential_info_v12.md)。 | 410 411**返回:** 412 4130 表示操作成功。 414 415非0 表示操作失败。 416 417 418### DeleteExecutor() 419 420``` 421IUserAuthInterface::DeleteExecutor ([in] unsigned long index) 422``` 423 424**描述** 425 426 427删除执行器,用于清理失效的执行器信息。 428 429**参数:** 430 431| 名称 | 描述 | 432| -------- | -------- | 433| index | 用户认证框架的执行器索引。 | 434 435**返回:** 436 4370 表示操作成功。 438 439非0 表示操作失败。 440 441 442### DeleteUser() 443 444``` 445IUserAuthInterface::DeleteUser ([in] int userId, [in] unsigned char[] authToken, [out] struct CredentialInfo[] deletedInfos ) 446``` 447 448**描述** 449 450 451删除用户口令认证凭据,在用户IAM系统内删除该用户,该请求由用户触发。 452 453**参数:** 454 455| 名称 | 描述 | 456| -------- | -------- | 457| userId | 用户ID。 | 458| authToken | 用户口令认证令牌。 | 459| deletedInfos | 删除的凭据信息[CredentialInfo](_credential_info_v12.md)。 | 460 461**返回:** 462 4630 表示操作成功。 464 465非0 表示操作失败。 466 467 468### EnforceDeleteUser() 469 470``` 471IUserAuthInterface::EnforceDeleteUser ([in] int userId, [out] struct CredentialInfo[] deletedInfos ) 472``` 473 474**描述** 475 476 477强制删除用户,该请求由系统内管理用户的模块触发。 478 479**参数:** 480 481| 名称 | 描述 | 482| -------- | -------- | 483| userId | 用户ID。 | 484| deletedInfos | 删除的凭据信息[CredentialInfo](_credential_info_v12.md)。 | 485 486**返回:** 487 4880 表示操作成功。 489 490非0 表示操作失败。 491 492 493### GetAllExtUserInfo() 494 495``` 496IUserAuthInterface::GetAllExtUserInfo ([out] ExtUserInfo[] userInfos) 497``` 498 499**描述** 500 501 502获取所有用户信息。 503 504**参数:** 505 506| 名称 | 描述 | 507| -------- | -------- | 508| userInfos | 用户信息列表[ExtUserInfo](_ext_user_info_v12.md)。 | 509 510**返回:** 511 5120 表示操作成功。 513 514非0 表示操作失败。 515 516 517### GetAllUserInfo() 518 519``` 520IUserAuthInterface::GetAllUserInfo ([out] UserInfo[] userInfos) 521``` 522 523**描述** 524 525 526获取所有用户信息。 527 528**参数:** 529 530| 名称 | 描述 | 531| -------- | -------- | 532| userInfos | 用户信息列表[UserInfo](_user_info_v12.md)}。 | 533 534**返回:** 535 5360 表示操作成功。 537 538非0 表示操作失败。 539 540 541### GetAuthTrustLevel() 542 543``` 544IUserAuthInterface::GetAuthTrustLevel ([in] int userId, [in] enum AuthType authType, [out] unsigned int authTrustLevel ) 545``` 546 547**描述** 548 549 550获取当前认证类型的认证结果可信等级。 551 552**参数:** 553 554| 名称 | 描述 | 555| -------- | -------- | 556| userId | 用户ID。 | 557| authType | 认证类型[AuthType](_hdf_user_auth_v12.md#authtype)。 | 558| authTrustLevel | 认证结果可信等级。 | 559 560**返回:** 561 5620 表示操作成功。 563 564非0 表示操作失败。 565 566 567### GetCredential() 568 569``` 570IUserAuthInterface::GetCredential ([in] int userId, [in] enum AuthType authType, [out] struct CredentialInfo[] infos ) 571``` 572 573**描述** 574 575 576查询用户凭据信息。 577 578**参数:** 579 580| 名称 | 描述 | 581| -------- | -------- | 582| userId | 用户ID。 | 583| authType | 凭据类型[AuthType](_hdf_user_auth_v12.md#authtype)。 | 584| infos | 凭据信息[CredentialInfo](_credential_info_v12.md)。 | 585 586**返回:** 587 5880 表示操作成功。 589 590非0 表示操作失败。 591 592 593### GetUserInfo() 594 595``` 596IUserAuthInterface::GetUserInfo ([in] int userId, [out] unsigned long secureUid, [out] enum PinSubType pinSubType, [out] struct EnrolledInfo[] infos ) 597``` 598 599**描述** 600 601 602查询用户认证相关信息。 603 604**参数:** 605 606| 名称 | 描述 | 607| -------- | -------- | 608| userId | 用户ID。 | 609| secureUid | 安全用户ID。 | 610| pinSubType | 口令认证子类型[PinSubType](_hdf_user_auth_v12.md#pinsubtype)。 | 611| infos | 注册信息[EnrolledInfo](_enrolled_info_v12.md)。 | 612 613**返回:** 614 6150 表示操作成功。 616 617非0 表示操作失败。 618 619 620### GetValidSolution() 621 622``` 623IUserAuthInterface::GetValidSolution ([in] int userId, [in] enum AuthType[] authTypes, [in] unsigned int authTrustLevel, [out] enum AuthType[] validTypes ) 624``` 625 626**描述** 627 628 629获取指定认证结果可信等级下有效的认证方式。 630 631**参数:** 632 633| 名称 | 描述 | 634| -------- | -------- | 635| userId | 用户ID。 | 636| authTypes | 用于筛选的认证方式列表[AuthType](_hdf_user_auth_v12.md#authtype)。 | 637| authTrustLevel | 认证结果可信等级。 | 638| validTypes | 有效的认证方式列表[AuthType](_hdf_user_auth_v12.md#authtype)。 | 639 640**返回:** 641 6420 表示操作成功。 643 644非0 表示操作失败。 645 646 647### Init() 648 649``` 650IUserAuthInterface::Init () 651``` 652 653**描述** 654 655 656初始化用户认证驱动缓存信息,用于用户认证框架进程启动时初始化信息。 657 658**返回:** 659 6600 表示操作成功。 661 662非0 表示操作失败。 663 664 665### OpenSession() 666 667``` 668IUserAuthInterface::OpenSession ([in] int userId, [out] unsigned char[] challenge ) 669``` 670 671**描述** 672 673 674开启一个认证凭据管理会话,用于在请求管理用户认证凭据前获取有效挑战值。 675 676**参数:** 677 678| 名称 | 描述 | 679| -------- | -------- | 680| userId | 用户ID。 | 681| challenge | 随机挑战值,用于生成用户身份认证令牌。 | 682 683**返回:** 684 6850 表示操作成功。 686 687非0 表示操作失败。 688 689 690### UpdateAuthenticationResult() 691 692``` 693IUserAuthInterface::UpdateAuthenticationResult ([in] unsigned long contextId, [in] unsigned char[] scheduleResult, [out] struct AuthResultInfo info ) 694``` 695 696**描述** 697 698 699更新认证结果,评估认证方案的认证结果。 700 701**参数:** 702 703| 名称 | 描述 | 704| -------- | -------- | 705| contextId | 上下文索引。 | 706| scheduleResult | 执行器签发的认证结果。 | 707| info | 认证结果信息[AuthResultInfo](_auth_result_info_v12.md)。 | 708 709**返回:** 710 7110 表示操作成功。 712 713非0 表示操作失败。 714 715 716### UpdateEnrollmentResult() 717 718``` 719IUserAuthInterface::UpdateEnrollmentResult ([in] int userId, [in] unsigned char[] scheduleResult, [out] struct EnrollResultInfo info ) 720``` 721 722**描述** 723 724 725更新用户凭据注册结果,完成凭据注册。 726 727**参数:** 728 729| 名称 | 描述 | 730| -------- | -------- | 731| userId | 用户ID。 | 732| scheduleResult | 执行器签发的注册结果。 | 733| info | 录入结果信息[EnrollResultInfo](_enroll_result_info_v12.md)。 | 734 735**返回:** 736 7370 表示操作成功。 738 739非0 表示操作失败。 740 741 742### UpdateIdentificationResult() 743 744``` 745IUserAuthInterface::UpdateIdentificationResult ([in] unsigned long contextId, [in] unsigned char[] scheduleResult, [out] struct IdentifyResultInfo info ) 746``` 747 748**描述** 749 750 751更新用户身份识别结果,生成身份识别方案的结果。 752 753**参数:** 754 755| 名称 | 描述 | 756| -------- | -------- | 757| contextId | 上下文索引。 | 758| scheduleResult | 执行器签发的用户身份识别结果。 | 759| info | 用户身份识别结果[IdentifyResultInfo](_identify_result_info_v12.md)。 | 760 761**返回:** 762 7630 表示操作成功。 764 765非0 表示操作失败。 766