removed old code
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@1276 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -47,34 +47,3 @@ krb5_build_authenticator (krb5_context context,
|
||||
free (auth);
|
||||
return ret;
|
||||
}
|
||||
#if 0
|
||||
|
||||
/*
|
||||
len = encode_Authenticator(buf + sizeof(buf) - 9,
|
||||
sizeof(buf) - 8 - 12,
|
||||
auth);
|
||||
|
||||
*/
|
||||
|
||||
|
||||
p = buf + sizeof(buf) - 8 - len;
|
||||
|
||||
p -= 12;
|
||||
len += 12;
|
||||
len = (len + 7) & ~7;
|
||||
crc_init_table ();
|
||||
crc = crc_update(p, len, 0);
|
||||
#if 0
|
||||
memcpy(p + 8, &crc, 4);
|
||||
#endif
|
||||
p[8] = crc & 0xff;
|
||||
p[9] = (crc >> 8) & 0xff;
|
||||
p[10] = (crc >> 16) & 0xff;
|
||||
p[11] = (crc >> 24) & 0xff;
|
||||
result->length = len;
|
||||
result->data = malloc(len);
|
||||
memcpy(result->data, p, len);
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@@ -52,35 +52,6 @@ decrypt_tkt (krb5_context context,
|
||||
return ASN1_PARSE_ERROR;
|
||||
return 0;
|
||||
}
|
||||
#if 0
|
||||
|
||||
(unsigned char*)buf + 12, len - 12, &dec_rep->part2);
|
||||
free (buf);
|
||||
if (i < 0)
|
||||
return ASN1_PARSE_ERROR;
|
||||
return 0;
|
||||
|
||||
|
||||
|
||||
des_set_key (key->contents.data, sched);
|
||||
buf = malloc (len);
|
||||
if (buf == NULL)
|
||||
return ENOMEM;
|
||||
des_cbc_encrypt ((des_cblock *)dec_rep->part1.enc_part.cipher.data,
|
||||
(des_cblock *)buf,
|
||||
len,
|
||||
sched,
|
||||
key->contents.data,
|
||||
DES_DECRYPT);
|
||||
/* XXX: Check CRC */
|
||||
|
||||
i = decode_EncTGSRepPart((unsigned char*)buf + 12, len - 12, &dec_rep->part2);
|
||||
free (buf);
|
||||
if (i < 0)
|
||||
return ASN1_PARSE_ERROR;
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
*
|
||||
|
@@ -31,21 +31,6 @@ krb5_mk_rep(krb5_context context,
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
#if 0
|
||||
len += 12; /* XXX */
|
||||
ap.enc_part.cipher.length = len;
|
||||
ap.enc_part.cipher.data = malloc(len);
|
||||
memcpy(ap.enc_part.cipher.data, buf +sizeof(buf) - len, len);
|
||||
|
||||
memcpy(&key, (*auth_context)->key.contents.data, sizeof(key));
|
||||
des_set_key (&key, schedule);
|
||||
|
||||
des_cbc_encrypt (ap.enc_part.cipher.data,
|
||||
ap.enc_part.cipher.data,
|
||||
ap.enc_part.cipher.length,
|
||||
schedule, &key, DES_ENCRYPT);
|
||||
#endif
|
||||
|
||||
len = encode_AP_REP (buf + sizeof(buf) - 1,
|
||||
sizeof(buf), &ap);
|
||||
free (ap.enc_part.cipher.data);
|
||||
|
Reference in New Issue
Block a user