#include "module.h"
#include <string.h>
Go to the source code of this file.
Data Structures | |
| struct | MD5_CTX |
Defines | |
| #define | F(x, y, z) (((x) & (y)) | ((~x) & (z))) |
| #define | FF(a, b, c, d, x, s, ac) |
| #define | G(x, y, z) (((x) & (z)) | ((y) & (~z))) |
| #define | GG(a, b, c, d, x, s, ac) |
| #define | H(x, y, z) ((x) ^ (y) ^ (z)) |
| #define | HH(a, b, c, d, x, s, ac) |
| #define | II(a, b, c, d, x, s, ac) |
| #define | MD5_I(x, y, z) ((y) ^ ((x) | (~z))) |
| #define | ROTATE_LEFT(x, n) (((x) << (n)) | ((x) >> (32-(n)))) |
| #define | S11 7 |
| #define | S12 12 |
| #define | S13 17 |
| #define | S14 22 |
| #define | S21 5 |
| #define | S22 9 |
| #define | S23 14 |
| #define | S24 20 |
| #define | S31 4 |
| #define | S32 11 |
| #define | S33 16 |
| #define | S34 23 |
| #define | S41 6 |
| #define | S42 10 |
| #define | S43 15 |
| #define | S44 21 |
| #define | XTOI(c) ((c)>9 ? (c)-'A'+10 : (c)-'0') |
Typedefs | |
| typedef void * | POINTER |
| typedef unsigned int | UINT4 |
Functions | |
| void | AnopeFini (void) |
| int | AnopeInit (int argc, char **argv) |
| void | binary_to_hex (unsigned char *bin, char *hex, int length) |
| int | old_check_password (const char *plaintext, const char *password) |
| int | old_decrypt (const char *src, char *dest, int size) |
| int | old_encrypt (const char *src, int len, char *dest, int size) |
| int | old_encrypt_check_len (int passlen, int bufsize) |
| int | old_encrypt_in_place (char *buf, int size) |
| #define FF | ( | a, | |||
| b, | |||||
| c, | |||||
| d, | |||||
| x, | |||||
| s, | |||||
| ac | ) |
Value:
{ \
(a) += F ((b), (c), (d)) + (x) + (UINT4)(ac); \
(a) = ROTATE_LEFT ((a), (s)); \
(a) += (b); \
}
| #define GG | ( | a, | |||
| b, | |||||
| c, | |||||
| d, | |||||
| x, | |||||
| s, | |||||
| ac | ) |
Value:
{ \
(a) += G ((b), (c), (d)) + (x) + (UINT4)(ac); \
(a) = ROTATE_LEFT ((a), (s)); \
(a) += (b); \
}
| #define HH | ( | a, | |||
| b, | |||||
| c, | |||||
| d, | |||||
| x, | |||||
| s, | |||||
| ac | ) |
Value:
{ \
(a) += H ((b), (c), (d)) + (x) + (UINT4)(ac); \
(a) = ROTATE_LEFT ((a), (s)); \
(a) += (b); \
}
| #define II | ( | a, | |||
| b, | |||||
| c, | |||||
| d, | |||||
| x, | |||||
| s, | |||||
| ac | ) |
Value:
{ \
(a) += MD5_I ((b), (c), (d)) + (x) + (UINT4)(ac); \
(a) = ROTATE_LEFT ((a), (s)); \
(a) += (b); \
}
| #define ROTATE_LEFT | ( | x, | |||
| n | ) | (((x) << (n)) | ((x) >> (32-(n)))) |
| void AnopeFini | ( | void | ) |
Definition at line 442 of file enc_old.c.
References encmodule_check_password(), encmodule_decrypt(), encmodule_encrypt(), encmodule_encrypt_check_len(), and encmodule_encrypt_in_place().
| int AnopeInit | ( | int | argc, | |
| char ** | argv | |||
| ) |
Definition at line 427 of file enc_old.c.
References encmodule_check_password(), encmodule_decrypt(), encmodule_encrypt(), encmodule_encrypt_check_len(), encmodule_encrypt_in_place(), ENCRYPTION, MOD_CONT, moduleAddAuthor(), moduleAddVersion(), moduleSetType(), old_check_password(), old_decrypt(), old_encrypt(), old_encrypt_check_len(), and old_encrypt_in_place().
| void binary_to_hex | ( | unsigned char * | bin, | |
| char * | hex, | |||
| int | length | |||
| ) |
| int old_check_password | ( | const char * | plaintext, | |
| const char * | password | |||
| ) |
Definition at line 410 of file enc_old.c.
References BUFSIZE, and old_encrypt().
Referenced by AnopeInit().
| int old_decrypt | ( | const char * | src, | |
| char * | dest, | |||
| int | size | |||
| ) |
| int old_encrypt | ( | const char * | src, | |
| int | len, | |||
| char * | dest, | |||
| int | size | |||
| ) |
Definition at line 362 of file enc_old.c.
References alog(), binary_to_hex(), debug, MD5Final(), MD5Init(), MD5Update(), and XTOI.
Referenced by AnopeInit(), old_check_password(), and old_encrypt_in_place().
| int old_encrypt_check_len | ( | int | passlen, | |
| int | bufsize | |||
| ) |
| int old_encrypt_in_place | ( | char * | buf, | |
| int | size | |||
| ) |
1.5.1-20070107