Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Third Party Openssl
提交
1baa9490
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看板
提交
1baa9490
编写于
1月 30, 2000
作者:
B
Bodo Möller
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Make output of "openssl dsaparam 1024" more interesting :-)
上级
7865b871
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
15 addition
and
6 deletion
+15
-6
CHANGES
CHANGES
+3
-1
crypto/bn/bn_prime.c
crypto/bn/bn_prime.c
+3
-0
doc/crypto/DSA_generate_parameters.pod
doc/crypto/DSA_generate_parameters.pod
+9
-5
未找到文件。
CHANGES
浏览文件 @
1baa9490
...
@@ -31,7 +31,9 @@
...
@@ -31,7 +31,9 @@
division before starting the Rabin-Miller test and has
division before starting the Rabin-Miller test and has
an additional BN_CTX * argument (whereas BN_is_prime always
an additional BN_CTX * argument (whereas BN_is_prime always
has to allocate at least one BN_CTX).
has to allocate at least one BN_CTX).
[Bodo Moeller]
'callback(1, -1, cb_arg)' is called when a number has passed the
trial division stage.
[Bodo Moeller]
*) Fix for bug in CRL encoding. The validity dates weren't being handled
*) Fix for bug in CRL encoding. The validity dates weren't being handled
as ASN1_TIME.
as ASN1_TIME.
...
...
crypto/bn/bn_prime.c
浏览文件 @
1baa9490
...
@@ -173,9 +173,12 @@ int BN_is_prime_fasttest(BIGNUM *a, int checks,
...
@@ -173,9 +173,12 @@ int BN_is_prime_fasttest(BIGNUM *a, int checks,
if
(
!
BN_is_odd
(
a
))
if
(
!
BN_is_odd
(
a
))
return
(
0
);
return
(
0
);
if
(
do_trial_division
)
if
(
do_trial_division
)
{
for
(
i
=
1
;
i
<
NUMPRIMES
;
i
++
)
for
(
i
=
1
;
i
<
NUMPRIMES
;
i
++
)
if
(
BN_mod_word
(
a
,
primes
[
i
])
==
0
)
if
(
BN_mod_word
(
a
,
primes
[
i
])
==
0
)
return
0
;
return
0
;
if
(
callback
!=
NULL
)
callback
(
1
,
-
1
,
cb_arg
);
}
if
(
ctx_passed
!=
NULL
)
if
(
ctx_passed
!=
NULL
)
ctx
=
ctx_passed
;
ctx
=
ctx_passed
;
...
...
doc/crypto/DSA_generate_parameters.pod
浏览文件 @
1baa9490
...
@@ -42,9 +42,11 @@ When a candidate for q is generated, B<callback(0, m++, cb_arg)> is called
...
@@ -42,9 +42,11 @@ When a candidate for q is generated, B<callback(0, m++, cb_arg)> is called
=item *
=item *
While a candidate for q is tested, B<callback(1, i, cb_arg)>
When a candidate for q has passed a test by trial division,
is called in the outer loop of the Miller-Rabin primality tests
B<callback(1, -1, cb_arg)> is called.
(once for each witness that confirms that the candidate may be prime).
While a candidate for q is tested by Miller-Rabin primality tests,
B<callback(1, i, cb_arg)> is called in the outer loop
(once for each witness that confirms that the candidate may be prime);
i is the loop counter (starting at 0).
i is the loop counter (starting at 0).
=item *
=item *
...
@@ -59,8 +61,10 @@ B<callback(0, counter, cb_arg)> is called.
...
@@ -59,8 +61,10 @@ B<callback(0, counter, cb_arg)> is called.
=item *
=item *
While a candidate for p is tested, B<callback(1, j++, cb_arg)>
When a candidate for p has passed the test by trial division,
is called in the outer loop of the Miller-Rabin primality test
B<callback(1, -1 , cb_arg)> is called.
While it is tested by the Miller-Rabin primality test,
B<callback(1, i, cb_arg)> is called in the outer loop
(once for each witness that confirms that the candidate may be prime).
(once for each witness that confirms that the candidate may be prime).
i is the loop counter (starting at 0).
i is the loop counter (starting at 0).
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录