# SearchSploit

> The command-line search for a local copy of Exploit-DB — find, examine and copy exploits by product, version or CVE.

- Category: Exploitation
- Commands: 60
- Page: https://terminal.rokibulroni.com/tool/exploitation/searchsploit
- Homepage: https://www.exploit-db.com/searchsploit
- Documentation: https://www.exploit-db.com/searchsploit
- Tags: exploits, search, offline

## Install

- apt: `sudo apt install exploitdb`
- brew: `brew install exploitdb`

## Help and Updates

### searchsploit --help

```bash
searchsploit --help
```

Displays the main help menu and lists all available options and flags

### searchsploit -u

```bash
searchsploit -u
```

Updates the local Exploit Database repository to the latest version


## Basic Keyword Search

### searchsploit apache

```bash
searchsploit apache
```

Searches for any exploits containing the term apache in the title or path

### searchsploit wordpress

```bash
searchsploit wordpress
```

Finds exploits related to the WordPress content management system

### searchsploit smb

```bash
searchsploit smb
```

Locates exploits targeting the Server Message Block protocol


## Multi Keyword Search

### searchsploit linux kernel

```bash
searchsploit linux kernel
```

Searches for exploits matching both 'linux' and 'kernel' terms

### searchsploit windows smb remote

```bash
searchsploit windows smb remote
```

Finds Windows SMB exploits that function remotely by combining keywords

### searchsploit apache 2.4

```bash
searchsploit apache 2.4
```

Narrows search results to specific software versions using the version number


## Title Based Search

### searchsploit -t oracle

```bash
searchsploit -t oracle
```

Restricts the search strictly to the exploit titles, ignoring file paths

### searchsploit -t "windows 10"

```bash
searchsploit -t "windows 10"
```

Searches specifically for 'windows 10' within exploit titles only


## Exact Match Search

### searchsploit -e "WordPress Core 4.7"

```bash
searchsploit -e "WordPress Core 4.7"
```

Performs a strict exact match search for the specified string

### searchsploit -e "ProFTPD 1.3.5"

```bash
searchsploit -e "ProFTPD 1.3.5"
```

Finds exploits matching exactly the specified ProFTPD version string


## Case Sensitivity

### searchsploit -c OpenSSH

```bash
searchsploit -c OpenSSH
```

Performs a case-sensitive search distinguishing between 'OpenSSH' and 'openssh'

### searchsploit -c MySQL

```bash
searchsploit -c MySQL
```

Ensures the search respects the capitalization of the term MySQL


## ID Based Search

### searchsploit 39446

```bash
searchsploit 39446
```

Retrieves the specific exploit associated with Exploit-DB ID 39446


## CVE Based Search

### searchsploit CVE-2021-44228

```bash
searchsploit CVE-2021-44228
```

Searches the database for exploits referencing the Log4Shell CVE ID


## Platform Filtering

### searchsploit --platform windows

```bash
searchsploit --platform windows
```

Lists all available exploits targeting the Windows operating system

### searchsploit --platform linux

```bash
searchsploit --platform linux
```

Filters the database to show only exploits designed for Linux systems

### searchsploit --platform android

```bash
searchsploit --platform android
```

Shows exploits targeting the Android mobile platform


## Type Filtering

### searchsploit --type webapps

```bash
searchsploit --type webapps
```

Filters results to show only web application based vulnerabilities

### searchsploit --type local

```bash
searchsploit --type local
```

Restricts results to local privilege escalation or local exploits

### searchsploit --type remote

```bash
searchsploit --type remote
```

Limits the output to remote code execution and remote exploits

### searchsploit --type shellcode

```bash
searchsploit --type shellcode
```

Searches specifically for shellcode entries rather than full exploit scripts

### searchsploit --type dos

```bash
searchsploit --type dos
```

Filters for Denial of Service (DoS) proof of concept scripts


## Combined Filtering

### searchsploit --platform windows --type local

```bash
searchsploit --platform windows --type local
```

Combines filters to find local privilege escalation exploits for Windows

### searchsploit apache --platform linux --type remote

```bash
searchsploit apache --platform linux --type remote
```

Finds remote Apache exploits specifically for Linux platforms


## Excluding Terms

### searchsploit wordpress --exclude="dos"

```bash
searchsploit wordpress --exclude="dos"
```

Searches for WordPress exploits while removing Denial of Service results

### searchsploit apache --exclude="dos|poisoning"

```bash
searchsploit apache --exclude="dos|poisoning"
```

Uses pipe syntax to exclude multiple terms like DoS and poisoning from results


## File Operations

### searchsploit -p 39446

```bash
searchsploit -p 39446
```

Displays the full local path to the exploit file with ID 39446

### searchsploit -m 39446

```bash
searchsploit -m 39446
```

Copies the exploit file 39446 to the current working directory

### searchsploit -m 42031 42032

```bash
searchsploit -m 42031 42032
```

