hacktricks-mcp

v0.5.7
io.github.zebbern/hacktricks-mcp Checked 2 hours ago Published 14 hours ago

Offline HackTricks and HackTricks Cloud search, permissions check, payload and cheatsheet lookups.

A 96/100 Discovery passed License not confirmed SearchCloud

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

hacktricks_get_page Read HackTricks Page

Retrieve content of a HackTricks page found via hacktricks_search. For a long page, start with outlineOnly=true to list its sections with their sizes, then use section= to read one section by heading name, or codeOnly=true to get just the commands/payloads; a code block that antivirus software flags comes back as a note with the page's link. A short page (the search result shows its size) can be read whole. Text comes in slices of up to 20,000 characters, each ending at the end of a line; a cut slice ends with the offset where the rest continues.

ParameterTypeDescription
path *stringPage path from hacktricks_search (e.g. 'windows-hardening/active-directory-methodology/kerberoast.md'). The ending of a path and a file name without .md also work ('kerberoast', 'ntlm/README.md'); whe…
bookstringBook to read from. Only matters for the few paths that exist in both books, such as README.md; the default is "hacktricks".
codeOnlybooleanIf true, return only the fenced code blocks (commands/payloads) of the page or section, each with its language and the label above it when the page gives one
offsetintegerSkip this many characters of the page or section. A truncated response ends with the offset where the rest continues.
outlineOnlybooleanIf true, return the headings with the size of each section instead of the content. Use it to choose a section before reading.
sectionstringOptional heading name to extract just that section. A heading with exactly that text is preferred, else the first whose text contains it; marks, footnote links and double spaces do not count. The answ…

hacktricks_get_toc HackTricks Table of Contents

Get the structure of both HackTricks books from their tables of contents. Call without arguments for the overview (each book's categories and chapters with page counts), or pass a filter to list the pages under the entries whose title contains it. Useful to see where a topic lives before searching.

ParameterTypeDescription
categorystringOptional text filter on entry titles, case-insensitive: a category to expand (e.g. 'Linux Hardening', 'Pentesting Cloud') or a topic to list (e.g. 'Kerberos', 'AWS', 'GitHub Actions'). Omit for the ov…

hacktricks_cloud_permissions Check Cloud Permissions

Check cloud permissions against HackTricks Cloud. Give the permissions a principal holds and get each one's rating (critical, high, medium, low) from the book's rated list, the combination rules they complete, and every escalation technique in the book's catalog whose required permissions are all held, with the page section that explains each. Use it for questions like 'is this permission dangerous?', 'what can I do with these permissions?' or 'which of these permissions should I remove?'. Resources, scopes and request conditions are not evaluated, so read a technique's conditions and its page…

ParameterTypeDescription
permissions *arrayThe permissions held, as the cloud writes them: "iam:PassRole", "iam.serviceAccounts.actAs", "Microsoft.Authorization/roleAssignments/write", "Application.ReadWrite.All". Wildcards as in a policy ("ia…
provider *stringThe cloud: "aws", "gcp", "azure" or "k8s"
limitintegerHow many escalation techniques to list at most (default 20); the total is always reported

payloads_topics Payload Collections Map

The map of two payload collections: Payloads All The Things, a topic per attack type with its pages and ready-made files (payload lists, bypass files, polyglots), and SecLists, wordlists and webshells by use, listed with their sizes and download links; a webshell is listed in both, never held as text. Read it once to see what exists; a filter word narrows it to the topics and folders whose name, description or file names contain it. It takes a word, not a question. Read a topic, folder or file with payloads_get.

ParameterTypeDescription
filterstringOptional word that a topic's or folder's name, description or file names must contain, case-insensitive (e.g. 'upload', 'password', 'shell'). Omit for the whole map, about 16,000 characters.
sourcestringCollection: "payloads" for Payloads All The Things, "seclists" for SecLists. Only needed when both have what you pass.

payloads_get Read a Payload Topic, Page or File

Read one thing of the payload collections by name or by path. A topic by name ('SQL Injection', 'upload', 'jwt') lists its pages, its files and the sections of its README; a folder of SecLists ('Passwords/Default-Credentials') lists its wordlists with sizes; a page is read whole, in one section or as its code blocks; a text file of Payloads All The Things (a bypass file, a payload list, a polyglot) comes back as written, ready to be saved under its name; a webshell or other server-side program (in either collection), a file antivirus software flags, a wordlist or a binary file comes back with…

ParameterTypeDescription
target *stringA topic by name ("SQL Injection", "upload"), a folder ("Passwords/Default-Credentials", "Web-Shells"), a page ("SQL Injection/README.md") or a file ("Web-Shells/PHP/php-backdoor.php"), as the map and…
codeOnlybooleanFor a page, or for a topic (its README): only the fenced code blocks (commands and payloads).
offsetintegerSkip this many characters of a long text. A truncated response ends with the offset where the rest continues.
outlineOnlybooleanFor a page, or for a topic (its README): the headings with the size of each section instead of the content.
sectionstringFor a page, or for a topic (its README): the heading of the one section to read. A heading with exactly that text is preferred, else the first whose text contains it.
sourcestringCollection: "payloads" for Payloads All The Things, "seclists" for SecLists. Only needed when both have what you pass.

internal_get Read an Internal All The Things Page

Read a cheatsheet or playbook of Internal All The Things by its name: 'reverse shell', 'amsi bypass', 'ESC8', 'S3 buckets', 'Cobalt Strike', 'MSSQL command execution', 'GitHub Actions'. The name of a folder or an area ('aws', 'azure', 'evasion', 'cloud') lists its pages; no target returns the map of the collection (shells, PowerShell, Mimikatz, Active Directory with the certificate attacks ESC1 to ESC15, AWS and Azure checklists, C2 frameworks, red team access, evasion, persistence, CI/CD attacks). A page is read whole, as its outline, in one section or as its code blocks. A name that several…

ParameterTypeDescription
codeOnlybooleanFor a page: only the code blocks (commands and payloads).
offsetintegerSkip this many characters of a long page. A truncated response ends with the offset where the rest continues.
outlineOnlybooleanFor a page: the headings with the size of each section instead of the content.
sectionstringFor a page: the heading of the one section to read. A heading with exactly that text is preferred, else the first whose text contains it.
targetstringA page by its title ("Windows - AMSI Bypass", "Reverse Shell Cheat Sheet") or by words its title has ("reverse shell", "esc8"); a folder ("cloud/aws", "redteam/evasion") or an area ("active-directory"…