diff --git a/spec/Overview.html b/spec/Overview.html index d8f02ff..981c442 100644 --- a/spec/Overview.html +++ b/spec/Overview.html @@ -625,14 +625,21 @@

Terminology

and then considering each consecutive sequence of 8 bits in that string as a byte.

- When this specification says to convert a non-negative + To convert a non-negative integer |i| to a byte sequence of length |n|, where |n| * 8 - is greater than the logarithm to base 2 of |i|, the user agent must - first calculate the binary representation of |i|, most significant bit first, + is greater than the logarithm to base 2 of |i|, + calculate the binary representation of |i|, most significant bit first, prefix this with sufficient zero bits to form a bit sequence of length |n| * 8, and then return the [= byte sequence =] formed by considering each consecutive sequence of 8 bits in that bit sequence as a byte.

+

+ To convert a byte sequence + to a non-negative integer, + interpret the byte sequence as a big-endian non-negative integer + (most significant bit first), + and return that integer. +

Comparing two strings in a case-sensitive manner means comparing them exactly, code point for code point. @@ -7135,7 +7142,7 @@

Sign
  • Perform the ECDSA signing process, as specified in [[RFC6090]], - Section 5.4, with |M| as the message, using |params| as the + Section 5.4.2, with |M| as the message, using |params| as the EC domain parameters, and with |d| as the private key.

  • @@ -7235,12 +7242,41 @@
    Verify
    |key| is "`P-256`", "`P-384`" or "`P-521`":
    -

    - Perform the ECDSA verifying process, as specified in [[RFC6090]], Section 5.3, with |M| as the received - message, |signature| as the received signature and using - |params| as the EC domain parameters, and - |Q| as the public key. -

    +
      +
    1. +

      + Let |n| be the smallest integer such that |n| * 8 is greater than + the logarithm to base 2 of the order of the base point of the elliptic curve identified + by |params|. +

      +
    2. +
    3. +

      + If |signature| does not have a [= byte sequence/length =] of |n| * 2 bytes, + then return false. +

      +
    4. +
    5. +

      + Let |r| be the result of + converting the first |n| bytes of |signature| to an integer. +

      +
    6. +
    7. +

      + Let |s| be the result of + converting the last |n| bytes of |signature| to an integer. +

      +
    8. +
    9. +

      + Perform the ECDSA verifying process, as specified in [[RFC6090]], Section 5.4.3, with |M| as the received + message, (|r|, |s|) as the signature and using + |params| as the EC domain parameters, and + |Q| as the public key. +

      +
    10. +
    Otherwise, the {{EcKeyAlgorithm/namedCurve}} attribute