Lines Matching refs:vector
243 static void parse_vector(const struct test_vector* vector, in parse_vector() argument
249 args->mode = vector->mode; in parse_vector()
251 args->key = vector->key; in parse_vector()
252 args->iv = vector->iv; in parse_vector()
253 args->aad = vector->aad; in parse_vector()
255 args->text_in = vector->plaintext; in parse_vector()
257 args->text_in = vector->ciphertext; in parse_vector()
258 args->tag_in = vector->tag; in parse_vector()
267 if (encrypt && vector->tag.len > 0) { in parse_vector()
269 args->tag_out.len = vector->tag.len; in parse_vector()
706 const struct test_vector* vector = vectors; in TEST_F() local
707 for (unsigned long i = 0; i < countof(vectors); ++i, ++vector) { in TEST_F()
716 parse_vector(vector, &shm_hd, &args, 1 /* encrypt */); in TEST_F()
721 rc = memcmp(_state->shm_base, vector->ciphertext.data_ptr, in TEST_F()
722 vector->ciphertext.len); in TEST_F()
725 if (vector->tag.len > 0) { in TEST_F()
726 rc = memcmp((uint8_t*)_state->shm_base + vector->ciphertext.len, in TEST_F()
727 vector->tag.data_ptr, vector->tag.len); in TEST_F()
736 const struct test_vector* vector = vectors; in TEST_F() local
737 for (unsigned long i = 0; i < countof(vectors); ++i, ++vector) { in TEST_F()
746 parse_vector(vector, &shm_hd, &args, 0 /* decrypt */); in TEST_F()
751 rc = memcmp(_state->shm_base, vector->plaintext.data_ptr, in TEST_F()
752 vector->plaintext.len); in TEST_F()