1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-12-22 22:58:30 +00:00

new feature: allow -o to be used in stdout mode

This commit is contained in:
philsmd 2016-08-18 11:04:23 +02:00
parent f715f675ec
commit 14677e915f
2 changed files with 18 additions and 1 deletions

View File

@ -22,6 +22,7 @@
- Replace RegGetValue() with RegQueryValueEx() to enable Windows XP 32 bit compatibility
- Slightly increased NVidias rule-processing performance by using generic instructions instead of byte_perm()
- Add support for @ rule (RULE_OP_MANGLE_PURGECHAR) to use on GPU
- Add support for --outfile (short -o) to be used together with --stdout
##
## Bugs

View File

@ -2544,7 +2544,18 @@ static void process_stdout (hc_device_param_t *device_param, const uint pws_cnt)
{
out_t out;
out.fp = stdout;
out.fp = stdout;
if (data.outfile != NULL)
{
if ((out.fp = fopen (data.outfile, "ab")) == NULL)
{
log_error ("ERROR: %s: %s", data.outfile, strerror (errno));
out.fp = stdout;
}
}
out.len = 0;
uint plain_buf[16] = { 0 };
@ -2712,6 +2723,11 @@ static void process_stdout (hc_device_param_t *device_param, const uint pws_cnt)
}
out_flush (&out);
if (out.fp != stdout)
{
fclose (out.fp);
}
}
static void save_hash ()