Lines Matching refs:algo
515 static void __xfrm_algo_print(struct xfrm_algo *algo, int type, int len, in __xfrm_algo_print() argument
526 if (len < sizeof(*algo)) { in __xfrm_algo_print()
530 len -= sizeof(*algo); in __xfrm_algo_print()
532 fprintf(fp, "%s ", algo->alg_name); in __xfrm_algo_print()
534 keylen = algo->alg_key_len / 8; in __xfrm_algo_print()
542 fprintf(fp, "%.2x", (unsigned char)algo->alg_key[i]); in __xfrm_algo_print()
545 fprintf(fp, " (%d bits)", algo->alg_key_len); in __xfrm_algo_print()
552 static inline void xfrm_algo_print(struct xfrm_algo *algo, int type, int len, in xfrm_algo_print() argument
555 return __xfrm_algo_print(algo, type, len, fp, prefix, 1); in xfrm_algo_print()
558 static void xfrm_aead_print(struct xfrm_algo_aead *algo, int len, in xfrm_aead_print() argument
562 struct xfrm_algo algo; in xfrm_aead_print() member
563 char key[algo->alg_key_len / 8]; in xfrm_aead_print()
566 memcpy(base.algo.alg_name, algo->alg_name, sizeof(base.algo.alg_name)); in xfrm_aead_print()
567 base.algo.alg_key_len = algo->alg_key_len; in xfrm_aead_print()
568 memcpy(base.algo.alg_key, algo->alg_key, algo->alg_key_len / 8); in xfrm_aead_print()
570 __xfrm_algo_print(&base.algo, XFRMA_ALG_AEAD, len, fp, prefix, 0); in xfrm_aead_print()
572 fprintf(fp, " %d", algo->alg_icv_len); in xfrm_aead_print()
577 static void xfrm_auth_trunc_print(struct xfrm_algo_auth *algo, int len, in xfrm_auth_trunc_print() argument
581 struct xfrm_algo algo; in xfrm_auth_trunc_print() member
582 char key[algo->alg_key_len / 8]; in xfrm_auth_trunc_print()
585 memcpy(base.algo.alg_name, algo->alg_name, sizeof(base.algo.alg_name)); in xfrm_auth_trunc_print()
586 base.algo.alg_key_len = algo->alg_key_len; in xfrm_auth_trunc_print()
587 memcpy(base.algo.alg_key, algo->alg_key, algo->alg_key_len / 8); in xfrm_auth_trunc_print()
589 __xfrm_algo_print(&base.algo, XFRMA_ALG_AUTH_TRUNC, len, fp, prefix, 0); in xfrm_auth_trunc_print()
591 fprintf(fp, " %d", algo->alg_trunc_len); in xfrm_auth_trunc_print()