GBounty Usage Manual
Overview
GBounty is a multi-step website vulnerability scanner designed for penetration testers and bug bounty hunters. It leverages customizable profiles contributed by security researchers to identify potential vulnerabilities in web applications. This guide provides an in-depth look into its features, configuration, and usage best practices.
Important Notices:
Active Development: GBounty is actively maintained. Breaking changes may occur with new releases. Always review the release changelog before updating.
Standalone Usage: GBounty is primarily intended as a standalone CLI tool. Running it as a service may pose security risks. Ensure additional security measures are in place.
Installation
Using Go
GBounty requires Go v1.21 or later for installation. Run the following command to install the latest development version:
Using Pre-Compiled Binaries
Navigate to the GitHub Releases page and download the latest binary for your operating system (Linux, macOS, or Windows) and architecture (e.g., amd64, arm64). Extract and make the binary executable:
Other Installation Methods
Currently, GBounty does not support package managers like Homebrew, Snap, Choco, or Docker. Contributions to add these are welcome.
Command Syntax
Flags allow customization of GBounty’s behavior. They are categorized into:
Global Flags
Target Input
Request Customization
Profile Management
Runtime Options
Output Options
Debugging Options
Global Flags
-h
,--help
: Display help information.--update
: Update both the binary and profiles to the latest version.--update-app
: Update the binary only.--update-profiles
: Update profiles only.--force-update-profiles
: Force re-download of profiles.--check-updates
: Force a check for updates, overriding the daily check.
Target Input Flags
Specifying Target URLs
-u
,--url
: Define one or more target URLs.-uf
,--urls-file
: Provide a file with one target URL per line.
Using Request Templates
-rf
,--requests-file
: Use a zipped file containing raw request templates.-rr
,--raw-request
: Specify raw request files for detailed crafting.Example of a raw request file:
Note: The first line must include the domain and protocol (e.g.,
https://example.com
).
Parameter-Based Scanning
The Parameter-Based Scanning feature allows GBounty to dynamically construct requests based on a set of parameters. This is especially useful for testing multiple parameter combinations efficiently.
-pf
,--params-file
: Specify a file containing parameters. Each line in the file should represent one parameter to be included in the scan. Example file:-ps
,--params-split
: Define the number of parameters to include per request group (default: 10). Set to1
to test each parameter individually.-pm
,--params-method
: Specify the HTTP method to be used when sending parameters. Options areGET
(appended to the URL) orPOST
(included in the body).-pe
,--params-encoding
: Specify the encoding format for parameters. Options:url
: Parameters encoded asapplication/x-www-form-urlencoded
.json
: Parameters encoded asapplication/json
(requiresPOST
method).
Example usage:
This command tests parameters from params.txt
in groups of 5, using the POST method with JSON encoding.
Enforcing Protocols
-h2
,--http2
: Force HTTP/2 usage, ignoring any protocol specified in request templates.
Request Customization Options
HTTP Methods and Headers
-X
,--method
: Override the default HTTP method (e.g.,GET
,POST
).-H
,--header
: Add custom headers to requests. Example:
Request Body Data
-d
,--data
: Specify body data for requests.
Profile Management Options
Loading Profiles
-p
,--profiles
: Specify directories or files containing profiles. Example:
Tag-Based Filtering
-t
,--tag
: Use profiles tagged with specific keywords. Example:--print-tags
: Display all available tags in the specified profiles.
Active and Passive Scans
--only-active
: Use only active profiles.--only-passive
: Use only passive profiles.--only-passive-req
: Use only request-based passive profiles.--only-passive-res
: Use only response-based passive profiles.--only-poc
: Only output matched requests; suppress other details.
Runtime Options
Concurrency and Rate Limits
-c
,--concurrency
: Sets the number of URLs to scan concurrently. The default is 10.-r
,--rps
: Limits the number of requests per second per URL. The default is 10.
Match and Output Control
--stop-at-first-match
,-safm
: Stops scanning a specific profile, step, or entry point once a match is found.--silent
,-s
: Suppresses all output to the terminal.
Scan State Management
-sos
,--save-on-stop
: Saves the scan state when interrupted, allowing it to resume later.-f
,--from
: Resumes a scan from a saved state using its identifier.-m
,--in-memory
: Stores scan data in memory instead of on disk for faster performance.
Interaction Hosts
--blind-host
,-bh
: Specifies a host for interaction-based vulnerabilities (e.g., blind XSS).--email-address
,-email
: Injects an email address into{EMAIL}
labels.
Proxy Settings
--proxy-address
: Routes all requests through a specified proxy server.--proxy-auth
: Adds authentication credentials for the proxy server:
Output Options
File Formats
-o
,--output
: Specifies the path and name for the output file.-j
,--json
: Saves the output in JSON format.-md
,--markdown
: Saves the output in Markdown format.
Detailed Results
-a
,--all
: Includes all requests and responses in the output.--all-requests
,-areq
: Includes all requests, even those that didn’t cause matches.--all-responses
,-ares
: Includes all responses, even if no vulnerabilities are found.--show-errors
,-se
: Includes failed requests in the output.--show-responses
,-sr
: Displays responses for matched requests in the output.--stream-errors
,-ste
: Streams failed requests live during the scan.--stream-matches
,-stm
: Streams matched requests live during the scan (enabled by default).
Debugging Options
-v
,--verbose
: Logs warnings and errors.-vv
,--verbose-extra
: Adds informational logs.-vvv
,--verbose-all
: Enables full debug logging, including warnings, errors, and info.--verbose-output
: Saves logs to a file.
Dynamic Labels
GBounty supports dynamic placeholders for flexible profile configuration. Examples:
Label
Description
{BH}
Interaction host specified with -bh
.
{EMAIL}
Email address specified with -email
.
{CURRENT_URL}
Entire original URL request.
{CURRENT_PORT}
Original request web server port.
{CURRENT_PATH}
Original request path.
{CURRENT_HOST}
Original request host.
{CURRENT_METHOD}
Original request method (e.g., GET, POST).
{CURRENT_QUERY}
Original POST data query.
{CURRENT_SUBDOMAIN}
Original request subdomain (e.g., www).
{CURRENT_FILE}
Original request file.
{CURRENT_PROTOCOL}
Original request protocol (http/https).
{CURRENT_USER_AGENT}
Original User-Agent header value.
{CURRENT_REFERER}
Original Referer header value.
{CURRENT_ORIGIN}
Original Origin header value.
{CURRENT_ACCEPT}
Original Accept header value.
{CURRENT_CONTENT_TYPE}
Original Content-Type header value.
{CURRENT_ACCEPT_LANGUAGE}
Original Accept-Language header value.
{CURRENT_ACCEPT_ENCODING}
Original Accept-Encoding header value.
{CURRENT_CONTENT_LENGTH}
Original Content-Length header value.
Examples
Simple URL Scan
Batch Scanning
POST Request with Custom Data
Proxies and Advanced Scans
Additional Resources
Profiles Repository: GBounty profiles can be found here.
License: GBounty is distributed under the MIT License.
Last updated