Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jhwohlgemuth/zsh-pentest
Aliases and functions for the lazy penetration tester
https://github.com/jhwohlgemuth/zsh-pentest
hacktoberfest
Last synced: 16 days ago
JSON representation
Aliases and functions for the lazy penetration tester
- Host: GitHub
- URL: https://github.com/jhwohlgemuth/zsh-pentest
- Owner: jhwohlgemuth
- License: mit
- Created: 2019-11-14T15:42:12.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2024-01-28T21:45:17.000Z (10 months ago)
- Last Synced: 2024-05-21T13:51:51.723Z (6 months ago)
- Topics: hacktoberfest
- Language: Shell
- Homepage:
- Size: 37.1 KB
- Stars: 57
- Watchers: 3
- Forks: 11
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
oh-my-zsh pentest plugin
========================
> [Aliases](#aliases) and [functions](#functions) for the lazy penetration testerInstallation
------------```bash
git clone https://github.com/jhwohlgemuth/zsh-pentest.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-pentest
```Usage
------ Add `zsh-pentest` to the plugins array in your `.zshrc` file:
```bash
plugins=(... zsh-pentest)
```- Open a new terminal or execute `source ~/.zshrc`
> **Tip**: For epic synergy and awesome productivity, use the [zsh-handy-helpers](https://github.com/jhwohlgemuth/zsh-handy-helpers) plugin too!
```bash
plugins=(... zsh-pentest zsh-handy-helpers)
```Aliases
-------
> ***Hint:*** The [nmap oh-my-zsh plugin](https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/nmap) has several great aliases for `nmap`| Alias | Command |
| :--- | :--- |
| me | `echo $(ifconfig eth0 \| grep "inet " \| cut -b 9- \| cut -d" " -f2)` |
| cme | `crackmapexec` |
| e4l | `enum4linux -a` |
| h2t | `html2text -style pretty` |
| oso | `onesixtyone ` |Functions
---------| Name | Command | Tested |
| :--- | :--- | :--- |
| `create_scan_directory` | Create directory for saving results | yes |
| `enum_snmp` **$IP** [**WORDLIST**] [**NETWORK**] | Create host list and scan **IP** with **WORDLIST** | yes |
| `enum_web` **$IP** [**PORT**] [**WORDLIST**] | Enumerate **IP** with `whatweb` and `nikto` | yes |
| `flush_iptables` | You guessed it...this flushes `iptables` | yes |
| `focus` [**IP**] [**PORT**] | Set RHOST=IP and RPORT=PORT | yes |
| `get_gateway` | Get router IP address | yes |
| `get_hosts` [**PORT**] | Get list of host IP addresses found via `nmap` | yes |
| `get_hostnames` **$IP** | Get list of host names using `nmap` and the **IP** of a known DNS server | yes |
| `htm` [**IP**] | Download **IP** and print with `html2text` | yes |
| `monitor_traffic` [**$IP**] | Monitor bytes over the line with `iptables` | yes |
| `scan_tcp` **$IP** | Scan **IP** with ~~`onetwopunch`~~ [`masscan`](https://github.com/robertdavidgraham/masscan) | yes |
| `serve` [**PORT**] | Start Python server in current directory on **PORT** [default: 80] | yes |
| `sort_ips` **ADDRESSES** | Sort list of IP addresses | yes |Example Usage
-------------This plugin pairs well with the [zsh-handy-helpers]() plugin `iter` function:
```bash
# Scan all SMB servers for vulnerabilities with nmap scripts
scan() {nmap $1 --script "smb-vuln-*"}
get_hosts 139 | iter scan
```