Program Implementation of Cryptographic Primitives