pub struct Sm2WithSm3Verifier;sm2 only.Expand description
Verifies SM2 signatures over SM3 (GB/T 32918).
§Scope
Nine self-issued roots in third_party/trust-stores/cn-sm2/ are
signed this way: four from the China Financial Certification
Authority, two from UniTrust, two from GDCA and NRCAC’s ROOTCA.
Before this verifier they reported
UnsupportedAlgorithm,
which was accurate and unhelpful.
The signer’s distinguishing identifier is
SM2_DEFAULT_DISTID; see there for why SM2 needs one at all and
why a certificate’s is not configurable.
§Not a legacy primitive
Unlike RsaPkcs1v15Sha1Verifier or
RsaPkcs1v15Ripemd160Verifier, this is in the rustcrypto
umbrella and on by default. Those two are named rather than linked
on purpose: they are gated on rsa-sha1 and rsa-ripemd160, which
rustcrypto does not include, so under the default feature set the
links have no targets – which is the whole point the sentence is
making. SM2 is a current national standard with
no published break, and the roots using it are in production.
Verification only.