Mirrors multiple exploit files to the current directory in a single command

### searchsploit -x 39446

```bash
searchsploit -x 39446
```

Opens the specified exploit file in the default terminal pager or editor


## Online Integration

### searchsploit -w apache

```bash
searchsploit -w apache
```

Provides URLs to the Exploit-DB website for the search results

### searchsploit -w 39446

```bash
searchsploit -w 39446
```

Generates the direct web link for the specific exploit ID 39446


## Output Formatting

### searchsploit --id

```bash
searchsploit --id
```

Displays the EDB-ID explicitly in the search results columns

### searchsploit --color

```bash
searchsploit --color
```

Forces colored output even when piping results to other commands

### searchsploit --no-color

```bash
searchsploit --no-color
```

Disables color codes in output for easier parsing or logging

### searchsploit -o apache

```bash
searchsploit -o apache
```

Allows overflow of columns to prevent description truncation

### searchsploit -v apache

```bash
searchsploit -v apache
```

Enables verbose mode to show more details about the search process


## JSON Output

### searchsploit -j apache

```bash
searchsploit -j apache
```

Outputs the search results in JSON format for programmatic processing

### searchsploit --json wordpress

```bash
searchsploit --json wordpress
```

Uses the long-form flag to generate machine-readable JSON output


## Strict Mode

### searchsploit -s "linux kernel"

```bash
searchsploit -s "linux kernel"
```

Enables strict searching which may filter out loose matches


## Advanced Workflow

### searchsploit tomcat --platform windows --type remote --id

```bash
searchsploit tomcat --platform windows --type remote --id
```

Combines ID display with platform and type filters for precise targeting

### searchsploit joomla --exclude="(SQLi|XSS)"

```bash
searchsploit joomla --exclude="(SQLi|XSS)"
```

Uses regex-style exclusion to filter out common SQLi and XSS vulnerabilities

### searchsploit --cve 2020

```bash
searchsploit --cve 2020
```

Searches specifically for CVEs assigned in the year 2020

### searchsploit privilege --platform linux --type local -t

```bash
searchsploit privilege --platform linux --type local -t
```

Searches titles only for privilege escalation on local Linux systems


## Automation and Scripting

### searchsploit -j nginx > nginx_exploits.json

```bash
searchsploit -j nginx > nginx_exploits.json
```

Redirects JSON output to a file for use in automated pipelines

### searchsploit -p 44228 | xargs grep "Usage"

```bash
searchsploit -p 44228 | xargs grep "Usage"
```

Finds the path and pipes it to grep to check usage instructions

### searchsploit struts --json | jq .

```bash
searchsploit struts --json | jq .
```

Pipes JSON output to jq for pretty-printing and parsing


## Red Team Discovery

### searchsploit "authenticated remote" --platform php

```bash
searchsploit "authenticated remote" --platform php
```

Searches for PHP exploits requiring authentication for remote execution

### searchsploit "unauthenticated RCE"

```bash
searchsploit "unauthenticated RCE"
```

Hunts for critical unauthenticated remote code execution vulnerabilities


## Blue Team Research

### searchsploit --author "Google Security"

```bash
searchsploit --author "Google Security"
```

Filters exploits by specific security researchers or organizations

### searchsploit --type webapps --exclude="cms"

```bash
searchsploit --type webapps --exclude="cms"
```

Looks for web app vulnerabilities excluding generic CMS results


## Nmap Integration

### searchsploit --nmap file.xml

```bash
searchsploit --nmap file.xml
```

Parses an Nmap XML output file to automatically suggest exploits

### searchsploit -v --nmap scan_result.xml

```bash
searchsploit -v --nmap scan_result.xml
```

Parses Nmap XML in verbose mode to see how services are matched


## Complex Regex

### searchsploit -t "(buffer|heap) overflow"

```bash
searchsploit -t "(buffer|heap) overflow"
```

Uses regex in title search to find buffer or heap overflows


## Exploit Mirroring

### searchsploit -m $(searchsploit wordpress -w -t --id | awk '{print $1}')

```bash
searchsploit -m $(searchsploit wordpress -w -t --id | awk '{print $1}')
```

Advanced subshell usage to mirror all found exploits (use with caution)


## Shellcode Analysis

### searchsploit linux/x86 --type shellcode

```bash
searchsploit linux/x86 --type shellcode
```

Searches specifically for x86 architecture shellcode for Linux


## Maintenance

### searchsploit --update

```bash
searchsploit --update
```

Alternative long-flag syntax to update the exploit database


## Full Path Output

### searchsploit --fullpath apache

```bash
searchsploit --fullpath apache
```

Displays the complete system path to the exploit files in results

## Related tools

- [Exploit-DB](https://terminal.rokibulroni.com/tool/exploitation/exploitdb)
- [Metasploit Framework](https://terminal.rokibulroni.com/tool/exploitation/metasploit)
- [Nmap](https://terminal.rokibulroni.com/tool/network/nmap)
