aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pubkey/sm2
Commit message (Collapse)AuthorAgeFilesLines
* Use blinded_base_point_multiply_x in the various signature schemesJack Lloyd2018-03-081-4/+4
|
* Add mixed (J+A) point addition, new scalar mul for base pointsJack Lloyd2018-03-081-7/+7
| | | | | | | | | Adds PointGFp::force_affine(), ::add_affine(), and ::is_affine() Use a (very simple) technique for base point precomputations. Stick with fixed window for variable point inputs. Scalar blinding is now always enabled
* Add functions to EC_Group for getting base point coordinatesJack Lloyd2018-02-251-2/+2
|
* New API for blinded ECC point multiplicationJack Lloyd2018-02-212-16/+18
| | | | No shared state
* Further simplifications in SM2 codeJack Lloyd2018-02-182-14/+14
|
* Add point_multiply operation to EC_GroupJack Lloyd2018-02-181-1/+1
| | | | Allows precomputations in the future.
* Add functions to reduce integers mod the order to EC_GroupJack Lloyd2018-02-181-22/+16
| | | | | | This allows calculating the Barett reduction params just once, when the group is initialized, then sharing them across all operations which use that group.
* Use shared representation of EC_GroupJack Lloyd2018-01-312-6/+6
| | | | Hide CurveGFp with an eye for eventual removal
* Expose SM2_compute_zaJack Lloyd2018-01-121-6/+7
| | | | | Was already supposed to be public, which is why it's declared in a public header - just missed the export annotation.
* Change default userid for SM2 signatures.Daniel Wyatt2018-01-041-0/+12
| | | | | GM/T 0009-2012 apparently specifies that this should default to the 16-byte hex sequence 31,32,33,34,35,36,37,38,31,32,33,34,35,36,37,38.
* Apply final annotations to the library alsoJack Lloyd2017-09-223-5/+5
| | | | | Done by a perl script which converted all classes to final, followed by selective reversion where it caused compilation failures.
* Update SM2 to use ASN.1 encoding for ciphertextsJack Lloyd2017-09-202-27/+32
| | | | | | | | | There are in fact 3 different variations of SM2 standard, first C1||C2||C3, then C1||C3||C2, then (most recently) an ASN.1 encoding. This makes us compatible with GmSSL This work was sponsored by Ribose Inc (@riboseinc).
* Change header guard format to BOTAN_FOO_H_Jack Lloyd2017-09-202-4/+4
| | | | | | ISO C++ reserves names with double underscores in them Closes #512
* Complete the final annotation changesJack Lloyd2017-09-192-4/+4
|
* Use constant_time_compare instead of same_memJack Lloyd2017-09-161-1/+1
| | | | New name, same great operation
* Change SM2 encryption to match updated standard.Jack Lloyd2017-09-101-5/+5
| | | | | | | | Unfortunately it seems the SM2 format changed between 2010 and 2012, now the ciphertext is C1 || C3 || C2. Unfortunate no matter how you slice it, but at least it's easy to convert from one form to another.
* Bump version for SM2Jack Lloyd2017-09-071-1/+1
| | | | | | To reflect support for arbitrary hashes [ci skip]
* Support arbitrary hashes for SM2 signaturesJack Lloyd2017-09-061-7/+37
| | | | This is a contribution from Ribose Inc
* Remove unused memberJack Lloyd2017-09-061-1/+0
|
* Support arbitrary hashes for SM2 encryptionJack Lloyd2017-09-051-12/+17
| | | | This is a contribution from Ribose Inc.
* Add SM2 encryption schemeJack Lloyd2017-08-045-11/+340
| | | | This is a contribution from Ribose Inc (@riboseinc)
* Remove debug printsJack Lloyd2017-06-301-17/+1
|
* Add SM2 signature schemeJack Lloyd2017-06-293-0/+345
From https://tools.ietf.org/html/draft-shen-sm2-ecdsa-02 This is a contribution from Ribose Inc (@riboseinc).