Skip to main content

SCAred

pipeline status PyPI version Conda installer Latest Conda release

scared is a side-channel analysis framework maintained by eShard team.

Getting started

Requirements

Scared need python 3.11, 3.12 or 3.13 and Numpy>=2

You can install scared, depending on your setup:

  • from source
  • with pip
  • with conda

Install with conda

You just have to run:

conda install -c eshard scared

Install with pip

Python wheels are available from Pypi, just run:

pip install scared

Install from sources

To install from sources, you will need to run:

pip install .

from the source folder.

If you are planning to contribute, see CONTRIBUTING.md to install the library in development mode and run the test suite.

Make a first cool thing

Start using scared by doing a cool thing:

# First import the lib
import scared
import numpy as np

# Define a selection function
@scared.attack_selection_function
def first_add_key(plaintext, guesses):
    res = np.empty((plaintext.shape[0], len(guesses), plaintext.shape[1]), dtype='uint8')
    for i, guess in enumerate(guesses):
        res[:, i, :] = np.bitwise_xor(plaintext, guess)
    return res

# Create an analysis CPA
a = scared.CPAAttack(
        selection_function=first_add_key,
        model=scared.HammingWeight(),
        discriminant=scared.maxabs)

# Load some traces, for example a dpa v2 subset
ths = scared.traces.read_ths_from_ets_file('dpa_v2.ets')

# Create a container for your ths
container = scared.Container(ths)

# Run!
a.run(container)

Documentation

To go further and learn all about scared, please go to the full documentation. You can also have an interactive introduction to scared by launching these notebooks with Binder.

Contributing

All contributions, starting with feedbacks, are welcomed. Please read CONTRIBUTING.md if you wish to contribute to the project.

License

This library is licensed under LGPL V3 license. See the LICENSE file for details.

It is mainly intended for non-commercial use, by academics, students or professional willing to learn the basics of side-channel analysis.

If you wish to use this library in a commercial or industrial context, eShard provides commercial licenses under fees. Contact us!

Authors

See AUTHORS for the list of contributors to the project.

Binary builds available

Binary builds (wheels on pypi and conda builds) are available for the following platforms and Python version.

Platforms:

  • Linux x86 64
  • Macosx x86 64

Python version:

  • 3.11
  • 3.12
  • 3.13

Metadata

Release files for scared 1.2.13

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for scared 1.2.13
File Size Uploaded
scared-1.2.13.tar.gz 60.4 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for scared 1.2.13
File Interpreter ABI Platform
scared-1.2.13-py3-none-any.whl Python 3 none any Details

Total release size: 60.5 MB

Release files / scared-1.2.13.tar.gz

Download URL scared-1.2.13.tar.gz
Size 60.4 MB
Tags Source
SHA-256 checksum
How to use checksums
4e48d28686ca91d096d54f8b2cad3e6be2f298e250c7310ab63dfa829a8c2442
BLAKE2b-256 checksum
How to use checksums
b1a757c777b334731240ccdf82c11c5d2feeba628091186f27bd7bd2c90a85f0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Release files / scared-1.2.13-py3-none-any.whl

Download URL scared-1.2.13-py3-none-any.whl
Size 109.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
019cee9984f7c59bc22cfffd00a27a4449121b02cea564487e05c4a95b6612f2
BLAKE2b-256 checksum
How to use checksums
bda88d586a403e8dd77eae6aac967badb10f6997acab13fa564f851b9dfa945c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.9

Release history Release notifications | RSS feed

This release

1.2.13 This release

2 release files

1.2.10

2 release files

1.2.9

2 release files

1.2.8

2 release files

1.2.7

2 release files

1.2.6

2 release files

1.2.5

2 release files

1.2.4

2 release files

1.2.3

2 release files

1.1.9

2 release files

1.1.8

2 release files

1.1.4

2 release files

1.1.2

2 release files

1.1.1

1 release file

1.1.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.9.1

1 release file

0.8.13

4 release files

0.8.12

4 release files

0.8.11

7 release files

0.8.10

7 release files

0.8.9

4 release files

0.8.8

7 release files

0.8.7

7 release files

0.8.6

7 release files

0.8.5

1 release file

0.8.4

1 release file

0.8.3

1 release file

0.8.2

1 release file

0.7.9

2 release files

0.7.8

2 release files

0.7.7

2 release files

0.7.6

2 release files

0.7.5

2 release files

0.7.4

2 release files

0.7.3

2 release files

0.7.2

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.0

2 release files

0.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page