<?xml version='1.0' encoding='utf-8'?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" version="3" category="info" docName="draft-dolmatov-magma-06" indexInclude="true" ipr="trust200902" number="8891" prepTime="2020-09-14T22:24:03" scripts="Common,Latin" sortRefs="true" submissionType="independent" symRefs="true" tocDepth="3" tocInclude="true" updates="5830" xml:lang="en">
  <link href="https://datatracker.ietf.org/doc/draft-dolmatov-magma-06" rel="prev"/>
  <link href="https://dx.doi.org/10.17487/rfc8891" rel="alternate"/>
  <link href="urn:issn:2070-1721" rel="alternate"/>
  <front>
    <title>GOST R 34.12-2015: Block Cipher "Magma"</title>
    <seriesInfo name="RFC" value="8891" stream="independent"/>
    <author fullname="Vasily Dolmatov" initials="V." surname="Dolmatov" role="editor">
      <organization showOnFrontPage="true">JSC "NPK Kryptonite"</organization>
      <address>
        <postal>
          <street>Spartakovskaya sq., 14, bld 2, JSC "NPK Kryptonite"</street>
          <city>Moscow</city>
          <region/>
          <code>105082</code>
          <country>Russian Federation</country>
        </postal>
        <email>vdolmatov@gmail.com</email>
      </address>
    </author>
    <author fullname="Dmitry Baryshkov" initials="D." surname="Baryshkov">
      <organization showOnFrontPage="true">Auriga, Inc.</organization>
      <address>
        <postal>
          <street>Torfyanaya Doroga, 7F</street>
          <extaddr>office 1410</extaddr>
          <city>Saint-Petersburg</city>
          <region/>
          <code>197374</code>
          <country>Russian Federation</country>
        </postal>
        <email>dbaryshkov@gmail.com</email>
      </address>
    </author>
    <date month="09" year="2020"/>
    <keyword>Magma</keyword>
    <keyword>Block Cipher</keyword>
    <abstract pn="section-abstract">
      <t indent="0" pn="section-abstract-1">In addition to a new cipher with a block length of n=128 bits (referred
        to as "Kuznyechik" and described in RFC 7801), Russian Federal standard
        GOST R 34.12-2015 includes an updated version of the block
        cipher with a block length of n=64 bits and key length of k=256 bits, which
        is also referred to as "Magma". The algorithm is an updated version of
        an older block cipher with a block length of n=64 bits described in GOST
        28147-89 (RFC 5830). This document is intended to be a source
        of information about the updated version of the 64-bit cipher. It may
        facilitate the use of the block cipher in Internet applications by
        providing information for developers and users of the GOST 64-bit
        cipher with the revised version of the cipher for encryption and
        decryption.</t>
    </abstract>
    <boilerplate>
      <section anchor="status-of-memo" numbered="false" removeInRFC="false" toc="exclude" pn="section-boilerplate.1">
        <name slugifiedName="name-status-of-this-memo">Status of This Memo</name>
        <t indent="0" pn="section-boilerplate.1-1">
            This document is not an Internet Standards Track specification; it is
            published for informational purposes.
        </t>
        <t indent="0" pn="section-boilerplate.1-2">
            This is a contribution to the RFC Series, independently of any
            other RFC stream.  The RFC Editor has chosen to publish this
            document at its discretion and makes no statement about its value
            for implementation or deployment.  Documents approved for
            publication by the RFC Editor are not candidates for any level of
            Internet Standard; see Section 2 of RFC 7841.
        </t>
        <t indent="0" pn="section-boilerplate.1-3">
            Information about the current status of this document, any
            errata, and how to provide feedback on it may be obtained at
            <eref target="https://www.rfc-editor.org/info/rfc8891" brackets="none"/>.
        </t>
      </section>
      <section anchor="copyright" numbered="false" removeInRFC="false" toc="exclude" pn="section-boilerplate.2">
        <name slugifiedName="name-copyright-notice">Copyright Notice</name>
        <t indent="0" pn="section-boilerplate.2-1">
            Copyright (c) 2020 IETF Trust and the persons identified as the
            document authors. All rights reserved.
        </t>
        <t indent="0" pn="section-boilerplate.2-2">
            This document is subject to BCP 78 and the IETF Trust's Legal
            Provisions Relating to IETF Documents
            (<eref target="https://trustee.ietf.org/license-info" brackets="none"/>) in effect on the date of
            publication of this document. Please review these documents
            carefully, as they describe your rights and restrictions with
            respect to this document.
        </t>
      </section>
    </boilerplate>
    <toc>
      <section anchor="toc" numbered="false" removeInRFC="false" toc="exclude" pn="section-toc.1">
        <name slugifiedName="name-table-of-contents">Table of Contents</name>
        <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1">
          <li pn="section-toc.1-1.1">
            <t indent="0" keepWithNext="true" pn="section-toc.1-1.1.1"><xref derivedContent="1" format="counter" sectionFormat="of" target="section-1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-introduction">Introduction</xref></t>
          </li>
          <li pn="section-toc.1-1.2">
            <t indent="0" keepWithNext="true" pn="section-toc.1-1.2.1"><xref derivedContent="2" format="counter" sectionFormat="of" target="section-2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-general-information">General Information</xref></t>
          </li>
          <li pn="section-toc.1-1.3">
            <t indent="0" pn="section-toc.1-1.3.1"><xref derivedContent="3" format="counter" sectionFormat="of" target="section-3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-definitions-and-notation">Definitions and Notation</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.3.2">
              <li pn="section-toc.1-1.3.2.1">
                <t indent="0" keepWithNext="true" pn="section-toc.1-1.3.2.1.1"><xref derivedContent="3.1" format="counter" sectionFormat="of" target="section-3.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-definitions">Definitions</xref></t>
              </li>
              <li pn="section-toc.1-1.3.2.2">
                <t indent="0" pn="section-toc.1-1.3.2.2.1"><xref derivedContent="3.2" format="counter" sectionFormat="of" target="section-3.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-notation">Notation</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.4">
            <t indent="0" pn="section-toc.1-1.4.1"><xref derivedContent="4" format="counter" sectionFormat="of" target="section-4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-parameter-values">Parameter Values</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.4.2">
              <li pn="section-toc.1-1.4.2.1">
                <t indent="0" pn="section-toc.1-1.4.2.1.1"><xref derivedContent="4.1" format="counter" sectionFormat="of" target="section-4.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-nonlinear-bijection">Nonlinear Bijection</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.2">
                <t indent="0" pn="section-toc.1-1.4.2.2.1"><xref derivedContent="4.2" format="counter" sectionFormat="of" target="section-4.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transformations">Transformations</xref></t>
              </li>
              <li pn="section-toc.1-1.4.2.3">
                <t indent="0" pn="section-toc.1-1.4.2.3.1"><xref derivedContent="4.3" format="counter" sectionFormat="of" target="section-4.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-key-schedule">Key Schedule</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.5">
            <t indent="0" pn="section-toc.1-1.5.1"><xref derivedContent="5" format="counter" sectionFormat="of" target="section-5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-basic-encryption-algorithm">Basic Encryption Algorithm</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.5.2">
              <li pn="section-toc.1-1.5.2.1">
                <t indent="0" pn="section-toc.1-1.5.2.1.1"><xref derivedContent="5.1" format="counter" sectionFormat="of" target="section-5.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-encryption">Encryption</xref></t>
              </li>
              <li pn="section-toc.1-1.5.2.2">
                <t indent="0" pn="section-toc.1-1.5.2.2.1"><xref derivedContent="5.2" format="counter" sectionFormat="of" target="section-5.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-decryption">Decryption</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.6">
            <t indent="0" pn="section-toc.1-1.6.1"><xref derivedContent="6" format="counter" sectionFormat="of" target="section-6"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-iana-considerations">IANA Considerations</xref></t>
          </li>
          <li pn="section-toc.1-1.7">
            <t indent="0" pn="section-toc.1-1.7.1"><xref derivedContent="7" format="counter" sectionFormat="of" target="section-7"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-security-considerations">Security Considerations</xref></t>
          </li>
          <li pn="section-toc.1-1.8">
            <t indent="0" pn="section-toc.1-1.8.1"><xref derivedContent="8" format="counter" sectionFormat="of" target="section-8"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-references">References</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.8.2">
              <li pn="section-toc.1-1.8.2.1">
                <t indent="0" pn="section-toc.1-1.8.2.1.1"><xref derivedContent="8.1" format="counter" sectionFormat="of" target="section-8.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-normative-references">Normative References</xref></t>
              </li>
              <li pn="section-toc.1-1.8.2.2">
                <t indent="0" pn="section-toc.1-1.8.2.2.1"><xref derivedContent="8.2" format="counter" sectionFormat="of" target="section-8.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-informative-references">Informative References</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.9">
            <t indent="0" pn="section-toc.1-1.9.1"><xref derivedContent="Appendix A" format="default" sectionFormat="of" target="section-appendix.a"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-test-examples">Test Examples</xref></t>
            <ul bare="true" empty="true" indent="2" spacing="compact" pn="section-toc.1-1.9.2">
              <li pn="section-toc.1-1.9.2.1">
                <t indent="0" pn="section-toc.1-1.9.2.1.1"><xref derivedContent="A.1" format="counter" sectionFormat="of" target="section-a.1"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transformation-t">Transformation t</xref></t>
              </li>
              <li pn="section-toc.1-1.9.2.2">
                <t indent="0" pn="section-toc.1-1.9.2.2.1"><xref derivedContent="A.2" format="counter" sectionFormat="of" target="section-a.2"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-transformation-g">Transformation g</xref></t>
              </li>
              <li pn="section-toc.1-1.9.2.3">
                <t indent="0" pn="section-toc.1-1.9.2.3.1"><xref derivedContent="A.3" format="counter" sectionFormat="of" target="section-a.3"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-key-schedule-2">Key Schedule</xref></t>
              </li>
              <li pn="section-toc.1-1.9.2.4">
                <t indent="0" pn="section-toc.1-1.9.2.4.1"><xref derivedContent="A.4" format="counter" sectionFormat="of" target="section-a.4"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-test-encryption">Test Encryption</xref></t>
              </li>
              <li pn="section-toc.1-1.9.2.5">
                <t indent="0" pn="section-toc.1-1.9.2.5.1"><xref derivedContent="A.5" format="counter" sectionFormat="of" target="section-a.5"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-test-decryption">Test Decryption</xref></t>
              </li>
            </ul>
          </li>
          <li pn="section-toc.1-1.10">
            <t indent="0" pn="section-toc.1-1.10.1"><xref derivedContent="Appendix B" format="default" sectionFormat="of" target="section-appendix.b"/>.  <xref derivedContent="" format="title" sectionFormat="of" target="name-background">Background</xref></t>
          </li>
          <li pn="section-toc.1-1.11">
            <t indent="0" pn="section-toc.1-1.11.1"><xref derivedContent="" format="none" sectionFormat="of" target="section-appendix.c"/><xref derivedContent="" format="title" sectionFormat="of" target="name-authors-addresses">Authors' Addresses</xref></t>
          </li>
        </ul>
      </section>
    </toc>
  </front>
  <middle>
    <section numbered="true" toc="include" removeInRFC="false" pn="section-1">
      <name slugifiedName="name-introduction">Introduction</name>
      <t indent="0" pn="section-1-1">The Russian Federal standard <xref target="GOSTR3412-2015" format="default" sectionFormat="of" derivedContent="GOSTR3412-2015"/>
      specifies basic block ciphers used as cryptographic techniques for
      information processing and information protection, including the
      provision of confidentiality, authenticity, and integrity of information
      during information transmission, processing, and storage in
      computer-aided systems.</t>
      <t indent="0" pn="section-1-2">The cryptographic algorithms defined in this specification are
	designed both for hardware and software implementation. They comply
	with modern cryptographic requirements and put no restrictions on the
	confidentiality level of the protected information.</t>
      <t indent="0" pn="section-1-3">This document is intended to be a source of information about the
        updated version of the 64-bit cipher.  It may facilitate the use of the
        block cipher in Internet applications by providing information for
        developers and users of a GOST 64-bit cipher with the revised version of
        the cipher for encryption and decryption.</t>
    </section>
    <section numbered="true" toc="include" removeInRFC="false" pn="section-2">
      <name slugifiedName="name-general-information">General Information</name>
      <t indent="0" pn="section-2-1">The Russian Federal standard <xref target="GOSTR3412-2015" format="default" sectionFormat="of" derivedContent="GOSTR3412-2015"/> was
      developed by the Center for Information Protection and Special
      Communications of the Federal Security Service of the Russian Federation,
      with participation of the open joint-stock company "Information
      Technologies and Communication Systems" (InfoTeCS JSC). GOST R
      34.12-2015 was approved and introduced by Decree #749 of the Federal
      Agency on Technical Regulating and Metrology on June 19, 2015.</t>
      <t indent="0" pn="section-2-2">Terms and concepts in the specification comply with the following
      international standards: </t>
      <ul spacing="normal" bare="false" empty="false" indent="3" pn="section-2-3">
        <li pn="section-2-3.1">ISO/IEC 10116 <xref target="ISO-IEC10116" format="default" sectionFormat="of" derivedContent="ISO-IEC10116"/></li>
        <li pn="section-2-3.2">series of standards ISO/IEC 18033 <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/><xref target="ISO-IEC18033-3" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-3"/></li>
      </ul>
    </section>
    <section anchor="section_defs_notation" numbered="true" toc="include" removeInRFC="false" pn="section-3">
      <name slugifiedName="name-definitions-and-notation">Definitions and Notation</name>
      <t indent="0" pn="section-3-1">The following terms and their corresponding definitions are used in
      the specification.</t>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-3.1">
        <name slugifiedName="name-definitions">Definitions</name>
        <dl indent="3" newline="false" spacing="normal" pn="section-3.1-1">
          <dt pn="section-3.1-1.1">encryption algorithm:</dt>
          <dd pn="section-3.1-1.2">process that transforms plaintext into
            ciphertext (Clause 2.19 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.3">decryption algorithm:</dt>
          <dd pn="section-3.1-1.4">process that transforms ciphertext into
            plaintext (Clause 2.14 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.5">basic block cipher:</dt>
          <dd pn="section-3.1-1.6">block cipher that, for a given key, provides
            a single invertible mapping of the set of fixed-length plaintext
            blocks into ciphertext blocks of the same length</dd>
          <dt pn="section-3.1-1.7">block:</dt>
          <dd pn="section-3.1-1.8">string of bits of a defined length (Clause 2.6 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.9">block cipher:</dt>
          <dd pn="section-3.1-1.10">
            <t indent="0" pn="section-3.1-1.10.1">symmetric encipherment system with the property
            that the encryption algorithm operates on a block of plaintext --
	    i.e., a string of bits of a defined length -- to yield a block of
            ciphertext (Clause 2.7 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</t>
            <t indent="0" pn="section-3.1-1.10.2">Note: In GOST R 34.12-2015, it is established that the
                terms "block cipher" and "block encryption algorithm" are
                synonyms.</t>
          </dd>
          <dt pn="section-3.1-1.11">encryption:</dt>
          <dd pn="section-3.1-1.12">reversible transformation of data by a
            cryptographic algorithm to produce ciphertext -- i.e., to hide the
            information content of the data (Clause 2.18 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.13">round key:</dt>
          <dd pn="section-3.1-1.14">sequence of symbols that is calculated from the key
            and controls a transformation for one round of a block cipher</dd>
          <dt pn="section-3.1-1.15">key:</dt>
          <dd pn="section-3.1-1.16">
            <t indent="0" pn="section-3.1-1.16.1">sequence of symbols that controls the operation of a
            cryptographic transformation (e.g., encipherment, decipherment)
            (Clause 2.21 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</t>
            <t indent="0" pn="section-3.1-1.16.2">Note: In GOST R 34.12-2015, the key must be a binary
                sequence.</t>
          </dd>
          <dt pn="section-3.1-1.17">plaintext:</dt>
          <dd pn="section-3.1-1.18">unencrypted information (Clause 3.11 of <xref target="ISO-IEC10116" format="default" sectionFormat="of" derivedContent="ISO-IEC10116"/>)</dd>
          <dt pn="section-3.1-1.19">key schedule:</dt>
          <dd pn="section-3.1-1.20">calculation of round keys from the key,</dd>
          <dt pn="section-3.1-1.21">decryption:</dt>
          <dd pn="section-3.1-1.22">reversal of a corresponding encipherment (Clause
            2.13 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.23">symmetric cryptographic technique:</dt>
          <dd pn="section-3.1-1.24">cryptographic technique that
            uses the same secret key for both the originator's and the
            recipient's transformation (Clause 2.32 of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.25">cipher:</dt>
          <dd pn="section-3.1-1.26">alternative term for encipherment system (Clause 2.20
            of <xref target="ISO-IEC18033-1" format="default" sectionFormat="of" derivedContent="ISO-IEC18033-1"/>)</dd>
          <dt pn="section-3.1-1.27">ciphertext:</dt>
          <dd pn="section-3.1-1.28">data that has been transformed to hide its
            information content (Clause 3.3 of <xref target="ISO-IEC10116" format="default" sectionFormat="of" derivedContent="ISO-IEC10116"/>)</dd>
        </dl>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-3.2">
        <name slugifiedName="name-notation">Notation</name>
        <t indent="0" pn="section-3.2-1">The following notation is used in the specification: </t>
        <dl newline="false" spacing="normal" indent="3" pn="section-3.2-2">
          <dt pn="section-3.2-2.1">V*</dt>
          <dd pn="section-3.2-2.2">the set of all binary vector strings of a
            finite length (hereinafter referred to as the strings), including
            the empty string</dd>
          <dt pn="section-3.2-2.3">V_s</dt>
          <dd pn="section-3.2-2.4">the set of all binary strings of length s,
            where s is a nonnegative integer; substrings and string
            components are enumerated from right to left, starting from
            zero</dd>
          <dt pn="section-3.2-2.5">U[*]W</dt>
          <dd pn="section-3.2-2.6">direct (Cartesian) product of two sets U and W</dd>
          <dt pn="section-3.2-2.7">|A|</dt>
          <dd pn="section-3.2-2.8">the number of components (the length) of a
            string A belonging to V* (if A is an empty string, then |A| =
	  0)</dd>
          <dt pn="section-3.2-2.9">A||B</dt>
          <dd pn="section-3.2-2.10">concatenation of strings A and B both
            belonging to V* -- i.e., a string from V_(|A|+|B|), where the left
            substring from V_|A| is equal to A and the right substring from
            V_|B| is equal to B</dd>
          <dt pn="section-3.2-2.11">A&lt;&lt;&lt;_11</dt>
          <dd pn="section-3.2-2.12">cyclic rotation of string A
            belonging to V_32 by 11 components in the direction of components
            having greater indices</dd>
          <dt pn="section-3.2-2.13">Z_(2^n)</dt>
          <dd pn="section-3.2-2.14">ring of residues modulo 2^n</dd>
          <dt pn="section-3.2-2.15">(xor)</dt>
          <dd pn="section-3.2-2.16">exclusive-or of two binary strings of the same length</dd>
          <dt pn="section-3.2-2.17">[+]</dt>
          <dd pn="section-3.2-2.18">addition in the ring Z_(2^32)</dd>
          <dt pn="section-3.2-2.19">Vec_s: Z_(2^s) -&gt; V_s</dt>
          <dd pn="section-3.2-2.20">bijective mapping that maps an element from ring Z_(2^s) into
	  its binary representation; i.e., for an element z of the
	  ring Z_(2^s), represented by the
            residue z_0 + (2*z_1) + ... + (2^(s-1)*z_(s-1)), where z_i in {0,
            1}, i = 0, ..., n-1, the equality Vec_s(z) =
            z_(s-1)||...||z_1||z_0 holds</dd>
          <dt pn="section-3.2-2.21">Int_s: V_s -&gt; Z_(2^s)</dt>
          <dd pn="section-3.2-2.22">the mapping inverse to the mapping Vec_s, i.e., Int_s =
	  Vec_s^(-1)</dd>
          <dt pn="section-3.2-2.23">PS</dt>
          <dd pn="section-3.2-2.24">composition of mappings, where the mapping
            S applies first</dd>
          <dt pn="section-3.2-2.25">P^s</dt>
          <dd pn="section-3.2-2.26">composition of mappings P^(s-1) and P, where P^1=P</dd>
        </dl>
      </section>
    </section>
    <section numbered="true" toc="include" removeInRFC="false" pn="section-4">
      <name slugifiedName="name-parameter-values">Parameter Values</name>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-4.1">
        <name slugifiedName="name-nonlinear-bijection">Nonlinear Bijection</name>
        <t indent="0" pn="section-4.1-1">The bijective nonlinear mapping is a set of substitutions:</t>
        <artwork name="" type="" align="left" alt="" pn="section-4.1-2">
Pi_i = Vec_4 Pi'_i Int_4: V_4 -&gt; V_4,
</artwork>
        <t indent="0" pn="section-4.1-3">where</t>
        <artwork name="" type="" align="left" alt="" pn="section-4.1-4">
Pi'_i: Z_(2^4) -&gt; Z_(2^4), i = 0, 1, ..., 7.
</artwork>
        <t indent="0" pn="section-4.1-5">The values of the substitution Pi' are specified below as
        arrays.</t>
        <artwork name="" type="" align="left" alt="" pn="section-4.1-6">
Pi'_i = (Pi'_i(0), Pi'_i(1), ... , Pi'_i(15)), i = 0, 1, ..., 7:

Pi'_0 = (12, 4, 6, 2, 10, 5, 11, 9, 14, 8, 13, 7, 0, 3, 15, 1);
Pi'_1 = (6, 8, 2, 3, 9, 10, 5, 12, 1, 14, 4, 7, 11, 13, 0, 15);
Pi'_2 = (11, 3, 5, 8, 2, 15, 10, 13, 14, 1, 7, 4, 12, 9, 6, 0);
Pi'_3 = (12, 8, 2, 1, 13, 4, 15, 6, 7, 0, 10, 5, 3, 14, 9, 11);
Pi'_4 = (7, 15, 5, 10, 8, 1, 6, 13, 0, 9, 3, 14, 11, 4, 2, 12);
Pi'_5 = (5, 13, 15, 6, 9, 2, 12, 10, 11, 7, 8, 1, 4, 3, 14, 0);
Pi'_6 = (8, 14, 2, 5, 6, 9, 1, 12, 15, 4, 11, 0, 13, 10, 3, 7);
Pi'_7 = (1, 7, 14, 13, 0, 5, 8, 3, 4, 15, 10, 6, 9, 12, 11, 2);</artwork>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-4.2">
        <name slugifiedName="name-transformations">Transformations</name>
        <t indent="0" pn="section-4.2-1">The following transformations are applicable for encryption and
        decryption algorithms: </t>
        <dl newline="true" spacing="normal" indent="3" pn="section-4.2-2">
          <dt pn="section-4.2-2.1">t: V_32 -&gt; V_32</dt>
          <dd pn="section-4.2-2.2">t(a) = t(a_7||...||a_0) =
            Pi_7(a_7)||...||Pi_0(a_0), where a=a_7||...||a_0 belongs to V_32,
            a_i belongs to V_4, i=0, 1, ..., 7.</dd>
          <dt pn="section-4.2-2.3">g[k]: V_32 -&gt; V_32</dt>
          <dd pn="section-4.2-2.4">g[k](a) = (t(Vec_32(Int_32(a)
            [+] Int_32(k)))) &lt;&lt;&lt;_11, where k, a belong to V_32</dd>
          <dt pn="section-4.2-2.5">G[k]: V_32[*]V_32 -&gt; V_32[*]V_32</dt>
          <dd pn="section-4.2-2.6">G[k](a_1, a_0) =
            (a_0, g[k](a_0) (xor) a_1), where k, a_0, a_1 belong to V_32</dd>
          <dt pn="section-4.2-2.7">G^*[k]: V_32[*]V_32 -&gt; V_64</dt>
          <dd pn="section-4.2-2.8">G^*[k](a_1, a_0) =
            (g[k](a_0) (xor) a_1) || a_0, where k, a_0, a_1 belong to
            V_32.</dd>
        </dl>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-4.3">
        <name slugifiedName="name-key-schedule">Key Schedule</name>
        <t indent="0" pn="section-4.3-1">Round keys K_i belonging to V_32, i=1, 2, ..., 32 are derived from
        key K = k_255||...||k_0 belonging to V_256, k_i belongs to V_1, i=0, 1,
        ..., 255, as follows:</t>
        <artwork align="left" name="" type="" alt="" pn="section-4.3-2">
K_1 = k_255||...||k_224;
K_2 = k_223||...||k_192;
K_3 = k_191||...||k_160;
K_4 = k_159||...||k_128;
K_5 = k_127||...||k_96;
K_6 = k_95||...||k_64;
K_7 = k_63||...||k_32;
K_8 = k_31||...||k_0;
K_(i+8) = K_i, i = 1, 2, ..., 8;
K_(i+16) = K_i, i = 1, 2, ..., 8;
K_(i+24) = K_(9-i), i = 1, 2, ..., 8.</artwork>
      </section>
    </section>
    <section numbered="true" toc="include" removeInRFC="false" pn="section-5">
      <name slugifiedName="name-basic-encryption-algorithm">Basic Encryption Algorithm</name>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-5.1">
        <name slugifiedName="name-encryption">Encryption</name>
        <t indent="0" pn="section-5.1-1">Depending on the values of round keys K_1,...,K_32, the encryption
        algorithm is a substitution E_⁠(K_1,...,K_32) defined as follows:</t>
        <artwork align="left" name="" type="" alt="" pn="section-5.1-2">E_(K_1,...,K_32)(a)=G^*[K_32]G[K_31]...G[K_2]G[K_1](a_1, a_0),</artwork>
        <t indent="0" pn="section-5.1-3">where a=(a_1, a_0) belongs to V_64, and a_0, a_1 belong to
        V_32.</t>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-5.2">
        <name slugifiedName="name-decryption">Decryption</name>
        <t indent="0" pn="section-5.2-1">Depending on the values of round keys K_1,...,K_32, the decryption
        algorithm is a substitution D_⁠(K_1,...,K_32) defined as follows:</t>
        <artwork align="left" name="" type="" alt="" pn="section-5.2-2">D_(K_1,...,K_32)(a)=G^*[K_1]G[K_2]...G[K_31]G[K_32](a_1, a_0),</artwork>
        <t indent="0" pn="section-5.2-3">where a=(a_1, a_0) belongs to V_64, and a_0, a_1 belong to
        V_32.</t>
      </section>
    </section>
    <section anchor="IANA" numbered="true" toc="include" removeInRFC="false" pn="section-6">
      <name slugifiedName="name-iana-considerations">IANA Considerations</name>
      <t indent="0" pn="section-6-1">This document has no IANA actions.</t>
    </section>
    <section anchor="Security" numbered="true" toc="include" removeInRFC="false" pn="section-7">
      <name slugifiedName="name-security-considerations">Security Considerations</name>
      <t indent="0" pn="section-7-1">This entire document is about security considerations.</t>
      <t indent="0" pn="section-7-2">Unlike <xref target="RFC5830" format="default" sectionFormat="of" derivedContent="RFC5830"/> (GOST 28147-89), but
      like <xref target="RFC7801" format="default" sectionFormat="of" derivedContent="RFC7801"/>, this specification does
      not define exact block
        modes that should be used together with the updated Magma cipher. One is
        free to select block modes depending on the protocol and necessity.</t>
    </section>
  </middle>
  <back>
    <references pn="section-8">
      <name slugifiedName="name-references">References</name>
      <references pn="section-8.1">
        <name slugifiedName="name-normative-references">Normative References</name>
        <reference anchor="GOSTR3412-2015" quoteTitle="true" derivedAnchor="GOSTR3412-2015">
          <front>
            <title>Information technology. Cryptographic data security. Block ciphers.</title>
            <author>
              <organization showOnFrontPage="true">Federal Agency on Technical Regulating and Metrology</organization>
            </author>
            <date year="2015"/>
          </front>
          <seriesInfo name="GOST R" value="34.12-2015"/>
        </reference>
        <reference anchor="RFC5830" target="https://www.rfc-editor.org/info/rfc5830" quoteTitle="true" derivedAnchor="RFC5830">
          <front>
            <title>GOST 28147-89: Encryption, Decryption, and Message Authentication Code (MAC) Algorithms</title>
            <author initials="V." surname="Dolmatov" fullname="V. Dolmatov" role="editor">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2010" month="March"/>
            <abstract>
              <t indent="0">This document is intended to be a source of information about the Russian Federal standard for electronic encryption, decryption, and message authentication algorithms (GOST 28147-89), which is one of the Russian cryptographic standard algorithms called GOST algorithms).  Recently, Russian cryptography is being used in Internet applications, and this document has been created as information for developers and users of GOST 28147-89 for encryption, decryption, and message authentication.   This document is not an Internet Standards Track specification; it is published for informational purposes.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="5830"/>
          <seriesInfo name="DOI" value="10.17487/RFC5830"/>
        </reference>
        <reference anchor="RFC7801" target="https://www.rfc-editor.org/info/rfc7801" quoteTitle="true" derivedAnchor="RFC7801">
          <front>
            <title>GOST R 34.12-2015: Block Cipher "Kuznyechik"</title>
            <author initials="V." surname="Dolmatov" fullname="V. Dolmatov" role="editor">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2016" month="March"/>
            <abstract>
              <t indent="0">This document is intended to be a source of information about the Russian Federal standard GOST R 34.12-2015 describing the block cipher with a block length of n=128 bits and a key length of k=256 bits, which is also referred to as "Kuznyechik".  This algorithm is one of the set of Russian cryptographic standard algorithms (called GOST algorithms).</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7801"/>
          <seriesInfo name="DOI" value="10.17487/RFC7801"/>
        </reference>
      </references>
      <references pn="section-8.2">
        <name slugifiedName="name-informative-references">Informative References</name>
        <reference anchor="GOST28147-89" quoteTitle="true" derivedAnchor="GOST28147-89">
          <front>
            <title>Cryptographic Protection for Data Processing System, GOST 28147-89, Gosudarstvennyi Standard of USSR</title>
            <author>
              <organization showOnFrontPage="true">Government Committee of the USSR for Standards</organization>
            </author>
            <date year="1989"/>
          </front>
        </reference>
        <reference anchor="ISO-IEC10116" quoteTitle="true" derivedAnchor="ISO-IEC10116">
          <front>
            <title>Information technology -- Security techniques -- Modes of operation for an n-bit block cipher</title>
            <author>
              <organization showOnFrontPage="true">ISO/IEC</organization>
            </author>
            <date year="2017"/>
          </front>
          <seriesInfo name="ISO/IEC" value="10116"/>
        </reference>
        <reference anchor="ISO-IEC18033-1" quoteTitle="true" derivedAnchor="ISO-IEC18033-1">
          <front>
            <title>Information technology -- Security techniques -- Encryption algorithms -- Part 1: General</title>
            <author>
              <organization showOnFrontPage="true">ISO/IEC</organization>
            </author>
            <date year="2015"/>
          </front>
          <seriesInfo name="ISO/IEC" value="18033-1:2015"/>
        </reference>
        <reference anchor="ISO-IEC18033-3" quoteTitle="true" derivedAnchor="ISO-IEC18033-3">
          <front>
            <title>Information technology -- Security techniques -- Encryption algorithms -- Part 3: Block ciphers</title>
            <author>
              <organization showOnFrontPage="true">ISO/IEC</organization>
            </author>
            <date year="2010"/>
          </front>
          <seriesInfo name="ISO/IEC" value="18033-3:2010"/>
        </reference>
        <reference anchor="RFC7836" target="https://www.rfc-editor.org/info/rfc7836" quoteTitle="true" derivedAnchor="RFC7836">
          <front>
            <title>Guidelines on the Cryptographic Algorithms to Accompany the Usage of Standards GOST R 34.10-2012 and GOST R 34.11-2012</title>
            <author initials="S." surname="Smyshlyaev" fullname="S. Smyshlyaev" role="editor">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="E." surname="Alekseev" fullname="E. Alekseev">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="I." surname="Oshkin" fullname="I. Oshkin">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="V." surname="Popov" fullname="V. Popov">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="S." surname="Leontiev" fullname="S. Leontiev">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="V." surname="Podobaev" fullname="V. Podobaev">
              <organization showOnFrontPage="true"/>
            </author>
            <author initials="D." surname="Belyavsky" fullname="D. Belyavsky">
              <organization showOnFrontPage="true"/>
            </author>
            <date year="2016" month="March"/>
            <abstract>
              <t indent="0">The purpose of this document is to make the specifications of the cryptographic algorithms defined by the Russian national standards GOST R 34.10-2012 and GOST R 34.11-2012 available to the Internet community for their implementation in the cryptographic protocols based on the accompanying algorithms.</t>
              <t indent="0">These specifications define the pseudorandom functions, the key agreement algorithm based on the Diffie-Hellman algorithm and a hash function, the parameters of elliptic curves, the key derivation functions, and the key export functions.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="7836"/>
          <seriesInfo name="DOI" value="10.17487/RFC7836"/>
        </reference>
      </references>
    </references>
    <section numbered="true" toc="include" removeInRFC="false" pn="section-appendix.a">
      <name slugifiedName="name-test-examples">Test Examples</name>
      <t indent="0" pn="section-appendix.a-1">This section is for information only and is not a normative part of
      the specification.</t>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-a.1">
        <name slugifiedName="name-transformation-t">Transformation t</name>
        <sourcecode type="test-vectors" markers="false" pn="section-a.1-1">t(fdb97531) = 2a196f34,
t(2a196f34) = ebd9f03a,
t(ebd9f03a) = b039bb3d,
t(b039bb3d) = 68695433.</sourcecode>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-a.2">
        <name slugifiedName="name-transformation-g">Transformation g</name>
        <sourcecode type="test-vectors" markers="false" pn="section-a.2-1">g[87654321](fedcba98) = fdcbc20c,
g[fdcbc20c](87654321) = 7e791a4b,
g[7e791a4b](fdcbc20c) = c76549ec,
g[c76549ec](7e791a4b) = 9791c849.</sourcecode>
      </section>
      <section anchor="test-ks" numbered="true" toc="include" removeInRFC="false" pn="section-a.3">
        <name slugifiedName="name-key-schedule-2">Key Schedule</name>
        <t indent="0" pn="section-a.3-1">With key set to</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.3-2">K = ffeeddccbbaa99887766554433221100f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff,</sourcecode>
        <t indent="0" pn="section-a.3-3">the following round keys are generated:</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.3-4">K_1 = ffeeddcc,
K_2 = bbaa9988,
K_3 = 77665544,
K_4 = 33221100,
K_5 = f0f1f2f3,
K_6 = f4f5f6f7,
K_7 = f8f9fafb,
K_8 = fcfdfeff,

K_9 = ffeeddcc,
K_10 = bbaa9988,
K_11 = 77665544,
K_12 = 33221100,
K_13 = f0f1f2f3,
K_14 = f4f5f6f7,
K_15 = f8f9fafb,
K_16 = fcfdfeff,

K_17 = ffeeddcc,
K_18 = bbaa9988,
K_19 = 77665544,
K_20 = 33221100,
K_21 = f0f1f2f3,
K_22 = f4f5f6f7,
K_23 = f8f9fafb,
K_24 = fcfdfeff,

K_25 = fcfdfeff,
K_26 = f8f9fafb,
K_27 = f4f5f6f7,
K_28 = f0f1f2f3,
K_29 = 33221100,
K_30 = 77665544,
K_31 = bbaa9988,
K_32 = ffeeddcc.</sourcecode>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-a.4">
        <name slugifiedName="name-test-encryption">Test Encryption</name>
        <t indent="0" pn="section-a.4-1">In this test example, encryption is performed on the round keys
        specified in <xref target="test-ks" format="default" sectionFormat="of" derivedContent="Appendix A.3"/>. Let the
        plaintext be</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.4-2">
a = fedcba9876543210,
</sourcecode>
        <t indent="0" pn="section-a.4-3">then</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.4-4">(a_1, a_0) = (fedcba98, 76543210),
G[K_1](a_1, a_0) = (76543210, 28da3b14),
G[K_2]G[K_1](a_1, a_0) = (28da3b14, b14337a5),
G[K_3]...G[K_1](a_1, a_0) = (b14337a5, 633a7c68),
G[K_4]...G[K_1](a_1, a_0) = (633a7c68, ea89c02c),
G[K_5]...G[K_1](a_1, a_0) = (ea89c02c, 11fe726d),
G[K_6]...G[K_1](a_1, a_0) = (11fe726d, ad0310a4),
G[K_7]...G[K_1](a_1, a_0) = (ad0310a4, 37d97f25),
G[K_8]...G[K_1](a_1, a_0) = (37d97f25, 46324615),
G[K_9]...G[K_1](a_1, a_0) = (46324615, ce995f2a),
G[K_10]...G[K_1](a_1, a_0) = (ce995f2a, 93c1f449),
G[K_11]...G[K_1](a_1, a_0) = (93c1f449, 4811c7ad),
G[K_12]...G[K_1](a_1, a_0) = (4811c7ad, c4b3edca),
G[K_13]...G[K_1](a_1, a_0) = (c4b3edca, 44ca5ce1),
G[K_14]...G[K_1](a_1, a_0) = (44ca5ce1, fef51b68),
G[K_15]...G[K_1](a_1, a_0) = (fef51b68, 2098cd86)
G[K_16]...G[K_1](a_1, a_0) = (2098cd86, 4f15b0bb),
G[K_17]...G[K_1](a_1, a_0) = (4f15b0bb, e32805bc),
G[K_18]...G[K_1](a_1, a_0) = (e32805bc, e7116722),
G[K_19]...G[K_1](a_1, a_0) = (e7116722, 89cadf21),
G[K_20]...G[K_1](a_1, a_0) = (89cadf21, bac8444d),
G[K_21]...G[K_1](a_1, a_0) = (bac8444d, 11263a21),
G[K_22]...G[K_1](a_1, a_0) = (11263a21, 625434c3),
G[K_23]...G[K_1](a_1, a_0) = (625434c3, 8025c0a5),
G[K_24]...G[K_1](a_1, a_0) = (8025c0a5, b0d66514),
G[K_25]...G[K_1](a_1, a_0) = (b0d66514, 47b1d5f4),
G[K_26]...G[K_1](a_1, a_0) = (47b1d5f4, c78e6d50),
G[K_27]...G[K_1](a_1, a_0) = (c78e6d50, 80251e99),
G[K_28]...G[K_1](a_1, a_0) = (80251e99, 2b96eca6),
G[K_29]...G[K_1](a_1, a_0) = (2b96eca6, 05ef4401),
G[K_30]...G[K_1](a_1, a_0) = (05ef4401, 239a4577),
G[K_31]...G[K_1](a_1, a_0) = (239a4577, c2d8ca3d).
</sourcecode>
        <t indent="0" pn="section-a.4-5">Then the ciphertext is</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.4-6">b = G^*[K_32]G[K_31]...G[K_1](a_1, a_0) = 4ee901e5c2d8ca3d.</sourcecode>
      </section>
      <section numbered="true" toc="include" removeInRFC="false" pn="section-a.5">
        <name slugifiedName="name-test-decryption">Test Decryption</name>
        <t indent="0" pn="section-a.5-1">In this test example, decryption is performed on the round keys
        specified in <xref target="test-ks" format="default" sectionFormat="of" derivedContent="Appendix A.3"/>. Let the
        ciphertext be</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.5-2">b = 4ee901e5c2d8ca3d,</sourcecode>
        <t indent="0" pn="section-a.5-3">then</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.5-4">(b_1, b_0) = (4ee901e5, c2d8ca3d),
G[K_32](b_1, b_0) = (c2d8ca3d, 239a4577),
G[K_31]G[K_32](b_1, b_0) = (239a4577, 05ef4401),
G[K_30]...G[K_32](b_1, b_0) = (05ef4401, 2b96eca6),
G[K_29]...G[K_32](b_1, b_0) = (2b96eca6, 80251e99),
G[K_28]...G[K_32](b_1, b_0) = (80251e99, c78e6d50),
G[K_27]...G[K_32](b_1, b_0) = (c78e6d50, 47b1d5f4),
G[K_26]...G[K_32](b_1, b_0) = (47b1d5f4, b0d66514),
G[K_25]...G[K_32](b_1, b_0) = (b0d66514, 8025c0a5),
G[K_24]...G[K_32](b_1, b_0) = (8025c0a5, 625434c3),
G[K_23]...G[K_32](b_1, b_0) = (625434c3, 11263a21),
G[K_22]...G[K_32](b_1, b_0) = (11263a21, bac8444d),
G[K_21]...G[K_32](b_1, b_0) = (bac8444d, 89cadf21),
G[K_20]...G[K_32](b_1, b_0) = (89cadf21, e7116722),
G[K_19]...G[K_32](b_1, b_0) = (e7116722, e32805bc),
G[K_18]...G[K_32](b_1, b_0) = (e32805bc, 4f15b0bb),
G[K_17]...G[K_32](b_1, b_0) = (4f15b0bb, 2098cd86),
G[K_16]...G[K_32](b_1, b_0) = (2098cd86, fef51b68),
G[K_15]...G[K_32](b_1, b_0) = (fef51b68, 44ca5ce1),
G[K_14]...G[K_32](b_1, b_0) = (44ca5ce1, c4b3edca),
G[K_13]...G[K_32](b_1, b_0) = (c4b3edca, 4811c7ad),
G[K_12]...G[K_32](b_1, b_0) = (4811c7ad, 93c1f449),
G[K_11]...G[K_32](b_1, b_0) = (93c1f449, ce995f2a),
G[K_10]...G[K_32](b_1, b_0) = (ce995f2a, 46324615),
G[K_9]...G[K_32](b_1, b_0) = (46324615, 37d97f25),
G[K_8]...G[K_32](b_1, b_0) = (37d97f25, ad0310a4),
G[K_7]...G[K_32](b_1, b_0) = (ad0310a4, 11fe726d),
G[K_6]...G[K_32](b_1, b_0) = (11fe726d, ea89c02c),
G[K_5]...G[K_32](b_1, b_0) = (ea89c02c, 633a7c68),
G[K_4]...G[K_32](b_1, b_0) = (633a7c68, b14337a5),
G[K_3]...G[K_32](b_1, b_0) = (b14337a5, 28da3b14),
G[K_2]...G[K_32](b_1, b_0) = (28da3b14, 76543210).
</sourcecode>
        <t indent="0" pn="section-a.5-5">Then the plaintext is</t>
        <sourcecode type="test-vectors" markers="false" pn="section-a.5-6">a = G^*[K_1]G[K_2]...G[K_32](b_1, b_0) = fedcba9876543210.</sourcecode>
      </section>
    </section>
    <section numbered="true" toc="include" removeInRFC="false" pn="section-appendix.b">
      <name slugifiedName="name-background">Background</name>
      <t indent="0" pn="section-appendix.b-1">This specification is a translation of relevant parts of the <xref target="GOSTR3412-2015" format="default" sectionFormat="of" derivedContent="GOSTR3412-2015"/> standard. The order of terms
      in both
	  parts of <xref target="section_defs_notation" format="default" sectionFormat="of" derivedContent="Section 3"/>
	  comes from the original
	  text. Combining <xref target="RFC7801" format="default" sectionFormat="of" derivedContent="RFC7801"/> with this
	  document will create a complete translation of <xref target="GOSTR3412-2015" format="default" sectionFormat="of" derivedContent="GOSTR3412-2015"/> into English.</t>
      <t indent="0" pn="section-appendix.b-2">Algorithmically, Magma is a variation of the block cipher defined in
        <xref target="RFC5830" format="default" sectionFormat="of" derivedContent="RFC5830"/> (<xref target="GOST28147-89" format="default" sectionFormat="of" derivedContent="GOST28147-89"/>)
	with the following clarifications and minor modifications:
      </t>
      <ol spacing="normal" type="1" indent="adaptive" start="1" pn="section-appendix.b-3">
        <li pn="section-appendix.b-3.1" derivedCounter="1.">S-BOX set is fixed at id-tc26-gost-28147-param-Z
	    (see <xref target="RFC7836" sectionFormat="of" section="C" format="default" derivedLink="https://rfc-editor.org/rfc/rfc7836#appendix-C" derivedContent="RFC7836"/>);</li>
        <li pn="section-appendix.b-3.2" derivedCounter="2.">key is parsed as a single big-endian integer (compared to the
	little-endian approach used in <xref target="GOST28147-89" format="default" sectionFormat="of" derivedContent="GOST28147-89"/>),
	    which results in different subkey values being used;</li>
        <li pn="section-appendix.b-3.3" derivedCounter="3.">data bytes are also parsed as a single big-endian integer (instead of being parsed as little-endian integer).</li>
      </ol>
    </section>
    <section anchor="authors-addresses" numbered="false" removeInRFC="false" toc="include" pn="section-appendix.c">
      <name slugifiedName="name-authors-addresses">Authors' Addresses</name>
      <author fullname="Vasily Dolmatov" initials="V." surname="Dolmatov" role="editor">
        <organization showOnFrontPage="true">JSC "NPK Kryptonite"</organization>
        <address>
          <postal>
            <street>Spartakovskaya sq., 14, bld 2, JSC "NPK Kryptonite"</street>
            <city>Moscow</city>
            <region/>
            <code>105082</code>
            <country>Russian Federation</country>
          </postal>
          <email>vdolmatov@gmail.com</email>
        </address>
      </author>
      <author fullname="Dmitry Baryshkov" initials="D." surname="Baryshkov">
        <organization showOnFrontPage="true">Auriga, Inc.</organization>
        <address>
          <postal>
            <street>Torfyanaya Doroga, 7F</street>
            <extaddr>office 1410</extaddr>
            <city>Saint-Petersburg</city>
            <region/>
            <code>197374</code>
            <country>Russian Federation</country>
          </postal>
          <email>dbaryshkov@gmail.com</email>
        </address>
      </author>
    </section>
  </back>
</rfc>
