Lines Matching refs:skck
55 struct skck { struct
75 #define SKCK_LEN(keylen) ALIGN8(sizeof (struct skck) + KEYLEN(keylen))
863 struct skck *skck; in cache_insert_ch() local
873 if (common.deskeyarray_len > sizeof (skck->common)/sizeof (des_block) || in cache_insert_ch()
893 skck = MOVE_ADDR(&(cd->public), DHKEYSIZE(pk)); in cache_insert_ch()
895 skck->common[i] = common.deskeyarray_val[i]; in cache_insert_ch()
897 skck->verifier = key; in cache_insert_ch()
898 memcpy(&(skck->secret), sk, DHKEYSIZE(sk)); in cache_insert_ch()
902 err = cbc_crypt(key.c, (char *)skck, SKCK_LEN(newch->keylen), in cache_insert_ch()
927 struct skck *skck, *skck_cd; in copy_cl_item() local
937 if ((skck = malloc(SKCK_LEN(ch->keylen))) == 0) { in copy_cl_item()
944 memcpy(skck, skck_cd, SKCK_LEN(ch->keylen)); in copy_cl_item()
946 err = cbc_crypt(key.c, (char *)skck, SKCK_LEN(ch->keylen), in copy_cl_item()
950 free(skck); in copy_cl_item()
953 if (memcmp(key.c, skck->verifier.c, sizeof (skck->verifier.c)) != 0) { in copy_cl_item()
955 free(skck); in copy_cl_item()
972 bin2hex(skck->secret.key, (u_char *)cl->secret->keybuf3_val, in copy_cl_item()
973 skck->secret.length); in copy_cl_item()
974 cl->secret->keybuf3_len = skck->secret.length*2+1; in copy_cl_item()
975 cl->deskey.deskeyarray_len = sizeof (skck->common)/sizeof (des_block); in copy_cl_item()
977 cl->deskey.deskeyarray_val[i] = skck->common[i]; in copy_cl_item()
983 free(skck); in copy_cl_item()