{"id":188152,"date":"2013-07-29T10:14:03","date_gmt":"2013-07-29T06:14:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=188152"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=188152","title":{"rendered":"<span class=\"post_title\">\u0425\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u044f \u0421\u0442\u0440\u0438\u0431\u043e\u0433 \u0438\u043b\u0438 \u0432 \u0433\u043e\u0440\u043e\u0434\u0435 \u043d\u043e\u0432\u044b\u0439 \u0448\u0435\u0440\u0438\u0444<\/span>"},"content":{"rendered":"<div class=\"content html_format\">   \t<img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/24d\/da3\/fa1\/24dda3fa1befb4727294d515a26a25fd.jpg\" align=\"left\"\/>\u0412 2012 \u0433\u043e\u0434\u0443 \u0432\u0441\u044f \u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0441\u0442\u044c, \u0431\u043e\u043b\u0435\u0435 \u0438\u043b\u0438 \u043c\u0435\u043d\u0435\u0435 \u043f\u0440\u0438\u0447\u0430\u0441\u0442\u043d\u0430\u044f \u043a \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438, \u043f\u0440\u0438\u0441\u0442\u0430\u043b\u044c\u043d\u043e \u0441\u043b\u0435\u0434\u0438\u043b\u0430 \u0437\u0430 \u0432\u044b\u0431\u043e\u0440\u0430\u043c\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u0445\u0435\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 SHA-3. \u041d\u0430 \u0445\u0430\u0431\u0440\u0435 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0448\u0438\u0440\u043e\u043a\u043e \u043e\u0441\u0432\u0435\u0449\u0430\u043b\u043e\u0441\u044c \u044d\u0442\u043e \u0432\u0430\u0436\u043d\u043e\u0435 \u0441\u043e\u0431\u044b\u0442\u0438\u0435: \u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0440\u0430\u0443\u043d\u0434\u0430 \u043a\u043e\u043d\u043a\u0443\u0440\u0441\u0430(<a href=\"http:\/\/habrahabr.ru\/post\/109946\/\">\u0440\u0430\u0437<\/a>, ,<a href=\"http:\/\/habrahabr.ru\/post\/152136\/\">\u0434\u0432\u0430<\/a>, <a href=\"http:\/\/habrahabr.ru\/post\/153349\/\">\u0442\u0440\u0438<\/a>), \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u043b\u043e\u0441\u044c <a href=\"http:\/\/habrahabr.ru\/post\/159073\/\">\u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435<\/a> \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430, \u0438 \u0434\u0430\u0436\u0435 <a href=\"http:\/\/habrahabr.ru\/post\/168707\/\">\u043e\u0431\u044a\u044f\u0441\u043d\u044f\u043b\u043e\u0441\u044c<\/a> \u043f\u043e\u0447\u0435\u043c\u0443 \u043d\u043e\u0432\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0442\u0430\u043a \u043a\u0440\u0443\u0442. <br \/>  \u041e\u0434\u043d\u0430\u043a\u043e, \u0437\u0430 \u0432\u0441\u0435\u043c \u044d\u0442\u0438\u043c \u0430\u0436\u0438\u043e\u0442\u0430\u0436\u0435\u043c \u0441\u043e\u0432\u0441\u0435\u043c \u043d\u0435\u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u044b\u043c \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0434\u0440\u0443\u0433\u043e\u0435, \u043d\u0435 \u043c\u0435\u043d\u0435\u0435 \u0437\u043d\u0430\u0447\u0438\u043c\u043e\u0435 \u0441\u043e\u0431\u044b\u0442\u0438\u0435: 1 \u044f\u043d\u0432\u0430\u0440\u044f 2013 \u0433\u043e\u0434\u0430 \u0432 \u0420\u0424 \u0442\u0430\u043a\u0436\u0435 \u0441\u043c\u0435\u043d\u0438\u043b\u0441\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438. <br \/>  \u0418\u0442\u0430\u043a, \u0432\u0441\u0442\u0440\u0435\u0447\u0430\u0439\u0442\u0435: \u043f\u043e\u043b\u043d\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u0438 \u0435\u0433\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430 C#. \u041a\u0430\u043a \u0433\u043e\u0432\u043e\u0440\u0438\u0442\u0441\u044f, \u043b\u0443\u0447\u0448\u0435 \u043f\u043e\u0437\u0434\u043d\u043e, \u0447\u0435\u043c \u043d\u0438\u043a\u043e\u0433\u0434\u0430.<a name=\"habracut\"><\/a><\/p>\n<p>  \u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u043b\u0443\u0447\u0438\u043b \u043d\u043e\u043c\u0435\u0440 34.11-2012, \u0431\u044b\u043b\u0430 \u043f\u0440\u0438\u043d\u044f\u0442\u0430 \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u044f \u043f\u043e\u0434 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435\u043c \u0421\u0442\u0440\u0438\u0431\u043e\u0433. \u0421\u0442\u0440\u0438\u0431\u043e\u0433 \u2014 \u044d\u0442\u043e \u0441\u0435\u043c\u0435\u0439\u0441\u0442\u0432\u043e \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0439, \u0432\u043a\u043b\u044e\u0447\u0430\u044e\u0449\u0435\u0435 \u0432 \u0441\u0435\u0431\u044f \u0432\u0441\u0435\u0433\u043e \u0434\u0432\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438. \u0424\u0443\u043d\u043a\u0446\u0438\u044e \u0441 \u0434\u043b\u0438\u043d\u043e\u0439 \u0432\u044b\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432 256 \u0431\u0438\u0442 \u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u0441 \u0434\u043b\u0438\u043d\u043e\u0439 \u0432\u044b\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432 512 \u0431\u0438\u0442. \u041e\u0431\u0435 \u044d\u0442\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0438\u043c\u0435\u044e\u0442 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u0443\u044e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443 \u0438 \u043e\u0442\u043b\u0438\u0447\u0430\u044e\u0442\u0441\u044f \u0434\u0440\u0443\u0433 \u043e\u0442 \u0434\u0440\u0443\u0433\u0430 \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0430\u043b\u044c\u043d\u044b\u043c \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435\u043c. \u0412\u0445\u043e\u0434\u043d\u044b\u043c\u0438 \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0434\u043b\u044f \u043e\u0431\u043e\u0438\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0431\u043b\u043e\u043a \u0434\u0430\u043d\u043d\u044b\u0445 \u0434\u043b\u0438\u043d\u043e\u0439 512 \u0431\u0438\u0442.<\/p>\n<p>  \u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043f\u0440\u0438\u0441\u0442\u0443\u043f\u0430\u0442\u044c \u043a \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044e \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430, \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0435\u043c \u043e \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f\u0445, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u043f\u0440\u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0438 \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438.<\/p>\n<h4>\u041f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u044f<\/h4>\n<p>  <\/p>\n<ol>\n<li><b>X-\u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435.<\/b> \u041d\u0430 \u0432\u0445\u043e\u0434 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <b>X<\/b> \u043f\u043e\u0434\u0430\u044e\u0442\u0441\u044f \u0434\u0432\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0434\u043b\u0438\u043d\u043e\u0439 512 \u0431\u0438\u0442 \u043a\u0430\u0436\u0434\u0430\u044f, \u0432\u044b\u0445\u043e\u0434\u043e\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f XOR \u044d\u0442\u0438\u0445 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0435\u0439.<br \/>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/14e\/5a4\/e8b\/14e5a4e8b70e277b9a279ab6ac1009ce.png\"\/>\n<\/li>\n<li><b>S-\u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435.<\/b> \u0424\u0443\u043d\u043a\u0446\u0438\u044f <b>S<\/b> \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439 \u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438. \u041a\u0430\u0436\u0434\u044b\u0439 \u0431\u0430\u0439\u0442 \u0438\u0437 512-\u0431\u0438\u0442\u043d\u043e\u0439 \u0432\u0445\u043e\u0434\u043d\u043e\u0439 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u0431\u0430\u0439\u0442\u043e\u043c \u0438\u0437 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a <b>\u03c0<\/b><br \/>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/3ee\/79f\/78a\/3ee79f78a7b9a7ba4307705edf346867.png\"\/><br \/>  \u0422\u0430\u0431\u043b\u0438\u0446\u0430 <b>\u03c0<\/b> \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u043e\u0439 \u0438 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043f\u0438\u0441\u0430\u043d\u0430 \u0432 \u0432\u0438\u0434\u0435 \u043c\u0430\u0441\u0441\u0438\u0432\u0430:<br \/> \n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u0434\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 pi;<\/b><\/p>\n<div class=\"spoiler_text\">  byte[] Pi={<br \/>   0xFC, 0xEE, 0xDD, 0x11, 0xCF, 0x6E, 0x31, 0x16, 0xFB, 0xC4, 0xFA, 0xDA, 0x23, 0xC5, 0x04, 0x4D,<br \/>   0xE9, 0x77, 0xF0, 0xDB, 0x93, 0x2E, 0x99, 0xBA, 0x17, 0x36, 0xF1, 0xBB, 0x14, 0xCD, 0x5F, 0xC1,<br \/>   0xF9, 0x18, 0x65, 0x5A, 0xE2, 0x5C, 0xEF, 0x21, 0x81, 0x1C, 0x3C, 0x42, 0x8B, 0x01, 0x8E, 0x4F,<br \/>   0x05, 0x84, 0x02, 0xAE, 0xE3, 0x6A, 0x8F, 0xA0, 0x06, 0x0B, 0xED, 0x98, 0x7F, 0xD4, 0xD3, 0x1F,<br \/>   0xEB, 0x34, 0x2C, 0x51, 0xEA, 0xC8, 0x48, 0xAB, 0xF2, 0x2A, 0x68, 0xA2, 0xFD, 0x3A, 0xCE, 0xCC,<br \/>   0xB5, 0x70, 0x0E, 0x56, 0x08, 0x0C, 0x76, 0x12, 0xBF, 0x72, 0x13, 0x47, 0x9C, 0xB7, 0x5D, 0x87,<br \/>   0x15, 0xA1, 0x96, 0x29, 0x10, 0x7B, 0x9A, 0xC7, 0xF3, 0x91, 0x78, 0x6F, 0x9D, 0x9E, 0xB2, 0xB1,<br \/>   0x32, 0x75, 0x19, 0x3D, 0xFF, 0x35, 0x8A, 0x7E, 0x6D, 0x54, 0xC6, 0x80, 0xC3, 0xBD, 0x0D, 0x57,<br \/>   0xDF, 0xF5, 0x24, 0xA9, 0x3E, 0xA8, 0x43, 0xC9, 0xD7, 0x79, 0xD6, 0xF6, 0x7C, 0x22, 0xB9, 0x03,<br \/>   0xE0, 0x0F, 0xEC, 0xDE, 0x7A, 0x94, 0xB0, 0xBC, 0xDC, 0xE8, 0x28, 0x50, 0x4E, 0x33, 0x0A, 0x4A,<br \/>   0xA7, 0x97, 0x60, 0x73, 0x1E, 0x00, 0x62, 0x44, 0x1A, 0xB8, 0x38, 0x82, 0x64, 0x9F, 0x26, 0x41,<br \/>   0xAD, 0x45, 0x46, 0x92, 0x27, 0x5E, 0x55, 0x2F, 0x8C, 0xA3, 0xA5, 0x7D, 0x69, 0xD5, 0x95, 0x3B,<br \/>   0x07, 0x58, 0xB3, 0x40, 0x86, 0xAC, 0x1D, 0xF7, 0x30, 0x37, 0x6B, 0xE4, 0x88, 0xD9, 0xE7, 0x89,<br \/>   0xE1, 0x1B, 0x83, 0x49, 0x4C, 0x3F, 0xF8, 0xFE, 0x8D, 0x53, 0xAA, 0x90, 0xCA, 0xD8, 0x85, 0x61,<br \/>   0x20, 0x71, 0x67, 0xA4, 0x2D, 0x2B, 0x09, 0x5B, 0xCB, 0x9B, 0x25, 0xD0, 0xBE, 0xE5, 0x6C, 0x52,<br \/>   0x59, 0xA6, 0x74, 0xD2, 0xE6, 0xF4, 0xB4, 0xC0, 0xD1, 0x66, 0xAF, 0xC2, 0x39, 0x4B, 0x63, 0xB6<br \/>   };<\/div>\n<\/div>\n<\/li>\n<li><b>P-\u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435.<\/b> \u0424\u0443\u043d\u043a\u0446\u0438\u044f \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438. \u0414\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u043f\u0430\u0440\u044b \u0431\u0430\u0439\u0442 \u0438\u0437 \u0432\u0445\u043e\u0434\u043d\u043e\u0439 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0437\u0430\u043c\u0435\u043d\u0430 \u043e\u0434\u043d\u043e\u0433\u043e \u0431\u0430\u0439\u0442\u0430 \u0434\u0440\u0443\u0433\u0438\u043c. <br \/>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/415\/fe9\/96c\/415fe996ce607ab43df0b634b98cfd12.png\"\/><br \/>  \u0422\u0430\u0431\u043b\u0438\u0446\u0430 \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a <b>\u03c4<\/b> \u0442\u0430\u043a\u0436\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u043e\u0439:<br \/> \n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 tau<\/b><\/p>\n<div class=\"spoiler_text\">byte[] Tau={<br \/>   0, 8, 16, 24, 32, 40, 48, 56,<br \/>   1, 9, 17, 25, 33, 41, 49, 57,<br \/>   2, 10, 18, 26, 34, 42, 50, 58,<br \/>   3, 11, 19, 27, 35, 43, 51, 59,<br \/>   4, 12, 20, 28, 36, 44, 52, 60,<br \/>   5, 13, 21, 29, 37, 45, 53, 61,<br \/>   6, 14, 22, 30, 38, 46, 54, 62,<br \/>   7, 15, 23, 31, 39, 47, 55, 63<br \/>   };<\/div>\n<\/div>\n<\/li>\n<li><b>L-\u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0438\u0435.<\/b> \u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0443\u043c\u043d\u043e\u0436\u0435\u043d\u0438\u0435 64-\u0431\u0438\u0442\u043d\u043e\u0433\u043e \u0432\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u0432\u0435\u043a\u0442\u043e\u0440\u0430 \u043d\u0430 \u0431\u0438\u043d\u0430\u0440\u043d\u0443\u044e \u043c\u0430\u0442\u0440\u0438\u0446\u0443 <b>A<\/b> \u0440\u0430\u0437\u043c\u0435\u0440\u0430\u043c\u0438 64&#215;64.<br \/>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/deb\/845\/9ab\/deb8459ab6e445ad29ac94471d3f51bd.png\"\/><br \/>  \u041c\u0430\u0442\u0440\u0438\u0446\u0443 <b>A<\/b> \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043a\u0430\u043a \u043c\u0430\u0441\u0441\u0438\u0432 64-\u0431\u0438\u0442\u043d\u044b\u0445 \u0441\u043b\u043e\u0432:<br \/> \n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043c\u0430\u0442\u0440\u0438\u0446\u044b A<\/b><\/p>\n<div class=\"spoiler_text\">ulong[] A = {<br \/>   0x8e20faa72ba0b470, 0x47107ddd9b505a38, 0xad08b0e0c3282d1c, 0xd8045870ef14980e,<br \/>   0x6c022c38f90a4c07, 0x3601161cf205268d, 0x1b8e0b0e798c13c8, 0x83478b07b2468764,<br \/>   0xa011d380818e8f40, 0x5086e740ce47c920, 0x2843fd2067adea10, 0x14aff010bdd87508,<br \/>   0x0ad97808d06cb404, 0x05e23c0468365a02, 0x8c711e02341b2d01, 0x46b60f011a83988e,<br \/>   0x90dab52a387ae76f, 0x486dd4151c3dfdb9, 0x24b86a840e90f0d2, 0x125c354207487869,<br \/>   0x092e94218d243cba, 0x8a174a9ec8121e5d, 0x4585254f64090fa0, 0xaccc9ca9328a8950,<br \/>   0x9d4df05d5f661451, 0xc0a878a0a1330aa6, 0x60543c50de970553, 0x302a1e286fc58ca7,<br \/>   0x18150f14b9ec46dd, 0x0c84890ad27623e0, 0x0642ca05693b9f70, 0x0321658cba93c138,<br \/>   0x86275df09ce8aaa8, 0x439da0784e745554, 0xafc0503c273aa42a, 0xd960281e9d1d5215,<br \/>   0xe230140fc0802984, 0x71180a8960409a42, 0xb60c05ca30204d21, 0x5b068c651810a89e,<br \/>   0x456c34887a3805b9, 0xac361a443d1c8cd2, 0x561b0d22900e4669, 0x2b838811480723ba,<br \/>   0x9bcf4486248d9f5d, 0xc3e9224312c8c1a0, 0xeffa11af0964ee50, 0xf97d86d98a327728,<br \/>   0xe4fa2054a80b329c, 0x727d102a548b194e, 0x39b008152acb8227, 0x9258048415eb419d,<br \/>   0x492c024284fbaec0, 0xaa16012142f35760, 0x550b8e9e21f7a530, 0xa48b474f9ef5dc18,<br \/>   0x70a6a56e2440598e, 0x3853dc371220a247, 0x1ca76e95091051ad, 0x0edd37c48a08a6d8,<br \/>   0x07e095624504536c, 0x8d70c431ac02a736, 0xc83862965601dd1b, 0x641c314b2b8ee083<br \/>   };<\/div>\n<\/div>\n<\/li>\n<\/ol>\n<p>  <\/p>\n<h4>\u0424\u0443\u043d\u043a\u0446\u0438\u044f \u0441\u0436\u0430\u0442\u0438\u044f<\/h4>\n<p>  \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u043c \u043b\u044e\u0431\u043e\u0439 \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u0441\u0436\u0430\u0442\u0438\u044f. \u041e\u043f\u0438\u0448\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0443\u044e \u0432 \u043d\u043e\u0432\u043e\u043c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u0441\u0436\u0430\u0442\u0438\u044f <b>g<sub>n<\/sub><\/b> \u0432 \u0432\u0438\u0434\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430.<br \/>  \u041f\u0443\u0441\u0442\u044c <b>h<\/b>, <b>N<\/b> \u0438 <b>m<\/b> \u2014 512-\u0431\u0438\u0442\u043d\u044b\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438. \u0414\u043b\u044f \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <b>g(N, m, h)<\/b> \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u0440\u043e\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0448\u0430\u0433\u0438:  <\/p>\n<ol>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <b>K<\/b> = h \u2295 N;<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = S(K);<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = P(K);<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = L(K);<\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c <b>t<\/b> = E(K, m);<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 t = h \u2295 t;<\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <b>G<\/b> = t \u2295 m;<\/li>\n<li>\u0412\u0435\u0440\u043d\u0443\u0442\u044c G \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u0438 g(N, m, h).<\/li>\n<\/ol>\n<p>  \u0412\u044b \u043d\u0430\u0432\u0435\u0440\u043d\u043e\u0435 \u0437\u0430\u043c\u0435\u0442\u0438\u043b\u0438, \u0447\u0442\u043e \u0432 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <b>g(N, m, h)<\/b> \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043d\u0435\u0437\u043d\u0430\u043a\u043e\u043c\u0430\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f <b>E(K, m)<\/b>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u043d\u0438\u0436\u0435\u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f:  <\/p>\n<ol>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <b>state<\/b> = K \u2295 m; <\/li>\n<li>\u0414\u043b\u044f i=0 \u043f\u043e 11 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c: <br \/> \n<ul>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 state = S(state); <\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 state = P(state);<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 state = L(state);<\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c K=KeySchedule(K, i);<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 state = state \u2295 K;<\/li>\n<\/ul>\n<\/li>\n<li>\u0412\u0435\u0440\u043d\u0443\u0442\u044c <b>state<\/b> \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430. <\/li>\n<\/ol>\n<p>  \u0418 \u043e\u043f\u044f\u0442\u044c \u043d\u0435\u0437\u043d\u0430\u043a\u043e\u043c\u043e\u0435 \u043f\u043e\u043d\u044f\u0442\u0438\u0435. \u041d\u0430 \u044d\u0442\u043e\u0442 \u0440\u0430\u0437 \u044d\u0442\u043e \u0444\u0443\u043d\u043a\u0446\u0438\u044f <b>KeySchedule(K, i)<\/b>, \u043e\u0442\u0432\u0435\u0447\u0430\u044e\u0449\u0430\u044f \u0437\u0430 \u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 K \u043d\u0430 \u043a\u0430\u0436\u0434\u043e\u043c \u0440\u0430\u0443\u043d\u0434\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 E(K, m). \u0412\u043e\u0441\u043f\u043e\u043b\u043d\u0438\u043c \u0438 \u044d\u0442\u043e\u0442 \u043f\u0440\u043e\u0431\u0435\u043b \u0432 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0438 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430. \u0424\u0443\u043d\u043a\u0446\u0438\u044f KeySchedule(K, i) \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f:  <\/p>\n<ol>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = K \u2295 C[i];<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = S(K); <\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = P(K);<\/li>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 K = L(K);<\/li>\n<li>\u0412\u0435\u0440\u043d\u0443\u0442\u044c K \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u0438.<\/li>\n<\/ol>\n<p>  \u0417\u0434\u0435\u0441\u044c \u0421 \u2014 \u044d\u0442\u043e \u043d\u0430\u0431\u043e\u0440 512-\u0431\u0438\u0442\u043d\u044b\u0445 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439. \u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0421 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u043c.  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0417\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0421<\/b><\/p>\n<div class=\"spoiler_text\">byte[][] C = {<br \/>   new byte[64]{<br \/>   0xb1,0x08,0x5b,0xda,0x1e,0xca,0xda,0xe9,0xeb,0xcb,0x2f,0x81,0xc0,0x65,0x7c,0x1f,<br \/>   0x2f,0x6a,0x76,0x43,0x2e,0x45,0xd0,0x16,0x71,0x4e,0xb8,0x8d,0x75,0x85,0xc4,0xfc,<br \/>   0x4b,0x7c,0xe0,0x91,0x92,0x67,0x69,0x01,0xa2,0x42,0x2a,0x08,0xa4,0x60,0xd3,0x15,<br \/>   0x05,0x76,0x74,0x36,0xcc,0x74,0x4d,0x23,0xdd,0x80,0x65,0x59,0xf2,0xa6,0x45,0x07<br \/>   },<br \/>   new byte[64]{<br \/>   0x6f,0xa3,0xb5,0x8a,0xa9,0x9d,0x2f,0x1a,0x4f,0xe3,0x9d,0x46,0x0f,0x70,0xb5,0xd7,<br \/>   0xf3,0xfe,0xea,0x72,0x0a,0x23,0x2b,0x98,0x61,0xd5,0x5e,0x0f,0x16,0xb5,0x01,0x31,<br \/>   0x9a,0xb5,0x17,0x6b,0x12,0xd6,0x99,0x58,0x5c,0xb5,0x61,0xc2,0xdb,0x0a,0xa7,0xca,<br \/>   0x55,0xdd,0xa2,0x1b,0xd7,0xcb,0xcd,0x56,0xe6,0x79,0x04,0x70,0x21,0xb1,0x9b,0xb7<br \/>   },<br \/>   new byte[64]{<br \/>   0xf5,0x74,0xdc,0xac,0x2b,0xce,0x2f,0xc7,0x0a,0x39,0xfc,0x28,0x6a,0x3d,0x84,0x35,<br \/>   0x06,0xf1,0x5e,0x5f,0x52,0x9c,0x1f,0x8b,0xf2,0xea,0x75,0x14,0xb1,0x29,0x7b,0x7b,<br \/>   0xd3,0xe2,0x0f,0xe4,0x90,0x35,0x9e,0xb1,0xc1,0xc9,0x3a,0x37,0x60,0x62,0xdb,0x09,<br \/>   0xc2,0xb6,0xf4,0x43,0x86,0x7a,0xdb,0x31,0x99,0x1e,0x96,0xf5,0x0a,0xba,0x0a,0xb2<br \/>   },<br \/>   new byte[64]{<br \/>   0xef,0x1f,0xdf,0xb3,0xe8,0x15,0x66,0xd2,0xf9,0x48,0xe1,0xa0,0x5d,0x71,0xe4,0xdd,<br \/>   0x48,0x8e,0x85,0x7e,0x33,0x5c,0x3c,0x7d,0x9d,0x72,0x1c,0xad,0x68,0x5e,0x35,0x3f,<br \/>   0xa9,0xd7,0x2c,0x82,0xed,0x03,0xd6,0x75,0xd8,0xb7,0x13,0x33,0x93,0x52,0x03,0xbe,<br \/>   0x34,0x53,0xea,0xa1,0x93,0xe8,0x37,0xf1,0x22,0x0c,0xbe,0xbc,0x84,0xe3,0xd1,0x2e<br \/>   },<br \/>   new byte[64]{<br \/>   0x4b,0xea,0x6b,0xac,0xad,0x47,0x47,0x99,0x9a,0x3f,0x41,0x0c,0x6c,0xa9,0x23,0x63,<br \/>   0x7f,0x15,0x1c,0x1f,0x16,0x86,0x10,0x4a,0x35,0x9e,0x35,0xd7,0x80,0x0f,0xff,0xbd,<br \/>   0xbf,0xcd,0x17,0x47,0x25,0x3a,0xf5,0xa3,0xdf,0xff,0x00,0xb7,0x23,0x27,0x1a,0x16,<br \/>   0x7a,0x56,0xa2,0x7e,0xa9,0xea,0x63,0xf5,0x60,0x17,0x58,0xfd,0x7c,0x6c,0xfe,0x57<br \/>   },<br \/>   new byte[64]{<br \/>   0xae,0x4f,0xae,0xae,0x1d,0x3a,0xd3,0xd9,0x6f,0xa4,0xc3,0x3b,0x7a,0x30,0x39,0xc0,<br \/>   0x2d,0x66,0xc4,0xf9,0x51,0x42,0xa4,0x6c,0x18,0x7f,0x9a,0xb4,0x9a,0xf0,0x8e,0xc6,<br \/>   0xcf,0xfa,0xa6,0xb7,0x1c,0x9a,0xb7,0xb4,0x0a,0xf2,0x1f,0x66,0xc2,0xbe,0xc6,0xb6,<br \/>   0xbf,0x71,0xc5,0x72,0x36,0x90,0x4f,0x35,0xfa,0x68,0x40,0x7a,0x46,0x64,0x7d,0x6e<br \/>   },<br \/>   new byte[64]{<br \/>   0xf4,0xc7,0x0e,0x16,0xee,0xaa,0xc5,0xec,0x51,0xac,0x86,0xfe,0xbf,0x24,0x09,0x54,<br \/>   0x39,0x9e,0xc6,0xc7,0xe6,0xbf,0x87,0xc9,0xd3,0x47,0x3e,0x33,0x19,0x7a,0x93,0xc9,<br \/>   0x09,0x92,0xab,0xc5,0x2d,0x82,0x2c,0x37,0x06,0x47,0x69,0x83,0x28,0x4a,0x05,0x04,<br \/>   0x35,0x17,0x45,0x4c,0xa2,0x3c,0x4a,0xf3,0x88,0x86,0x56,0x4d,0x3a,0x14,0xd4,0x93<br \/>   },<br \/>   new byte[64]{<br \/>   0x9b,0x1f,0x5b,0x42,0x4d,0x93,0xc9,0xa7,0x03,0xe7,0xaa,0x02,0x0c,0x6e,0x41,0x41,<br \/>   0x4e,0xb7,0xf8,0x71,0x9c,0x36,0xde,0x1e,0x89,0xb4,0x44,0x3b,0x4d,0xdb,0xc4,0x9a,<br \/>   0xf4,0x89,0x2b,0xcb,0x92,0x9b,0x06,0x90,0x69,0xd1,0x8d,0x2b,0xd1,0xa5,0xc4,0x2f,<br \/>   0x36,0xac,0xc2,0x35,0x59,0x51,0xa8,0xd9,0xa4,0x7f,0x0d,0xd4,0xbf,0x02,0xe7,0x1e<br \/>   },<br \/>   new byte[64]{<br \/>   0x37,0x8f,0x5a,0x54,0x16,0x31,0x22,0x9b,0x94,0x4c,0x9a,0xd8,0xec,0x16,0x5f,0xde,<br \/>   0x3a,0x7d,0x3a,0x1b,0x25,0x89,0x42,0x24,0x3c,0xd9,0x55,0xb7,0xe0,0x0d,0x09,0x84,<br \/>   0x80,0x0a,0x44,0x0b,0xdb,0xb2,0xce,0xb1,0x7b,0x2b,0x8a,0x9a,0xa6,0x07,0x9c,0x54,<br \/>   0x0e,0x38,0xdc,0x92,0xcb,0x1f,0x2a,0x60,0x72,0x61,0x44,0x51,0x83,0x23,0x5a,0xdb<br \/>   },<br \/>   new byte[64]{<br \/>   0xab,0xbe,0xde,0xa6,0x80,0x05,0x6f,0x52,0x38,0x2a,0xe5,0x48,0xb2,0xe4,0xf3,0xf3,<br \/>   0x89,0x41,0xe7,0x1c,0xff,0x8a,0x78,0xdb,0x1f,0xff,0xe1,0x8a,0x1b,0x33,0x61,0x03,<br \/>   0x9f,0xe7,0x67,0x02,0xaf,0x69,0x33,0x4b,0x7a,0x1e,0x6c,0x30,0x3b,0x76,0x52,0xf4,<br \/>   0x36,0x98,0xfa,0xd1,0x15,0x3b,0xb6,0xc3,0x74,0xb4,0xc7,0xfb,0x98,0x45,0x9c,0xed<br \/>   },<br \/>   new byte[64]{<br \/>   0x7b,0xcd,0x9e,0xd0,0xef,0xc8,0x89,0xfb,0x30,0x02,0xc6,0xcd,0x63,0x5a,0xfe,0x94,<br \/>   0xd8,0xfa,0x6b,0xbb,0xeb,0xab,0x07,0x61,0x20,0x01,0x80,0x21,0x14,0x84,0x66,0x79,<br \/>   0x8a,0x1d,0x71,0xef,0xea,0x48,0xb9,0xca,0xef,0xba,0xcd,0x1d,0x7d,0x47,0x6e,0x98,<br \/>   0xde,0xa2,0x59,0x4a,0xc0,0x6f,0xd8,0x5d,0x6b,0xca,0xa4,0xcd,0x81,0xf3,0x2d,0x1b<br \/>   },<br \/>   new byte[64]{<br \/>   0x37,0x8e,0xe7,0x67,0xf1,0x16,0x31,0xba,0xd2,0x13,0x80,0xb0,0x04,0x49,0xb1,0x7a,<br \/>   0xcd,0xa4,0x3c,0x32,0xbc,0xdf,0x1d,0x77,0xf8,0x20,0x12,0xd4,0x30,0x21,0x9f,0x9b,<br \/>   0x5d,0x80,0xef,0x9d,0x18,0x91,0xcc,0x86,0xe7,0x1d,0xa4,0xaa,0x88,0xe1,0x28,0x52,<br \/>   0xfa,0xf4,0x17,0xd5,0xd9,0xb2,0x1b,0x99,0x48,0xbc,0x92,0x4a,0xf1,0x1b,0xd7,0x20<br \/>   }<br \/>   };<\/div>\n<\/div>\n<h4>\u0412\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0435 \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438<\/h4>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u043e\u043f\u0438\u0448\u0435\u043c \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0443 \u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0445\u0435\u0448-\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f. \u0414\u043b\u044f \u043b\u044e\u0431\u043e\u0433\u043e \u0432\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f M:  <\/p>\n<ol>\n<li>\u041f\u0440\u0438\u0441\u0432\u043e\u0438\u0442\u044c \u043d\u0430\u0447\u0430\u043b\u044c\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u0445 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445: <br \/> \n<ul>\n<li>\u0414\u043b\u044f \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0441 \u0434\u043b\u0438\u043d\u043e\u0439 \u0432\u044b\u0445\u043e\u0434\u0430 512 \u0431\u0438\u0442: h=iv=0x00<sup>64<\/sup>. \u0414\u043b\u044f \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0441 \u0434\u043b\u0438\u043d\u043e\u0439 \u0432\u044b\u0445\u043e\u0434\u0430 256 \u0431\u0438\u0442: h=iv=0x01<sup>64<\/sup>. <\/li>\n<li>N = 0<sup>512<\/sup><\/li>\n<li>\u03a3 = 0<sup>512<\/sup><\/li>\n<\/ul>\n<\/li>\n<li>\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435 \u0443\u0441\u043b\u043e\u0432\u0438\u0435: \u0434\u043b\u0438\u043d\u0430 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f M&lt;512. \u0415\u0441\u043b\u0438 \u0443\u0441\u043b\u043e\u0432\u0438\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0439\u0442\u0438 \u043a \u043f\u0443\u043d\u043a\u0442\u0443 3. \u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u0439:<br \/> \n<ul>\n<li>m \u2014 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0435 512 \u0431\u0438\u0442 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f M <\/li>\n<li>h = g(N, m, h)<\/li>\n<li>N = (N + 512) mod 2<sup>512<\/sup><\/li>\n<li>\u03a3 = (\u03a3 + m) mod 2<sup>512<\/sup><\/li>\n<li>\u041e\u0431\u0440\u0435\u0437\u0430\u0442\u044c M, \u0443\u0431\u0440\u0430\u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0435 512 \u0431\u0438\u0442<\/li>\n<li>\u041f\u0435\u0440\u0435\u0439\u0442\u0438 \u043a \u0448\u0430\u0433\u0443 2 <\/li>\n<\/ul>\n<\/li>\n<li>\u041f\u0440\u043e\u0438\u0437\u0432\u0435\u0441\u0442\u0438 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f M \u0434\u043e \u0434\u043b\u0438\u043d\u044b \u0432 512 \u0431\u0438\u0442 \u043f\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c\u0443 \u043f\u0440\u0430\u0432\u0438\u043b\u0443: <br \/>  m = 0<sup>511-|M|<\/sup>||1||M, \u0433\u0434\u0435 |M| \u2014 \u0434\u043b\u0438\u043d\u0430 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f M \u0432 \u0431\u0438\u0442\u0430\u0445.<\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c h = g(N, m, h)<\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c N = (N + |M|) mod 2<sup>512<\/sup> <\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u03a3 = (\u03a3 + m) mod 2<sup>512<\/sup> <\/li>\n<li>\u0412\u044b\u0447\u0438\u0441\u043b\u0438\u0442\u044c h = g(0, m, h)<\/li>\n<li>\u0414\u043b\u044f \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0441 \u0434\u043b\u0438\u043d\u043e\u0439 \u0432\u044b\u0445\u043e\u0434\u0430 \u0432 512 \u0431\u0438\u0442 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c h \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430. \u0414\u043b\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0441 \u0434\u043b\u0438\u043d\u043e\u0439 \u0432\u044b\u0445\u043e\u0434\u0430 256 \u0431\u0438\u0442 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c MSB<sub>256<\/sub>(h). <\/li>\n<\/ol>\n<p>  \u041e\u0431\u0435\u0449\u0430\u043d\u043d\u0443\u044e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430 \u043d\u0430 C# \u0432\u044b \u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u043f\u043e\u0434 \u0441\u043f\u043e\u0439\u043b\u0435\u0440\u043e\u043c:  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">C# \u043a\u043b\u0430\u0441\u0441 GOST<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"cs\">class GOST     {         \/\/ Matrix A for MixColumns (L) function         private ulong[] A = {         0x8e20faa72ba0b470, 0x47107ddd9b505a38, 0xad08b0e0c3282d1c, 0xd8045870ef14980e,         0x6c022c38f90a4c07, 0x3601161cf205268d, 0x1b8e0b0e798c13c8, 0x83478b07b2468764,         0xa011d380818e8f40, 0x5086e740ce47c920, 0x2843fd2067adea10, 0x14aff010bdd87508,         0x0ad97808d06cb404, 0x05e23c0468365a02, 0x8c711e02341b2d01, 0x46b60f011a83988e,         0x90dab52a387ae76f, 0x486dd4151c3dfdb9, 0x24b86a840e90f0d2, 0x125c354207487869,         0x092e94218d243cba, 0x8a174a9ec8121e5d, 0x4585254f64090fa0, 0xaccc9ca9328a8950,         0x9d4df05d5f661451, 0xc0a878a0a1330aa6, 0x60543c50de970553, 0x302a1e286fc58ca7,         0x18150f14b9ec46dd, 0x0c84890ad27623e0, 0x0642ca05693b9f70, 0x0321658cba93c138,         0x86275df09ce8aaa8, 0x439da0784e745554, 0xafc0503c273aa42a, 0xd960281e9d1d5215,         0xe230140fc0802984, 0x71180a8960409a42, 0xb60c05ca30204d21, 0x5b068c651810a89e,         0x456c34887a3805b9, 0xac361a443d1c8cd2, 0x561b0d22900e4669, 0x2b838811480723ba,         0x9bcf4486248d9f5d, 0xc3e9224312c8c1a0, 0xeffa11af0964ee50, 0xf97d86d98a327728,         0xe4fa2054a80b329c, 0x727d102a548b194e, 0x39b008152acb8227, 0x9258048415eb419d,         0x492c024284fbaec0, 0xaa16012142f35760, 0x550b8e9e21f7a530, 0xa48b474f9ef5dc18,         0x70a6a56e2440598e, 0x3853dc371220a247, 0x1ca76e95091051ad, 0x0edd37c48a08a6d8,         0x07e095624504536c, 0x8d70c431ac02a736, 0xc83862965601dd1b, 0x641c314b2b8ee083         };          \/\/ Substitution for SubBytes function         private byte[] Sbox={         0xFC, 0xEE, 0xDD, 0x11, 0xCF, 0x6E, 0x31, 0x16, 0xFB, 0xC4, 0xFA, 0xDA, 0x23, 0xC5, 0x04, 0x4D,         0xE9, 0x77, 0xF0, 0xDB, 0x93, 0x2E, 0x99, 0xBA, 0x17, 0x36, 0xF1, 0xBB, 0x14, 0xCD, 0x5F, 0xC1,         0xF9, 0x18, 0x65, 0x5A, 0xE2, 0x5C, 0xEF, 0x21, 0x81, 0x1C, 0x3C, 0x42, 0x8B, 0x01, 0x8E, 0x4F,         0x05, 0x84, 0x02, 0xAE, 0xE3, 0x6A, 0x8F, 0xA0, 0x06, 0x0B, 0xED, 0x98, 0x7F, 0xD4, 0xD3, 0x1F,         0xEB, 0x34, 0x2C, 0x51, 0xEA, 0xC8, 0x48, 0xAB, 0xF2, 0x2A, 0x68, 0xA2, 0xFD, 0x3A, 0xCE, 0xCC,         0xB5, 0x70, 0x0E, 0x56, 0x08, 0x0C, 0x76, 0x12, 0xBF, 0x72, 0x13, 0x47, 0x9C, 0xB7, 0x5D, 0x87,         0x15, 0xA1, 0x96, 0x29, 0x10, 0x7B, 0x9A, 0xC7, 0xF3, 0x91, 0x78, 0x6F, 0x9D, 0x9E, 0xB2, 0xB1,         0x32, 0x75, 0x19, 0x3D, 0xFF, 0x35, 0x8A, 0x7E, 0x6D, 0x54, 0xC6, 0x80, 0xC3, 0xBD, 0x0D, 0x57,         0xDF, 0xF5, 0x24, 0xA9, 0x3E, 0xA8, 0x43, 0xC9, 0xD7, 0x79, 0xD6, 0xF6, 0x7C, 0x22, 0xB9, 0x03,         0xE0, 0x0F, 0xEC, 0xDE, 0x7A, 0x94, 0xB0, 0xBC, 0xDC, 0xE8, 0x28, 0x50, 0x4E, 0x33, 0x0A, 0x4A,         0xA7, 0x97, 0x60, 0x73, 0x1E, 0x00, 0x62, 0x44, 0x1A, 0xB8, 0x38, 0x82, 0x64, 0x9F, 0x26, 0x41,         0xAD, 0x45, 0x46, 0x92, 0x27, 0x5E, 0x55, 0x2F, 0x8C, 0xA3, 0xA5, 0x7D, 0x69, 0xD5, 0x95, 0x3B,         0x07, 0x58, 0xB3, 0x40, 0x86, 0xAC, 0x1D, 0xF7, 0x30, 0x37, 0x6B, 0xE4, 0x88, 0xD9, 0xE7, 0x89,         0xE1, 0x1B, 0x83, 0x49, 0x4C, 0x3F, 0xF8, 0xFE, 0x8D, 0x53, 0xAA, 0x90, 0xCA, 0xD8, 0x85, 0x61,         0x20, 0x71, 0x67, 0xA4, 0x2D, 0x2B, 0x09, 0x5B, 0xCB, 0x9B, 0x25, 0xD0, 0xBE, 0xE5, 0x6C, 0x52,         0x59, 0xA6, 0x74, 0xD2, 0xE6, 0xF4, 0xB4, 0xC0, 0xD1, 0x66, 0xAF, 0xC2, 0x39, 0x4B, 0x63, 0xB6         };          \/\/ Substitution for Transposition (P) function         private byte[] Tau={         0, 8, 16, 24, 32, 40, 48, 56,         1, 9, 17, 25, 33, 41, 49, 57,         2, 10, 18, 26, 34, 42, 50, 58,         3, 11, 19, 27, 35, 43, 51, 59,         4, 12, 20, 28, 36, 44, 52, 60,         5, 13, 21, 29, 37, 45, 53, 61,         6, 14, 22, 30, 38, 46, 54, 62,         7, 15, 23, 31, 39, 47, 55, 63         };          \/\/ Constant values for KeySchedule function         private byte[][] C = {         new byte[64]{         0xb1,0x08,0x5b,0xda,0x1e,0xca,0xda,0xe9,0xeb,0xcb,0x2f,0x81,0xc0,0x65,0x7c,0x1f,         0x2f,0x6a,0x76,0x43,0x2e,0x45,0xd0,0x16,0x71,0x4e,0xb8,0x8d,0x75,0x85,0xc4,0xfc,         0x4b,0x7c,0xe0,0x91,0x92,0x67,0x69,0x01,0xa2,0x42,0x2a,0x08,0xa4,0x60,0xd3,0x15,         0x05,0x76,0x74,0x36,0xcc,0x74,0x4d,0x23,0xdd,0x80,0x65,0x59,0xf2,0xa6,0x45,0x07         },         new byte[64]{         0x6f,0xa3,0xb5,0x8a,0xa9,0x9d,0x2f,0x1a,0x4f,0xe3,0x9d,0x46,0x0f,0x70,0xb5,0xd7,         0xf3,0xfe,0xea,0x72,0x0a,0x23,0x2b,0x98,0x61,0xd5,0x5e,0x0f,0x16,0xb5,0x01,0x31,         0x9a,0xb5,0x17,0x6b,0x12,0xd6,0x99,0x58,0x5c,0xb5,0x61,0xc2,0xdb,0x0a,0xa7,0xca,         0x55,0xdd,0xa2,0x1b,0xd7,0xcb,0xcd,0x56,0xe6,0x79,0x04,0x70,0x21,0xb1,0x9b,0xb7         },         new byte[64]{         0xf5,0x74,0xdc,0xac,0x2b,0xce,0x2f,0xc7,0x0a,0x39,0xfc,0x28,0x6a,0x3d,0x84,0x35,         0x06,0xf1,0x5e,0x5f,0x52,0x9c,0x1f,0x8b,0xf2,0xea,0x75,0x14,0xb1,0x29,0x7b,0x7b,         0xd3,0xe2,0x0f,0xe4,0x90,0x35,0x9e,0xb1,0xc1,0xc9,0x3a,0x37,0x60,0x62,0xdb,0x09,         0xc2,0xb6,0xf4,0x43,0x86,0x7a,0xdb,0x31,0x99,0x1e,0x96,0xf5,0x0a,0xba,0x0a,0xb2         },         new byte[64]{         0xef,0x1f,0xdf,0xb3,0xe8,0x15,0x66,0xd2,0xf9,0x48,0xe1,0xa0,0x5d,0x71,0xe4,0xdd,         0x48,0x8e,0x85,0x7e,0x33,0x5c,0x3c,0x7d,0x9d,0x72,0x1c,0xad,0x68,0x5e,0x35,0x3f,         0xa9,0xd7,0x2c,0x82,0xed,0x03,0xd6,0x75,0xd8,0xb7,0x13,0x33,0x93,0x52,0x03,0xbe,         0x34,0x53,0xea,0xa1,0x93,0xe8,0x37,0xf1,0x22,0x0c,0xbe,0xbc,0x84,0xe3,0xd1,0x2e         },         new byte[64]{         0x4b,0xea,0x6b,0xac,0xad,0x47,0x47,0x99,0x9a,0x3f,0x41,0x0c,0x6c,0xa9,0x23,0x63,         0x7f,0x15,0x1c,0x1f,0x16,0x86,0x10,0x4a,0x35,0x9e,0x35,0xd7,0x80,0x0f,0xff,0xbd,         0xbf,0xcd,0x17,0x47,0x25,0x3a,0xf5,0xa3,0xdf,0xff,0x00,0xb7,0x23,0x27,0x1a,0x16,         0x7a,0x56,0xa2,0x7e,0xa9,0xea,0x63,0xf5,0x60,0x17,0x58,0xfd,0x7c,0x6c,0xfe,0x57         },         new byte[64]{         0xae,0x4f,0xae,0xae,0x1d,0x3a,0xd3,0xd9,0x6f,0xa4,0xc3,0x3b,0x7a,0x30,0x39,0xc0,         0x2d,0x66,0xc4,0xf9,0x51,0x42,0xa4,0x6c,0x18,0x7f,0x9a,0xb4,0x9a,0xf0,0x8e,0xc6,         0xcf,0xfa,0xa6,0xb7,0x1c,0x9a,0xb7,0xb4,0x0a,0xf2,0x1f,0x66,0xc2,0xbe,0xc6,0xb6,         0xbf,0x71,0xc5,0x72,0x36,0x90,0x4f,0x35,0xfa,0x68,0x40,0x7a,0x46,0x64,0x7d,0x6e         },         new byte[64]{         0xf4,0xc7,0x0e,0x16,0xee,0xaa,0xc5,0xec,0x51,0xac,0x86,0xfe,0xbf,0x24,0x09,0x54,         0x39,0x9e,0xc6,0xc7,0xe6,0xbf,0x87,0xc9,0xd3,0x47,0x3e,0x33,0x19,0x7a,0x93,0xc9,         0x09,0x92,0xab,0xc5,0x2d,0x82,0x2c,0x37,0x06,0x47,0x69,0x83,0x28,0x4a,0x05,0x04,         0x35,0x17,0x45,0x4c,0xa2,0x3c,0x4a,0xf3,0x88,0x86,0x56,0x4d,0x3a,0x14,0xd4,0x93         },         new byte[64]{         0x9b,0x1f,0x5b,0x42,0x4d,0x93,0xc9,0xa7,0x03,0xe7,0xaa,0x02,0x0c,0x6e,0x41,0x41,         0x4e,0xb7,0xf8,0x71,0x9c,0x36,0xde,0x1e,0x89,0xb4,0x44,0x3b,0x4d,0xdb,0xc4,0x9a,         0xf4,0x89,0x2b,0xcb,0x92,0x9b,0x06,0x90,0x69,0xd1,0x8d,0x2b,0xd1,0xa5,0xc4,0x2f,         0x36,0xac,0xc2,0x35,0x59,0x51,0xa8,0xd9,0xa4,0x7f,0x0d,0xd4,0xbf,0x02,0xe7,0x1e         },         new byte[64]{         0x37,0x8f,0x5a,0x54,0x16,0x31,0x22,0x9b,0x94,0x4c,0x9a,0xd8,0xec,0x16,0x5f,0xde,         0x3a,0x7d,0x3a,0x1b,0x25,0x89,0x42,0x24,0x3c,0xd9,0x55,0xb7,0xe0,0x0d,0x09,0x84,         0x80,0x0a,0x44,0x0b,0xdb,0xb2,0xce,0xb1,0x7b,0x2b,0x8a,0x9a,0xa6,0x07,0x9c,0x54,         0x0e,0x38,0xdc,0x92,0xcb,0x1f,0x2a,0x60,0x72,0x61,0x44,0x51,0x83,0x23,0x5a,0xdb         },         new byte[64]{         0xab,0xbe,0xde,0xa6,0x80,0x05,0x6f,0x52,0x38,0x2a,0xe5,0x48,0xb2,0xe4,0xf3,0xf3,         0x89,0x41,0xe7,0x1c,0xff,0x8a,0x78,0xdb,0x1f,0xff,0xe1,0x8a,0x1b,0x33,0x61,0x03,         0x9f,0xe7,0x67,0x02,0xaf,0x69,0x33,0x4b,0x7a,0x1e,0x6c,0x30,0x3b,0x76,0x52,0xf4,         0x36,0x98,0xfa,0xd1,0x15,0x3b,0xb6,0xc3,0x74,0xb4,0xc7,0xfb,0x98,0x45,0x9c,0xed         },         new byte[64]{         0x7b,0xcd,0x9e,0xd0,0xef,0xc8,0x89,0xfb,0x30,0x02,0xc6,0xcd,0x63,0x5a,0xfe,0x94,         0xd8,0xfa,0x6b,0xbb,0xeb,0xab,0x07,0x61,0x20,0x01,0x80,0x21,0x14,0x84,0x66,0x79,         0x8a,0x1d,0x71,0xef,0xea,0x48,0xb9,0xca,0xef,0xba,0xcd,0x1d,0x7d,0x47,0x6e,0x98,         0xde,0xa2,0x59,0x4a,0xc0,0x6f,0xd8,0x5d,0x6b,0xca,0xa4,0xcd,0x81,0xf3,0x2d,0x1b         },         new byte[64]{         0x37,0x8e,0xe7,0x67,0xf1,0x16,0x31,0xba,0xd2,0x13,0x80,0xb0,0x04,0x49,0xb1,0x7a,         0xcd,0xa4,0x3c,0x32,0xbc,0xdf,0x1d,0x77,0xf8,0x20,0x12,0xd4,0x30,0x21,0x9f,0x9b,         0x5d,0x80,0xef,0x9d,0x18,0x91,0xcc,0x86,0xe7,0x1d,0xa4,0xaa,0x88,0xe1,0x28,0x52,         0xfa,0xf4,0x17,0xd5,0xd9,0xb2,0x1b,0x99,0x48,0xbc,0x92,0x4a,0xf1,0x1b,0xd7,0x20         }         };          private byte[] iv =new byte[64];          private byte[] N =new byte[64];          private byte[] Sigma = new byte[64];          public int outLen = 0;          public GOST(int outputLenght)         {             if (outputLenght == 512)             {                 for (int i = 0; i &lt; 64; i++)                 {                     N[i] = 0x00;                     Sigma[i] = 0x00;                     iv[i] = 0x00;                 }                 outLen = 512;             }             else if (outputLenght == 256)             {                 for (int i = 0; i &lt; 64; i++)                 {                     N[i] = 0x00;                     Sigma[i] = 0x00;                     iv[i] = 0x01;                 }                 outLen = 256;             }         }          private byte[] AddModulo512(byte[] a, byte[] b)         {             byte[] temp = new byte[64];             int i = 0, t = 0;             byte[] tempA = new byte[64];             byte[] tempB = new byte[64];             Array.Copy(a, 0, tempA, 64 - a.Length, a.Length);             Array.Copy(b, 0, tempB, 64 - b.Length, b.Length);             for (i = 63; i &gt;= 0; i--)             {                 t = tempA[i] + tempB[i] + (t &gt;&gt; 8);                 temp[i] = (byte)(t & 0xFF);             }             return temp;         }          private byte[] AddXor512(byte[] a, byte[] b)         {             byte[] c = new byte[64];             for (int i = 0; i &lt; 64; i++)                 c[i] = (byte)(a[i] ^ b[i]);             return c;         }          private byte[] S(byte[] state)         {             byte[] result = new byte[64];             for (int i = 0; i &lt; 64; i++)                 result[i] = Sbox[state[i]];             return result;         }          private byte[] P(byte[] state)         {             byte[] result = new byte[64];             for (int i = 0; i &lt; 64; i++)             {                 result[i] = state[Tau[i]];             }             return result;         }          private byte[] L(byte[] state)         {             byte[] result = new byte[64];                         for (int i = 0; i &lt; 8; i++)             {                 ulong t = 0;                 byte[] tempArray = new byte[8];                 Array.Copy(state, i * 8, tempArray, 0, 8);                 tempArray = tempArray.Reverse().ToArray();                 BitArray tempBits1 = new BitArray(tempArray);                 bool[] tempBits=new bool[64];                 tempBits1.CopyTo(tempBits, 0);                 tempBits=tempBits.Reverse().ToArray();                 for (int j = 0; j &lt; 64; j++)                 {                     if (tempBits[j] != false)                         t = t ^ A[j];                 }                 byte[] ResPart = BitConverter.GetBytes(t).Reverse().ToArray();                 Array.Copy(ResPart, 0, result, i * 8, 8);             }             return result;         }          private byte[] KeySchedule(byte[] K, int i)         {             K=AddXor512(K, C[i]);             K = S(K);             K = P(K);             K = L(K);             return K;         }          private byte[] E(byte[] K, byte[] m)         {             byte[] state = AddXor512(K, m);             for (int i = 0; i &lt; 12; i++)             {                 state=S(state);                 state = P(state);                 state = L(state);                                 K=KeySchedule(K, i);                 state = AddXor512(state, K);             }             return state;         }          private byte[] G_n(byte[] N, byte[] h, byte[] m)         {             byte[] K = AddXor512(h, N);             K=S(K);             K=P(K);             K=L(K);             byte[] t= E(K, m);             t=AddXor512(t, h);             byte[] newh = AddXor512(t, m);             return newh;         }          public byte[] GetHash(byte[] message)         {             byte[] paddedMes=new byte[64];             int len = message.Length * 8;             byte[] h = new byte[64];             Array.Copy(iv, h, 64);             byte[] N_0 ={             0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,             0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,             0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,             0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00             };             if (outLen == 512)             {                 for (int i = 0; i &lt; 64; i++)                 {                     N[i] = 0x00;                     Sigma[i] = 0x00;                     iv[i] = 0x00;                 }                             }             else if (outLen == 256)             {                 for (int i = 0; i &lt; 64; i++)                 {                     N[i] = 0x00;                     Sigma[i] = 0x00;                     iv[i] = 0x01;                 }                             }             byte[] N_512 = BitConverter.GetBytes(512);             int inc = 0;             while (len &gt;= 512)             {                 inc++;                 byte[] tempMes = new byte[64];                 Array.Copy(message, message.Length - inc*64, tempMes, 0, 64);                                 h=G_n(N, h, tempMes);                 N = AddModulo512(N, N_512.Reverse().ToArray());                 Sigma=AddModulo512(Sigma, tempMes);                 len -= 512;                             }             byte[] message1 = new byte[message.Length - inc * 64];             Array.Copy(message, 0, message1, 0, message.Length - inc * 64);             if (message1.Length &lt; 64)             {                 for (int i = 0; i &lt; (64 - message1.Length - 1); i++)                 {                     paddedMes[i] = 0;                 }                 paddedMes[64 - message1.Length - 1] = 0x01;                 Array.Copy(message1, 0, paddedMes, 64 - message1.Length, message1.Length);             }                         h=G_n(N, h, paddedMes);             byte[] MesLen = BitConverter.GetBytes(message1.Length * 8);             N = AddModulo512(N, MesLen.Reverse().ToArray());             Sigma = AddModulo512(Sigma, paddedMes);                         h = G_n(N_0, h, N);             h = G_n(N_0, h, Sigma);             if (outLen == 512)                 return h;             else             {                 byte[] h256 = new byte[32];                 Array.Copy(h, 0, h256, 0, 32);                 return h256;             }         }     } <\/code><\/pre>\n<\/div>\n<\/div>\n<h4>\u041a\u043e\u043d\u0442\u0440\u043e\u043b\u044c\u043d\u044b\u0439 \u043f\u0440\u0438\u043c\u0435\u0440<\/h4>\n<p>  \u0412\u044b\u0447\u0438\u0441\u043b\u0438\u043c \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u044e \u0434\u043b\u044f \u043c\u0430\u0441\u0441\u0438\u0432\u0430 \u0434\u0430\u043d\u043d\u044b\u0445: <br \/>  <code> 0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37, 0x36,0x35,0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31, 0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35, 0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,0x30 <\/code><\/p>\n<p>  \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u043e\u0439:  <\/p>\n<pre><code class=\"cs\">private void ComputeHash()         {             GOST G = new GOST(256);             GOST G512 = new GOST(512);             byte[] message={                                 0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,                                 0x36,0x35,0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,                                 0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,                                 0x34,0x33,0x32,0x31,0x30,0x39,0x38,0x37,0x36,0x35,0x34,0x33,0x32,0x31,0x30};                       byte[] res = G.GetHash(message);             byte[] res2 = G512.GetHash(message);                         string h256 = BitConverter.ToString(res);             string h512 = BitConverter.ToString(res2);         } <\/code><\/pre>\n<p>  \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f:<\/p>\n<p>  <b>h256<\/b>=00-55-7B-E5-E5-84-FD-52-A4-49-B1-6B-02-51-D0-5D-27-F9-4A-B7-6C-BA-A6-DA-89-0B-59-D8-EF-1E-15-9D<\/p>\n<p>  <b>h512<\/b>=48-6F-64-C1-91-78-79-41-7F-EF-08-2B-33-81-A4-E2-11-C3-24-F0-74-65-4C-38-82-3A-7B-76-F8-30-AD-00-FA-1F-BA-E4-2B-12-85-C0-35-2F-22-75-24-BC-9A-B1-62-54-28-8D-D6-86-3D-CC-D5-B9-F5-4A-1A-D0-54-1B<\/p>\n<h4>\u0421\u0441\u044b\u043b\u043a\u0438<\/h4>\n<p>  <\/p>\n<ol>\n<li>\u041f\u043e\u043b\u043d\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043a\u0430\u0447\u0430\u0442\u044c <a href=\"http:\/\/specremont.su\/pdf\/gost_34_11_2012.pdf\">\u043e\u0442\u0441\u044e\u0434\u0430<\/a>. <\/li>\n<li><a href=\"http:\/\/paco2012.ipu.ru\/procdngs\/F108.pdf\">\u0421\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435 \u0441\u0442\u0430\u0440\u043e\u0433\u043e \u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043e\u0432<\/a>.<\/li>\n<\/ol>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/188152\/\"> http:\/\/habrahabr.ru\/post\/188152\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">   \t<img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/24d\/da3\/fa1\/24dda3fa1befb4727294d515a26a25fd.jpg\" align=\"left\"\/>\u0412 2012 \u0433\u043e\u0434\u0443 \u0432\u0441\u044f \u043e\u0431\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0441\u0442\u044c, \u0431\u043e\u043b\u0435\u0435 \u0438\u043b\u0438 \u043c\u0435\u043d\u0435\u0435 \u043f\u0440\u0438\u0447\u0430\u0441\u0442\u043d\u0430\u044f \u043a \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438, \u043f\u0440\u0438\u0441\u0442\u0430\u043b\u044c\u043d\u043e \u0441\u043b\u0435\u0434\u0438\u043b\u0430 \u0437\u0430 \u0432\u044b\u0431\u043e\u0440\u0430\u043c\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u0445\u0435\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 SHA-3. \u041d\u0430 \u0445\u0430\u0431\u0440\u0435 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0448\u0438\u0440\u043e\u043a\u043e \u043e\u0441\u0432\u0435\u0449\u0430\u043b\u043e\u0441\u044c \u044d\u0442\u043e \u0432\u0430\u0436\u043d\u043e\u0435 \u0441\u043e\u0431\u044b\u0442\u0438\u0435: \u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0440\u0430\u0443\u043d\u0434\u0430 \u043a\u043e\u043d\u043a\u0443\u0440\u0441\u0430(<a href=\"http:\/\/habrahabr.ru\/post\/109946\/\">\u0440\u0430\u0437<\/a>, ,<a href=\"http:\/\/habrahabr.ru\/post\/152136\/\">\u0434\u0432\u0430<\/a>, <a href=\"http:\/\/habrahabr.ru\/post\/153349\/\">\u0442\u0440\u0438<\/a>), \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u043b\u043e\u0441\u044c <a href=\"http:\/\/habrahabr.ru\/post\/159073\/\">\u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435<\/a> \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430, \u0438 \u0434\u0430\u0436\u0435 <a href=\"http:\/\/habrahabr.ru\/post\/168707\/\">\u043e\u0431\u044a\u044f\u0441\u043d\u044f\u043b\u043e\u0441\u044c<\/a> \u043f\u043e\u0447\u0435\u043c\u0443 \u043d\u043e\u0432\u044b\u0439 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0442\u0430\u043a \u043a\u0440\u0443\u0442. <br \/>  \u041e\u0434\u043d\u0430\u043a\u043e, \u0437\u0430 \u0432\u0441\u0435\u043c \u044d\u0442\u0438\u043c \u0430\u0436\u0438\u043e\u0442\u0430\u0436\u0435\u043c \u0441\u043e\u0432\u0441\u0435\u043c \u043d\u0435\u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u044b\u043c \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0434\u0440\u0443\u0433\u043e\u0435, \u043d\u0435 \u043c\u0435\u043d\u0435\u0435 \u0437\u043d\u0430\u0447\u0438\u043c\u043e\u0435 \u0441\u043e\u0431\u044b\u0442\u0438\u0435: 1 \u044f\u043d\u0432\u0430\u0440\u044f 2013 \u0433\u043e\u0434\u0430 \u0432 \u0420\u0424 \u0442\u0430\u043a\u0436\u0435 \u0441\u043c\u0435\u043d\u0438\u043b\u0441\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442 \u0445\u0435\u0448-\u0444\u0443\u043d\u043a\u0446\u0438\u0438. <br \/>  \u0418\u0442\u0430\u043a, \u0432\u0441\u0442\u0440\u0435\u0447\u0430\u0439\u0442\u0435: \u043f\u043e\u043b\u043d\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 \u0438 \u0435\u0433\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430 C#. \u041a\u0430\u043a \u0433\u043e\u0432\u043e\u0440\u0438\u0442\u0441\u044f, \u043b\u0443\u0447\u0448\u0435 \u043f\u043e\u0437\u0434\u043d\u043e, \u0447\u0435\u043c \u043d\u0438\u043a\u043e\u0433\u0434\u0430.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-188152","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/188152","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=188152"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/188152\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=188152"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=188152"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=188152"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}