Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 Makefile
Octocat-spinner-32 README.rst
Octocat-spinner-32 consumer.py
Octocat-spinner-32 response.proto
Octocat-spinner-32 tokencrypto.cpp
Octocat-spinner-32 tokencrypto.h
Octocat-spinner-32 worker.cpp
README.rst

Crypto library for the token server

This repository contains a library which is used on the token server to deal with crypto related things.

This is done in C++ to be able to deal with multiple processors at the same time, and to have the best possible performances. The underlying library is a patched version of Crypto++, with added code to deal with HKDF derivation.

When you compile the library, it generates a library and an executable binary. The binary is meant to run with powerhose, and the exchanged messages are encoded using protocol buffers.

How to run it?

To run this code, you need to compile it. First, make sure that you have the right version of Crypto++. What we are doing here is generating a derivated secret from a key, using the HKDF algorithm provided by the patched version of Crypto++.

Then, make sure you have the right libraries to run the project. You need to install powerhose on your system and compile it. Once done that, running make should be enough for building the code able to spawn the processes:

make serve&

You also need to start a consumer for this lib. This code ships with a python consumer. You need to have the pyzmq library installed as well as powerhose. If everything is correct, then you can run the consumer by doing

make consume
Something went wrong with that request. Please try again.