Commit Graph

50 Commits

Author SHA1 Message Date
Dihambo
c96c10ea2a fix: tag mask错误 2024-09-27 12:48:55 +00:00
Zhi Guan
5821f2041d Remove warnings from clang --analyze 2024-06-18 09:25:52 +08:00
Zhi Guan
b1f25ab306 Fix DER length decoding bug
`asn1_length_from_der` incorrectly accept the BER long length.
2024-06-11 23:18:55 +08:00
Zhi Guan
76312df4d6 Clean code 2024-05-31 21:02:04 +08:00
Zhi Guan
d56eeaac5a Remove warnings 2024-05-17 13:12:51 +08:00
Wendal Chen
171a15f2b4 update: asn1_tag_index应该是常量,加上const描述
从代码逻辑可知, asn1_tag_index 是只读的
2023-03-04 01:32:42 +08:00
Zhi Guan
094db3bce0 Remove depends on ctype functions 2023-02-14 22:00:03 +08:00
Zhi Guan
6a02a61c4f Update X509 cert 2023-02-04 21:04:43 +08:00
Zhi Guan
13eae91d7d Update X.509 Extensions 2023-01-31 15:57:53 +08:00
Zhi Guan
ec7700c17c Update X509 and certgen tool 2023-01-28 22:00:22 +08:00
Zhi Guan
e3a0f73e0e Remove warnings 2023-01-15 21:02:25 +08:00
Zhi Guan
4b75346983 Refine ASN.1 functions 2023-01-15 11:59:53 +08:00
Zhi Guan
b858b01d39 Refine ASN.1 functions 2023-01-14 19:07:03 +08:00
Zhi Guan
e54b4ae182 Add checking to ASN.1 IA5, UTF8, Printable strings 2023-01-13 17:20:09 +08:00
Zhi Guan
adfa3aaf60 Add functions for SEQUENCE OF
SEQUENCE SIZE (1..n) OF <type>
Always check that SEQUENCE OF is not empty.
2023-01-11 14:19:37 +08:00
Zhi Guan
4ac1abb2a6 Add X.509 validation and auto UTF8 DN 2023-01-10 23:47:27 +08:00
Zhi Guan
4b100b38d1 Update ASN.1 PrintableString functions 2023-01-09 18:13:59 +08:00
Zhi Guan
6803910428 Fix asn1_bit_string_from_der_ex bug
from https://github.com/vita1984

文件:asn1.c
函数名:asn1_bit_string_from_der_ex
BUG描述:nbits的值没有减去unused_bits部分的值导致nbits值错误
复现方式:
ASN hex值:03 02 06 aa
返回值照理应该是2bit。但当前函数实际返回8bit。
修改方式:
原代码:
-- *nbits = (len - 1) << 3;
修改为:
*nbits = (((len - 1) << 3) - unused_bits);
建议把unused_bits的int类型修改为size_t类型
2022-12-27 17:01:10 +08:00
Zhi Guan
8d6ab311f0 Remove Warnings 2022-12-27 14:41:58 +08:00
Zhi Guan
7aec17e140 Fix ASN.1 Time 2022-12-27 14:35:11 +08:00
Zhi Guan
27e9c56bc1 Update ASN.1 Time 2022-12-27 13:55:32 +08:00
Zhi Guan
34ad2a61de Use own time functions 2022-12-22 21:50:06 +08:00
toorls
a959ee8bf6 fix asn1 time bug on windows 2022-10-12 06:24:38 -07:00
Zhi Guan
47639d439e Remove warning 2022-10-12 14:36:11 +08:00
Zhi Guan
74fbb19f13 Update Windows support 2022-10-05 11:12:06 +08:00
Zhi Guan
5e38788659 Add Windows and Visual Studio support 2022-10-03 11:36:03 +08:00
Simon
60c3c33116 license 2022-08-28 19:12:50 +08:00
Simon
4e5880e2ea Revert "修改License"
This reverts commit 0b4308b948.
2022-08-26 13:44:26 +08:00
Simon
0b4308b948 修改License 2022-08-25 22:42:11 -07:00
Simon
36f6a6d4d3 COPYRIGHT 2022-08-08 05:46:54 -07:00
zhaoxiaomeng
c2dacaae46 修改copyright
This reverts commit 7de8e1d83d.
2022-08-08 20:14:44 +08:00
Simon
7de8e1d83d 修改copyright 2022-08-08 05:11:52 -07:00
Zhi Guan
cda0fae675 Update version to beta
Fix the record_do_recv bug and update version
2022-07-27 17:50:01 +08:00
Zhi Guan
f49d465b42 Update demos, asn.1 bug fix 2022-07-25 16:48:45 +08:00
Zhi Guan
79182e93eb Fix bug 2022-06-12 08:58:19 +08:00
Zhi Guan
5eaab7033d Update TLCP 2022-06-11 23:50:54 +08:00
Zhi Guan
19ea6fdf92 Update Tools 2022-05-29 18:10:41 +08:00
Zhi Guan
767dae98ab Update Tools 2022-05-26 23:57:32 +08:00
Zhi Guan
d7a96e3ba1 Update Public API 2022-05-23 09:42:08 +08:00
Zhi Guan
d1b3816319 expose all functions 2022-05-01 09:46:46 +08:00
Zhi Guan
7e4dd76839 update 2022-04-11 17:56:25 +08:00
Zhi Guan
c21972168d All tests passed 2022-03-22 22:30:22 +08:00
Zhi Guan
5ea884ce8f More tests 2022-03-21 13:11:41 +08:00
Zhi Guan
ea4cc6585c Update tests and tools 2022-03-16 15:12:29 +08:00
Zhi Guan
381bfb5b99 Update src 2022-02-27 19:09:39 +08:00
Zhi Guan
becaed76fa update 2021-09-10 11:33:48 +08:00
Zhi Guan
bcad2eb8dd update 2021-09-10 11:29:16 +08:00
Zhi Guan
ae001fbf15 utf8 + bom 2021-08-04 22:07:50 +08:00
Zhi Guan
a57193836b add sdf and skf 2021-08-03 17:09:35 +08:00
Zhi Guan
0af5775be3 Init commit of gmssl-v3 2021-07-13 19:21:43 +08:00