Commit Graph

844 Commits

Author SHA1 Message Date
Zhi Guan
2e6cef2999 Change sm4_cl_encrypt to sm4_cl_ctr32_encrypt 2024-04-23 22:39:43 +08:00
Zhi Guan
2e45b3fbe1 Add zuc speed test 2024-04-23 09:57:44 +08:00
Zhi Guan
329b539c50 Add sm9 speed test 2024-04-23 09:57:37 +08:00
Zhi Guan
fa5bf0e3a8 Add sm4_cl speed test 2024-04-22 22:59:02 +08:00
Zhi Guan
242bbb3f6d Add speed tests 2024-04-22 22:46:23 +08:00
Zhi Guan
ae2f635b7f Fix SM4-CCM counter overflow bug
Need test vectors to check the correctness
2024-04-22 17:43:29 +08:00
Zhi Guan
e05fd9c1b9 Use Montgomery's Trick on sm2_fast_sign_pre_compute 2024-04-22 17:43:05 +08:00
Zhi Guan
bdd2149dc8 Merge pull request #1663 from Gorachya/master
Faster pairing
2024-04-22 12:13:33 +08:00
Gorachya
d1131455b6 Update sm9test.c 2024-04-22 12:00:29 +08:00
Gorachya
797c7739f3 Update sm9_z256.h 2024-04-22 11:58:16 +08:00
Gorachya
5775cb5f42 Add files via upload 2024-04-22 11:55:14 +08:00
Gorachya
3fb7eebba8 Add files via upload 2024-04-22 11:34:30 +08:00
Zhi Guan
506ab2711c Delete sha3.h 2024-04-21 23:58:05 +08:00
Zhi Guan
b2e334bfb9 FIX GCM counter bug, change inc128 to inc32 2024-04-21 23:58:01 +08:00
Zhi Guan
252c9e1765 Add more SM4 test vectors
SM4 pass openssl and other known test vectors. SM4-GCM and SM4-XTS only support the GB/T GF(2^128) encoding standard.
2024-04-21 10:10:46 +08:00
Zhi Guan
a485fa0b10 Fix SM4-CCM bug in length encoding 2024-04-21 10:09:31 +08:00
Zhi Guan
afd9682254 Merge pull request #1660 from Gorachya/master
Add SM2_mont_mul_2_way for NEON
2024-04-20 12:53:52 +08:00
Simon
f3fb2ee94b Update README.md 2024-04-20 12:26:32 +08:00
Simon
350e91af0a 修复Windows编译的问题。
将Windows CI单独拿出来。在Windows环境下编译需要在cmake的时候增加-DWIN32=ON参数。
2024-04-20 12:23:30 +08:00
Zhi Guan
6f870889cf Adjust digest APIs 2024-04-19 21:14:10 +08:00
Zhi Guan
8cb306ad0b Adjust SM3 SM4 API
Remove sm3_digest. Use more _gmssl_export
2024-04-19 18:32:06 +08:00
Gorachya
bab131604f Update CMakeLists.txt 2024-04-19 17:56:47 +08:00
Gorachya
36f256913d Update sm2_z256.c 2024-04-19 17:55:28 +08:00
Zhi Guan
ab7c9a7651 Adjust SM2 API and tests 2024-04-19 17:32:54 +08:00
Zhi Guan
725817add9 Use sm3_pbkdf2 without digest API 2024-04-19 13:21:52 +08:00
Zhi Guan
356e618d99 Add sm2_key test 2024-04-18 22:01:50 +08:00
Zhi Guan
b2707a1f0e Adjust SM9 files 2024-04-18 21:41:17 +08:00
Zhi Guan
e9bbcf5490 Use z256 and jacobian coordinates as inner presentation of SM2 point 2024-04-18 21:27:00 +08:00
Zhi Guan
549c68d2df Re-organize SM2 files 2024-04-17 22:43:04 +08:00
Zhi Guan
2a5dc640bd Remove some modn functions 2024-04-17 20:55:20 +08:00
Zhi Guan
3a6bfbe03f Merge pull request #1655 from ohos-rs/master
fix(include): FILE deps on stdio header
2024-04-17 20:43:53 +08:00
Zhi Guan
42e55d249d Merge pull request #1649 from fnMrRice/master
Fix link error when link as static library with OpenSSL
2024-04-17 20:43:00 +08:00
Zhi Guan
fbad76e807 Update CMakeLists.txt 2024-04-17 15:47:28 +08:00
Zhi Guan
b01ad79475 Update sm9test.c 2024-04-17 15:44:56 +08:00
Zhi Guan
5d40024f14 Update SM9 to/from_hex API 2024-04-17 15:42:47 +08:00
Zhi Guan
c79084ad03 Remove sm9 modp to/from bytes/hex 2024-04-17 09:09:37 +08:00
Zhi Guan
c32cb0f8e4 Add sm3_pbkdf2 function
digest.h will be removed in the future.
2024-04-16 23:04:18 +08:00
Zhi Guan
f0e70bbb4d Rename SM2_Z256 to sm2_z256_t 2024-04-16 22:58:07 +08:00
Zhi Guan
6028d1e10b Rename POINT_AFFINE to AFFINE_POINT 2024-04-16 22:51:38 +08:00
Zhi Guan
4e66f911d0 Update rand_range functions
`rand_range` will stop and return 0 if the `range` is too small. Caller can call it again or stop. `rand_range` return -1 only if RNG failure.
2024-04-16 22:49:59 +08:00
Zhi Guan
e061dda71f Remove modp_to_bytes 2024-04-16 22:27:59 +08:00
Zhi Guan
b2a5885e23 Update sm9.h 2024-04-16 19:23:14 +08:00
Zhi Guan
9083a7a60b Rename SM2 file names 2024-04-16 19:20:35 +08:00
Zhi Guan
fea2b018dc Rename SM9 file names 2024-04-16 19:18:07 +08:00
Zhi Guan
b519f973b9 Delete sm2_uint128test.c 2024-04-16 19:04:17 +08:00
Zhi Guan
ddda806267 Change function names 2024-04-16 19:03:05 +08:00
Zhi Guan
1b69de3820 Update sm9_z256_alg.c 2024-04-16 11:22:35 +08:00
Zhi Guan
afed7a0ecb Make SDF/SKF optional in CMake 2024-04-15 08:49:16 +08:00
Zhi Guan
bd12c4ef50 Update tls.c 2024-04-15 08:48:40 +08:00
Zhi Guan
56f45c8dbf Remove warnings 2024-04-14 11:20:45 +08:00