mirror of
https://github.com/vanhauser-thc/thc-hydra.git
synced 2025-08-22 06:13:55 -07:00
uptodate with rainycrack
This commit is contained in:
parent
5697d99476
commit
51a47c5cf6
1 changed files with 8 additions and 7 deletions
13
bfg.c
13
bfg.c
|
@ -200,15 +200,16 @@ uint64_t bf_get_pcount() {
|
|||
}
|
||||
|
||||
char *bf_next() {
|
||||
int32_t i, pos = bf_options.current - 1;
|
||||
|
||||
if (bf_options.current > bf_options.to)
|
||||
return NULL; // we are done
|
||||
|
||||
if ((bf_options.ptr = malloc(BF_CHARSMAX)) == NULL) {
|
||||
fprintf(stderr, "Error: Can not allocate memory for -x data!\n");
|
||||
return NULL;
|
||||
int accu(int x) {
|
||||
int a = 0, b;
|
||||
for(b=1; b<x; ++b)
|
||||
a+=b;
|
||||
return a;
|
||||
}
|
||||
|
||||
char *bf_next(_Bool rainy) {
|
||||
for (i = 0; i < bf_options.current; i++)
|
||||
bf_options.ptr[i] = bf_options.crs[bf_options.state[i]];
|
||||
bf_options.ptr[bf_options.current] = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue