> For the complete documentation index, see [llms.txt](https://www.impacket.wiki/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.impacket.wiki/readme.md).

# README

An introduction to the documentation, the Impacket project and useful references

## impacket.wiki

### About This Documentation

Impacket is, without a doubt, one of the most starred and widely deployed offensive security toolkits in the world. Yet for a library this established and this core to the field, its documentation has never quite kept pace with the code itself.

What I want this project to be is a place operators who *hack* with the tool, developers who want to write example scripts against the library, and engineers looking to import it into their own projects can all come to and find whatever information they actually need — instead of reverse-engineering it from the source every time.

A quick note of honesty: these docs are very much a work in progress. Impacket has been in active development for **over two decades** — its roots go all the way back to the early 2000s under Core Security — so there is a *lot* of surface area to cover. As the sole person writing this documentation, it takes a fair amount of time to work my way through the codebase and document it meticulously. So please bear with me as it fills out : )

### What is Impacket?

Impacket is a collection of Python classes for working with network protocols. It's focused on providing low-level, programmatic access to packets, and for some protocols, like SMB1-3 and MSRPC, the implementation of the protocol is provided.

The library also ships a set of example tools that act as a sort of demonstration of what you can build on top of it, these are the `secretsdump`, `psexec`, `wmiexec`, `GetUserSPNs` and friends that most people first meet Impacket through. While useful, you would be missing out on alot by not exploring the actual code base and leveraging it for your own needs!

Impacket was originally created by SecureAuth and is now maintained by Fortra's Core Security. It's released under a slightly modified version of the Apache Software License.

### Supported Protocols

At a high level, Impacket covers:

* **Link / network layer:** Ethernet, Linux "Cooked" capture, and IP, TCP, UDP, ICMP, IGMP, ARP — with both IPv4 and IPv6 support.
* **SMB / NetBIOS:** NMB and SMB1, plus high-level implementations of SMB2 and SMB3.
* **MSRPC:** version 5, over several transports — TCP, SMB/TCP, SMB/NetBIOS, and HTTP.
* **Authentication:** Plain, NTLM, and Kerberos,  using passwords, hashes, tickets, or keys. Note that soon certificate/PKINIT support will be added by yours truly : )&#x20;
* **MSRPC interfaces (full or partial):** EPM, DTYPES, LSAD, LSAT, NRPC, RRP, SAMR, SRVS, WKST, SCMR, BKRP, DHCPM, EVEN6, MGMT, SASEC, TSCH, DCOM, WMI, OXABREF, NSPI, OXNSPI, RAA, CAPR
* **Databases / directory:** portions of TDS (MSSQL) and LDAP.

### Installing Impacket

`pipx` over `pip` for system-wide installs, since it keeps Impacket and its example scripts isolated from the rest of your Python environment. I always recommend using uv however

**Latest stable release (recommended):**

```bash
pipx install impacket
```

**From source (development version):**

```bash
git clone https://github.com/fortra/impacket.git
cd impacket
python3 -m pip install .
```

You may find complete and thorough installation directions on the following link: <https://fortra-impacket.mintlify.app/installation>

### Useful Links

* **Source (Fortra / Core Security):** <https://github.com/fortra/impacket>
* **PyPI package:** <https://pypi.org/project/impacket/>
* **Core Security project page:** <https://www.coresecurity.com/core-labs/impacket>
* **RPC Developer Guide:** [**https://cicada-8.medium.com/impacket-developer-guide-part-1-rpc-4df4fe6d79d7**](https://cicada-8.medium.com/impacket-developer-guide-part-1-rpc-4df4fe6d79d7)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://www.impacket.wiki/readme.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
