Home
last modified time | relevance | path

Searched refs:token (Results 1 – 25 of 31) sorted by relevance

12

/system/core/libpixelflinger/codeflinger/
DArm64Disassembler.cpp95 static void get_token(const char *instr, uint32_t index, char *token) in get_token() argument
102 token[j++] = instr[i]; in get_token()
111 token[j++] = instr[i]; in get_token()
114 token[j] = '\0'; in get_token()
134 static void decode_token(uint32_t code, char *token, char *instr_part) in decode_token() argument
136 if(strcmp(token, "<imm1>") == 0) in decode_token()
138 else if(strcmp(token, "<imm2>") == 0) in decode_token()
140 else if(strcmp(token, "<shift1>") == 0) in decode_token()
142 else if(strcmp(token, "<shift2>") == 0) in decode_token()
147 else if(strcmp(token, "<shift3>") == 0) in decode_token()
[all …]
/system/keymaster/
Dkeymaster_enforcement_test.cpp54 bool auth_token_timed_out(const hw_auth_token_t& token, uint32_t timeout) const { in auth_token_timed_out() argument
55 return current_time_ > ntoh(token.timestamp) + timeout; in auth_token_timed_out()
520 hw_auth_token_t token; in TEST_F() local
521 memset(&token, 0, sizeof(token)); in TEST_F()
522 token.version = HW_AUTH_TOKEN_VERSION; in TEST_F()
523 token.challenge = 99; in TEST_F()
524 token.user_id = 9; in TEST_F()
525 token.authenticator_id = 0; in TEST_F()
526 token.authenticator_type = hton(static_cast<uint32_t>(HW_AUTH_PASSWORD)); in TEST_F()
527 token.timestamp = 0; in TEST_F()
[all …]
/system/security/keystore/
Doperation.cpp33 sp<IBinder> token = new BBinder(); in addOperation() local
34 mMap[token] = std::move(Operation(handle, keyid, purpose, dev, characteristics, appToken)); in addOperation()
36 mLru.push_back(token); in addOperation()
41 mAppTokenMap[appToken].push_back(token); in addOperation()
42 return token; in addOperation()
45 bool OperationMap::getOperation(sp<IBinder> token, keymaster_operation_handle_t* outHandle, in getOperation() argument
52 auto entry = mMap.find(token); in getOperation()
56 updateLru(token); in getOperation()
68 void OperationMap::updateLru(sp<IBinder> token) { in updateLru() argument
69 auto lruEntry = std::find(mLru.begin(), mLru.end(), token); in updateLru()
[all …]
Doperation.h54 bool getOperation(sp<IBinder> token, keymaster_operation_handle_t* outHandle,
58 bool removeOperation(sp<IBinder> token);
61 bool getOperationAuthToken(sp<IBinder> token, const hw_auth_token_t** outToken);
62 bool setOperationAuthToken(sp<IBinder> token, const hw_auth_token_t* authToken);
67 void updateLru(sp<IBinder> token);
68 void removeOperationTracking(sp<IBinder> token, sp<IBinder> appToken);
Dauth_token_table.cpp111 entries_, [&](Entry& e) { return e.token()->challenge == op_handle && !e.completed(); }); in FindAuthPerOpAuthorization()
119 *found = matching_op->token(); in FindAuthPerOpAuthorization()
142 *found = newest_match->token(); in FindTimedAuthorization()
168 auto found = find_if(entries_, [&](Entry& e) { return e.token()->challenge == op_handle; }); in MarkCompleted()
179 AuthTokenTable::Entry::Entry(const hw_auth_token_t* token, time_t current_time) in Entry() argument
180 : token_(token), time_received_(current_time), last_use_(current_time), in Entry()
Dauth_token_table.h61 void AddAuthenticationToken(const hw_auth_token_t* token);
107 Entry(const hw_auth_token_t* token, time_t current_time);
132 const hw_auth_token_t* token() { return token_.get(); } in token() function
DIKeystoreService.cpp51 OperationResult::OperationResult() : resultCode(0), token(), handle(0), inputConsumed(0), in OperationResult()
60 token = in.readStrongBinder(); in readFromParcel()
84 out->writeStrongBinder(token); in writeToParcel()
1102 virtual void update(const sp<IBinder>& token, const KeymasterArguments& params, in update() argument
1110 data.writeStrongBinder(token); in update()
1131 virtual void finish(const sp<IBinder>& token, const KeymasterArguments& params, in finish() argument
1141 data.writeStrongBinder(token); in finish()
1163 virtual int32_t abort(const sp<IBinder>& token) in abort() argument
1167 data.writeStrongBinder(token); in abort()
1182 virtual bool isOperationAuthorized(const sp<IBinder>& token) in isOperationAuthorized() argument
[all …]
Dkeystore.cpp1704 for (auto token: operations) { in binderDied() local
1705 abort(token); in binderDied()
2556 result->token = operationToken; in begin()
2564 void update(const sp<IBinder>& token, const KeymasterArguments& params, const uint8_t* data, in update() argument
2575 if (!mOperationMap.getOperation(token, &handle, &keyid, &purpose, &dev, &characteristics)) { in update()
2580 int32_t authResult = addOperationAuthTokenIfNeeded(token, &opParams); in update()
2615 void finish(const sp<IBinder>& token, const KeymasterArguments& params, in finish() argument
2627 if (!mOperationMap.getOperation(token, &handle, &keyid, &purpose, &dev, &characteristics)) { in finish()
2632 int32_t authResult = addOperationAuthTokenIfNeeded(token, &opParams); in finish()
2668 mOperationMap.removeOperation(token); in finish()
[all …]
/system/core/adb/
Dadb_auth.h28 void send_auth_response(uint8_t *token, size_t token_size, atransport *t);
41 int adb_auth_sign(void *key, const unsigned char* token, size_t token_size,
46 static inline int adb_auth_generate_token(void *token, size_t token_size) { return 0; } in adb_auth_generate_token() argument
47 static inline int adb_auth_verify(void *token, void *sig, int siglen) { return 0; } in adb_auth_verify() argument
52 static inline int adb_auth_sign(void* key, const unsigned char* token, in adb_auth_sign() argument
61 int adb_auth_generate_token(void *token, size_t token_size);
62 int adb_auth_verify(uint8_t* token, uint8_t* sig, int siglen);
Dadb_auth.cpp39 ret = adb_auth_generate_token(t->token, sizeof(t->token)); in send_auth_request()
40 if (ret != sizeof(t->token)) { in send_auth_request()
46 memcpy(p->data, t->token, ret); in send_auth_request()
53 void send_auth_response(uint8_t *token, size_t token_size, atransport *t) in send_auth_response() argument
59 ret = adb_auth_sign(t->key, token, token_size, p->data); in send_auth_response()
Dadb_auth_client.cpp126 int adb_auth_generate_token(void *token, size_t token_size) in adb_auth_generate_token() argument
135 ret = fread(token, token_size, 1, f); in adb_auth_generate_token()
141 int adb_auth_verify(uint8_t* token, uint8_t* sig, int siglen) in adb_auth_verify() argument
154 ret = RSA_verify(&key->key, sig, siglen, token, SHA_DIGEST_SIZE); in adb_auth_verify()
Dadb_auth_host.cpp371 int adb_auth_sign(void *node, const unsigned char* token, size_t token_size, in adb_auth_sign() argument
382 if (!RSA_sign(NID_sha1, token, token_size, sig, &len, key->rsa)) { in adb_auth_sign()
/system/gatekeeper/
Dgatekeeper.cpp220 hw_auth_token_t *token = new hw_auth_token_t; in MintAuthToken() local
223 token->version = HW_AUTH_TOKEN_VERSION; in MintAuthToken()
224 token->challenge = challenge; in MintAuthToken()
225 token->user_id = user_id; in MintAuthToken()
226 token->authenticator_id = authenticator_id; in MintAuthToken()
227 token->authenticator_type = htonl(HW_AUTH_PASSWORD); in MintAuthToken()
228 token->timestamp = htobe64(timestamp); in MintAuthToken()
233 uint32_t hash_len = (uint32_t)((uint8_t *)&token->hmac - (uint8_t *)token); in MintAuthToken()
234 ComputeSignature(token->hmac, sizeof(token->hmac), auth_token_key, key_len, in MintAuthToken()
235 reinterpret_cast<uint8_t *>(token), hash_len); in MintAuthToken()
[all …]
/system/extras/ext4_utils/
Dcanned_fs_config.c63 char* token = NULL; in load_canned_fs_config() local
65 token = strtok(NULL, " "); in load_canned_fs_config()
66 if (token && strncmp(token, "capabilities=", 13) == 0) { in load_canned_fs_config()
67 p->capabilities = strtoll(token+13, NULL, 0); in load_canned_fs_config()
70 } while (token); in load_canned_fs_config()
/system/core/sdcard/
Dsdcard.c241 int token; member
789 TRACE("[%d] LOOKUP %s @ %"PRIx64" (%s)\n", handler->token, name, hdr->nodeid, in handle_lookup()
811 TRACE("[%d] FORGET #%"PRIu64" @ %"PRIx64" (%s)\n", handler->token, req->nlookup, in handle_forget()
831 TRACE("[%d] GETATTR flags=%x fh=%"PRIx64" @ %"PRIx64" (%s)\n", handler->token, in handle_getattr()
854 TRACE("[%d] SETATTR fh=%"PRIx64" valid=%x @ %"PRIx64" (%s)\n", handler->token, in handle_setattr()
900 handler->token, path, times[0].tv_sec, times[1].tv_sec); in handle_setattr()
919 TRACE("[%d] MKNOD %s 0%o @ %"PRIx64" (%s)\n", handler->token, in handle_mknod()
948 TRACE("[%d] MKDIR %s 0%o @ %"PRIx64" (%s)\n", handler->token, in handle_mkdir()
996 TRACE("[%d] UNLINK %s @ %"PRIx64" (%s)\n", handler->token, in handle_unlink()
1019 handler->token, (uint64_t) parent_node->nid, (uint64_t) child_node->nid, name); in handle_unlink()
[all …]
/system/keymaster/include/keymaster/
Dkeymaster_enforcement.h127 virtual bool auth_token_timed_out(const hw_auth_token_t& token, uint32_t timeout) const = 0;
144 virtual bool ValidateTokenSignature(const hw_auth_token_t& token) const = 0;
/system/security/keystore/tests/
Dauth_token_table_test.cpp76 hw_auth_token_t* token = new hw_auth_token_t; in make_token() local
77 token->user_id = rsid; in make_token()
78 token->authenticator_id = ssid; in make_token()
79 token->authenticator_type = hton(static_cast<uint32_t>(HW_AUTH_PASSWORD)); in make_token()
80 token->challenge = challenge; in make_token()
81 token->timestamp = hton(timestamp); in make_token()
82 return token; in make_token()
/system/security/keystore/include/keystore/
DIKeystoreService.h63 sp<IBinder> token; member
216 virtual void update(const sp<IBinder>& token, const KeymasterArguments& params,
219 virtual void finish(const sp<IBinder>& token, const KeymasterArguments& params,
228 virtual int32_t addAuthToken(const uint8_t* token, size_t length) = 0;
/system/core/init/
Dueventd_parser.cpp206 int token = next_token(&state); in parse_config() local
207 switch (token) { in parse_config()
/system/vold/
DDisk.cpp273 char* token = strtok(cline, kSgdiskToken); in readPartitions() local
274 if (token == nullptr) continue; in readPartitions()
276 if (!strcmp(token, "DISK")) { in readPartitions()
283 } else if (!strcmp(token, "PART")) { in readPartitions()
/system/core/include/utils/
DPropertyMap.h97 status_t parseModifier(const String8& token, int32_t* outMetaState);
/system/core/fingerprintd/
DIFingerprintDaemon.cpp78 const uint8_t* token = static_cast<const uint8_t *>(data.readInplace(tokenSize)); in onTransact() local
81 const int32_t ret = enroll(token, tokenSize, groupId, timeout); in onTransact()
DFingerprintDaemonProxy.h36 …virtual int32_t enroll(const uint8_t* token, ssize_t tokenLength, int32_t groupId, int32_t timeout…
DIFingerprintDaemon.h55 virtual int32_t enroll(const uint8_t* token, ssize_t tokenLength, int32_t groupId,
DFingerprintDaemonProxy.cpp122 int32_t FingerprintDaemonProxy::enroll(const uint8_t* token, ssize_t tokenSize, int32_t groupId, in enroll() argument
129 const hw_auth_token_t* authToken = reinterpret_cast<const hw_auth_token_t*>(token); in enroll()

12