/base/startup/init/interfaces/hals/utils/token/ |
D | hal_token.c | 20 __attribute__((weak)) static int OEMReadToken(char* token, unsigned int len) in OEMReadToken() argument 23 (void)(token); in OEMReadToken() 28 __attribute__((weak)) static int OEMWriteToken(const char* token, unsigned int len) in OEMWriteToken() argument 31 (void)(token); in OEMWriteToken() 60 __attribute__((weak)) int HalReadToken(char* token, unsigned int len) in HalReadToken() argument 62 if (token == NULL) { in HalReadToken() 66 return OEMReadToken(token, len); in HalReadToken() 69 __attribute__((weak)) int HalWriteToken(const char* token, unsigned int len) in HalWriteToken() argument 71 if (token == NULL) { in HalWriteToken() 75 return OEMWriteToken(token, len); in HalWriteToken()
|
/base/security/device_auth/services/authenticators/src/account_related/creds_manager/ |
D | asy_token_manager.c | 112 static int32_t GenerateTokenFromJson(const CJson *tokenJson, AccountToken *token) in GenerateTokenFromJson() argument 124 …if (memcpy_s(token->pkInfoStr.val, token->pkInfoStr.length, pkInfoStr, HcStrlen(pkInfoStr) + 1) !=… in GenerateTokenFromJson() 129 token->pkInfoStr.length = HcStrlen(pkInfoStr) + 1; in GenerateTokenFromJson() 131 if (GetByteFromJson(tokenJson, FIELD_PK_INFO_SIGNATURE, token->pkInfoSignature.val, in GenerateTokenFromJson() 132 token->pkInfoSignature.length) != HC_SUCCESS) { in GenerateTokenFromJson() 137 token->pkInfoSignature.length = HcStrlen(signatureStr) / BYTE_TO_HEX_OPER_LENGTH; in GenerateTokenFromJson() 138 if (GetByteFromJson(tokenJson, FIELD_SERVER_PK, token->serverPk.val, in GenerateTokenFromJson() 139 token->serverPk.length) != HC_SUCCESS) { in GenerateTokenFromJson() 144 token->serverPk.length = HcStrlen(serverPkStr) / BYTE_TO_HEX_OPER_LENGTH; in GenerateTokenFromJson() 145 int32_t ret = GeneratePkInfoFromJson(&token->pkInfo, pkInfoJson); in GenerateTokenFromJson() [all …]
|
D | sym_token_manager.c | 48 static bool IsTokenMatch(const SymToken *token, const char *userId, const char *deviceId) in IsTokenMatch() argument 50 return (strcmp(userId, token->userId) == 0) && (strcmp(deviceId, token->deviceId) == 0); in IsTokenMatch() 75 SymToken *token = (SymToken *)HcMalloc(sizeof(SymToken), 0); in CreateSymTokenByJson() local 76 if (token == NULL) { in CreateSymTokenByJson() 83 HcFree(token); in CreateSymTokenByJson() 89 HcFree(token); in CreateSymTokenByJson() 92 if (strcpy_s(token->userId, DEV_AUTH_USER_ID_SIZE, userId) != EOK) { in CreateSymTokenByJson() 94 HcFree(token); in CreateSymTokenByJson() 97 if (strcpy_s(token->deviceId, DEV_AUTH_DEVICE_ID_SIZE, deviceId) != EOK) { in CreateSymTokenByJson() 99 HcFree(token); in CreateSymTokenByJson() [all …]
|
/base/powermgr/power_manager/test/systemtest/src/ |
D | power_mgr_st_mock_test.cpp | 156 sptr<IRemoteObject> token = new RunningLockTokenStub(); variable 158 pms->CreateRunningLock(token, info); 159 pms->Lock(token, 0); 160 EXPECT_EQ(pms->IsUsed(token), true); 161 pms->UnLock(token); 162 EXPECT_EQ(pms->IsUsed(token), false); 191 sptr<IRemoteObject> token = new RunningLockTokenStub(); variable 193 pms->CreateRunningLock(token, info); 196 pms->Lock(token, 0); 197 EXPECT_EQ(pms->IsUsed(token), true); [all …]
|
D | power_mgr_st_suspend_test.cpp | 97 sptr<IRemoteObject> token = new RunningLockTokenStub(); variable 99 pms->CreateRunningLock(token, info); 100 pms->Lock(token, 0); 101 EXPECT_EQ(pms->IsUsed(token), true); 104 pms->UnLock(token); 105 EXPECT_EQ(pms->IsUsed(token), false); 128 sptr<IRemoteObject> token = new RunningLockTokenStub(); variable 130 pms->CreateRunningLock(token, info); 132 pms->Lock(token, 0); 133 EXPECT_EQ(pms->IsUsed(token), true); [all …]
|
D | power_mgr_mock_system_test.cpp | 79 sptr<IRemoteObject> token = new RunningLockTokenStub(); variable 81 pms->CreateRunningLock(token, info); 83 pms->Lock(token, 0); 84 EXPECT_EQ(pms->IsUsed(token), true);
|
/base/security/access_token/ |
D | README.md | 8 …token information of an app includes the app identifier (**APPID**), user ID, app twin index, app … 11 - Verifying app permissions based on the token ID before an app accesses sensitive data or calls … 12 - Obtaining access token information (for example, APL) based on the token ID. 25 │ └── tokensync # Code of the access token synchronization framework. 28 │ │ ├── accesstoken # Code of the internal access token interfaces. 29 │ │ ├── nativetoken # Code of the internal native token interfaces. 32 │ │ ├── token_setproc # Code of internal interfaces for exchanging token IDs. 33 │ │ └── tokensync # Code of the internal access token synchronization interfaces. 35 │ │ ├── accesstoken # Code of the external access token interfaces. 41 └── tokensyncmanager # Code of the access token synchronization service. [all …]
|
/base/startup/init/interfaces/innerkits/token/src/token_impl_hal/ |
D | token.c | 21 int ReadToken(char *token, unsigned int len) in ReadToken() argument 23 if (token == NULL) { in ReadToken() 28 return HalReadToken(token, len); in ReadToken() 31 int WriteToken(const char *token, unsigned int len) in WriteToken() argument 33 if (token == NULL) { in WriteToken() 38 return HalWriteToken(token, len); in WriteToken()
|
/base/startup/init/interfaces/innerkits/token/ |
D | BUILD.gn | 23 "//base/startup/init/interfaces/innerkits/include/token", 25 "//base/startup/init/interfaces/innerkits/token", 27 sources = [ "src/token_impl_posix/token.c" ] 30 "$ohos_product_adapter_dir/utils/token:haltoken_shared", 38 sources = [ "src/token_impl_hal/token.c" ] 42 "//base/startup/init/interfaces/innerkits/include/token", 44 "//base/startup/init/interfaces/innerkits/token", 48 rebase_path("${ohos_product_adapter_dir}/utils/token") 53 deps += [ "$ohos_product_adapter_dir/utils/token:hal_token_static" ] 56 [ "//base/startup/init/interfaces/hals/utils/token:static_hal_token" ] [all …]
|
/base/account/os_account/services/accountmgr/test/unittest/app_account/ |
D | app_account_info_test.cpp | 562 EXPECT_EQ(tokens[0].token, STRING_TOKEN); 608 ASSERT_EQ(tokenInfos[STRING_AUTH_TYPE].token, STRING_TOKEN); 737 std::string token; variable 738 ErrCode result = appAccountInfo.GetOAuthToken(STRING_AUTH_TYPE, token); 740 token = STRING_TOKEN; 741 result = appAccountInfo.SetOAuthToken(STRING_AUTH_TYPE, token); 743 token = STRING_EMPTY; 744 result = appAccountInfo.GetOAuthToken(STRING_AUTH_TYPE, token); 746 EXPECT_EQ(token, STRING_TOKEN); 747 result = appAccountInfo.DeleteOAuthToken(STRING_AUTH_TYPE, token); [all …]
|
/base/startup/init/interfaces/innerkits/token/src/token_impl_posix/ |
D | token.c | 40 int ReadToken(char *token, unsigned int len) in ReadToken() argument 44 if (token == NULL) { in ReadToken() 54 ret = HalReadToken(token, len); in ReadToken() 60 int WriteToken(const char *token, unsigned int len) in WriteToken() argument 64 if (token == NULL) { in WriteToken() 74 ret = HalWriteToken(token, len); in WriteToken()
|
/base/security/access_token/interfaces/innerkits/token_setproc/src/ |
D | token_setproc.c | 52 uint64_t token = INVAL_TOKEN_ID; in GetSelfTokenID() local 57 int ret = ioctl(fd, ACCESS_TOKENID_GET_TOKENID, &token); in GetSelfTokenID() 64 return token; in GetSelfTokenID() 85 uint64_t token = INVAL_TOKEN_ID; in GetFirstCallerTokenID() local 90 int ret = ioctl(fd, ACCESS_TOKENID_GET_FTOKENID, &token); in GetFirstCallerTokenID() 97 return token; in GetFirstCallerTokenID()
|
/base/useriam/face_auth/ui/Settings_FaceAuth/entry/src/main/ets/model/ |
D | userIdmModel.ts | 24 protected token: Uint8Array property in UserIdmModel 45 setToken(token: Uint8Array): void { 46 let tokenStr = CommonController.uin8Array2JsonString(token); 48 Log.info(this.TAG, "setToken ok, size " + token.length) 53 let token = CommonController.jsonString2Uint8Array(tokenStr) 54 Log.info(this.TAG, "getToken ok, size " + token.length) 55 return token 96 token: localToken,
|
/base/powermgr/power_manager/test/unittest/include/ |
D | running_lock_test.h | 34 void TestRunningLockInnerExisit(sptr<IRemoteObject>& token, RunningLockInfo& runningLockInfo) in TestRunningLockInnerExisit() argument 37 auto iterator = lockMap.find(token); in TestRunningLockInnerExisit() 45 void TestRunningLockInnerNoExisit(sptr<IRemoteObject>& token) in TestRunningLockInnerNoExisit() argument 48 auto iterator = lockMap.find(token); in TestRunningLockInnerNoExisit()
|
/base/telephony/core_service/test/unittest/core_service_gtest/ |
D | sim_icc_test.cpp | 43 AccessToken token; variable 60 AccessToken token; variable 93 AccessToken token; variable 114 AccessToken token; variable 135 AccessToken token; variable 173 AccessToken token; variable 194 AccessToken token; variable 215 AccessToken token; variable 236 AccessToken token; variable 258 AccessToken token; variable [all …]
|
/base/account/os_account/frameworks/appaccount/extension/src/ |
D | authorization_extension.cpp | 45 const sptr<IRemoteObject> &token) in Init() argument 47 ExtensionBase<AuthorizationExtensionContext>::Init(record, application, handler, token); in Init() 52 std::shared_ptr<AbilityHandler> &handler, const sptr<IRemoteObject> &token) in CreateAndInitContext() argument 55 …sionBase<AuthorizationExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|
/base/security/huks/interfaces/kits/napi/src/v9/ |
D | huks_napi_init_session.cpp | 44 struct HksBlob *token = nullptr; member 70 if (context->token != nullptr) { in DeleteInitAsyncContext() 71 FreeHksBlob(context->token); in DeleteInitAsyncContext() 120 context->token = static_cast<struct HksBlob *>(HksMalloc(sizeof(HksBlob))); in InitOutParams() 121 if (context->token == nullptr) { in InitOutParams() 125 context->token->data = static_cast<uint8_t *>(HksMalloc(HKS_MAX_TOKEN_SIZE)); in InitOutParams() 126 if (context->token->data == nullptr) { in InitOutParams() 130 context->token->size = HKS_MAX_TOKEN_SIZE; in InitOutParams() 157 napiContext->handle, napiContext->token); in InitAsyncWork() 164 resultData.challenge = napiContext->token; in InitAsyncWork()
|
/base/security/huks/interfaces/kits/napi/src/v8/ |
D | huks_napi_init.cpp | 44 struct HksBlob *token = nullptr; member 70 if (context->token != nullptr) { in DeleteInitAsyncContext() 71 FreeHksBlob(context->token); in DeleteInitAsyncContext() 120 context->token = static_cast<HksBlob *>(HksMalloc(sizeof(HksBlob))); in InitOutParams() 121 if (context->token == nullptr) { in InitOutParams() 125 context->token->data = static_cast<uint8_t *>(HksMalloc(HKS_MAX_TOKEN_SIZE)); in InitOutParams() 126 if (context->token->data == nullptr) { in InitOutParams() 130 context->token->size = HKS_MAX_TOKEN_SIZE; in InitOutParams() 136 return GenerateHksHandle(env, context->result, context->handle, context->token); in InitWriteResult() 162 napiContext->paramSet, napiContext->handle, napiContext->token); in InitAsyncWork()
|
/base/theme/wallpaper_mgr/frameworks/kits/extension/src/ |
D | wallpaper_extension_ability.cpp | 45 const sptr<IRemoteObject> &token) in Init() argument 48 ExtensionBase<WallpaperExtensionContext>::Init(record, application, handler, token); in Init() 55 const sptr<IRemoteObject> &token) in CreateAndInitContext() argument 59 …xtensionBase<WallpaperExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|
/base/useriam/user_auth_framework/frameworks/js/napi/user_auth_extension/module_loader/ |
D | user_auth_extension.cpp | 43 const sptr<IRemoteObject> &token) in Init() argument 46 ExtensionBase<UIExtensionContext>::Init(record, application, handler, token); in Init() 53 const sptr<IRemoteObject> &token) in CreateAndInitContext() argument 56 … ExtensionBase<UIExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|
/base/inputmethod/imf/frameworks/kits/extension/src/ |
D | inputmethod_extension.cpp | 44 const sptr<IRemoteObject> &token) in Init() argument 47 ExtensionBase<InputMethodExtensionContext>::Init(record, application, handler, token); in Init() 52 std::shared_ptr<AbilityHandler> &handler, const sptr<IRemoteObject> &token) in CreateAndInitContext() argument 56 …ensionBase<InputMethodExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|
/base/print/print_fwk/frameworks/kits/extension/src/ |
D | print_extension.cpp | 46 const sptr<IRemoteObject> &token) in Init() argument 49 ExtensionBase<PrintExtensionContext>::Init(record, application, handler, token); in Init() 55 std::shared_ptr<AbilityHandler> &handler, const sptr<IRemoteObject> &token) in CreateAndInitContext() argument 59 … ExtensionBase<PrintExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|
/base/update/updater/services/flashd/daemon/ |
D | flashd_utils.cpp | 68 auto token = strtok_s(buffer.data(), delimit, &nextToken); in Split() local 69 while (token != nullptr) { in Split() 70 if (find(filter.cbegin(), filter.cend(), token) == filter.cend()) { in Split() 71 result.push_back(token); in Split() 73 token = strtok_s(nullptr, delimit, &nextToken); in Split()
|
/base/notification/common_event_service/frameworks/extension/src/ |
D | static_subscriber_extension.cpp | 44 const sptr<IRemoteObject>& token) in Init() argument 47 ExtensionBase<StaticSubscriberExtensionContext>::Init(record, application, handler, token); in Init() 54 const sptr<IRemoteObject>& token) in CreateAndInitContext() argument 57 …nBase<StaticSubscriberExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|
/base/customization/enterprise_device_management/framework/extension/src/ |
D | enterprise_admin_extension.cpp | 43 const sptr<IRemoteObject>& token) in Init() argument 46 ExtensionBase<EnterpriseAdminExtensionContext>::Init(record, application, handler, token); in Init() 53 const sptr<IRemoteObject>& token) in CreateAndInitContext() argument 56 …onBase<EnterpriseAdminExtensionContext>::CreateAndInitContext(record, application, handler, token); in CreateAndInitContext()
|