Hello

From google code view I got some code and fall in shock.

Taken from http://www.minix3.org/software/ libmcrypt-2.5.7.tar.bz2/ libmcrypt-2.5.7/ modules/ algorithms/

So it is 2.5.7 version;

Take a look on first S-Box:

static unsigned char const gost_k1[16] = {

1, 15, 13, 0, 5, 7, 10, 4, 9, 2, 3, 14, 6, 11, 8, 2 };

Do you really think, that it is an permutation? I get "2" twice in this line and no "12";

Right S-Box (from wikipedia or http://www.cryptocom.ru/ OpenSource/ engine-gost-20061220.tar.gz/ engine-gost-20061220/ --> GostR3411_94_TestParamSet first line ) IS

1, 15, 13, 0, 5, 7, 10, 4, 9, 2, 3, 14, 6, 11, 8, 12 <-- !!!

-- Alex V Breger

Done as part of Information Security Course in MIPT (Moscow Institute of Physics And Technology) -- re.mipt.ru