| Name | Date | Size | #Lines | LOC | ||
|---|---|---|---|---|---|---|
| .. | - | - | ||||
| AppScope/ | 06-May-2025 | - | 35 | 32 | ||
| entry/ | 06-May-2025 | - | 1,052 | 985 | ||
| hvigor/ | 06-May-2025 | - | 38 | 36 | ||
| screenshots/ | 06-May-2025 | - | ||||
| .gitignore | D | 06-May-2025 | 133 | 12 | 12 | |
| README.md | D | 06-May-2025 | 3.1 KiB | 75 | 54 | |
| build-profile.json5 | D | 06-May-2025 | 1.4 KiB | 58 | 57 | |
| code-linter.json5 | D | 06-May-2025 | 958 | 35 | 34 | |
| hvigorfile.ts | D | 06-May-2025 | 843 | 22 | 5 | |
| oh-package.json5 | D | 06-May-2025 | 834 | 26 | 24 | |
| ohosTest.md | D | 06-May-2025 | 1.2 KiB | 12 | 10 |
README.md
1# 管理系统账号凭据 2 3### 介绍 4 5凭据可用于认证用户的身份,本文档将介绍如何录入、认证、更新、查询和删除指定系统账号的凭据。 6 7该工程中展示的代码详细描述可查如下链接: 8 9- [ 管理系统账号凭据](https://gitee.com/openharmony/docs/blob/master/zh-cn/application-dev/basic-services/account/manage-os-account-credential.md) 10 11### 效果预览 12 13| 首页 | 执行录入PIN码 | 14| :----------------------------------------------------------: | :----------------------------------------------------------: | 15| <img src="./screenshots/AccountCredentials_1.png" width="360" style="zoom:33%;" /> | <img src="./screenshots/AccountCredentials_2.png" width="360" style="zoom:33%;" /> | 16| 执行认证PIN码 | 执行更新凭据 | 17| <img src="./screenshots/AccountCredentials_3.png" width="360" style="zoom:33%;" /> | <img src="./screenshots/AccountCredentials_4.png" width="360" style="zoom:33%;" /> | 18| 执行查询凭据信息 | 执行删除凭据 | 19| <img src="./screenshots/AccountCredentials_5.png" width="360" style="zoom:33%;" /> | <img src="./screenshots/AccountCredentials_6.png" width="360" style="zoom:33%;" /> | 20 21### 使用说明 22 231. 在主界面,点击'Enter PIN code',执行录入PIN码。 242. 点击'Authenticate PIN code',执行认证PIN码。 253. 点击'Update credentials',执行更新凭据。 264. 点击'Query credential information',执行查询凭据信息。 275. 点击'Delete credentials',执行删除凭据。 286. 执行结果会即时反馈在屏幕中央,并在控制台打印log。 29 30### 工程目录 31 32``` 33entry/src/ 34 ├── main 35 │ ├── ets 36 │ │ ├── entryability 37 │ │ ├── entrybackupability 38 │ │ ├── pages 39 │ │ ├── Index.ets // 管理系统账号凭据示例代码 40 │ ├── module.json5 41 │ └── resources 42 ├── ohosTest 43 │ ├── ets 44 │ │ ├── test 45 │ │ ├── Ability.test.ets // 自动化测试代码 46``` 47 48### 相关权限 49 50- ohos.permission.MANAGE_USER_IDM 51- ohos.permission.ACCESS_PIN_AUTH 52 53### 依赖 54 55不涉及。 56 57### 约束与限制 58 591.本示例仅支持标准系统上运行, 支持设备:RK3568。 60 612.本示例为Stage模型,支持API14版本SDK,版本号:5.0.2.57,镜像版本号:OpenHarmony_5.0.2.58。 62 633.本示例需要使用DevEco Studio 5.0.1 Release (Build Version: 5.0.5.306, built on December 6, 2024)及以上版本才可编译运行。 64 65### 下载 66 67如需单独下载本工程,执行如下命令: 68 69```` 70git init 71git config core.sparsecheckout true 72echo code/DocsSample/Account/ManageSystemAccountCredentials > .git/info/sparse-checkout 73git remote add origin https://gitee.com/openharmony/applications_app_samples.git 74git pull origin master 75````