GithubHelp home page GithubHelp logo

hartl3y94 / impacket Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fortra/impacket

0.0 0.0 0.0 6.44 MB

Impacket is a collection of Python classes for working with network protocols.

License: Other

Python 99.91% Shell 0.09% Batchfile 0.01% Dockerfile 0.01%

impacket's Introduction

What is Impacket?

Impacket is a collection of Python classes for working with network protocols. Impacket is focused on providing low-level programmatic access to the packets and for some protocols (e.g. SMB1-3 and MSRPC) the protocol implementation itself. Packets can be constructed from scratch, as well as parsed from raw data, and the object oriented API makes it simple to work with deep hierarchies of protocols. The library provides a set of tools as examples of what can be done within the context of this library.

A description of some of the tools can be found at: https://www.secureauth.com/labs/open-source-tools/impacket

What protocols are featured?

  • Ethernet, Linux "Cooked" capture.
  • IP, TCP, UDP, ICMP, IGMP, ARP.
  • IPv4 and IPv6 Support.
  • NMB and SMB1, SMB2 and SMB3 (high-level implementations).
  • MSRPC version 5, over different transports: TCP, SMB/TCP, SMB/NetBIOS and HTTP.
  • Plain, NTLM and Kerberos authentications, using password/hashes/tickets/keys.
  • Portions/full implementation of the following MSRPC interfaces: EPM, DTYPES, LSAD, LSAT, NRPC, RRP, SAMR, SRVS, WKST, SCMR, BKRP, DHCPM, EVEN6, MGMT, SASEC, TSCH, DCOM, WMI, OXABREF, NSPI, OXNSPI.
  • Portions of TDS (MSSQL) and LDAP protocol implementations.

Getting Impacket

Setup

Quick start

Grab the latest stable release, unpack it and run pip3 install . (pip install . for Python 2.x) from the directory where you placed it. Isn't that easy?

Requirements

  • A Python interpreter. Python 2.6/2.7 and Python 3.7 are known to work.
    1. If you want to run the examples and you have Python < 2.7, you will need to install the argparse package for them to work.
    2. For Kerberos support you will need pyasn1 package
    3. For cryptographic operations you will need pycryptodomex package
    4. For some examples you will need pyOpenSSL (rdp_check.py) and ldap3 (ntlmrelayx.py)
    5. For ntlmrelayx.py you will also need ldapdomaindump, flask and ldap3
    6. If you're under Windows, you will need pyReadline
  • A recent release of Impacket.

Installing

In order to install the source execute the following command from the directory where the Impacket's distribution has been unpacked: pip3 install . (pip install . for Python 2.x). This will install the classes into the default Python modules path; note that you might need special permissions to write there.

Testing

If you want to run the library test cases you need to do mainly three things:

  1. Install and configure a Windows 2012 R2 Domain Controller.
    • Be sure the RemoteRegistry service is enabled and running.
  2. Configure the dcetest.cfg file with the necessary information
  3. Install tox (pip3 install tox)

Once that's done, you can run tox and wait for the results. If all goes well, all test cases should pass. You will also have a coverage HTML report located at impacket/tests/htlmcov/index.html

Support Docker

Build Image Impacket To create image

docker build -t "impacket:latest" .

Using Impacket

docker run -it --rm "impacket:latest"

Licensing

This software is provided under under a slightly modified version of the Apache Software License. See the accompanying LICENSE file for more information.

SMBv1 and NetBIOS support based on Pysmb by Michael Teo.

Disclaimer

The spirit of this open source initiative is hopefully to help the community to alleviate some of the hindrances associated with the implementation of networking protocols and stacks, aiming at speeding up research and educational activities. By no means this package is meant to be used in production environments / commercial products. If so, we would advise to include it into a proper SDLC process.

Contact Us

Whether you want to report a bug, send a patch or give some suggestions on this package, drop us a few lines at [email protected].

impacket's People

Contributors

0xdeaddood avatar 0xsauby avatar adamcrosser avatar asolino avatar c0d3z3r0 avatar cclauss avatar cnotin avatar contactr2m avatar cube0x0 avatar dirkjanm avatar exploide avatar franferrax avatar g0ldengunsec avatar gifts avatar kacpern avatar machosec avatar martingalloar avatar martinuy avatar mgeeky avatar mlefebvre avatar mohemiv avatar mrande7son avatar rcarnus avatar rdubourguais avatar real-datagram avatar rmaksimov avatar ropnop avatar rxwx avatar snovvcrash avatar tshmul avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.