Home | History | Annotate | Download | only in pkcs1

Lines Matching refs:DB

40    unsigned char *DB, *seed, *mask;
66 /* allocate ram for DB/mask/salt of size modulus_len */
67 DB = XMALLOC(modulus_len);
70 if (DB == NULL || mask == NULL || seed == NULL) {
71 if (DB != NULL) {
72 XFREE(DB);
84 /* DB == lhash || PS || 0x01 || M, PS == k - mlen - 2hlen - 2 zeroes */
87 if ((err = hash_memory(hash_idx, lparam, lparamlen, DB, &x)) != CRYPT_OK) {
91 /* can't pass hash_memory a NULL so use DB with zero length */
92 if ((err = hash_memory(hash_idx, DB, 0, DB, &x)) != CRYPT_OK) {
100 XMEMSET(DB+x, 0, y);
104 DB[x++] = 0x01;
107 XMEMCPY(DB+x, msg, msglen);
121 /* xor against DB */
123 DB[y] ^= mask[y];
127 if ((err = pkcs_1_mgf1(hash_idx, DB, modulus_len - hLen - 1, mask, hLen)) != CRYPT_OK) {
148 XMEMCPY(out+x, DB, modulus_len - hLen - 1);
156 zeromem(DB, modulus_len);
163 XFREE(DB);