All Projects → julijonas → apdu-intercept

julijonas / apdu-intercept

Licence: other
Smartcard APDU interception and MITM for one smartcard model

Programming Languages

python
139335 projects - #7 most used programming language
TeX
3793 projects
C++
36643 projects - #6 most used programming language
CMake
9771 projects

Projects that are alternatives of or similar to apdu-intercept

APDUPlay
PC/SC inspection and manipulation tool
Stars: ✭ 41 (+24.24%)
Mutual labels:  smartcard, apdu
oseid
Microchip AVR based smartcard/token with ECC and RSA cryptography
Stars: ✭ 17 (-48.48%)
Mutual labels:  smartcard, apdu
Sslproxy
Transparent SSL/TLS proxy for decrypting and diverting network traffic to other programs, such as UTM services, for deep SSL inspection
Stars: ✭ 134 (+306.06%)
Mutual labels:  mitm
cie-middleware
Middleware della CIE (Carta di identità elettronica)
Stars: ✭ 57 (+72.73%)
Mutual labels:  smartcard
Rebel Framework
Advanced and easy to use penetration testing framework 💣🔎
Stars: ✭ 183 (+454.55%)
Mutual labels:  mitm
Raw Packet
Raw-packet Project
Stars: ✭ 144 (+336.36%)
Mutual labels:  mitm
Bettercap
DEPRECATED, bettercap developement moved here: https://github.com/bettercap/bettercap
Stars: ✭ 2,518 (+7530.3%)
Mutual labels:  mitm
Mitmap
📡 A python program to create a fake AP and sniff data.
Stars: ✭ 1,526 (+4524.24%)
Mutual labels:  mitm
cie-middleware-linux
Middleware della CIE (Carta di Identità Elettronica) per Linux
Stars: ✭ 31 (-6.06%)
Mutual labels:  smartcard
Badssl.com
🔒 Memorable site for testing clients against bad SSL configs.
Stars: ✭ 2,234 (+6669.7%)
Mutual labels:  mitm
keycard-cli
A command line tool and shell to manage keycards
Stars: ✭ 42 (+27.27%)
Mutual labels:  smartcard
Awesome Mitm
Curated List of MitM frameworks on GitHub
Stars: ✭ 169 (+412.12%)
Mutual labels:  mitm
Shuttle
A web proxy in Golang with amazing features.
Stars: ✭ 1,857 (+5527.27%)
Mutual labels:  mitm
man-in-the-middle
Modify requests, inject JavaScript and CSS into pages
Stars: ✭ 74 (+124.24%)
Mutual labels:  mitm
Hoverfly
Lightweight service virtualization/API simulation tool for developers and testers
Stars: ✭ 1,814 (+5396.97%)
Mutual labels:  mitm
Awesome Hacking Resources
A collection of hacking / penetration testing resources to make you better!
Stars: ✭ 11,466 (+34645.45%)
Mutual labels:  mitm
Striptls
proxy poc implementation of STARTTLS stripping attacks
Stars: ✭ 163 (+393.94%)
Mutual labels:  mitm
Node Mitmproxy
node-mitmproxy is an extensible man-in-the-middle(MITM) proxy server for HTTP/HTTPS base on Node.js.
Stars: ✭ 203 (+515.15%)
Mutual labels:  mitm
Houki
🧹 Customizable MitM proxy / 可定制化的中间人代理
Stars: ✭ 28 (-15.15%)
Mutual labels:  mitm
G-Earth
Cross-platform Habbo packet manipulator
Stars: ✭ 52 (+57.58%)
Mutual labels:  mitm

APDU interception

This repository provides code for interception of smartcard application protocol data unit (APDU) commands by listening and responding to messages received by a virtual smartcard driver. It shows the hexadecimal traces in a hexdump format, logs them, colour-codes the APDU fields, prints the descriptions for the detected inter-industry commands and responses, and provides a hook to manipulate them.

It depends on the Virtual Smart Card library.

To collect APDU traces make sure the smartcard is inserted, pcscd is running, smartcard can be found in pcsc_scan. Then execute intercept.py using Python interpreter and use OpenSC, GnuPG, or your vendor's smartcard tools to perform operations on the smartcard.

To perform MITM attack, the method respond_to_message in a class inherited from InterceptAttack is the point where the attacker can issue commands and manipulate responses.

Virtual smartcard OS'es available using parameter --os:

  • RelayOS that relays messages to another smartcard reader specified by --reader.
  • GemaltoOS providing valid responses to authentication commands issued by Gemalto libgclib.so/libgck2015x.so Cryptoki libraries emulating Gemalto IDClassic 340.

Attack logic available using parameter --attack:

  • InterceptAttack that just prints the sniffed APDU traces to stdout and logs/date-time.log.
  • GemaltoMITMAttack that calculates parameters of secure messaging agreed between library and card.
  • YubikeyMITMAttack that intercepts GENERATE ASYMMETRIC KEY PAIR, puts the attackers private key on card, and returns corresponding public key.

The ISO inter-industry command/response descriptions are taken from the apdu-parser project.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].