Fixed carry propagation bug in P-256 'm62' implementation (found by Auke Zeilstra...
[BearSSL] / src / x509 / asn1.t0
index 6732f9d..c329514 100644 (file)
@@ -278,7 +278,7 @@ cc: get32 ( addr -- val ) {
        0x80 - dup ifnot ERR_X509_INDEFINITE_LENGTH fail then
 
        \ Masking out bit 7, this yields the number of bytes over which
-       \ the value is encoded. Since the total certicate length must
+       \ the value is encoded. Since the total certificate length must
        \ fit over 3 bytes (this is a consequence of SSL/TLS message
        \ format), we can reject big lengths and keep the length in a
        \ single integer.
@@ -480,7 +480,7 @@ OID: id-at-commonName            2.5.4.3
 \ 66 noncharacters, and also the surrogate range; this function does NOT
 \ check that the value is in the 0..10FFFF range.
 : valid-unicode? ( val -- bool )
-       dup 0xFDD0 0xFEDF between? if drop 0 ret then
+       dup 0xFDD0 0xFDEF between? if drop 0 ret then
        dup 0xD800 0xDFFF between? if drop 0 ret then
        0xFFFF and 0xFFFE < ;