VKO GOST R 34.10-2001 was described in RFC4357 Page 7 But the description is very poor. Here it is:
This algorithm creates a key encryption key (KEK) using 64 bit UKM, the sender's private key, and the recipient's public key (or the reverse of the latter pair).
- Let $K(x,y,UKM) = ((UKM*x)(mod q)) . (y.P)$ (512 bit), where
$x$ - sender's private key (256 bit)
$x.P$ - sender's public key (512 bit)
$y$ - recipient's private key (256 bit)
$y.P$ - recipient's public key (512 bit)
$UKM$ - non-zero integer, produced as in step 2 p. 6.1 [GOSTR341001]
$P$ - base point on the elliptic curve (two 256-bit coordinates)
$UKM*x$ - $x$ multiplied by UKM as integers
$x.P$ - a multiple point
- Calculate a 256-bit hash of $K(x,y,UKM)$:
$KEK(x,y,UKM) = gostR3411 (K(x,y,UKM))$
Keypairs $(x,x.P)$ and $(y,y.P)$ MUST comply with [GOSTR341001].
This algorithm MUST NOT be used when $x.P = P, y.P = P$
I want to implement it. Would be great to get more detailed description of that alogirthm with standard values for all parameters, with several examples (to be used in testing my own implementation) of all intermediate and final values on both sides. Here’s an example of a great description for Signature Algorithm GOST R 34.10-2012 (PDF, Russian language).
There is an implementation in OpenSSL of VKO GOST “engines/ccgost/gost2001_keyx.c”, but I'm not familiar with OpenSSL, so understanding of those functions internals is difficult for me. Maybe someone has at least some C++ (or any other language) implementation of VKO GOST key agreement algorithm (could be through OpenSSL) so that I can run it and get golden test values for testing my own implementation.
I just finished with implementing my own Big Integer C++ library with elliptic curves support. I've implemented Key Agreement from RFC4357 and surprisingly it works! You get the same$ K(x, y, UKM)$ on both sides while only sharing public keys and UKM between both parties.
Just found a nice description of VKO GOST in the next document Using cryptographic algorithms related to GOST R 34.10/11-2012 (PDF, Russian language). It has reference examples of computing shared key $K(x, y, UKM)$ after hashing it with Hash GOST R 34.11-2012.
Still looking for real detailed standards with real values. Maybe some other Key Agreement standards that are well used in Russia or related to GOST R 34.10 standard.