bruter
A rule based string bruteforcer. Similar to brute but more versatile.
Overview
Bruter provides a callback based bruteforce interface. Mainly a single function brute is exported:
brute(fmt, callback=None, symbols={})
fmt: The string to be plugged variables intocallback: This is the function which will be called for every terminal valuesymbols: This is adictwhich maps symbols (which are strings) to a list of values
Example
from bruter import brute
def printer(x):
print(x)
symbols = {
'H': ['a', 'b', 'c'],
'L': ['x', 'y'],
'X': ['1', '2']
}
brute("hello <H> <L> <X>", printer, symbols)
This one gives you output --
hello a x 1
hello a x 2
hello a y 1
hello a y 2
hello b x 1
hello b x 2
hello b y 1
hello b y 2
hello c x 1
hello c x 2
hello c y 1
hello c y 2
You can also use the predefined strings inside the string module in Python 3 for defining symbols
from bruter import brute
import string
def printer(x):
print(x)
symbols = {
'H': string.ascii_lowercase
}
brute("hello <H>", printer, symbols)
which gives output --
hello a
hello b
hello c
hello d
hello e
hello f
hello g
hello h
hello i
hello j
hello k
hello l
hello m
hello n
hello o
hello p
hello q
hello r
hello s
hello t
hello u
hello v
hello w
hello x
hello y
hello z
Metadata
Release files for bruter 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| bruter-0.0.2.tar.gz | 2.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| bruter-0.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 5.4 kB
Release files / bruter-0.0.2.tar.gz
| Download URL | bruter-0.0.2.tar.gz |
|---|---|
| Size | 2.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
766a8e1f92310feaafd41a55f6cb296e8515f61a45f1ffa7702c9fd6c821c5bc
|
|
BLAKE2b-256 checksum How to use checksums |
daef31913c285f28401a2c6aca109070a10b361529fb7a4903dfb49ecb4b6dcb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.1
|
Release files / bruter-0.0.2-py3-none-any.whl
| Download URL | bruter-0.0.2-py3-none-any.whl |
|---|---|
| Size | 3.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3f0d196da2e196388cde485b215b26664f6d1084f63789ca10f99552ae366000
|
|
BLAKE2b-256 checksum How to use checksums |
3b90a798670357dacf042cdd05b65f994f282fef01dffc5f9fce71d6d66ce7f8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.1
|