Crypto Shield Hookup Guide

This Tutorial is Retired!

This tutorial covers concepts or technologies that are no longer current. It's still here for you to read and enjoy, but may not be as useful as our newest tutorials.

Pages
Contributors: jbdatko, CaseyTheRobot
Favorited Favorite 0

ATSHA204

alt text

The Atmel ATSHA204 is an authentication chip that performs SHA-256 and HMAC-256. It can store up to 16 secret keys that can be used for shared-secret authentication between two devices with an ATSHA204 or between a ATSHA204 and a remote server. It also can produce random numbers with its on-chip random number generator. The ATSHA204 on the CryptoCape is the I2C version of our Breakout Board version. It's also on the Electric Imp.

This chip, like the other crypto chips, is one-time-programmable. This means that once you run certain commands on the chip, it can not be reversed. This is a security feature.

NOTE

On version 2 of the CryptoShield this device is the older ATSHA204 and not the ATSHA204A.

Software

You have three options for software with this Chip.

  1. Use Atmel's AVR library with Atmel Studio.
  2. Use the Cryptotronix Arduino library (a Work In Progress)
  3. Use the Cryptotronix Linux user-space driver

Atmel's AVR Library

Atmel's ATSHA204 AVR Library page has links to their software.

Cryptotronix Linux driver

The linux driver, called hashlet, can be download here or cloned from GitHub. See the GitHub page for examples.

If you don't want to build this from source but want to use an ARM based Linux board, you can add the Cryptotronix debian repository debian.cryptotronix.com and then perform sudo apt-get upgrade && sudo apt-get install hashlet.

The Linux driver is the easiest option to use currently.

Cryptotronix Arduino library

A third option is to use the Cryptotronix Arduino Library. For the ATSHA204, the software support is very limited. The goal of the library is to be a wrapper around the Atmel library to make using the ATSHA204 a bit easier to use. If you want to help, pull requests are welcome!