1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-11-23 00:28:11 +00:00

Removed functions sort_by_pot() and sort_by_salt_buf() from potfile.c - Code no longer required due to potfile --show and --left handling logic

This commit is contained in:
jsteube 2016-11-16 10:16:15 +01:00
parent 92d485c8c7
commit 23fa7000fa
2 changed files with 0 additions and 35 deletions

View File

@ -12,8 +12,6 @@
#define INCR_POT 1000
int sort_by_pot (const void *v1, const void *v2, MAYBE_UNUSED void *v3);
int sort_by_salt_buf (const void *v1, const void *v2, MAYBE_UNUSED void *v3);
int sort_by_hash_t_salt (const void *v1, const void *v2);
int sort_by_hash_t_salt_hccap (const void *v1, const void *v2);

View File

@ -27,39 +27,6 @@ int sort_by_hash (const void *v1, const void *v2, void *v3);
int sort_by_hash_no_salt (const void *v1, const void *v2, void *v3);
// get rid of this later
int sort_by_pot (const void *v1, const void *v2, MAYBE_UNUSED void *v3)
{
const pot_t *p1 = (const pot_t *) v1;
const pot_t *p2 = (const pot_t *) v2;
const hash_t *h1 = &p1->hash;
const hash_t *h2 = &p2->hash;
return sort_by_hash (h1, h2, v3);
}
int sort_by_salt_buf (const void *v1, const void *v2, MAYBE_UNUSED void *v3)
{
const pot_t *p1 = (const pot_t *) v1;
const pot_t *p2 = (const pot_t *) v2;
const hash_t *h1 = &p1->hash;
const hash_t *h2 = &p2->hash;
const salt_t *s1 = h1->salt;
const salt_t *s2 = h2->salt;
u32 n = 16;
while (n--)
{
if (s1->salt_buf[n] > s2->salt_buf[n]) return 1;
if (s1->salt_buf[n] < s2->salt_buf[n]) return -1;
}
return 0;
}
int sort_by_hash_t_salt (const void *v1, const void *v2)
{
const hash_t *h1 = (const hash_t *) v1;