From b3067680a7c795aba2d147419c48f774413efa58 Mon Sep 17 00:00:00 2001 From: jsteube Date: Thu, 5 Jan 2017 16:15:12 +0100 Subject: [PATCH] If the user specifies a folder to scan for wordlists instead of directly a wordlist, then ignore the hidden files --- docs/changes.txt | 1 + src/folder.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/changes.txt b/docs/changes.txt index 0fed80d99..1f42f1078 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -5,6 +5,7 @@ ## - Files: Use $HEX[...] in case the password includes the separater character, increases potfile reading performance +- Files: If the user specifies a folder to scan for wordlists instead of directly a wordlist, then ignore the hidden files - Loopback: Include passwords for removed hashes present in the potfile to next loopback iteration - New option --progress-only: Quickly provides ideal progress step size and time to process on the user hashes and selected options, then quit - Status screen: Reenabled automatic status screen display in case of stdin used diff --git a/src/folder.c b/src/folder.c index 1c2c62ab8..82c8727b8 100644 --- a/src/folder.c +++ b/src/folder.c @@ -154,7 +154,7 @@ char *first_file_in_directory (const char *path) #endif - if ((strncmp (de->d_name, ".", strlen (de->d_name)) == 0) || (strncmp (de->d_name, "..", strlen (de->d_name)) == 0)) continue; + if (de->d_name[0] == '.') continue; first_file = strdup (de->d_name);