librz/hash: add descriptions to all crypto & hash plugins (#5194)
This commit is contained in:
parent
0eb6c909c2
commit
181c74f4f2
49 changed files with 626 additions and 2742 deletions
|
|
@ -8,6 +8,7 @@ static RzCmdStatus core_crypto_plugin_print(RzCmdStateOutput *state, const RzCry
|
|||
const char *name = rz_str_get(plugin->name);
|
||||
const char *license = rz_str_get(plugin->license);
|
||||
const char *author = rz_str_get(plugin->author);
|
||||
const char *description = rz_str_get(plugin->description);
|
||||
|
||||
PJ *pj = state->d.pj;
|
||||
switch (state->mode) {
|
||||
|
|
@ -19,13 +20,14 @@ static RzCmdStatus core_crypto_plugin_print(RzCmdStateOutput *state, const RzCry
|
|||
pj_ks(pj, "name", name);
|
||||
pj_ks(pj, "license", license);
|
||||
pj_ks(pj, "author", author);
|
||||
pj_ks(pj, "description", description);
|
||||
pj_end(pj);
|
||||
break;
|
||||
case RZ_OUTPUT_MODE_STANDARD:
|
||||
rz_cons_printf("%-14s %-10s %s\n", name, license, author);
|
||||
rz_cons_printf("%-14s %-10s %-24s %s\n", name, license, author, description);
|
||||
break;
|
||||
case RZ_OUTPUT_MODE_TABLE:
|
||||
rz_table_add_rowf(state->d.t, "sss", name, license, author);
|
||||
rz_table_add_rowf(state->d.t, "ssss", name, license, author, description);
|
||||
break;
|
||||
default:
|
||||
rz_warn_if_reached();
|
||||
|
|
@ -38,7 +40,7 @@ RZ_API RzCmdStatus rz_core_crypto_plugins_print(RzCrypto *cry, RzCmdStateOutput
|
|||
rz_return_val_if_fail(cry, RZ_CMD_STATUS_ERROR);
|
||||
|
||||
rz_cmd_state_output_array_start(state);
|
||||
rz_cmd_state_output_set_columnsf(state, "sss", "algorithm", "license", "author");
|
||||
rz_cmd_state_output_set_columnsf(state, "ssss", "algorithm", "license", "author", "description");
|
||||
|
||||
RzIterator *iter = ht_sp_as_iter(cry->plugins);
|
||||
RzList *plugin_list = rz_list_new_from_iterator(iter);
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ static RzCmdStatus core_hash_plugin_print(RzCmdStateOutput *state, const RzHashP
|
|||
const char *name = rz_str_get(plugin->name);
|
||||
const char *license = rz_str_get(plugin->license);
|
||||
const char *author = rz_str_get(plugin->author);
|
||||
const char *description = rz_str_get(plugin->description);
|
||||
|
||||
PJ *pj = state->d.pj;
|
||||
switch (state->mode) {
|
||||
|
|
@ -18,13 +19,14 @@ static RzCmdStatus core_hash_plugin_print(RzCmdStateOutput *state, const RzHashP
|
|||
pj_ks(pj, "name", name);
|
||||
pj_ks(pj, "license", license);
|
||||
pj_ks(pj, "author", author);
|
||||
pj_ks(pj, "description", description);
|
||||
pj_end(pj);
|
||||
break;
|
||||
case RZ_OUTPUT_MODE_STANDARD:
|
||||
rz_cons_printf("%-14s %-10s %s\n", name, license, author);
|
||||
rz_cons_printf("%-14s %-10s %-30s %s\n", name, license, author, description);
|
||||
break;
|
||||
case RZ_OUTPUT_MODE_TABLE:
|
||||
rz_table_add_rowf(state->d.t, "sss", name, license, author);
|
||||
rz_table_add_rowf(state->d.t, "ssss", name, license, author, description);
|
||||
break;
|
||||
default:
|
||||
rz_warn_if_reached();
|
||||
|
|
@ -42,10 +44,10 @@ RZ_API RzCmdStatus rz_core_hash_plugins_print(RZ_NONNULL RZ_BORROW RzHash *hash,
|
|||
rz_iterator_free(iter);
|
||||
return RZ_CMD_STATUS_ERROR;
|
||||
}
|
||||
rz_list_sort(plugin_list, (RzListComparator)rz_crypto_plugin_cmp, NULL);
|
||||
rz_list_sort(plugin_list, (RzListComparator)rz_hash_plugin_cmp, NULL);
|
||||
|
||||
rz_cmd_state_output_array_start(state);
|
||||
rz_cmd_state_output_set_columnsf(state, "sss", "algorithm", "license", "author");
|
||||
rz_cmd_state_output_set_columnsf(state, "ssss", "algorithm", "license", "author", "description");
|
||||
|
||||
RzCmdStatus status = RZ_CMD_STATUS_OK;
|
||||
RzListIter *it;
|
||||
|
|
|
|||
|
|
@ -23991,7 +23991,7 @@ RZ_IPI void rzshell_cmddescs_init(RzCore *core) {
|
|||
|
||||
RzCmdDesc *cmd_print_default_cd = rz_cmd_desc_group_new(core->rcmd, cmd_print_cd, "ph", rz_cmd_print_hash_cfg_handler, &cmd_print_hash_cfg_help, &cmd_print_default_help);
|
||||
rz_warn_if_fail(cmd_print_default_cd);
|
||||
RzCmdDesc *cmd_print_hash_cfg_algo_list_cd = rz_cmd_desc_argv_state_new(core->rcmd, cmd_print_default_cd, "phl", RZ_OUTPUT_MODE_STANDARD | RZ_OUTPUT_MODE_RIZIN | RZ_OUTPUT_MODE_JSON | RZ_OUTPUT_MODE_QUIET, rz_cmd_print_hash_cfg_algo_list_handler, &cmd_print_hash_cfg_algo_list_help);
|
||||
RzCmdDesc *cmd_print_hash_cfg_algo_list_cd = rz_cmd_desc_argv_state_new(core->rcmd, cmd_print_default_cd, "phl", RZ_OUTPUT_MODE_STANDARD | RZ_OUTPUT_MODE_TABLE | RZ_OUTPUT_MODE_RIZIN | RZ_OUTPUT_MODE_JSON | RZ_OUTPUT_MODE_QUIET, rz_cmd_print_hash_cfg_algo_list_handler, &cmd_print_hash_cfg_algo_list_help);
|
||||
rz_warn_if_fail(cmd_print_hash_cfg_algo_list_cd);
|
||||
|
||||
RzCmdDesc *pi_cd = rz_cmd_desc_group_new(core->rcmd, cmd_print_cd, "pi", rz_print_instr_handler, &print_instr_help, &pi_help);
|
||||
|
|
|
|||
|
|
@ -766,6 +766,7 @@ commands:
|
|||
type: RZ_CMD_DESC_TYPE_ARGV_STATE
|
||||
modes:
|
||||
- RZ_OUTPUT_MODE_STANDARD
|
||||
- RZ_OUTPUT_MODE_TABLE
|
||||
- RZ_OUTPUT_MODE_RIZIN
|
||||
- RZ_OUTPUT_MODE_JSON
|
||||
- RZ_OUTPUT_MODE_QUIET
|
||||
|
|
|
|||
|
|
@ -162,6 +162,7 @@ RzCryptoPlugin rz_crypto_plugin_aes = {
|
|||
.name = "aes-ecb",
|
||||
.author = "Nettle project,pancake",
|
||||
.license = "LGPL3",
|
||||
.description = "AES symmetric-key block cipher (ECB block mode)",
|
||||
.set_key = aes_set_key,
|
||||
.get_key_size = aes_get_key_size,
|
||||
.use = aes_use,
|
||||
|
|
|
|||
|
|
@ -189,6 +189,7 @@ RzCryptoPlugin rz_crypto_plugin_aes_cbc = {
|
|||
.name = "aes-cbc",
|
||||
.author = "rakholiyajenish.07",
|
||||
.license = "LGPL-3",
|
||||
.description = "AES symmetric-key block cipher (CBC block mode)",
|
||||
.set_key = aes_cbc_set_key,
|
||||
.get_key_size = aes_cbc_get_key_size,
|
||||
.set_iv = aes_cbc_set_iv,
|
||||
|
|
|
|||
|
|
@ -61,6 +61,7 @@ RzCryptoPlugin rz_crypto_plugin_base64 = {
|
|||
.name = "base64",
|
||||
.author = "rakholiyajenish.07",
|
||||
.license = "LGPL-3",
|
||||
.description = "Base64 encoder/decoder",
|
||||
.set_key = base64_set_key,
|
||||
.get_key_size = base64_get_key_size,
|
||||
.use = base64_use,
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ RzCryptoPlugin rz_crypto_plugin_base91 = {
|
|||
.name = "base91",
|
||||
.author = "rakholiyajenish.07",
|
||||
.license = "LGPL-3",
|
||||
.description = "Base91 encoder/decoder",
|
||||
.set_key = base91_set_key,
|
||||
.get_key_size = base91_get_key_size,
|
||||
.use = base91_use,
|
||||
|
|
|
|||
|
|
@ -349,6 +349,7 @@ RzCryptoPlugin rz_crypto_plugin_blowfish = {
|
|||
.name = "blowfish",
|
||||
.license = "LGPL3",
|
||||
.author = "kishorbhat",
|
||||
.description = "Blowfish symmetric-key block cipher",
|
||||
.set_key = blowfish_set_key,
|
||||
.get_key_size = blowfish_get_key_size,
|
||||
.use = blowfish_use,
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -184,6 +184,7 @@ RzCryptoPlugin rz_crypto_plugin_des = {
|
|||
.name = "des-ecb",
|
||||
.author = "deroad",
|
||||
.license = "LGPL-3",
|
||||
.description = "DES symmetric-key block cipher (ECB block mode)",
|
||||
.set_key = des_set_key,
|
||||
.get_key_size = des_get_key_size,
|
||||
.use = des_use,
|
||||
|
|
|
|||
|
|
@ -43,6 +43,7 @@ RzCryptoPlugin rz_crypto_plugin_punycode = {
|
|||
.name = "punycode",
|
||||
.author = "pancake",
|
||||
.license = "LGPL-3",
|
||||
.description = "Punycode encoder/decoder",
|
||||
.set_key = punycode_set_key,
|
||||
.get_key_size = punycode_get_key_size,
|
||||
.use = punycode_use,
|
||||
|
|
|
|||
|
|
@ -258,6 +258,7 @@ RzCryptoPlugin rz_crypto_plugin_rc2 = {
|
|||
.name = "rc2",
|
||||
.author = "lionaneesh",
|
||||
.license = "LGPL-3",
|
||||
.description = "RC2 symmetric-key block cipher",
|
||||
.set_key = rc2_set_key,
|
||||
.get_key_size = rc2_get_key_size,
|
||||
.use = rc2_use,
|
||||
|
|
|
|||
|
|
@ -127,6 +127,7 @@ RzCryptoPlugin rz_crypto_plugin_rc4 = {
|
|||
.name = "rc4",
|
||||
.author = "pancake",
|
||||
.license = "LGPL-3",
|
||||
.description = "RC4 symmetric-key block cipher",
|
||||
.set_key = rc4_set_key,
|
||||
.get_key_size = rc4_get_key_size,
|
||||
.use = rc4_use,
|
||||
|
|
|
|||
|
|
@ -220,6 +220,7 @@ RzCryptoPlugin rz_crypto_plugin_rc6 = {
|
|||
.name = "rc6",
|
||||
.author = "rakholiyajenish.07",
|
||||
.license = "LGPL-3",
|
||||
.description = "RC6 symmetric-key block cipher",
|
||||
.set_key = rc6_set_key,
|
||||
.get_key_size = rc6_get_key_size,
|
||||
.use = rc6_use,
|
||||
|
|
|
|||
|
|
@ -5,17 +5,15 @@
|
|||
#include <rz_crypto.h>
|
||||
#include <rz_util.h>
|
||||
|
||||
#define NAME "rol"
|
||||
|
||||
enum { MAX_rol_KEY_SIZE = 32768 };
|
||||
#define MAX_ROL_KEY_SIZE 32768
|
||||
|
||||
struct rol_state {
|
||||
ut8 key[MAX_rol_KEY_SIZE];
|
||||
ut8 key[MAX_ROL_KEY_SIZE];
|
||||
int key_size;
|
||||
};
|
||||
|
||||
static bool rol_init_state(struct rol_state *const state, const ut8 *key, int keylen) {
|
||||
if (!state || !key || keylen < 1 || keylen > MAX_rol_KEY_SIZE) {
|
||||
if (!state || !key || keylen < 1 || keylen > MAX_ROL_KEY_SIZE) {
|
||||
return false;
|
||||
}
|
||||
int i;
|
||||
|
|
@ -51,7 +49,7 @@ static int rol_get_key_size(RzCrypto *cry) {
|
|||
}
|
||||
|
||||
static bool rol_use(const char *algo) {
|
||||
return !strcmp(algo, NAME);
|
||||
return !strcmp(algo, "rol");
|
||||
}
|
||||
|
||||
static bool update(RzCrypto *cry, const ut8 *buf, int len) {
|
||||
|
|
@ -87,9 +85,10 @@ static bool rol_fini(RzCrypto *cry) {
|
|||
}
|
||||
|
||||
RzCryptoPlugin rz_crypto_plugin_rol = {
|
||||
.name = NAME,
|
||||
.name = "rol",
|
||||
.author = "pancake",
|
||||
.license = "LGPL-3",
|
||||
.description = "Rotate Left symmetric-key block cipher",
|
||||
.set_key = rol_set_key,
|
||||
.get_key_size = rol_get_key_size,
|
||||
.use = rol_use,
|
||||
|
|
|
|||
|
|
@ -5,17 +5,15 @@
|
|||
#include <rz_crypto.h>
|
||||
#include <rz_util.h>
|
||||
|
||||
#define NAME "ror"
|
||||
|
||||
enum { MAX_ror_KEY_SIZE = 32768 };
|
||||
#define MAX_ROR_KEY_SIZE 32768
|
||||
|
||||
struct ror_state {
|
||||
ut8 key[MAX_ror_KEY_SIZE];
|
||||
ut8 key[MAX_ROR_KEY_SIZE];
|
||||
int key_size;
|
||||
};
|
||||
|
||||
static bool ror_init_state(struct ror_state *const state, const ut8 *key, int keylen) {
|
||||
if (!state || !key || keylen < 1 || keylen > MAX_ror_KEY_SIZE) {
|
||||
if (!state || !key || keylen < 1 || keylen > MAX_ROR_KEY_SIZE) {
|
||||
return false;
|
||||
}
|
||||
int i;
|
||||
|
|
@ -51,7 +49,7 @@ static int ror_get_key_size(RzCrypto *cry) {
|
|||
}
|
||||
|
||||
static bool ror_use(const char *algo) {
|
||||
return !strcmp(algo, NAME);
|
||||
return !strcmp(algo, "ror");
|
||||
}
|
||||
|
||||
static bool update(RzCrypto *cry, const ut8 *buf, int len) {
|
||||
|
|
@ -87,9 +85,10 @@ static bool ror_fini(RzCrypto *cry) {
|
|||
}
|
||||
|
||||
RzCryptoPlugin rz_crypto_plugin_ror = {
|
||||
.name = NAME,
|
||||
.name = "ror",
|
||||
.author = "pancake",
|
||||
.license = "LGPL-3",
|
||||
.description = "Rotate Right symmetric-key block cipher",
|
||||
.set_key = ror_set_key,
|
||||
.get_key_size = ror_get_key_size,
|
||||
.use = ror_use,
|
||||
|
|
|
|||
|
|
@ -116,6 +116,7 @@ RzCryptoPlugin rz_crypto_plugin_rot = {
|
|||
.name = "rot",
|
||||
.author = "pancake",
|
||||
.license = "LGPL-3",
|
||||
.description = "Caesar symmetric-key cipher",
|
||||
.set_key = rot_set_key,
|
||||
.get_key_size = rot_get_key_size,
|
||||
.use = rot_use,
|
||||
|
|
|
|||
|
|
@ -125,6 +125,7 @@ RzCryptoPlugin rz_crypto_plugin_serpent = {
|
|||
.name = "serpent-ecb",
|
||||
.author = "NicsTr",
|
||||
.license = "LGPL-3",
|
||||
.description = "Serpent symmetric-key block cipher (ECB block mode)",
|
||||
.set_key = serpent_set_key,
|
||||
.get_key_size = serpent_get_key_size,
|
||||
.use = serpent_use,
|
||||
|
|
|
|||
|
|
@ -244,6 +244,7 @@ RzCryptoPlugin rz_crypto_plugin_sm4_ecb = {
|
|||
.name = "sm4-ecb",
|
||||
.author = "0xSh4dy",
|
||||
.license = "LGPL-3",
|
||||
.description = "ShangMi 4 symmetric-key block cipher (ECB block mode)",
|
||||
.set_key = sm4_ecb_set_key,
|
||||
.get_key_size = sm4_ecb_get_key_size,
|
||||
.use = sm4_use,
|
||||
|
|
|
|||
|
|
@ -91,6 +91,7 @@ RzCryptoPlugin rz_crypto_plugin_xor = {
|
|||
.name = "xor",
|
||||
.author = "pancake",
|
||||
.license = "LGPL-3",
|
||||
.description = "XOR symmetric-key block cipher",
|
||||
.set_key = xor_set_key,
|
||||
.get_key_size = xor_get_key_size,
|
||||
.use = xor_use,
|
||||
|
|
|
|||
|
|
@ -58,57 +58,57 @@ void crc_final(RzCrc *ctx, utcrc *r) {
|
|||
|
||||
/* NOTE: Run `rz-hash -a <algo> -s 123456789` to test CRC. */
|
||||
RzCrc crc_presets[] = {
|
||||
CRC_PRESET(0x00, 8, 0, 0x07, 0x00), // CRC-8-SMBUS, test vector for "1234567892: f4
|
||||
CRC_PRESET(0xFF, 8, 0, 0x9B, 0x00), // CRC-8/CDMA2000, test vector for "123456789": 0xda
|
||||
CRC_PRESET(0x00, 8, 1, 0x39, 0x00), // CRC-8/DARC, test vector for "123456789": 0x15
|
||||
CRC_PRESET(0x00, 8, 0, 0xD5, 0x00), // CRC-8/DVB-S2, test vector for "123456789": 0xbc
|
||||
CRC_PRESET(0xFF, 8, 1, 0x1D, 0x00), // CRC-8/EBU, test vector for "123456789": 0x97
|
||||
CRC_PRESET(0xFD, 8, 0, 0x1D, 0x00), // CRC-8/I-CODE, test vector for "123456789": 0x7e
|
||||
CRC_PRESET(0x00, 8, 0, 0x07, 0x55), // CRC-8/ITU, test vector for "123456789": 0xa1
|
||||
CRC_PRESET(0x00, 8, 1, 0x31, 0x00), // CRC-8/MAXIM, test vector for "123456789": 0xa1
|
||||
CRC_PRESET(0xFF, 8, 1, 0x07, 0x00), // CRC-8/ROHC, test vector for "123456789": 0xd0
|
||||
CRC_PRESET(0x00, 8, 1, 0x9B, 0x00), // CRC-8/WCDMA, test vector for "123456789": 0x25
|
||||
CRC_PRESET(0x0000, 15, 0, 0x4599, 0x0000), // CRC-15-CAN, test vector for "1234567892: 059e
|
||||
CRC_PRESET(0x0000, 16, 1, 0x8005, 0x0000), // CRC-16-IBM (CRC-16/ARC), test vector for "1234567892: bb3d
|
||||
CRC_PRESET(0xFFFF, 16, 0, 0x1021, 0x0000), // CRC-16-CITT (CRC-16/CCITT-FALSE), test vector for "1234567892: 29b1
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x8005, 0xFFFF), // CRC-16-USB, test vector for "1234567892: b4c8
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x1021, 0xFFFF), // CRC-HDLC, test vector for "1234567892: 906e
|
||||
CRC_PRESET(0x1D0F, 16, 0, 0x1021, 0x0000), // CRC-16/AUG-CCITT, test vector for "123456789": 0xe5cc
|
||||
CRC_PRESET(0x0000, 16, 0, 0x8005, 0x0000), // CRC-16/BUYPASS, test vector for "123456789": 0xfee8
|
||||
CRC_PRESET(0xFFFF, 16, 0, 0xC867, 0x0000), // CRC-16/CDMA2000, test vector for "123456789": 0x4c06
|
||||
CRC_PRESET(0x800D, 16, 0, 0x8005, 0x0000), // CRC-16/DDS110, test vector for "123456789": 0x9ecf
|
||||
CRC_PRESET(0x0000, 16, 0, 0x0589, 0x0001), // CRC-16/DECT-R, test vector for "123456789": 0x007e
|
||||
CRC_PRESET(0x0000, 16, 0, 0x0589, 0x0000), // CRC-16/DECT-X, test vector for "123456789": 0x007f
|
||||
CRC_PRESET(0x0000, 16, 1, 0x3D65, 0xFFFF), // CRC-16/DNP, test vector for "123456789": 0xea82
|
||||
CRC_PRESET(0x0000, 16, 0, 0x3D65, 0xFFFF), // CRC-16/EN-13757, test vector for "123456789": 0xc2b7
|
||||
CRC_PRESET(0xFFFF, 16, 0, 0x1021, 0xFFFF), // CRC-16/GENIBUS, test vector for "123456789": 0xd64e
|
||||
CRC_PRESET(0x0000, 16, 1, 0x8005, 0xFFFF), // CRC-16/MAXIM, test vector for "123456789": 0x44c2
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x1021, 0x0000), // CRC-16/MCRF4XX, test vector for "123456789": 0x6f91
|
||||
CRC_PRESET(0xB2AA, 16, 1, 0x1021, 0x0000), // CRC-16/RIELLO, test vector for "123456789": 0x63d0
|
||||
CRC_PRESET(0x0000, 16, 0, 0x8BB7, 0x0000), // CRC-16/T10-DIF, test vector for "123456789": 0xd0db
|
||||
CRC_PRESET(0x0000, 16, 0, 0xA097, 0x0000), // CRC-16/TELEDISK, test vector for "123456789": 0x0fb3
|
||||
CRC_PRESET(0x89EC, 16, 1, 0x1021, 0x0000), // CRC-16/TMS37157, test vector for "123456789": 0x26b1
|
||||
CRC_PRESET(0xC6C6, 16, 1, 0x1021, 0x0000), // CRC-A, test vector for "123456789": 0xbf05
|
||||
CRC_PRESET(0x0000, 16, 1, 0x1021, 0x0000), // CRC-16/KERMIT, test vector for "123456789": 0x2189
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x8005, 0x0000), // CRC-16/MODBUS, test vector for "123456789": 0x4b37
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x1021, 0xFFFF), // CRC-16/X-25, test vector for "123456789": 0x906e
|
||||
CRC_PRESET(0x0000, 16, 0, 0x1021, 0x0000), // CRC-16/XMODEM, test vector for "123456789": 0x31c3
|
||||
CRC_PRESET(0xB704CE, 24, 0, 0x864CFB, 0x000000), // CRC-24, test vector for "1234567892: 21cf02
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0x04C11DB7, 0xFFFFFFFF), // CRC-32, test vector for "1234567892: cbf43926
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x80000011, 0x00000000), // CRC-32-ECMA-267 (EDC for DVD sectors), test vector for "1234567892: b27ce117
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0x1EDC6F41, 0xFFFFFFFF), // CRC-32C, test vector for "1234567892: e3069283
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 0, 0x04C11DB7, 0xFFFFFFFF), // CRC-32/BZIP2, test vector for "123456789": 0xfc891918
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0xA833982B, 0xFFFFFFFF), // CRC-32D, test vector for "123456789": 0x87315576
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 0, 0x04C11DB7, 0x00000000), // CRC-32/MPEG2, test vector for "123456789": 0x0376e6e7
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x04C11DB7, 0xFFFFFFFF), // CRC-32/POSIX, test vector for "123456789": 0x765e7680
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x814141AB, 0x00000000), // CRC-32Q, test vector for "123456789": 0x3010bf7f
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0x04C11DB7, 0x00000000), // CRC-32/JAMCRC, test vector for "123456789": 0x340bc6d9
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x000000AF, 0x00000000), // CRC-32/XFER, test vector for "123456789": 0xbd0be338
|
||||
CRC_PRESET(0x0000000000000000, 64, 0, 0x42F0E1EBA9EA3693, 0x0000000000000000), // CRC-64, check: 0x6c40df5f0b497347
|
||||
CRC_PRESET(0x0000000000000000, 64, 0, 0x42F0E1EBA9EA3693, 0x0000000000000000), // CRC-64/ECMA-182, check: 0x6c40df5f0b497347
|
||||
CRC_PRESET(0xFFFFFFFFFFFFFFFF, 64, 0, 0x42F0E1EBA9EA3693, 0xFFFFFFFFFFFFFFFF), // CRC-64/WE, check: 0x62ec59e3f1a4f00a
|
||||
CRC_PRESET(0xFFFFFFFFFFFFFFFF, 64, 1, 0x42F0E1EBA9EA3693, 0xFFFFFFFFFFFFFFFF), // CRC-64/XZ, check: 0x995dc9bbdf1939fa
|
||||
CRC_PRESET(0xFFFFFFFFFFFFFFFF, 64, 1, 0x000000000000001b, 0xFFFFFFFFFFFFFFFF), // CRC-64/ISO, check: 0xb90956c775a41001
|
||||
CRC_PRESET(0x00, 8, 0, 0x07, 0x00), // CRC-8-SMBUS, "123456789" -> 0xf4
|
||||
CRC_PRESET(0xFF, 8, 0, 0x9B, 0x00), // CRC-8/CDMA2000, "123456789" -> 0xda
|
||||
CRC_PRESET(0x00, 8, 1, 0x39, 0x00), // CRC-8/DARC, "123456789" -> 0x15
|
||||
CRC_PRESET(0x00, 8, 0, 0xD5, 0x00), // CRC-8/DVB-S2, "123456789" -> 0xbc
|
||||
CRC_PRESET(0xFF, 8, 1, 0x1D, 0x00), // CRC-8/EBU, "123456789" -> 0x97
|
||||
CRC_PRESET(0xFD, 8, 0, 0x1D, 0x00), // CRC-8/I-CODE, "123456789" -> 0x7e
|
||||
CRC_PRESET(0x00, 8, 0, 0x07, 0x55), // CRC-8/ITU, "123456789" -> 0xa1
|
||||
CRC_PRESET(0x00, 8, 1, 0x31, 0x00), // CRC-8/MAXIM, "123456789" -> 0xa1
|
||||
CRC_PRESET(0xFF, 8, 1, 0x07, 0x00), // CRC-8/ROHC, "123456789" -> 0xd0
|
||||
CRC_PRESET(0x00, 8, 1, 0x9B, 0x00), // CRC-8/WCDMA, "123456789" -> 0x25
|
||||
CRC_PRESET(0x0000, 15, 0, 0x4599, 0x0000), // CRC-15-CAN, "123456789" -> 0x059e
|
||||
CRC_PRESET(0x0000, 16, 1, 0x8005, 0x0000), // CRC-16-IBM (CRC-16/ARC), "123456789" -> 0xbb3d
|
||||
CRC_PRESET(0xFFFF, 16, 0, 0x1021, 0x0000), // CRC-16-CITT (CRC-16/CCITT-FALSE), "123456789" -> 0x29b1
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x8005, 0xFFFF), // CRC-16-USB, "123456789" -> 0xb4c8
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x1021, 0xFFFF), // CRC-HDLC, "123456789" -> 0x906e
|
||||
CRC_PRESET(0x1D0F, 16, 0, 0x1021, 0x0000), // CRC-16/AUG-CCITT, "123456789" -> 0xe5cc
|
||||
CRC_PRESET(0x0000, 16, 0, 0x8005, 0x0000), // CRC-16/BUYPASS, "123456789" -> 0xfee8
|
||||
CRC_PRESET(0xFFFF, 16, 0, 0xC867, 0x0000), // CRC-16/CDMA2000, "123456789" -> 0x4c06
|
||||
CRC_PRESET(0x800D, 16, 0, 0x8005, 0x0000), // CRC-16/DDS110, "123456789" -> 0x9ecf
|
||||
CRC_PRESET(0x0000, 16, 0, 0x0589, 0x0001), // CRC-16/DECT-R, "123456789" -> 0x007e
|
||||
CRC_PRESET(0x0000, 16, 0, 0x0589, 0x0000), // CRC-16/DECT-X, "123456789" -> 0x007f
|
||||
CRC_PRESET(0x0000, 16, 1, 0x3D65, 0xFFFF), // CRC-16/DNP, "123456789" -> 0xea82
|
||||
CRC_PRESET(0x0000, 16, 0, 0x3D65, 0xFFFF), // CRC-16/EN-13757, "123456789" -> 0xc2b7
|
||||
CRC_PRESET(0xFFFF, 16, 0, 0x1021, 0xFFFF), // CRC-16/GENIBUS, "123456789" -> 0xd64e
|
||||
CRC_PRESET(0x0000, 16, 1, 0x8005, 0xFFFF), // CRC-16/MAXIM, "123456789" -> 0x44c2
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x1021, 0x0000), // CRC-16/MCRF4XX, "123456789" -> 0x6f91
|
||||
CRC_PRESET(0xB2AA, 16, 1, 0x1021, 0x0000), // CRC-16/RIELLO, "123456789" -> 0x63d0
|
||||
CRC_PRESET(0x0000, 16, 0, 0x8BB7, 0x0000), // CRC-16/T10-DIF, "123456789" -> 0xd0db
|
||||
CRC_PRESET(0x0000, 16, 0, 0xA097, 0x0000), // CRC-16/TELEDISK, "123456789" -> 0x0fb3
|
||||
CRC_PRESET(0x89EC, 16, 1, 0x1021, 0x0000), // CRC-16/TMS37157, "123456789" -> 0x26b1
|
||||
CRC_PRESET(0xC6C6, 16, 1, 0x1021, 0x0000), // CRC-A, "123456789" -> 0xbf05
|
||||
CRC_PRESET(0x0000, 16, 1, 0x1021, 0x0000), // CRC-16/KERMIT, "123456789" -> 0x2189
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x8005, 0x0000), // CRC-16/MODBUS, "123456789" -> 0x4b37
|
||||
CRC_PRESET(0xFFFF, 16, 1, 0x1021, 0xFFFF), // CRC-16/X-25, "123456789" -> 0x906e
|
||||
CRC_PRESET(0x0000, 16, 0, 0x1021, 0x0000), // CRC-16/XMODEM, "123456789" -> 0x31c3
|
||||
CRC_PRESET(0xB704CE, 24, 0, 0x864CFB, 0x000000), // CRC-24, "123456789" -> 0x21cf02
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0x04C11DB7, 0xFFFFFFFF), // CRC-32, "123456789" -> 0xcbf43926
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x80000011, 0x00000000), // CRC-32-ECMA-267 (EDC for DVD sectors), "123456789" -> 0xb27ce117
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0x1EDC6F41, 0xFFFFFFFF), // CRC-32C, "123456789" -> 0xe3069283
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 0, 0x04C11DB7, 0xFFFFFFFF), // CRC-32/BZIP2, "123456789" -> 0xfc891918
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0xA833982B, 0xFFFFFFFF), // CRC-32D, "123456789" -> 0x87315576
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 0, 0x04C11DB7, 0x00000000), // CRC-32/MPEG2, "123456789" -> 0x0376e6e7
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x04C11DB7, 0xFFFFFFFF), // CRC-32/POSIX, "123456789" -> 0x765e7680
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x814141AB, 0x00000000), // CRC-32Q, "123456789" -> 0x3010bf7f
|
||||
CRC_PRESET(0xFFFFFFFF, 32, 1, 0x04C11DB7, 0x00000000), // CRC-32/JAMCRC, "123456789" -> 0x340bc6d9
|
||||
CRC_PRESET(0x00000000, 32, 0, 0x000000AF, 0x00000000), // CRC-32/XFER, "123456789" -> 0xbd0be338
|
||||
CRC_PRESET(0x0000000000000000, 64, 0, 0x42F0E1EBA9EA3693, 0x0000000000000000), // CRC-64, "123456789" -> 0x6c40df5f0b497347
|
||||
CRC_PRESET(0x0000000000000000, 64, 0, 0x42F0E1EBA9EA3693, 0x0000000000000000), // CRC-64/ECMA-182, "123456789" -> 0x6c40df5f0b497347
|
||||
CRC_PRESET(0xFFFFFFFFFFFFFFFF, 64, 0, 0x42F0E1EBA9EA3693, 0xFFFFFFFFFFFFFFFF), // CRC-64/WE, "123456789" -> 0x62ec59e3f1a4f00a
|
||||
CRC_PRESET(0xFFFFFFFFFFFFFFFF, 64, 1, 0x42F0E1EBA9EA3693, 0xFFFFFFFFFFFFFFFF), // CRC-64/XZ, "123456789" -> 0x995dc9bbdf1939fa
|
||||
CRC_PRESET(0xFFFFFFFFFFFFFFFF, 64, 1, 0x000000000000001b, 0xFFFFFFFFFFFFFFFF), // CRC-64/ISO, "123456789" -> 0xb90956c775a41001
|
||||
};
|
||||
|
||||
void crc_init_preset(RzCrc *ctx, RzCrcPresets preset) {
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ hash_plugins_list = [
|
|||
'fletcher32',
|
||||
'fletcher64',
|
||||
'adler32',
|
||||
'mod255',
|
||||
'crca_crc8smbus',
|
||||
'crca_crc8cdma2000',
|
||||
'crca_crc8darc',
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_adler32 = {
|
|||
.name = "adler32",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "Adler-32 checksum",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_adler32_context_new,
|
||||
.context_free = plugin_adler32_context_free,
|
||||
|
|
|
|||
|
|
@ -62,6 +62,7 @@ RzHashPlugin rz_hash_plugin_blake3 = {
|
|||
.name = "blake3",
|
||||
.license = "CC0",
|
||||
.author = "Samuel Neves,Jack O'Connor",
|
||||
.description = "BLAKE3 cryptographic hash",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_blake3_context_new,
|
||||
.context_free = plugin_blake3_context_free,
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ static bool plugin_crca_final(void *context, ut8 *digest) {
|
|||
return true;
|
||||
}
|
||||
|
||||
#define rz_hash_plugin_crca_preset(crcalgo, preset) \
|
||||
#define rz_hash_plugin_crca_preset(crcalgo, preset, crcdesc) \
|
||||
plugin_crca_preset_context_new(crcalgo, preset); \
|
||||
plugin_crca_preset_init(crcalgo, preset); \
|
||||
plugin_crca_preset_small_block(crcalgo, preset); \
|
||||
|
|
@ -99,6 +99,7 @@ static bool plugin_crca_final(void *context, ut8 *digest) {
|
|||
.name = #crcalgo, \
|
||||
.license = "LGPL3", \
|
||||
.author = "deroad", \
|
||||
.description = crcdesc, \
|
||||
.support_hmac = false, \
|
||||
.context_new = plugin_crca_##crcalgo##_context_new, \
|
||||
.context_free = plugin_crca_context_free, \
|
||||
|
|
@ -121,58 +122,58 @@ static bool plugin_crca_final(void *context, ut8 *digest) {
|
|||
#define rz_lib_plugin_crca_preset(crcalgo)
|
||||
#endif
|
||||
|
||||
#define rz_plugin_crca_preset_definition(crcalgo, preset) \
|
||||
rz_hash_plugin_crca_preset(crcalgo, preset); \
|
||||
#define rz_plugin_crca_preset_definition(crcalgo, preset, crcdesc) \
|
||||
rz_hash_plugin_crca_preset(crcalgo, preset, crcdesc); \
|
||||
rz_lib_plugin_crca_preset(crcalgo)
|
||||
|
||||
rz_plugin_crca_preset_definition(crc8smbus, /* */ CRC_PRESET_8_SMBUS);
|
||||
rz_plugin_crca_preset_definition(crc8cdma2000, /* */ CRC_PRESET_CRC8_CDMA2000);
|
||||
rz_plugin_crca_preset_definition(crc8darc, /* */ CRC_PRESET_CRC8_DARC);
|
||||
rz_plugin_crca_preset_definition(crc8dvbs2, /* */ CRC_PRESET_CRC8_DVB_S2);
|
||||
rz_plugin_crca_preset_definition(crc8ebu, /* */ CRC_PRESET_CRC8_EBU);
|
||||
rz_plugin_crca_preset_definition(crc8icode, /* */ CRC_PRESET_CRC8_ICODE);
|
||||
rz_plugin_crca_preset_definition(crc8itu, /* */ CRC_PRESET_CRC8_ITU);
|
||||
rz_plugin_crca_preset_definition(crc8maxim, /* */ CRC_PRESET_CRC8_MAXIM);
|
||||
rz_plugin_crca_preset_definition(crc8rohc, /* */ CRC_PRESET_CRC8_ROHC);
|
||||
rz_plugin_crca_preset_definition(crc8wcdma, /* */ CRC_PRESET_CRC8_WCDMA);
|
||||
rz_plugin_crca_preset_definition(crc15can, /* */ CRC_PRESET_15_CAN);
|
||||
rz_plugin_crca_preset_definition(crc16, /* */ CRC_PRESET_16);
|
||||
rz_plugin_crca_preset_definition(crc16citt, /* */ CRC_PRESET_16_CITT);
|
||||
rz_plugin_crca_preset_definition(crc16usb, /* */ CRC_PRESET_16_USB);
|
||||
rz_plugin_crca_preset_definition(crc16hdlc, /* */ CRC_PRESET_16_HDLC);
|
||||
rz_plugin_crca_preset_definition(crc16augccitt, /**/ CRC_PRESET_CRC16_AUG_CCITT);
|
||||
rz_plugin_crca_preset_definition(crc16buypass, /* */ CRC_PRESET_CRC16_BUYPASS);
|
||||
rz_plugin_crca_preset_definition(crc16cdma2000, /**/ CRC_PRESET_CRC16_CDMA2000);
|
||||
rz_plugin_crca_preset_definition(crc16dds110, /* */ CRC_PRESET_CRC16_DDS110);
|
||||
rz_plugin_crca_preset_definition(crc16dectr, /* */ CRC_PRESET_CRC16_DECT_R);
|
||||
rz_plugin_crca_preset_definition(crc16dectx, /* */ CRC_PRESET_CRC16_DECT_X);
|
||||
rz_plugin_crca_preset_definition(crc16dnp, /* */ CRC_PRESET_CRC16_DNP);
|
||||
rz_plugin_crca_preset_definition(crc16en13757, /* */ CRC_PRESET_CRC16_EN13757);
|
||||
rz_plugin_crca_preset_definition(crc16genibus, /* */ CRC_PRESET_CRC16_GENIBUS);
|
||||
rz_plugin_crca_preset_definition(crc16maxim, /* */ CRC_PRESET_CRC16_MAXIM);
|
||||
rz_plugin_crca_preset_definition(crc16mcrf4xx, /* */ CRC_PRESET_CRC16_MCRF4XX);
|
||||
rz_plugin_crca_preset_definition(crc16riello, /* */ CRC_PRESET_CRC16_RIELLO);
|
||||
rz_plugin_crca_preset_definition(crc16t10dif, /* */ CRC_PRESET_CRC16_T10_DIF);
|
||||
rz_plugin_crca_preset_definition(crc16teledisk, /**/ CRC_PRESET_CRC16_TELEDISK);
|
||||
rz_plugin_crca_preset_definition(crc16tms37157, /**/ CRC_PRESET_CRC16_TMS37157);
|
||||
rz_plugin_crca_preset_definition(crca, /* */ CRC_PRESET_CRCA);
|
||||
rz_plugin_crca_preset_definition(crc16kermit, /* */ CRC_PRESET_CRC16_KERMIT);
|
||||
rz_plugin_crca_preset_definition(crc16modbus, /* */ CRC_PRESET_CRC16_MODBUS);
|
||||
rz_plugin_crca_preset_definition(crc16x25, /* */ CRC_PRESET_CRC16_X25);
|
||||
rz_plugin_crca_preset_definition(crc16xmodem, /* */ CRC_PRESET_CRC16_XMODEM);
|
||||
rz_plugin_crca_preset_definition(crc24, /* */ CRC_PRESET_24);
|
||||
rz_plugin_crca_preset_definition(crc32, /* */ CRC_PRESET_32);
|
||||
rz_plugin_crca_preset_definition(crc32ecma267, /* */ CRC_PRESET_32_ECMA_267);
|
||||
rz_plugin_crca_preset_definition(crc32c, /* */ CRC_PRESET_32C);
|
||||
rz_plugin_crca_preset_definition(crc32bzip2, /* */ CRC_PRESET_CRC32_BZIP2);
|
||||
rz_plugin_crca_preset_definition(crc32d, /* */ CRC_PRESET_CRC32D);
|
||||
rz_plugin_crca_preset_definition(crc32mpeg2, /* */ CRC_PRESET_CRC32_MPEG2);
|
||||
rz_plugin_crca_preset_definition(crc32posix, /* */ CRC_PRESET_CRC32_POSIX);
|
||||
rz_plugin_crca_preset_definition(crc32q, /* */ CRC_PRESET_CRC32Q);
|
||||
rz_plugin_crca_preset_definition(crc32jamcrc, /* */ CRC_PRESET_CRC32_JAMCRC);
|
||||
rz_plugin_crca_preset_definition(crc32xfer, /* */ CRC_PRESET_CRC32_XFER);
|
||||
rz_plugin_crca_preset_definition(crc64, /* */ CRC_PRESET_CRC64);
|
||||
rz_plugin_crca_preset_definition(crc64ecma182, /* */ CRC_PRESET_CRC64_ECMA182);
|
||||
rz_plugin_crca_preset_definition(crc64we, /* */ CRC_PRESET_CRC64_WE);
|
||||
rz_plugin_crca_preset_definition(crc64xz, /* */ CRC_PRESET_CRC64_XZ);
|
||||
rz_plugin_crca_preset_definition(crc64iso, /* */ CRC_PRESET_CRC64_ISO);
|
||||
rz_plugin_crca_preset_definition(crc8smbus, /* */ CRC_PRESET_8_SMBUS, "CRC-8 SMBUS checksum");
|
||||
rz_plugin_crca_preset_definition(crc8cdma2000, /* */ CRC_PRESET_CRC8_CDMA2000, "CRC-8 CDMA-2000 checksum");
|
||||
rz_plugin_crca_preset_definition(crc8darc, /* */ CRC_PRESET_CRC8_DARC, "CRC-8 DARC checksum");
|
||||
rz_plugin_crca_preset_definition(crc8dvbs2, /* */ CRC_PRESET_CRC8_DVB_S2, "CRC-8 DVB-S2 checksum");
|
||||
rz_plugin_crca_preset_definition(crc8ebu, /* */ CRC_PRESET_CRC8_EBU, "CRC-8 EBU checksum");
|
||||
rz_plugin_crca_preset_definition(crc8icode, /* */ CRC_PRESET_CRC8_ICODE, "CRC-8 I-CODE checksum");
|
||||
rz_plugin_crca_preset_definition(crc8itu, /* */ CRC_PRESET_CRC8_ITU, "CRC-8 ITU checksum");
|
||||
rz_plugin_crca_preset_definition(crc8maxim, /* */ CRC_PRESET_CRC8_MAXIM, "CRC-8 MAXIM checksum");
|
||||
rz_plugin_crca_preset_definition(crc8rohc, /* */ CRC_PRESET_CRC8_ROHC, "CRC-8 ROHC checksum");
|
||||
rz_plugin_crca_preset_definition(crc8wcdma, /* */ CRC_PRESET_CRC8_WCDMA, "CRC-8 WCDMA checksum");
|
||||
rz_plugin_crca_preset_definition(crc15can, /* */ CRC_PRESET_15_CAN, "CRC-15 CAN checksum");
|
||||
rz_plugin_crca_preset_definition(crc16, /* */ CRC_PRESET_16, "CRC-16 IBM/ARC checksum");
|
||||
rz_plugin_crca_preset_definition(crc16citt, /* */ CRC_PRESET_16_CITT, "CRC-16 CITT checksum");
|
||||
rz_plugin_crca_preset_definition(crc16usb, /* */ CRC_PRESET_16_USB, "CRC-16 USB checksum");
|
||||
rz_plugin_crca_preset_definition(crc16hdlc, /* */ CRC_PRESET_16_HDLC, "CRC-16 HDLC checksum");
|
||||
rz_plugin_crca_preset_definition(crc16augccitt, /**/ CRC_PRESET_CRC16_AUG_CCITT, "CRC-16 AUG-CCITT checksum");
|
||||
rz_plugin_crca_preset_definition(crc16buypass, /* */ CRC_PRESET_CRC16_BUYPASS, "CRC-16 BUYPASS checksum");
|
||||
rz_plugin_crca_preset_definition(crc16cdma2000, /**/ CRC_PRESET_CRC16_CDMA2000, "CRC-16 CDMA-2000 checksum");
|
||||
rz_plugin_crca_preset_definition(crc16dds110, /* */ CRC_PRESET_CRC16_DDS110, "CRC-16 DDS110 checksum");
|
||||
rz_plugin_crca_preset_definition(crc16dectr, /* */ CRC_PRESET_CRC16_DECT_R, "CRC-16 DECT-R checksum");
|
||||
rz_plugin_crca_preset_definition(crc16dectx, /* */ CRC_PRESET_CRC16_DECT_X, "CRC-16 DECT-X checksum");
|
||||
rz_plugin_crca_preset_definition(crc16dnp, /* */ CRC_PRESET_CRC16_DNP, "CRC-16 DNP checksum");
|
||||
rz_plugin_crca_preset_definition(crc16en13757, /* */ CRC_PRESET_CRC16_EN13757, "CRC-16 EN-13757 checksum");
|
||||
rz_plugin_crca_preset_definition(crc16genibus, /* */ CRC_PRESET_CRC16_GENIBUS, "CRC-16 GENIBUS checksum");
|
||||
rz_plugin_crca_preset_definition(crc16maxim, /* */ CRC_PRESET_CRC16_MAXIM, "CRC-16 MAXIM checksum");
|
||||
rz_plugin_crca_preset_definition(crc16mcrf4xx, /* */ CRC_PRESET_CRC16_MCRF4XX, "CRC-16 MCRF4XX checksum");
|
||||
rz_plugin_crca_preset_definition(crc16riello, /* */ CRC_PRESET_CRC16_RIELLO, "CRC-16 RIELLO checksum");
|
||||
rz_plugin_crca_preset_definition(crc16t10dif, /* */ CRC_PRESET_CRC16_T10_DIF, "CRC-16 T10-DIF checksum");
|
||||
rz_plugin_crca_preset_definition(crc16teledisk, /**/ CRC_PRESET_CRC16_TELEDISK, "CRC-16 TELEDISK checksum");
|
||||
rz_plugin_crca_preset_definition(crc16tms37157, /**/ CRC_PRESET_CRC16_TMS37157, "CRC-16 TMS37157 checksum");
|
||||
rz_plugin_crca_preset_definition(crca, /* */ CRC_PRESET_CRCA, "CRC-16/CRCA checksum");
|
||||
rz_plugin_crca_preset_definition(crc16kermit, /* */ CRC_PRESET_CRC16_KERMIT, "CRC-16 KERMIT checksum");
|
||||
rz_plugin_crca_preset_definition(crc16modbus, /* */ CRC_PRESET_CRC16_MODBUS, "CRC-16 MODBUS checksum");
|
||||
rz_plugin_crca_preset_definition(crc16x25, /* */ CRC_PRESET_CRC16_X25, "CRC-16 X25 checksum");
|
||||
rz_plugin_crca_preset_definition(crc16xmodem, /* */ CRC_PRESET_CRC16_XMODEM, "CRC-16 XMODEM checksum");
|
||||
rz_plugin_crca_preset_definition(crc24, /* */ CRC_PRESET_24, "CRC-24 checksum");
|
||||
rz_plugin_crca_preset_definition(crc32, /* */ CRC_PRESET_32, "CRC-32 checksum");
|
||||
rz_plugin_crca_preset_definition(crc32ecma267, /* */ CRC_PRESET_32_ECMA_267, "CRC-32 ECMA-267 checksum (EDC for DVD sectors)");
|
||||
rz_plugin_crca_preset_definition(crc32c, /* */ CRC_PRESET_32C, "CRC-32C checksum");
|
||||
rz_plugin_crca_preset_definition(crc32bzip2, /* */ CRC_PRESET_CRC32_BZIP2, "CRC-32 BZIP2 checksum");
|
||||
rz_plugin_crca_preset_definition(crc32d, /* */ CRC_PRESET_CRC32D, "CRC-32D checksum");
|
||||
rz_plugin_crca_preset_definition(crc32mpeg2, /* */ CRC_PRESET_CRC32_MPEG2, "CRC-32 MPEG2 checksum");
|
||||
rz_plugin_crca_preset_definition(crc32posix, /* */ CRC_PRESET_CRC32_POSIX, "CRC-32 POSIX checksum");
|
||||
rz_plugin_crca_preset_definition(crc32q, /* */ CRC_PRESET_CRC32Q, "CRC-32Q checksum");
|
||||
rz_plugin_crca_preset_definition(crc32jamcrc, /* */ CRC_PRESET_CRC32_JAMCRC, "CRC-32 JAMCRC checksum");
|
||||
rz_plugin_crca_preset_definition(crc32xfer, /* */ CRC_PRESET_CRC32_XFER, "CRC-32 XFER checksum");
|
||||
rz_plugin_crca_preset_definition(crc64, /* */ CRC_PRESET_CRC64, "CRC-64 checksum");
|
||||
rz_plugin_crca_preset_definition(crc64ecma182, /* */ CRC_PRESET_CRC64_ECMA182, "CRC-64 ECMA-182 checksum");
|
||||
rz_plugin_crca_preset_definition(crc64we, /* */ CRC_PRESET_CRC64_WE, "CRC-64 WE checksum");
|
||||
rz_plugin_crca_preset_definition(crc64xz, /* */ CRC_PRESET_CRC64_XZ, "CRC-64 XZ checksum");
|
||||
rz_plugin_crca_preset_definition(crc64iso, /* */ CRC_PRESET_CRC64_ISO, "CRC-64 ISO checksum");
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_entropy = {
|
|||
.name = "entropy",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "Entropy [0.0-8.0] range",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_entropy_context_new,
|
||||
.context_free = plugin_entropy_context_free,
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_entropy_fract = {
|
|||
.name = "entropy_fract",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "Fractional entropy [0.0-1.0] range",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_entropy_context_new,
|
||||
.context_free = plugin_entropy_context_free,
|
||||
|
|
|
|||
|
|
@ -83,6 +83,7 @@
|
|||
.name = "fletcher" #bits, \
|
||||
.license = "LGPL3", \
|
||||
.author = "deroad", \
|
||||
.description = "Fletcher" #bits " checksum", \
|
||||
.support_hmac = false, \
|
||||
.context_new = plugin_fletcher##bits##_context_new, \
|
||||
.context_free = plugin_fletcher##bits##_context_free, \
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_md2 = {
|
|||
.name = "md2",
|
||||
.license = "LGPL3",
|
||||
.author = "swedenspy",
|
||||
.description = "MD2 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_md2_context_new,
|
||||
.context_free = plugin_md2_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_md4 = {
|
|||
.name = "md4",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "MD4 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_md4_context_new,
|
||||
.context_free = plugin_md4_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_md5 = {
|
|||
.name = "md5",
|
||||
.license = "LGPL2",
|
||||
.author = "Alan DeKok",
|
||||
.description = "MD5 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_md5_context_new,
|
||||
.context_free = plugin_md5_context_free,
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_mod255 = {
|
|||
.name = "mod255",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "Modulo 255 checksum",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_mod255_context_new,
|
||||
.context_free = plugin_mod255_context_free,
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_parity = {
|
|||
.name = "parity",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "Parity checksum",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_parity_context_new,
|
||||
.context_free = plugin_parity_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_sha1 = {
|
|||
.name = "sha1",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "SHA-1 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_sha1_context_new,
|
||||
.context_free = plugin_sha1_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_sha256 = {
|
|||
.name = "sha256",
|
||||
.author = "Aaron D. Gifford",
|
||||
.license = "BSD-3",
|
||||
.description = "SHA-256 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_sha256_context_new,
|
||||
.context_free = plugin_sha256_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_sha384 = {
|
|||
.name = "sha384",
|
||||
.author = "Aaron D. Gifford",
|
||||
.license = "BSD-3",
|
||||
.description = "SHA-384 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_sha384_context_new,
|
||||
.context_free = plugin_sha384_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_sha512 = {
|
|||
.name = "sha512",
|
||||
.author = "Aaron D. Gifford",
|
||||
.license = "BSD-3",
|
||||
.description = "SHA-512 cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_sha512_context_new,
|
||||
.context_free = plugin_sha512_context_free,
|
||||
|
|
|
|||
|
|
@ -79,6 +79,7 @@ RzHashPlugin rz_hash_plugin_sm3 = {
|
|||
.name = "sm3",
|
||||
.license = "LGPL2",
|
||||
.author = "FSF/deroad",
|
||||
.description = "ShangMi 3 (SM3) cryptographic hash",
|
||||
.support_hmac = true,
|
||||
.context_new = plugin_sm3_context_new,
|
||||
.context_free = plugin_sm3_context_free,
|
||||
|
|
|
|||
|
|
@ -72,6 +72,7 @@ RzHashPlugin rz_hash_plugin_ssdeep = {
|
|||
.name = "ssdeep",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "SSDeep Context Triggered Piecewise Hash (CTPH, fuzzy hash)",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_ssdeep_context_new,
|
||||
.context_free = plugin_ssdeep_context_free,
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_temperature = {
|
|||
.name = "temperature",
|
||||
.license = "LGPL3",
|
||||
.author = "Seva",
|
||||
.description = "Binary temperature [0.0-1.0] range",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_temperature_context_new,
|
||||
.context_free = plugin_temperature_context_free,
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_xor16 = {
|
|||
.name = "xor16",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "XOR-16 checksum",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_xor16_context_new,
|
||||
.context_free = plugin_xor16_context_free,
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ RzHashPlugin rz_hash_plugin_xor8 = {
|
|||
.name = "xor8",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "XOR-8 checksum",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_xor8_context_new,
|
||||
.context_free = plugin_xor8_context_free,
|
||||
|
|
|
|||
|
|
@ -67,6 +67,7 @@ RzHashPlugin rz_hash_plugin_xxhash32 = {
|
|||
.name = "xxhash32",
|
||||
.license = "LGPL3",
|
||||
.author = "deroad",
|
||||
.description = "xxHash32 non-cryptographic hash",
|
||||
.support_hmac = false,
|
||||
.context_new = plugin_xxhash32_context_new,
|
||||
.context_free = plugin_xxhash32_context_free,
|
||||
|
|
|
|||
|
|
@ -42,6 +42,7 @@ typedef struct rz_crypto_plugin_t {
|
|||
const char *name;
|
||||
const char *license;
|
||||
const char *author;
|
||||
const char *description;
|
||||
int (*get_key_size)(RzCrypto *cry);
|
||||
bool (*set_iv)(RzCrypto *cry, const ut8 *iv, int ivlen);
|
||||
bool (*set_key)(RzCrypto *cry, const ut8 *key, int keylen, int mode, int direction);
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ typedef struct rz_hash_plugin_t {
|
|||
const char *name;
|
||||
const char *license;
|
||||
const char *author;
|
||||
const char *description;
|
||||
bool support_hmac;
|
||||
void *(*context_new)();
|
||||
void (*context_free)(void *context);
|
||||
|
|
@ -111,6 +112,7 @@ extern RzHashPlugin rz_hash_plugin_fletcher16;
|
|||
extern RzHashPlugin rz_hash_plugin_fletcher32;
|
||||
extern RzHashPlugin rz_hash_plugin_fletcher64;
|
||||
extern RzHashPlugin rz_hash_plugin_adler32;
|
||||
extern RzHashPlugin rz_hash_plugin_mod255;
|
||||
extern RzHashPlugin rz_hash_plugin_crca_crc8smbus;
|
||||
extern RzHashPlugin rz_hash_plugin_crca_crc8cdma2000;
|
||||
extern RzHashPlugin rz_hash_plugin_crca_crc8darc;
|
||||
|
|
@ -171,6 +173,7 @@ extern RzHashPlugin rz_hash_plugin_entropy_fract;
|
|||
extern RzHashPlugin rz_hash_plugin_blake3;
|
||||
extern RzHashPlugin rz_hash_plugin_ssdeep;
|
||||
extern RzHashPlugin rz_hash_plugin_sm3;
|
||||
extern RzHashPlugin rz_hash_plugin_temperature;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
|
|
|||
|
|
@ -141,7 +141,7 @@ static void rz_hash_show_algorithms(RzHashContext *ctx) {
|
|||
const RzHashPlugin *rmdp;
|
||||
rz_list_foreach (plugin_list, it, rmdp) {
|
||||
snprintf(flags, sizeof(flags), "____h%c", rmdp->support_hmac ? 'm' : '_');
|
||||
printf("%6s %-14s %-10s %s\n", flags, rmdp->name, rmdp->license, rmdp->author);
|
||||
printf("%6s %-14s %-10s %-30s %s\n", flags, rmdp->name, rmdp->license, rmdp->author, rmdp->description);
|
||||
}
|
||||
rz_list_free(plugin_list);
|
||||
rz_iterator_free(iter);
|
||||
|
|
@ -157,14 +157,14 @@ static void rz_hash_show_algorithms(RzHashContext *ctx) {
|
|||
} else {
|
||||
snprintf(flags, sizeof(flags), "ED____");
|
||||
}
|
||||
printf("%6s %-14s %-10s %s\n", flags, rcp->name, rcp->license, rcp->author);
|
||||
printf("%6s %-14s %-10s %-30s %s\n", flags, rcp->name, rcp->license, rcp->author, rcp->description);
|
||||
}
|
||||
printf(
|
||||
"\n"
|
||||
"flags legenda:\n"
|
||||
" E = encryption, D = decryption\n"
|
||||
" e = encoding, d = encoding\n"
|
||||
" h = hash, m = hmac\n");
|
||||
" h = hash/crc, m = hmac\n");
|
||||
}
|
||||
|
||||
#define rz_hash_bool_error(x, o, f, ...) \
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -204,101 +204,102 @@ FILE==
|
|||
CMDS=!rz-hash -L
|
||||
EXPECT=<<EOF
|
||||
flags algorithm license author
|
||||
____h_ adler32 LGPL3 deroad
|
||||
____h_ blake3 CC0 Samuel Neves,Jack O'Connor
|
||||
____h_ crc15can LGPL3 deroad
|
||||
____h_ crc16 LGPL3 deroad
|
||||
____h_ crc16augccitt LGPL3 deroad
|
||||
____h_ crc16buypass LGPL3 deroad
|
||||
____h_ crc16cdma2000 LGPL3 deroad
|
||||
____h_ crc16citt LGPL3 deroad
|
||||
____h_ crc16dds110 LGPL3 deroad
|
||||
____h_ crc16dectr LGPL3 deroad
|
||||
____h_ crc16dectx LGPL3 deroad
|
||||
____h_ crc16dnp LGPL3 deroad
|
||||
____h_ crc16en13757 LGPL3 deroad
|
||||
____h_ crc16genibus LGPL3 deroad
|
||||
____h_ crc16hdlc LGPL3 deroad
|
||||
____h_ crc16kermit LGPL3 deroad
|
||||
____h_ crc16maxim LGPL3 deroad
|
||||
____h_ crc16mcrf4xx LGPL3 deroad
|
||||
____h_ crc16modbus LGPL3 deroad
|
||||
____h_ crc16riello LGPL3 deroad
|
||||
____h_ crc16t10dif LGPL3 deroad
|
||||
____h_ crc16teledisk LGPL3 deroad
|
||||
____h_ crc16tms37157 LGPL3 deroad
|
||||
____h_ crc16usb LGPL3 deroad
|
||||
____h_ crc16x25 LGPL3 deroad
|
||||
____h_ crc16xmodem LGPL3 deroad
|
||||
____h_ crc24 LGPL3 deroad
|
||||
____h_ crc32 LGPL3 deroad
|
||||
____h_ crc32bzip2 LGPL3 deroad
|
||||
____h_ crc32c LGPL3 deroad
|
||||
____h_ crc32d LGPL3 deroad
|
||||
____h_ crc32ecma267 LGPL3 deroad
|
||||
____h_ crc32jamcrc LGPL3 deroad
|
||||
____h_ crc32mpeg2 LGPL3 deroad
|
||||
____h_ crc32posix LGPL3 deroad
|
||||
____h_ crc32q LGPL3 deroad
|
||||
____h_ crc32xfer LGPL3 deroad
|
||||
____h_ crc64 LGPL3 deroad
|
||||
____h_ crc64ecma182 LGPL3 deroad
|
||||
____h_ crc64iso LGPL3 deroad
|
||||
____h_ crc64we LGPL3 deroad
|
||||
____h_ crc64xz LGPL3 deroad
|
||||
____h_ crc8cdma2000 LGPL3 deroad
|
||||
____h_ crc8darc LGPL3 deroad
|
||||
____h_ crc8dvbs2 LGPL3 deroad
|
||||
____h_ crc8ebu LGPL3 deroad
|
||||
____h_ crc8icode LGPL3 deroad
|
||||
____h_ crc8itu LGPL3 deroad
|
||||
____h_ crc8maxim LGPL3 deroad
|
||||
____h_ crc8rohc LGPL3 deroad
|
||||
____h_ crc8smbus LGPL3 deroad
|
||||
____h_ crc8wcdma LGPL3 deroad
|
||||
____h_ crca LGPL3 deroad
|
||||
____h_ entropy LGPL3 deroad
|
||||
____h_ entropy_fract LGPL3 deroad
|
||||
____h_ fletcher16 LGPL3 deroad
|
||||
____h_ fletcher32 LGPL3 deroad
|
||||
____h_ fletcher64 LGPL3 deroad
|
||||
____h_ fletcher8 LGPL3 deroad
|
||||
____hm md2 LGPL3 swedenspy
|
||||
____hm md4 LGPL3 deroad
|
||||
____hm md5 LGPL2 Alan DeKok
|
||||
____h_ parity LGPL3 deroad
|
||||
____hm sha1 LGPL3 deroad
|
||||
____hm sha256 BSD-3 Aaron D. Gifford
|
||||
____hm sha384 BSD-3 Aaron D. Gifford
|
||||
____hm sha512 BSD-3 Aaron D. Gifford
|
||||
____hm sm3 LGPL2 FSF/deroad
|
||||
____h_ ssdeep LGPL3 deroad
|
||||
____h_ temperature LGPL3 Seva
|
||||
____h_ xor16 LGPL3 deroad
|
||||
____h_ xor8 LGPL3 deroad
|
||||
____h_ xxhash32 LGPL3 deroad
|
||||
ED____ rc4 LGPL-3 pancake
|
||||
ED____ rc6 LGPL-3 rakholiyajenish.07
|
||||
_D____ ror LGPL-3 pancake
|
||||
__ed__ base64 LGPL-3 rakholiyajenish.07
|
||||
ED____ xor LGPL-3 pancake
|
||||
ED____ rc2 LGPL-3 lionaneesh
|
||||
ED____ cps2 LGPL-3 pancake,esanfelix,pof
|
||||
ED____ rot LGPL-3 pancake
|
||||
__ed__ punycode LGPL-3 pancake
|
||||
ED____ serpent-ecb LGPL-3 NicsTr
|
||||
ED____ sm4-ecb LGPL-3 0xSh4dy
|
||||
ED____ aes-cbc LGPL-3 rakholiyajenish.07
|
||||
E_____ rol LGPL-3 pancake
|
||||
ED____ aes-ecb LGPL3 Nettle project,pancake
|
||||
ED____ des-ecb LGPL-3 deroad
|
||||
ED____ blowfish LGPL3 kishorbhat
|
||||
__ed__ base91 LGPL-3 rakholiyajenish.07
|
||||
____h_ adler32 LGPL3 deroad Adler-32 checksum
|
||||
____h_ blake3 CC0 Samuel Neves,Jack O'Connor BLAKE3 cryptographic hash
|
||||
____h_ crc15can LGPL3 deroad CRC-15 CAN checksum
|
||||
____h_ crc16 LGPL3 deroad CRC-16 IBM/ARC checksum
|
||||
____h_ crc16augccitt LGPL3 deroad CRC-16 AUG-CCITT checksum
|
||||
____h_ crc16buypass LGPL3 deroad CRC-16 BUYPASS checksum
|
||||
____h_ crc16cdma2000 LGPL3 deroad CRC-16 CDMA-2000 checksum
|
||||
____h_ crc16citt LGPL3 deroad CRC-16 CITT checksum
|
||||
____h_ crc16dds110 LGPL3 deroad CRC-16 DDS110 checksum
|
||||
____h_ crc16dectr LGPL3 deroad CRC-16 DECT-R checksum
|
||||
____h_ crc16dectx LGPL3 deroad CRC-16 DECT-X checksum
|
||||
____h_ crc16dnp LGPL3 deroad CRC-16 DNP checksum
|
||||
____h_ crc16en13757 LGPL3 deroad CRC-16 EN-13757 checksum
|
||||
____h_ crc16genibus LGPL3 deroad CRC-16 GENIBUS checksum
|
||||
____h_ crc16hdlc LGPL3 deroad CRC-16 HDLC checksum
|
||||
____h_ crc16kermit LGPL3 deroad CRC-16 KERMIT checksum
|
||||
____h_ crc16maxim LGPL3 deroad CRC-16 MAXIM checksum
|
||||
____h_ crc16mcrf4xx LGPL3 deroad CRC-16 MCRF4XX checksum
|
||||
____h_ crc16modbus LGPL3 deroad CRC-16 MODBUS checksum
|
||||
____h_ crc16riello LGPL3 deroad CRC-16 RIELLO checksum
|
||||
____h_ crc16t10dif LGPL3 deroad CRC-16 T10-DIF checksum
|
||||
____h_ crc16teledisk LGPL3 deroad CRC-16 TELEDISK checksum
|
||||
____h_ crc16tms37157 LGPL3 deroad CRC-16 TMS37157 checksum
|
||||
____h_ crc16usb LGPL3 deroad CRC-16 USB checksum
|
||||
____h_ crc16x25 LGPL3 deroad CRC-16 X25 checksum
|
||||
____h_ crc16xmodem LGPL3 deroad CRC-16 XMODEM checksum
|
||||
____h_ crc24 LGPL3 deroad CRC-24 checksum
|
||||
____h_ crc32 LGPL3 deroad CRC-32 checksum
|
||||
____h_ crc32bzip2 LGPL3 deroad CRC-32 BZIP2 checksum
|
||||
____h_ crc32c LGPL3 deroad CRC-32C checksum
|
||||
____h_ crc32d LGPL3 deroad CRC-32D checksum
|
||||
____h_ crc32ecma267 LGPL3 deroad CRC-32 ECMA-267 checksum (EDC for DVD sectors)
|
||||
____h_ crc32jamcrc LGPL3 deroad CRC-32 JAMCRC checksum
|
||||
____h_ crc32mpeg2 LGPL3 deroad CRC-32 MPEG2 checksum
|
||||
____h_ crc32posix LGPL3 deroad CRC-32 POSIX checksum
|
||||
____h_ crc32q LGPL3 deroad CRC-32Q checksum
|
||||
____h_ crc32xfer LGPL3 deroad CRC-32 XFER checksum
|
||||
____h_ crc64 LGPL3 deroad CRC-64 checksum
|
||||
____h_ crc64ecma182 LGPL3 deroad CRC-64 ECMA-182 checksum
|
||||
____h_ crc64iso LGPL3 deroad CRC-64 ISO checksum
|
||||
____h_ crc64we LGPL3 deroad CRC-64 WE checksum
|
||||
____h_ crc64xz LGPL3 deroad CRC-64 XZ checksum
|
||||
____h_ crc8cdma2000 LGPL3 deroad CRC-8 CDMA-2000 checksum
|
||||
____h_ crc8darc LGPL3 deroad CRC-8 DARC checksum
|
||||
____h_ crc8dvbs2 LGPL3 deroad CRC-8 DVB-S2 checksum
|
||||
____h_ crc8ebu LGPL3 deroad CRC-8 EBU checksum
|
||||
____h_ crc8icode LGPL3 deroad CRC-8 I-CODE checksum
|
||||
____h_ crc8itu LGPL3 deroad CRC-8 ITU checksum
|
||||
____h_ crc8maxim LGPL3 deroad CRC-8 MAXIM checksum
|
||||
____h_ crc8rohc LGPL3 deroad CRC-8 ROHC checksum
|
||||
____h_ crc8smbus LGPL3 deroad CRC-8 SMBUS checksum
|
||||
____h_ crc8wcdma LGPL3 deroad CRC-8 WCDMA checksum
|
||||
____h_ crca LGPL3 deroad CRC-16/CRCA checksum
|
||||
____h_ entropy LGPL3 deroad Entropy [0.0-8.0] range
|
||||
____h_ entropy_fract LGPL3 deroad Fractional entropy [0.0-1.0] range
|
||||
____h_ fletcher16 LGPL3 deroad Fletcher16 checksum
|
||||
____h_ fletcher32 LGPL3 deroad Fletcher32 checksum
|
||||
____h_ fletcher64 LGPL3 deroad Fletcher64 checksum
|
||||
____h_ fletcher8 LGPL3 deroad Fletcher8 checksum
|
||||
____hm md2 LGPL3 swedenspy MD2 cryptographic hash
|
||||
____hm md4 LGPL3 deroad MD4 cryptographic hash
|
||||
____hm md5 LGPL2 Alan DeKok MD5 cryptographic hash
|
||||
____h_ mod255 LGPL3 deroad Modulo 255 checksum
|
||||
____h_ parity LGPL3 deroad Parity checksum
|
||||
____hm sha1 LGPL3 deroad SHA-1 cryptographic hash
|
||||
____hm sha256 BSD-3 Aaron D. Gifford SHA-256 cryptographic hash
|
||||
____hm sha384 BSD-3 Aaron D. Gifford SHA-384 cryptographic hash
|
||||
____hm sha512 BSD-3 Aaron D. Gifford SHA-512 cryptographic hash
|
||||
____hm sm3 LGPL2 FSF/deroad ShangMi 3 (SM3) cryptographic hash
|
||||
____h_ ssdeep LGPL3 deroad SSDeep Context Triggered Piecewise Hash (CTPH, fuzzy hash)
|
||||
____h_ temperature LGPL3 Seva Binary temperature [0.0-1.0] range
|
||||
____h_ xor16 LGPL3 deroad XOR-16 checksum
|
||||
____h_ xor8 LGPL3 deroad XOR-8 checksum
|
||||
____h_ xxhash32 LGPL3 deroad xxHash32 non-cryptographic hash
|
||||
ED____ rc4 LGPL-3 pancake RC4 symmetric-key block cipher
|
||||
ED____ rc6 LGPL-3 rakholiyajenish.07 RC6 symmetric-key block cipher
|
||||
_D____ ror LGPL-3 pancake Rotate Right symmetric-key block cipher
|
||||
__ed__ base64 LGPL-3 rakholiyajenish.07 Base64 encoder/decoder
|
||||
ED____ xor LGPL-3 pancake XOR symmetric-key block cipher
|
||||
ED____ rc2 LGPL-3 lionaneesh RC2 symmetric-key block cipher
|
||||
ED____ cps2 LGPL-3 pancake,esanfelix,pof Capcom Play System 2 (CPS-2) symmetric-key block cipher
|
||||
ED____ rot LGPL-3 pancake Caesar symmetric-key cipher
|
||||
__ed__ punycode LGPL-3 pancake Punycode encoder/decoder
|
||||
ED____ serpent-ecb LGPL-3 NicsTr Serpent symmetric-key block cipher (ECB block mode)
|
||||
ED____ sm4-ecb LGPL-3 0xSh4dy ShangMi 4 symmetric-key block cipher (ECB block mode)
|
||||
ED____ aes-cbc LGPL-3 rakholiyajenish.07 AES symmetric-key block cipher (CBC block mode)
|
||||
E_____ rol LGPL-3 pancake Rotate Left symmetric-key block cipher
|
||||
ED____ aes-ecb LGPL3 Nettle project,pancake AES symmetric-key block cipher (ECB block mode)
|
||||
ED____ des-ecb LGPL-3 deroad DES symmetric-key block cipher (ECB block mode)
|
||||
ED____ blowfish LGPL3 kishorbhat Blowfish symmetric-key block cipher
|
||||
__ed__ base91 LGPL-3 rakholiyajenish.07 Base91 encoder/decoder
|
||||
|
||||
flags legenda:
|
||||
E = encryption, D = decryption
|
||||
e = encoding, d = encoding
|
||||
h = hash, m = hmac
|
||||
h = hash/crc, m = hmac
|
||||
EOF
|
||||
RUN
|
||||
|
||||
|
|
@ -734,6 +735,7 @@ string: 0x00000000-0x00000005 fletcher8: computed hash doesn't match the expecte
|
|||
string: 0x00000000-0x00000005 md2: computed hash doesn't match the expected one
|
||||
string: 0x00000000-0x00000005 md4: computed hash doesn't match the expected one
|
||||
string: 0x00000000-0x00000005 md5: computed hash matches the expected one
|
||||
string: 0x00000000-0x00000005 mod255: computed hash doesn't match the expected one
|
||||
string: 0x00000000-0x00000005 parity: computed hash doesn't match the expected one
|
||||
string: 0x00000000-0x00000005 sha1: computed hash doesn't match the expected one
|
||||
string: 0x00000000-0x00000005 sha256: computed hash doesn't match the expected one
|
||||
|
|
|
|||
Loading…
Reference in a new issue