Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Openssl
提交
3ae70939
T
Third Party Openssl
项目概览
OpenHarmony
/
Third Party Openssl
1 年多 前同步成功
通知
9
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看板
提交
3ae70939
编写于
4月 03, 2003
作者:
R
Richard Levitte
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Correct a lot of printing calls. Remove extra arguments...
上级
c433d725
变更
15
显示空白变更内容
内联
并排
Showing
15 changed file
with
36 addition
and
36 deletion
+36
-36
apps/ca.c
apps/ca.c
+1
-1
apps/ocsp.c
apps/ocsp.c
+2
-2
apps/pkcs12.c
apps/pkcs12.c
+3
-2
apps/pkcs8.c
apps/pkcs8.c
+5
-6
apps/req.c
apps/req.c
+2
-2
apps/s_cb.c
apps/s_cb.c
+2
-2
apps/s_server.c
apps/s_server.c
+11
-11
apps/speed.c
apps/speed.c
+2
-2
crypto/asn1/t_crl.c
crypto/asn1/t_crl.c
+1
-1
crypto/asn1/t_req.c
crypto/asn1/t_req.c
+1
-1
crypto/dsa/dsatest.c
crypto/dsa/dsatest.c
+1
-1
crypto/ocsp/ocsp_prn.c
crypto/ocsp/ocsp_prn.c
+2
-2
crypto/x509v3/v3_prn.c
crypto/x509v3/v3_prn.c
+1
-1
crypto/x509v3/v3_sxnet.c
crypto/x509v3/v3_sxnet.c
+1
-1
ssl/ssltest.c
ssl/ssltest.c
+1
-1
未找到文件。
apps/ca.c
浏览文件 @
3ae70939
...
...
@@ -2096,7 +2096,7 @@ again2:
BIO_printf
(
bio_err
,
"Certificate is to be certified until "
);
ASN1_UTCTIME_print
(
bio_err
,
X509_get_notAfter
(
ret
));
if
(
days
)
BIO_printf
(
bio_err
,
" (%d days)"
,
days
);
if
(
days
)
BIO_printf
(
bio_err
,
" (%
l
d days)"
,
days
);
BIO_printf
(
bio_err
,
"
\n
"
);
if
(
!
batch
)
...
...
apps/ocsp.c
浏览文件 @
3ae70939
...
...
@@ -781,7 +781,7 @@ int MAIN(int argc, char **argv)
if
(
i
!=
OCSP_RESPONSE_STATUS_SUCCESSFUL
)
{
BIO_printf
(
out
,
"Responder Error: %s (%
l
d)
\n
"
,
BIO_printf
(
out
,
"Responder Error: %s (%d)
\n
"
,
OCSP_response_status_str
(
i
),
i
);
ret
=
0
;
goto
end
;
...
...
@@ -845,7 +845,7 @@ int MAIN(int argc, char **argv)
if
(
i
<=
0
)
{
BIO_printf
(
bio_err
,
"Response Verify Failure
\n
"
,
i
);
BIO_printf
(
bio_err
,
"Response Verify Failure
\n
"
);
ERR_print_errors
(
bio_err
);
}
else
...
...
apps/pkcs12.c
浏览文件 @
3ae70939
...
...
@@ -814,8 +814,9 @@ int alg_print (BIO *x, X509_ALGOR *alg)
unsigned
char
*
p
;
p
=
alg
->
parameter
->
value
.
sequence
->
data
;
pbe
=
d2i_PBEPARAM
(
NULL
,
&
p
,
alg
->
parameter
->
value
.
sequence
->
length
);
BIO_printf
(
bio_err
,
"%s, Iteration %d
\n
"
,
OBJ_nid2ln
(
OBJ_obj2nid
(
alg
->
algorithm
)),
ASN1_INTEGER_get
(
pbe
->
iter
));
BIO_printf
(
bio_err
,
"%s, Iteration %ld
\n
"
,
OBJ_nid2ln
(
OBJ_obj2nid
(
alg
->
algorithm
)),
ASN1_INTEGER_get
(
pbe
->
iter
));
PBEPARAM_free
(
pbe
);
return
0
;
}
...
...
apps/pkcs8.c
浏览文件 @
3ae70939
...
...
@@ -235,7 +235,7 @@ int MAIN(int argc, char **argv)
return
(
1
);
}
if
(
!
(
p8inf
=
EVP_PKEY2PKCS8_broken
(
pkey
,
p8_broken
)))
{
BIO_printf
(
bio_err
,
"Error converting key
\n
"
,
outfile
);
BIO_printf
(
bio_err
,
"Error converting key
\n
"
);
ERR_print_errors
(
bio_err
);
return
(
1
);
}
...
...
@@ -259,8 +259,7 @@ int MAIN(int argc, char **argv)
if
(
!
(
p8
=
PKCS8_encrypt
(
pbe_nid
,
cipher
,
p8pass
,
strlen
(
p8pass
),
NULL
,
0
,
iter
,
p8inf
)))
{
BIO_printf
(
bio_err
,
"Error encrypting key
\n
"
,
outfile
);
BIO_printf
(
bio_err
,
"Error encrypting key
\n
"
);
ERR_print_errors
(
bio_err
);
return
(
1
);
}
...
...
@@ -303,7 +302,7 @@ int MAIN(int argc, char **argv)
}
if
(
!
p8
)
{
BIO_printf
(
bio_err
,
"Error reading key
\n
"
,
outfile
);
BIO_printf
(
bio_err
,
"Error reading key
\n
"
);
ERR_print_errors
(
bio_err
);
return
(
1
);
}
...
...
@@ -317,13 +316,13 @@ int MAIN(int argc, char **argv)
}
if
(
!
p8inf
)
{
BIO_printf
(
bio_err
,
"Error decrypting key
\n
"
,
outfile
);
BIO_printf
(
bio_err
,
"Error decrypting key
\n
"
);
ERR_print_errors
(
bio_err
);
return
(
1
);
}
if
(
!
(
pkey
=
EVP_PKCS82PKEY
(
p8inf
)))
{
BIO_printf
(
bio_err
,
"Error converting key
\n
"
,
outfile
);
BIO_printf
(
bio_err
,
"Error converting key
\n
"
);
ERR_print_errors
(
bio_err
);
return
(
1
);
}
...
...
apps/req.c
浏览文件 @
3ae70939
...
...
@@ -728,10 +728,10 @@ bad:
if
(
newkey
<
MIN_KEY_LENGTH
&&
(
pkey_type
==
TYPE_RSA
||
pkey_type
==
TYPE_DSA
))
{
BIO_printf
(
bio_err
,
"private key length is too short,
\n
"
);
BIO_printf
(
bio_err
,
"it needs to be at least %d bits, not %d
\n
"
,
MIN_KEY_LENGTH
,
newkey
);
BIO_printf
(
bio_err
,
"it needs to be at least %d bits, not %
l
d
\n
"
,
MIN_KEY_LENGTH
,
newkey
);
goto
end
;
}
BIO_printf
(
bio_err
,
"Generating a %d bit %s private key
\n
"
,
BIO_printf
(
bio_err
,
"Generating a %
l
d bit %s private key
\n
"
,
newkey
,(
pkey_type
==
TYPE_RSA
)
?
"RSA"
:
(
pkey_type
==
TYPE_DSA
)
?
"DSA"
:
"EC"
);
...
...
apps/s_cb.c
浏览文件 @
3ae70939
...
...
@@ -239,14 +239,14 @@ long MS_CALLBACK bio_dump_cb(BIO *bio, int cmd, const char *argp, int argi,
if
(
cmd
==
(
BIO_CB_READ
|
BIO_CB_RETURN
))
{
BIO_printf
(
out
,
"read from %
08X [%08lX] (%d bytes => %ld (0x%
X))
\n
"
,
BIO_printf
(
out
,
"read from %
p [%p] (%d bytes => %ld (0x%l
X))
\n
"
,
bio
,
argp
,
argi
,
ret
,
ret
);
BIO_dump
(
out
,
argp
,(
int
)
ret
);
return
(
ret
);
}
else
if
(
cmd
==
(
BIO_CB_WRITE
|
BIO_CB_RETURN
))
{
BIO_printf
(
out
,
"write to %
08X [%08lX] (%d bytes => %ld (0x%
X))
\n
"
,
BIO_printf
(
out
,
"write to %
p [%p] (%d bytes => %ld (0x%l
X))
\n
"
,
bio
,
argp
,
argi
,
ret
,
ret
);
BIO_dump
(
out
,
argp
,(
int
)
ret
);
}
...
...
apps/s_server.c
浏览文件 @
3ae70939
...
...
@@ -971,23 +971,23 @@ static void print_stats(BIO *bio, SSL_CTX *ssl_ctx)
{
BIO_printf
(
bio
,
"%4ld items in the session cache
\n
"
,
SSL_CTX_sess_number
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d client connects (SSL_connect())
\n
"
,
BIO_printf
(
bio
,
"%4
l
d client connects (SSL_connect())
\n
"
,
SSL_CTX_sess_connect
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d client renegotiates (SSL_connect())
\n
"
,
BIO_printf
(
bio
,
"%4
l
d client renegotiates (SSL_connect())
\n
"
,
SSL_CTX_sess_connect_renegotiate
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d client connects that finished
\n
"
,
BIO_printf
(
bio
,
"%4
l
d client connects that finished
\n
"
,
SSL_CTX_sess_connect_good
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d server accepts (SSL_accept())
\n
"
,
BIO_printf
(
bio
,
"%4
l
d server accepts (SSL_accept())
\n
"
,
SSL_CTX_sess_accept
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d server renegotiates (SSL_accept())
\n
"
,
BIO_printf
(
bio
,
"%4
l
d server renegotiates (SSL_accept())
\n
"
,
SSL_CTX_sess_accept_renegotiate
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d server accepts that finished
\n
"
,
BIO_printf
(
bio
,
"%4
l
d server accepts that finished
\n
"
,
SSL_CTX_sess_accept_good
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d session cache hits
\n
"
,
SSL_CTX_sess_hits
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d session cache misses
\n
"
,
SSL_CTX_sess_misses
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d session cache timeouts
\n
"
,
SSL_CTX_sess_timeouts
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4d callback cache hits
\n
"
,
SSL_CTX_sess_cb_hits
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4
d cache full overflows (%
d allowed)
\n
"
,
BIO_printf
(
bio
,
"%4
l
d session cache hits
\n
"
,
SSL_CTX_sess_hits
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4
l
d session cache misses
\n
"
,
SSL_CTX_sess_misses
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4
l
d session cache timeouts
\n
"
,
SSL_CTX_sess_timeouts
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4
l
d callback cache hits
\n
"
,
SSL_CTX_sess_cb_hits
(
ssl_ctx
));
BIO_printf
(
bio
,
"%4
ld cache full overflows (%l
d allowed)
\n
"
,
SSL_CTX_sess_cache_full
(
ssl_ctx
),
SSL_CTX_sess_get_cache_size
(
ssl_ctx
));
}
...
...
apps/speed.c
浏览文件 @
3ae70939
...
...
@@ -2382,8 +2382,8 @@ static void pkey_print_message(char *str, char *str2, long num, int bits,
static
void
print_result
(
int
alg
,
int
run_no
,
int
count
,
double
time_used
)
{
BIO_printf
(
bio_err
,
mr
?
"+R:%
l
d:%s:%f
\n
"
:
"%
l
d %s's in %.2fs
\n
"
,
count
,
names
[
alg
],
time_used
);
BIO_printf
(
bio_err
,
mr
?
"+R:%d:%s:%f
\n
"
:
"%d %s's in %.2fs
\n
"
,
count
,
names
[
alg
],
time_used
);
results
[
alg
][
run_no
]
=
((
double
)
count
)
/
time_used
*
lengths
[
run_no
];
}
...
...
crypto/asn1/t_crl.c
浏览文件 @
3ae70939
...
...
@@ -121,7 +121,7 @@ int X509_CRL_print(BIO *out, X509_CRL *x)
r
=
sk_X509_REVOKED_value
(
rev
,
i
);
BIO_printf
(
out
,
" Serial Number: "
);
i2a_ASN1_INTEGER
(
out
,
r
->
serialNumber
);
BIO_printf
(
out
,
"
\n
Revocation Date: "
,
""
);
BIO_printf
(
out
,
"
\n
Revocation Date: "
);
ASN1_TIME_print
(
out
,
r
->
revocationDate
);
BIO_printf
(
out
,
"
\n
"
);
X509V3_extensions_print
(
out
,
"CRL entry extensions"
,
...
...
crypto/asn1/t_req.c
浏览文件 @
3ae70939
...
...
@@ -254,7 +254,7 @@ get_next:
obj
=
X509_EXTENSION_get_object
(
ex
);
i2a_ASN1_OBJECT
(
bp
,
obj
);
j
=
X509_EXTENSION_get_critical
(
ex
);
if
(
BIO_printf
(
bp
,
": %s
\n
"
,
j
?
"critical"
:
""
,
""
)
<=
0
)
if
(
BIO_printf
(
bp
,
": %s
\n
"
,
j
?
"critical"
:
""
)
<=
0
)
goto
err
;
if
(
!
X509V3_EXT_print
(
bp
,
ex
,
0
,
16
))
{
...
...
crypto/dsa/dsatest.c
浏览文件 @
3ae70939
...
...
@@ -166,7 +166,7 @@ int main(int argc, char **argv)
BIO_printf
(
bio_err
,
"%02X%02X%02X%02X "
,
seed
[
i
],
seed
[
i
+
1
],
seed
[
i
+
2
],
seed
[
i
+
3
]);
}
BIO_printf
(
bio_err
,
"
\n
counter=%d h=%d
\n
"
,
counter
,
h
);
BIO_printf
(
bio_err
,
"
\n
counter=%d h=%
l
d
\n
"
,
counter
,
h
);
if
(
dsa
==
NULL
)
goto
end
;
DSA_print
(
bio_err
,
dsa
,
0
);
...
...
crypto/ocsp/ocsp_prn.c
浏览文件 @
3ae70939
...
...
@@ -194,7 +194,7 @@ int OCSP_RESPONSE_print(BIO *bp, OCSP_RESPONSE* o, unsigned long flags)
if
(
BIO_puts
(
bp
,
"OCSP Response Data:
\n
"
)
<=
0
)
goto
err
;
l
=
ASN1_ENUMERATED_get
(
o
->
responseStatus
);
if
(
BIO_printf
(
bp
,
" OCSP Response Status: %s (0x%x)
\n
"
,
if
(
BIO_printf
(
bp
,
" OCSP Response Status: %s (0x%
l
x)
\n
"
,
OCSP_response_status_str
(
l
),
l
)
<=
0
)
goto
err
;
if
(
rb
==
NULL
)
return
1
;
if
(
BIO_puts
(
bp
,
" Response Type: "
)
<=
0
)
...
...
@@ -252,7 +252,7 @@ int OCSP_RESPONSE_print(BIO *bp, OCSP_RESPONSE* o, unsigned long flags)
{
l
=
ASN1_ENUMERATED_get
(
rev
->
revocationReason
);
if
(
BIO_printf
(
bp
,
"
\n
Revocation Reason: %s (0x%x)"
,
"
\n
Revocation Reason: %s (0x%
l
x)"
,
OCSP_crl_reason_str
(
l
),
l
)
<=
0
)
goto
err
;
}
...
...
crypto/x509v3/v3_prn.c
浏览文件 @
3ae70939
...
...
@@ -182,7 +182,7 @@ int X509V3_extensions_print(BIO *bp, char *title, STACK_OF(X509_EXTENSION) *exts
obj
=
X509_EXTENSION_get_object
(
ex
);
i2a_ASN1_OBJECT
(
bp
,
obj
);
j
=
X509_EXTENSION_get_critical
(
ex
);
if
(
BIO_printf
(
bp
,
": %s
\n
"
,
j
?
"critical"
:
""
,
""
)
<=
0
)
if
(
BIO_printf
(
bp
,
": %s
\n
"
,
j
?
"critical"
:
""
)
<=
0
)
return
0
;
if
(
!
X509V3_EXT_print
(
bp
,
ex
,
flag
,
12
))
{
...
...
crypto/x509v3/v3_sxnet.c
浏览文件 @
3ae70939
...
...
@@ -109,7 +109,7 @@ static int sxnet_i2r(X509V3_EXT_METHOD *method, SXNET *sx, BIO *out,
SXNETID
*
id
;
int
i
;
v
=
ASN1_INTEGER_get
(
sx
->
version
);
BIO_printf
(
out
,
"%*sVersion: %
d (0x%
X)"
,
indent
,
""
,
v
+
1
,
v
);
BIO_printf
(
out
,
"%*sVersion: %
ld (0x%l
X)"
,
indent
,
""
,
v
+
1
,
v
);
for
(
i
=
0
;
i
<
sk_SXNETID_num
(
sx
->
ids
);
i
++
)
{
id
=
sk_SXNETID_value
(
sx
->
ids
,
i
);
tmp
=
i2s_ASN1_INTEGER
(
NULL
,
id
->
zone
);
...
...
ssl/ssltest.c
浏览文件 @
3ae70939
...
...
@@ -1597,7 +1597,7 @@ static RSA MS_CALLBACK *tmp_rsa_cb(SSL *s, int is_export, int keylength)
(
void
)
BIO_flush
(
bio_err
);
if
(
!
RSA_generate_key_ex
(
rsa_tmp
,
keylength
,
RSA_F4
,
NULL
))
{
BIO_printf
(
bio_err
,
"Error generating key."
,
keylength
);
BIO_printf
(
bio_err
,
"Error generating key."
);
RSA_free
(
rsa_tmp
);
rsa_tmp
=
NULL
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录