| 1416 int i; |
1416 int i; |
| 1417 unsigned char Kxoripad[65]; |
1417 unsigned char Kxoripad[65]; |
| 1418 unsigned char Kxoropad[65]; |
1418 unsigned char Kxoropad[65]; |
| 1419 int pwlen; |
1419 int pwlen; |
| 1420 char * pwinput; |
1420 char * pwinput; |
| 1421 guint8 md5buf[16]; |
1421 guchar md5buf[16]; |
| 1422 |
1422 |
| 1423 cipher = gaim_ciphers_find_cipher("md5"); |
1423 cipher = gaim_ciphers_find_cipher("md5"); |
| 1424 ctx = gaim_cipher_context_new(cipher, NULL); |
1424 ctx = gaim_cipher_context_new(cipher, NULL); |
| 1425 |
1425 |
| 1426 pwinput=(char *)passwd; |
1426 pwinput=(char *)passwd; |
| 1427 pwlen=strlen(passwd); |
1427 pwlen=strlen(passwd); |
| 1428 if (pwlen>64) { |
1428 if (pwlen>64) { |
| 1429 gaim_cipher_context_append(ctx, (const guint8 *)passwd, strlen(passwd)); |
1429 gaim_cipher_context_append(ctx, (const guchar *)passwd, strlen(passwd)); |
| 1430 gaim_cipher_context_digest(ctx, sizeof(md5buf), md5buf, NULL); |
1430 gaim_cipher_context_digest(ctx, sizeof(md5buf), md5buf, NULL); |
| 1431 pwinput=(char *)md5buf; |
1431 pwinput=(char *)md5buf; |
| 1432 pwlen=16; |
1432 pwlen=16; |
| 1433 } |
1433 } |
| 1434 |
1434 |