Searched refs:key (Results 1 - 25 of 43) sorted by relevance

12

/system/core/libmincrypt/
H A Drsa.c30 int RSA_e_f4_verify(const RSAPublicKey* key,
35 int RSA_e_3_verify(const RSAPublicKey *key,
40 int RSA_verify(const RSAPublicKey *key, argument
44 switch (key->exponent) {
46 return RSA_e_3_verify(key, signature, len, sha);
49 return RSA_e_f4_verify(key, signature, len, sha);
H A Drsa_e_f4.c32 static void subM(const RSAPublicKey* key, argument
36 for (i = 0; i < key->len; ++i) {
37 A += (uint64_t)a[i] - key->n[i];
44 static int geM(const RSAPublicKey* key, argument
47 for (i = key->len; i;) {
49 if (a[i] < key->n[i]) return 0;
50 if (a[i] > key->n[i]) return 1;
56 static void montMulAdd(const RSAPublicKey* key, argument
61 uint32_t d0 = (uint32_t)A * key->n0inv;
62 uint64_t B = (uint64_t)d0 * key
81 montMul(const RSAPublicKey* key, uint32_t* c, const uint32_t* a, const uint32_t* b) argument
96 modpowF4(const RSAPublicKey* key, uint8_t* inout) argument
155 RSA_e_f4_verify(const RSAPublicKey* key, const uint8_t* signature, const int len, const uint8_t* sha) argument
[all...]
H A Drsa_e_3.c32 static void subM(const RSAPublicKey *key, uint32_t *a) { argument
35 for (i = 0; i < key->len; ++i) {
36 A += (uint64_t)a[i] - key->n[i];
43 static int geM(const RSAPublicKey *key, const uint32_t *a) { argument
45 for (i = key->len; i;) {
47 if (a[i] < key->n[i]) return 0;
48 if (a[i] > key->n[i]) return 1;
54 static void montMulAdd(const RSAPublicKey *key, argument
59 uint32_t d0 = (uint32_t)A * key->n0inv;
60 uint64_t B = (uint64_t)d0 * key
79 montMul(const RSAPublicKey *key, uint32_t* c, const uint32_t* a, const uint32_t* b) argument
95 modpow3(const RSAPublicKey *key, uint8_t* inout) argument
162 RSA_e_3_verify(const RSAPublicKey *key, const uint8_t *signature, const int len, const uint8_t *sha) argument
[all...]
/system/core/include/cutils/
H A Dstr_parms.h28 void str_parms_del(struct str_parms *str_parms, const char *key);
30 int str_parms_add_str(struct str_parms *str_parms, const char *key,
32 int str_parms_add_int(struct str_parms *str_parms, const char *key, int value);
34 int str_parms_add_float(struct str_parms *str_parms, const char *key,
37 int str_parms_get_str(struct str_parms *str_parms, const char *key,
39 int str_parms_get_int(struct str_parms *str_parms, const char *key,
41 int str_parms_get_float(struct str_parms *str_parms, const char *key,
H A Dproperties.h41 int property_get(const char *key, char *value, const char *default_value);
45 int property_set(const char *key, const char *value);
47 int property_list(void (*propfn)(const char *key, const char *value, void *cookie), void *cookie);
H A Dhashmap.h42 int (*hash)(void* key), bool (*equals)(void* keyA, void* keyB));
50 * Hashes the memory pointed to by key with the given size. Useful for
53 int hashmapHash(void* key, size_t keySize);
56 * Puts value for the given key in the map. Returns pre-existing value if
62 void* hashmapPut(Hashmap* map, void* key, void* value);
65 * Gets a value from the map. Returns NULL if no entry for the given key is
68 void* hashmapGet(Hashmap* map, void* key);
71 * Returns true if the map contains an entry for the given key.
73 bool hashmapContainsKey(Hashmap* map, void* key);
76 * Gets the value for a key
[all...]
H A Dsockets.h49 char key[64] = ANDROID_SOCKET_ENV_PREFIX; local
55 strlcpy(key + sizeof(ANDROID_SOCKET_ENV_PREFIX) - 1,
57 sizeof(key) - sizeof(ANDROID_SOCKET_ENV_PREFIX));
59 strncpy(key + sizeof(ANDROID_SOCKET_ENV_PREFIX) - 1,
61 sizeof(key) - sizeof(ANDROID_SOCKET_ENV_PREFIX));
62 key[sizeof(key)-1] = '\0';
65 val = getenv(key);
/system/core/adb/
H A Dadb_auth_client.c34 RSAPublicKey key; member in struct:adb_public_key
51 struct adb_public_key *key; local
65 key = calloc(1, sizeof(*key) + 4);
66 if (!key) {
67 D("Can't malloc key\n");
75 ret = __b64_pton(buf, (u_char *)&key->key, sizeof(key->key)
139 struct adb_public_key *key; local
175 adb_auth_confirm_key(unsigned char *key, size_t len, atransport *t) argument
[all...]
H A Dadb_auth.h32 int adb_auth_sign(void *key, void *token, size_t token_size, void *sig);
43 static inline int adb_auth_sign(void* key, void *token, size_t token_size, void *sig) { return 0; } argument
H A Dadb_auth_host.c62 /* Convert OpenSSL RSA private key to android pre-computed RSAPublicKey format */
155 D("Writing public key to '%s'\n", path);
186 D("Failed to allocate key\n");
206 D("Failed to write key\n");
211 D("Failed to write public key\n");
228 struct adb_private_key *key; local
239 key = malloc(sizeof(*key));
240 if (!key) {
241 D("Failed to alloc key\
349 struct adb_private_key *key = node_to_item(node, struct adb_private_key, node); local
[all...]
/system/core/libcutils/
H A Dstr_parms.c75 const char *key; member in struct:remove_ctxt
78 static bool remove_pair(void *key, void *value, void *context) argument
84 * - if key is not supplied, then we are removing all entries,
85 * so remove key and continue (i.e. return true)
86 * - if key is supplied and matches, then remove it and don't
88 * for key.
91 if (!ctxt->key) {
94 } else if (!strcmp(ctxt->key, key)) {
102 hashmapRemove(ctxt->str_parms->map, key);
108 str_parms_del(struct str_parms *str_parms, const char *key) argument
150 char *key; local
192 str_parms_add_str(struct str_parms *str_parms, const char *key, const char *value) argument
214 str_parms_add_int(struct str_parms *str_parms, const char *key, int value) argument
227 str_parms_add_float(struct str_parms *str_parms, const char *key, float value) argument
241 str_parms_get_str(struct str_parms *str_parms, const char *key, char *val, int len) argument
253 str_parms_get_int(struct str_parms *str_parms, const char *key, int *val) argument
269 str_parms_get_float(struct str_parms *str_parms, const char *key, float *val) argument
287 combine_strings(void *key, void *value, void *context) argument
321 dump_entry(void *key, void *value, void *context) argument
[all...]
H A Dhashmap.c28 void* key; member in struct:Entry
37 int (*hash)(void* key);
44 int (*hash)(void* key), bool (*equals)(void* keyA, void* keyB)) {
78 * Hashes the given key.
80 static inline int hashKey(Hashmap* map, void* key) { argument
81 int h = map->hash(key);
155 int hashmapHash(void* key, size_t keySize) { argument
157 char* data = (char*) key;
166 static Entry* createEntry(void* key, int hash, void* value) { argument
171 entry->key
43 hashmapCreate(size_t initialCapacity, int (*hash)(void* key), bool (*equals)(void* keyA, void* keyB)) argument
189 hashmapPut(Hashmap* map, void* key, void* value) argument
221 hashmapGet(Hashmap* map, void* key) argument
236 hashmapContainsKey(Hashmap* map, void* key) argument
251 hashmapMemoize(Hashmap* map, void* key, void* (*initialValue)(void* key, void* context), void* context) argument
284 hashmapRemove(Hashmap* map, void* key) argument
306 hashmapForEach(Hashmap* map, bool (*callback)(void* key, void* value, void* context), void* context) argument
342 hashmapIntHash(void* key) argument
[all...]
H A Dproperties.c34 int property_set(const char *key, const char *value) argument
36 return __system_property_set(key, value);
39 int property_get(const char *key, char *value, const char *default_value) argument
43 len = __system_property_get(key, value);
55 int property_list(void (*propfn)(const char *key, const char *value, void *cookie), argument
137 int property_get(const char *key, char *value, const char *default_value) argument
143 //ALOGV("PROPERTY GET [%s]\n", key);
155 if (strlen(key) >= PROPERTY_KEY_MAX) return -1;
160 strcpy(sendBuf+1, key);
198 // recvBuf[0], default_value, len, key, valu
204 property_set(const char *key, const char *value) argument
241 property_list(void (*propfn)(const char *key, const char *value, void *cookie), void *cookie) argument
260 property_get(const char *key, char *value, const char *default_value) argument
294 property_set(const char *key, const char *value) argument
324 property_list(void (*propfn)(const char *key, const char *value, void *cookie), void *cookie) argument
[all...]
/system/core/libpixelflinger/tinyutils/
H A DKeyedVector.h55 const VALUE& valueFor(const KEY& key) const;
58 ssize_t indexOfKey(const KEY& key) const;
64 VALUE& editValueFor(const KEY& key);
71 ssize_t add(const KEY& key, const VALUE& item);
72 ssize_t replaceValueFor(const KEY& key, const VALUE& item);
79 ssize_t removeItem(const KEY& key);
90 * valueFor() is called with a key that doesn't exist.
97 const VALUE& valueFor(const KEY& key) const;
111 ssize_t KeyedVector<KEY,VALUE>::indexOfKey(const KEY& key) const {
112 return mVector.indexOf( key_value_pair_t<KEY,VALUE>(key) );
133 editValueFor(const KEY& key) argument
145 add(const KEY& key, const VALUE& value) argument
150 replaceValueFor(const KEY& key, const VALUE& value) argument
166 removeItem(const KEY& key) argument
[all...]
H A DTypeHelpers.h206 * a key/value pair
211 KEY key; member in struct:android::key_value_pair_t
214 key_value_pair_t(const key_value_pair_t& o) : key(o.key), value(o.value) { }
215 key_value_pair_t(const KEY& k, const VALUE& v) : key(k), value(v) { }
216 key_value_pair_t(const KEY& k) : key(k) { }
218 return strictly_order_type(key, o.key);
/system/core/include/mincrypt/
H A Drsa.h37 #define RSANUMBYTES 256 /* 2048 bit key length */
48 int RSA_verify(const RSAPublicKey *key,
/system/core/libpixelflinger/codeflinger/
H A DCodeCache.h36 virtual int compare_type(const AssemblyKeyBase& key) const = 0;
44 virtual int compare_type(const AssemblyKeyBase& key) const {
45 const T& rhs = static_cast<const AssemblyKey&>(key).mKey;
84 sp<Assembly> lookup(const AssemblyKeyBase& key) const;
86 int cache( const AssemblyKeyBase& key,
126 return lhs.key.mKey->compare_type(*(rhs.key.mKey));
/system/core/libmincrypt/tools/
H A DDumpPublicKey.java35 * @param key to perform sanity checks on
36 * @return version number of key. Supported versions are:
37 * 1: 2048-bit key with e=3
38 * 2: 2048-bit key with e=65537
39 * @throws Exception if the key has the wrong size or public exponent
42 static int check(RSAPublicKey key) throws Exception { argument
43 BigInteger pubexp = key.getPublicExponent();
44 BigInteger modulus = key.getModulus();
65 * @param key to output
66 * @return a String representing this public key
70 print(RSAPublicKey key) argument
[all...]
/system/core/toolbox/
H A Dreadtty.c11 char key; member in struct:__anon485
26 char next_char(char key, char current) argument
31 if(key == map[i].key) {
38 return key;
41 char prev_char(char key, char current) argument
46 if(key == map[i].key) {
53 return key;
H A Dgetprop.c9 static void record_prop(const char* key, const char* name, void* opaque) argument
13 snprintf(temp, sizeof temp, "[%s]: [%s]", key, name);
/system/core/fastboot/
H A Dgenkey.sh9 # Generate a 2048 bit RSA key with public exponent 3.
10 # Encrypt private key with provided password.
13 # Create a self-signed cert for this key.
14 openssl req -new -x509 -key $1.pem -passin pass:"$2" \
18 # Create a PKCS12 store containing the generated private key.
19 # Protect the keystore and the private key with the provided password.
/system/vold/
H A DDevmapper.h27 static int create(const char *name, const char *loopFile, const char *key,
H A DVolumeManager.h93 const char *key, const int ownerUid, bool isExternal);
108 int mountAsec(const char *id, const char *key, int ownerUid);
116 int mountObb(const char *fileName, const char *key, int ownerUid);
/system/security/keystore/
H A Dkeystore_get.h36 * The first two arguments are the key and its length. The third argument
40 static int keystore_get(const char *key, int length, char *value) argument
55 send(sock, key, length, 0) == length && shutdown(sock, SHUT_WR) == 0 &&
/system/extras/tests/bionic/libc/common/
H A Dbench_pthread.c165 /* Used when creating the key */
176 pthread_key_t key; local
177 pthread_key_create(&key, key_destroy);
178 pthread_setspecific(key, (void*)(int)100);
182 BENCH(pthread_getspecific(key));

Completed in 152 milliseconds

12