GithubHelp home page GithubHelp logo

scl-metal's Introduction

SCL - SiFive Cryptographic Library

scl-metal provides a bridge between a high level API for the cryptographic functions and basic crypto operations, that could be either a software or a hardware implementation of cryptographic functions

The current version implements the basic functions operations connected to the HCA (Hardware Cryptographic Accelerator). It supports the AES through the HCA-supported modes of operation, the SHA-2 and the TRNG.

For AES it supports:

  • key size: 128, 192 and 256 bits
  • mode ECB, CBC, CFB, OFB, CTR, CCM and GCM

For SHA-2, it supports:

  • SHA224, SHA256, SHA384 and SHA512

Supports the HCA version 0.5.x

ECDSA signature and verification are supported: - for standard curves SECP256r1, SECP384r1 and SECP521r1

Warning:

Local variable cleaning is not done yet, therefore it's not secure to use the library for cryptographic signature, but it's safe to use signature verification. A cleaning mechanism will be added in the future.

Optimization

Computation speed can be improved by placing crypto_const_data section/symbol into RAM. This avoid Flash access and speed up computation (on ecdsa). Placing crypto_const_data in RAM should be done with special care (Security issues if constant are modified). Reserving a non writable/executable section protected by PMP might be a good idea. This is only an improvment if the rodata are located in Flash.

Standalone download

git clone --recursive https://github.com/sifive/scl-metal.git

The --recursive option is required to clone the git submodules included in the repository. If at first you omit the --recursive option, you can achieve the same effect by updating submodules using the command:

In case the test framework reference have been updated (which should not occur very often)

git submodule update --init --recursive

scl-metal's People

Contributors

phmoussay avatar sifive-eblot avatar e-puerto avatar nategraff-sifive avatar ygaude avatar bsousi5 avatar yloisel 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.