Home
last modified time | relevance | path

Searched refs:UniquePtr (Results 1 – 25 of 130) sorted by relevance

123456

/system/chre/util/include/chre/util/
Dunique_ptr_impl.h32 UniquePtr<ObjectType>::UniquePtr() : mObject(nullptr) {} in UniquePtr() function
35 UniquePtr<ObjectType>::UniquePtr(ObjectType *object) : mObject(object) {} in UniquePtr() function
38 UniquePtr<ObjectType>::UniquePtr(UniquePtr<ObjectType>&& other) { in UniquePtr() function
45 UniquePtr<ObjectType>::UniquePtr(UniquePtr<OtherObjectType>&& other) { in UniquePtr() function
51 UniquePtr<ObjectType>::~UniquePtr() { in ~UniquePtr()
56 bool UniquePtr<ObjectType>::isNull() const { in isNull()
61 ObjectType *UniquePtr<ObjectType>::get() const { in get()
66 ObjectType *UniquePtr<ObjectType>::release() { in release()
73 void UniquePtr<ObjectType>::reset(ObjectType *object) { in reset()
81 void UniquePtr<ObjectType>::reset() { in reset()
[all …]
Dunique_ptr.h32 class UniquePtr : public NonCopyable {
42 UniquePtr();
52 UniquePtr(ObjectType *object);
59 UniquePtr(UniquePtr<ObjectType>&& other);
69 UniquePtr(UniquePtr<OtherObjectType>&& other);
74 ~UniquePtr();
138 UniquePtr<ObjectType>& operator=(UniquePtr<ObjectType>&& other);
148 bool operator==(const UniquePtr<ObjectType> &other) const;
158 bool operator!=(const UniquePtr<ObjectType> &other) const;
164 friend class UniquePtr;
[all …]
/system/keymaster/include/keymaster/
DUniquePtr.h52 class UniquePtr {
55 class UniquePtr;
57 UniquePtr() : mPtr(nullptr) {}
59 explicit UniquePtr(T* ptr) : mPtr(ptr) {
62 UniquePtr(const decltype(nullptr)&) : mPtr(nullptr) {}
64 UniquePtr(UniquePtr && other): mPtr(other.mPtr) {
70 UniquePtr(UniquePtr<U>&& other) : mPtr(other.mPtr) {
73 UniquePtr& operator=(UniquePtr && other) {
81 ~UniquePtr() {
116 template <typename T2> bool operator==(const UniquePtr<T2>& p) const;
[all …]
Doperation_table.h28 using OperationPtr = UniquePtr<Operation>;
41 UniquePtr<OperationPtr[]> table_;
Dasymmetric_key_factory.h34 UniquePtr<Key>* key) const override;
38 UniquePtr<AsymmetricKey>* key) const = 0;
/system/gatekeeper/include/gatekeeper/
DUniquePtr.h52 class UniquePtr {
55 class UniquePtr;
57 UniquePtr() : mPtr(nullptr) {}
59 explicit UniquePtr(T* ptr) : mPtr(ptr) {
62 UniquePtr(const decltype(nullptr)&) : mPtr(nullptr) {}
64 UniquePtr(UniquePtr && other): mPtr(other.mPtr) {
70 UniquePtr(UniquePtr<U>&& other) : mPtr(other.mPtr) {
73 UniquePtr& operator=(UniquePtr && other) {
81 ~UniquePtr() {
116 template <typename T2> bool operator==(const UniquePtr<T2>& p) const;
[all …]
/system/chre/apps/include/chre/apps/
Dapps.h25 UniquePtr<Nanoapp> initializeStaticNanoappAshWorld();
26 UniquePtr<Nanoapp> initializeStaticNanoappAudioWorld();
27 UniquePtr<Nanoapp> initializeStaticNanoappGnssWorld();
28 UniquePtr<Nanoapp> initializeStaticNanoappHelloWorld();
29 UniquePtr<Nanoapp> initializeStaticNanoappHostAwakeWorld();
30 UniquePtr<Nanoapp> initializeStaticNanoappMessageWorld();
31 UniquePtr<Nanoapp> initializeStaticNanoappSensorWorld();
32 UniquePtr<Nanoapp> initializeStaticNanoappSpammer();
33 UniquePtr<Nanoapp> initializeStaticNanoappTimerWorld();
34 UniquePtr<Nanoapp> initializeStaticNanoappUnloadTester();
[all …]
/system/chre/util/tests/
Dunique_ptr_test.cc7 using chre::UniquePtr;
31 TEST(UniquePtr, Construct) { in TEST() argument
32 UniquePtr<Value> myInt = MakeUnique<Value>(0xcafe); in TEST()
44 TEST(UniquePtr, MakeUniqueZeroFill) { in TEST() argument
55 TEST(UniquePtr, MoveConstruct) { in TEST() argument
56 UniquePtr<Value> myInt = MakeUnique<Value>(0xcafe); in TEST()
60 UniquePtr<Value> moved(std::move(myInt)); in TEST()
65 TEST(UniquePtr, Move) { in TEST() argument
69 UniquePtr<Value> myInt = MakeUnique<Value>(0xcafe); in TEST()
73 UniquePtr<Value> myMovedInt = MakeUnique<Value>(0); in TEST()
[all …]
Dblocking_queue_test.cc24 using chre::UniquePtr;
43 UniquePtr<int> ptr = MakeUnique<int>(); in TEST()
46 FixedSizeBlockingQueue<UniquePtr<int>, 16> blockingQueue; in TEST()
/system/core/adb/tls/
Dtls_connection.cpp53 static bssl::UniquePtr<EVP_PKEY> EvpPkeyFromPEM(std::string_view pem);
54 static bssl::UniquePtr<CRYPTO_BUFFER> BufferFromPEM(std::string_view pem);
60 static bssl::UniquePtr<X509> X509FromBuffer(bssl::UniquePtr<CRYPTO_BUFFER> buffer);
67 bssl::UniquePtr<EVP_PKEY> priv_key_;
68 bssl::UniquePtr<CRYPTO_BUFFER> cert_;
70 bssl::UniquePtr<STACK_OF(X509_NAME)> ca_list_;
71 bssl::UniquePtr<SSL_CTX> ssl_ctx_;
72 bssl::UniquePtr<SSL> ssl_;
73 std::vector<bssl::UniquePtr<X509>> known_certificates_;
108 bssl::UniquePtr<EVP_PKEY> TlsConnectionImpl::EvpPkeyFromPEM(std::string_view pem) { in EvpPkeyFromPEM()
[all …]
/system/keymaster/tests/
Dandroid_keymaster_messages_test.cpp40 UniquePtr<uint8_t[]> buf(new uint8_t[size]); in round_trip()
71 UniquePtr<EmptyKeymasterResponse> deserialized(round_trip(ver, msg, 5)); in TEST()
80 UniquePtr<EmptyKeymasterResponse> deserialized(round_trip(ver, msg, 4)); in TEST()
89 UniquePtr<SupportedByAlgorithmRequest> deserialized(round_trip(ver, req, 4)); in TEST()
100 UniquePtr<SupportedByAlgorithmAndPurposeRequest> deserialized(round_trip(ver, req, 8)); in TEST()
113 UniquePtr<SupportedResponse<keymaster_digest_t>> deserialized(round_trip(ver, rsp, 20)); in TEST()
134 UniquePtr<GenerateKeyRequest> deserialized(round_trip(ver, req, 78)); in TEST()
147 UniquePtr<GenerateKeyResponse> deserialized(round_trip(ver, rsp, 109)); in TEST()
162 UniquePtr<GenerateKeyResponse> deserialized(round_trip(ver, rsp, 4)); in TEST()
176 UniquePtr<GetKeyCharacteristicsRequest> deserialized(round_trip(ver, req, 85)); in TEST()
[all …]
/system/chre/platform/slpi/include/chre/platform/slpi/smgr/
Dsmr_helper.h46 using SmrReqCallback = void (*)(UniquePtr<RespStruct> resp, void *callbackData,
85 UniquePtr<ReqStruct> *req, UniquePtr<RespStruct> *resp, in sendReqAsync()
137 UniquePtr<ReqStruct> *req, UniquePtr<RespStruct> *resp,
212 UniquePtr<ReqStruct> reqCStruct;
215 UniquePtr<RespStruct> respCStruct;
288 UniquePtr<AsyncCallbackData<ReqStruct, RespStruct>> cbData( in smrAsyncRespCb()
/system/keymaster/include/keymaster/km_openssl/
Dopenssl_utils.h52 typedef UniquePtr<name, name##_Delete> name##_Ptr;
72 typedef UniquePtr<BIGNUM, BIGNUM_Delete> BIGNUM_Ptr;
83 inline void release_because_ownership_transferred(UniquePtr<T, Delete_T>& p) { in release_because_ownership_transferred()
89 UniquePtr<EVP_PKEY, EVP_PKEY_Delete>* pkey);
94 UniquePtr<EVP_PKEY, EVP_PKEY_Delete>* evp_pkey);
/system/keymaster/km_openssl/
Dopenssl_utils.cpp79 UniquePtr<EVP_PKEY, EVP_PKEY_Delete>* pkey) { in convert_pkcs8_blob_to_evp()
83 UniquePtr<PKCS8_PRIV_KEY_INFO, PKCS8_PRIV_KEY_INFO_Delete> pkcs8( in convert_pkcs8_blob_to_evp()
104 UniquePtr<EVP_PKEY, EVP_PKEY_Delete>* pkey) { in KeyMaterialToEvpKey()
128 UniquePtr<BN_CTX, BN_CTX_Delete> bn_ctx(BN_CTX_new()); in ec_group_size_bits()
129 UniquePtr<BIGNUM, BIGNUM_Delete> order(BN_new()); in ec_group_size_bits()
Dasymmetric_key_factory.cpp45 UniquePtr<Key>* key) const { in LoadKey()
46 UniquePtr<AsymmetricKey> asym_key; in LoadKey()
59 UniquePtr<EVP_PKEY, EVP_PKEY_Delete> pkey_deleter(pkey); in LoadKey()
Dhkdf.cpp38 UniquePtr<uint8_t[]> zeros(new(std::nothrow) uint8_t[digest_size_]); in GenerateKey()
48 UniquePtr<uint8_t[]> pseudo_random_key(new(std::nothrow) uint8_t[digest_size_]); in GenerateKey()
64 UniquePtr<uint8_t[]> buf(new(std::nothrow) uint8_t[digest_size_ + info_len + 1]); in GenerateKey()
65 UniquePtr<uint8_t[]> digest(new(std::nothrow) uint8_t[digest_size_]); in GenerateKey()
Drsa_key_factory.cpp81 UniquePtr<BIGNUM, BIGNUM_Delete> exponent(BN_new()); in GenerateKey()
82 UniquePtr<RSA, RsaKey::RSA_Delete> rsa_key(RSA_new()); in GenerateKey()
83 UniquePtr<EVP_PKEY, EVP_PKEY_Delete> pkey(EVP_PKEY_new()); in GenerateKey()
133 UniquePtr<EVP_PKEY, EVP_PKEY_Delete> pkey; in UpdateImportKeyDescription()
139 UniquePtr<RSA, RsaKey::RSA_Delete> rsa_key(EVP_PKEY_get1_RSA(pkey.get())); in UpdateImportKeyDescription()
176 UniquePtr<AsymmetricKey>* key) const { in CreateEmptyKey()
Dnist_curve_key_exchange.cpp58 UniquePtr<EC_KEY, EC_KEY_Delete> key(EC_KEY_new_by_curve_name(curve_name)); in GenerateKeyExchange()
63 UniquePtr<NistCurveKeyExchange> key_exchange(new (std::nothrow) in GenerateKeyExchange()
101 UniquePtr<EC_POINT, EC_POINT_Delete> point(EC_POINT_new(group)); in CalculateSharedKey()
111 UniquePtr<uint8_t[]> result(new (std::nothrow) uint8_t[shared_secret_len_]); in CalculateSharedKey()
Dec_key_factory.cpp94 UniquePtr<EC_KEY, EC_KEY_Delete> ec_key(EC_KEY_new()); in GenerateKey()
95 UniquePtr<EVP_PKEY, EVP_PKEY_Delete> pkey(EVP_PKEY_new()); in GenerateKey()
99 UniquePtr<EC_GROUP, EC_GROUP_Delete> group(ChooseGroup(ec_curve)); in GenerateKey()
155 UniquePtr<EVP_PKEY, EVP_PKEY_Delete> pkey; in UpdateImportKeyDescription()
161 UniquePtr<EC_KEY, EC_KEY_Delete> ec_key(EVP_PKEY_get1_EC_KEY(pkey.get())); in UpdateImportKeyDescription()
244 UniquePtr<AsymmetricKey>* key) const { in CreateEmptyKey()
/system/keymaster/include/keymaster/contexts/
Dkeymaster1_passthrough_context.h82 UniquePtr<Key>* key) const override;
126 mutable std::unordered_map<keymaster_algorithm_t, UniquePtr<KeyFactory>> factories_;
127 UniquePtr<KeymasterPassthroughEngine> pt_engine_;
128 UniquePtr<Keymaster1Engine> km1_engine_;
Dkeymaster2_passthrough_context.h75 UniquePtr<Key>* key) const override;
113 mutable std::unordered_map<keymaster_algorithm_t, UniquePtr<KeymasterPassthroughKeyFactory>>
115 UniquePtr<KeymasterPassthroughEngine> engine_;
/system/chre/core/
Devent_loop.cc67 for (const UniquePtr<Nanoapp>& app : mNanoapps) { in findNanoappInstanceIdByAppId()
81 for (const UniquePtr<Nanoapp>& nanoapp : mNanoapps) { in forEachNanoapp()
143 bool EventLoop::startNanoapp(UniquePtr<Nanoapp>& nanoapp) { in startNanoapp()
328 for (const UniquePtr<Nanoapp>& app : mNanoapps) { in logStateToBuffer()
363 for (const UniquePtr<Nanoapp>& app : mNanoapps) { in deliverEvents()
372 bool EventLoop::deliverNextEvent(const UniquePtr<Nanoapp>& app) { in deliverNextEvent()
386 for (const UniquePtr<Nanoapp>& app : mNanoapps) { in distributeEvent()
427 for (const UniquePtr<Nanoapp>& app : mNanoapps) { in lookupAppByAppId()
440 for (const UniquePtr<Nanoapp>& app : mNanoapps) { in lookupAppByInstanceId()
465 const UniquePtr<Nanoapp>& nanoapp = mNanoapps[index]; in unloadNanoappAtIndex()
/system/core/adb/crypto/
Drsa_2048_key.cpp71 bssl::UniquePtr<EVP_PKEY> pkey(EVP_PKEY_new()); in CreateRSA2048Key()
72 bssl::UniquePtr<BIGNUM> exponent(BN_new()); in CreateRSA2048Key()
73 bssl::UniquePtr<RSA> rsa(RSA_new()); in CreateRSA2048Key()
/system/core/adb/crypto/include/adb/crypto/
Dkey.h31 explicit Key(bssl::UniquePtr<EVP_PKEY>&& pkey, adb::proto::KeyType type) in Key()
41 bssl::UniquePtr<EVP_PKEY> pkey_;
/system/security/keystore-engine/
Dandroid_engine.cpp258 bssl::UniquePtr<RSA> rsa(RSA_new_method(g_keystore_engine->engine())); in wrap_rsa()
280 bssl::UniquePtr<EVP_PKEY> result(EVP_PKEY_new()); in wrap_rsa()
294 bssl::UniquePtr<EC_KEY> ec(EC_KEY_new_method(g_keystore_engine->engine())); in wrap_ecdsa()
315 bssl::UniquePtr<EVP_PKEY> result(EVP_PKEY_new()); in wrap_ecdsa()
352 bssl::UniquePtr<EVP_PKEY> pkey(d2i_PUBKEY(nullptr, &inp, pubkey_len)); in EVP_PKEY_from_keystore()
361 bssl::UniquePtr<RSA> public_rsa(EVP_PKEY_get1_RSA(pkey.get())); in EVP_PKEY_from_keystore()
366 bssl::UniquePtr<EC_KEY> public_ecdsa(EVP_PKEY_get1_EC_KEY(pkey.get())); in EVP_PKEY_from_keystore()

123456