Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upload wordlists/rulesets from disk #126

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

puzzlepeaches
Copy link

This PR adds support for uploading wordlists/rulesets from disk instead of a web browser. The functionality here is identical to the Ruby version.

Changes Made:

Directories were added to the following locations and contain .gitkeep files:

hashview/control/rules/auto_upload
hashview/control/wordlists/auto_upload

A job with APScehduler was added to hashview.py for both rulesets and wordlist that checks for new files every minute. When a new file is detected in the auto_upload folders:

  1. A checksum for the file is generated and compared to existing rulesets/wordlists in the DB
  2. If the wordlist/ruleset is unique, the file is imported into the database in the background

Notes:

  • This PR contains the code from Adds Docker support #125. I think you should merge that first before attempting to merge this code.
  • This feature has yet to be tested with very large files. Can't with my current setup.
  • The one-minute interval check for new word lists might be too frequent. I cannot tell how system-intensive the file hashing is on a large wordlist. If it eats a ton of resources, the user may experience issues.
  • Changes were also made to the docker-compose.yaml file to support this change for a docker-based environment. They are commented out with a note.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant