/external/google-tv-pairing-protocol/cpp/src/polo/pairing/ |
D | polochallengeresponse.cc | 32 Alpha* PoloChallengeResponse::GetAlpha(const Nonce& nonce) const { in GetAlpha() 64 + nonce.size(); in GetAlpha() 81 memcpy(pos, &nonce[0], nonce.size()); in GetAlpha() 96 Gamma* PoloChallengeResponse::GetGamma(const Nonce& nonce) const { in GetGamma() 97 const Alpha* alpha = GetAlpha(nonce); in GetGamma() 102 Gamma* gamma = new Gamma(nonce.size() * 2); in GetGamma() 104 if (alpha->size() >= nonce.size()) { in GetGamma() 105 memcpy(&(*gamma)[0], &(*alpha)[0], nonce.size()); in GetGamma() 106 memcpy(&(*gamma)[nonce.size()], &nonce[0], nonce.size()); in GetGamma() 118 Nonce* nonce = new Nonce(gamma.size() / 2); in ExtractNonce() local [all …]
|
/external/google-tv-pairing-protocol/java/src/com/google/polo/pairing/ |
D | PoloChallengeResponse.java | 83 public byte[] getAlpha(byte[] nonce) throws PoloException { in getAlpha() argument 87 logDebug("getAlpha, nonce=" + PoloUtil.bytesToHexString(nonce)); in getAlpha() 124 logVerbose(" nonce: " + PoloUtil.bytesToHexString(nonce)); in getAlpha() 133 digest.update(nonce); in getAlpha() 148 public byte[] getGamma(byte[] nonce) throws PoloException { in getGamma() argument 149 byte[] alphaBytes = getAlpha(nonce); in getGamma() 150 assert(alphaBytes.length >= nonce.length); in getGamma() 152 byte[] result = new byte[nonce.length * 2]; in getGamma() 154 System.arraycopy(alphaBytes, 0, result, 0, nonce.length); in getGamma() 155 System.arraycopy(nonce, 0, result, nonce.length, nonce.length); in getGamma() [all …]
|
/external/chromium-trace/catapult/third_party/Paste/paste/auth/ |
D | digest.py | 80 self.nonce = {} # list to prevent replay attacks 89 nonce = md5(content).hexdigest() 96 self.nonce[nonce] = None 98 'nonce': nonce, 'opaque': opaque } 106 path, nonce, nc, cnonce, qop): argument 115 chk = "%s:%s:%s:%s:%s:%s" % (ha1, nonce, nc, cnonce, qop, ha2) 117 chk = "%s:%s:%s" % (ha1, nonce, ha2) 121 if nonce in self.nonce: 122 del self.nonce[nonce] 124 pnc = self.nonce.get(nonce,'00000000') [all …]
|
/external/boringssl/src/ssl/test/runner/ |
D | chacha20_poly1305.go | 65 func chaCha20(out, in, key, nonce []byte, counter uint64) { 75 switch len(nonce) { 77 state[14] = binary.LittleEndian.Uint32(nonce[0:4]) 78 state[15] = binary.LittleEndian.Uint32(nonce[4:8]) 80 state[13] = binary.LittleEndian.Uint32(nonce[0:4]) 81 state[14] = binary.LittleEndian.Uint32(nonce[4:8]) 82 state[15] = binary.LittleEndian.Uint32(nonce[8:12]) 143 func (c *chaCha20Poly1305) poly1305(tag *[16]byte, nonce, ciphertext, additionalData []byte) { 160 chaCha20(poly1305Key[:], poly1305Key[:], c.key[:], nonce, 0) 165 func (c *chaCha20Poly1305) poly1305Old(tag *[16]byte, nonce, ciphertext, additionalData []byte) { [all …]
|
D | chacha20_poly1305_test.go | 81 nonce := decodeHexOrPanic("cd7cf67be39c794a") 90 out, err := aead.Open(nil, nonce, output, ad) 97 out = aead.Seal(nil, nonce, input, ad) 103 _, err = aead.Open(nil, nonce, out, ad) 110 key, input, nonce, ad, output string 116 nonce: "070000004041424344454647", 124 nonce: "000000000102030405060708", 135 nonce := decodeHexOrPanic(tt.nonce) 144 out, err := aead.Open(nil, nonce, output, ad) 151 out = aead.Seal(nil, nonce, input, ad) [all …]
|
D | cipher_suites.go | 227 func (f *fixedNonceAEAD) Seal(out, nonce, plaintext, additionalData []byte) []byte { 228 copy(f.sealNonce[len(f.sealNonce)-8:], nonce) 232 func (f *fixedNonceAEAD) Open(out, nonce, plaintext, additionalData []byte) ([]byte, error) { 233 copy(f.openNonce[len(f.openNonce)-8:], nonce) 281 func (x *xorNonceAEAD) Seal(out, nonce, plaintext, additionalData []byte) []byte { 282 xorSlice(x.sealNonce[len(x.sealNonce)-len(nonce):], nonce) 284 xorSlice(x.sealNonce[len(x.sealNonce)-len(nonce):], nonce) 288 func (x *xorNonceAEAD) Open(out, nonce, plaintext, additionalData []byte) ([]byte, error) { 289 xorSlice(x.openNonce[len(x.openNonce)-len(nonce):], nonce) 291 xorSlice(x.openNonce[len(x.openNonce)-len(nonce):], nonce)
|
/external/dbus/dbus/ |
D | dbus-nonce.c | 34 do_check_nonce (int fd, const DBusString *nonce, DBusError *error) in do_check_nonce() argument 82 result = _dbus_string_equal_len (&buffer, nonce, 16); in do_check_nonce() 101 _dbus_read_nonce (const DBusString *fname, DBusString *nonce, DBusError* error) in _dbus_read_nonce() argument 125 if (!_dbus_string_append_len (nonce, buffer, sizeof buffer - 1 )) in _dbus_read_nonce() 137 DBusString nonce; in _dbus_accept_with_noncefile() local 140 if (!_dbus_string_init (&nonce)) in _dbus_accept_with_noncefile() 143 if (_dbus_read_nonce (_dbus_noncefile_get_path(noncefile), &nonce, NULL) != TRUE) in _dbus_accept_with_noncefile() 148 if (do_check_nonce(fd, &nonce, NULL) != TRUE) { in _dbus_accept_with_noncefile() 160 DBusString nonce; in generate_and_write_nonce() local 165 if (!_dbus_string_init (&nonce)) in generate_and_write_nonce() [all …]
|
/external/jetty/src/java/org/eclipse/jetty/security/authentication/ |
D | DigestAuthenticator.java | 73 public Nonce(String nonce, long ts, int size) in Nonce() argument 75 _nonce=nonce; in Nonce() 202 digest.nonce = tok; in validateRequest() 263 Nonce nonce; in newNonce() local 270 nonce = new Nonce(new String(B64Code.encode(nounce)),request.getTimeStamp(),_maxNC); in newNonce() 272 while (_nonceMap.putIfAbsent(nonce._nonce,nonce)!=null); in newNonce() 273 _nonceQueue.add(nonce); in newNonce() 275 return nonce._nonce; in newNonce() 288 Nonce nonce=_nonceQueue.peek(); in checkNonce() local 289 while (nonce!=null && nonce._ts<expired) in checkNonce() [all …]
|
/external/libmicrohttpd/src/microhttpd/ |
D | digestauth.c | 103 const char *nonce, in digest_calc_ha1() argument 122 MD5Update (&md5, nonce, strlen (nonce)); in digest_calc_ha1() 146 const char *nonce, in digest_calc_response() argument 180 MD5Update (&md5, nonce, strlen(nonce)); in digest_calc_response() 302 const char *nonce, in check_nonce_nc() argument 314 np = nonce; in check_nonce_nc() 330 strcpy(connection->daemon->nnc[off].nonce, in check_nonce_nc() 331 nonce); in check_nonce_nc() 337 (0 != strcmp(connection->daemon->nnc[off].nonce, nonce)) ) in check_nonce_nc() 403 char *nonce) in calculate_nonce() argument [all …]
|
/external/bouncycastle/bcprov/src/main/java/org/bouncycastle/crypto/params/ |
D | AEADParameters.java | 9 private byte[] nonce; field in AEADParameters 20 public AEADParameters(KeyParameter key, int macSize, byte[] nonce) in AEADParameters() argument 22 this(key, macSize, nonce, null); in AEADParameters() 33 public AEADParameters(KeyParameter key, int macSize, byte[] nonce, byte[] associatedText) in AEADParameters() argument 36 this.nonce = nonce; in AEADParameters() 58 return nonce; in getNonce()
|
/external/google-tv-pairing-protocol/cpp/tests/polo/pairing/ |
D | polochallengeresponsetest.cc | 26 PoloChallengeResponseTest() : nonce(4) { } in PoloChallengeResponseTest() 76 nonce[0] = 0x1; in SetUp() 77 nonce[1] = 0x2; in SetUp() 78 nonce[2] = 0x3; in SetUp() 79 nonce[3] = 0x4; in SetUp() 98 Nonce nonce; member in polo::pairing::PoloChallengeResponseTest 103 const Alpha* alpha = response->GetAlpha(nonce); in TEST_F() 112 const Gamma* gamma = response->GetGamma(nonce); in TEST_F() 121 const Gamma* gamma = response->GetGamma(nonce); in TEST_F()
|
/external/boringssl/src/crypto/cipher/ |
D | e_chacha20poly1305.c | 98 const uint8_t nonce[12], const uint8_t *ad, in aead_poly1305() 104 c20_ctx->key, nonce, 0); in aead_poly1305() 113 size_t max_out_len, const uint8_t nonce[12], in seal_impl() 140 CRYPTO_chacha_20(out, in, in_len, c20_ctx->key, nonce, 1); in seal_impl() 143 aead_poly1305(poly1305_update, tag, c20_ctx, nonce, ad, ad_len, out, in_len); in seal_impl() 152 size_t max_out_len, const uint8_t nonce[12], in open_impl() 177 aead_poly1305(poly1305_update, tag, c20_ctx, nonce, ad, ad_len, in, in open_impl() 184 CRYPTO_chacha_20(out, in, plaintext_len, c20_ctx->key, nonce, 1); in open_impl() 210 const uint8_t *nonce, size_t nonce_len, in aead_chacha20_poly1305_seal() argument 217 return seal_impl(poly1305_update, ctx, out, out_len, max_out_len, nonce, in, in aead_chacha20_poly1305_seal() [all …]
|
D | aead_test.cc | 41 std::vector<uint8_t> key, nonce, in, ad, ct, tag; in TestAEAD() local 43 !t->GetBytes(&nonce, "NONCE") || in TestAEAD() 62 nonce.data(), nonce.size(), in.data(), in.size(), in TestAEAD() 97 nonce.data(), nonce.size(), out.data(), in TestAEAD() 130 nonce.data(), nonce.size(), out.data(), out.size(), in TestAEAD() 151 nonce.data(), nonce.size(), out.data(), out.size(), in TestAEAD()
|
/external/boringssl/src/ssl/ |
D | ssl_aead_ctx.c | 180 uint8_t nonce[EVP_AEAD_MAX_NONCE_LENGTH]; in SSL_AEAD_CTX_open() local 186 memset(nonce, 0, nonce_len); in SSL_AEAD_CTX_open() 188 memcpy(nonce, aead->fixed_nonce, aead->fixed_nonce_len); in SSL_AEAD_CTX_open() 199 memcpy(nonce + nonce_len, in, aead->variable_nonce_len); in SSL_AEAD_CTX_open() 204 memcpy(nonce + nonce_len, seqnum, aead->variable_nonce_len); in SSL_AEAD_CTX_open() 213 nonce[i] ^= aead->fixed_nonce[i]; in SSL_AEAD_CTX_open() 217 return EVP_AEAD_CTX_open(&aead->ctx, out, out_len, max_out, nonce, nonce_len, in SSL_AEAD_CTX_open() 241 uint8_t nonce[EVP_AEAD_MAX_NONCE_LENGTH]; in SSL_AEAD_CTX_seal() local 247 memset(nonce, 0, nonce_len); in SSL_AEAD_CTX_seal() 249 memcpy(nonce, aead->fixed_nonce, aead->fixed_nonce_len); in SSL_AEAD_CTX_seal() [all …]
|
/external/bouncycastle/bcprov/src/main/java/org/bouncycastle/asn1/cms/ |
D | GCMParameters.java | 28 private byte[] nonce; field in GCMParameters 62 this.nonce = ASN1OctetString.getInstance(seq.getObjectAt(0)).getOctets(); in GCMParameters() 78 byte[] nonce, in GCMParameters() argument 81 this.nonce = Arrays.clone(nonce); in GCMParameters() 87 return Arrays.clone(nonce); in getNonce() 99 v.add(new DEROctetString(nonce)); in toASN1Primitive()
|
/external/curl/tests/data/ |
D | test2027 | 29 WWW-Authenticate: Digest realm="testrealm", nonce="1" 39 WWW-Authenticate: Digest realm="testrealm", nonce="2" 50 WWW-Authenticate: Digest realm="testrealm", nonce="3" 70 WWW-Authenticate: Digest realm="testrealm", nonce="4" 80 WWW-Authenticate: Digest realm="testrealm", nonce="5" 91 WWW-Authenticate: Digest realm="testrealm", nonce="6" 101 WWW-Authenticate: Digest realm="testrealm", nonce="7" 121 WWW-Authenticate: Digest realm="testrealm", nonce="1" 127 WWW-Authenticate: Digest realm="testrealm", nonce="2" 140 WWW-Authenticate: Digest realm="testrealm", nonce="4" [all …]
|
D | test2030 | 35 WWW-Authenticate: Digest realm="testrealm", nonce="1" 55 WWW-Authenticate: Digest realm="testrealm", nonce="2" 68 WWW-Authenticate: Digest realm="testrealm", nonce="3" 88 WWW-Authenticate: Digest realm="testrealm", nonce="4" 110 WWW-Authenticate: Digest realm="testrealm", nonce="5" 121 WWW-Authenticate: Digest realm="testrealm", nonce="6" 133 WWW-Authenticate: Digest realm="testrealm", nonce="7" 144 WWW-Authenticate: Digest realm="testrealm", nonce="8" 170 WWW-Authenticate: Digest realm="testrealm", nonce="2" 191 WWW-Authenticate: Digest realm="testrealm", nonce="5" [all …]
|
D | test2026 | 22 WWW-Authenticate: Digest realm="testrealm", nonce="1" 34 WWW-Authenticate: Digest realm="testrealm", nonce="2" 55 WWW-Authenticate: Digest realm="testrealm", nonce="3" 67 WWW-Authenticate: Digest realm="testrealm", nonce="4" 78 WWW-Authenticate: Digest realm="testrealm", nonce="5" 99 WWW-Authenticate: Digest realm="testrealm", nonce="1" 107 WWW-Authenticate: Digest realm="testrealm", nonce="2" 120 WWW-Authenticate: Digest realm="testrealm", nonce="3" 128 WWW-Authenticate: Digest realm="testrealm", nonce="4" 135 WWW-Authenticate: Digest realm="testrealm", nonce="5" [all …]
|
D | test2028 | 23 WWW-Authenticate: Digest realm="testrealm", nonce="1" 33 WWW-Authenticate: Digest realm="testrealm", nonce="2" 46 WWW-Authenticate: Digest realm="testrealm", nonce="3" 76 WWW-Authenticate: Digest realm="testrealm", nonce="4" 88 WWW-Authenticate: Digest realm="testrealm", nonce="5" 99 WWW-Authenticate: Digest realm="testrealm", nonce="6" 121 WWW-Authenticate: Digest realm="testrealm", nonce="7" 132 WWW-Authenticate: Digest realm="testrealm", nonce="8" 163 WWW-Authenticate: Digest realm="testrealm", nonce="1" 169 WWW-Authenticate: Digest realm="testrealm", nonce="2" [all …]
|
/external/boringssl/src/crypto/rand/ |
D | rand.c | 162 uint8_t nonce[12]; in RAND_bytes() local 163 memset(nonce, 0, 4); in RAND_bytes() 164 memcpy(nonce + 4, &state->calls_used, sizeof(state->calls_used)); in RAND_bytes() 165 CRYPTO_chacha_20(buf, buf, todo, state->key, nonce, 0); in RAND_bytes() 172 uint8_t nonce[12]; in RAND_bytes() local 173 memset(nonce, 0, 4); in RAND_bytes() 174 memcpy(nonce + 4, &state->calls_used, sizeof(state->calls_used)); in RAND_bytes() 176 sizeof(state->partial_block), state->key, nonce, 0); in RAND_bytes()
|
/external/bouncycastle/bcprov/src/main/java/org/bouncycastle/crypto/modes/ |
D | CCMBlockCipher.java | 28 private byte[] nonce; field in CCMBlockCipher 74 nonce = param.getNonce(); in init() 83 nonce = param.getIV(); in init() 99 if (nonce == null || nonce.length < 7 || nonce.length > 13) in init() 248 int n = nonce.length; in processPacket() 261 System.arraycopy(nonce, 0, iv, 1, nonce.length); in processPacket() 368 b0[0] |= ((15 - nonce.length) - 1) & 0x7; in calculateMac() 370 System.arraycopy(nonce, 0, b0, 1, nonce.length); in calculateMac()
|
/external/wpa_supplicant_8/src/crypto/ |
D | aes-ccm.c | 28 static void aes_ccm_auth_start(void *aes, size_t M, size_t L, const u8 *nonce, in aes_ccm_auth_start() argument 40 os_memcpy(&b[1], nonce, 15 - L); in aes_ccm_auth_start() 84 static void aes_ccm_encr_start(size_t L, const u8 *nonce, u8 *a) in aes_ccm_encr_start() argument 88 os_memcpy(&a[1], nonce, 15 - L); in aes_ccm_encr_start() 148 int aes_ccm_ae(const u8 *key, size_t key_len, const u8 *nonce, in aes_ccm_ae() argument 163 aes_ccm_auth_start(aes, M, L, nonce, aad, aad_len, plain_len, x); in aes_ccm_ae() 167 aes_ccm_encr_start(L, nonce, a); in aes_ccm_ae() 178 int aes_ccm_ad(const u8 *key, size_t key_len, const u8 *nonce, in aes_ccm_ad() argument 195 aes_ccm_encr_start(L, nonce, a); in aes_ccm_ad() 201 aes_ccm_auth_start(aes, M, L, nonce, aad, aad_len, crypt_len, x); in aes_ccm_ad()
|
/external/tpm2/ |
D | Policy_spt.c | 25 TPM2B_NONCE *nonce, in PolicyParameterChecks() argument 33 if(nonce != NULL && nonce->t.size != 0) in PolicyParameterChecks() 36 if(!Memory2BEqual(&nonce->b, &session->nonceTPM.b)) in PolicyParameterChecks() 44 if(nonce != NULL && nonce->t.size == 0) in PolicyParameterChecks()
|
/external/srtp/crypto/test/ |
D | stat_driver.c | 46 v128_t nonce; in main() local 74 err_check(cipher_set_iv(c, &nonce)); in main() 84 v128_set_to_zero(&nonce); in main() 88 nonce.v32[3] = i; in main() 89 err_check(cipher_set_iv(c, &nonce)); in main()
|
/external/boringssl/src/crypto/modes/ |
D | gcm_test.c | 64 const char *nonce; member 305 *nonce = NULL, *ciphertext = NULL, *tag = NULL, *out = NULL; in run_test_case() local 315 !decode_hex(&nonce, &nonce_len, test->nonce, test_num, "nonce") || in run_test_case() 348 CRYPTO_gcm128_setiv(&ctx, &aes_key, nonce, nonce_len); in run_test_case() 364 CRYPTO_gcm128_setiv(&ctx, &aes_key, nonce, nonce_len); in run_test_case() 387 OPENSSL_free(nonce); in run_test_case()
|