Skip to main content

tool to perform differential fault analysis attacks (DFA) against SM4

Project description

phoenixSM4: a tool to perform differential fault analysis attacks (DFA) against SM4

Currently phoenixSM4 contains the following combined attacks:

Installation

There is no dependencies, it requires only Python 3.

python3 -m pip install phoenixSM4

Usage

It takes a file of recorded outputs, optionally preceded by inputs (which will be ignored). First record must be with the correct output, to be used as reference.

#!/usr/bin/env python
import phoenixSM4

with open('tracefile', 'wb') as t:
    t.write("""
09325c4853832dcb9337a5984f671b9a
c8141f5697ac1e7021f567e84f671b92
dcfa486ad93d750d4950c2254f671b1a
05f91951f692aee2bca07947d3e1aeec
ab3854a661620285448b8ccd0fda1609
""".encode('utf8'))

phoenixSM4.crack_file('tracefile')
Round key 32 found:
12A02491
Round key 31 found:
E572CF01
Round key 30 found:
96342962
Round key 29 found:
54368D42
[2435096594, 30372581, 1646867606, 1116550740]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

phoenixSM4-0.0.1.tar.gz (18.2 kB view details)

Uploaded Source

Built Distribution

phoenixSM4-0.0.1-py3-none-any.whl (18.7 kB view details)

Uploaded Python 3

File details

Details for the file phoenixSM4-0.0.1.tar.gz.

File metadata

  • Download URL: phoenixSM4-0.0.1.tar.gz
  • Upload date:
  • Size: 18.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.7

File hashes

Hashes for phoenixSM4-0.0.1.tar.gz
Algorithm Hash digest
SHA256 a9e1010795a9f7a413f06ca3f180d7b1a8d2301a68706deceaba65ab0213add3
MD5 0b28db1cdfb1d2a3ad8372f10ee47bb8
BLAKE2b-256 206bf9c013c628bb4ab4ce569aa59f5f4af8402e9504367f44b0460291f47fb0

See more details on using hashes here.

File details

Details for the file phoenixSM4-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: phoenixSM4-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 18.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.7

File hashes

Hashes for phoenixSM4-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4201d2a9b2436d55d65c7e351a4af412b9e06b728f6c4315b340ed6b45deac58
MD5 e28c7dbb57ffc0f896dc8c53097e4ed1
BLAKE2b-256 d9a8490a430e3e747924b4dd2911c303916e32ba7eec842d0f179e924a442d4f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page