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

first version of libdirsearch #960

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
- Option to skip target by specified status codes
- Bug fixes

## [0.4.2] - 2021.9.8
- LibDirSearch. Allows dirsearch to be used as a library.

## [0.4.1] - 2020.12.8
- Faster
- Allow to brute force through a CIDR notation
Expand Down
1 change: 1 addition & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@
- [Ivan Fedotov](https://github.com/qumusabel)
- [Manuel Poisson](https://github.com/ManuelPOISSON)
- [XinRoom](https://github.com/XinRoom)
- [InsaneMiner](https://github.com/InsaneMiner/)

Special thanks to all the people who are named here!

Expand Down
28 changes: 28 additions & 0 deletions example/libs_example.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
import dirsearch.libdirsearch as lds

class DirFoundHandle(lds.DirFoundHandler):
def found_dir(self, path, reponse, full_url, added_to_queue):
print(path)
if (reponse.redirect):
print(reponse.redirect)

def config_data(self, extensions, prefixes, suffixes, threads_count, dictionary, httpmethod):
print(
', '.join(extensions),
', '.join(prefixes),
', '.join(suffixes),
str(threads_count),
str(len(dictionary)),
str(httpmethod),
)


dfh = DirFoundHandle()

dirsearch = lds.dirsearch(dfh)

args = ["-u", "http://sneaindia.com/"]

dirsearch.run(args)

print(dfh.dirs)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All files should be ended with a new line

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, I would like to rename the folder to examples, as in the future there will be more examples

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, I would like to rename the folder to examples, as in the future there will be more examples

ok

Loading