2018-10-07 00:16:23 +02:00
2018-10-07 00:16:23 +02:00
2018-10-07 00:16:23 +02:00
2018-10-07 00:16:23 +02:00
2018-10-07 00:16:23 +02:00
2018-10-07 00:16:23 +02:00
2018-10-07 00:16:23 +02:00
2018-07-21 12:38:15 +02:00
2018-10-07 00:16:23 +02:00

cryptofun Go Report Card

Crypto algorithms from scratch. Academic purposes only.

RSA

https://en.wikipedia.org/wiki/RSA_(cryptosystem)#

  • GenerateKeyPair
  • Encrypt
  • Decrypt
  • Blind
  • Blind Signature
  • Unblind Signature
  • Verify Signature
  • Homomorphic Multiplication

Paillier

https://en.wikipedia.org/wiki/Paillier_cryptosystem

  • GenerateKeyPair
  • Encrypt
  • Decrypt
  • Homomorphic Addition

Shamir Secret Sharing

https://en.wikipedia.org/wiki/Shamir%27s_Secret_Sharing

  • create secret sharing from number of secrets needed, number of shares, random point p, secret to share
  • Lagrange Interpolation to restore the secret from the shares

Diffie-Hellman

https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange

  • key exchange

ECC

https://en.wikipedia.org/wiki/Elliptic-curve_cryptography

  • define elliptic curve
  • get point at X
  • get order of a Point on the elliptic curve
  • Add two points on the elliptic curve
  • Multiply a point n times on the elliptic curve

ECC ElGamal

https://en.wikipedia.org/wiki/ElGamal_encryption

  • ECC ElGamal key generation
  • ECC ElGamal Encrypton
  • ECC ElGamal Decryption

ECC ECDSA

https://en.wikipedia.org/wiki/Elliptic_Curve_Digital_Signature_Algorithm

  • define ECDSA data structure
  • ECDSA Sign
  • ECDSA Verify signature

Schnorr signature

https://en.wikipedia.org/wiki/Schnorr_signature

  • Hash[M || R] (where M is the msg bytes and R is a Point on the ECC, using sha256 hash function)
  • Generate Schnorr scheme
  • Sign
  • Verify signature

Bn128

[not finished]

This is implemented followng the implementations and info from:


To run all tests:

go test ./... -v
Description
No description provided
Readme GPL-3.0 121 KiB
Languages
Go 100%