initial commit
This commit is contained in:
commit
93d4831bd4
6 changed files with 472 additions and 0 deletions
21
src/plugin_crc16.c
Normal file
21
src/plugin_crc16.c
Normal file
|
@ -0,0 +1,21 @@
|
|||
#include "checksum.h"
|
||||
|
||||
const char* checkbrute_format()
|
||||
{
|
||||
return "CRC16";
|
||||
}
|
||||
|
||||
const char* checkbrute_version()
|
||||
{
|
||||
return "0.1";
|
||||
}
|
||||
|
||||
uint64_t checkbrute_hash64(unsigned char* data, size_t size)
|
||||
{
|
||||
return (uint64_t)crc_16(data, size);
|
||||
}
|
||||
|
||||
int checkbrute_hashsz()
|
||||
{
|
||||
return 2;
|
||||
}
|
21
src/plugin_crc32.c
Normal file
21
src/plugin_crc32.c
Normal file
|
@ -0,0 +1,21 @@
|
|||
#include "checksum.h"
|
||||
|
||||
const char* checkbrute_format()
|
||||
{
|
||||
return "CRC32";
|
||||
}
|
||||
|
||||
const char* checkbrute_version()
|
||||
{
|
||||
return "0.1";
|
||||
}
|
||||
|
||||
uint64_t checkbrute_hash64(unsigned char* data, size_t size)
|
||||
{
|
||||
return (uint64_t)crc_32(data, size);
|
||||
}
|
||||
|
||||
int checkbrute_hashsz()
|
||||
{
|
||||
return 4;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue