Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Openssl
提交
d8223efd
T
Third Party Openssl
项目概览
OpenHarmony
/
Third Party Openssl
1 年多 前同步成功
通知
10
Star
18
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
Third Party Openssl
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
d8223efd
编写于
12月 10, 1999
作者:
D
Dr. Stephen Henson
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix for crashing INTEGERs, ENUMERATEDs and OBJECT IDENTIFIERs.
Also fix a memory leak in PKCS#7 routines.
上级
e3775a33
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
21 addition
and
5 deletion
+21
-5
CHANGES
CHANGES
+4
-0
crypto/asn1/a_enum.c
crypto/asn1/a_enum.c
+6
-1
crypto/asn1/a_int.c
crypto/asn1/a_int.c
+9
-2
crypto/asn1/a_object.c
crypto/asn1/a_object.c
+1
-1
crypto/pkcs7/pk7_lib.c
crypto/pkcs7/pk7_lib.c
+1
-1
未找到文件。
CHANGES
浏览文件 @
d8223efd
...
...
@@ -4,6 +4,10 @@
Changes between 0.9.4 and 0.9.5 [xx XXX 1999]
*) Some ASN1 types with illegal zero length encoding (INTEGER,
ENUMERATED and OBJECT IDENTIFIER) choked the ASN1 routines.
[Frans Heymans <fheymans@isaserver.be>, modified by Steve Henson]
*) Merge in my S/MIME library for OpenSSL. This provides a simple
S/MIME API on top of the PKCS#7 code, a MIME parser (with enough
functionality to handle multipart/signed properly) and a utility
...
...
crypto/asn1/a_enum.c
浏览文件 @
d8223efd
...
...
@@ -177,7 +177,12 @@ ASN1_ENUMERATED *d2i_ASN1_ENUMERATED(ASN1_ENUMERATED **a, unsigned char **pp,
goto
err
;
}
to
=
s
;
if
(
*
p
&
0x80
)
/* a negative number */
if
(
!
len
)
{
/* Strictly speaking this is an illegal ENUMERATED but we
* tolerate it.
*/
ret
->
type
=
V_ASN1_INTEGER
;
}
else
if
(
*
p
&
0x80
)
/* a negative number */
{
ret
->
type
=
V_ASN1_NEG_ENUMERATED
;
if
((
*
p
==
0xff
)
&&
(
len
!=
1
))
{
...
...
crypto/asn1/a_int.c
浏览文件 @
d8223efd
...
...
@@ -202,7 +202,12 @@ ASN1_INTEGER *d2i_ASN1_INTEGER(ASN1_INTEGER **a, unsigned char **pp,
goto
err
;
}
to
=
s
;
if
(
*
p
&
0x80
)
/* a negative number */
if
(
!
len
)
{
/* Strictly speaking this is an illegal INTEGER but we
* tolerate it.
*/
ret
->
type
=
V_ASN1_INTEGER
;
}
else
if
(
*
p
&
0x80
)
/* a negative number */
{
ret
->
type
=
V_ASN1_NEG_INTEGER
;
if
((
*
p
==
0xff
)
&&
(
len
!=
1
))
{
...
...
@@ -301,7 +306,8 @@ ASN1_INTEGER *d2i_ASN1_UINTEGER(ASN1_INTEGER **a, unsigned char **pp,
goto
err
;
}
to
=
s
;
ret
->
type
=
V_ASN1_INTEGER
;
ret
->
type
=
V_ASN1_INTEGER
;
if
(
len
)
{
if
((
*
p
==
0
)
&&
(
len
!=
1
))
{
p
++
;
...
...
@@ -309,6 +315,7 @@ ASN1_INTEGER *d2i_ASN1_UINTEGER(ASN1_INTEGER **a, unsigned char **pp,
}
memcpy
(
s
,
p
,(
int
)
len
);
p
+=
len
;
}
if
(
ret
->
data
!=
NULL
)
Free
((
char
*
)
ret
->
data
);
ret
->
data
=
s
;
...
...
crypto/asn1/a_object.c
浏览文件 @
d8223efd
...
...
@@ -223,7 +223,7 @@ ASN1_OBJECT *d2i_ASN1_OBJECT(ASN1_OBJECT **a, unsigned char **pp,
if
((
ret
->
data
==
NULL
)
||
(
ret
->
length
<
len
))
{
if
(
ret
->
data
!=
NULL
)
Free
((
char
*
)
ret
->
data
);
ret
->
data
=
(
unsigned
char
*
)
Malloc
(
(
int
)
len
);
ret
->
data
=
(
unsigned
char
*
)
Malloc
(
len
?
(
int
)
len
:
1
);
ret
->
flags
|=
ASN1_OBJECT_FLAG_DYNAMIC_DATA
;
if
(
ret
->
data
==
NULL
)
{
i
=
ERR_R_MALLOC_FAILURE
;
goto
err
;
}
...
...
crypto/pkcs7/pk7_lib.c
浏览文件 @
d8223efd
...
...
@@ -123,7 +123,7 @@ int PKCS7_set_content(PKCS7 *p7, PKCS7 *p7_data)
{
case
NID_pkcs7_signed
:
if
(
p7
->
d
.
sign
->
contents
!=
NULL
)
PKCS7_
content_
free
(
p7
->
d
.
sign
->
contents
);
PKCS7_free
(
p7
->
d
.
sign
->
contents
);
p7
->
d
.
sign
->
contents
=
p7_data
;
break
;
case
NID_pkcs7_digest
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录