Skip to content

GOST R 34.10-2012 Key Agreement Function (RFC 7836)

License

Notifications You must be signed in to change notification settings

pedroalbanese/vko

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

VKO

ISC License GitHub downloads GoDoc Go Report Card GitHub go.mod Go version GitHub release (latest by date)

GOST R 34.10-2012 VKO (выработка ключа общего)

VKO is an elliptic curve Diffie-Hellman key agreement function using GOST R 34.10-2012. It allows two parties to jointly agree on a shared secret using an insecure channel.

            Alice                            Bob
            -----                            ---
      choose private key:             choose private key:
             d_A                             d_B
              |                               |
              v                               v
      compute public key:             compute public key:
    Q_A = d_A * BasePoint_TE        Q_B = d_B * BasePoint_TE
              |                               |
              v                               v
          ------- Begin Key Exchange Phase -------
              |                               |
              v                               v
     compute shared secret:          compute shared secret:
S_A = d_A * Q_B + d_A * BasePoint S_B = d_B * Q_A + d_B * BasePoint
              |                               |
              v                               v
          -------- End Key Exchange Phase --------
              |                               |
              v                               v
            (S_A)                           (S_B)

Command-line VKO Tool:

Usage of vko:
  -key string
        Our private key.
  -keygen
        Generate keypair.
  -paramset string
        ParamSet: A, B, C or D. (default "A")
  -pub string
        Remote's side public key.

Examples:

./vko -keygen // 2x
./vko -key $2ndprivatekey -pub $1stpublickey
./vko -key $1stprivatekey -pub $2ndpublickey

License

This project is licensed under the ISC License.

Copyright (c) 2020-2021 Pedro Albanese - ALBANESE Research Lab.

About

GOST R 34.10-2012 Key Agreement Function (RFC 7836)

Topics

Resources

License

Security policy

Stars

Watchers

Forks

Packages

No packages published

Languages