Package: tokenish
tokenishA simple tool to fill pattern with tokens from file or directory.InstallationHow to useExampleCommandsLicenseTestsInstallationpipinstalltokenishHow to useusage: tokenish [-h] [-t TOKENS [TOKENS ...]] [-e ENCODING] [-o OUTPUT_DIRECTORY] [-om MAX_FILE_ROWS] pattern

Generate rows from pattern for each token combinations

positional arguments:
  pattern               text to fill with links or usernames/passwords

optional arguments:
  -h, --help            show this help message and exit
  -t TOKENS [TOKENS ...], --tokens TOKENS [TOKENS ...]
                        list of tokens file or directory path
  -e ENCODING, --encoding ENCODING
                        type of encoding to apply
  -o OUTPUT_DIRECTORY, --output-directory OUTPUT_DIRECTORY
                        directory where results will write, print is None
  -om MAX_FILE_ROWS, --max-file-rows MAX_FILE_ROWS
                        maximum number of rows per file, default 10 000Available token paths:file: all lines in file are consider like tokens.directory: all lines of all files in directory are consider like tokens.Each token paths should have an associated token in pattern.
For example, if two token paths are defined, pattern should contain &TOKEN_0& and &TOKEN_1&.Available encodings:base64The pattern part to encode must be in the following tag:&ENC[to encode]ODE&ExampleLet's consider the /tokens directory with the following tree structure:.
├── passwords
│   └── passwords_1.txt
└── usernames
    ├── usernames_1.txt
    └── usernames_2.txtContent of usernames_1.txt:admin
root
userContent of usernames_2.txt:user1
user2Content of passwords_1.txt:1234
6712The command:tokenish"Authorization: Basic &TOKEN_0&:&TOKEN_1&"-tusernames/passwords/passwords_1.txtPrint:Authorization: Basic admin:1234
Authorization: Basic admin:6712
Authorization: Basic root:1234
Authorization: Basic root:6712
Authorization: Basic user:1234
Authorization: Basic user:6712
Authorization: Basic user1:1234
Authorization: Basic user1:6712
Authorization: Basic user2:1234
Authorization: Basic user2:6712You can add an encoding like:tokenish"Authorization: Basic &ENC[&TOKEN_0&:&TOKEN_1&]ODE&"-tusernames/passwords/passwords_1.txt-ebase64Print:Authorization: Basic YWRtaW46MTIzNA==
Authorization: Basic YWRtaW46NjcxMg==
Authorization: Basic cm9vdDoxMjM0
Authorization: Basic cm9vdDo2NzEy
Authorization: Basic dXNlcjoxMjM0
Authorization: Basic dXNlcjo2NzEy
Authorization: Basic dXNlcjE6MTIzNA==
Authorization: Basic dXNlcjE6NjcxMg==
Authorization: Basic dXNlcjI6MTIzNA==
Authorization: Basic dXNlcjI6NjcxMg==CommandsPrint all combination of username/password, where usernames replace &TOKEN_0& and passwords replace &TOKEN_1&.tokenish"Authorization: Basic &TOKEN_0&:&TOKEN_1&"-t/path/to/usernames/dir//path/to/passwords.txtSave all combination of username/password in directory /path/output/ composed by files of 10 000 lines.tokenish"Authorization: Basic &TOKEN_0&:&TOKEN_1&"-t/path/to/usernames/dir//path/to/passwords.txt-o/path/output/Save all combination of username/password in directory /path/output/ composed by files of 500 lines.tokenish"Authorization: Basic &TOKEN_0&:&TOKEN_1&"-t/path/to/usernames/dir//path/to/passwords.txt-o/path/output/-om500Print all combination of username/password, where usernames replace &TOKEN_0& and passwords replace &TOKEN_1&.
Expression in tag &ENC[...]ODE& will encode in base64.tokenish"Authorization: Basic &ENC[&TOKEN_0&:&TOKEN_1&]ODE&"-t/path/to/usernames/dir//path/to/passwords.txt-ebase64Licensetokenish is released under MIT license. SeeLICENSE.TestsRun these commands to run tests and update coverage badge:pipinstallreadme-coverage-badger
coveragerun-m--omit"/usr/local/*,/usr/lib/*,tests/*,venv/*"unittestdiscovertests/tokenish
readme-covChangelogAll notable changes to this project will be documented in this file.Log types:addedfor new features.changedfor changes in existing functionality.fixedfor any bug fixes.removedfor features removed in this release.securityto invite users to upgrade in case of vulnerabilities.[Unreleased]AddedchangedFixedremovedsecurity0.1- 2023/03/02AddedInitial releaseMIT LicenseCopyright (c) 2023 Victor MeyerPermission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.