Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Openssl
提交
2b40660e
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看板
提交
2b40660e
编写于
9月 06, 2000
作者:
B
Bodo Möller
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add OAEP. Seed the PRNG.
上级
f5882ce7
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
12 addition
and
5 deletion
+12
-5
apps/rsautl.c
apps/rsautl.c
+6
-1
doc/apps/rsautl.pod
doc/apps/rsautl.pod
+6
-4
未找到文件。
apps/rsautl.c
浏览文件 @
2b40660e
...
@@ -121,6 +121,7 @@ int MAIN(int argc, char **argv)
...
@@ -121,6 +121,7 @@ int MAIN(int argc, char **argv)
else
if
(
!
strcmp
(
*
argv
,
"-asn1parse"
))
asn1parse
=
1
;
else
if
(
!
strcmp
(
*
argv
,
"-asn1parse"
))
asn1parse
=
1
;
else
if
(
!
strcmp
(
*
argv
,
"-hexdump"
))
hexdump
=
1
;
else
if
(
!
strcmp
(
*
argv
,
"-hexdump"
))
hexdump
=
1
;
else
if
(
!
strcmp
(
*
argv
,
"-raw"
))
pad
=
RSA_NO_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-raw"
))
pad
=
RSA_NO_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-oaep"
))
pad
=
RSA_PKCS1_OAEP_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-ssl"
))
pad
=
RSA_SSLV23_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-ssl"
))
pad
=
RSA_SSLV23_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-pkcs"
))
pad
=
RSA_PKCS1_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-pkcs"
))
pad
=
RSA_PKCS1_PADDING
;
else
if
(
!
strcmp
(
*
argv
,
"-sign"
))
{
else
if
(
!
strcmp
(
*
argv
,
"-sign"
))
{
...
@@ -146,6 +147,9 @@ int MAIN(int argc, char **argv)
...
@@ -146,6 +147,9 @@ int MAIN(int argc, char **argv)
goto
end
;
goto
end
;
}
}
/* FIXME: seed PRNG only if needed */
app_RAND_load_file
(
NULL
,
bio_err
,
0
);
switch
(
key_type
)
{
switch
(
key_type
)
{
case
KEY_PRIVKEY
:
case
KEY_PRIVKEY
:
pkey
=
load_key
(
bio_err
,
keyfile
,
keyform
,
NULL
);
pkey
=
load_key
(
bio_err
,
keyfile
,
keyform
,
NULL
);
...
@@ -266,7 +270,8 @@ static void usage()
...
@@ -266,7 +270,8 @@ static void usage()
BIO_printf
(
bio_err
,
"-certin input is a certificate carrying an RSA public key
\n
"
);
BIO_printf
(
bio_err
,
"-certin input is a certificate carrying an RSA public key
\n
"
);
BIO_printf
(
bio_err
,
"-ssl use SSL v2 padding
\n
"
);
BIO_printf
(
bio_err
,
"-ssl use SSL v2 padding
\n
"
);
BIO_printf
(
bio_err
,
"-raw use no padding
\n
"
);
BIO_printf
(
bio_err
,
"-raw use no padding
\n
"
);
BIO_printf
(
bio_err
,
"-pkcs use PKCS#1 padding (default)
\n
"
);
BIO_printf
(
bio_err
,
"-pkcs use PKCS#1 v.15 padding (default)
\n
"
);
BIO_printf
(
bio_err
,
"-oaep use PKCS#1 OAEP
\n
"
);
BIO_printf
(
bio_err
,
"-sign sign with private key
\n
"
);
BIO_printf
(
bio_err
,
"-sign sign with private key
\n
"
);
BIO_printf
(
bio_err
,
"-verify verify with public key
\n
"
);
BIO_printf
(
bio_err
,
"-verify verify with public key
\n
"
);
BIO_printf
(
bio_err
,
"-encrypt encrypt with public key
\n
"
);
BIO_printf
(
bio_err
,
"-encrypt encrypt with public key
\n
"
);
...
...
doc/apps/rsautl.pod
浏览文件 @
2b40660e
...
@@ -70,10 +70,12 @@ encrypt the input data using an RSA public key.
...
@@ -70,10 +70,12 @@ encrypt the input data using an RSA public key.
decrypt the input data using an RSA private key.
decrypt the input data using an RSA private key.
=item B<-pkcs, -ssl, -raw>
=item B<-pkcs, -
oaep, -
ssl, -raw>
the padding to use, PKCS#1 v1.5 (the default) SSL v2 or no padding
the padding to use: PKCS#1 v1.5 (the default), PKCS#1 OAEP,
respectively.
special padding used in SSL v2 backwards compatible handshakes,
or no padding, respectively.
For signatures, only B<-pkcs> and B<-raw> can be used.
=item B<-hexdump>
=item B<-hexdump>
...
@@ -93,7 +95,7 @@ used to sign or verify small pieces of data.
...
@@ -93,7 +95,7 @@ used to sign or verify small pieces of data.
=head1 EXAMPLES
=head1 EXAMPLES
Sign
the
some data using a private key:
Sign some data using a private key:
openssl rsautl -sign -in file -inkey key.pem -out sig
openssl rsautl -sign -in file -inkey key.pem -out sig
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录