Lines Matching refs:length
56 static rt_uint32_t _crc_update(struct hwcrypto_crc *ctx, const rt_uint8_t *in, rt_size_t length) in _crc_update() argument
68 temp = rt_malloc(length); in _crc_update()
71 memcpy(temp, in, length); in _crc_update()
107 crc_result = tls_crypto_crc_update_adv(ctx->crc_cfg.last_val, type, mode, in, length); in _crc_update()
123 static rt_err_t _hash_update(struct hwcrypto_hash *ctx, const rt_uint8_t *in, rt_size_t length) in _hash_update() argument
133 temp = rt_malloc(length); in _hash_update()
136 memcpy(temp, in, length); in _hash_update()
153 tls_crypto_md5_update(&((struct hash_ctx_des *)(ctx->parent.contex))->contex, in, length); in _hash_update()
156 tls_crypto_sha1_update(&((struct hash_ctx_des *)(ctx->parent.contex))->contex, in, length); in _hash_update()
176 static rt_err_t _hash_finish(struct hwcrypto_hash *ctx, rt_uint8_t *out, rt_size_t length) in _hash_finish() argument
211 || (symmetric_info->length % 8) != 0) in _des_crypt()
222 in = rt_malloc(symmetric_info->length); in _des_crypt()
225 memcpy(in, symmetric_info->in, symmetric_info->length); in _des_crypt()
255 symmetric_info->length, cbc, mode); in _des_crypt()
263 memcpy(symmetric_info->out, out, symmetric_info->length); in _des_crypt()
279 || (symmetric_info->length % 8) != 0) in _des3_crypt()
290 in = rt_malloc(symmetric_info->length); in _des3_crypt()
293 memcpy(in, symmetric_info->in, symmetric_info->length); in _des3_crypt()
323 symmetric_info->length, cbc, mode); in _des3_crypt()
331 memcpy(symmetric_info->out, out, symmetric_info->length); in _des3_crypt()
355 in = rt_malloc(symmetric_info->length); in _rc4_crypt()
358 memcpy(in, symmetric_info->in, symmetric_info->length); in _rc4_crypt()
375 symmetric_info->length); in _rc4_crypt()
383 memcpy(symmetric_info->out, out, symmetric_info->length); in _rc4_crypt()
399 || (symmetric_info->length % 16) != 0) in _aes_crypt()
410 in = rt_malloc(symmetric_info->length); in _aes_crypt()
413 memcpy(in, symmetric_info->in, symmetric_info->length); in _aes_crypt()
445 in, out, symmetric_info->length, cbc, mode); in _aes_crypt()
453 memcpy(symmetric_info->out, out, symmetric_info->length); in _aes_crypt()