/system/core/trusty/keymaster/set_attestation_ids/ |
D | set_attestation_ids.cpp | 98 void print_usage(const char* prog, const keymaster::SetAttestationIdsKM3Request& req) { in print_usage() argument 114 prog, buf2string(req.base.brand).c_str(), buf2string(req.base.device).c_str(), in print_usage() 115 buf2string(req.base.product).c_str(), buf2string(req.base.serial).c_str(), in print_usage() 116 buf2string(req.base.manufacturer).c_str(), buf2string(req.base.model).c_str(), in print_usage() 117 buf2string(req.base.imei).c_str(), buf2string(req.base.meid).c_str(), in print_usage() 118 buf2string(req.second_imei).c_str()); in print_usage() 132 void populate_base_ids(keymaster::SetAttestationIdsRequest* req) { in populate_base_ids() argument 133 set_from_prop(&req->brand, "ro.product.brand"); in populate_base_ids() 134 set_from_prop(&req->device, "ro.product.device"); in populate_base_ids() 135 set_from_prop(&req->product, "ro.product.name"); in populate_base_ids() [all …]
|
/system/authgraph/core/src/ |
D | ta.rs | 71 Ok(req) => { in process() 72 trace!("-> TA: received request {:?}", req.code()); in process() 73 (Some(req.code()), self.process_req(req)) in process() 95 fn process_req(&mut self, req: PerformOpReq) -> PerformOpResponse { in process_req() 96 let code = req.code(); in process_req() 97 let result = match req { in process_req() 101 PerformOpReq::Init(req) => self in process_req() 102 .init(&req.peer_pub_key, &req.peer_id, &req.peer_nonce, req.peer_version) in process_req() 104 PerformOpReq::Finish(req) => self in process_req() 106 &req.peer_pub_key, in process_req() [all …]
|
/system/core/trusty/storage/proxy/ |
D | rpmb.c | 324 static int send_mmc_rpmb_req(int mmc_fd, const struct storage_rpmb_send_req* req, in send_mmc_rpmb_req() argument 333 const uint8_t* write_buf = req->payload; in send_mmc_rpmb_req() 334 if (req->reliable_write_size) { in send_mmc_rpmb_req() 339 cmd->blocks = req->reliable_write_size / MMC_BLOCK_SIZE; in send_mmc_rpmb_req() 343 log_buf(ANDROID_LOG_INFO, "request: ", write_buf, req->reliable_write_size); in send_mmc_rpmb_req() 345 write_buf += req->reliable_write_size; in send_mmc_rpmb_req() 350 if (req->write_size) { in send_mmc_rpmb_req() 355 cmd->blocks = req->write_size / MMC_BLOCK_SIZE; in send_mmc_rpmb_req() 359 log_buf(ANDROID_LOG_INFO, "request: ", write_buf, req->write_size); in send_mmc_rpmb_req() 361 write_buf += req->write_size; in send_mmc_rpmb_req() [all …]
|
D | storage.c | 277 const struct storage_file_delete_req *req = r; in storage_file_delete() local 279 if (req_len < sizeof(*req)) { in storage_file_delete() 281 __func__, req_len, sizeof(*req)); in storage_file_delete() 286 size_t fname_len = strlen(req->name); in storage_file_delete() 287 if (fname_len != req_len - sizeof(*req)) { in storage_file_delete() 289 __func__, fname_len, req_len - sizeof(*req)); in storage_file_delete() 294 int rc = asprintf(&path, "%s/%s", ssdir_name, req->name); in storage_file_delete() 404 const struct storage_file_open_req *req = r; in storage_file_open() local 408 if (req_len < sizeof(*req)) { in storage_file_open() 410 __func__, req_len, sizeof(*req)); in storage_file_open() [all …]
|
D | storage.h | 32 int storage_file_delete(struct storage_msg* msg, const void* req, size_t req_len, 35 int storage_file_open(struct storage_msg* msg, const void* req, size_t req_len, 38 int storage_file_close(struct storage_msg* msg, const void* req, size_t req_len, 41 int storage_file_write(struct storage_msg* msg, const void* req, size_t req_len, 44 int storage_file_read(struct storage_msg* msg, const void* req, size_t req_len, 47 int storage_file_get_size(struct storage_msg* msg, const void* req, size_t req_len, 50 int storage_file_set_size(struct storage_msg* msg, const void* req, size_t req_len, 53 int storage_file_get_max_size(struct storage_msg* msg, const void* req, size_t req_len,
|
D | proxy.c | 123 static int handle_req(struct storage_msg* msg, const void* req, size_t req_len) { in handle_req() argument 164 rc = storage_file_delete(msg, req, req_len, watcher); in handle_req() 168 rc = storage_file_open(msg, req, req_len, watcher); in handle_req() 172 rc = storage_file_close(msg, req, req_len, watcher); in handle_req() 176 rc = storage_file_write(msg, req, req_len, watcher); in handle_req() 180 rc = storage_file_read(msg, req, req_len, watcher); in handle_req() 184 rc = storage_file_get_size(msg, req, req_len, watcher); in handle_req() 188 rc = storage_file_set_size(msg, req, req_len, watcher); in handle_req() 192 rc = storage_file_get_max_size(msg, req, req_len, watcher); in handle_req() 196 rc = rpmb_send(msg, req, req_len, watcher); in handle_req()
|
/system/core/trusty/line-coverage/ |
D | coverage.cpp | 74 Result<void> CoverageRecord::Rpc(struct line_coverage_client_req* req, \ in Rpc() argument 80 rc = write(coverage_srv_fd_, req, sizeof(*req)); in Rpc() 83 .iov_base = req, in Rpc() 84 .iov_len = sizeof(*req), in Rpc() 95 if (rc != (int)sizeof(*req)) { in Rpc() 104 if (resp->hdr.cmd != (req->hdr.cmd | LINE_COVERAGE_CLIENT_CMD_RESP_BIT)) { in Rpc() 112 struct line_coverage_client_req req; in Open() local 121 req.hdr.cmd = LINE_COVERAGE_CLIENT_CMD_OPEN; in Open() 122 req.open_args.uuid = uuid_; in Open() 123 auto ret = Rpc(&req, -1, &resp); in Open() [all …]
|
/system/keymint/ta/src/ |
D | lib.rs | 652 Ok(req) => { in process() 653 trace!("-> TA: received request {:?}", req.code()); in process() 654 (Some(req.code()), self.process_req(req)) in process() 680 fn process_req(&mut self, req: PerformOpReq) -> PerformOpResponse { in process_req() 681 match req { in process_req() 683 PerformOpReq::SetBootInfo(req) => { in process_req() 684 let verified_boot_state = match VerifiedBootState::try_from(req.verified_boot_state) in process_req() 690 verified_boot_key: req.verified_boot_key, in process_req() 691 device_boot_locked: req.device_boot_locked, in process_req() 693 verified_boot_hash: req.verified_boot_hash, in process_req() [all …]
|
/system/authgraph/wire/src/ |
D | lib.rs | 168 Self::Create(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 169 Self::Init(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 170 Self::Finish(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 171 Self::AuthenticationComplete(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 215 Self::Create(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 216 Self::Init(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 217 Self::Finish(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 218 Self::AuthenticationComplete(req) => vec![req.value(), req.to_cbor_value()?], in to_cbor_value() 279 { $req:ident => $code:ident } => { 280 impl Code for $req {
|
/system/core/trusty/storage/lib/ |
D | storage.c | 147 struct storage_file_open_req req = { .flags = flags }; in storage_open_file() local 148 struct iovec tx[3] = {{&msg, sizeof(msg)}, {&req, sizeof(req)}, {(void *)name, strlen(name)}}; in storage_open_file() 169 struct storage_file_close_req req = { .handle = _to_handle(fh)}; in storage_close_file() local 170 struct iovec tx[2] = {{&msg, sizeof(msg)}, {&req, sizeof(req)}}; in storage_close_file() 183 struct storage_file_delete_req req = { .flags = 0, }; in storage_delete_file() local 184 struct iovec tx[3] = {{&msg, sizeof(msg)}, {&req, sizeof(req)}, {(void *)name, strlen(name)}}; in storage_delete_file() 194 struct storage_file_read_req req = { .handle = _to_handle(fh), .size = size, .offset = off }; in _read_chunk() local 195 struct iovec tx[2] = {{&msg, sizeof(msg)}, {&req, sizeof(req)}}; in _read_chunk() 229 struct storage_file_write_req req = { .handle = _to_handle(fh), .offset = off, }; in _write_req() local 230 struct iovec tx[3] = {{&msg, sizeof(msg)}, {&req, sizeof(req)}, {(void *)buf, size}}; in _write_req() [all …]
|
/system/keymaster/tests/ |
D | android_keymaster_messages_test.cpp | 81 GenerateKeyRequest req(ver); in TEST() local 82 req.key_description.Reinitialize(params, array_length(params)); in TEST() 83 req.attestation_signing_key_blob = in TEST() 85 req.attest_key_params.Reinitialize(params, array_length(params)); in TEST() 86 req.issuer_subject = KeymasterBlob(reinterpret_cast<const uint8_t*>("bar"), 3); in TEST() 88 UniquePtr<GenerateKeyRequest> deserialized(round_trip(ver, req, ver < 4 ? 78 : 170)); in TEST() 89 EXPECT_EQ(deserialized->key_description, req.key_description); in TEST() 94 EXPECT_EQ(0, memcmp(req.attestation_signing_key_blob.key_material, in TEST() 97 EXPECT_EQ(deserialized->attest_key_params, req.attest_key_params); in TEST() 98 EXPECT_EQ(0, memcmp(req.issuer_subject.data, deserialized->issuer_subject.data, in TEST() [all …]
|
/system/secretkeeper/comm/tests/ |
D | data_types.rs | 40 let req = in request_serialization_deserialization_store_secret() localVariable 42 verify_request_structure(req, Opcode::StoreSecret); in request_serialization_deserialization_store_secret() 47 let req = GetSecretRequest { id: ex_id(), updated_sealing_policy: Some(ex_dice_policy()) }; in request_serialization_deserialization_get_secret() localVariable 48 verify_request_structure(req, Opcode::GetSecret); in request_serialization_deserialization_get_secret() 50 let req = GetSecretRequest { id: ex_id(), updated_sealing_policy: None }; in request_serialization_deserialization_get_secret() localVariable 51 verify_request_structure(req, Opcode::GetSecret); in request_serialization_deserialization_get_secret() 79 req: R, in verify_request_structure() 82 let packet = req.serialize_to_packet(); in verify_request_structure() 87 assert_eq!(req, req_other_end); in verify_request_structure() 108 let req: StoreSecretRequest = *Request::new(vec![ in request_creation() localVariable [all …]
|
/system/core/trusty/libtrusty/ |
D | trusty.c | 57 struct tipc_send_msg_req req; in tipc_send() local 58 req.iov = (__u64)iov; in tipc_send() 59 req.iov_cnt = (__u64)iovcnt; in tipc_send() 60 req.shm = (__u64)shms; in tipc_send() 61 req.shm_cnt = (__u64)shmcnt; in tipc_send() 63 int rc = TEMP_FAILURE_RETRY(ioctl(fd, TIPC_IOC_SEND_MSG, &req)); in tipc_send()
|
/system/logging/logd/libaudit/ |
D | libaudit.cpp | 69 struct audit_message req = {}; in audit_send() local 70 req.nlh.nlmsg_type = static_cast<uint16_t>(type); in audit_send() 71 req.nlh.nlmsg_len = NLMSG_SPACE(size); in audit_send() 72 req.nlh.nlmsg_flags = NLM_F_REQUEST | NLM_F_ACK; in audit_send() 89 memcpy(NLMSG_DATA(&req.nlh), data, size); in audit_send() 102 req.nlh.nlmsg_seq = sequence; in audit_send() 105 sendto(fd, &req, req.nlh.nlmsg_len, 0, (struct sockaddr*)&addr, sizeof(addr))); in audit_send() 110 } else if ((uint32_t)rc != req.nlh.nlmsg_len) { in audit_send()
|
/system/keymint/hal/src/ |
D | lib.rs | 156 fn channel_execute<T, R, S>(channel: &mut T, req: R) -> binder::Result<S> in channel_execute() 166 req.to_cbor_value().map_err(failed_cbor)?, in channel_execute() 252 fn execute<R, S>(&self, req: R) -> binder::Result<S> in execute() 257 channel_execute(self.channel().deref_mut(), req) in execute() 263 let req = env::populate_hal_info().map_err(|e| { in send_hal_info() localVariable 269 info!("HAL->TA: environment info is {:?}", req); in send_hal_info() 270 let _rsp: kmr_wire::SetHalInfoResponse = channel_execute(channel, req)?; in send_hal_info() 279 let req = kmr_wire::SetHalVersionRequest { aidl_version }; in send_hal_info() localVariable 281 let result: binder::Result<kmr_wire::SetHalVersionResponse> = channel_execute(channel, req); in send_hal_info() 292 req: kmr_wire::SetBootInfoRequest, in send_boot_info() [all …]
|
/system/core/trusty/utils/coverage-controller/ |
D | controller.cpp | 84 struct line_coverage_client_req req; in setUpShm() local 89 req.hdr.cmd = LINE_COVERAGE_CLIENT_CMD_SEND_LIST; in setUpShm() 90 int rc = write(coverage_srv_fd, &req, sizeof(req)); in setUpShm() 91 if (rc != (int)sizeof(req)) { in setUpShm() 102 if (resp.hdr.cmd == (req.hdr.cmd | LINE_COVERAGE_CLIENT_CMD_RESP_BIT)) { in setUpShm() 132 req.hdr.cmd = LINE_COVERAGE_CLIENT_CMD_SEND_LIST; in setUpShm() 133 req.send_list_args.index = cur_index; in setUpShm() 134 int rc = write(coverage_srv_fd, &req, sizeof(req)); in setUpShm() 135 if (rc != (int)sizeof(req)) { in setUpShm()
|
/system/core/trusty/coverage/ |
D | coverage.cpp | 77 Result<void> CoverageRecord::Rpc(coverage_client_req* req, int req_fd, coverage_client_resp* resp) { in Rpc() argument 81 rc = write(coverage_srv_fd_, req, sizeof(*req)); in Rpc() 84 .iov_base = req, in Rpc() 85 .iov_len = sizeof(*req), in Rpc() 96 if (rc != (int)sizeof(*req)) { in Rpc() 105 if (resp->hdr.cmd != (req->hdr.cmd | COVERAGE_CLIENT_CMD_RESP_BIT)) { in Rpc() 113 coverage_client_req req; in Open() local 128 req.hdr.cmd = COVERAGE_CLIENT_CMD_OPEN; in Open() 129 req.open_args.uuid = uuid_; in Open() 130 auto ret = Rpc(&req, -1, &resp); in Open() [all …]
|
/system/authgraph/hal/src/ |
D | service.rs | 62 fn execute_req(&self, req: PerformOpReq) -> binder::Result<PerformOpRsp> { in execute_req() 63 let code = req.code(); in execute_req() 64 let req_data = req.into_vec().map_err(failed_cbor)?; in execute_req() 111 let req = PerformOpReq::Create(wire::CreateRequest {}); in create() localVariable 112 let wire::CreateResponse { ret } = require_op_rsp!(self.execute_req(req)? => Create)?; in create() 122 let req = PerformOpReq::Init(wire::InitRequest { in init() localVariable 128 let wire::InitResponse { ret } = require_op_rsp!(self.execute_req(req)? => Init)?; in init() 141 let req = PerformOpReq::Finish(wire::FinishRequest { in finish() localVariable 149 let wire::FinishResponse { ret } = require_op_rsp!(self.execute_req(req)? => Finish)?; in finish() 158 let req = PerformOpReq::AuthenticationComplete(wire::AuthenticationCompleteRequest { localVariable [all …]
|
/system/core/trusty/keymaster/set_attestation_key/ |
D | set_attestation_key.cpp | 122 SetAttestationKeyRequest req; in set_attestation_key_or_cert_bin() local 123 req.algorithm = algorithm; in set_attestation_key_or_cert_bin() 124 req.key_data.Reinitialize(key_data, key_data_size); in set_attestation_key_or_cert_bin() 127 ret = trusty_keymaster_send(cmd, req, &rsp); in set_attestation_key_or_cert_bin() 249 ClearAttestationCertChainRequest req; in clear_cert_chain() local 252 ret = str_to_algorithm(&req.algorithm, algorithm_str); in clear_cert_chain() 257 ret = trusty_keymaster_send(KM_CLEAR_ATTESTATION_CERT_CHAIN, req, &rsp); in clear_cert_chain() 346 keymaster::SetAttestationIdsRequest req(4 /* ver */); in provision_ids() local 349 req.brand.Reinitialize("trusty", 6); in provision_ids() 350 req.device.Reinitialize("trusty", 6); in provision_ids() [all …]
|
/system/extras/simpleperf/runtest/ |
D | run_and_sleep.cpp | 25 struct timespec req; in SleepFunction() local 26 req.tv_sec = sleep_time_in_ns / 1000000000; in SleepFunction() 27 req.tv_nsec = sleep_time_in_ns % 1000000000; in SleepFunction() 28 nanosleep(&req, nullptr); in SleepFunction()
|
D | runtest.py | 195 for req in self.symbol_overhead_requirements: 196 strs.append('\t\t%s' % req) 198 for req in self.symbol_children_overhead_requirements: 199 strs.append('\t\t%s' % req) 201 for req in self.symbol_relation_requirements: 202 strs.append('\t\t%s' % req) 264 req = load_symbol_relation_requirement(symbol_item) 265 symbol_relation_requirements.append(req) 285 req = SymbolRelationRequirement(symbol_name, comm) 288 req.add_child(child_req) [all …]
|
/system/secretkeeper/comm/src/data_types/ |
D | request.rs | 61 let mut req = packet.into_inner(); in deserialize_from_packet() localVariable 62 if req.first() != Some(&Value::from(Self::OPCODE as u16)) { in deserialize_from_packet() 65 req.remove(0); in deserialize_from_packet() 66 Self::new(req) in deserialize_from_packet()
|
/system/core/libnetutils/ |
D | ifc_utils.c | 273 } req; in ifc_act_on_address() local 304 memset(&req, 0, sizeof(req)); in ifc_act_on_address() 307 req.n.nlmsg_len = NLMSG_LENGTH(sizeof(req.r)); in ifc_act_on_address() 308 req.n.nlmsg_type = action; in ifc_act_on_address() 309 req.n.nlmsg_flags = NLM_F_REQUEST | NLM_F_ACK; in ifc_act_on_address() 310 req.n.nlmsg_pid = getpid(); in ifc_act_on_address() 313 req.r.ifa_family = ss.ss_family; in ifc_act_on_address() 314 req.r.ifa_flags = nodad ? IFA_F_NODAD : 0; in ifc_act_on_address() 315 req.r.ifa_prefixlen = prefixlen; in ifc_act_on_address() 316 req.r.ifa_index = ifindex; in ifc_act_on_address() [all …]
|
/system/chre/core/ |
D | wifi_request_manager.cc | 281 PendingRangingRequest &req = mPendingRangingRequests.back(); in requestRanging() local 282 req.nanoappInstanceId = nanoapp->getInstanceId(); in requestRanging() 283 req.cookie = cookie; in requestRanging() 299 success = updateRangingRequest(rangingType, req, rangingParams); in requestRanging() 461 auto &req = mPendingNanSubscribeRequests.front(); in handleNanServiceIdentifierEventSync() local 472 event->result.cookie = req.cookie; in handleNanServiceIdentifierEventSync() 478 req.nanoappInstanceId, subscriptionId))) { in handleNanServiceIdentifierEventSync() 492 req.nanoappInstanceId); in handleNanServiceIdentifierEventSync() 725 for (const auto &req : mPendingNanSubscribeRequests) { in logStateToBuffer() local 727 req.nanoappInstanceId, req.type, req.service.data()); in logStateToBuffer() [all …]
|
/system/secretkeeper/core/src/ |
D | ta.rs | 155 let req = match bl::Request::from_slice(req_data) { in process_bootloader() localVariable 156 Ok(req) => req, in process_bootloader() 163 let rsp = match req { in process_bootloader() 186 Ok(req) => { in process() 187 trace!("-> TA: received request {:?}", req.code()); in process() 188 (Some(req.code()), self.process_req(req)) in process() 203 fn process_req(&mut self, req: PerformOpReq) -> PerformOpResponse { in process_req() 204 let code = req.code(); in process_req() 205 let result = match req { in process_req() 245 let req = self.decrypt_request(&encrypt0, kid)?; in secret_management() localVariable [all …]
|