/test/xts/device_attest_lite/services/core/adapter/ |
H A D | attest_adapter_hal.c | 55 char token[TOKEN_ENCRYPT_LEN + 1];
in AttestWriteToken() local 57 (void)memset_s(token, sizeof(token), 0, sizeof(token));
in AttestWriteToken() 59 if (memcpy_s(token, sizeof(token), tokenInfo->tokenId, sizeof(tokenInfo->tokenId)) != 0) {
in AttestWriteToken() 63 token[offset - 1] = separator;
in AttestWriteToken() 64 if (memcpy_s(token + offset, sizeof(token), tokenInfo->tokenValue, sizeof(tokenInfo->tokenValue)) != 0) {
in AttestWriteToken() 68 token[offse in AttestWriteToken() 103 char token[TOKEN_ENCRYPT_LEN + 1] = {0}; AttestReadToken() local [all...] |
/test/xts/device_attest/services/core/adapter/ |
H A D | attest_adapter_hal.c | 55 char token[TOKEN_ENCRYPT_LEN + 1];
in AttestWriteToken() local 57 (void)memset_s(token, sizeof(token), 0, sizeof(token));
in AttestWriteToken() 59 if (memcpy_s(token, sizeof(token), tokenInfo->tokenId, sizeof(tokenInfo->tokenId)) != 0) {
in AttestWriteToken() 63 token[offset - 1] = separator;
in AttestWriteToken() 64 if (memcpy_s(token + offset, sizeof(token), tokenInfo->tokenValue, sizeof(tokenInfo->tokenValue)) != 0) {
in AttestWriteToken() 68 token[offse in AttestWriteToken() 97 char token[TOKEN_ENCRYPT_LEN + 1] = {0}; AttestReadToken() local [all...] |
/test/testfwk/arkxtest/uitest/test/ |
H A D | ipc_transactor_test.cpp | 84 auto token = string("testInitConnection_#") + string(params.description); in TEST_P() local 91 server.InitAndConnectPeer(token, nullptr); in TEST_P() 100 RedirectStdoutToPipe(token + "-client", fds); in TEST_P() 104 token.append("_bad"); in TEST_P() 107 auto success = client.InitAndConnectPeer(token, nullptr); in TEST_P() 121 constexpr string_view token = "testAapiTransaction"; in TEST() local 135 server.InitAndConnectPeer(token, executor); in TEST() 147 auto connSuccess = client.InitAndConnectPeer(token, nullptr); in TEST() 176 constexpr string_view token = "testHandleFdParam"; in TEST() local 182 auto executor = [token](cons in TEST() 229 constexpr string_view token = "testDetectConcurrentTransaction"; TEST() local 277 constexpr string_view token = "testServerDetectClientDeath"; TEST() local [all...] |
/test/xts/hats/kernel/accesstokenid/ |
H A D | accesstokenid_test.cpp | 90 static int GetTokenid(unsigned long long *token) in GetTokenid() argument 98 int ret = ioctl(fd, ACCESS_TOKENID_GET_TOKENID, token); in GetTokenid() 109 static int SetTokenid(unsigned long long *token) in SetTokenid() argument 117 int ret = ioctl(fd, ACCESS_TOKENID_SET_TOKENID, token); in SetTokenid() 166 static void GetCurToken(unsigned long long *token, unsigned long long *ftoken) in GetCurToken() argument 168 GetTokenid(token); in GetCurToken() 234 unsigned long long token = INVAL_TOKEN; in HWTEST_F() local 237 GetCurToken(&token, &ftoken); in HWTEST_F() 242 ASSERT_NE(0, token); in HWTEST_F() 254 unsigned long long token in HWTEST_F() local 290 unsigned long long token = INVAL_TOKEN; HWTEST_F() local 332 unsigned long long token = INVAL_TOKEN; HWTEST_F() local 452 unsigned long long token; HWTEST_F() local 504 unsigned long long token = INVAL_TOKEN; HWTEST_F() local [all...] |
/test/xts/device_attest_lite/services/core/network/ |
H A D | attest_coap.c | 51 static int32_t CoapCreateToken(uint8_t token[], uint8_t* tkl) in CoapCreateToken() argument 53 if (token == NULL || tkl == NULL || (*tkl > MAX_TOK_LEN)) { in CoapCreateToken() 61 token[i] = (uint8_t)(GetRandomNum() % (MAX_VALUE_ONE_BYTE + 1)); // create a random value, range: 0~255 in CoapCreateToken() 66 static int32_t CoapAddToken(CoapPacket* pkt, const CoapBuffer* token, CoapRWBuffer* buf) in CoapAddToken() argument 69 if (pkt == NULL || token == NULL || ((token->len != 0) && token->buffer == NULL) || in CoapAddToken() 75 if (token->len > MAX_TOK_LEN) { in CoapAddToken() 80 if ((buf->len + token->len) > buf->size) { in CoapAddToken() 85 pkt->tok.len = token in CoapAddToken() 378 CoapEncode(CoapPacket* pkt, const CoapPacketParam* param, const CoapBuffer* token, const CoapBuffer* payload, CoapRWBuffer* outBuf) CoapEncode() argument 448 uint8_t token[PKT_TOKEN_LEN] = {0}; CoapBuildMessage() local [all...] |
/test/xts/device_attest/services/oem_adapter/src/ |
H A D | device_attest_oem_adapter.c | 78 int32_t OEMReadToken(char *token, uint32_t len) in OEMReadToken() argument 80 if (token == NULL || len == 0) { in OEMReadToken() 92 (void)memcpy_s(token, len, tokenWithFlagA, len); in OEMReadToken() 96 (void)memcpy_s(token, len, tokenWithFlagB, len); in OEMReadToken() 103 (void)memcpy_s(token, len, tokenWithFlagA, len); in OEMReadToken() 106 (void)memcpy_s(token, len, tokenWithFlagB, len); in OEMReadToken() 112 int32_t OEMWriteToken(const char *token, uint32_t len) in OEMWriteToken() argument 114 if (token == NULL || len == 0) { in OEMWriteToken() 123 if ((memcpy_s(tokenWithFlagA, TOKEN_WITH_FLAG_SIZE, token, len) != 0) || in OEMWriteToken() 136 if ((memcpy_s(tokenWithFlagB, TOKEN_WITH_FLAG_SIZE, token, le in OEMWriteToken() [all...] |
/test/xts/acts/distributed_schedule_lite/system_ability_manager_posix/src/ |
H A D | SendShareRequestTest.cpp | 37 uint32 *(*SAMGR_SendSharedRequestProxy)(const Identity *identity, const Request *request, uint32 *token, 62 static uint32 *SAMGR_SendSharedRequestProxy(const Identity *identity, const Request *request, uint32 *token, in SAMGR_SendSharedRequestProxy() argument 65 return SAMGR_SendSharedRequest(identity, request, token, handler); in SAMGR_SendSharedRequestProxy() 389 uint32 *token = NULL; in HWTEST_F() local 390 token = demoApi->SAMGR_SendSharedRequestProxy(&feature->identity, &request, token, DemoHandlerAndCheck); in HWTEST_F() 431 uint32 *token = NULL; in HWTEST_F() local 433 &token, DemoHandlerAndCheck); in HWTEST_F()
|
/test/xts/acts/communication/dsoftbus/rpc/entry/src/ohosTest/js/test/ |
H A D | RpcClientJsunit.test.js | 805 let token = "hello ruan zong xian";
806 data.writeInterfaceToken(token);
810 expect(result.reply.readInterfaceToken()).assertEqual(token);
839 let token = "hello ruan zong xian";
840 data.writeInterfaceToken(token);
844 expect(result.reply.readInterfaceToken()).assertEqual(token);
873 let token = "";
875 token += 'a';
877 data.writeInterfaceToken(token);
881 expect(result.reply.readInterfaceToken()).assertEqual(token);
[all...] |
/test/testfwk/arkxtest/uitest/connection/ |
H A D | ipc_transactor.cpp | 193 static sptr<IRemoteObject> PublishCallerAndWaitForBackcaller(const sptr<ApiCaller> &caller, string_view token) in PublishCallerAndWaitForBackcaller() argument 197 want.SetAction(string(PUBLISH_EVENT_PREFIX) + token.data()); in PublishCallerAndWaitForBackcaller() 198 want.SetParam(string(token), caller->AsObject()); in PublishCallerAndWaitForBackcaller() 222 static sptr<IRemoteObject> WaitForPublishedCaller(string_view token) in WaitForPublishedCaller() argument 225 matchingSkills.AddEvent(string(PUBLISH_EVENT_PREFIX) + token.data()); in WaitForPublishedCaller() 231 auto onEvent = [&condition, &remoteObject, &token](const CommonEventData &data) { in WaitForPublishedCaller() 234 remoteObject = want.GetRemoteObject(string(token)); in WaitForPublishedCaller() 292 bool ApiTransactor::InitAndConnectPeer(string_view token, ApiCallHandler handler) in InitAndConnectPeer() argument 302 remoteObject = PublishCallerAndWaitForBackcaller(caller_, token); in InitAndConnectPeer() 308 remoteObject = WaitForPublishedCaller(token); in InitAndConnectPeer() [all...] |
/test/xts/acts/ability/ability_runtime/capichildprocess/entry/src/main/cpp/ |
H A D | IpcStub.cpp | 91 char *token; in CheckInterfaceToken() local 93 int ret = OH_IPCParcel_ReadInterfaceToken(data, &token, &tokenLen, IpcStub::OnIpcMemAlloc); in CheckInterfaceToken() 98 bool tokenCheckRes = strcmp(token, interfaceToken_) == 0; in CheckInterfaceToken() 99 ReleaseIpcMem(token); in CheckInterfaceToken()
|
/test/testfwk/arkxtest/uitest/server/ |
H A D | server_main.cpp | 61 "start-daemon <token> start the test process\n" 206 static int32_t StartDaemon(string_view token, int32_t argc, char *argv[]) in StartDaemon() argument 208 if (token.empty()) { in StartDaemon() 209 LOG_E("Empty transaction token"); in StartDaemon() 212 auto transalatedToken = TranslateToken(token); in StartDaemon() 224 if (token == singlenessToken) { in StartDaemon() 316 string_view token = argc < 3 ? "" : argv[2]; in main() 317 _Exit(StartDaemon(token, argc - THREE, argv + THREE)); in main()
|
/test/xts/acts/distributed_schedule_lite/system_ability_manager_hal/src/ |
H A D | sendsharerequest_func_test.c | 40 uint32 *(*SAMGR_SendSharedRequestProxy)(const Identity *identity, const Request *request, uint32 *token,
65 static uint32 *SAMGR_SendSharedRequestProxy(const Identity *identity, const Request *request, uint32 *token,
in SAMGR_SendSharedRequestProxy() argument 68 return SAMGR_SendSharedRequest(identity, request, token, handler);
in SAMGR_SendSharedRequestProxy() 396 uint32 *token = NULL;
variable 397 token = demoApi->SAMGR_SendSharedRequestProxy(&feature->identity, &request, token, DemoHandlerAndCheck);
437 uint32 *token = NULL;
variable 439 &token, DemoHandlerAndCheck);
|
/test/xts/acts/communication/dsoftbus/rpc_request/entry/src/ohosTest/js/test/ |
H A D | ActsRpcRequestJsTest.test.js | 184 let token = "async onRemoteMessageRequest invoking";
185 data.writeString(token);
215 let token = "async onRemoteMessageRequest invoking";
216 data.writeString(token);
247 let token = "onRemoteRequest or async onRemoteMessageRequest invoking";
248 data.writeString(token);
279 let token = "onRemoteRequest or async onRemoteMessageRequest invoking";
280 data.writeString(token);
311 let token = "async onRemoteMessageRequest invoking";
312 var result = data.writeString(token);
[all...] |
/test/xts/device_attest/services/devattest_ability/test/tdd/gtest/src/ |
H A D | attest_tdd_test.cpp | 254 * @tc.desc: Test gen reset msg with stored token. 270 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 285 * @tc.desc: Test gen reset msg without token. 301 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 361 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 375 * @tc.desc: Test gen auth msg without token. 390 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 447 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 461 * @tc.desc: Test gen auth msg without token. 476 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() [all...] |
/test/xts/device_attest_lite/test/tdd/gtest/src/ |
H A D | attest_tdd_test.cpp | 273 * @tc.desc: Test gen reset msg with stored token. 289 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 304 * @tc.desc: Test gen reset msg without token. 320 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 378 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 392 * @tc.desc: Test gen auth msg without token. 407 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 460 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() 474 * @tc.desc: Test gen auth msg without token. 489 char *outToken = reqMsg->tokenInfo.token; in HWTEST_F() [all...] |
/test/xts/device_attest/services/oem_adapter/include/ |
H A D | device_attest_oem_adapter.h | 54 * @brief Read token value from device. 56 * @param token : the result token value, if read successfully. 57 * @param len : length of the token. 58 * @returns 0 if success and get the update area token, 60 * -2 if no pre-made token. 62 int32_t OEMReadToken(char *token, uint32_t len); 65 * @brief Write token value to device. 67 * @param token : the token t [all...] |
/test/testfwk/arkxtest/uitest/cj/ |
H A D | uitest_ffi.cpp | 155 void CJ_InitConnection(char *token) in CJ_InitConnection() argument 157 string realToken{token}; in CJ_InitConnection() 158 LOG_I("connect token is %{public}s", token); in CJ_InitConnection()
|
H A D | uitest_ffi.h | 34 FFI_EXPORT void CJ_InitConnection(char *token);
|
/test/xts/acts/ability/ability_runtime/actsserviceabilityclienttest/actsserviceabilityclienttest/entry/src/main/js/ServiceAbility1/ |
H A D | service.js | 35 let token = data.readInterfaceToken(); 36 console.log('ACTS_SerivceAbilityServer ====< onRemoteRequest token:' + token);
|
/test/xts/acts/ability/ability_runtime/actsserviceabilityclienttest/actsserviceabilityclienttest/entry/src/main/js/ServiceAbility2/ |
H A D | service.js | 35 let token = data.readInterfaceToken(); 36 console.log('ACTS_SerivceAbilityServerSecond ====< onRemoteRequest token:' + token);
|
/test/xts/device_attest/services/core/dfx/ |
H A D | attest_dfx.c | 93 if (tokenInfo->token == NULL) { in PrintDeviceTokenInfo() 94 ATTEST_LOG_WARN("token = null;"); in PrintDeviceTokenInfo() 96 ATTEST_LOG_INFO_ANONY("token = %s;", tokenInfo->token); in PrintDeviceTokenInfo()
|
/test/xts/device_attest_lite/services/core/dfx/ |
H A D | attest_dfx.c | 93 if (tokenInfo->token == NULL) { in PrintDeviceTokenInfo() 94 ATTEST_LOG_WARN("token = null;"); in PrintDeviceTokenInfo() 96 ATTEST_LOG_INFO_ANONY("token = %s;", tokenInfo->token); in PrintDeviceTokenInfo()
|
/test/testfwk/arkxtest/uitest/napi/ |
H A D | uitest_exporter.js | 57 console.info(`UiTestKit_exporter: ScheduleProbeAndEstablishConnection, token=${connToken}`);
|
/test/xts/device_attest/services/core/attest/ |
H A D | attest_service_active.c | 44 ATTEST_LOG_ERROR("[GenActiveMsg] The length of token is 0."); in GenActiveMsg() 68 devicePacket->tokenInfo.token = AttestStrdup((char*)tokenValueHmac); in GenActiveMsg()
|
/test/xts/device_attest_lite/services/core/attest/ |
H A D | attest_service_active.c | 44 ATTEST_LOG_ERROR("[GenActiveMsg] The length of token is 0."); in GenActiveMsg() 68 devicePacket->tokenInfo.token = AttestStrdup((char*)tokenValueHmac); in GenActiveMsg()
|