Compare commits
1054 Commits
OpenSSL-en
...
OpenSSL-en
Author | SHA1 | Date | |
---|---|---|---|
![]() |
7b24a1a33b | ||
![]() |
393a9b68cf | ||
![]() |
4ae5099856 | ||
![]() |
5c36f01000 | ||
![]() |
6ef9d8328b | ||
![]() |
5a9c441c6e | ||
![]() |
d69d8b5ffa | ||
![]() |
9aef355cf0 | ||
![]() |
11f3f9f4a1 | ||
![]() |
ef9088c9ec | ||
![]() |
422830e17b | ||
![]() |
ac0d075faa | ||
![]() |
53195ba215 | ||
![]() |
6b4580887e | ||
![]() |
4c37da8051 | ||
![]() |
381798377e | ||
![]() |
ffade5fb96 | ||
![]() |
0294674b44 | ||
![]() |
771c8a7ce5 | ||
![]() |
a307eeba84 | ||
![]() |
1fbc936cca | ||
![]() |
ac63f88790 | ||
![]() |
ecfb406f1e | ||
![]() |
eb272ac0b0 | ||
![]() |
63c43dcc59 | ||
![]() |
8562801137 | ||
![]() |
5d8094143e | ||
![]() |
bb6dcb54f9 | ||
![]() |
0a3ea5d34a | ||
![]() |
a5e4c0bb9e | ||
![]() |
df9badad4c | ||
![]() |
cad4b840c8 | ||
![]() |
37a92e9ce4 | ||
![]() |
1896ce3558 | ||
![]() |
c4af8daf34 | ||
![]() |
0357422d14 | ||
![]() |
b4ac8b1e0a | ||
![]() |
adccc4cc7e | ||
![]() |
bbc89d2e1f | ||
![]() |
d3ee37c5d9 | ||
![]() |
1e6c9fc26f | ||
![]() |
3d4bb90138 | ||
![]() |
f51cf14b85 | ||
![]() |
194dd04699 | ||
![]() |
14f7ee4916 | ||
![]() |
a29d78e90b | ||
![]() |
5b054c6955 | ||
![]() |
10654d3a74 | ||
![]() |
6017e604f8 | ||
![]() |
3837491174 | ||
![]() |
86a921af06 | ||
![]() |
616df35633 | ||
![]() |
e44fcedadf | ||
![]() |
6f8f443170 | ||
![]() |
d18af3f37e | ||
![]() |
48fe4d6233 | ||
![]() |
7b8250053b | ||
![]() |
251cb4cfed | ||
![]() |
24a93e6cdd | ||
![]() |
40e15f9d78 | ||
![]() |
b4f682d32f | ||
![]() |
83d0e5e512 | ||
![]() |
c540bd2851 | ||
![]() |
4e20b1a656 | ||
![]() |
cc5ba6a7b6 | ||
![]() |
0396479dec | ||
![]() |
e34cfcf7e1 | ||
![]() |
1358835050 | ||
![]() |
754d494bef | ||
![]() |
6ad0776236 | ||
![]() |
ca7fcc65ef | ||
![]() |
42909e3968 | ||
![]() |
c108108028 | ||
![]() |
5451e0d924 | ||
![]() |
4ea3855514 | ||
![]() |
20a9b1a7cf | ||
![]() |
156e85578d | ||
![]() |
b28ec12420 | ||
![]() |
bb62a8b0c5 | ||
![]() |
a75d8bebd2 | ||
![]() |
b72ff47037 | ||
![]() |
a2b03690a8 | ||
![]() |
abb48d5a5f | ||
![]() |
0e99546424 | ||
![]() |
bd9e2e4c53 | ||
![]() |
ff612904d2 | ||
![]() |
429cf462d0 | ||
![]() |
c62b26fdc6 | ||
![]() |
e0a9ba9c3c | ||
![]() |
2dc769a1c1 | ||
![]() |
4f98cbabde | ||
![]() |
98499135d7 | ||
![]() |
3285076c8e | ||
![]() |
3b4cfea688 | ||
![]() |
de10f6900d | ||
![]() |
adfe54b7be | ||
![]() |
b576337e8b | ||
![]() |
4de633dd5f | ||
![]() |
91f29a38a0 | ||
![]() |
1d5bd6cf71 | ||
![]() |
226cc7ded4 | ||
![]() |
e869d4bd32 | ||
![]() |
60428dbf0a | ||
![]() |
70d70a3c81 | ||
![]() |
f1f25544e0 | ||
![]() |
2e0db07627 | ||
![]() |
58fc62296f | ||
![]() |
df9cc1535e | ||
![]() |
c4b36ff474 | ||
![]() |
f418f8c17c | ||
![]() |
5277d7cb7c | ||
![]() |
0657bf9c14 | ||
![]() |
5b438e9b0f | ||
![]() |
7b4c588f58 | ||
![]() |
1d00800e88 | ||
![]() |
774530f412 | ||
![]() |
fb171e534e | ||
![]() |
7d7db13e67 | ||
![]() |
45abac85a9 | ||
![]() |
24b8dc9a55 | ||
![]() |
d8c79c7f72 | ||
![]() |
3a12ce0137 | ||
![]() |
9bd35f6376 | ||
![]() |
62763f682b | ||
![]() |
38e3c5815c | ||
![]() |
f8fe20e0d9 | ||
![]() |
65e8167079 | ||
![]() |
757a8b4621 | ||
![]() |
5cac59b6c1 | ||
![]() |
bad4058574 | ||
![]() |
d8c2adae57 | ||
![]() |
786e0c2424 | ||
![]() |
794103d285 | ||
![]() |
c454dbcd32 | ||
![]() |
f3a3106807 | ||
![]() |
62dc5aad06 | ||
![]() |
45ecfb1973 | ||
![]() |
f23478c314 | ||
![]() |
3d2e469cfa | ||
![]() |
bf401a2aef | ||
![]() |
06a2b07bb0 | ||
![]() |
8700e7b3cf | ||
![]() |
7f19d42e9d | ||
![]() |
d7bbd31efe | ||
![]() |
fafc7f9875 | ||
![]() |
d88a26c489 | ||
![]() |
64b48877fa | ||
![]() |
b31cc2d9f7 | ||
![]() |
f196522159 | ||
![]() |
4ff18c8c3e | ||
![]() |
db4a465974 | ||
![]() |
3cdc8ad07a | ||
![]() |
cd9bed6d1d | ||
![]() |
2c1571b4ff | ||
![]() |
6767a53669 | ||
![]() |
ba93fd6a38 | ||
![]() |
d7c06e9ec7 | ||
![]() |
386828d029 | ||
![]() |
d339187b1a | ||
![]() |
61fca8b69b | ||
![]() |
bb5ea36b96 | ||
![]() |
e3a9164073 | ||
![]() |
f85c9904c6 | ||
![]() |
48bf4aae24 | ||
![]() |
6231576088 | ||
![]() |
4270144b39 | ||
![]() |
5031a89dc3 | ||
![]() |
bbd1c84e6e | ||
![]() |
a2cf08cc23 | ||
![]() |
d3a73875e2 | ||
![]() |
41d2a336ee | ||
![]() |
627774fd87 | ||
![]() |
a5bc1e8568 | ||
![]() |
c38171ba1f | ||
![]() |
bb3ee8e75d | ||
![]() |
32654e792b | ||
![]() |
19f2192136 | ||
![]() |
1961b327eb | ||
![]() |
2ae87d465e | ||
![]() |
e3ef8d2e6b | ||
![]() |
65a87c7d01 | ||
![]() |
72e3c20c14 | ||
![]() |
ec0f19597e | ||
![]() |
fa2b8db499 | ||
![]() |
1aa0d94781 | ||
![]() |
dc644fe229 | ||
![]() |
47ddf355b4 | ||
![]() |
941181ec0f | ||
![]() |
d399fdf877 | ||
![]() |
487550b61d | ||
![]() |
35618bf6ad | ||
![]() |
460fe31f0c | ||
![]() |
14565bedaf | ||
![]() |
02cc82ff8a | ||
![]() |
38f3b3e29c | ||
![]() |
4dc719fc37 | ||
![]() |
48f2ef8d00 | ||
![]() |
be1bd9239f | ||
![]() |
b8feddae71 | ||
![]() |
a9daa46758 | ||
![]() |
569afce4b0 | ||
![]() |
a9aa3d580c | ||
![]() |
56a6ccc84f | ||
![]() |
03c4d82fa1 | ||
![]() |
7ab1a39181 | ||
![]() |
56dde3ebe6 | ||
![]() |
6525ced540 | ||
![]() |
32d0ad41a4 | ||
![]() |
e28e42a549 | ||
![]() |
ff055b5c89 | ||
![]() |
d8770f3ece | ||
![]() |
4981372d03 | ||
![]() |
3ebac273f5 | ||
![]() |
5af18f65f4 | ||
![]() |
a9b34991d9 | ||
![]() |
bc36ee6227 | ||
![]() |
f2bc668429 | ||
![]() |
8120813066 | ||
![]() |
7242cd8f8f | ||
![]() |
12c2fe8d53 | ||
![]() |
28143c66e1 | ||
![]() |
335c4f0966 | ||
![]() |
5003a61b9f | ||
![]() |
7bd51947e5 | ||
![]() |
4901b41653 | ||
![]() |
74cd365b03 | ||
![]() |
2affbab9fc | ||
![]() |
cf1b7d9664 | ||
![]() |
649c5a2b09 | ||
![]() |
07247321c6 | ||
![]() |
0c43540433 | ||
![]() |
acba75c59d | ||
![]() |
267a1927eb | ||
![]() |
b0c8638650 | ||
![]() |
b36c170d1b | ||
![]() |
934397ec66 | ||
![]() |
0f8631495d | ||
![]() |
95ffe86dbc | ||
![]() |
87b79c3ef3 | ||
![]() |
52d160d85d | ||
![]() |
54ff1e6ae5 | ||
![]() |
a6b7ffddac | ||
![]() |
f30d34f3a8 | ||
![]() |
84a2173797 | ||
![]() |
52b621db88 | ||
![]() |
a6ed5dd674 | ||
![]() |
1417f2dccb | ||
![]() |
f2e5ca84d4 | ||
![]() |
36fafffae2 | ||
![]() |
cdc7b8cc60 | ||
![]() |
720235eeec | ||
![]() |
8e495e4ac7 | ||
![]() |
2afbd6fa08 | ||
![]() |
f282ca7413 | ||
![]() |
67c1801924 | ||
![]() |
46a58ab946 | ||
![]() |
94fcd01349 | ||
![]() |
9a04387362 | ||
![]() |
282d8b1c38 | ||
![]() |
41ecaba97e | ||
![]() |
96dfab9e0e | ||
![]() |
1b65ce7db3 | ||
![]() |
7b9cb4a224 | ||
![]() |
bc2dfde4b3 | ||
![]() |
ec9dc137e7 | ||
![]() |
620cea37e0 | ||
![]() |
c15e036398 | ||
![]() |
ccb08f98ae | ||
![]() |
e306892994 | ||
![]() |
836f996010 | ||
![]() |
1613c4d3bf | ||
![]() |
b5f6d9dc6e | ||
![]() |
c063f2c5ec | ||
![]() |
c47c619680 | ||
![]() |
93cd57a578 | ||
![]() |
49ce63cd7c | ||
![]() |
b3f2e399d2 | ||
![]() |
8c950429a9 | ||
![]() |
c2bf70a27c | ||
![]() |
9235adbf47 | ||
![]() |
a71b5abfa4 | ||
![]() |
928cc3a6de | ||
![]() |
466e4249ab | ||
![]() |
9fbc45b159 | ||
![]() |
792e2ce7f4 | ||
![]() |
3952584571 | ||
![]() |
a5d2acfc79 | ||
![]() |
35ed8cb8b6 | ||
![]() |
7edc5ed90a | ||
![]() |
420125f996 | ||
![]() |
57e7d3ce15 | ||
![]() |
a8ebe4697e | ||
![]() |
deb2c1a1c5 | ||
![]() |
d4219c485b | ||
![]() |
73fc98a7bf | ||
![]() |
259810e05b | ||
![]() |
171cc53a96 | ||
![]() |
9eea2be6f1 | ||
![]() |
69a03c1799 | ||
![]() |
4327aae816 | ||
![]() |
741a9690df | ||
![]() |
e24e40657f | ||
![]() |
448361a86c | ||
![]() |
26e083ccb7 | ||
![]() |
4978361212 | ||
![]() |
247c1361f3 | ||
![]() |
1618bc7921 | ||
![]() |
1b843d3c69 | ||
![]() |
0bc6597d4d | ||
![]() |
2b916952a8 | ||
![]() |
02e4fbed3d | ||
![]() |
7403c34b0b | ||
![]() |
9022f2403b | ||
![]() |
08f3f07212 | ||
![]() |
8cbceba610 | ||
![]() |
88ce56f8c1 | ||
![]() |
664d83bb23 | ||
![]() |
8cff6331c9 | ||
![]() |
cd6aa710b5 | ||
![]() |
903872d65e | ||
![]() |
16a44ae7e9 | ||
![]() |
739423fceb | ||
![]() |
78f3a2aad7 | ||
![]() |
b847024026 | ||
![]() |
50d5199120 | ||
![]() |
9020b86250 | ||
![]() |
a342cc5a70 | ||
![]() |
67c3cf0675 | ||
![]() |
9a875a3574 | ||
![]() |
a43cf9fae9 | ||
![]() |
9ae9c221de | ||
![]() |
4256650d68 | ||
![]() |
ae0665b8f1 | ||
![]() |
75802000c8 | ||
![]() |
325ae88efb | ||
![]() |
a25b265d27 | ||
![]() |
d0a8af61b1 | ||
![]() |
e58d808a4c | ||
![]() |
751b5e8ff2 | ||
![]() |
36f74d60b3 | ||
![]() |
9756da13dd | ||
![]() |
893b76c544 | ||
![]() |
b5a6f0a92d | ||
![]() |
ba8e28248f | ||
![]() |
bfcec27d61 | ||
![]() |
8e8972bb68 | ||
![]() |
57108f0ad5 | ||
![]() |
73758d435b | ||
![]() |
90f63e8f83 | ||
![]() |
e8af92fcb1 | ||
![]() |
361ef5f4dc | ||
![]() |
b3466895e6 | ||
![]() |
81f169e95c | ||
![]() |
a068630a20 | ||
![]() |
dfebac32c0 | ||
![]() |
ab5db00717 | ||
![]() |
6308af199d | ||
![]() |
8e5b6314ef | ||
![]() |
b4b1bdd5d3 | ||
![]() |
5782ceb298 | ||
![]() |
cc85ec447b | ||
![]() |
c67cdb50d2 | ||
![]() |
af5473c45a | ||
![]() |
f2c46006e7 | ||
![]() |
69e42952e1 | ||
![]() |
adf87b2df5 | ||
![]() |
40753f760d | ||
![]() |
d199858e89 | ||
![]() |
10a2975a27 | ||
![]() |
9b4dc8308f | ||
![]() |
b93642c5cc | ||
![]() |
a5435e8b29 | ||
![]() |
72e2d9138c | ||
![]() |
1dd080bca4 | ||
![]() |
f648590991 | ||
![]() |
a14280d41e | ||
![]() |
91b842c972 | ||
![]() |
eddf82a36a | ||
![]() |
673b3fde82 | ||
![]() |
a87e50a945 | ||
![]() |
b62a0c4cab | ||
![]() |
c06648f7f0 | ||
![]() |
cd56182b41 | ||
![]() |
65a22e8e4d | ||
![]() |
cbf0f45f90 | ||
![]() |
b2293b1e9b | ||
![]() |
04e53c273f | ||
![]() |
599c03530a | ||
![]() |
56a67adb64 | ||
![]() |
28e5428d5d | ||
![]() |
3c91484052 | ||
![]() |
98d517c5da | ||
![]() |
18602745de | ||
![]() |
ad2e032049 | ||
![]() |
601140b363 | ||
![]() |
e02cc10ea4 | ||
![]() |
b5524a3ac3 | ||
![]() |
0c61e299b3 | ||
![]() |
0b33bc65cd | ||
![]() |
0f5fa24a7c | ||
![]() |
8e96183506 | ||
![]() |
a8312c0e24 | ||
![]() |
bf0d176e48 | ||
![]() |
ec5add8784 | ||
![]() |
856d456a71 | ||
![]() |
7f2113a2d5 | ||
![]() |
97f56446a3 | ||
![]() |
5d92be8cc6 | ||
![]() |
e102a3dcfd | ||
![]() |
ecbe07817a | ||
![]() |
71db02813c | ||
![]() |
a6574c21eb | ||
![]() |
26da3e65ac | ||
![]() |
21cd437886 | ||
![]() |
f09628e42f | ||
![]() |
6f346c7115 | ||
![]() |
d8ecc56c9d | ||
![]() |
4e1209ebf8 | ||
![]() |
78d3b819f0 | ||
![]() |
200b24e391 | ||
![]() |
1690c2b26e | ||
![]() |
701adceb12 | ||
![]() |
3f07fe09b5 | ||
![]() |
f86c5c9ac7 | ||
![]() |
66a0def81b | ||
![]() |
73e92de577 | ||
![]() |
09ab755c55 | ||
![]() |
ec558b6548 | ||
![]() |
037a9f9c1a | ||
![]() |
29e1fdf3f2 | ||
![]() |
28ddfc61dc | ||
![]() |
725c88879c | ||
![]() |
a0aae68cf6 | ||
![]() |
57d2f21782 | ||
![]() |
895959b736 | ||
![]() |
3c07b4c2ee | ||
![]() |
1cc0b0a66a | ||
![]() |
beb23252a6 | ||
![]() |
3ba25ee86a | ||
![]() |
0be35f5c51 | ||
![]() |
60f7492646 | ||
![]() |
1456d1860e | ||
![]() |
5755cab49d | ||
![]() |
975842f9fb | ||
![]() |
126fe085db | ||
![]() |
123d24d600 | ||
![]() |
3880cd35ad | ||
![]() |
cb38052b3a | ||
![]() |
f640ee90c3 | ||
![]() |
09f4278d25 | ||
![]() |
1f47ec53a2 | ||
![]() |
959f67d6a4 | ||
![]() |
b2e7419a1d | ||
![]() |
6546fdfaf8 | ||
![]() |
3a3ca1d474 | ||
![]() |
7522254b48 | ||
![]() |
f1a6a0d4dd | ||
![]() |
9c67ab2f26 | ||
![]() |
1a7b2d33f4 | ||
![]() |
6e2dad1cc7 | ||
![]() |
2c0d10123e | ||
![]() |
3ac82faae5 | ||
![]() |
c08523d862 | ||
![]() |
137e601277 | ||
![]() |
09f4bd2a39 | ||
![]() |
2fc0d1f15e | ||
![]() |
2a86064f95 | ||
![]() |
016d7d250a | ||
![]() |
2c15d426b9 | ||
![]() |
bdcfe1d165 | ||
![]() |
3b28dbce7e | ||
![]() |
5a4fbc69c3 | ||
![]() |
7e7c8952b5 | ||
![]() |
de487514ae | ||
![]() |
06db4253e2 | ||
![]() |
4ce7894c4a | ||
![]() |
36f554d43c | ||
![]() |
8d28d5f81b | ||
![]() |
53b407da84 | ||
![]() |
765e531159 | ||
![]() |
de282fe3ba | ||
![]() |
36ac656a1b | ||
![]() |
2aff7727f7 | ||
![]() |
cc93ae3ef4 | ||
![]() |
34d69d3b23 | ||
![]() |
daea0ff8a9 | ||
![]() |
448701473a | ||
![]() |
572f0017d5 | ||
![]() |
df2c442a6d | ||
![]() |
23e2947cc8 | ||
![]() |
44b51ca36c | ||
![]() |
bbf848ce8d | ||
![]() |
d0fa136ce2 | ||
![]() |
15156cce0e | ||
![]() |
9d6b1ce644 | ||
![]() |
66ebbb6a56 | ||
![]() |
c5e48d8b01 | ||
![]() |
8dea52fa42 | ||
![]() |
f7356b677b | ||
![]() |
80d89e6a6a | ||
![]() |
bc5f2740d2 | ||
![]() |
aa66eba7c8 | ||
![]() |
f27b45d237 | ||
![]() |
3bb4736289 | ||
![]() |
bac685417a | ||
![]() |
1a4d6400ae | ||
![]() |
322006dcb1 | ||
![]() |
db01d55671 | ||
![]() |
0a52d38b31 | ||
![]() |
902d1051b1 | ||
![]() |
f67868ff4c | ||
![]() |
a6576c56dd | ||
![]() |
240f516939 | ||
![]() |
ef8f14a882 | ||
![]() |
aecb0b018f | ||
![]() |
e4d56bab5b | ||
![]() |
1435ccfba1 | ||
![]() |
d766a23deb | ||
![]() |
b1e21f8fac | ||
![]() |
9347ba487c | ||
![]() |
c28500900e | ||
![]() |
e4c5391ddb | ||
![]() |
0c34556cbd | ||
![]() |
b50118ca3e | ||
![]() |
a57ecb95f6 | ||
![]() |
428a55a0fe | ||
![]() |
cc74659fcc | ||
![]() |
90e7ce363a | ||
![]() |
a47b505e37 | ||
![]() |
9f49524331 | ||
![]() |
6a2347ee45 | ||
![]() |
e5164b7041 | ||
![]() |
ebff44b83a | ||
![]() |
c0e7c3aab9 | ||
![]() |
733777275b | ||
![]() |
f1919c3df9 | ||
![]() |
97b1719583 | ||
![]() |
b0dc680f71 | ||
![]() |
addb309ad6 | ||
![]() |
152a689cf9 | ||
![]() |
35a99b6380 | ||
![]() |
dfa46e502d | ||
![]() |
c21c35e6a4 | ||
![]() |
b26f84cbbd | ||
![]() |
0dba0613ea | ||
![]() |
e0c875081e | ||
![]() |
ea1b7fe6d4 | ||
![]() |
db88223baa | ||
![]() |
d29b63bc9b | ||
![]() |
1946cd8bc2 | ||
![]() |
111482cf2e | ||
![]() |
52a1bab2d9 | ||
![]() |
0826c85f4c | ||
![]() |
385d81380c | ||
![]() |
862e973b50 | ||
![]() |
2efff10cfa | ||
![]() |
33479d275a | ||
![]() |
3e7a6396ed | ||
![]() |
5a12df5c40 | ||
![]() |
b5a25a430a | ||
![]() |
592c784ffe | ||
![]() |
17e757478a | ||
![]() |
a023052580 | ||
![]() |
4b757c830d | ||
![]() |
9b7a552f4b | ||
![]() |
8df788c97f | ||
![]() |
12cfcc128c | ||
![]() |
f9b3bff6f7 | ||
![]() |
fc2e05c2d5 | ||
![]() |
b2993bdea1 | ||
![]() |
470fa98f8a | ||
![]() |
de6e207db6 | ||
![]() |
1363155145 | ||
![]() |
db5bda670f | ||
![]() |
0ae485dc07 | ||
![]() |
19cda70045 | ||
![]() |
4751717cd8 | ||
![]() |
bd68b6b1f6 | ||
![]() |
cd9b7d7c35 | ||
![]() |
058123afb6 | ||
![]() |
a4614bf06d | ||
![]() |
23f80f46a4 | ||
![]() |
c4438dc0e5 | ||
![]() |
04ca16890b | ||
![]() |
20f88b9bd4 | ||
![]() |
25439b76ad | ||
![]() |
3465dd3853 | ||
![]() |
ac445acf69 | ||
![]() |
77ac92d00a | ||
![]() |
73c2522c7c | ||
![]() |
6b5d39e82d | ||
![]() |
cd2eebfd64 | ||
![]() |
06676624fc | ||
![]() |
ef8b601789 | ||
![]() |
01e62900c7 | ||
![]() |
d50f1bdfac | ||
![]() |
38b40c624c | ||
![]() |
eb1f1b0a34 | ||
![]() |
a9376dbff9 | ||
![]() |
14697d9d6d | ||
![]() |
c6a926d9e2 | ||
![]() |
c1db5bfc08 | ||
![]() |
429b8162c6 | ||
![]() |
0dd2254d76 | ||
![]() |
03a0848922 | ||
![]() |
9161672950 | ||
![]() |
a08bcccc67 | ||
![]() |
bdec3c5323 | ||
![]() |
53d286797c | ||
![]() |
b6cafbd7d8 | ||
![]() |
499e167fda | ||
![]() |
0135e33511 | ||
![]() |
f2cc7559dd | ||
![]() |
fe8686ba4b | ||
![]() |
4aa69fe0b6 | ||
![]() |
b984cd2b01 | ||
![]() |
adcc64cd9e | ||
![]() |
c94b6de017 | ||
![]() |
000e21779c | ||
![]() |
f1d6f64c8e | ||
![]() |
d79cab27a5 | ||
![]() |
24b44446e2 | ||
![]() |
87739b2c53 | ||
![]() |
c782089611 | ||
![]() |
265592b99a | ||
![]() |
077ff61eef | ||
![]() |
dcbd0d74d5 | ||
![]() |
1ec0a3862e | ||
![]() |
946cd9a540 | ||
![]() |
0ac87024e3 | ||
![]() |
7abe830501 | ||
![]() |
5acaa49504 | ||
![]() |
535b9b5724 | ||
![]() |
78a0c1f18d | ||
![]() |
6cc5e19d47 | ||
![]() |
7e0c5264e7 | ||
![]() |
73343ac38a | ||
![]() |
d53d271728 | ||
![]() |
37fc8c3747 | ||
![]() |
01412ec600 | ||
![]() |
c4f3542abf | ||
![]() |
c799770060 | ||
![]() |
cd26e6c79d | ||
![]() |
4e773226f5 | ||
![]() |
646d56956b | ||
![]() |
0cc1115643 | ||
![]() |
257341b5b4 | ||
![]() |
83f2571782 | ||
![]() |
baa257f1ed | ||
![]() |
e06cc57118 | ||
![]() |
0450d28759 | ||
![]() |
7f56097c65 | ||
![]() |
7396958515 | ||
![]() |
3c758be86e | ||
![]() |
227385b719 | ||
![]() |
f7a059316f | ||
![]() |
b1d6e3f551 | ||
![]() |
db70a3fd6e | ||
![]() |
28fd5c60de | ||
![]() |
cbd48ba626 | ||
![]() |
67d93e6f49 | ||
![]() |
afb83c45e6 | ||
![]() |
43fcc1b096 | ||
![]() |
d5695a26a6 | ||
![]() |
8bfc8f934f | ||
![]() |
ef02b10a16 | ||
![]() |
803e4e93d4 | ||
![]() |
60b8607727 | ||
![]() |
159564ae9f | ||
![]() |
cd1bf28e2c | ||
![]() |
74e10aa58b | ||
![]() |
5f524accc1 | ||
![]() |
451e60e99f | ||
![]() |
89c16ab53e | ||
![]() |
820aaa5fc5 | ||
![]() |
993ea851f5 | ||
![]() |
305db17b5f | ||
![]() |
6a8ba34f9d | ||
![]() |
f777408fc5 | ||
![]() |
2984b0ae24 | ||
![]() |
3d6001f7b9 | ||
![]() |
f6a8898fc3 | ||
![]() |
757e392d4e | ||
![]() |
2f9f0c72de | ||
![]() |
cb4ae6c0d3 | ||
![]() |
359fd02fec | ||
![]() |
e1a8ac495b | ||
![]() |
0b5806b5f5 | ||
![]() |
ccb9643f02 | ||
![]() |
7f7b8d6871 | ||
![]() |
bb7e632aef | ||
![]() |
55d892e373 | ||
![]() |
f971ccb264 | ||
![]() |
a4aba800d9 | ||
![]() |
669cefdd35 | ||
![]() |
7be7c2eda5 | ||
![]() |
8de2910b5c | ||
![]() |
74489a3668 | ||
![]() |
e06433d9ba | ||
![]() |
e0bf5c11ea | ||
![]() |
58f0f52e67 | ||
![]() |
55b3c877c7 | ||
![]() |
bbbc96a87e | ||
![]() |
5e4ca4220e | ||
![]() |
e5828cd46f | ||
![]() |
7081f3bd89 | ||
![]() |
0413ba429c | ||
![]() |
29c1f0615b | ||
![]() |
10e473e930 | ||
![]() |
e7ef1a561a | ||
![]() |
458d356db9 | ||
![]() |
020fc820dc | ||
![]() |
bc8a9f1f0f | ||
![]() |
6b77e6d7f3 | ||
![]() |
361c7f2b52 | ||
![]() |
9f6fe8dbe7 | ||
![]() |
ee78e1fc8b | ||
![]() |
864170286a | ||
![]() |
02af65b347 | ||
![]() |
2f13ee21ea | ||
![]() |
1d833a9910 | ||
![]() |
11c0f1201c | ||
![]() |
69e7805f54 | ||
![]() |
e264cfe17a | ||
![]() |
8224b0cbe5 | ||
![]() |
15d52ddb55 | ||
![]() |
d48f487e2c | ||
![]() |
ce23b0f73e | ||
![]() |
d313047f63 | ||
![]() |
d1855cc7af | ||
![]() |
14c6d27d63 | ||
![]() |
dcea8e12e2 | ||
![]() |
26b264795d | ||
![]() |
501ebf16b6 | ||
![]() |
815c83f70a | ||
![]() |
92125ffaec | ||
![]() |
7db2fcaa81 | ||
![]() |
7d09713d09 | ||
![]() |
3aba98e787 | ||
![]() |
32d862ede4 | ||
![]() |
a44f26d5c9 | ||
![]() |
3e126d3610 | ||
![]() |
5660eb489e | ||
![]() |
7c155330de | ||
![]() |
8bb4ad88d8 | ||
![]() |
eb64730b9c | ||
![]() |
34a1488220 | ||
![]() |
5270e7025e | ||
![]() |
1df586bec2 | ||
![]() |
551e5990d2 | ||
![]() |
d9efa3616a | ||
![]() |
51c8dc37dd | ||
![]() |
28967cf079 | ||
![]() |
a2bbe59401 | ||
![]() |
421cb50b2d | ||
![]() |
0fa504b68d | ||
![]() |
705bfcf8e7 | ||
![]() |
4fb40db932 | ||
![]() |
9dd0463852 | ||
![]() |
5cb5715f97 | ||
![]() |
e9a583aa26 | ||
![]() |
f3f316f13f | ||
![]() |
99b1aaf2ec | ||
![]() |
53400da75c | ||
![]() |
2b59a6ac14 | ||
![]() |
48d89b560c | ||
![]() |
b5a43800ef | ||
![]() |
0fd44e2ddb | ||
![]() |
0a2221f9ad | ||
![]() |
567f17cfe0 | ||
![]() |
627ec355d8 | ||
![]() |
c80abb148d | ||
![]() |
4184a78761 | ||
![]() |
bbdc9c98a8 | ||
![]() |
11b62699a1 | ||
![]() |
14a74a21f0 | ||
![]() |
c8cda405e7 | ||
![]() |
befb3e7a4d | ||
![]() |
c6f1787bbd | ||
![]() |
9bd3bd227f | ||
![]() |
d0ef53bd2d | ||
![]() |
8d3f155a66 | ||
![]() |
ef0ab7f94f | ||
![]() |
bf55ece1c1 | ||
![]() |
51754ec835 | ||
![]() |
1bc5dd3efc | ||
![]() |
0ded1638ba | ||
![]() |
71d525c9f6 | ||
![]() |
757ab9b506 | ||
![]() |
3ab5651112 | ||
![]() |
82ce0b2308 | ||
![]() |
a22fb399cb | ||
![]() |
8df8f27513 | ||
![]() |
cde70093ac | ||
![]() |
5f97f508e4 | ||
![]() |
868af8e4be | ||
![]() |
553615f500 | ||
![]() |
924046ce75 | ||
![]() |
e100946038 | ||
![]() |
9e2c0f41d7 | ||
![]() |
5ef67042f9 | ||
![]() |
53fe8d5be5 | ||
![]() |
5209202f3b | ||
![]() |
8c23788dd1 | ||
![]() |
ef76e3dbda | ||
![]() |
7ba839bfe2 | ||
![]() |
d2dcf4f40d | ||
![]() |
75a382bd90 | ||
![]() |
5b0a0544f2 | ||
![]() |
a0ec9cf6d5 | ||
![]() |
e9ebf346c4 | ||
![]() |
73701c27b3 | ||
![]() |
8ca533e378 | ||
![]() |
d0c9858914 | ||
![]() |
4ef897d1fc | ||
![]() |
356c06c776 | ||
![]() |
ef71cb6daf | ||
![]() |
2e7e3d6ce9 | ||
![]() |
a269d312da | ||
![]() |
a87aa87bcc | ||
![]() |
6df3553255 | ||
![]() |
2eaad87f36 | ||
![]() |
b7af080fb1 | ||
![]() |
3a0afe1eed | ||
![]() |
086a32d754 | ||
![]() |
544ebbceb4 | ||
![]() |
6d0dcbedb1 | ||
![]() |
19a5e404cb | ||
![]() |
88aeb646bd | ||
![]() |
46b1b91309 | ||
![]() |
be054868a1 | ||
![]() |
0acc90e5f7 | ||
![]() |
4e20a4e688 | ||
![]() |
9ef9e78520 | ||
![]() |
e3f527177b | ||
![]() |
393e826ec3 | ||
![]() |
f09a419c6a | ||
![]() |
f4bdbfea66 | ||
![]() |
f00ba75c69 | ||
![]() |
c5e8580e7b | ||
![]() |
47dc5a1321 | ||
![]() |
16221173c8 | ||
![]() |
0e8f2fdfdd | ||
![]() |
fec8c79a7e | ||
![]() |
56245be46d | ||
![]() |
3476515195 | ||
![]() |
eb206eb8be | ||
![]() |
fda05b2155 | ||
![]() |
8c4ab6d5ae | ||
![]() |
8fdec3e558 | ||
![]() |
e1db7a5e30 | ||
![]() |
69431c2998 | ||
![]() |
90d7fc1de4 | ||
![]() |
bb28bcdf98 | ||
![]() |
d49da3aa5b | ||
![]() |
fc55bf3b20 | ||
![]() |
03dbae0d20 | ||
![]() |
5a5accdd64 | ||
![]() |
f1192b7f2e | ||
![]() |
dbba890cf1 | ||
![]() |
3f8b90c345 | ||
![]() |
28a63d3e6f | ||
![]() |
318e09356b | ||
![]() |
4839df4061 | ||
![]() |
6b3a4ffe36 | ||
![]() |
9cfb6bbd29 | ||
![]() |
7f6e0a4c09 | ||
![]() |
6cffb201f3 | ||
![]() |
4b0f00b7ce | ||
![]() |
4aa4f333ed | ||
![]() |
a04cfb72d5 | ||
![]() |
1cbb729fdc | ||
![]() |
d176986488 | ||
![]() |
c759ddd676 | ||
![]() |
9cfab47b18 | ||
![]() |
6e3dfc1f3b | ||
![]() |
ef63568e94 | ||
![]() |
27f00db152 | ||
![]() |
d40898dfab | ||
![]() |
a9c33b529e | ||
![]() |
422e5a4807 | ||
![]() |
6397710486 | ||
![]() |
10bb0dbfec | ||
![]() |
5deb47f12a | ||
![]() |
c19b6c922a | ||
![]() |
c5f8bbbc0b | ||
![]() |
775c289db5 | ||
![]() |
099f5bfeba | ||
![]() |
4759abc5f2 | ||
![]() |
e31e385ce3 | ||
![]() |
103a604932 | ||
![]() |
12f49bd79d | ||
![]() |
b22bda21a1 | ||
![]() |
b38d84d867 | ||
![]() |
50b14a38f5 | ||
![]() |
edb0d64367 | ||
![]() |
4b250a3d25 | ||
![]() |
33b1a4c218 | ||
![]() |
c200ff0446 | ||
![]() |
a7ce1f0514 | ||
![]() |
645749ef98 | ||
![]() |
4cae3ac371 | ||
![]() |
9a0c0d3f74 | ||
![]() |
7cae5f9fc8 | ||
![]() |
18edda0f92 | ||
![]() |
89681b183d | ||
![]() |
63ccddf717 | ||
![]() |
c8973693ab | ||
![]() |
4e87e05b25 | ||
![]() |
fe03519704 | ||
![]() |
b004872c59 | ||
![]() |
933f32cc4d | ||
![]() |
c6def253b4 | ||
![]() |
dd3430a6e9 | ||
![]() |
cb1fbf8e6a | ||
![]() |
51012a0969 | ||
![]() |
a45bd29535 | ||
![]() |
688fbf5475 | ||
![]() |
f4364e0730 | ||
![]() |
fae8762630 | ||
![]() |
28178bcf24 | ||
![]() |
cec7fe4da6 | ||
![]() |
c15602f48e | ||
![]() |
3b2cbbcb9a | ||
![]() |
c69c47b9fe | ||
![]() |
5d1a5ddb65 | ||
![]() |
f97cc10372 | ||
![]() |
a3829b8650 | ||
![]() |
615513ba52 | ||
![]() |
2bd8aaefa4 | ||
![]() |
252d333fc1 | ||
![]() |
2aa4e2e2d4 | ||
![]() |
c6cda0bdb7 | ||
![]() |
730e37edb6 | ||
![]() |
4b6e6ab91c | ||
![]() |
24842e0586 | ||
![]() |
159cf04e86 | ||
![]() |
676432d4e1 | ||
![]() |
1e72b77994 | ||
![]() |
1cf3bbaea6 | ||
![]() |
d448429e52 | ||
![]() |
4534fb1c86 | ||
![]() |
362f2b69ff | ||
![]() |
3c184d8180 | ||
![]() |
ce6990739e | ||
![]() |
42cc160301 | ||
![]() |
a440d6636f | ||
![]() |
91e8cc6216 | ||
![]() |
0e61cfff53 | ||
![]() |
d0c2ebf414 | ||
![]() |
e17b712894 | ||
![]() |
1d95fb659d | ||
![]() |
62324627aa | ||
![]() |
f77600524f | ||
![]() |
623eea376a | ||
![]() |
ebcdd0c43e | ||
![]() |
5ef8093732 | ||
![]() |
6d50071e84 | ||
![]() |
60dae9985d | ||
![]() |
df320c4473 | ||
![]() |
3aa477f6ec | ||
![]() |
282f92f7dd | ||
![]() |
8e913bff55 | ||
![]() |
07fcf422a1 | ||
![]() |
8de7587e02 | ||
![]() |
da542e1bf7 | ||
![]() |
93fe6e13a3 | ||
![]() |
90ac586317 | ||
![]() |
2c281ebb6c | ||
![]() |
37b08e8365 | ||
![]() |
318f962928 | ||
![]() |
acb5b34328 | ||
![]() |
c1629c9ea2 | ||
![]() |
1e4e549296 | ||
![]() |
439fb8e1e0 | ||
![]() |
53e44d90c7 | ||
![]() |
32751b8ab1 | ||
![]() |
15c0fb18a2 | ||
![]() |
f30839ecaa | ||
![]() |
5ce0e07da7 | ||
![]() |
1c86d93ca5 | ||
![]() |
eb31944f81 | ||
![]() |
ea4e4149af | ||
![]() |
0e05f54516 | ||
![]() |
095aadc43f | ||
![]() |
68a1c6b0d9 | ||
![]() |
bda702ef83 | ||
![]() |
a4129c6e33 | ||
![]() |
848f3d40c8 | ||
![]() |
1949e78336 | ||
![]() |
2273d6b657 | ||
![]() |
e39c194387 | ||
![]() |
e1b78bc64d | ||
![]() |
e65c84abb0 | ||
![]() |
8eec1389fb | ||
![]() |
e38dabbc0c | ||
![]() |
54731d75d7 | ||
![]() |
18f2259499 | ||
![]() |
1d84fd64fc | ||
![]() |
03ed26afdd | ||
![]() |
775bcebde5 | ||
![]() |
7fcc8326e3 | ||
![]() |
cc99526db1 | ||
![]() |
72660f5f15 | ||
![]() |
bace212474 | ||
![]() |
e117a890ca | ||
![]() |
5614bb91f5 | ||
![]() |
7abee0cedf | ||
![]() |
6dcbaf5857 | ||
![]() |
baa080d46a | ||
![]() |
0dcf7fd543 | ||
![]() |
02539402af | ||
![]() |
02ef611ef3 | ||
![]() |
24b8bf2163 | ||
![]() |
e37c27d239 | ||
![]() |
270f4f6d63 | ||
![]() |
e147c6fef8 | ||
![]() |
cea81a62ff | ||
![]() |
c0366d89f6 | ||
![]() |
523d778aef | ||
![]() |
5b7417dbe1 | ||
![]() |
5401c4c2bf | ||
![]() |
c11dead17c | ||
![]() |
4041156461 | ||
![]() |
279fff0d7f | ||
![]() |
54f10e6adc | ||
![]() |
fb1cba063d | ||
![]() |
e4daf9dfce | ||
![]() |
8a26980b07 | ||
![]() |
1e27f4b68c | ||
![]() |
2be9694116 | ||
![]() |
03ea28c985 | ||
![]() |
0f92cae9bc | ||
![]() |
a9740b7da6 | ||
![]() |
b46ba9b1bc | ||
![]() |
d572cb6c1c | ||
![]() |
05c2b37176 | ||
![]() |
8e1ec9fb37 | ||
![]() |
dc005a7367 | ||
![]() |
8c0514f741 | ||
![]() |
2aff74dd68 | ||
![]() |
b924f04784 | ||
![]() |
d63b8db852 | ||
![]() |
2959f292db | ||
![]() |
965c17756a | ||
![]() |
0c415ddd67 | ||
![]() |
16e91fe8ab | ||
![]() |
74d2b0f112 | ||
![]() |
d40a9e8257 | ||
![]() |
ec6a40e278 | ||
![]() |
4a6367ae66 | ||
![]() |
bed1847b6a | ||
![]() |
4d0c6b2936 | ||
![]() |
25a73f2690 |
505
CHANGES
505
CHANGES
@@ -2,7 +2,506 @@
|
||||
OpenSSL CHANGES
|
||||
_______________
|
||||
|
||||
Changes between 0.9.5a and 0.9.6 [xx XXX 2000]
|
||||
Changes between 0.9.6a and 0.9.6b [9 Jul 2001]
|
||||
|
||||
*) Change ssleay_rand_bytes (crypto/rand/md_rand.c)
|
||||
to avoid a SSLeay/OpenSSL PRNG weakness pointed out by
|
||||
Markku-Juhani O. Saarinen <markku-juhani.saarinen@nokia.com>:
|
||||
PRNG state recovery was possible based on the output of
|
||||
one PRNG request appropriately sized to gain knowledge on
|
||||
'md' followed by enough consecutive 1-byte PRNG requests
|
||||
to traverse all of 'state'.
|
||||
|
||||
1. When updating 'md_local' (the current thread's copy of 'md')
|
||||
during PRNG output generation, hash all of the previous
|
||||
'md_local' value, not just the half used for PRNG output.
|
||||
|
||||
2. Make the number of bytes from 'state' included into the hash
|
||||
independent from the number of PRNG bytes requested.
|
||||
|
||||
The first measure alone would be sufficient to avoid
|
||||
Markku-Juhani's attack. (Actually it had never occurred
|
||||
to me that the half of 'md_local' used for chaining was the
|
||||
half from which PRNG output bytes were taken -- I had always
|
||||
assumed that the secret half would be used.) The second
|
||||
measure makes sure that additional data from 'state' is never
|
||||
mixed into 'md_local' in small portions; this heuristically
|
||||
further strengthens the PRNG.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix crypto/bn/asm/mips3.s.
|
||||
[Andy Polyakov]
|
||||
|
||||
*) When only the key is given to "enc", the IV is undefined. Print out
|
||||
an error message in this case.
|
||||
[Lutz Jaenicke]
|
||||
|
||||
*) Handle special case when X509_NAME is empty in X509 printing routines.
|
||||
[Steve Henson]
|
||||
|
||||
*) In dsa_do_verify (crypto/dsa/dsa_ossl.c), verify that r and s are
|
||||
positive and less than q.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Don't change *pointer in CRYPTO_add_lock() is add_lock_callback is
|
||||
used: it isn't thread safe and the add_lock_callback should handle
|
||||
that itself.
|
||||
[Paul Rose <Paul.Rose@bridge.com>]
|
||||
|
||||
*) Verify that incoming data obeys the block size in
|
||||
ssl3_enc (ssl/s3_enc.c) and tls1_enc (ssl/t1_enc.c).
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix OAEP check.
|
||||
[Ulf M<>ller, Bodo M<>ller]
|
||||
|
||||
*) The countermeasure against Bleichbacher's attack on PKCS #1 v1.5
|
||||
RSA encryption was accidentily removed in s3_srvr.c in OpenSSL 0.9.5
|
||||
when fixing the server behaviour for backwards-compatible 'client
|
||||
hello' messages. (Note that the attack is impractical against
|
||||
SSL 3.0 and TLS 1.0 anyway because length and version checking
|
||||
means that the probability of guessing a valid ciphertext is
|
||||
around 2^-40; see section 5 in Bleichenbacher's CRYPTO '98
|
||||
paper.)
|
||||
|
||||
Before 0.9.5, the countermeasure (hide the error by generating a
|
||||
random 'decryption result') did not work properly because
|
||||
ERR_clear_error() was missing, meaning that SSL_get_error() would
|
||||
detect the supposedly ignored error.
|
||||
|
||||
Both problems are now fixed.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) In crypto/bio/bf_buff.c, increase DEFAULT_BUFFER_SIZE to 4096
|
||||
(previously it was 1024).
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix for compatibility mode trust settings: ignore trust settings
|
||||
unless some valid trust or reject settings are present.
|
||||
[Steve Henson]
|
||||
|
||||
*) Fix for blowfish EVP: its a variable length cipher.
|
||||
[Steve Henson]
|
||||
|
||||
*) Fix various bugs related to DSA S/MIME verification. Handle missing
|
||||
parameters in DSA public key structures and return an error in the
|
||||
DSA routines if parameters are absent.
|
||||
[Steve Henson]
|
||||
|
||||
*) In versions up to 0.9.6, RAND_file_name() resorted to file ".rnd"
|
||||
in the current directory if neither $RANDFILE nor $HOME was set.
|
||||
RAND_file_name() in 0.9.6a returned NULL in this case. This has
|
||||
caused some confusion to Windows users who haven't defined $HOME.
|
||||
Thus RAND_file_name() is changed again: e_os.h can define a
|
||||
DEFAULT_HOME, which will be used if $HOME is not set.
|
||||
For Windows, we use "C:"; on other platforms, we still require
|
||||
environment variables.
|
||||
|
||||
*) Move 'if (!initialized) RAND_poll()' into regions protected by
|
||||
CRYPTO_LOCK_RAND. This is not strictly necessary, but avoids
|
||||
having multiple threads call RAND_poll() concurrently.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) In crypto/rand/md_rand.c, replace 'add_do_not_lock' flag by a
|
||||
combination of a flag and a thread ID variable.
|
||||
Otherwise while one thread is in ssleay_rand_bytes (which sets the
|
||||
flag), *other* threads can enter ssleay_add_bytes without obeying
|
||||
the CRYPTO_LOCK_RAND lock (and may even illegaly release the lock
|
||||
that they do not hold after the first thread unsets add_do_not_lock).
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Change bctest again: '-x' expressions are not available in all
|
||||
versions of 'test'.
|
||||
[Bodo Moeller]
|
||||
|
||||
Changes between 0.9.6 and 0.9.6a [5 Apr 2001]
|
||||
|
||||
*) Fix a couple of memory leaks in PKCS7_dataDecode()
|
||||
[Steve Henson, reported by Heyun Zheng <hzheng@atdsprint.com>]
|
||||
|
||||
*) Change Configure and Makefiles to provide EXE_EXT, which will contain
|
||||
the default extension for executables, if any. Also, make the perl
|
||||
scripts that use symlink() to test if it really exists and use "cp"
|
||||
if it doesn't. All this made OpenSSL compilable and installable in
|
||||
CygWin.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Fix for asn1_GetSequence() for indefinite length constructed data.
|
||||
If SEQUENCE is length is indefinite just set c->slen to the total
|
||||
amount of data available.
|
||||
[Steve Henson, reported by shige@FreeBSD.org]
|
||||
[This change does not apply to 0.9.7.]
|
||||
|
||||
*) Change bctest to avoid here-documents inside command substitution
|
||||
(workaround for FreeBSD /bin/sh bug).
|
||||
For compatibility with Ultrix, avoid shell functions (introduced
|
||||
in the bctest version that searches along $PATH).
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Rename 'des_encrypt' to 'des_encrypt1'. This avoids the clashes
|
||||
with des_encrypt() defined on some operating systems, like Solaris
|
||||
and UnixWare.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Check the result of RSA-CRT (see D. Boneh, R. DeMillo, R. Lipton:
|
||||
On the Importance of Eliminating Errors in Cryptographic
|
||||
Computations, J. Cryptology 14 (2001) 2, 101-119,
|
||||
http://theory.stanford.edu/~dabo/papers/faults.ps.gz).
|
||||
[Ulf Moeller]
|
||||
|
||||
*) MIPS assembler BIGNUM division bug fix.
|
||||
[Andy Polyakov]
|
||||
|
||||
*) Disabled incorrect Alpha assembler code.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Fix PKCS#7 decode routines so they correctly update the length
|
||||
after reading an EOC for the EXPLICIT tag.
|
||||
[Steve Henson]
|
||||
[This change does not apply to 0.9.7.]
|
||||
|
||||
*) Fix bug in PKCS#12 key generation routines. This was triggered
|
||||
if a 3DES key was generated with a 0 initial byte. Include
|
||||
PKCS12_BROKEN_KEYGEN compilation option to retain the old
|
||||
(but broken) behaviour.
|
||||
[Steve Henson]
|
||||
|
||||
*) Enhance bctest to search for a working bc along $PATH and print
|
||||
it when found.
|
||||
[Tim Rice <tim@multitalents.net> via Richard Levitte]
|
||||
|
||||
*) Fix memory leaks in err.c: free err_data string if necessary;
|
||||
don't write to the wrong index in ERR_set_error_data.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Implement ssl23_peek (analogous to ssl23_read), which previously
|
||||
did not exist.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Replace rdtsc with _emit statements for VC++ version 5.
|
||||
[Jeremy Cooper <jeremy@baymoo.org>]
|
||||
|
||||
*) Make it possible to reuse SSLv2 sessions.
|
||||
[Richard Levitte]
|
||||
|
||||
*) In copy_email() check for >= 0 as a return value for
|
||||
X509_NAME_get_index_by_NID() since 0 is a valid index.
|
||||
[Steve Henson reported by Massimiliano Pala <madwolf@opensca.org>]
|
||||
|
||||
*) Avoid coredump with unsupported or invalid public keys by checking if
|
||||
X509_get_pubkey() fails in PKCS7_verify(). Fix memory leak when
|
||||
PKCS7_verify() fails with non detached data.
|
||||
[Steve Henson]
|
||||
|
||||
*) Don't use getenv in library functions when run as setuid/setgid.
|
||||
New function OPENSSL_issetugid().
|
||||
[Ulf Moeller]
|
||||
|
||||
*) Avoid false positives in memory leak detection code (crypto/mem_dbg.c)
|
||||
due to incorrect handling of multi-threading:
|
||||
|
||||
1. Fix timing glitch in the MemCheck_off() portion of CRYPTO_mem_ctrl().
|
||||
|
||||
2. Fix logical glitch in is_MemCheck_on() aka CRYPTO_is_mem_check_on().
|
||||
|
||||
3. Count how many times MemCheck_off() has been called so that
|
||||
nested use can be treated correctly. This also avoids
|
||||
inband-signalling in the previous code (which relied on the
|
||||
assumption that thread ID 0 is impossible).
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Add "-rand" option also to s_client and s_server.
|
||||
[Lutz Jaenicke]
|
||||
|
||||
*) Fix CPU detection on Irix 6.x.
|
||||
[Kurt Hockenbury <khockenb@stevens-tech.edu> and
|
||||
"Bruce W. Forsberg" <bruce.forsberg@baesystems.com>]
|
||||
|
||||
*) Fix X509_NAME bug which produced incorrect encoding if X509_NAME
|
||||
was empty.
|
||||
[Steve Henson]
|
||||
[This change does not apply to 0.9.7.]
|
||||
|
||||
*) Use the cached encoding of an X509_NAME structure rather than
|
||||
copying it. This is apparently the reason for the libsafe "errors"
|
||||
but the code is actually correct.
|
||||
[Steve Henson]
|
||||
|
||||
*) Add new function BN_rand_range(), and fix DSA_sign_setup() to prevent
|
||||
Bleichenbacher's DSA attack.
|
||||
Extend BN_[pseudo_]rand: As before, top=1 forces the highest two bits
|
||||
to be set and top=0 forces the highest bit to be set; top=-1 is new
|
||||
and leaves the highest bit random.
|
||||
[Ulf Moeller, Bodo Moeller]
|
||||
|
||||
*) In the NCONF_...-based implementations for CONF_... queries
|
||||
(crypto/conf/conf_lib.c), if the input LHASH is NULL, avoid using
|
||||
a temporary CONF structure with the data component set to NULL
|
||||
(which gives segmentation faults in lh_retrieve).
|
||||
Instead, use NULL for the CONF pointer in CONF_get_string and
|
||||
CONF_get_number (which may use environment variables) and directly
|
||||
return NULL from CONF_get_section.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix potential buffer overrun for EBCDIC.
|
||||
[Ulf Moeller]
|
||||
|
||||
*) Tolerate nonRepudiation as being valid for S/MIME signing and certSign
|
||||
keyUsage if basicConstraints absent for a CA.
|
||||
[Steve Henson]
|
||||
|
||||
*) Make SMIME_write_PKCS7() write mail header values with a format that
|
||||
is more generally accepted (no spaces before the semicolon), since
|
||||
some programs can't parse those values properly otherwise. Also make
|
||||
sure BIO's that break lines after each write do not create invalid
|
||||
headers.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Make the CRL encoding routines work with empty SEQUENCE OF. The
|
||||
macros previously used would not encode an empty SEQUENCE OF
|
||||
and break the signature.
|
||||
[Steve Henson]
|
||||
[This change does not apply to 0.9.7.]
|
||||
|
||||
*) Zero the premaster secret after deriving the master secret in
|
||||
DH ciphersuites.
|
||||
[Steve Henson]
|
||||
|
||||
*) Add some EVP_add_digest_alias registrations (as found in
|
||||
OpenSSL_add_all_digests()) to SSL_library_init()
|
||||
aka OpenSSL_add_ssl_algorithms(). This provides improved
|
||||
compatibility with peers using X.509 certificates
|
||||
with unconventional AlgorithmIdentifier OIDs.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix for Irix with NO_ASM.
|
||||
["Bruce W. Forsberg" <bruce.forsberg@baesystems.com>]
|
||||
|
||||
*) ./config script fixes.
|
||||
[Ulf Moeller, Richard Levitte]
|
||||
|
||||
*) Fix 'openssl passwd -1'.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Change PKCS12_key_gen_asc() so it can cope with non null
|
||||
terminated strings whose length is passed in the passlen
|
||||
parameter, for example from PEM callbacks. This was done
|
||||
by adding an extra length parameter to asc2uni().
|
||||
[Steve Henson, reported by <oddissey@samsung.co.kr>]
|
||||
|
||||
*) Fix C code generated by 'openssl dsaparam -C': If a BN_bin2bn
|
||||
call failed, free the DSA structure.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix to uni2asc() to cope with zero length Unicode strings.
|
||||
These are present in some PKCS#12 files.
|
||||
[Steve Henson]
|
||||
|
||||
*) Increase s2->wbuf allocation by one byte in ssl2_new (ssl/s2_lib.c).
|
||||
Otherwise do_ssl_write (ssl/s2_pkt.c) will write beyond buffer limits
|
||||
when writing a 32767 byte record.
|
||||
[Bodo Moeller; problem reported by Eric Day <eday@concentric.net>]
|
||||
|
||||
*) In RSA_eay_public_{en,ed}crypt and RSA_eay_mod_exp (rsa_eay.c),
|
||||
obtain lock CRYPTO_LOCK_RSA before setting rsa->_method_mod_{n,p,q}.
|
||||
|
||||
(RSA objects have a reference count access to which is protected
|
||||
by CRYPTO_LOCK_RSA [see rsa_lib.c, s3_srvr.c, ssl_cert.c, ssl_rsa.c],
|
||||
so they are meant to be shared between threads.)
|
||||
[Bodo Moeller, Geoff Thorpe; original patch submitted by
|
||||
"Reddie, Steven" <Steven.Reddie@ca.com>]
|
||||
|
||||
*) Fix a deadlock in CRYPTO_mem_leaks().
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Use better test patterns in bntest.
|
||||
[Ulf M<>ller]
|
||||
|
||||
*) rand_win.c fix for Borland C.
|
||||
[Ulf M<>ller]
|
||||
|
||||
*) BN_rshift bugfix for n == 0.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Add a 'bctest' script that checks for some known 'bc' bugs
|
||||
so that 'make test' does not abort just because 'bc' is broken.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Store verify_result within SSL_SESSION also for client side to
|
||||
avoid potential security hole. (Re-used sessions on the client side
|
||||
always resulted in verify_result==X509_V_OK, not using the original
|
||||
result of the server certificate verification.)
|
||||
[Lutz Jaenicke]
|
||||
|
||||
*) Fix ssl3_pending: If the record in s->s3->rrec is not of type
|
||||
SSL3_RT_APPLICATION_DATA, return 0.
|
||||
Similarly, change ssl2_pending to return 0 if SSL_in_init(s) is true.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Fix SSL_peek:
|
||||
Both ssl2_peek and ssl3_peek, which were totally broken in earlier
|
||||
releases, have been re-implemented by renaming the previous
|
||||
implementations of ssl2_read and ssl3_read to ssl2_read_internal
|
||||
and ssl3_read_internal, respectively, and adding 'peek' parameters
|
||||
to them. The new ssl[23]_{read,peek} functions are calls to
|
||||
ssl[23]_read_internal with the 'peek' flag set appropriately.
|
||||
A 'peek' parameter has also been added to ssl3_read_bytes, which
|
||||
does the actual work for ssl3_read_internal.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Initialise "ex_data" member of RSA/DSA/DH structures prior to calling
|
||||
the method-specific "init()" handler. Also clean up ex_data after
|
||||
calling the method-specific "finish()" handler. Previously, this was
|
||||
happening the other way round.
|
||||
[Geoff Thorpe]
|
||||
|
||||
*) Increase BN_CTX_NUM (the number of BIGNUMs in a BN_CTX) to 16.
|
||||
The previous value, 12, was not always sufficient for BN_mod_exp().
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Make sure that shared libraries get the internal name engine with
|
||||
the full version number and not just 0. This should mark the
|
||||
shared libraries as not backward compatible. Of course, this should
|
||||
be changed again when we can guarantee backward binary compatibility.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Fix typo in get_cert_by_subject() in by_dir.c
|
||||
[Jean-Marc Desperrier <jean-marc.desperrier@certplus.com>]
|
||||
|
||||
*) Rework the system to generate shared libraries:
|
||||
|
||||
- Make note of the expected extension for the shared libraries and
|
||||
if there is a need for symbolic links from for example libcrypto.so.0
|
||||
to libcrypto.so.0.9.7. There is extended info in Configure for
|
||||
that.
|
||||
|
||||
- Make as few rebuilds of the shared libraries as possible.
|
||||
|
||||
- Still avoid linking the OpenSSL programs with the shared libraries.
|
||||
|
||||
- When installing, install the shared libraries separately from the
|
||||
static ones.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Fix SSL_CTX_set_read_ahead macro to actually use its argument.
|
||||
|
||||
Copy SSL_CTX's read_ahead flag to SSL object directly in SSL_new
|
||||
and not in SSL_clear because the latter is also used by the
|
||||
accept/connect functions; previously, the settings made by
|
||||
SSL_set_read_ahead would be lost during the handshake.
|
||||
[Bodo Moeller; problems reported by Anders Gertz <gertz@epact.se>]
|
||||
|
||||
*) Correct util/mkdef.pl to be selective about disabled algorithms.
|
||||
Previously, it would create entries for disableed algorithms no
|
||||
matter what.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Added several new manual pages for SSL_* function.
|
||||
[Lutz Jaenicke]
|
||||
|
||||
Changes between 0.9.5a and 0.9.6 [24 Sep 2000]
|
||||
|
||||
*) In ssl23_get_client_hello, generate an error message when faced
|
||||
with an initial SSL 3.0/TLS record that is too small to contain the
|
||||
first two bytes of the ClientHello message, i.e. client_version.
|
||||
(Note that this is a pathologic case that probably has never happened
|
||||
in real life.) The previous approach was to use the version number
|
||||
from the record header as a substitute; but our protocol choice
|
||||
should not depend on that one because it is not authenticated
|
||||
by the Finished messages.
|
||||
[Bodo Moeller]
|
||||
|
||||
*) More robust randomness gathering functions for Windows.
|
||||
[Jeffrey Altman <jaltman@columbia.edu>]
|
||||
|
||||
*) For compatibility reasons if the flag X509_V_FLAG_ISSUER_CHECK is
|
||||
not set then we don't setup the error code for issuer check errors
|
||||
to avoid possibly overwriting other errors which the callback does
|
||||
handle. If an application does set the flag then we assume it knows
|
||||
what it is doing and can handle the new informational codes
|
||||
appropriately.
|
||||
[Steve Henson]
|
||||
|
||||
*) Fix for a nasty bug in ASN1_TYPE handling. ASN1_TYPE is used for
|
||||
a general "ANY" type, as such it should be able to decode anything
|
||||
including tagged types. However it didn't check the class so it would
|
||||
wrongly interpret tagged types in the same way as their universal
|
||||
counterpart and unknown types were just rejected. Changed so that the
|
||||
tagged and unknown types are handled in the same way as a SEQUENCE:
|
||||
that is the encoding is stored intact. There is also a new type
|
||||
"V_ASN1_OTHER" which is used when the class is not universal, in this
|
||||
case we have no idea what the actual type is so we just lump them all
|
||||
together.
|
||||
[Steve Henson]
|
||||
|
||||
*) On VMS, stdout may very well lead to a file that is written to
|
||||
in a record-oriented fashion. That means that every write() will
|
||||
write a separate record, which will be read separately by the
|
||||
programs trying to read from it. This can be very confusing.
|
||||
|
||||
The solution is to put a BIO filter in the way that will buffer
|
||||
text until a linefeed is reached, and then write everything a
|
||||
line at a time, so every record written will be an actual line,
|
||||
not chunks of lines and not (usually doesn't happen, but I've
|
||||
seen it once) several lines in one record. BIO_f_linebuffer() is
|
||||
the answer.
|
||||
|
||||
Currently, it's a VMS-only method, because that's where it has
|
||||
been tested well enough.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Remove 'optimized' squaring variant in BN_mod_mul_montgomery,
|
||||
it can return incorrect results.
|
||||
(Note: The buggy variant was not enabled in OpenSSL 0.9.5a,
|
||||
but it was in 0.9.6-beta[12].)
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Disable the check for content being present when verifying detached
|
||||
signatures in pk7_smime.c. Some versions of Netscape (wrongly)
|
||||
include zero length content when signing messages.
|
||||
[Steve Henson]
|
||||
|
||||
*) New BIO_shutdown_wr macro, which invokes the BIO_C_SHUTDOWN_WR
|
||||
BIO_ctrl (for BIO pairs).
|
||||
[Bodo M<>ller]
|
||||
|
||||
*) Add DSO method for VMS.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Bug fix: Montgomery multiplication could produce results with the
|
||||
wrong sign.
|
||||
[Ulf M<>ller]
|
||||
|
||||
*) Add RPM specification openssl.spec and modify it to build three
|
||||
packages. The default package contains applications, application
|
||||
documentation and run-time libraries. The devel package contains
|
||||
include files, static libraries and function documentation. The
|
||||
doc package contains the contents of the doc directory. The original
|
||||
openssl.spec was provided by Damien Miller <djm@mindrot.org>.
|
||||
[Richard Levitte]
|
||||
|
||||
*) Add a large number of documentation files for many SSL routines.
|
||||
[Lutz Jaenicke <Lutz.Jaenicke@aet.TU-Cottbus.DE>]
|
||||
|
||||
*) Add a configuration entry for Sony News 4.
|
||||
[NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp>]
|
||||
|
||||
*) Don't set the two most significant bits to one when generating a
|
||||
random number < q in the DSA library.
|
||||
[Ulf M<>ller]
|
||||
|
||||
*) New SSL API mode 'SSL_MODE_AUTO_RETRY'. This disables the default
|
||||
behaviour that SSL_read may result in SSL_ERROR_WANT_READ (even if
|
||||
the underlying transport is blocking) if a handshake took place.
|
||||
(The default behaviour is needed by applications such as s_client
|
||||
and s_server that use select() to determine when to use SSL_read;
|
||||
but for applications that know in advance when to expect data, it
|
||||
just makes things more complicated.)
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Add RAND_egd_bytes(), which gives control over the number of bytes read
|
||||
from EGD.
|
||||
[Ben Laurie]
|
||||
|
||||
*) Add a few more EBCDIC conditionals that make `req' and `x509'
|
||||
work better on such systems.
|
||||
@@ -198,7 +697,7 @@
|
||||
[Steve Henson]
|
||||
|
||||
*) Changes needed for Tandem NSK.
|
||||
[Scott Uroff scott@xypro.com]
|
||||
[Scott Uroff <scott@xypro.com>]
|
||||
|
||||
*) Fix SSL 2.0 rollback checking: Due to an off-by-one error in
|
||||
RSA_padding_check_SSLv23(), special padding was never detected
|
||||
@@ -1976,7 +2475,7 @@
|
||||
copied!)
|
||||
[Bodo Moeller]
|
||||
|
||||
*) Bugfix: SSL_set_mode ignored its parameter, only SSL_CTX_set_mode
|
||||
*) Bugfix: SSL_set_options ignored its parameter, only SSL_CTX_set_options
|
||||
worked.
|
||||
|
||||
*) Fix problems with no-hmac etc.
|
||||
|
192
Configure
192
Configure
@@ -33,6 +33,10 @@ my $usage="Usage: Configure [no-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-
|
||||
# multithreaded applications (default is "threads" if we
|
||||
# know how to do it)
|
||||
# [no-]shared [don't] try to create shared libraries when supported.
|
||||
# IT IS NOT RECOMMENDED TO USE "shared"! Since this is a
|
||||
# development branch, the positions of the ENGINE symbols
|
||||
# in the transfer vector are constantly moving, so binary
|
||||
# backward compatibility can't be guaranteed in any way.
|
||||
# no-asm do not use assembler
|
||||
# no-dso do not compile in any native shared-library methods. This
|
||||
# will ensure that all methods just return NULL.
|
||||
@@ -94,6 +98,11 @@ my $x86_elf_asm="asm/bn86-elf.o asm/co86-elf.o:asm/dx86-elf.o asm/yx86-elf.o:asm
|
||||
my $x86_out_asm="asm/bn86-out.o asm/co86-out.o:asm/dx86-out.o asm/yx86-out.o:asm/bx86-out.o:asm/mx86-out.o:asm/sx86-out.o:asm/cx86-out.o:asm/rx86-out.o:asm/rm86-out.o:asm/r586-out.o";
|
||||
my $x86_bsdi_asm="asm/bn86bsdi.o asm/co86bsdi.o:asm/dx86bsdi.o asm/yx86bsdi.o:asm/bx86bsdi.o:asm/mx86bsdi.o:asm/sx86bsdi.o:asm/cx86bsdi.o:asm/rx86bsdi.o:asm/rm86bsdi.o:asm/r586bsdi.o";
|
||||
|
||||
my $mips3_irix_asm="asm/mips3.o::::::::";
|
||||
# There seems to be boundary faults in asm/alpha.s.
|
||||
#my $alpha_asm="asm/alpha.o::::::::";
|
||||
my $alpha_asm="::::::::";
|
||||
|
||||
# -DB_ENDIAN slows things down on a sparc for md5, but helps sha1.
|
||||
# So the md5_locl.h file has an undef B_ENDIAN if sun is defined
|
||||
|
||||
@@ -132,32 +141,35 @@ my %table=(
|
||||
# surrounds it with #APP #NO_APP comment pair which (at least Solaris
|
||||
# 7_x86) /usr/ccs/bin/as fails to assemble with "Illegal mnemonic"
|
||||
# error message.
|
||||
"solaris-x86-gcc","gcc:-O3 -fomit-frame-pointer -m486 -Wall -DL_ENDIAN -DNO_INLINE_ASM::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_sol_asm}:dlfcn:solaris-shared:-fPIC",
|
||||
"solaris-x86-gcc","gcc:-O3 -fomit-frame-pointer -m486 -Wall -DL_ENDIAN -DNO_INLINE_ASM::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_sol_asm}:dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
#### Solaris x86 with Sun C setups
|
||||
"solaris-x86-cc","cc:-fast -O -Xa::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_UNROLL BF_PTR::::::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
#### SPARC Solaris with GNU C setups
|
||||
"solaris-sparcv7-gcc","gcc:-O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR::::::::::dlfcn:solaris-shared:-fPIC",
|
||||
"solaris-sparcv8-gcc","gcc:-mv8 -O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-fPIC",
|
||||
"solaris-sparcv9-gcc","gcc:-mcpu=ultrasparc -O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:solaris-shared:-fPIC",
|
||||
"solaris-sparcv7-gcc","gcc:-O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR::::::::::dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"solaris-sparcv8-gcc","gcc:-mv8 -O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"solaris-sparcv9-gcc","gcc:-mcpu=ultrasparc -O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
# gcc pre-2.8 doesn't understand -mcpu=ultrasparc, so fall down to -mv8
|
||||
# but keep the assembler modules.
|
||||
"solaris-sparcv9-gcc27","gcc:-mv8 -O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus-gcc27.o:::asm/md5-sparcv8plus-gcc27.o::::::dlfcn:solaris-shared:-fPIC",
|
||||
"solaris-sparcv9-gcc27","gcc:-mv8 -O3 -fomit-frame-pointer -Wall -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus-gcc27.o:::asm/md5-sparcv8plus-gcc27.o::::::dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
####
|
||||
"debug-solaris-sparcv8-gcc","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -O -g -mv8 -Wall -DB_ENDIAN::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-fPIC",
|
||||
"debug-solaris-sparcv9-gcc","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -O -g -mcpu=ultrasparc -Wall -DB_ENDIAN::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus.o:::::::::dlfcn:solaris-shared:-fPIC",
|
||||
"debug-solaris-sparcv8-gcc","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -O -g -mv8 -Wall -DB_ENDIAN::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"debug-solaris-sparcv9-gcc","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -O -g -mcpu=ultrasparc -Wall -DB_ENDIAN::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/sparcv8plus.o:::::::::dlfcn:gnu-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
#### SPARC Solaris with Sun C setups
|
||||
# DO NOT use /xO[34] on sparc with SC3.0. It is broken, and will not pass the tests
|
||||
"solaris-sparc-sc3","cc:-fast -O -Xa -DB_ENDIAN::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_UNROLL BF_PTR::::::::::dlfcn:solaris-shared:-KPIC",
|
||||
"solaris-sparc-sc3","cc:-fast -O -Xa -DB_ENDIAN::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_UNROLL BF_PTR::::::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
# SC4.0 doesn't pass 'make test', upgrade to SC5.0 or SC4.2.
|
||||
# SC4.2 is ok, better than gcc even on bn as long as you tell it -xarch=v8
|
||||
# SC5.0 note: Compiler common patch 107357-01 or later is required!
|
||||
"solaris-sparcv7-cc","cc:-xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR::::::::::dlfcn:solaris-shared:-KPIC",
|
||||
"solaris-sparcv8-cc","cc:-xarch=v8 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-KPIC",
|
||||
"solaris-sparcv9-cc","cc:-xtarget=ultra -xarch=v8plus -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK_LL DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:solaris-shared:-KPIC",
|
||||
"solaris64-sparcv9-cc","cc:-xtarget=ultra -xarch=v9 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL BF_PTR::::asm/md5-sparcv9.o::::::dlfcn:solaris-shared:-KPIC",
|
||||
"solaris-sparcv7-cc","cc:-xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR::::::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"solaris-sparcv8-cc","cc:-xarch=v8 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"solaris-sparcv9-cc","cc:-xtarget=ultra -xarch=v8plus -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK_LL DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"solaris64-sparcv9-cc","cc:-xtarget=ultra -xarch=v9 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL BF_PTR::::asm/md5-sparcv9.o::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):/usr/ccs/bin/ar rs",
|
||||
####
|
||||
"debug-solaris-sparcv8-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -xarch=v8 -g -O -xstrconst -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-KPIC",
|
||||
"debug-solaris-sparcv9-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -xtarget=ultra -xarch=v8plus -g -O -xstrconst -Xa -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK_LL DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:solaris-shared:-KPIC",
|
||||
"debug-solaris-sparcv8-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -xarch=v8 -g -O -xstrconst -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"debug-solaris-sparcv9-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -xtarget=ultra -xarch=v8plus -g -O -xstrconst -Xa -DB_ENDIAN -DBN_DIV2W -DULTRASPARC::-D_REENTRANT:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK_LL DES_PTR DES_RISC1 DES_UNROLL BF_PTR:asm/sparcv8plus.o:::asm/md5-sparcv8plus.o::::::dlfcn:solaris-shared:-KPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
#### SPARC Linux setups
|
||||
"linux-sparcv7","gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR::",
|
||||
@@ -183,11 +195,11 @@ my %table=(
|
||||
# Only N32 and N64 ABIs are supported. If you need O32 ABI build, invoke
|
||||
# './Configure irix-[g]cc' manually.
|
||||
# -mips4 flag is added by ./config when appropriate.
|
||||
"irix-mips3-gcc","gcc:-mabi=n32 -mmips-as -O3 -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::MD2_CHAR RC4_INDEX RC4_CHAR RC4_CHUNK_LL DES_UNROLL DES_RISC2 DES_PTR BF_PTR SIXTY_FOUR_BIT:asm/mips3.o::",
|
||||
"irix-mips3-cc", "cc:-n32 -O2 -use_readonly_const -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::DES_PTR RC4_CHAR RC4_CHUNK_LL DES_RISC2 DES_UNROLL BF_PTR SIXTY_FOUR_BIT:asm/mips3.o::",
|
||||
"irix-mips3-gcc","gcc:-mabi=n32 -mmips-as -O3 -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::MD2_CHAR RC4_INDEX RC4_CHAR RC4_CHUNK_LL DES_UNROLL DES_RISC2 DES_PTR BF_PTR SIXTY_FOUR_BIT:${mips3_irix_asm}",
|
||||
"irix-mips3-cc", "cc:-n32 -O2 -use_readonly_const -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::DES_PTR RC4_CHAR RC4_CHUNK_LL DES_RISC2 DES_UNROLL BF_PTR SIXTY_FOUR_BIT:${mips3_irix_asm}",
|
||||
# N64 ABI builds.
|
||||
"irix64-mips4-gcc","gcc:-mabi=64 -mips4 -mmips-as -O3 -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:asm/mips3.o::",
|
||||
"irix64-mips4-cc", "cc:-64 -mips4 -O2 -use_readonly_const -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:asm/mips3.o::",
|
||||
"irix64-mips4-gcc","gcc:-mabi=64 -mips4 -mmips-as -O3 -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:${mips3_irix_asm}",
|
||||
"irix64-mips4-cc", "cc:-64 -mips4 -O2 -use_readonly_const -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:${mips3_irix_asm}",
|
||||
|
||||
#### Unified HP-UX ANSI C configs.
|
||||
# Special notes:
|
||||
@@ -217,11 +229,20 @@ my %table=(
|
||||
# crypto/sha/sha_lcl.h.
|
||||
# <appro@fy.chalmers.se>
|
||||
#
|
||||
"hpux-parisc-cc","cc:-Ae +O3 +ESlit -z -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY:::-ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl",
|
||||
#!#"hpux-parisc-cc","cc:-Ae +O3 +ESlit -z -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY:::-ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl",
|
||||
# Since there is mention of this in shlib/hpux10-cc.sh
|
||||
"hpux-parisc-cc-o4","cc:-Ae +O4 +ESlit -z -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY:::-ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl",
|
||||
"hpux-parisc-gcc","gcc:-O3 -DB_ENDIAN -DBN_DIV2W:::-ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl",
|
||||
"hpux64-parisc-cc","cc:-Ae +DD64 +O3 +ESlit -z -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT:-ldld:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl",
|
||||
"hpux64-parisc-cc","cc:-Ae +DD64 +O3 +ESlit -z -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT:-ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dlfcn",
|
||||
|
||||
# More attempts at unified 10.X and 11.X targets for HP C compiler.
|
||||
#
|
||||
# Chris Ruemmler <ruemmler@cup.hp.com>
|
||||
# Kevin Steves <ks@hp.se>
|
||||
"hpux-parisc-cc","cc:+O3 +Optrs_strongly_typed +Olibcalls -Ae +ESlit -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY::-D_REENTRANT:-ldld:MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl",
|
||||
"hpux-parisc2-cc","cc:+DA2.0 +DS2.0 +O3 +Optrs_strongly_typed +Olibcalls -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT:-ldld:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/pa-risc2.o:::::::::dl",
|
||||
"hpux64-parisc2-cc","cc:+DD64 +O3 +Optrs_strongly_typed +Olibcalls -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT:-ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/pa-risc2W.o:::::::::dlfcn",
|
||||
"hpux-parisc1_1-cc","cc:+DA1.1 +DS1.1 +O3 +Optrs_strongly_typed +Olibcalls -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT:-ldld:MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl",
|
||||
|
||||
# HPUX 9.X config.
|
||||
# Don't use the bundled cc. It is broken. Use HP ANSI C if possible, or
|
||||
@@ -252,13 +273,16 @@ my %table=(
|
||||
#"hpux11-64bit-cc","cc:+DA2.0W -g -D_HPUX_SOURCE -Aa -Ae +ESlit::-D_REENTRANT::SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT :::",
|
||||
# Use unified settings above instead.
|
||||
|
||||
#### HP MPE/iX http://jazz.external.hp.com/src/openssl/
|
||||
"MPE/iX-gcc", "gcc:-D_ENDIAN -DBN_DIV2W -O3 -DMPE -D_POSIX_SOURCE -D_SOCKET_SOURCE -I/SYSLOG/PUB::(unknown):-L/SYSLOG/PUB -lsyslog -lsocket -lcurses:BN_LLONG DES_PTR DES_UNROLL DES_RISC1:::",
|
||||
|
||||
# Dec Alpha, OSF/1 - the alpha164-cc is the flags for a 21164A with
|
||||
# the new compiler
|
||||
# For gcc, the following gave a %50 speedup on a 164 over the 'DES_INT' version
|
||||
"alpha-gcc","gcc:-O3::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_RISC1:asm/alpha.o:::::::::dlfcn:true64-shared",
|
||||
"alpha-cc", "cc:-std1 -tune host -O4 -readonly_strings::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK:asm/alpha.o:::::::::dlfcn:true64-shared",
|
||||
"alpha164-cc", "cc:-std1 -tune host -fast -readonly_strings::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK:asm/alpha.o:::::::::dlfcn:true64-shared",
|
||||
"FreeBSD-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC2:::",
|
||||
"alpha-gcc","gcc:-O3::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_RISC1:${alpha_asm}:dlfcn:tru64-shared::.so",
|
||||
"alpha-cc", "cc:-std1 -tune host -O4 -readonly_strings::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK:${alpha_asm}:dlfcn:tru64-shared::.so",
|
||||
"alpha164-cc", "cc:-std1 -tune host -fast -readonly_strings::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK:${alpha_asm}:dlfcn:tru64-shared::.so",
|
||||
"FreeBSD-alpha","gcc:-DTERMIOS -O -fomit-frame-pointer::(unknown)::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC2::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
#### Alpha Linux with GNU C and Compaq C setups
|
||||
# Special notes:
|
||||
@@ -273,31 +297,32 @@ my %table=(
|
||||
#
|
||||
# <appro@fy.chalmers.se>
|
||||
#
|
||||
"linux-alpha-gcc","gcc:-O3 -DL_ENDIAN -DTERMIO::-D_REENTRANT::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:asm/alpha.o::",
|
||||
"linux-alpha+bwx-gcc","gcc:-O3 -DL_ENDIAN -DTERMIO::-D_REENTRANT::SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:asm/alpha.o::",
|
||||
"linux-alpha-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:asm/alpha.o::",
|
||||
"linux-alpha+bwx-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT::SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:asm/alpha.o::",
|
||||
"linux-alpha-gcc","gcc:-O3 -DL_ENDIAN -DTERMIO::-D_REENTRANT:-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"linux-alpha+bwx-gcc","gcc:-O3 -DL_ENDIAN -DTERMIO::-D_REENTRANT:-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:${alpha_asm}:dlfcn:linux-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"linux-alpha-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:${alpha_asm}",
|
||||
"linux-alpha+bwx-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT::SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:${alpha_asm}",
|
||||
|
||||
# assembler versions -- currently defunct:
|
||||
##"OpenBSD-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown):SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2:asm/alpha.o::",
|
||||
##"OpenBSD-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown):SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2:${alpha_asm}",
|
||||
|
||||
# The intel boxes :-), It would be worth seeing if bsdi-gcc can use the
|
||||
# bn86-elf.o file file since it is hand tweaked assembler.
|
||||
"linux-elf", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall::-D_REENTRANT:-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC",
|
||||
"debug-linux-elf","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -m486 -Wall::-D_REENTRANT:-lefence:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||
"debug-linux-elf-noefence","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -m486 -Wall::-D_REENTRANT::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||
"linux-elf", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall::-D_REENTRANT:-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"debug-linux-elf","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -m486 -Wall::-D_REENTRANT:-lefence -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||
"debug-linux-elf-noefence","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -m486 -Wall::-D_REENTRANT:-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||
"linux-aout", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}",
|
||||
"linux-mips", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::(unknown)::BN_LLONG:::",
|
||||
"linux-ppc", "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::BN_LLONG::",
|
||||
"linux-m68k", "gcc:-DB_ENDIAN -DTERMIO -O2 -fomit-frame-pointer -Wall::-D_REENTRANT::BN_LLONG::",
|
||||
"linux-s390", "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::BN_LLONG::",
|
||||
"linux-ia64", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::(unknown)::SIXTY_FOUR_BIT_LONG::",
|
||||
"NetBSD-sparc", "gcc:-DTERMIOS -O3 -fomit-frame-pointer -mv8 -Wall -DB_ENDIAN::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL:::",
|
||||
"NetBSD-m68", "gcc:-DTERMIOS -O3 -fomit-frame-pointer -Wall -DB_ENDIAN::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL:::",
|
||||
"NetBSD-x86", "gcc:-DTERMIOS -O3 -fomit-frame-pointer -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:",
|
||||
"FreeBSD-elf", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
||||
"NetBSD-sparc", "gcc:-DTERMIOS -O3 -fomit-frame-pointer -mv8 -Wall -DB_ENDIAN::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"NetBSD-m68", "gcc:-DTERMIOS -O3 -fomit-frame-pointer -Wall -DB_ENDIAN::(unknown)::BN_LLONG MD2_CHAR RC4_INDEX DES_UNROLL::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"NetBSD-x86", "gcc:-DTERMIOS -O3 -fomit-frame-pointer -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"FreeBSD-elf", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"FreeBSD", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}",
|
||||
"bsdi-gcc", "gcc:-O3 -ffast-math -DL_ENDIAN -DPERL5 -m486::(unknown)::RSA_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_bsdi_asm}",
|
||||
"bsdi-elf-gcc", "gcc:-DPERL5 -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
||||
"bsdi-elf-gcc", "gcc:-DPERL5 -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown):-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"nextstep", "cc:-O -Wall:<libc.h>:(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:::",
|
||||
"nextstep3.3", "cc:-O3 -Wall:<libc.h>:(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:::",
|
||||
# NCR MP-RAS UNIX ver 02.03.01
|
||||
@@ -307,18 +332,27 @@ my %table=(
|
||||
"qnx4", "cc:-DL_ENDIAN -DTERMIO::(unknown)::${x86_gcc_des} ${x86_gcc_opts}:",
|
||||
|
||||
# Linux on ARM
|
||||
"linux-elf-arm","gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::BN_LLONG::::::::::dlfcn:linux-shared:-fPIC",
|
||||
"linux-elf-arm","gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::BN_LLONG::::::::::dlfcn:linux-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
# UnixWare 2.0
|
||||
"unixware-2.0","cc:-O -DFILIO_H::(unknown):-lsocket -lnsl:${x86_gcc_des} ${x86_gcc_opts}:::",
|
||||
"unixware-2.0-pentium","cc:-O -DFILIO_H -Kpentium -Kthread::(unknown):-lsocket -lnsl:MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
# UnixWare 2.0x fails destest with -O
|
||||
"unixware-2.0","cc:-DFILIO_H::-Kthread:-lsocket -lnsl -lx:${x86_gcc_des} ${x86_gcc_opts}:::",
|
||||
"unixware-2.0-pentium","cc:-DFILIO_H -Kpentium::-Kthread:-lsocket -lnsl -lx:MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
|
||||
# UnixWare 2.1
|
||||
"unixware-2.1","cc:-O -DFILIO_H::-Kthread:-lsocket -lnsl -lx:${x86_gcc_des} ${x86_gcc_opts}:::",
|
||||
"unixware-2.1-pentium","cc:-O -DFILIO_H -Kpentium::-Kthread:-lsocket -lnsl -lx:MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
"unixware-2.1-p6","cc:-O -DFILIO_H -Kp6::-Kthread:-lsocket -lnsl -lx:MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
|
||||
# UnixWare 7
|
||||
"unixware-7","cc:-O -DFILIO_H -Kalloca::-Kthread:-lsocket -lnsl:MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
"unixware-7","cc:-O -DFILIO_H -Kalloca::-Kthread:-lsocket -lnsl:BN_LLONG MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
"unixware-7-pentium","cc:-O -DFILIO_H -Kalloca -Kpentium::-Kthread:-lsocket -lnsl:BN_LLONG MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
"unixware-7-pentium_pro","cc:-O -DFILIO_H -Kalloca -Kpentium_pro::-Kthread:-lsocket -lnsl:BN_LLONG MD2_CHAR RC4_INDEX ${x86_gcc_des}::",
|
||||
|
||||
# IBM's AIX.
|
||||
"aix-cc", "cc:-O -DAIX -DB_ENDIAN -qmaxmem=16384::(unknown)::BN_LLONG RC4_CHAR:::",
|
||||
"aix-gcc", "gcc:-O3 -DAIX -DB_ENDIAN::(unknown)::BN_LLONG RC4_CHAR:::",
|
||||
"aix43-cc", "cc:-O -DAIX -DB_ENDIAN -qmaxmem=16384::(unknown)::BN_LLONG RC4_CHAR::::::::::dlfcn:",
|
||||
"aix43-gcc", "gcc:-O3 -DAIX -DB_ENDIAN::(unknown)::BN_LLONG RC4_CHAR::::::::::dlfcn:",
|
||||
|
||||
#
|
||||
# Cray T90 (SDSC)
|
||||
@@ -345,12 +379,16 @@ my %table=(
|
||||
|
||||
# DGUX, 88100.
|
||||
"dgux-R3-gcc", "gcc:-O3 -fomit-frame-pointer::(unknown)::RC4_INDEX DES_UNROLL:::",
|
||||
"dgux-R4-gcc", "gcc:-O3 -fomit-frame-pointer::(unknown):-lnsl -lsocket:RC4_INDEX:RC4_INDEX DES_UNROLL:::",
|
||||
"dgux-R4-gcc", "gcc:-O3 -fomit-frame-pointer::(unknown):-lnsl -lsocket:RC4_INDEX DES_UNROLL:::",
|
||||
"dgux-R4-x86-gcc", "gcc:-O3 -fomit-frame-pointer -DL_ENDIAN::(unknown):-lnsl -lsocket:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
||||
|
||||
# SCO 3 - Tim Rice <tim@multitalents.net>
|
||||
"sco3-gcc", "gcc:-O3 -fomit-frame-pointer -Dssize_t=int -DNO_SYS_UN_H::(unknown):-lsocket:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:::", # the SCO assembler doesn't seem to like our assembler files ...
|
||||
|
||||
# SCO 5 - Ben Laurie <ben@algroup.co.uk> says the -O breaks the
|
||||
# SCO cc.
|
||||
"sco5-cc", "cc:::(unknown):-lsocket:${x86_gcc_des} ${x86_gcc_opts}:::", # des options?
|
||||
"sco5-cc-pentium", "cc:-Kpentium::(unknown):-lsocket:${x86_gcc_des} ${x86_gcc_opts}:::", # des options?
|
||||
"sco5-gcc", "gcc:-O3 -fomit-frame-pointer::(unknown):-lsocket:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:::", # the SCO assembler doesn't seem to like our assembler files ...
|
||||
|
||||
# Sinix/ReliantUNIX RM400
|
||||
@@ -364,24 +402,24 @@ my %table=(
|
||||
|
||||
# Windows NT, Microsoft Visual C++ 4.0
|
||||
|
||||
"VC-NT","cl:::::BN_LLONG RC4_INDEX ${x86_gcc_opts}:::",
|
||||
"VC-WIN32","cl:::::BN_LLONG RC4_INDEX ${x86_gcc_opts}:::",
|
||||
"VC-NT","cl:::::BN_LLONG RC4_INDEX ${x86_gcc_opts}::::::::::win32",
|
||||
"VC-WIN32","cl:::::BN_LLONG RC4_INDEX ${x86_gcc_opts}::::::::::win32",
|
||||
"VC-WIN16","cl:::(unknown)::MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX THIRTY_TWO_BIT:::",
|
||||
"VC-W31-16","cl:::(unknown)::BN_LLONG MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX SIXTEEN_BIT:::",
|
||||
"VC-W31-32","cl:::::BN_LLONG MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX THIRTY_TWO_BIT:::",
|
||||
"VC-MSDOS","cl:::(unknown)::BN_LLONG MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX SIXTEEN_BIT:::",
|
||||
|
||||
# Borland C++ 4.5
|
||||
"BC-32","bcc32:::::BN_LLONG DES_PTR RC4_INDEX:::",
|
||||
"BC-32","bcc32:::::BN_LLONG DES_PTR RC4_INDEX::::::::::win32",
|
||||
"BC-16","bcc:::(unknown)::BN_LLONG DES_PTR RC4_INDEX SIXTEEN_BIT:::",
|
||||
|
||||
# Mingw32
|
||||
# (Note: the real CFLAGS for Windows builds are defined by util/mk1mf.pl
|
||||
# and its library files in util/pl/*)
|
||||
"Mingw32", "gcc:-DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:",
|
||||
"Mingw32", "gcc:-DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::win32",
|
||||
|
||||
# CygWin32
|
||||
"CygWin32", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:",
|
||||
"CygWin32", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::win32",
|
||||
|
||||
# Ultrix from Bernhard Simon <simon@zid.tuwien.ac.at>
|
||||
"ultrix-cc","cc:-std1 -O -Olimit 1000 -DL_ENDIAN::(unknown)::::::",
|
||||
@@ -390,14 +428,17 @@ my %table=(
|
||||
##"ultrix","cc:-O2 -DNOPROTO -DNOCONST -DL_ENDIAN::(unknown)::::::",
|
||||
|
||||
# Some OpenBSD from Bob Beck <beck@obtuse.com>
|
||||
"OpenBSD-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown)::SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2:::",
|
||||
"OpenBSD-x86", "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -m486::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}:dlfcn",
|
||||
"OpenBSD", "gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown)::BN_LLONG RC2_CHAR RC4_INDEX DES_UNROLL:::",
|
||||
"OpenBSD-mips","gcc:-O2 -DL_ENDIAN::(unknown):BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC2 DES_PTR BF_PTR::::",
|
||||
"OpenBSD-alpha","gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown)::SIXTY_FOUR_BIT_LONG DES_INT DES_PTR DES_RISC2::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"OpenBSD-x86", "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -m486::(unknown)::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}:dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"OpenBSD", "gcc:-DTERMIOS -O3 -fomit-frame-pointer::(unknown)::BN_LLONG RC2_CHAR RC4_INDEX DES_UNROLL::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
"OpenBSD-mips","gcc:-O2 -DL_ENDIAN::(unknown):BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC2 DES_PTR BF_PTR:::::::::::dlfcn:bsd-gcc-shared:-fPIC:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||
|
||||
##### MacOS X (a.k.a. Rhapsody) setup
|
||||
"rhapsody-ppc-cc","cc:-O3 -DB_ENDIAN::(unknown)::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::",
|
||||
|
||||
##### Sony NEWS-OS 4.x
|
||||
"newsos4-gcc","gcc:-O -DB_ENDIAN -DNEWS4::(unknown):-lmld -liberty:BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC1 DES_UNROLL BF_PTR::::",
|
||||
|
||||
);
|
||||
|
||||
my @WinTargets=qw(VC-NT VC-WIN32 VC-WIN16 VC-W31-16 VC-W31-32 VC-MSDOS BC-32
|
||||
@@ -405,6 +446,7 @@ my @WinTargets=qw(VC-NT VC-WIN32 VC-WIN16 VC-W31-16 VC-W31-32 VC-MSDOS BC-32
|
||||
|
||||
my $prefix="";
|
||||
my $openssldir="";
|
||||
my $exe_ext="";
|
||||
my $install_prefix="";
|
||||
my $no_threads=0;
|
||||
my $no_shared=1;
|
||||
@@ -432,10 +474,10 @@ my $md5_obj="";
|
||||
my $sha1_obj="";
|
||||
my $rmd160_obj="";
|
||||
my $processor="";
|
||||
my $ranlib;
|
||||
my $default_ranlib;
|
||||
my $perl;
|
||||
|
||||
$ranlib=&which("ranlib") or $ranlib="true";
|
||||
$default_ranlib= &which("ranlib") or $default_ranlib="true";
|
||||
$perl=$ENV{'PERL'} or $perl=&which("perl5") or $perl=&which("perl")
|
||||
or $perl="perl";
|
||||
|
||||
@@ -621,6 +663,7 @@ print "Configuring for $target\n";
|
||||
|
||||
my $IsWindows=scalar grep /^$target$/,@WinTargets;
|
||||
|
||||
$exe_ext=".exe" if ($target eq "CygWin32");
|
||||
$openssldir="/usr/local/ssl" if ($openssldir eq "" and $prefix eq "");
|
||||
$prefix=$openssldir if $prefix eq "";
|
||||
|
||||
@@ -634,8 +677,8 @@ $openssldir=$prefix . "/" . $openssldir if $openssldir !~ /^\//;
|
||||
print "IsWindows=$IsWindows\n";
|
||||
|
||||
(my $cc,my $cflags,my $unistd,my $thread_cflag,my $lflags,my $bn_ops,my $bn_obj,my $des_obj,my $bf_obj,
|
||||
$md5_obj,$sha1_obj,my $cast_obj,my $rc4_obj,$rmd160_obj,my $rc5_obj,my $dso_scheme,my $shared_target,my $shared_cflag)=
|
||||
split(/\s*:\s*/,$table{$target} . ":" x 22 , -1);
|
||||
$md5_obj,$sha1_obj,my $cast_obj,my $rc4_obj,$rmd160_obj,my $rc5_obj,my $dso_scheme,my $shared_target,my $shared_cflag,my $shared_extension,my $ranlib)=
|
||||
split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||
$cflags="$flags$cflags" if ($flags ne "");
|
||||
|
||||
# The DSO code currently always implements all functions so that no
|
||||
@@ -710,17 +753,27 @@ if ($threads)
|
||||
}
|
||||
|
||||
# You will find shlib_mark1 and shlib_mark2 explained in Makefile.org
|
||||
my $shared_mark1 = "";
|
||||
my $shared_mark2 = "";
|
||||
if ($shared_cflag ne "")
|
||||
my $shared_mark = "";
|
||||
if ($shared_target ne "")
|
||||
{
|
||||
$cflags = "$shared_cflag $cflags";
|
||||
if ($shared_cflag ne "")
|
||||
{
|
||||
$cflags = "$shared_cflag $cflags";
|
||||
}
|
||||
if (!$no_shared)
|
||||
{
|
||||
$shared_mark1 = ".shlib-clean.";
|
||||
$shared_mark2 = ".shlib.";
|
||||
#$shared_mark = "\$(SHARED_LIBS)";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$no_shared = 1;
|
||||
}
|
||||
|
||||
if ($ranlib eq "")
|
||||
{
|
||||
$ranlib = $default_ranlib;
|
||||
}
|
||||
|
||||
#my ($bn1)=split(/\s+/,$bn_obj);
|
||||
#$bn1 = "" unless defined $bn1;
|
||||
@@ -802,6 +855,7 @@ while (<IN>)
|
||||
s/^SHLIB_VERSION_HISTORY=.*/SHLIB_VERSION_HISTORY=$shlib_version_history/;
|
||||
s/^SHLIB_MAJOR=.*/SHLIB_MAJOR=$shlib_major/;
|
||||
s/^SHLIB_MINOR=.*/SHLIB_MINOR=$shlib_minor/;
|
||||
s/^SHLIB_EXT=.*/SHLIB_EXT=$shared_extension/;
|
||||
s/^INSTALLTOP=.*$/INSTALLTOP=$prefix/;
|
||||
s/^OPENSSLDIR=.*$/OPENSSLDIR=$openssldir/;
|
||||
s/^INSTALL_PREFIX=.*$/INSTALL_PREFIX=$install_prefix/;
|
||||
@@ -812,6 +866,7 @@ while (<IN>)
|
||||
s/^CFLAG=.*$/CFLAG= $cflags/;
|
||||
s/^DEPFLAG=.*$/DEPFLAG= $depflags/;
|
||||
s/^EX_LIBS=.*$/EX_LIBS= $lflags/;
|
||||
s/^EXE_EXT=.*$/EXE_EXT= $exe_ext/;
|
||||
s/^BN_ASM=.*$/BN_ASM= $bn_obj/;
|
||||
s/^DES_ENC=.*$/DES_ENC= $des_obj/;
|
||||
s/^BF_ENC=.*$/BF_ENC= $bf_obj/;
|
||||
@@ -825,9 +880,9 @@ while (<IN>)
|
||||
s/^RANLIB=.*/RANLIB= $ranlib/;
|
||||
s/^PERL=.*/PERL= $perl/;
|
||||
s/^SHLIB_TARGET=.*/SHLIB_TARGET=$shared_target/;
|
||||
s/^SHLIB_MARK1=.*/SHLIB_MARK1=$shared_mark1/;
|
||||
s/^SHLIB_MARK2=.*/SHLIB_MARK2=$shared_mark2/;
|
||||
s/^LIBS=.*/LIBS=libcrypto\.so\* libssl\.so\*/ if (!$no_shared);
|
||||
s/^SHLIB_MARK=.*/SHLIB_MARK=$shared_mark/;
|
||||
s/^SHARED_LIBS=.*/SHARED_LIBS=\$(SHARED_CRYPTO) \$(SHARED_SSL)/ if (!$no_shared);
|
||||
s/^SHARED_LIBS_LINK_EXTS=.*/SHARED_LIBS_LINK_EXTS=.so.\$(SHLIB_MAJOR) .so/ if ($shared_extension ne "" && $shared_extension !~ /^\.s[ol]$/);
|
||||
print OUT $_."\n";
|
||||
}
|
||||
close(IN);
|
||||
@@ -1114,8 +1169,9 @@ sub print_table_entry
|
||||
(my $cc,my $cflags,my $unistd,my $thread_cflag,my $lflags,my $bn_ops,
|
||||
my $bn_obj,my $des_obj,my $bf_obj,
|
||||
my $md5_obj,my $sha1_obj,my $cast_obj,my $rc4_obj,my $rmd160_obj,
|
||||
my $rc5_obj,my $dso_scheme,my $shared_target,my $shared_cflag)=
|
||||
split(/\s*:\s*/,$table{$target} . ":" x 22 , -1);
|
||||
my $rc5_obj,my $dso_scheme,my $shared_target,my $shared_cflag,
|
||||
my $shared_extension,my $ranlib)=
|
||||
split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||
|
||||
print <<EOF
|
||||
|
||||
@@ -1138,5 +1194,7 @@ sub print_table_entry
|
||||
\$dso_scheme = $dso_scheme
|
||||
\$shared_target= $shared_target
|
||||
\$shared_cflag = $shared_cflag
|
||||
\$shared_extension = $shared_extension
|
||||
\$ranlib = $ranlib
|
||||
EOF
|
||||
}
|
||||
|
565
FAQ
565
FAQ
@@ -1,20 +1,23 @@
|
||||
OpenSSL - Frequently Asked Questions
|
||||
--------------------------------------
|
||||
|
||||
[MISC] Miscellaneous questions
|
||||
|
||||
* Which is the current version of OpenSSL?
|
||||
* Where is the documentation?
|
||||
* How can I contact the OpenSSL developers?
|
||||
* Do I need patent licenses to use OpenSSL?
|
||||
* Is OpenSSL thread-safe?
|
||||
* Why do I get a "PRNG not seeded" error message?
|
||||
* Why does the linker complain about undefined symbols?
|
||||
* Where can I get a compiled version of OpenSSL?
|
||||
* I've compiled a program under Windows and it crashes: why?
|
||||
* How do I read or write a DER encoded buffer using the ASN1 functions?
|
||||
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
||||
* I've called <some function> and it fails, why?
|
||||
* I just get a load of numbers for the error output, what do they mean?
|
||||
* Why do I get errors about unknown algorithms?
|
||||
* Why aren't tools like 'autoconf' and 'libtool' used?
|
||||
|
||||
[LEGAL] Legal questions
|
||||
|
||||
* Do I need patent licenses to use OpenSSL?
|
||||
* Can I use OpenSSL with GPL software?
|
||||
|
||||
[USER] Questions on using the OpenSSL applications
|
||||
|
||||
* Why do I get a "PRNG not seeded" error message?
|
||||
* Why do I get an "unable to write 'random state'" error message?
|
||||
* How do I create certificates or certificate requests?
|
||||
* Why can't I create certificate requests?
|
||||
* Why does <SSL program> fail with a certificate verify error?
|
||||
@@ -22,17 +25,39 @@ OpenSSL - Frequently Asked Questions
|
||||
* How can I create DSA certificates?
|
||||
* Why can't I make an SSL connection using a DSA certificate?
|
||||
* How can I remove the passphrase on a private key?
|
||||
* Why can't the OpenSSH configure script detect OpenSSL?
|
||||
* Why can't I use OpenSSL certificates with SSL client authentication?
|
||||
* Why does my browser give a warning about a mismatched hostname?
|
||||
|
||||
[BUILD] Questions about building and testing OpenSSL
|
||||
|
||||
* Why does the linker complain about undefined symbols?
|
||||
* Why does the OpenSSL test fail with "bc: command not found"?
|
||||
* Why does the OpenSSL test fail with "bc: 1 no implemented"?
|
||||
* Why does the OpenSSL compilation fail on Alpha True64 Unix?
|
||||
* Why does the OpenSSL compilation fail with "ar: command not found"?
|
||||
* Why does the OpenSSL compilation fail on Win32 with VC++?
|
||||
|
||||
[PROG] Questions about programming with OpenSSL
|
||||
|
||||
* Is OpenSSL thread-safe?
|
||||
* I've compiled a program under Windows and it crashes: why?
|
||||
* How do I read or write a DER encoded buffer using the ASN1 functions?
|
||||
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
||||
* I've called <some function> and it fails, why?
|
||||
* I just get a load of numbers for the error output, what do they mean?
|
||||
* Why do I get errors about unknown algorithms?
|
||||
* Why can't the OpenSSH configure script detect OpenSSL?
|
||||
* Can I use OpenSSL's SSL library with non-blocking I/O?
|
||||
* Why doesn't my server application receive a client certificate?
|
||||
|
||||
===============================================================================
|
||||
|
||||
[MISC] ========================================================================
|
||||
|
||||
* Which is the current version of OpenSSL?
|
||||
|
||||
The current version is available from <URL: http://www.openssl.org>.
|
||||
OpenSSL 0.9.5a was released on April 1st, 2000.
|
||||
OpenSSL 0.9.6b was released on July 9th, 2001.
|
||||
|
||||
In addition to the current stable release, you can also access daily
|
||||
snapshots of the OpenSSL development version at <URL:
|
||||
@@ -78,90 +103,6 @@ OpenSSL. Information on the OpenSSL mailing lists is available from
|
||||
<URL: http://www.openssl.org>.
|
||||
|
||||
|
||||
* Do I need patent licenses to use OpenSSL?
|
||||
|
||||
The patents section of the README file lists patents that may apply to
|
||||
you if you want to use OpenSSL. For information on intellectual
|
||||
property rights, please consult a lawyer. The OpenSSL team does not
|
||||
offer legal advice.
|
||||
|
||||
You can configure OpenSSL so as not to use RC5 and IDEA by using
|
||||
./config no-rc5 no-idea
|
||||
|
||||
|
||||
* Is OpenSSL thread-safe?
|
||||
|
||||
Yes (with limitations: an SSL connection may not concurrently be used
|
||||
by multiple threads). On Windows and many Unix systems, OpenSSL
|
||||
automatically uses the multi-threaded versions of the standard
|
||||
libraries. If your platform is not one of these, consult the INSTALL
|
||||
file.
|
||||
|
||||
Multi-threaded applications must provide two callback functions to
|
||||
OpenSSL. This is described in the threads(3) manpage.
|
||||
|
||||
|
||||
* Why do I get a "PRNG not seeded" error message?
|
||||
|
||||
Cryptographic software needs a source of unpredictable data to work
|
||||
correctly. Many open source operating systems provide a "randomness
|
||||
device" that serves this purpose. On other systems, applications have
|
||||
to call the RAND_add() or RAND_seed() function with appropriate data
|
||||
before generating keys or performing public key encryption.
|
||||
|
||||
Some broken applications do not do this. As of version 0.9.5, the
|
||||
OpenSSL functions that need randomness report an error if the random
|
||||
number generator has not been seeded with at least 128 bits of
|
||||
randomness. If this error occurs, please contact the author of the
|
||||
application you are using. It is likely that it never worked
|
||||
correctly. OpenSSL 0.9.5 and later make the error visible by refusing
|
||||
to perform potentially insecure encryption.
|
||||
|
||||
On systems without /dev/urandom, it is a good idea to use the Entropy
|
||||
Gathering Demon; see the RAND_egd() manpage for details.
|
||||
|
||||
Most components of the openssl command line tool try to use the
|
||||
file $HOME/.rnd (or $RANDFILE, if this environment variable is set)
|
||||
for seeding the PRNG. If this file does not exist or is too short,
|
||||
the "PRNG not seeded" error message may occur.
|
||||
|
||||
[Note to OpenSSL 0.9.5 users: The command "openssl rsa" in version
|
||||
0.9.5 does not do this and will fail on systems without /dev/urandom
|
||||
when trying to password-encrypt an RSA key! This is a bug in the
|
||||
library; try a later version instead.]
|
||||
|
||||
For Solaris 2.6, Tim Nibbe <tnibbe@sprint.net> and others have suggested
|
||||
installing the SUNski package from Sun patch 105710-01 (Sparc) which
|
||||
adds a /dev/random device and make sure it gets used, usually through
|
||||
$RANDFILE. There are probably similar patches for the other Solaris
|
||||
versions. However, be warned that /dev/random is usually a blocking
|
||||
device, which may have som effects on OpenSSL.
|
||||
|
||||
|
||||
* Why does the linker complain about undefined symbols?
|
||||
|
||||
Maybe the compilation was interrupted, and make doesn't notice that
|
||||
something is missing. Run "make clean; make".
|
||||
|
||||
If you used ./Configure instead of ./config, make sure that you
|
||||
selected the right target. File formats may differ slightly between
|
||||
OS versions (for example sparcv8/sparcv9, or a.out/elf).
|
||||
|
||||
In case you get errors about the following symbols, use the config
|
||||
option "no-asm", as described in INSTALL:
|
||||
|
||||
BF_cbc_encrypt, BF_decrypt, BF_encrypt, CAST_cbc_encrypt,
|
||||
CAST_decrypt, CAST_encrypt, RC4, RC5_32_cbc_encrypt, RC5_32_decrypt,
|
||||
RC5_32_encrypt, bn_add_words, bn_div_words, bn_mul_add_words,
|
||||
bn_mul_comba4, bn_mul_comba8, bn_mul_words, bn_sqr_comba4,
|
||||
bn_sqr_comba8, bn_sqr_words, bn_sub_words, des_decrypt3,
|
||||
des_ede3_cbc_encrypt, des_encrypt, des_encrypt2, des_encrypt3,
|
||||
des_ncbc_encrypt, md5_block_asm_host_order, sha1_block_asm_data_order
|
||||
|
||||
If none of these helps, you may want to try using the current snapshot.
|
||||
If the problem persists, please submit a bug report.
|
||||
|
||||
|
||||
* Where can I get a compiled version of OpenSSL?
|
||||
|
||||
Some applications that use OpenSSL are distributed in binary form.
|
||||
@@ -175,88 +116,111 @@ on how to obtain and install the free GNU C compiler.
|
||||
A number of Linux and *BSD distributions include OpenSSL.
|
||||
|
||||
|
||||
* I've compiled a program under Windows and it crashes: why?
|
||||
* Why aren't tools like 'autoconf' and 'libtool' used?
|
||||
|
||||
This is usually because you've missed the comment in INSTALL.W32. You
|
||||
must link with the multithreaded DLL version of the VC++ runtime library
|
||||
otherwise the conflict will cause a program to crash: typically on the
|
||||
first BIO related read or write operation.
|
||||
autoconf will probably be used in future OpenSSL versions. If it was
|
||||
less Unix-centric, it might have been used much earlier.
|
||||
|
||||
|
||||
* How do I read or write a DER encoded buffer using the ASN1 functions?
|
||||
[LEGAL] =======================================================================
|
||||
|
||||
You have two options. You can either use a memory BIO in conjunction
|
||||
with the i2d_XXX_bio() or d2i_XXX_bio() functions or you can use the
|
||||
i2d_XXX(), d2i_XXX() functions directly. Since these are often the
|
||||
cause of grief here are some code fragments using PKCS7 as an example:
|
||||
* Do I need patent licenses to use OpenSSL?
|
||||
|
||||
unsigned char *buf, *p;
|
||||
int len;
|
||||
The patents section of the README file lists patents that may apply to
|
||||
you if you want to use OpenSSL. For information on intellectual
|
||||
property rights, please consult a lawyer. The OpenSSL team does not
|
||||
offer legal advice.
|
||||
|
||||
len = i2d_PKCS7(p7, NULL);
|
||||
buf = OPENSSL_Malloc(len); /* or Malloc, error checking omitted */
|
||||
p = buf;
|
||||
i2d_PKCS7(p7, &p);
|
||||
|
||||
At this point buf contains the len bytes of the DER encoding of
|
||||
p7.
|
||||
|
||||
The opposite assumes we already have len bytes in buf:
|
||||
|
||||
unsigned char *p;
|
||||
p = buf;
|
||||
p7 = d2i_PKCS7(NULL, &p, len);
|
||||
|
||||
At this point p7 contains a valid PKCS7 structure of NULL if an error
|
||||
occurred. If an error occurred ERR_print_errors(bio) should give more
|
||||
information.
|
||||
|
||||
The reason for the temporary variable 'p' is that the ASN1 functions
|
||||
increment the passed pointer so it is ready to read or write the next
|
||||
structure. This is often a cause of problems: without the temporary
|
||||
variable the buffer pointer is changed to point just after the data
|
||||
that has been read or written. This may well be uninitialized data
|
||||
and attempts to free the buffer will have unpredictable results
|
||||
because it no longer points to the same address.
|
||||
You can configure OpenSSL so as not to use RC5 and IDEA by using
|
||||
./config no-rc5 no-idea
|
||||
|
||||
|
||||
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
||||
* Can I use OpenSSL with GPL software?
|
||||
|
||||
This usually happens when you try compiling something using the PKCS#12
|
||||
macros with a C++ compiler. There is hardly ever any need to use the
|
||||
PKCS#12 macros in a program, it is much easier to parse and create
|
||||
PKCS#12 files using the PKCS12_parse() and PKCS12_create() functions
|
||||
documented in doc/openssl.txt and with examples in demos/pkcs12. The
|
||||
'pkcs12' application has to use the macros because it prints out
|
||||
debugging information.
|
||||
On many systems including the major Linux and BSD distributions, yes (the
|
||||
GPL does not place restrictions on using libraries that are part of the
|
||||
normal operating system distribution).
|
||||
|
||||
On other systems, the situation is less clear. Some GPL software copyright
|
||||
holders claim that you infringe on their rights if you use OpenSSL with
|
||||
their software on operating systems that don't normally include OpenSSL.
|
||||
|
||||
If you develop open source software that uses OpenSSL, you may find it
|
||||
useful to choose an other license than the GPL, or state explicitely that
|
||||
"This program is released under the GPL with the additional exemption that
|
||||
compiling, linking, and/or using OpenSSL is allowed." If you are using
|
||||
GPL software developed by others, you may want to ask the copyright holder
|
||||
for permission to use their software with OpenSSL.
|
||||
|
||||
|
||||
* I've called <some function> and it fails, why?
|
||||
[USER] ========================================================================
|
||||
|
||||
Before submitting a report or asking in one of the mailing lists, you
|
||||
should try to determine the cause. In particular, you should call
|
||||
ERR_print_errors() or ERR_print_errors_fp() after the failed call
|
||||
and see if the message helps. Note that the problem may occur earlier
|
||||
than you think -- you should check for errors after every call where
|
||||
it is possible, otherwise the actual problem may be hidden because
|
||||
some OpenSSL functions clear the error state.
|
||||
* Why do I get a "PRNG not seeded" error message?
|
||||
|
||||
Cryptographic software needs a source of unpredictable data to work
|
||||
correctly. Many open source operating systems provide a "randomness
|
||||
device" that serves this purpose. On other systems, applications have
|
||||
to call the RAND_add() or RAND_seed() function with appropriate data
|
||||
before generating keys or performing public key encryption.
|
||||
(These functions initialize the pseudo-random number generator, PRNG.)
|
||||
|
||||
Some broken applications do not do this. As of version 0.9.5, the
|
||||
OpenSSL functions that need randomness report an error if the random
|
||||
number generator has not been seeded with at least 128 bits of
|
||||
randomness. If this error occurs, please contact the author of the
|
||||
application you are using. It is likely that it never worked
|
||||
correctly. OpenSSL 0.9.5 and later make the error visible by refusing
|
||||
to perform potentially insecure encryption.
|
||||
|
||||
On systems without /dev/urandom and /dev/random, it is a good idea to
|
||||
use the Entropy Gathering Demon (EGD); see the RAND_egd() manpage for
|
||||
details. Starting with version 0.9.7, OpenSSL will automatically look
|
||||
for an EGD socket at /var/run/egd-pool, /dev/egd-pool, /etc/egd-pool and
|
||||
/etc/entropy.
|
||||
|
||||
Most components of the openssl command line utility automatically try
|
||||
to seed the random number generator from a file. The name of the
|
||||
default seeding file is determined as follows: If environment variable
|
||||
RANDFILE is set, then it names the seeding file. Otherwise if
|
||||
environment variable HOME is set, then the seeding file is $HOME/.rnd.
|
||||
If neither RANDFILE nor HOME is set, versions up to OpenSSL 0.9.6 will
|
||||
use file .rnd in the current directory while OpenSSL 0.9.6a uses no
|
||||
default seeding file at all. OpenSSL 0.9.6b and later will behave
|
||||
similarly to 0.9.6a, but will use a default of "C:" for HOME on
|
||||
Windows systems if the environment variable has not been set.
|
||||
|
||||
If the default seeding file does not exist or is too short, the "PRNG
|
||||
not seeded" error message may occur.
|
||||
|
||||
The openssl command line utility will write back a new state to the
|
||||
default seeding file (and create this file if necessary) unless
|
||||
there was no sufficient seeding.
|
||||
|
||||
Pointing $RANDFILE to an Entropy Gathering Daemon socket does not work.
|
||||
Use the "-rand" option of the OpenSSL command line tools instead.
|
||||
The $RANDFILE environment variable and $HOME/.rnd are only used by the
|
||||
OpenSSL command line tools. Applications using the OpenSSL library
|
||||
provide their own configuration options to specify the entropy source,
|
||||
please check out the documentation coming the with application.
|
||||
|
||||
For Solaris 2.6, Tim Nibbe <tnibbe@sprint.net> and others have suggested
|
||||
installing the SUNski package from Sun patch 105710-01 (Sparc) which
|
||||
adds a /dev/random device and make sure it gets used, usually through
|
||||
$RANDFILE. There are probably similar patches for the other Solaris
|
||||
versions. However, be warned that /dev/random is usually a blocking
|
||||
device, which may have some effects on OpenSSL.
|
||||
|
||||
|
||||
* I just get a load of numbers for the error output, what do they mean?
|
||||
|
||||
The actual format is described in the ERR_print_errors() manual page.
|
||||
You should call the function ERR_load_crypto_strings() before hand and
|
||||
the message will be output in text form. If you can't do this (for example
|
||||
it is a pre-compiled binary) you can use the errstr utility on the error
|
||||
code itself (the hex digits after the second colon).
|
||||
* Why do I get an "unable to write 'random state'" error message?
|
||||
|
||||
|
||||
* Why do I get errors about unknown algorithms?
|
||||
|
||||
This can happen under several circumstances such as reading in an
|
||||
encrypted private key or attempting to decrypt a PKCS#12 file. The cause
|
||||
is forgetting to load OpenSSL's table of algorithms with
|
||||
OpenSSL_add_all_algorithms(). See the manual page for more information.
|
||||
Sometimes the openssl command line utility does not abort with
|
||||
a "PRNG not seeded" error message, but complains that it is
|
||||
"unable to write 'random state'". This message refers to the
|
||||
default seeding file (see previous answer). A possible reason
|
||||
is that no default filename is known because neither RANDFILE
|
||||
nor HOME is set. (Versions up to 0.9.6 used file ".rnd" in the
|
||||
current directory in this case, but this has changed with 0.9.6a.)
|
||||
|
||||
|
||||
* How do I create certificates or certificate requests?
|
||||
@@ -321,45 +285,61 @@ you do have to do this check the EXAMPLES sections of the rsa(1) and
|
||||
dsa(1) manual pages.
|
||||
|
||||
|
||||
* Why can't the OpenSSH configure script detect OpenSSL?
|
||||
* Why can't I use OpenSSL certificates with SSL client authentication?
|
||||
|
||||
There is a problem with OpenSSH 1.2.2p1, in that the configure script
|
||||
can't find the installed OpenSSL libraries. The problem is actually
|
||||
a small glitch that is easily solved with the following patch to be
|
||||
applied to the OpenSSH distribution:
|
||||
What will typically happen is that when a server requests authentication
|
||||
it will either not include your certificate or tell you that you have
|
||||
no client certificates (Netscape) or present you with an empty list box
|
||||
(MSIE). The reason for this is that when a server requests a client
|
||||
certificate it includes a list of CAs names which it will accept. Browsers
|
||||
will only let you select certificates from the list on the grounds that
|
||||
there is little point presenting a certificate which the server will
|
||||
reject.
|
||||
|
||||
----- snip:start -----
|
||||
--- openssh-1.2.2p1/configure.in.orig Thu Mar 23 18:56:58 2000
|
||||
+++ openssh-1.2.2p1/configure.in Thu Mar 23 18:55:05 2000
|
||||
@@ -152,10 +152,10 @@
|
||||
AC_MSG_CHECKING([for OpenSSL/SSLeay directory])
|
||||
for ssldir in "" $tryssldir /usr /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do
|
||||
if test ! -z "$ssldir" ; then
|
||||
- LIBS="$saved_LIBS -L$ssldir"
|
||||
+ LIBS="$saved_LIBS -L$ssldir/lib"
|
||||
CFLAGS="$CFLAGS -I$ssldir/include"
|
||||
if test "x$need_dash_r" = "x1" ; then
|
||||
- LIBS="$LIBS -R$ssldir"
|
||||
+ LIBS="$LIBS -R$ssldir/lib"
|
||||
fi
|
||||
fi
|
||||
LIBS="$LIBS -lcrypto"
|
||||
--- openssh-1.2.2p1/configure.orig Thu Mar 23 18:55:02 2000
|
||||
+++ openssh-1.2.2p1/configure Thu Mar 23 18:57:08 2000
|
||||
@@ -1890,10 +1890,10 @@
|
||||
echo "configure:1891: checking for OpenSSL/SSLeay directory" >&5
|
||||
for ssldir in "" $tryssldir /usr /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do
|
||||
if test ! -z "$ssldir" ; then
|
||||
- LIBS="$saved_LIBS -L$ssldir"
|
||||
+ LIBS="$saved_LIBS -L$ssldir/lib"
|
||||
CFLAGS="$CFLAGS -I$ssldir/include"
|
||||
if test "x$need_dash_r" = "x1" ; then
|
||||
- LIBS="$LIBS -R$ssldir"
|
||||
+ LIBS="$LIBS -R$ssldir/lib"
|
||||
fi
|
||||
fi
|
||||
LIBS="$LIBS -lcrypto"
|
||||
----- snip:end -----
|
||||
The solution is to add the relevant CA certificate to your servers "trusted
|
||||
CA list". How you do this depends on the server sofware in uses. You can
|
||||
print out the servers list of acceptable CAs using the OpenSSL s_client tool:
|
||||
|
||||
openssl s_client -connect www.some.host:443 -prexit
|
||||
|
||||
If your server only requests certificates on certain URLs then you may need
|
||||
to manually issue an HTTP GET command to get the list when s_client connects:
|
||||
|
||||
GET /some/page/needing/a/certificate.html
|
||||
|
||||
If your CA does not appear in the list then this confirms the problem.
|
||||
|
||||
|
||||
* Why does my browser give a warning about a mismatched hostname?
|
||||
|
||||
Browsers expect the server's hostname to match the value in the commonName
|
||||
(CN) field of the certificate. If it does not then you get a warning.
|
||||
|
||||
|
||||
[BUILD] =======================================================================
|
||||
|
||||
* Why does the linker complain about undefined symbols?
|
||||
|
||||
Maybe the compilation was interrupted, and make doesn't notice that
|
||||
something is missing. Run "make clean; make".
|
||||
|
||||
If you used ./Configure instead of ./config, make sure that you
|
||||
selected the right target. File formats may differ slightly between
|
||||
OS versions (for example sparcv8/sparcv9, or a.out/elf).
|
||||
|
||||
In case you get errors about the following symbols, use the config
|
||||
option "no-asm", as described in INSTALL:
|
||||
|
||||
BF_cbc_encrypt, BF_decrypt, BF_encrypt, CAST_cbc_encrypt,
|
||||
CAST_decrypt, CAST_encrypt, RC4, RC5_32_cbc_encrypt, RC5_32_decrypt,
|
||||
RC5_32_encrypt, bn_add_words, bn_div_words, bn_mul_add_words,
|
||||
bn_mul_comba4, bn_mul_comba8, bn_mul_words, bn_sqr_comba4,
|
||||
bn_sqr_comba8, bn_sqr_words, bn_sub_words, des_decrypt3,
|
||||
des_ede3_cbc_encrypt, des_encrypt, des_encrypt2, des_encrypt3,
|
||||
des_ncbc_encrypt, md5_block_asm_host_order, sha1_block_asm_data_order
|
||||
|
||||
If none of these helps, you may want to try using the current snapshot.
|
||||
If the problem persists, please submit a bug report.
|
||||
|
||||
|
||||
* Why does the OpenSSL test fail with "bc: command not found"?
|
||||
@@ -370,12 +350,13 @@ tests, get GNU bc from ftp://ftp.gnu.org or from your OS distributor.
|
||||
|
||||
* Why does the OpenSSL test fail with "bc: 1 no implemented"?
|
||||
|
||||
On some SCO installations or versions, bc has a bug that gets triggered when
|
||||
you run the test suite (using "make test"). The message returned is "bc:
|
||||
1 not implemented". The best way to deal with this is to find another
|
||||
implementation of bc and compile/install it. For example, GNU bc (see
|
||||
http://www.gnu.org/software/software.html for download instructions) can
|
||||
be safely used.
|
||||
On some SCO installations or versions, bc has a bug that gets triggered
|
||||
when you run the test suite (using "make test"). The message returned is
|
||||
"bc: 1 not implemented".
|
||||
|
||||
The best way to deal with this is to find another implementation of bc
|
||||
and compile/install it. GNU bc (see http://www.gnu.org/software/software.html
|
||||
for download instructions) can be safely used, for example.
|
||||
|
||||
|
||||
* Why does the OpenSSL compilation fail on Alpha True64 Unix?
|
||||
@@ -430,3 +411,177 @@ and then redo the compilation. What you should really do is make sure
|
||||
'/usr/ccs/bin' is permanently in your $PATH, for example through your
|
||||
'.profile' (again, assuming you use a sh-compatible shell).
|
||||
|
||||
|
||||
* Why does the OpenSSL compilation fail on Win32 with VC++?
|
||||
|
||||
Sometimes, you may get reports from VC++ command line (cl) that it
|
||||
can't find standard include files like stdio.h and other weirdnesses.
|
||||
One possible cause is that the environment isn't correctly set up.
|
||||
To solve that problem, one should run VCVARS32.BAT which is found in
|
||||
the 'bin' subdirectory of the VC++ installation directory (somewhere
|
||||
under 'Program Files'). This needs to be done prior to running NMAKE,
|
||||
and the changes are only valid for the current DOS session.
|
||||
|
||||
|
||||
[PROG] ========================================================================
|
||||
|
||||
* Is OpenSSL thread-safe?
|
||||
|
||||
Yes (with limitations: an SSL connection may not concurrently be used
|
||||
by multiple threads). On Windows and many Unix systems, OpenSSL
|
||||
automatically uses the multi-threaded versions of the standard
|
||||
libraries. If your platform is not one of these, consult the INSTALL
|
||||
file.
|
||||
|
||||
Multi-threaded applications must provide two callback functions to
|
||||
OpenSSL. This is described in the threads(3) manpage.
|
||||
|
||||
|
||||
* I've compiled a program under Windows and it crashes: why?
|
||||
|
||||
This is usually because you've missed the comment in INSTALL.W32. You
|
||||
must link with the multithreaded DLL version of the VC++ runtime library
|
||||
otherwise the conflict will cause a program to crash: typically on the
|
||||
first BIO related read or write operation.
|
||||
|
||||
|
||||
* How do I read or write a DER encoded buffer using the ASN1 functions?
|
||||
|
||||
You have two options. You can either use a memory BIO in conjunction
|
||||
with the i2d_XXX_bio() or d2i_XXX_bio() functions or you can use the
|
||||
i2d_XXX(), d2i_XXX() functions directly. Since these are often the
|
||||
cause of grief here are some code fragments using PKCS7 as an example:
|
||||
|
||||
unsigned char *buf, *p;
|
||||
int len;
|
||||
|
||||
len = i2d_PKCS7(p7, NULL);
|
||||
buf = OPENSSL_malloc(len); /* or Malloc, error checking omitted */
|
||||
p = buf;
|
||||
i2d_PKCS7(p7, &p);
|
||||
|
||||
At this point buf contains the len bytes of the DER encoding of
|
||||
p7.
|
||||
|
||||
The opposite assumes we already have len bytes in buf:
|
||||
|
||||
unsigned char *p;
|
||||
p = buf;
|
||||
p7 = d2i_PKCS7(NULL, &p, len);
|
||||
|
||||
At this point p7 contains a valid PKCS7 structure of NULL if an error
|
||||
occurred. If an error occurred ERR_print_errors(bio) should give more
|
||||
information.
|
||||
|
||||
The reason for the temporary variable 'p' is that the ASN1 functions
|
||||
increment the passed pointer so it is ready to read or write the next
|
||||
structure. This is often a cause of problems: without the temporary
|
||||
variable the buffer pointer is changed to point just after the data
|
||||
that has been read or written. This may well be uninitialized data
|
||||
and attempts to free the buffer will have unpredictable results
|
||||
because it no longer points to the same address.
|
||||
|
||||
|
||||
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
||||
|
||||
This usually happens when you try compiling something using the PKCS#12
|
||||
macros with a C++ compiler. There is hardly ever any need to use the
|
||||
PKCS#12 macros in a program, it is much easier to parse and create
|
||||
PKCS#12 files using the PKCS12_parse() and PKCS12_create() functions
|
||||
documented in doc/openssl.txt and with examples in demos/pkcs12. The
|
||||
'pkcs12' application has to use the macros because it prints out
|
||||
debugging information.
|
||||
|
||||
|
||||
* I've called <some function> and it fails, why?
|
||||
|
||||
Before submitting a report or asking in one of the mailing lists, you
|
||||
should try to determine the cause. In particular, you should call
|
||||
ERR_print_errors() or ERR_print_errors_fp() after the failed call
|
||||
and see if the message helps. Note that the problem may occur earlier
|
||||
than you think -- you should check for errors after every call where
|
||||
it is possible, otherwise the actual problem may be hidden because
|
||||
some OpenSSL functions clear the error state.
|
||||
|
||||
|
||||
* I just get a load of numbers for the error output, what do they mean?
|
||||
|
||||
The actual format is described in the ERR_print_errors() manual page.
|
||||
You should call the function ERR_load_crypto_strings() before hand and
|
||||
the message will be output in text form. If you can't do this (for example
|
||||
it is a pre-compiled binary) you can use the errstr utility on the error
|
||||
code itself (the hex digits after the second colon).
|
||||
|
||||
|
||||
* Why do I get errors about unknown algorithms?
|
||||
|
||||
This can happen under several circumstances such as reading in an
|
||||
encrypted private key or attempting to decrypt a PKCS#12 file. The cause
|
||||
is forgetting to load OpenSSL's table of algorithms with
|
||||
OpenSSL_add_all_algorithms(). See the manual page for more information.
|
||||
|
||||
|
||||
* Why can't the OpenSSH configure script detect OpenSSL?
|
||||
|
||||
There is a problem with OpenSSH 1.2.2p1, in that the configure script
|
||||
can't find the installed OpenSSL libraries. The problem is actually
|
||||
a small glitch that is easily solved with the following patch to be
|
||||
applied to the OpenSSH distribution:
|
||||
|
||||
----- snip:start -----
|
||||
--- openssh-1.2.2p1/configure.in.orig Thu Mar 23 18:56:58 2000
|
||||
+++ openssh-1.2.2p1/configure.in Thu Mar 23 18:55:05 2000
|
||||
@@ -152,10 +152,10 @@
|
||||
AC_MSG_CHECKING([for OpenSSL/SSLeay directory])
|
||||
for ssldir in "" $tryssldir /usr /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do
|
||||
if test ! -z "$ssldir" ; then
|
||||
- LIBS="$saved_LIBS -L$ssldir"
|
||||
+ LIBS="$saved_LIBS -L$ssldir/lib"
|
||||
CFLAGS="$CFLAGS -I$ssldir/include"
|
||||
if test "x$need_dash_r" = "x1" ; then
|
||||
- LIBS="$LIBS -R$ssldir"
|
||||
+ LIBS="$LIBS -R$ssldir/lib"
|
||||
fi
|
||||
fi
|
||||
LIBS="$LIBS -lcrypto"
|
||||
--- openssh-1.2.2p1/configure.orig Thu Mar 23 18:55:02 2000
|
||||
+++ openssh-1.2.2p1/configure Thu Mar 23 18:57:08 2000
|
||||
@@ -1890,10 +1890,10 @@
|
||||
echo "configure:1891: checking for OpenSSL/SSLeay directory" >&5
|
||||
for ssldir in "" $tryssldir /usr /usr/local/openssl /usr/lib/openssl /usr/local/ssl /usr/lib/ssl /usr/local /usr/pkg /opt /opt/openssl ; do
|
||||
if test ! -z "$ssldir" ; then
|
||||
- LIBS="$saved_LIBS -L$ssldir"
|
||||
+ LIBS="$saved_LIBS -L$ssldir/lib"
|
||||
CFLAGS="$CFLAGS -I$ssldir/include"
|
||||
if test "x$need_dash_r" = "x1" ; then
|
||||
- LIBS="$LIBS -R$ssldir"
|
||||
+ LIBS="$LIBS -R$ssldir/lib"
|
||||
fi
|
||||
fi
|
||||
LIBS="$LIBS -lcrypto"
|
||||
----- snip:end -----
|
||||
|
||||
|
||||
* Can I use OpenSSL's SSL library with non-blocking I/O?
|
||||
|
||||
Yes; make sure to read the SSL_get_error(3) manual page!
|
||||
|
||||
A pitfall to avoid: Don't assume that SSL_read() will just read from
|
||||
the underlying transport or that SSL_write() will just write to it --
|
||||
it is also possible that SSL_write() cannot do any useful work until
|
||||
there is data to read, or that SSL_read() cannot do anything until it
|
||||
is possible to send data. One reason for this is that the peer may
|
||||
request a new TLS/SSL handshake at any time during the protocol,
|
||||
requiring a bi-directional message exchange; both SSL_read() and
|
||||
SSL_write() will try to continue any pending handshake.
|
||||
|
||||
|
||||
* Why doesn't my server application receive a client certificate?
|
||||
|
||||
Due to the TLS protocol definition, a client will only send a certificate,
|
||||
if explicitely asked by the server. Use the SSL_VERIFY_PEER flag of the
|
||||
SSL_CTX_set_verify() function to enable the use of client certificates.
|
||||
|
||||
|
||||
===============================================================================
|
||||
|
||||
|
13
INSTALL
13
INSTALL
@@ -7,8 +7,11 @@
|
||||
|
||||
To install OpenSSL, you will need:
|
||||
|
||||
* make
|
||||
* Perl 5
|
||||
* an ANSI C compiler
|
||||
* a development environment in form of development libraries and C
|
||||
header files
|
||||
* a supported Unix operating system
|
||||
|
||||
Quick Start
|
||||
@@ -43,9 +46,6 @@
|
||||
--openssldir=DIR Directory for OpenSSL files. If no prefix is specified,
|
||||
the library files and binaries are also installed there.
|
||||
|
||||
rsaref Build with RSADSI's RSAREF toolkit (this assumes that
|
||||
librsaref.a is in the library search path).
|
||||
|
||||
no-threads Don't try to build with support for multi-threaded
|
||||
applications.
|
||||
|
||||
@@ -57,7 +57,10 @@
|
||||
|
||||
shared In addition to the usual static libraries, create shared
|
||||
libraries on platforms where it's supported. See "Note on
|
||||
shared libraries" below.
|
||||
shared libraries" below. THIS IS NOT RECOMMENDED! Since
|
||||
this is a development branch, the positions of the ENGINE
|
||||
symbols in the transfer vector are constantly moving, so
|
||||
binary backward compatibility can't be guaranteed in any way.
|
||||
|
||||
no-asm Do not use assembler code.
|
||||
|
||||
@@ -125,7 +128,7 @@
|
||||
directory, and the binary will be in the "apps" directory.
|
||||
|
||||
If "make" fails, look at the output. There may be reasons for
|
||||
the failure that isn't a problem in OpenSSL itself (like missing
|
||||
the failure that aren't problems in OpenSSL itself (like missing
|
||||
standard headers). If it is a problem with OpenSSL itself, please
|
||||
report the problem to <openssl-bugs@openssl.org> (note that your
|
||||
message will be forwarded to a public mailing list). Include the
|
||||
|
29
INSTALL.VMS
29
INSTALL.VMS
@@ -8,6 +8,7 @@ Intro:
|
||||
|
||||
This file is divided in the following parts:
|
||||
|
||||
Requirements - Mandatory reading.
|
||||
Checking the distribution - Mandatory reading.
|
||||
Compilation - Mandatory reading.
|
||||
Logical names - Mandatory reading.
|
||||
@@ -19,6 +20,15 @@ This file is divided in the following parts:
|
||||
TODO - Things that are to come.
|
||||
|
||||
|
||||
Requirements:
|
||||
=============
|
||||
|
||||
To build and install OpenSSL, you will need:
|
||||
|
||||
* DEC C or some other ANSI C compiler. VAX C is *not* supported.
|
||||
[Note: OpenSSL has only been tested with DEC C. Compiling with
|
||||
a different ANSI C compiler may require some work]
|
||||
|
||||
Checking the distribution:
|
||||
==========================
|
||||
|
||||
@@ -82,12 +92,17 @@ directory. The syntax is trhe following:
|
||||
RSAREF compile using the RSAREF Library
|
||||
NORSAREF compile without using RSAREF
|
||||
|
||||
Note 1: The RSAREF libraries are NOT INCLUDED and you have to
|
||||
download it from "ftp://ftp.rsa.com/rsaref". You have to
|
||||
get the ".tar-Z" file as the ".zip" file doesn't have the
|
||||
directory structure stored. You have to extract the file
|
||||
into the [.RSAREF] directory as that is where the scripts
|
||||
will look for the files.
|
||||
Note 0: The RASREF library IS NO LONGER NEEDED. The RSA patent
|
||||
expires September 20, 2000, and RSA Security chose to make
|
||||
the algorithm public domain two weeks before that.
|
||||
|
||||
Note 1: If you still want to use RSAREF, the library is NOT INCLUDED
|
||||
and you have to download it. RSA Security doesn't carry it
|
||||
any more, but there are a number of places where you can find
|
||||
it. You have to get the ".tar-Z" file as the ".zip" file
|
||||
doesn't have the directory structure stored. You have to
|
||||
extract the file into the [.RSAREF] directory as that is where
|
||||
the scripts will look for the files.
|
||||
|
||||
Note 2: I have never done this, so I've no idea if it works or not.
|
||||
|
||||
@@ -129,7 +144,7 @@ Currently, the logical names supported are:
|
||||
used. This is good to try if something doesn't work.
|
||||
OPENSSL_NO_'alg' with value YES, the corresponding crypto algorithm
|
||||
will not be implemented. Supported algorithms to
|
||||
do this with are: RSA, DSA, DH, MD2, MD5, RIPEMD,
|
||||
do this with are: RSA, DSA, DH, MD2, MD4, MD5, RIPEMD,
|
||||
SHA, DES, MDC2, CR2, RC4, RC5, IDEA, BF, CAST, HMAC,
|
||||
SSL2. So, for example, having the logical name
|
||||
OPENSSL_NO_RSA with the value YES means that the
|
||||
|
@@ -108,8 +108,8 @@
|
||||
|
||||
* Compiler installation:
|
||||
|
||||
Mingw32 is available from <ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/
|
||||
mingw32/egcs-1.1.2/egcs-1.1.2-mingw32.zip>. GNU make is at
|
||||
Mingw32 is available from <ftp://ftp.xraylith.wisc.edu/pub/khan/
|
||||
gnu-win32/mingw32/gcc-2.95.2/gcc-2.95.2-msvcrt.exe>. GNU make is at
|
||||
<ftp://agnes.dida.physik.uni-essen.de/home/janjaap/mingw32/binaries/
|
||||
make-3.76.1.zip>. Install both of them in C:\egcs-1.1.2 and run
|
||||
C:\egcs-1.1.2\mingw32.bat to set the PATH.
|
||||
|
2
LICENSE
2
LICENSE
@@ -12,7 +12,7 @@
|
||||
---------------
|
||||
|
||||
/* ====================================================================
|
||||
* Copyright (c) 1998-2000 The OpenSSL Project. All rights reserved.
|
||||
* Copyright (c) 1998-2001 The OpenSSL Project. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
|
190
Makefile.org
190
Makefile.org
@@ -9,6 +9,7 @@ SHLIB_VERSION_NUMBER=
|
||||
SHLIB_VERSION_HISTORY=
|
||||
SHLIB_MAJOR=
|
||||
SHLIB_MINOR=
|
||||
SHLIB_EXT=
|
||||
PLATFORM=dist
|
||||
OPTIONS=
|
||||
CONFIGURE_ARGS=
|
||||
@@ -56,13 +57,14 @@ CC= gcc
|
||||
#CFLAG= -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall -Wuninitialized -DSHA1_ASM -DMD5_ASM -DRMD160_ASM
|
||||
CFLAG= -DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall -DSHA1_ASM -DMD5_ASM -DRMD160_ASM
|
||||
DEPFLAG=
|
||||
PEX_LIBS= -L. -L.. -L../.. -L../../..
|
||||
PEX_LIBS=
|
||||
EX_LIBS=
|
||||
EXE_EXT=
|
||||
AR=ar r
|
||||
RANLIB= ranlib
|
||||
PERL= perl
|
||||
TAR= tar
|
||||
TARFLAGS= --norecurse
|
||||
TARFLAGS= --no-recursion
|
||||
|
||||
# Set BN_ASM to bn_asm.o if you want to use the C version
|
||||
BN_ASM= bn_asm.o
|
||||
@@ -149,14 +151,11 @@ RMD160_ASM_OBJ= asm/rm86-out.o
|
||||
#RMD160_ASM_OBJ= asm/rm86-out.o # a.out, FreeBSD
|
||||
#RMD160_ASM_OBJ= asm/rm86bsdi.o # bsdi
|
||||
|
||||
# To do special treatment, use "directory names" starting with a period.
|
||||
# When we're prepared to use shared libraries in the programs we link here
|
||||
# we might have SHLIB_MARK1 get the value ".shlib." and SHLIB_MARK2 be empty,
|
||||
# or have that configurable.
|
||||
SHLIB_MARK1=.shlib-clean.
|
||||
SHLIB_MARK2=.shlib.
|
||||
# we might set SHLIB_MARK to '$(SHARED_LIBS)'.
|
||||
SHLIB_MARK=
|
||||
|
||||
DIRS= crypto ssl rsaref $(SHLIB_MARK1) apps test tools $(SHLIB_MARK2)
|
||||
DIRS= crypto ssl rsaref $(SHLIB_MARK) apps test tools
|
||||
SHLIBDIRS= crypto ssl
|
||||
|
||||
# dirs in crypto to build
|
||||
@@ -180,7 +179,10 @@ ONEDIRS=out tmp
|
||||
EDIRS= times doc bugs util include certs ms shlib mt demos perl sf dep VMS
|
||||
WDIRS= windows
|
||||
LIBS= libcrypto.a libssl.a
|
||||
SHARED_LIBS=libcrypto.so libssl.so
|
||||
SHARED_CRYPTO=libcrypto$(SHLIB_EXT)
|
||||
SHARED_SSL=libssl$(SHLIB_EXT)
|
||||
SHARED_LIBS=
|
||||
SHARED_LIBS_LINK_EXTS=
|
||||
|
||||
GENERAL= Makefile
|
||||
BASENAME= openssl
|
||||
@@ -190,108 +192,93 @@ WTARFILE= $(NAME)-win.tar
|
||||
EXHEADER= e_os.h e_os2.h
|
||||
HEADER= e_os.h
|
||||
|
||||
all: Makefile.ssl
|
||||
@need_shlib=true; \
|
||||
for i in $(DIRS) ;\
|
||||
do \
|
||||
if [ "$$i" = ".shlib-clean." ]; then \
|
||||
if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||
$(MAKE) clean-shared; \
|
||||
fi; \
|
||||
elif [ "$$i" = ".shlib." ]; then \
|
||||
if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||
$(MAKE) $(SHARED_LIBS); \
|
||||
fi; \
|
||||
need_shlib=false; \
|
||||
else \
|
||||
(cd $$i && echo "making all in $$i..." && \
|
||||
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' SDIRS='${SDIRS}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' all ) || exit 1; \
|
||||
fi; \
|
||||
done; \
|
||||
if $$need_shlib && [ "$(SHLIB_MARK1)" != "" -o "$(SHLIB_MARK1)" != "" ]; then \
|
||||
$(MAKE) $(SHARED_LIBS); \
|
||||
fi
|
||||
# When we're prepared to use shared libraries in the programs we link here
|
||||
# we might remove 'clean-shared' from the targets to perform at this stage
|
||||
|
||||
all: clean-shared Makefile.ssl sub_all
|
||||
|
||||
sub_all:
|
||||
@need_shlib=true; \
|
||||
for i in $(DIRS) ;\
|
||||
@for i in $(DIRS); \
|
||||
do \
|
||||
if [ "$$i" = ".shlib-clean." ]; then \
|
||||
if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||
$(MAKE) clean-shared; \
|
||||
fi; \
|
||||
elif [ "$$i" = ".shlib." ]; then \
|
||||
if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||
$(MAKE) $(SHARED_LIBS); \
|
||||
fi; \
|
||||
need_shlib=false; \
|
||||
else \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making all in $$i..." && \
|
||||
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' SDIRS='$(SDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' all ) || exit 1; \
|
||||
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' SDIRS='$(SDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' EXE_EXT='${EXE_EXT}' all ) || exit 1; \
|
||||
else \
|
||||
$(MAKE) $$i; \
|
||||
fi; \
|
||||
done; \
|
||||
if $$need_shlib && [ "$(SHLIB_MARK1)" != "" -o "$(SHLIB_MARK1)" != "" ]; then \
|
||||
if echo "$(DIRS)" | \
|
||||
egrep '(^| )(crypto|ssl)( |$$)' > /dev/null 2>&1 && \
|
||||
[ -n "$(SHARED_LIBS)" ]; then \
|
||||
$(MAKE) $(SHARED_LIBS); \
|
||||
fi
|
||||
|
||||
libcrypto.so: libcrypto.a
|
||||
libcrypto$(SHLIB_EXT): libcrypto.a
|
||||
@if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||
$(MAKE) SHLIBDIRS=crypto $(SHLIB_TARGET); \
|
||||
$(MAKE) SHLIBDIRS=crypto build-shared; \
|
||||
else \
|
||||
echo "There's no support for shared libraries on this platform" >&2; \
|
||||
fi
|
||||
libssl.so: libcrypto.so libssl.a
|
||||
libssl$(SHLIB_EXT): libcrypto$(SHLIB_EXT) libssl.a
|
||||
@if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||
$(MAKE) SHLIBDIRS=ssl SHLIBDEPS='-L. -lcrypto' $(SHLIB_TARGET); \
|
||||
$(MAKE) SHLIBDIRS=ssl SHLIBDEPS='-lcrypto' build-shared; \
|
||||
else \
|
||||
echo "There's no support for shared libraries on this platform" >&2; \
|
||||
fi
|
||||
|
||||
clean-shared:
|
||||
for i in ${SHLIBDIRS}; do \
|
||||
rm -f lib$$i.so \
|
||||
lib$$i.so.${SHLIB_MAJOR} \
|
||||
lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
||||
@for i in $(SHLIBDIRS); do \
|
||||
if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \
|
||||
tmp="$(SHARED_LIBS_LINK_EXTS)"; \
|
||||
for j in $${tmp:-x}; do \
|
||||
( set -x; rm -f lib$$i$$j ); \
|
||||
done; \
|
||||
fi; \
|
||||
( set -x; rm -f lib$$i$(SHLIB_EXT) ); \
|
||||
done
|
||||
|
||||
linux-shared:
|
||||
libs='${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \
|
||||
rm -f lib$$i.so \
|
||||
lib$$i.so.${SHLIB_MAJOR} \
|
||||
lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
||||
link-shared:
|
||||
@for i in $(SHLIBDIRS); do \
|
||||
prev=lib$$i$(SHLIB_EXT); \
|
||||
if [ -n "$(SHARED_LIBS_LINK_EXTS)" ]; then \
|
||||
tmp="$(SHARED_LIBS_LINK_EXTS)"; \
|
||||
for j in $${tmp:-x}; do \
|
||||
( set -x; ln -f -s $$prev lib$$i$$j ); \
|
||||
prev=lib$$i$$j; \
|
||||
done; \
|
||||
fi; \
|
||||
done
|
||||
|
||||
build-shared: clean-shared do_$(SHLIB_TARGET) link-shared
|
||||
|
||||
do_bsd-gcc-shared: do_gnu-shared
|
||||
do_linux-shared: do_gnu-shared
|
||||
do_gnu-shared:
|
||||
libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \
|
||||
( set -x; ${CC} -shared -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
-Wl,-S,-soname=lib$$i.so.${SHLIB_MAJOR} \
|
||||
-Wl,-S,-soname=lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
-Wl,--whole-archive lib$$i.a \
|
||||
-Wl,--no-whole-archive $$libs ${EX_LIBS} -lc ) || exit 1; \
|
||||
libs="$$libs -L. -l$$i"; \
|
||||
( set -x; \
|
||||
ln -s lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
lib$$i.so.${SHLIB_MAJOR}; \
|
||||
ln -s lib$$i.so.${SHLIB_MAJOR} lib$$i.so ); \
|
||||
libs="$$libs -l$$i"; \
|
||||
done
|
||||
|
||||
# This assumes that GNU utilities are *not* used
|
||||
true64-shared:
|
||||
libs='${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \
|
||||
do_tru64-shared:
|
||||
libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \
|
||||
( set -x; ${CC} -shared -no_archive -o lib$$i.so \
|
||||
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
||||
-all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \
|
||||
libs="$$libs -L. -l$$i"; \
|
||||
libs="$$libs -l$$i"; \
|
||||
done
|
||||
|
||||
# This assumes that GNU utilities are *not* used
|
||||
solaris-shared:
|
||||
libs='${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \
|
||||
rm -f lib$$i.so \
|
||||
lib$$i.so.${SHLIB_MAJOR} \
|
||||
lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
||||
( set -x; ${CC} -G -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
-h lib$$i.so.${SHLIB_MAJOR} \
|
||||
do_solaris-shared:
|
||||
libs='-L. ${SHLIBDEPS}'; for i in ${SHLIBDIRS}; do \
|
||||
( PATH=/usr/ccs/bin:$$PATH ; export PATH; \
|
||||
set -x; ${CC} -G -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
-z allextract lib$$i.a $$libs ${EX_LIBS} -lc ) || exit 1; \
|
||||
libs="$$libs -L. -l$$i"; \
|
||||
ln -s lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||
lib$$i.so.${SHLIB_MAJOR}; \
|
||||
ln -s lib$$i.so.${SHLIB_MAJOR} lib$$i.so; \
|
||||
libs="$$libs -l$$i"; \
|
||||
done
|
||||
|
||||
Makefile.ssl: Makefile.org
|
||||
@@ -306,7 +293,7 @@ clean:
|
||||
rm -f shlib/*.o *.o core a.out fluff *.map rehash.time testlog make.log cctest cctest.c
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making clean in $$i..." && \
|
||||
$(MAKE) SDIRS='${SDIRS}' clean ) || exit 1; \
|
||||
rm -f $(LIBS); \
|
||||
@@ -327,7 +314,7 @@ files:
|
||||
$(PERL) $(TOP)/util/files.pl Makefile.ssl > $(TOP)/MINFO
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making 'files' in $$i..." && \
|
||||
$(MAKE) SDIRS='${SDIRS}' PERL='${PERL}' files ) || exit 1; \
|
||||
fi; \
|
||||
@@ -338,7 +325,7 @@ links:
|
||||
@$(PERL) $(TOP)/util/mkdir-p.pl include/openssl
|
||||
@$(PERL) $(TOP)/util/mklink.pl include/openssl $(EXHEADER)
|
||||
@for i in $(DIRS); do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making links in $$i..." && \
|
||||
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' SDIRS='$(SDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PERL='${PERL}' links ) || exit 1; \
|
||||
fi; \
|
||||
@@ -348,7 +335,7 @@ dclean:
|
||||
rm -f *.bak
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making dclean in $$i..." && \
|
||||
$(MAKE) SDIRS='${SDIRS}' PERL='${PERL}' dclean ) || exit 1; \
|
||||
fi; \
|
||||
@@ -363,7 +350,7 @@ test: tests
|
||||
|
||||
tests: rehash
|
||||
@(cd test && echo "testing..." && \
|
||||
$(MAKE) CC='${CC}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SDIRS='${SDIRS}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' tests );
|
||||
$(MAKE) CC='${CC}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SDIRS='${SDIRS}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' EXE_EXT='${EXE_EXT}' tests );
|
||||
@apps/openssl version -a
|
||||
|
||||
report:
|
||||
@@ -372,7 +359,7 @@ report:
|
||||
depend:
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making dependencies $$i..." && \
|
||||
$(MAKE) SDIRS='${SDIRS}' DEPFLAG='${DEPFLAG}' depend ) || exit 1; \
|
||||
fi; \
|
||||
@@ -381,7 +368,7 @@ depend:
|
||||
lint:
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making lint $$i..." && \
|
||||
$(MAKE) SDIRS='${SDIRS}' lint ) || exit 1; \
|
||||
fi; \
|
||||
@@ -390,7 +377,7 @@ lint:
|
||||
tags:
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i && echo "making tags $$i..." && \
|
||||
$(MAKE) SDIRS='${SDIRS}' tags ) || exit 1; \
|
||||
fi; \
|
||||
@@ -452,9 +439,9 @@ install: all install_docs
|
||||
done;
|
||||
@for i in $(DIRS) ;\
|
||||
do \
|
||||
if echo "$$i" | grep -v '^\.'; then \
|
||||
if [ -d "$$i" ]; then \
|
||||
(cd $$i; echo "installing $$i..."; \
|
||||
$(MAKE) CC='${CC}' CFLAG='${CFLAG}' INSTALL_PREFIX='${INSTALL_PREFIX}' INSTALLTOP='${INSTALLTOP}' OPENSSLDIR='${OPENSSLDIR}' EX_LIBS='${EX_LIBS}' SDIRS='${SDIRS}' RANLIB='${RANLIB}' install ); \
|
||||
$(MAKE) CC='${CC}' CFLAG='${CFLAG}' INSTALL_PREFIX='${INSTALL_PREFIX}' INSTALLTOP='${INSTALLTOP}' OPENSSLDIR='${OPENSSLDIR}' EX_LIBS='${EX_LIBS}' SDIRS='${SDIRS}' RANLIB='${RANLIB}' EXE_EXT='${EXE_EXT}' install ); \
|
||||
fi; \
|
||||
done
|
||||
@for i in $(LIBS) ;\
|
||||
@@ -466,6 +453,20 @@ install: all install_docs
|
||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
|
||||
fi \
|
||||
done
|
||||
@if [ -n "$(SHARED_LIBS)" ]; then \
|
||||
tmp="$(SHARED_LIBS)"; \
|
||||
for i in $${tmp:-x}; \
|
||||
do \
|
||||
if [ -f "$$i" ]; then \
|
||||
( echo installing $$i; \
|
||||
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib; \
|
||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
|
||||
fi \
|
||||
done; \
|
||||
( here="`pwd`"; \
|
||||
cd $(INSTALL_PREFIX)$(INSTALLTOP)/lib; \
|
||||
make -f $$here/Makefile link-shared ); \
|
||||
fi
|
||||
|
||||
install_docs:
|
||||
@$(PERL) $(TOP)/util/mkdir-p.pl \
|
||||
@@ -473,30 +474,23 @@ install_docs:
|
||||
$(INSTALL_PREFIX)$(MANDIR)/man3 \
|
||||
$(INSTALL_PREFIX)$(MANDIR)/man5 \
|
||||
$(INSTALL_PREFIX)$(MANDIR)/man7
|
||||
@echo installing man 1 and man 5
|
||||
@for i in doc/apps/*.pod; do \
|
||||
fn=`basename $$i .pod`; \
|
||||
sec=`[ "$$fn" = "config" ] && echo 5 || echo 1`; \
|
||||
if [ "$$fn" = "config" ]; then sec=5; else sec=1; fi; \
|
||||
echo "installing man$$sec/`basename $$i .pod`.$$sec"; \
|
||||
(cd `dirname $$i`; \
|
||||
$(PERL) ../../util/pod2man.pl --section=$$sec --center=OpenSSL \
|
||||
--release=$(VERSION) `basename $$i`) \
|
||||
> $(INSTALL_PREFIX)$(MANDIR)/man$$sec/`basename $$i .pod`.$$sec; \
|
||||
done
|
||||
@echo installing man 3 and man 7
|
||||
@for i in doc/crypto/*.pod doc/ssl/*.pod; do \
|
||||
fn=`basename $$i .pod`; \
|
||||
sec=`[ "$$fn" = "des_modes" ] && echo 7 || echo 3`; \
|
||||
if [ "$$fn" = "des_modes" ]; then sec=7; else sec=3; fi; \
|
||||
echo "installing man$$sec/`basename $$i .pod`.$$sec"; \
|
||||
(cd `dirname $$i`; \
|
||||
$(PERL) ../../util/pod2man.pl --section=$$sec --center=OpenSSL \
|
||||
--release=$(VERSION) `basename $$i`) \
|
||||
> $(INSTALL_PREFIX)$(MANDIR)/man$$sec/`basename $$i .pod`.$$sec; \
|
||||
done
|
||||
|
||||
shlib: all
|
||||
if [ ! -d shlib_dir ] ; then mkdir shlib_dir ; else rm -f shlib_dir/* ; fi
|
||||
cd shlib_dir ; ar -x ../libcrypto.a && $(CC) -shared ./*.o -Wl,-soname -Wl,libcrypto.so.0.9 \
|
||||
-o ./libcrypto.so.0.9.4 && rm *.o
|
||||
cd shlib_dir ; ar -x ../libssl.a && $(CC) -shared ./*.o -Wl,-soname -Wl,libssl.so.0.9 \
|
||||
-o ./libssl.so.0.9.4 && rm *.o
|
||||
|
||||
# DO NOT DELETE THIS LINE -- make depend depends on it.
|
||||
|
57
NEWS
57
NEWS
@@ -5,6 +5,63 @@
|
||||
This file gives a brief overview of the major changes between each OpenSSL
|
||||
release. For more details please read the CHANGES file.
|
||||
|
||||
Changes between OpenSSL 0.9.6a and OpenSSL 0.9.6b:
|
||||
|
||||
o Security fix: PRNG improvements.
|
||||
o Security fix: RSA OAEP check.
|
||||
o Security fix: Reinsert and fix countermeasure to Bleichbacher's
|
||||
attack.
|
||||
o MIPS bug fix in BIGNUM.
|
||||
o Bug fix in "openssl enc".
|
||||
o Bug fix in X.509 printing routine.
|
||||
o Bug fix in DSA verification routine and DSA S/MIME verification.
|
||||
o Bug fix to make PRNG thread-safe.
|
||||
o Bug fix in RAND_file_name().
|
||||
o Bug fix in compatibility mode trust settings.
|
||||
o Bug fix in blowfish EVP.
|
||||
o Increase default size for BIO buffering filter.
|
||||
o Compatibility fixes in some scripts.
|
||||
|
||||
Major changes between OpenSSL 0.9.6 and OpenSSL 0.9.6a:
|
||||
|
||||
o Security fix: change behavior of OpenSSL to avoid using
|
||||
environment variables when running as root.
|
||||
o Security fix: check the result of RSA-CRT to reduce the
|
||||
possibility of deducing the private key from an incorrectly
|
||||
calculated signature.
|
||||
o Security fix: prevent Bleichenbacher's DSA attack.
|
||||
o Security fix: Zero the premaster secret after deriving the
|
||||
master secret in DH ciphersuites.
|
||||
o Reimplement SSL_peek(), which had various problems.
|
||||
o Compatibility fix: the function des_encrypt() renamed to
|
||||
des_encrypt1() to avoid clashes with some Unixen libc.
|
||||
o Bug fixes for Win32, HP/UX and Irix.
|
||||
o Bug fixes in BIGNUM, SSL, PKCS#7, PKCS#12, X.509, CONF and
|
||||
memory checking routines.
|
||||
o Bug fixes for RSA operations in threaded enviroments.
|
||||
o Bug fixes in misc. openssl applications.
|
||||
o Remove a few potential memory leaks.
|
||||
o Add tighter checks of BIGNUM routines.
|
||||
o Shared library support has been reworked for generality.
|
||||
o More documentation.
|
||||
o New function BN_rand_range().
|
||||
o Add "-rand" option to openssl s_client and s_server.
|
||||
|
||||
Major changes between OpenSSL 0.9.5a and OpenSSL 0.9.6:
|
||||
|
||||
o Some documentation for BIO and SSL libraries.
|
||||
o Enhanced chain verification using key identifiers.
|
||||
o New sign and verify options to 'dgst' application.
|
||||
o Support for DER and PEM encoded messages in 'smime' application.
|
||||
o New 'rsautl' application, low level RSA utility.
|
||||
o MD4 now included.
|
||||
o Bugfix for SSL rollback padding check.
|
||||
o Support for external crypto devices [1].
|
||||
o Enhanced EVP interface.
|
||||
|
||||
[1] The support for external crypto devices is currently a separate
|
||||
distribution. See the file README.ENGINE.
|
||||
|
||||
Major changes between OpenSSL 0.9.5 and OpenSSL 0.9.5a:
|
||||
|
||||
o Bug fixes for Win32, SuSE Linux, NeXTSTEP and FreeBSD 2.2.8
|
||||
|
7
README
7
README
@@ -1,7 +1,7 @@
|
||||
|
||||
OpenSSL 0.9.6-beta1 [engine] 11 Sep 2000
|
||||
OpenSSL 0.9.6b [engine] 9 Jul 2001
|
||||
|
||||
Copyright (c) 1998-2000 The OpenSSL Project
|
||||
Copyright (c) 1998-2001 The OpenSSL Project
|
||||
Copyright (c) 1995-1998 Eric A. Young, Tim J. Hudson
|
||||
All rights reserved.
|
||||
|
||||
@@ -163,6 +163,9 @@
|
||||
the string "[PATCH]" in the subject. Please be sure to include a
|
||||
textual explanation of what your patch does.
|
||||
|
||||
Note: For legal reasons, contributions from the US can be accepted only
|
||||
if a copy of the patch is sent to crypt@bxa.doc.gov
|
||||
|
||||
The preferred format for changes is "diff -u" output. You might
|
||||
generate it like this:
|
||||
|
||||
|
63
README.ENGINE
Normal file
63
README.ENGINE
Normal file
@@ -0,0 +1,63 @@
|
||||
|
||||
ENGINE
|
||||
======
|
||||
|
||||
With OpenSSL 0.9.6, a new component has been added to support external
|
||||
crypto devices, for example accelerator cards. The component is called
|
||||
ENGINE, and has still a pretty experimental status and almost no
|
||||
documentation. It's designed to be faily easily extensible by the
|
||||
calling programs.
|
||||
|
||||
There's currently built-in support for the following crypto devices:
|
||||
|
||||
o CryptoSwift
|
||||
o Compaq Atalla
|
||||
o nCipher CHIL
|
||||
|
||||
A number of things are still needed and are being worked on:
|
||||
|
||||
o An openssl utility command to handle or at least check available
|
||||
engines.
|
||||
o A better way of handling the methods that are handled by the
|
||||
engines.
|
||||
o Documentation!
|
||||
|
||||
What already exists is fairly stable as far as it has been tested, but
|
||||
the test base has been a bit small most of the time.
|
||||
|
||||
Because of this experimental status and what's lacking, the ENGINE
|
||||
component is not yet part of the default OpenSSL distribution. However,
|
||||
we have made a separate kit for those who want to try this out, to be
|
||||
found in the same places as the default OpenSSL distribution, but with
|
||||
"-engine-" being part of the kit file name. For example, version 0.9.6
|
||||
is distributed in the following two files:
|
||||
|
||||
openssl-0.9.6.tar.gz
|
||||
openssl-engine-0.9.6.tar.gz
|
||||
|
||||
NOTES
|
||||
=====
|
||||
|
||||
openssl-engine-0.9.6.tar.gz does not depend on openssl-0.9.6.tar, you do
|
||||
not need to download both.
|
||||
|
||||
openssl-engine-0.9.6.tar.gz is usable even if you don't have an external
|
||||
crypto device. The internal OpenSSL functions are contained in the
|
||||
engine "openssl", and will be used by default.
|
||||
|
||||
No external crypto device is chosen unless you say so. You have actively
|
||||
tell the openssl utility commands to use it through a new command line
|
||||
switch called "-engine". And if you want to use the ENGINE library to
|
||||
do something similar, you must also explicitely choose an external crypto
|
||||
device, or the built-in crypto routines will be used, just as in the
|
||||
default OpenSSL distribution.
|
||||
|
||||
|
||||
PROBLEMS
|
||||
========
|
||||
|
||||
It seems like the ENGINE part doesn't work too well with Cryptoswift on
|
||||
Win32. A quick test done right before the release showed that trying
|
||||
"openssl speed -engine cswift" generated errors. If the DSO gets enabled,
|
||||
an attempt is made to write at memory address 0x00000002.
|
||||
|
47
STATUS
47
STATUS
@@ -1,31 +1,30 @@
|
||||
|
||||
OpenSSL STATUS Last modified at
|
||||
______________ $Date: 2000/09/11 13:28:30 $
|
||||
______________ $Date: 2001/04/05 17:48:02 $
|
||||
|
||||
DEVELOPMENT STATE
|
||||
|
||||
o OpenSSL 0.9.6: Under development (in release cycle)...
|
||||
Proposed release date September 24, 2000
|
||||
o OpenSSL 0.9.5a: Released on April 1st, 2000
|
||||
o OpenSSL 0.9.5: Released on February 28th, 2000
|
||||
o OpenSSL 0.9.4: Released on August 09th, 1999
|
||||
o OpenSSL 0.9.3a: Released on May 29th, 1999
|
||||
o OpenSSL 0.9.3: Released on May 25th, 1999
|
||||
o OpenSSL 0.9.2b: Released on March 22th, 1999
|
||||
o OpenSSL 0.9.1c: Released on December 23th, 1998
|
||||
o OpenSSL 0.9.6a: Released on April 5th, 2001
|
||||
o OpenSSL 0.9.6: Released on September 24th, 2000
|
||||
o OpenSSL 0.9.5a: Released on April 1st, 2000
|
||||
o OpenSSL 0.9.5: Released on February 28th, 2000
|
||||
o OpenSSL 0.9.4: Released on August 09th, 1999
|
||||
o OpenSSL 0.9.3a: Released on May 29th, 1999
|
||||
o OpenSSL 0.9.3: Released on May 25th, 1999
|
||||
o OpenSSL 0.9.2b: Released on March 22th, 1999
|
||||
o OpenSSL 0.9.1c: Released on December 23th, 1998
|
||||
|
||||
RELEASE SHOWSTOPPERS
|
||||
|
||||
AVAILABLE PATCHES
|
||||
|
||||
o CA.pl patch (Damien Miller)
|
||||
|
||||
IN PROGRESS
|
||||
|
||||
o Steve is currently working on (in no particular order):
|
||||
ASN1 code redesign, butchery, replacement.
|
||||
OCSP
|
||||
EVP cipher enhancement.
|
||||
Proper (or at least usable) certificate chain verification.
|
||||
Enhanced certificate chain verification.
|
||||
Private key, certificate and CRL API and implementation.
|
||||
Developing and bugfixing PKCS#7 (S/MIME code).
|
||||
Various X509 issues: character sets, certificate request extensions.
|
||||
@@ -34,19 +33,29 @@
|
||||
o Richard is currently working on:
|
||||
UTIL (a new set of library functions to support some higher level
|
||||
functionality that is currently missing).
|
||||
Dynamic thread-lock support.
|
||||
Shared library support for VMS.
|
||||
OCSP
|
||||
Kerberos 5 authentication
|
||||
Constification
|
||||
|
||||
NEEDS PATCH
|
||||
|
||||
o non-blocking socket on AIX
|
||||
o $(PERL) in */Makefile.ssl
|
||||
o "Sign the certificate?" - "n" creates empty certificate file
|
||||
o apps/ca.c: "Sign the certificate?" - "n" creates empty certificate file
|
||||
|
||||
o OpenSSL_0_9_6-stable:
|
||||
#include <openssl/e_os.h> in exported header files is illegal since
|
||||
e_os.h is suitable only for library-internal use.
|
||||
|
||||
o Whenever strncpy is used, make sure the resulting string is NULL-terminated
|
||||
or an error is reported
|
||||
|
||||
OPEN ISSUES
|
||||
|
||||
o internal_verify doesn't know about X509.v3 (basicConstraints
|
||||
CA flag ...)
|
||||
o crypto/ex_data.c is not really thread-safe and so must be used
|
||||
with care (e.g., extra locking where necessary, or don't call
|
||||
CRYPTO_get_ex_new_index once multiple threads exist).
|
||||
The current API is not suitable for everything that it pretends
|
||||
to offer.
|
||||
|
||||
o The Makefile hierarchy and build mechanism is still not a round thing:
|
||||
|
||||
|
@@ -36,6 +36,7 @@
|
||||
# default openssl.cnf file has setup as per the following
|
||||
# demoCA ... where everything is stored
|
||||
|
||||
$SSLEAY_CONFIG=$ENV{"SSLEAY_CONFIG"};
|
||||
$DAYS="-days 365";
|
||||
$REQ="openssl req $SSLEAY_CONFIG";
|
||||
$CA="openssl ca $SSLEAY_CONFIG";
|
||||
|
@@ -18,6 +18,7 @@ RM= rm -f
|
||||
|
||||
PEX_LIBS=
|
||||
EX_LIBS=
|
||||
EXE_EXT=
|
||||
|
||||
CFLAGS= -DMONOLITH $(INCLUDES) $(CFLAG)
|
||||
|
||||
@@ -32,7 +33,7 @@ PROGRAM= openssl
|
||||
|
||||
SCRIPTS=CA.sh CA.pl der_chop
|
||||
|
||||
EXE= $(PROGRAM)
|
||||
EXE= $(PROGRAM)$(EXE_EXT)
|
||||
|
||||
E_EXE= verify asn1pars req dgst dh dhparam enc passwd gendh errstr \
|
||||
ca crl rsa rsautl dsa dsaparam \
|
||||
@@ -77,7 +78,7 @@ top:
|
||||
|
||||
all: exe
|
||||
|
||||
exe: $(EXE)
|
||||
exe: $(PROGRAM)
|
||||
|
||||
req: sreq.o $(A_OBJ) $(DLIBCRYPTO)
|
||||
$(CC) -o req $(CFLAG) sreq.o $(A_OBJ) $(RAND_OBJ) $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS)
|
||||
@@ -146,8 +147,9 @@ progs.h: progs.pl
|
||||
app_rand.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
app_rand.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
app_rand.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
app_rand.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
app_rand.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
app_rand.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
app_rand.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
app_rand.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
app_rand.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
app_rand.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
app_rand.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
@@ -164,8 +166,9 @@ app_rand.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
apps.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
apps.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
apps.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
apps.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
apps.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
apps.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
apps.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
apps.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
apps.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
apps.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
apps.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -184,8 +187,9 @@ apps.o: ../include/openssl/x509_vfy.h apps.h
|
||||
asn1pars.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
asn1pars.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
asn1pars.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
asn1pars.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
asn1pars.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
asn1pars.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
asn1pars.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
asn1pars.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
asn1pars.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
asn1pars.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
asn1pars.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -225,9 +229,10 @@ ca.o: ../include/openssl/x509v3.h apps.h
|
||||
ciphers.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
ciphers.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
ciphers.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
ciphers.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
ciphers.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
ciphers.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
ciphers.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
ciphers.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
ciphers.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
ciphers.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
ciphers.o: ../include/openssl/e_os2.h ../include/openssl/err.h
|
||||
ciphers.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
ciphers.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
@@ -268,8 +273,9 @@ crl.o: ../include/openssl/x509v3.h apps.h
|
||||
crl2p7.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
crl2p7.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
crl2p7.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
crl2p7.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
crl2p7.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
crl2p7.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
crl2p7.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
crl2p7.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
crl2p7.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
crl2p7.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
crl2p7.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -287,8 +293,9 @@ crl2p7.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
dgst.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
dgst.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
dgst.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
dgst.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
dgst.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
dgst.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
dgst.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
dgst.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
dgst.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
dgst.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
dgst.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -307,28 +314,30 @@ dgst.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
dh.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
dh.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
dh.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
dh.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
dh.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
dh.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
dh.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
dh.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
dh.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
dh.o: ../include/openssl/md4.h ../include/openssl/md5.h
|
||||
dh.o: ../include/openssl/mdc2.h ../include/openssl/obj_mac.h
|
||||
dh.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h
|
||||
dh.o: ../include/openssl/opensslv.h ../include/openssl/pem.h
|
||||
dh.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||
dh.o: ../include/openssl/rand.h ../include/openssl/rc2.h
|
||||
dh.o: ../include/openssl/rc4.h ../include/openssl/rc5.h
|
||||
dh.o: ../include/openssl/ripemd.h ../include/openssl/rsa.h
|
||||
dh.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
||||
dh.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||
dh.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
dh.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
dh.o: ../include/openssl/des.h ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
dh.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
dh.o: ../include/openssl/e_os2.h ../include/openssl/engine.h
|
||||
dh.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
dh.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
dh.o: ../include/openssl/md2.h ../include/openssl/md4.h
|
||||
dh.o: ../include/openssl/md5.h ../include/openssl/mdc2.h
|
||||
dh.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
||||
dh.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||
dh.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
||||
dh.o: ../include/openssl/pkcs7.h ../include/openssl/rand.h
|
||||
dh.o: ../include/openssl/rc2.h ../include/openssl/rc4.h
|
||||
dh.o: ../include/openssl/rc5.h ../include/openssl/ripemd.h
|
||||
dh.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
|
||||
dh.o: ../include/openssl/sha.h ../include/openssl/stack.h
|
||||
dh.o: ../include/openssl/symhacks.h ../include/openssl/x509.h
|
||||
dh.o: ../include/openssl/x509_vfy.h apps.h
|
||||
dsa.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
dsa.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
dsa.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
dsa.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
dsa.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
dsa.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
dsa.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
dsa.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
dsa.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
dsa.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
dsa.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -347,8 +356,9 @@ dsa.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
dsaparam.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
dsaparam.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
dsaparam.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
dsaparam.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
dsaparam.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
dsaparam.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
dsaparam.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
dsaparam.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
dsaparam.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
dsaparam.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
dsaparam.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -367,8 +377,9 @@ dsaparam.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
enc.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
enc.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
enc.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
enc.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
enc.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
enc.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
enc.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
enc.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
enc.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
enc.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
enc.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -387,9 +398,10 @@ enc.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
errstr.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
errstr.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
errstr.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
errstr.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
errstr.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
errstr.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
errstr.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
errstr.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
errstr.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
errstr.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
errstr.o: ../include/openssl/e_os2.h ../include/openssl/err.h
|
||||
errstr.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
errstr.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
@@ -409,8 +421,9 @@ errstr.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
gendh.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
gendh.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
gendh.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
gendh.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
gendh.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
gendh.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
gendh.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
gendh.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
gendh.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
gendh.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
gendh.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -429,8 +442,9 @@ gendh.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
gendsa.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
gendsa.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
gendsa.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
gendsa.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
gendsa.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
gendsa.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
gendsa.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
gendsa.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
gendsa.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
gendsa.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
gendsa.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -449,8 +463,9 @@ gendsa.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
genrsa.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
genrsa.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
genrsa.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
genrsa.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
genrsa.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
genrsa.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
genrsa.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
genrsa.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
genrsa.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
genrsa.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
genrsa.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -469,8 +484,9 @@ genrsa.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
nseq.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
nseq.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
nseq.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
nseq.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
nseq.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
nseq.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
nseq.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
nseq.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
nseq.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
nseq.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
nseq.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -512,8 +528,9 @@ openssl.o: progs.h s_apps.h
|
||||
passwd.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
passwd.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
passwd.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
passwd.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
passwd.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
passwd.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
passwd.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
passwd.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
passwd.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
passwd.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
passwd.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -531,8 +548,9 @@ passwd.o: ../include/openssl/x509_vfy.h apps.h
|
||||
pkcs12.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
pkcs12.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
pkcs12.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
pkcs12.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
pkcs12.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
pkcs12.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
pkcs12.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
pkcs12.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
pkcs12.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
pkcs12.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
pkcs12.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -552,8 +570,9 @@ pkcs12.o: ../include/openssl/x509_vfy.h apps.h
|
||||
pkcs7.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
pkcs7.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
pkcs7.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
pkcs7.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
pkcs7.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
pkcs7.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
pkcs7.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
pkcs7.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
pkcs7.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
pkcs7.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
pkcs7.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -572,8 +591,9 @@ pkcs7.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
pkcs8.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
pkcs8.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
pkcs8.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
pkcs8.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
pkcs8.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
pkcs8.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
pkcs8.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
pkcs8.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
pkcs8.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
pkcs8.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
pkcs8.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -593,8 +613,9 @@ pkcs8.o: ../include/openssl/x509_vfy.h apps.h
|
||||
rand.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
rand.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
rand.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
rand.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
rand.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
rand.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
rand.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
rand.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
rand.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
rand.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
rand.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -634,8 +655,9 @@ req.o: ../include/openssl/x509v3.h apps.h
|
||||
rsa.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
rsa.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
rsa.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
rsa.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
rsa.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
rsa.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
rsa.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
rsa.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
rsa.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
rsa.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
rsa.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -654,8 +676,9 @@ rsa.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
rsautl.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
rsautl.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
rsautl.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
rsautl.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
rsautl.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
rsautl.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
rsautl.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
rsautl.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
rsautl.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
rsautl.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
rsautl.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -674,9 +697,10 @@ rsautl.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
s_cb.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
s_cb.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
s_cb.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
s_cb.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
s_cb.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
s_cb.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
s_cb.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
s_cb.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
s_cb.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
s_cb.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
s_cb.o: ../include/openssl/e_os2.h ../include/openssl/err.h
|
||||
s_cb.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
s_cb.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
@@ -696,9 +720,10 @@ s_cb.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h s_apps.h
|
||||
s_client.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
s_client.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
s_client.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
s_client.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
s_client.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
s_client.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
s_client.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
s_client.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
s_client.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
s_client.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
s_client.o: ../include/openssl/e_os2.h ../include/openssl/engine.h
|
||||
s_client.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
s_client.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -720,9 +745,10 @@ s_client.o: s_apps.h
|
||||
s_server.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
s_server.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
s_server.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
s_server.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
s_server.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
s_server.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
s_server.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
s_server.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
s_server.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
s_server.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
s_server.o: ../include/openssl/e_os2.h ../include/openssl/engine.h
|
||||
s_server.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||
s_server.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
@@ -744,9 +770,10 @@ s_server.o: s_apps.h
|
||||
s_socket.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
s_socket.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
s_socket.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
s_socket.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
s_socket.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
s_socket.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
s_socket.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
s_socket.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
s_socket.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
s_socket.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
s_socket.o: ../include/openssl/e_os2.h ../include/openssl/evp.h
|
||||
s_socket.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||
s_socket.o: ../include/openssl/md2.h ../include/openssl/md4.h
|
||||
@@ -766,9 +793,10 @@ s_socket.o: ../include/openssl/x509_vfy.h apps.h s_apps.h
|
||||
s_time.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
s_time.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
s_time.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
s_time.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
s_time.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
s_time.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
s_time.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
s_time.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
s_time.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
s_time.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
s_time.o: ../include/openssl/e_os2.h ../include/openssl/err.h
|
||||
s_time.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
s_time.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
@@ -789,9 +817,10 @@ s_time.o: s_apps.h
|
||||
sess_id.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
sess_id.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
sess_id.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
sess_id.o: ../include/openssl/comp.h ../include/openssl/crypto.h
|
||||
sess_id.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
sess_id.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
sess_id.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||
sess_id.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
sess_id.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
sess_id.o: ../include/openssl/e_os.h ../include/openssl/e_os.h
|
||||
sess_id.o: ../include/openssl/e_os2.h ../include/openssl/err.h
|
||||
sess_id.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
sess_id.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
@@ -811,8 +840,9 @@ sess_id.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
smime.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
smime.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
smime.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
smime.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
smime.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
smime.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
smime.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
smime.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
smime.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
smime.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
smime.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
@@ -831,8 +861,9 @@ smime.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||
speed.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
speed.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
speed.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
speed.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
speed.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
speed.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
speed.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
speed.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
speed.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
speed.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||
speed.o: ../include/openssl/evp.h ../include/openssl/hmac.h
|
||||
@@ -894,8 +925,9 @@ verify.o: ../include/openssl/x509v3.h apps.h
|
||||
version.o: ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||
version.o: ../include/openssl/blowfish.h ../include/openssl/bn.h
|
||||
version.o: ../include/openssl/buffer.h ../include/openssl/cast.h
|
||||
version.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||
version.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||
version.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||
version.o: ../include/openssl/des.h ../include/openssl/dh.h
|
||||
version.o: ../include/openssl/dsa.h ../include/openssl/e_os.h
|
||||
version.o: ../include/openssl/e_os.h ../include/openssl/e_os2.h
|
||||
version.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||
version.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||
|
@@ -177,8 +177,10 @@ long app_RAND_load_files(char *name)
|
||||
if (*n == '\0') break;
|
||||
|
||||
egd=RAND_egd(n);
|
||||
if (egd > 0) tot+=egd;
|
||||
tot+=RAND_load_file(n,-1);
|
||||
if (egd > 0)
|
||||
tot+=egd;
|
||||
else
|
||||
tot+=RAND_load_file(n,-1);
|
||||
if (last) break;
|
||||
}
|
||||
if (tot > 512)
|
||||
|
@@ -662,7 +662,7 @@ STACK_OF(X509) *load_certs(BIO *err, char *file, int format)
|
||||
|
||||
if (format == FORMAT_PEM)
|
||||
{
|
||||
othercerts = sk_X509_new(NULL);
|
||||
othercerts = sk_X509_new_null();
|
||||
if(!othercerts)
|
||||
{
|
||||
sk_X509_free(othercerts);
|
||||
|
@@ -66,6 +66,7 @@
|
||||
#include <openssl/crypto.h>
|
||||
#include <openssl/x509.h>
|
||||
#include <openssl/lhash.h>
|
||||
#include <openssl/conf.h>
|
||||
|
||||
int app_RAND_load_file(const char *file, BIO *bio_e, int dont_warn);
|
||||
int app_RAND_write_file(const char *file, BIO *bio_e);
|
||||
@@ -99,7 +100,6 @@ extern BIO *bio_err;
|
||||
#else
|
||||
|
||||
#define MAIN(a,v) PROG(a,v)
|
||||
#include <openssl/conf.h>
|
||||
extern LHASH *config;
|
||||
extern char *default_config_file;
|
||||
extern BIO *bio_err;
|
||||
|
@@ -206,6 +206,12 @@ bad:
|
||||
goto end;
|
||||
}
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE|BIO_FP_TEXT);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (oidfile != NULL)
|
||||
{
|
||||
@@ -315,7 +321,7 @@ bad:
|
||||
end:
|
||||
BIO_free(derout);
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (b64 != NULL) BIO_free(b64);
|
||||
if (ret != 0)
|
||||
ERR_print_errors(bio_err);
|
||||
|
@@ -1 +1 @@
|
||||
05
|
||||
07
|
||||
|
32
apps/ca.c
32
apps/ca.c
@@ -717,6 +717,12 @@ bad:
|
||||
if (verbose)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE|BIO_FP_TEXT); /* cannot fail */
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
TXT_DB_write(out,db);
|
||||
BIO_printf(bio_err,"%d entries loaded from the database\n",
|
||||
db->data->num);
|
||||
@@ -751,7 +757,15 @@ bad:
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
BIO_set_fp(Sout,stdout,BIO_NOCLOSE|BIO_FP_TEXT);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
Sout = BIO_push(tmpbio, Sout);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
if (req)
|
||||
@@ -1047,7 +1061,7 @@ bad:
|
||||
#endif
|
||||
|
||||
BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
in=NULL;
|
||||
out=NULL;
|
||||
if (rename(serialfile,buf[2]) < 0)
|
||||
@@ -1233,7 +1247,11 @@ bad:
|
||||
X509_free(revcert);
|
||||
|
||||
strncpy(buf[0],dbfile,BSIZE-4);
|
||||
#ifndef VMS
|
||||
strcat(buf[0],".new");
|
||||
#else
|
||||
strcat(buf[0],"-new");
|
||||
#endif
|
||||
if (BIO_write_filename(out,buf[0]) <= 0)
|
||||
{
|
||||
perror(dbfile);
|
||||
@@ -1243,7 +1261,11 @@ bad:
|
||||
j=TXT_DB_write(out,db);
|
||||
if (j <= 0) goto err;
|
||||
strncpy(buf[1],dbfile,BSIZE-4);
|
||||
#ifndef VMS
|
||||
strcat(buf[1],".old");
|
||||
#else
|
||||
strcat(buf[1],"-old");
|
||||
#endif
|
||||
if (rename(dbfile,buf[1]) < 0)
|
||||
{
|
||||
BIO_printf(bio_err,"unable to rename %s to %s\n", dbfile, buf[1]);
|
||||
@@ -1264,9 +1286,9 @@ bad:
|
||||
ret=0;
|
||||
err:
|
||||
BIO_free(hex);
|
||||
BIO_free(Cout);
|
||||
BIO_free(Sout);
|
||||
BIO_free(out);
|
||||
BIO_free_all(Cout);
|
||||
BIO_free_all(Sout);
|
||||
BIO_free_all(out);
|
||||
BIO_free(in);
|
||||
|
||||
sk_X509_pop_free(cert_sk,X509_free);
|
||||
@@ -1381,7 +1403,7 @@ static int save_serial(char *serialfile, BIGNUM *serial)
|
||||
BIO_puts(out,"\n");
|
||||
ret=1;
|
||||
err:
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (ai != NULL) ASN1_INTEGER_free(ai);
|
||||
return(ret);
|
||||
}
|
||||
|
@@ -108,6 +108,12 @@ int MAIN(int argc, char **argv)
|
||||
if (bio_err == NULL)
|
||||
bio_err=BIO_new_fp(stderr,BIO_NOCLOSE);
|
||||
STDout=BIO_new_fp(stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
STDout = BIO_push(tmpbio, STDout);
|
||||
}
|
||||
#endif
|
||||
|
||||
argc--;
|
||||
argv++;
|
||||
@@ -195,7 +201,7 @@ err:
|
||||
end:
|
||||
if (ctx != NULL) SSL_CTX_free(ctx);
|
||||
if (ssl != NULL) SSL_free(ssl);
|
||||
if (STDout != NULL) BIO_free(STDout);
|
||||
if (STDout != NULL) BIO_free_all(STDout);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
||||
|
20
apps/crl.c
20
apps/crl.c
@@ -122,7 +122,15 @@ int MAIN(int argc, char **argv)
|
||||
|
||||
if (bio_out == NULL)
|
||||
if ((bio_out=BIO_new(BIO_s_file())) != NULL)
|
||||
{
|
||||
BIO_set_fp(bio_out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
bio_out = BIO_push(tmpbio, bio_out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
informat=FORMAT_PEM;
|
||||
outformat=FORMAT_PEM;
|
||||
@@ -314,7 +322,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -340,8 +356,8 @@ bad:
|
||||
if (!i) { BIO_printf(bio_err,"unable to write CRL\n"); goto end; }
|
||||
ret=0;
|
||||
end:
|
||||
BIO_free(out);
|
||||
BIO_free(bio_out);
|
||||
BIO_free_all(out);
|
||||
BIO_free_all(bio_out);
|
||||
bio_out=NULL;
|
||||
X509_CRL_free(x);
|
||||
if(store) {
|
||||
|
@@ -141,7 +141,7 @@ int MAIN(int argc, char **argv)
|
||||
else if (strcmp(*argv,"-certfile") == 0)
|
||||
{
|
||||
if (--argc < 1) goto bad;
|
||||
if(!certflst) certflst = sk_new(NULL);
|
||||
if(!certflst) certflst = sk_new_null();
|
||||
sk_push(certflst,*(++argv));
|
||||
}
|
||||
else
|
||||
@@ -215,7 +215,7 @@ bad:
|
||||
p7s->contents->type=OBJ_nid2obj(NID_pkcs7_data);
|
||||
|
||||
if (!ASN1_INTEGER_set(p7s->version,1)) goto end;
|
||||
if ((crl_stack=sk_X509_CRL_new(NULL)) == NULL) goto end;
|
||||
if ((crl_stack=sk_X509_CRL_new_null()) == NULL) goto end;
|
||||
p7s->crl=crl_stack;
|
||||
if (crl != NULL)
|
||||
{
|
||||
@@ -223,7 +223,7 @@ bad:
|
||||
crl=NULL; /* now part of p7 for OPENSSL_freeing */
|
||||
}
|
||||
|
||||
if ((cert_stack=sk_X509_new(NULL)) == NULL) goto end;
|
||||
if ((cert_stack=sk_X509_new_null()) == NULL) goto end;
|
||||
p7s->cert=cert_stack;
|
||||
|
||||
if(certflst) for(i = 0; i < sk_num(certflst); i++) {
|
||||
@@ -239,7 +239,15 @@ bad:
|
||||
sk_free(certflst);
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -266,7 +274,7 @@ bad:
|
||||
ret=0;
|
||||
end:
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (p7 != NULL) PKCS7_free(p7);
|
||||
if (crl != NULL) X509_CRL_free(crl);
|
||||
|
||||
|
26
apps/dgst.c
26
apps/dgst.c
@@ -74,8 +74,8 @@
|
||||
#undef PROG
|
||||
#define PROG dgst_main
|
||||
|
||||
void do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, char binout,
|
||||
EVP_PKEY *key, unsigned char *sigin, unsigned int siglen);
|
||||
void do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
||||
EVP_PKEY *key, unsigned char *sigin, int siglen);
|
||||
|
||||
int MAIN(int, char **);
|
||||
|
||||
@@ -95,10 +95,10 @@ int MAIN(int argc, char **argv)
|
||||
int debug=0;
|
||||
const char *outfile = NULL, *keyfile = NULL;
|
||||
const char *sigfile = NULL, *randfile = NULL;
|
||||
char out_bin = -1, want_pub = 0, do_verify = 0;
|
||||
int out_bin = -1, want_pub = 0, do_verify = 0;
|
||||
EVP_PKEY *sigkey = NULL;
|
||||
unsigned char *sigbuf = NULL;
|
||||
unsigned int siglen = 0;
|
||||
int siglen = 0;
|
||||
char *engine=NULL;
|
||||
|
||||
apps_startup();
|
||||
@@ -263,7 +263,15 @@ int MAIN(int argc, char **argv)
|
||||
if(out_bin)
|
||||
out = BIO_new_file(outfile, "wb");
|
||||
else out = BIO_new_file(outfile, "w");
|
||||
} else out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
} else {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
if(!out) {
|
||||
BIO_printf(bio_err, "Error opening output file %s\n",
|
||||
@@ -350,15 +358,15 @@ end:
|
||||
OPENSSL_free(buf);
|
||||
}
|
||||
if (in != NULL) BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
EVP_PKEY_free(sigkey);
|
||||
if(sigbuf) OPENSSL_free(sigbuf);
|
||||
if (bmd != NULL) BIO_free(bmd);
|
||||
EXIT(err);
|
||||
}
|
||||
|
||||
void do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, char binout,
|
||||
EVP_PKEY *key, unsigned char *sigin, unsigned int siglen)
|
||||
void do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
||||
EVP_PKEY *key, unsigned char *sigin, int siglen)
|
||||
{
|
||||
int len;
|
||||
int i;
|
||||
@@ -372,7 +380,7 @@ void do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, char binout,
|
||||
{
|
||||
EVP_MD_CTX *ctx;
|
||||
BIO_get_md_ctx(bp, &ctx);
|
||||
i = EVP_VerifyFinal(ctx, sigin, siglen, key);
|
||||
i = EVP_VerifyFinal(ctx, sigin, (unsigned int)siglen, key);
|
||||
if(i > 0) BIO_printf(out, "Verified OK\n");
|
||||
else if(i == 0) BIO_printf(out, "Verification Failure\n");
|
||||
else
|
||||
|
10
apps/dh.c
10
apps/dh.c
@@ -211,7 +211,15 @@ bad:
|
||||
}
|
||||
}
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -336,7 +344,7 @@ bad:
|
||||
ret=0;
|
||||
end:
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (dh != NULL) DH_free(dh);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
@@ -417,7 +417,15 @@ bad:
|
||||
goto end;
|
||||
}
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -522,7 +530,7 @@ bad:
|
||||
ret=0;
|
||||
end:
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (dh != NULL) DH_free(dh);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
10
apps/dsa.c
10
apps/dsa.c
@@ -260,7 +260,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -308,7 +316,7 @@ bad:
|
||||
ret=0;
|
||||
end:
|
||||
if(in != NULL) BIO_free(in);
|
||||
if(out != NULL) BIO_free(out);
|
||||
if(out != NULL) BIO_free_all(out);
|
||||
if(dsa != NULL) DSA_free(dsa);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
|
@@ -207,7 +207,15 @@ bad:
|
||||
}
|
||||
}
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -305,7 +313,7 @@ bad:
|
||||
printf("\tdsa->g=BN_bin2bn(dsa%d_g,sizeof(dsa%d_g),NULL);\n",
|
||||
bits_p,bits_p);
|
||||
printf("\tif ((dsa->p == NULL) || (dsa->q == NULL) || (dsa->g == NULL))\n");
|
||||
printf("\t\treturn(NULL);\n");
|
||||
printf("\t\t{ DSA_free(dsa); return(NULL); }\n");
|
||||
printf("\treturn(dsa);\n\t}\n");
|
||||
}
|
||||
|
||||
@@ -349,7 +357,7 @@ bad:
|
||||
ret=0;
|
||||
end:
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (dsa != NULL) DSA_free(dsa);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
18
apps/enc.c
18
apps/enc.c
@@ -443,7 +443,15 @@ bad:
|
||||
|
||||
|
||||
if (outf == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outf) <= 0)
|
||||
@@ -534,6 +542,14 @@ bad:
|
||||
BIO_printf(bio_err,"invalid hex iv value\n");
|
||||
goto end;
|
||||
}
|
||||
if ((hiv == NULL) && (str == NULL))
|
||||
{
|
||||
/* No IV was explicitly set and no IV was generated
|
||||
* during EVP_BytesToKey. Hence the IV is undefined,
|
||||
* making correct decryption impossible. */
|
||||
BIO_printf(bio_err, "iv undefined\n");
|
||||
goto end;
|
||||
}
|
||||
if ((hkey != NULL) && !set_hex(hkey,key,24))
|
||||
{
|
||||
BIO_printf(bio_err,"invalid hex key value\n");
|
||||
@@ -611,7 +627,7 @@ end:
|
||||
if (strbuf != NULL) OPENSSL_free(strbuf);
|
||||
if (buff != NULL) OPENSSL_free(buff);
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (benc != NULL) BIO_free(benc);
|
||||
if (b64 != NULL) BIO_free(b64);
|
||||
if(pass) OPENSSL_free(pass);
|
||||
|
@@ -91,12 +91,18 @@ int MAIN(int argc, char **argv)
|
||||
out=BIO_new(BIO_s_file());
|
||||
if ((out != NULL) && BIO_set_fp(out,stdout,BIO_NOCLOSE))
|
||||
{
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
lh_node_stats_bio((LHASH *)ERR_get_string_table(),out);
|
||||
lh_stats_bio((LHASH *)ERR_get_string_table(),out);
|
||||
lh_node_usage_stats_bio((LHASH *)
|
||||
ERR_get_string_table(),out);
|
||||
}
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
argc--;
|
||||
argv++;
|
||||
}
|
||||
|
10
apps/gendh.c
10
apps/gendh.c
@@ -169,7 +169,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -201,7 +209,7 @@ bad:
|
||||
end:
|
||||
if (ret != 0)
|
||||
ERR_print_errors(bio_err);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (dh != NULL) DH_free(dh);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
@@ -205,7 +205,15 @@ bad:
|
||||
if (out == NULL) goto end;
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -236,7 +244,7 @@ end:
|
||||
if (ret != 0)
|
||||
ERR_print_errors(bio_err);
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (dsa != NULL) DSA_free(dsa);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
EXIT(ret);
|
||||
|
@@ -195,7 +195,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -240,7 +248,7 @@ bad:
|
||||
ret=0;
|
||||
err:
|
||||
if (rsa != NULL) RSA_free(rsa);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
if (ret != 0)
|
||||
ERR_print_errors(bio_err);
|
||||
|
15
apps/nseq.c
15
apps/nseq.c
@@ -119,11 +119,18 @@ int MAIN(int argc, char **argv)
|
||||
"Can't open output file %s\n", outfile);
|
||||
goto end;
|
||||
}
|
||||
} else out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
|
||||
} else {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
if (toseq) {
|
||||
seq = NETSCAPE_CERT_SEQUENCE_new();
|
||||
seq->certs = sk_X509_new(NULL);
|
||||
seq->certs = sk_X509_new_null();
|
||||
while((x509 = PEM_read_bio_X509(in, NULL, NULL, NULL)))
|
||||
sk_X509_push(seq->certs,x509);
|
||||
|
||||
@@ -152,7 +159,7 @@ int MAIN(int argc, char **argv)
|
||||
ret = 0;
|
||||
end:
|
||||
BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
NETSCAPE_CERT_SEQUENCE_free(seq);
|
||||
|
||||
EXIT(ret);
|
||||
|
@@ -238,13 +238,19 @@ static int do_cmd(LHASH *prog, int argc, char *argv[])
|
||||
else if ((strncmp(argv[0],"no-",3)) == 0)
|
||||
{
|
||||
BIO *bio_stdout = BIO_new_fp(stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
bio_stdout = BIO_push(tmpbio, bio_stdout);
|
||||
}
|
||||
#endif
|
||||
f.name=argv[0]+3;
|
||||
ret = (lh_retrieve(prog,&f) != NULL);
|
||||
if (!ret)
|
||||
BIO_printf(bio_stdout, "%s\n", argv[0]);
|
||||
else
|
||||
BIO_printf(bio_stdout, "%s\n", argv[0]+3);
|
||||
BIO_free(bio_stdout);
|
||||
BIO_free_all(bio_stdout);
|
||||
goto end;
|
||||
}
|
||||
else if ((strcmp(argv[0],"quit") == 0) ||
|
||||
@@ -269,11 +275,17 @@ static int do_cmd(LHASH *prog, int argc, char *argv[])
|
||||
else /* strcmp(argv[0],LIST_CIPHER_COMMANDS) == 0 */
|
||||
list_type = FUNC_TYPE_CIPHER;
|
||||
bio_stdout = BIO_new_fp(stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
bio_stdout = BIO_push(tmpbio, bio_stdout);
|
||||
}
|
||||
#endif
|
||||
|
||||
for (fp=functions; fp->name != NULL; fp++)
|
||||
if (fp->type == list_type)
|
||||
BIO_printf(bio_stdout, "%s\n", fp->name);
|
||||
BIO_free(bio_stdout);
|
||||
BIO_free_all(bio_stdout);
|
||||
ret=0;
|
||||
goto end;
|
||||
}
|
||||
|
@@ -81,6 +81,12 @@ int MAIN(int argc, char **argv)
|
||||
if (out == NULL)
|
||||
goto err;
|
||||
BIO_set_fp(out, stdout, BIO_NOCLOSE | BIO_FP_TEXT);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
|
||||
badopt = 0, opt_done = 0;
|
||||
i = 0;
|
||||
@@ -266,6 +272,7 @@ int MAIN(int argc, char **argv)
|
||||
}
|
||||
while (!done);
|
||||
}
|
||||
ret = 0;
|
||||
|
||||
err:
|
||||
ERR_print_errors(bio_err);
|
||||
@@ -276,7 +283,7 @@ err:
|
||||
if (in)
|
||||
BIO_free(in);
|
||||
if (out)
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
||||
@@ -309,7 +316,7 @@ static char *md5crypt(const char *passwd, const char *magic, const char *salt)
|
||||
strncat(out_buf, "$", 1);
|
||||
strncat(out_buf, salt, 8);
|
||||
assert(strlen(out_buf) <= 6 + 8); /* "$apr1$..salt.." */
|
||||
salt_out = out_buf + 6;
|
||||
salt_out = out_buf + 2 + strlen(magic);
|
||||
salt_len = strlen(salt_out);
|
||||
assert(salt_len <= 8);
|
||||
|
||||
|
@@ -1 +1 @@
|
||||
01
|
||||
07
|
||||
|
@@ -200,7 +200,7 @@ int MAIN(int argc, char **argv)
|
||||
} else if (!strcmp (*args, "-caname")) {
|
||||
if (args[1]) {
|
||||
args++;
|
||||
if (!canames) canames = sk_new(NULL);
|
||||
if (!canames) canames = sk_new_null();
|
||||
sk_push(canames, *args);
|
||||
} else badarg = 1;
|
||||
} else if (!strcmp (*args, "-in")) {
|
||||
@@ -373,8 +373,15 @@ int MAIN(int argc, char **argv)
|
||||
CRYPTO_push_info("write files");
|
||||
#endif
|
||||
|
||||
if (!outfile) out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
else out = BIO_new_file(outfile, "wb");
|
||||
if (!outfile) {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
} else out = BIO_new_file(outfile, "wb");
|
||||
if (!out) {
|
||||
BIO_printf(bio_err, "Error opening output file %s\n",
|
||||
outfile ? outfile : "<stdout>");
|
||||
@@ -427,7 +434,7 @@ int MAIN(int argc, char **argv)
|
||||
CRYPTO_push_info("reading certs from input");
|
||||
#endif
|
||||
|
||||
certs = sk_X509_new(NULL);
|
||||
certs = sk_X509_new_null();
|
||||
|
||||
/* Load in all certs in input file */
|
||||
if(!cert_load(in, certs)) {
|
||||
@@ -459,7 +466,7 @@ int MAIN(int argc, char **argv)
|
||||
CRYPTO_push_info("reading certs from certfile");
|
||||
#endif
|
||||
|
||||
bags = sk_PKCS12_SAFEBAG_new (NULL);
|
||||
bags = sk_PKCS12_SAFEBAG_new_null ();
|
||||
|
||||
/* Add any more certificates asked for */
|
||||
if (certsin) {
|
||||
@@ -550,7 +557,7 @@ int MAIN(int argc, char **argv)
|
||||
goto export_end;
|
||||
}
|
||||
|
||||
safes = sk_PKCS7_new (NULL);
|
||||
safes = sk_PKCS7_new_null ();
|
||||
sk_PKCS7_push (safes, authsafe);
|
||||
|
||||
#ifdef CRYPTO_MDEBUG
|
||||
@@ -566,7 +573,7 @@ int MAIN(int argc, char **argv)
|
||||
p8 = NULL;
|
||||
if (name) PKCS12_add_friendlyname (bag, name, -1);
|
||||
PKCS12_add_localkeyid (bag, keyid, keyidlen);
|
||||
bags = sk_PKCS12_SAFEBAG_new(NULL);
|
||||
bags = sk_PKCS12_SAFEBAG_new_null();
|
||||
sk_PKCS12_SAFEBAG_push (bags, bag);
|
||||
|
||||
#ifdef CRYPTO_MDEBUG
|
||||
@@ -680,7 +687,7 @@ int MAIN(int argc, char **argv)
|
||||
CRYPTO_remove_all_info();
|
||||
#endif
|
||||
BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
if (canames) sk_free(canames);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
@@ -903,14 +910,14 @@ int print_attribs (BIO *out, STACK_OF(X509_ATTRIBUTE) *attrlst, char *name)
|
||||
break;
|
||||
|
||||
case V_ASN1_OCTET_STRING:
|
||||
hex_prin(out, av->value.bit_string->data,
|
||||
av->value.bit_string->length);
|
||||
hex_prin(out, av->value.octet_string->data,
|
||||
av->value.octet_string->length);
|
||||
BIO_printf(out, "\n");
|
||||
break;
|
||||
|
||||
case V_ASN1_BIT_STRING:
|
||||
hex_prin(out, av->value.octet_string->data,
|
||||
av->value.octet_string->length);
|
||||
hex_prin(out, av->value.bit_string->data,
|
||||
av->value.bit_string->length);
|
||||
BIO_printf(out, "\n");
|
||||
break;
|
||||
|
||||
|
10
apps/pkcs7.c
10
apps/pkcs7.c
@@ -223,7 +223,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -307,6 +315,6 @@ bad:
|
||||
end:
|
||||
if (p7 != NULL) PKCS7_free(p7);
|
||||
if (in != NULL) BIO_free(in);
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
15
apps/pkcs8.c
15
apps/pkcs8.c
@@ -224,8 +224,15 @@ int MAIN(int argc, char **argv)
|
||||
"Can't open output file %s\n", outfile);
|
||||
return (1);
|
||||
}
|
||||
} else out = BIO_new_fp (stdout, BIO_NOCLOSE);
|
||||
|
||||
} else {
|
||||
out = BIO_new_fp (stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
if (topk8) {
|
||||
if(informat == FORMAT_PEM)
|
||||
pkey = PEM_read_bio_PrivateKey(in, NULL, NULL, passin);
|
||||
@@ -283,7 +290,7 @@ int MAIN(int argc, char **argv)
|
||||
}
|
||||
PKCS8_PRIV_KEY_INFO_free (p8inf);
|
||||
EVP_PKEY_free(pkey);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
return (0);
|
||||
@@ -366,7 +373,7 @@ int MAIN(int argc, char **argv)
|
||||
}
|
||||
|
||||
EVP_PKEY_free(pkey);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
BIO_free(in);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
|
@@ -130,7 +130,15 @@ int MAIN(int argc, char **argv)
|
||||
if (outfile != NULL)
|
||||
r = BIO_write_filename(out, outfile);
|
||||
else
|
||||
{
|
||||
r = BIO_set_fp(out, stdout, BIO_NOCLOSE | BIO_FP_TEXT);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
if (r <= 0)
|
||||
goto err;
|
||||
|
||||
|
25
apps/req.c
25
apps/req.c
@@ -649,6 +649,12 @@ bad:
|
||||
{
|
||||
BIO_printf(bio_err,"writing new private key to stdout\n");
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -719,16 +725,15 @@ loop:
|
||||
|
||||
if (newreq || x509)
|
||||
{
|
||||
#ifndef NO_DSA
|
||||
if (pkey->type == EVP_PKEY_DSA)
|
||||
digest=EVP_dss1();
|
||||
#endif
|
||||
|
||||
if (pkey == NULL)
|
||||
{
|
||||
BIO_printf(bio_err,"you need to specify a private key\n");
|
||||
goto end;
|
||||
}
|
||||
#ifndef NO_DSA
|
||||
if (pkey->type == EVP_PKEY_DSA)
|
||||
digest=EVP_dss1();
|
||||
#endif
|
||||
if (req == NULL)
|
||||
{
|
||||
req=X509_REQ_new();
|
||||
@@ -844,7 +849,15 @@ loop:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if ((keyout != NULL) && (strcmp(outfile,keyout) == 0))
|
||||
@@ -930,7 +943,7 @@ end:
|
||||
}
|
||||
if ((req_conf != NULL) && (req_conf != config)) CONF_free(req_conf);
|
||||
BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
EVP_PKEY_free(pkey);
|
||||
X509_REQ_free(req);
|
||||
X509_free(x509ss);
|
||||
|
10
apps/rsa.c
10
apps/rsa.c
@@ -305,7 +305,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -404,7 +412,7 @@ bad:
|
||||
ret=0;
|
||||
end:
|
||||
if(in != NULL) BIO_free(in);
|
||||
if(out != NULL) BIO_free(out);
|
||||
if(out != NULL) BIO_free_all(out);
|
||||
if(rsa != NULL) RSA_free(rsa);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
if(passout) OPENSSL_free(passout);
|
||||
|
@@ -55,6 +55,9 @@
|
||||
* Hudson (tjh@cryptsoft.com).
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef NO_RSA
|
||||
|
||||
#include "apps.h"
|
||||
#include <string.h>
|
||||
#include <openssl/err.h>
|
||||
@@ -222,7 +225,15 @@ int MAIN(int argc, char **argv)
|
||||
ERR_print_errors(bio_err);
|
||||
goto end;
|
||||
}
|
||||
} else out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
} else {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
keysize = RSA_size(rsa);
|
||||
|
||||
@@ -279,7 +290,7 @@ int MAIN(int argc, char **argv)
|
||||
end:
|
||||
RSA_free(rsa);
|
||||
BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
if(rsa_in) OPENSSL_free(rsa_in);
|
||||
if(rsa_out) OPENSSL_free(rsa_out);
|
||||
return ret;
|
||||
@@ -305,3 +316,4 @@ static void usage()
|
||||
BIO_printf(bio_err, "-hexdump hex dump output\n");
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@@ -79,6 +79,7 @@ typedef unsigned int u_int;
|
||||
#include <openssl/ssl.h>
|
||||
#include <openssl/err.h>
|
||||
#include <openssl/pem.h>
|
||||
#include <openssl/rand.h>
|
||||
#include <openssl/engine.h>
|
||||
#include "s_apps.h"
|
||||
|
||||
@@ -153,8 +154,8 @@ static void sc_usage(void)
|
||||
BIO_printf(bio_err," -bugs - Switch on all SSL implementation bug workarounds\n");
|
||||
BIO_printf(bio_err," -cipher - preferred cipher to use, use the 'openssl ciphers'\n");
|
||||
BIO_printf(bio_err," command to see what is available\n");
|
||||
BIO_printf(bio_err," -rand file%cfile%c...\n", LIST_SEPARATOR_CHAR, LIST_SEPARATOR_CHAR);
|
||||
BIO_printf(bio_err," -engine id - Initialise and use the specified engine\n");
|
||||
|
||||
}
|
||||
|
||||
int MAIN(int, char **);
|
||||
@@ -181,6 +182,7 @@ int MAIN(int argc, char **argv)
|
||||
int prexit = 0;
|
||||
SSL_METHOD *meth=NULL;
|
||||
BIO *sbio;
|
||||
char *inrand=NULL;
|
||||
char *engine_id=NULL;
|
||||
ENGINE *e=NULL;
|
||||
#ifdef WINDOWS
|
||||
@@ -320,6 +322,11 @@ int MAIN(int argc, char **argv)
|
||||
else if (strcmp(*argv,"-nbio") == 0)
|
||||
{ c_nbio=1; }
|
||||
#endif
|
||||
else if (strcmp(*argv,"-rand") == 0)
|
||||
{
|
||||
if (--argc < 1) goto bad;
|
||||
inrand= *(++argv);
|
||||
}
|
||||
else if (strcmp(*argv,"-engine") == 0)
|
||||
{
|
||||
if (--argc < 1) goto bad;
|
||||
@@ -341,7 +348,14 @@ bad:
|
||||
goto end;
|
||||
}
|
||||
|
||||
app_RAND_load_file(NULL, bio_err, 0);
|
||||
if (!app_RAND_load_file(NULL, bio_err, 1) && inrand == NULL
|
||||
&& !RAND_status())
|
||||
{
|
||||
BIO_printf(bio_err,"warning, not much extra random data, consider using the -rand option\n");
|
||||
}
|
||||
if (inrand != NULL)
|
||||
BIO_printf(bio_err,"%ld semi-random bytes loaded\n",
|
||||
app_RAND_load_files(inrand));
|
||||
|
||||
if (bio_c_out == NULL)
|
||||
{
|
||||
|
@@ -83,6 +83,7 @@ typedef unsigned int u_int;
|
||||
#include <openssl/pem.h>
|
||||
#include <openssl/x509.h>
|
||||
#include <openssl/ssl.h>
|
||||
#include <openssl/rand.h>
|
||||
#include <openssl/engine.h>
|
||||
#include "s_apps.h"
|
||||
|
||||
@@ -245,6 +246,7 @@ static void sv_usage(void)
|
||||
BIO_printf(bio_err," -bugs - Turn on SSL bug compatibility\n");
|
||||
BIO_printf(bio_err," -www - Respond to a 'GET /' with a status page\n");
|
||||
BIO_printf(bio_err," -WWW - Respond to a 'GET /<path> HTTP/1.0' with file ./<path>\n");
|
||||
BIO_printf(bio_err," -rand file%cfile%c...\n", LIST_SEPARATOR_CHAR, LIST_SEPARATOR_CHAR);
|
||||
BIO_printf(bio_err," -engine id - Initialise and use the specified engine\n");
|
||||
}
|
||||
|
||||
@@ -415,6 +417,8 @@ int MAIN(int argc, char *argv[])
|
||||
int no_tmp_rsa=0,no_dhe=0,nocert=0;
|
||||
int state=0;
|
||||
SSL_METHOD *meth=NULL;
|
||||
char *inrand=NULL;
|
||||
char *engine_id=NULL;
|
||||
ENGINE *e=NULL;
|
||||
#ifndef NO_DH
|
||||
DH *dh=NULL;
|
||||
@@ -570,6 +574,11 @@ int MAIN(int argc, char *argv[])
|
||||
else if (strcmp(*argv,"-tls1") == 0)
|
||||
{ meth=TLSv1_server_method(); }
|
||||
#endif
|
||||
else if (strcmp(*argv,"-rand") == 0)
|
||||
{
|
||||
if (--argc < 1) goto bad;
|
||||
inrand= *(++argv);
|
||||
}
|
||||
else if (strcmp(*argv,"-engine") == 0)
|
||||
{
|
||||
if (--argc < 1) goto bad;
|
||||
@@ -591,7 +600,14 @@ bad:
|
||||
goto end;
|
||||
}
|
||||
|
||||
app_RAND_load_file(NULL, bio_err, 0);
|
||||
if (!app_RAND_load_file(NULL, bio_err, 1) && inrand == NULL
|
||||
&& !RAND_status())
|
||||
{
|
||||
BIO_printf(bio_err,"warning, not much extra random data, consider using the -rand option\n");
|
||||
}
|
||||
if (inrand != NULL)
|
||||
BIO_printf(bio_err,"%ld semi-random bytes loaded\n",
|
||||
app_RAND_load_files(inrand));
|
||||
|
||||
if (bio_s_out == NULL)
|
||||
{
|
||||
@@ -709,7 +725,8 @@ bad:
|
||||
|
||||
#ifndef NO_RSA
|
||||
#if 1
|
||||
SSL_CTX_set_tmp_rsa_callback(ctx,tmp_rsa_cb);
|
||||
if (!no_tmp_rsa)
|
||||
SSL_CTX_set_tmp_rsa_callback(ctx,tmp_rsa_cb);
|
||||
#else
|
||||
if (!no_tmp_rsa && SSL_CTX_need_tmp_RSA(ctx))
|
||||
{
|
||||
@@ -1369,15 +1386,29 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
||||
|
||||
/* skip the '/' */
|
||||
p= &(buf[5]);
|
||||
dot=0;
|
||||
|
||||
dot = 1;
|
||||
for (e=p; *e != '\0'; e++)
|
||||
{
|
||||
if (e[0] == ' ') break;
|
||||
if ( (e[0] == '.') &&
|
||||
(strncmp(&(e[-1]),"/../",4) == 0))
|
||||
dot=1;
|
||||
if (e[0] == ' ')
|
||||
break;
|
||||
|
||||
switch (dot)
|
||||
{
|
||||
case 1:
|
||||
dot = (e[0] == '.') ? 2 : 0;
|
||||
break;
|
||||
case 2:
|
||||
dot = (e[0] == '.') ? 3 : 0;
|
||||
break;
|
||||
case 3:
|
||||
dot = (e[0] == '/') ? -1 : 0;
|
||||
break;
|
||||
}
|
||||
if (dot == 0)
|
||||
dot = (e[0] == '/') ? 1 : 0;
|
||||
}
|
||||
|
||||
dot = (dot == 3) || (dot == -1); /* filename contains ".." component */
|
||||
|
||||
if (*e == '\0')
|
||||
{
|
||||
@@ -1401,9 +1432,11 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
||||
break;
|
||||
}
|
||||
|
||||
#if 0
|
||||
/* append if a directory lookup */
|
||||
if (e[-1] == '/')
|
||||
strcat(p,"index.html");
|
||||
#endif
|
||||
|
||||
/* if a directory, do the index thang */
|
||||
if (stat(p,&st_buf) < 0)
|
||||
@@ -1415,7 +1448,13 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
||||
}
|
||||
if (S_ISDIR(st_buf.st_mode))
|
||||
{
|
||||
#if 0 /* must check buffer size */
|
||||
strcat(p,"/index.html");
|
||||
#else
|
||||
BIO_puts(io,text);
|
||||
BIO_printf(io,"'%s' is a directory\r\n",p);
|
||||
break;
|
||||
#endif
|
||||
}
|
||||
|
||||
if ((file=BIO_new_file(p,"r")) == NULL)
|
||||
|
@@ -209,9 +209,11 @@ static int init_client_ip(int *sock, unsigned char ip[4], int port)
|
||||
s=socket(AF_INET,SOCK_STREAM,SOCKET_PROTOCOL);
|
||||
if (s == INVALID_SOCKET) { perror("socket"); return(0); }
|
||||
|
||||
#ifndef MPE
|
||||
i=0;
|
||||
i=setsockopt(s,SOL_SOCKET,SO_KEEPALIVE,(char *)&i,sizeof(i));
|
||||
if (i < 0) { perror("keepalive"); return(0); }
|
||||
#endif
|
||||
|
||||
if (connect(s,(struct sockaddr *)&them,sizeof(them)) == -1)
|
||||
{ close(s); perror("connect"); return(0); }
|
||||
|
@@ -1,17 +1,17 @@
|
||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit)
|
||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Server test cert (512 bit)
|
||||
subject= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Server test cert (512 bit)
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIIB6TCCAVICAQQwDQYJKoZIhvcNAQEEBQAwWzELMAkGA1UEBhMCQVUxEzARBgNV
|
||||
MIIB6TCCAVICAQYwDQYJKoZIhvcNAQEEBQAwWzELMAkGA1UEBhMCQVUxEzARBgNV
|
||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRswGQYD
|
||||
VQQDExJUZXN0IENBICgxMDI0IGJpdCkwHhcNOTgwNjI5MjM1MjQwWhcNMDAwNjI4
|
||||
MjM1MjQwWjBjMQswCQYDVQQGEwJBVTETMBEGA1UECBMKUXVlZW5zbGFuZDEaMBgG
|
||||
VQQDExJUZXN0IENBICgxMDI0IGJpdCkwHhcNMDAxMDE2MjIzMTAzWhcNMDMwMTE0
|
||||
MjIzMTAzWjBjMQswCQYDVQQGEwJBVTETMBEGA1UECBMKUXVlZW5zbGFuZDEaMBgG
|
||||
A1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxIzAhBgNVBAMTGlNlcnZlciB0ZXN0IGNl
|
||||
cnQgKDUxMiBiaXQpMFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJ+zw4Qnlf8SMVIP
|
||||
Fe9GEcStgOY2Ww/dgNdhjeD8ckUJNP5VZkVDTGiXav6ooKXfX3j/7tdkuD8Ey2//
|
||||
Kv7+ue0CAwEAATANBgkqhkiG9w0BAQQFAAOBgQCVvvfkGSe2GHgDFfmOua4Isjb9
|
||||
JVhImWMASiOClkZlMESDJjsszg/6+d/W+8TrbObhazpl95FivXBVucbj9dudh7AO
|
||||
IZu1h1MAPlyknc9Ud816vz3FejB4qqUoaXjnlkrIgEbr/un7jSS86WOe0hRhwHkJ
|
||||
FUGcPZf9ND22Etc+AQ==
|
||||
Kv7+ue0CAwEAATANBgkqhkiG9w0BAQQFAAOBgQCT0grFQeZaqYb5EYfk20XixZV4
|
||||
GmyAbXMftG1Eo7qGiMhYzRwGNWxEYojf5PZkYZXvSqZ/ZXHXa4g59jK/rJNnaVGM
|
||||
k+xIX8mxQvlV0n5O9PIha5BX5teZnkHKgL8aKKLKW1BK7YTngsfSzzaeame5iKfz
|
||||
itAE+OjGF+PFKbwX8Q==
|
||||
-----END CERTIFICATE-----
|
||||
-----BEGIN RSA PRIVATE KEY-----
|
||||
MIIBPAIBAAJBAJ+zw4Qnlf8SMVIPFe9GEcStgOY2Ww/dgNdhjeD8ckUJNP5VZkVD
|
||||
|
@@ -206,7 +206,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -262,7 +270,7 @@ bad:
|
||||
}
|
||||
ret=0;
|
||||
end:
|
||||
if (out != NULL) BIO_free(out);
|
||||
if (out != NULL) BIO_free_all(out);
|
||||
if (x != NULL) SSL_SESSION_free(x);
|
||||
EXIT(ret);
|
||||
}
|
||||
|
13
apps/smime.c
13
apps/smime.c
@@ -299,6 +299,7 @@ int MAIN(int argc, char **argv)
|
||||
BIO_printf (bio_err, "-CApath dir trusted certificates directory\n");
|
||||
BIO_printf (bio_err, "-CAfile file trusted certificates file\n");
|
||||
BIO_printf (bio_err, "-engine e use engine e, possibly a hardware device.\n");
|
||||
BIO_printf (bio_err, "-passin arg input file pass phrase source\n");
|
||||
BIO_printf(bio_err, "-rand file%cfile%c...\n", LIST_SEPARATOR_CHAR, LIST_SEPARATOR_CHAR);
|
||||
BIO_printf(bio_err, " load the file (or the files in the directory) into\n");
|
||||
BIO_printf(bio_err, " the random number generator\n");
|
||||
@@ -420,7 +421,15 @@ int MAIN(int argc, char **argv)
|
||||
"Can't open output file %s\n", outfile);
|
||||
goto end;
|
||||
}
|
||||
} else out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
} else {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
if(operation == SMIME_VERIFY) {
|
||||
if(!(store = setup_verify(CAfile, CApath))) goto end;
|
||||
@@ -517,7 +526,7 @@ end:
|
||||
PKCS7_free(p7);
|
||||
BIO_free(in);
|
||||
BIO_free(indata);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
return (ret);
|
||||
}
|
||||
|
203
apps/speed.c
203
apps/speed.c
@@ -83,12 +83,12 @@
|
||||
#include <openssl/err.h>
|
||||
#include <openssl/engine.h>
|
||||
|
||||
#if defined(__FreeBSD__)
|
||||
#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
|
||||
# define USE_TOD
|
||||
#elif !defined(MSDOS) && (!defined(VMS) || defined(__DECC))
|
||||
# define TIMES
|
||||
#endif
|
||||
#if !defined(_UNICOS)
|
||||
#if !defined(_UNICOS) && !defined(__OpenBSD__) && !defined(sgi) && !defined(__FreeBSD__) && !(defined(__bsdi) || defined(__bsdi__)) && !defined(_AIX) && !defined(MPE) && !defined(__NetBSD__)
|
||||
# define TIMEB
|
||||
#endif
|
||||
|
||||
@@ -116,7 +116,7 @@
|
||||
#include <sys/timeb.h>
|
||||
#endif
|
||||
|
||||
#if !defined(TIMES) && !defined(TIMEB)
|
||||
#if !defined(TIMES) && !defined(TIMEB) && !defined(USE_TOD)
|
||||
#error "It seems neither struct tms nor struct timeb is supported in this platform!"
|
||||
#endif
|
||||
|
||||
@@ -320,7 +320,7 @@ int MAIN(int argc, char **argv)
|
||||
#define DSA_NUM 3
|
||||
long count,rsa_count;
|
||||
int i,j,k;
|
||||
unsigned rsa_num,rsa_num2;
|
||||
unsigned rsa_num;
|
||||
#ifndef NO_MD2
|
||||
unsigned char md2[MD2_DIGEST_LENGTH];
|
||||
#endif
|
||||
@@ -865,6 +865,7 @@ int MAIN(int argc, char **argv)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifndef NO_DSA
|
||||
dsa_c[R_DSA_512][0]=count/1000;
|
||||
dsa_c[R_DSA_512][1]=count/1000/2;
|
||||
for (i=1; i<DSA_NUM; i++)
|
||||
@@ -882,6 +883,7 @@ int MAIN(int argc, char **argv)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
#define COND(d) (count < (d))
|
||||
#define COUNT(d) (d)
|
||||
@@ -1167,49 +1169,73 @@ int MAIN(int argc, char **argv)
|
||||
int ret;
|
||||
if (!rsa_doit[j]) continue;
|
||||
ret=RSA_sign(NID_md5_sha1, buf,36, buf2, &rsa_num, rsa_key[j]);
|
||||
pkey_print_message("private","rsa",rsa_c[j][0],rsa_bits[j],
|
||||
RSA_SECONDS);
|
||||
/* RSA_blinding_on(rsa_key[j],NULL); */
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(rsa_c[j][0]); count++)
|
||||
if (ret == 0)
|
||||
{
|
||||
ret=RSA_sign(NID_md5_sha1, buf,36, buf2, &rsa_num,
|
||||
rsa_key[j]);
|
||||
if (ret <= 0)
|
||||
{
|
||||
BIO_printf(bio_err,"RSA private encrypt failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
BIO_printf(bio_err,"RSA sign failure. No RSA sign will be done.\n");
|
||||
ERR_print_errors(bio_err);
|
||||
rsa_count=1;
|
||||
}
|
||||
else
|
||||
{
|
||||
pkey_print_message("private","rsa",
|
||||
rsa_c[j][0],rsa_bits[j],
|
||||
RSA_SECONDS);
|
||||
/* RSA_blinding_on(rsa_key[j],NULL); */
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(rsa_c[j][0]); count++)
|
||||
{
|
||||
ret=RSA_sign(NID_md5_sha1, buf,36, buf2,
|
||||
&rsa_num, rsa_key[j]);
|
||||
if (ret == 0)
|
||||
{
|
||||
BIO_printf(bio_err,
|
||||
"RSA sign failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,
|
||||
"%ld %d bit private RSA's in %.2fs\n",
|
||||
count,rsa_bits[j],d);
|
||||
rsa_results[j][0]=d/(double)count;
|
||||
rsa_count=count;
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,"%ld %d bit private RSA's in %.2fs\n",
|
||||
count,rsa_bits[j],d);
|
||||
rsa_results[j][0]=d/(double)count;
|
||||
rsa_count=count;
|
||||
|
||||
#if 1
|
||||
ret=RSA_verify(NID_md5_sha1, buf,36, buf2, rsa_num, rsa_key[j]);
|
||||
pkey_print_message("public","rsa",rsa_c[j][1],rsa_bits[j],
|
||||
RSA_SECONDS);
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(rsa_c[j][1]); count++)
|
||||
if (ret <= 0)
|
||||
{
|
||||
ret=RSA_verify(NID_md5_sha1, buf,36, buf2, rsa_num,
|
||||
rsa_key[j]);
|
||||
if (ret <= 0)
|
||||
{
|
||||
BIO_printf(bio_err,"RSA verify failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
BIO_printf(bio_err,"RSA verify failure. No RSA verify will be done.\n");
|
||||
ERR_print_errors(bio_err);
|
||||
rsa_doit[j] = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
pkey_print_message("public","rsa",
|
||||
rsa_c[j][1],rsa_bits[j],
|
||||
RSA_SECONDS);
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(rsa_c[j][1]); count++)
|
||||
{
|
||||
ret=RSA_verify(NID_md5_sha1, buf,36, buf2,
|
||||
rsa_num, rsa_key[j]);
|
||||
if (ret == 0)
|
||||
{
|
||||
BIO_printf(bio_err,
|
||||
"RSA verify failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,
|
||||
"%ld %d bit public RSA's in %.2fs\n",
|
||||
count,rsa_bits[j],d);
|
||||
rsa_results[j][1]=d/(double)count;
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,"%ld %d bit public RSA's in %.2fs\n",
|
||||
count,rsa_bits[j],d);
|
||||
rsa_results[j][1]=d/(double)count;
|
||||
#endif
|
||||
|
||||
if (rsa_count <= 1)
|
||||
@@ -1231,54 +1257,77 @@ int MAIN(int argc, char **argv)
|
||||
for (j=0; j<DSA_NUM; j++)
|
||||
{
|
||||
unsigned int kk;
|
||||
int ret;
|
||||
|
||||
if (!dsa_doit[j]) continue;
|
||||
DSA_generate_key(dsa_key[j]);
|
||||
/* DSA_sign_setup(dsa_key[j],NULL); */
|
||||
rsa_num=DSA_sign(EVP_PKEY_DSA,buf,20,buf2,
|
||||
ret=DSA_sign(EVP_PKEY_DSA,buf,20,buf2,
|
||||
&kk,dsa_key[j]);
|
||||
pkey_print_message("sign","dsa",dsa_c[j][0],dsa_bits[j],
|
||||
DSA_SECONDS);
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(dsa_c[j][0]); count++)
|
||||
if (ret == 0)
|
||||
{
|
||||
rsa_num=DSA_sign(EVP_PKEY_DSA,buf,20,buf2,
|
||||
&kk,dsa_key[j]);
|
||||
if (rsa_num == 0)
|
||||
{
|
||||
BIO_printf(bio_err,"DSA sign failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
BIO_printf(bio_err,"DSA sign failure. No DSA sign will be done.\n");
|
||||
ERR_print_errors(bio_err);
|
||||
rsa_count=1;
|
||||
}
|
||||
else
|
||||
{
|
||||
pkey_print_message("sign","dsa",
|
||||
dsa_c[j][0],dsa_bits[j],
|
||||
DSA_SECONDS);
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(dsa_c[j][0]); count++)
|
||||
{
|
||||
ret=DSA_sign(EVP_PKEY_DSA,buf,20,buf2,
|
||||
&kk,dsa_key[j]);
|
||||
if (ret == 0)
|
||||
{
|
||||
BIO_printf(bio_err,
|
||||
"DSA sign failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,"%ld %d bit DSA signs in %.2fs\n",
|
||||
count,dsa_bits[j],d);
|
||||
dsa_results[j][0]=d/(double)count;
|
||||
rsa_count=count;
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,"%ld %d bit DSA signs in %.2fs\n",
|
||||
count,dsa_bits[j],d);
|
||||
dsa_results[j][0]=d/(double)count;
|
||||
rsa_count=count;
|
||||
|
||||
rsa_num2=DSA_verify(EVP_PKEY_DSA,buf,20,buf2,
|
||||
ret=DSA_verify(EVP_PKEY_DSA,buf,20,buf2,
|
||||
kk,dsa_key[j]);
|
||||
pkey_print_message("verify","dsa",dsa_c[j][1],dsa_bits[j],
|
||||
DSA_SECONDS);
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(dsa_c[j][1]); count++)
|
||||
if (ret <= 0)
|
||||
{
|
||||
rsa_num2=DSA_verify(EVP_PKEY_DSA,buf,20,buf2,
|
||||
kk,dsa_key[j]);
|
||||
if (rsa_num2 == 0)
|
||||
{
|
||||
BIO_printf(bio_err,"DSA verify failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
BIO_printf(bio_err,"DSA verify failure. No DSA verify will be done.\n");
|
||||
ERR_print_errors(bio_err);
|
||||
dsa_doit[j] = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
pkey_print_message("verify","dsa",
|
||||
dsa_c[j][1],dsa_bits[j],
|
||||
DSA_SECONDS);
|
||||
Time_F(START,usertime);
|
||||
for (count=0,run=1; COND(dsa_c[j][1]); count++)
|
||||
{
|
||||
ret=DSA_verify(EVP_PKEY_DSA,buf,20,buf2,
|
||||
kk,dsa_key[j]);
|
||||
if (ret <= 0)
|
||||
{
|
||||
BIO_printf(bio_err,
|
||||
"DSA verify failure\n");
|
||||
ERR_print_errors(bio_err);
|
||||
count=1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,"%ld %d bit DSA verify in %.2fs\n",
|
||||
count,dsa_bits[j],d);
|
||||
dsa_results[j][1]=d/(double)count;
|
||||
}
|
||||
d=Time_F(STOP,usertime);
|
||||
BIO_printf(bio_err,"%ld %d bit DSA verify in %.2fs\n",
|
||||
count,dsa_bits[j],d);
|
||||
dsa_results[j][1]=d/(double)count;
|
||||
|
||||
if (rsa_count <= 1)
|
||||
{
|
||||
|
22
apps/spkac.c
22
apps/spkac.c
@@ -219,7 +219,15 @@ bad:
|
||||
spkstr = NETSCAPE_SPKI_b64_encode(spki);
|
||||
|
||||
if (outfile) out = BIO_new_file(outfile, "w");
|
||||
else out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
else {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
if(!out) {
|
||||
BIO_printf(bio_err, "Error opening output file\n");
|
||||
@@ -268,7 +276,15 @@ bad:
|
||||
}
|
||||
|
||||
if (outfile) out = BIO_new_file(outfile, "w");
|
||||
else out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
else {
|
||||
out = BIO_new_fp(stdout, BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
if(!out) {
|
||||
BIO_printf(bio_err, "Error opening output file\n");
|
||||
@@ -295,7 +311,7 @@ end:
|
||||
CONF_free(conf);
|
||||
NETSCAPE_SPKI_free(spki);
|
||||
BIO_free(in);
|
||||
BIO_free(out);
|
||||
BIO_free_all(out);
|
||||
BIO_free(key);
|
||||
EVP_PKEY_free(pkey);
|
||||
if(passin) OPENSSL_free(passin);
|
||||
|
20
apps/x509.c
20
apps/x509.c
@@ -187,6 +187,12 @@ int MAIN(int argc, char **argv)
|
||||
if (bio_err == NULL)
|
||||
bio_err=BIO_new_fp(stderr,BIO_NOCLOSE);
|
||||
STDout=BIO_new_fp(stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
STDout = BIO_push(tmpbio, STDout);
|
||||
}
|
||||
#endif
|
||||
|
||||
informat=FORMAT_PEM;
|
||||
outformat=FORMAT_PEM;
|
||||
@@ -603,7 +609,15 @@ bad:
|
||||
goto end;
|
||||
}
|
||||
if (outfile == NULL)
|
||||
{
|
||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||
#ifdef VMS
|
||||
{
|
||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||
out = BIO_push(tmpbio, out);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
if (BIO_write_filename(out,outfile) <= 0)
|
||||
@@ -880,8 +894,10 @@ bad:
|
||||
|
||||
BIO_printf(bio_err,"Generating certificate request\n");
|
||||
|
||||
#ifndef NO_DSA
|
||||
if (pk->type == EVP_PKEY_DSA)
|
||||
digest=EVP_dss1();
|
||||
#endif
|
||||
|
||||
rq=X509_to_X509_REQ(x,pk,digest);
|
||||
EVP_PKEY_free(pk);
|
||||
@@ -960,8 +976,8 @@ end:
|
||||
app_RAND_write_file(NULL, bio_err);
|
||||
OBJ_cleanup();
|
||||
CONF_free(extconf);
|
||||
BIO_free(out);
|
||||
BIO_free(STDout);
|
||||
BIO_free_all(out);
|
||||
BIO_free_all(STDout);
|
||||
X509_STORE_free(ctx);
|
||||
X509_REQ_free(req);
|
||||
X509_free(x);
|
||||
|
59
config
59
config
@@ -49,10 +49,18 @@ if [ "x$XREL" != "x" ]; then
|
||||
echo "whatever-whatever-sco5"; exit 0
|
||||
;;
|
||||
4.2MP)
|
||||
if [ "x$VERSION" = "x2.1.1" ]; then
|
||||
if [ "x$VERSION" = "x2.01" ]; then
|
||||
echo "${MACHINE}-whatever-unixware201"; exit 0
|
||||
elif [ "x$VERSION" = "x2.02" ]; then
|
||||
echo "${MACHINE}-whatever-unixware202"; exit 0
|
||||
elif [ "x$VERSION" = "x2.03" ]; then
|
||||
echo "${MACHINE}-whatever-unixware203"; exit 0
|
||||
elif [ "x$VERSION" = "x2.1.1" ]; then
|
||||
echo "${MACHINE}-whatever-unixware211"; exit 0
|
||||
elif [ "x$VERSION" = "x2.1.2" ]; then
|
||||
echo "${MACHINE}-whatever-unixware212"; exit 0
|
||||
elif [ "x$VERSION" = "x2.1.3" ]; then
|
||||
echo "${MACHINE}-whatever-unixware213"; exit 0
|
||||
else
|
||||
echo "${MACHINE}-whatever-unixware2"; exit 0
|
||||
fi
|
||||
@@ -71,10 +79,22 @@ fi
|
||||
# Now we simply scan though... In most cases, the SYSTEM info is enough
|
||||
#
|
||||
case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
||||
MPE/iX:*)
|
||||
MACHINE=`echo "$MACHINE" | sed -e 's/-/_/g'`
|
||||
echo "parisc-hp-MPE/iX"; exit 0
|
||||
;;
|
||||
A/UX:*)
|
||||
echo "m68k-apple-aux3"; exit 0
|
||||
;;
|
||||
|
||||
AIX:[3456789]:4:*)
|
||||
echo "${MACHINE}-ibm-aix43"; exit 0
|
||||
;;
|
||||
|
||||
AIX:*:[56789]:*)
|
||||
echo "${MACHINE}-ibm-aix43"; exit 0
|
||||
;;
|
||||
|
||||
AIX:*)
|
||||
echo "${MACHINE}-ibm-aix"; exit 0
|
||||
;;
|
||||
@@ -164,7 +184,7 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
||||
;;
|
||||
|
||||
NetBSD:*:*:*386*)
|
||||
echo "`/usr/sbin/sysctl -n hw.model | sed 's,.*\(.\)86-class.*,i\186,'`-whatever-netbsd"; exit 0
|
||||
echo "`(/usr/sbin/sysctl -n hw.model || /sbin/sysctl -n hw.model) | sed 's,.*\(.\)86-class.*,i\186,'`-whatever-netbsd"; exit 0
|
||||
;;
|
||||
|
||||
NetBSD:*)
|
||||
@@ -247,6 +267,10 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
||||
echo "${MACHINE}-v11-${SYSTEM}"; exit 0;
|
||||
;;
|
||||
|
||||
NEWS-OS:4.*)
|
||||
echo "mips-sony-newsos4"; exit 0;
|
||||
;;
|
||||
|
||||
esac
|
||||
|
||||
#
|
||||
@@ -385,10 +409,16 @@ case "$GUESSOS" in
|
||||
;;
|
||||
mips4-sgi-irix64)
|
||||
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
||||
echo " invoke './Configre irix64-mips4-$CC' *manually*."
|
||||
echo " Type Ctrl-C if you don't want to continue."
|
||||
echo " invoke './Configure irix64-mips4-$CC' *manually*."
|
||||
echo " Type return if you want to continue, Ctrl-C to abort."
|
||||
read waste < /dev/tty
|
||||
options="$options -mips4"
|
||||
CPU=`(hinv -t cpu) 2>/dev/null | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
||||
CPU=${CPU:-0}
|
||||
if [ $CPU -ge 5000 ]; then
|
||||
options="$options -mips4"
|
||||
else
|
||||
options="$options -mips3"
|
||||
fi
|
||||
OUT="irix-mips3-$CC"
|
||||
;;
|
||||
alpha-*-linux2)
|
||||
@@ -415,11 +445,11 @@ case "$GUESSOS" in
|
||||
#till 64-bit glibc for SPARC is operational:-(
|
||||
#echo "WARNING! If you wish to build 64-bit library, then you have to"
|
||||
#echo " invoke './Configure linux64-sparcv9' *manually*."
|
||||
#echo " Type Ctrl-C if you don't want to continue."
|
||||
#echo " Type return if you want to continue, Ctrl-C to abort."
|
||||
#read waste < /dev/tty
|
||||
OUT="linux-sparcv9" ;;
|
||||
sparc-*-linux2)
|
||||
KARCH=`awk '/type/{print$3}' /proc/cpuinfo`
|
||||
KARCH=`awk '/^type/{print$3}' /proc/cpuinfo`
|
||||
case ${KARCH:-sun4} in
|
||||
sun4u*) OUT="linux-sparcv9" ;;
|
||||
sun4m) OUT="linux-sparcv8" ;;
|
||||
@@ -427,6 +457,7 @@ case "$GUESSOS" in
|
||||
*) OUT="linux-sparcv7" ;;
|
||||
esac ;;
|
||||
arm*-*-linux2) OUT="linux-elf-arm" ;;
|
||||
s390-*-linux2) OUT="linux-s390" ;;
|
||||
*-*-linux2) OUT="linux-elf" ;;
|
||||
*-*-linux1) OUT="linux-aout" ;;
|
||||
sun4u*-*-solaris2)
|
||||
@@ -434,7 +465,7 @@ case "$GUESSOS" in
|
||||
if [ "$ISA64" != "" -a "$CC" = "cc" -a $CCVER -ge 50 ]; then
|
||||
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
||||
echo " invoke './Configure solaris64-sparcv9-cc' *manually*."
|
||||
echo " Type Ctrl-C if you don't want to continue."
|
||||
echo " Type return if you want to continue, Ctrl-C to abort."
|
||||
read waste < /dev/tty
|
||||
fi
|
||||
OUT="solaris-sparcv9-$CC" ;;
|
||||
@@ -458,9 +489,12 @@ case "$GUESSOS" in
|
||||
*-*-unixware7) OUT="unixware-7" ;;
|
||||
*-*-UnixWare7) OUT="unixware-7" ;;
|
||||
*-*-Unixware7) OUT="unixware-7" ;;
|
||||
*-*-unixware[1-2]*) OUT="unixware-2.0" ;;
|
||||
*-*-UnixWare[1-2]*) OUT="unixware-2.0" ;;
|
||||
*-*-Unixware[1-2]*) OUT="unixware-2.0" ;;
|
||||
*-*-unixware20*) OUT="unixware-2.0" ;;
|
||||
*-*-unixware21*) OUT="unixware-2.1" ;;
|
||||
*-*-UnixWare20*) OUT="unixware-2.0" ;;
|
||||
*-*-UnixWare21*) OUT="unixware-2.1" ;;
|
||||
*-*-Unixware20*) OUT="unixware-2.0" ;;
|
||||
*-*-Unixware21*) OUT="unixware-2.1" ;;
|
||||
BS2000-siemens-sysv4) OUT="BS2000-OSD" ;;
|
||||
RM*-siemens-sysv4) OUT="ReliantUNIX" ;;
|
||||
*-siemens-sysv4) OUT="SINIX" ;;
|
||||
@@ -470,6 +504,7 @@ case "$GUESSOS" in
|
||||
# these are all covered by the catchall below
|
||||
# *-aix) OUT="aix-$CC" ;;
|
||||
# *-dgux) OUT="dgux" ;;
|
||||
mips-sony-newsos4) OUT="newsos4-gcc" ;;
|
||||
*) OUT=`echo $GUESSOS | awk -F- '{print $3}'`;;
|
||||
esac
|
||||
|
||||
@@ -564,7 +599,7 @@ OUT="$PREFIX$OUT"
|
||||
|
||||
$PERL ./Configure LIST | grep "$OUT" > /dev/null
|
||||
if [ $? = "0" ]; then
|
||||
#echo Configuring for $OUT
|
||||
echo Configuring for $OUT
|
||||
|
||||
if [ "$TEST" = "true" ]; then
|
||||
echo $PERL ./Configure $OUT $options
|
||||
|
@@ -34,8 +34,8 @@ SDIRS= md2 md5 sha mdc2 hmac ripemd \
|
||||
GENERAL=Makefile README crypto-lib.com install.com
|
||||
|
||||
LIB= $(TOP)/libcrypto.a
|
||||
LIBSRC= cryptlib.c mem.c mem_dbg.c cversion.c ex_data.c tmdiff.c cpt_err.c ebcdic.c
|
||||
LIBOBJ= cryptlib.o mem.o mem_dbg.o cversion.o ex_data.o tmdiff.o cpt_err.o ebcdic.o
|
||||
LIBSRC= cryptlib.c mem.c mem_dbg.c cversion.c ex_data.c tmdiff.c cpt_err.c ebcdic.c uid.c
|
||||
LIBOBJ= cryptlib.o mem.o mem_dbg.o cversion.o ex_data.o tmdiff.o cpt_err.o ebcdic.o uid.o
|
||||
|
||||
SRC= $(LIBSRC)
|
||||
|
||||
@@ -90,7 +90,8 @@ links:
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
libs:
|
||||
@@ -197,3 +198,6 @@ tmdiff.o: ../include/openssl/lhash.h ../include/openssl/opensslconf.h
|
||||
tmdiff.o: ../include/openssl/opensslv.h ../include/openssl/safestack.h
|
||||
tmdiff.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||
tmdiff.o: ../include/openssl/tmdiff.h cryptlib.h
|
||||
uid.o: ../include/openssl/crypto.h ../include/openssl/opensslv.h
|
||||
uid.o: ../include/openssl/safestack.h ../include/openssl/stack.h
|
||||
uid.o: ../include/openssl/symhacks.h
|
||||
|
@@ -75,7 +75,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
files:
|
||||
|
@@ -158,7 +158,7 @@ STACK *d2i_ASN1_SET(STACK **a, unsigned char **pp, long length,
|
||||
STACK *ret=NULL;
|
||||
|
||||
if ((a == NULL) || ((*a) == NULL))
|
||||
{ if ((ret=sk_new(NULL)) == NULL) goto err; }
|
||||
{ if ((ret=sk_new_null()) == NULL) goto err; }
|
||||
else
|
||||
ret=(*a);
|
||||
|
||||
|
@@ -133,7 +133,7 @@ ASN1_STRING *ASN1_STRING_set_by_NID(ASN1_STRING **out, const unsigned char *in,
|
||||
if(tbl) {
|
||||
mask = tbl->mask;
|
||||
if(!(tbl->flags & STABLE_NO_MASK)) mask &= global_mask;
|
||||
ret = ASN1_mbstring_ncopy(out, in, inlen, inform, tbl->mask,
|
||||
ret = ASN1_mbstring_ncopy(out, in, inlen, inform, mask,
|
||||
tbl->minsize, tbl->maxsize);
|
||||
} else ret = ASN1_mbstring_copy(out, in, inlen, inform, DIRSTRING_TYPE & global_mask);
|
||||
if(ret <= 0) return NULL;
|
||||
|
@@ -123,6 +123,8 @@ int i2d_ASN1_TYPE(ASN1_TYPE *a, unsigned char **pp)
|
||||
break;
|
||||
case V_ASN1_SET:
|
||||
case V_ASN1_SEQUENCE:
|
||||
case V_ASN1_OTHER:
|
||||
default:
|
||||
if (a->value.set == NULL)
|
||||
r=0;
|
||||
else
|
||||
@@ -159,6 +161,8 @@ ASN1_TYPE *d2i_ASN1_TYPE(ASN1_TYPE **a, unsigned char **pp, long length)
|
||||
|
||||
inf=ASN1_get_object(&q,&len,&tag,&xclass,length);
|
||||
if (inf & 0x80) goto err;
|
||||
/* If not universal tag we've no idea what it is */
|
||||
if(xclass != V_ASN1_UNIVERSAL) tag = V_ASN1_OTHER;
|
||||
|
||||
ASN1_TYPE_component_free(ret);
|
||||
|
||||
@@ -245,6 +249,8 @@ ASN1_TYPE *d2i_ASN1_TYPE(ASN1_TYPE **a, unsigned char **pp, long length)
|
||||
break;
|
||||
case V_ASN1_SET:
|
||||
case V_ASN1_SEQUENCE:
|
||||
case V_ASN1_OTHER:
|
||||
default:
|
||||
/* Sets and sequences are left complete */
|
||||
if ((ret->value.set=ASN1_STRING_new()) == NULL) goto err;
|
||||
ret->value.set->type=tag;
|
||||
@@ -252,9 +258,6 @@ ASN1_TYPE *d2i_ASN1_TYPE(ASN1_TYPE **a, unsigned char **pp, long length)
|
||||
if (!ASN1_STRING_set(ret->value.set,p,(int)len)) goto err;
|
||||
p+=len;
|
||||
break;
|
||||
default:
|
||||
ASN1err(ASN1_F_D2I_ASN1_TYPE,ASN1_R_BAD_TYPE);
|
||||
goto err;
|
||||
}
|
||||
|
||||
ret->type=tag;
|
||||
@@ -312,6 +315,8 @@ static void ASN1_TYPE_component_free(ASN1_TYPE *a)
|
||||
case V_ASN1_OBJECT:
|
||||
ASN1_OBJECT_free(a->value.object);
|
||||
break;
|
||||
case V_ASN1_NULL:
|
||||
break;
|
||||
case V_ASN1_INTEGER:
|
||||
case V_ASN1_NEG_INTEGER:
|
||||
case V_ASN1_ENUMERATED:
|
||||
@@ -333,10 +338,9 @@ static void ASN1_TYPE_component_free(ASN1_TYPE *a)
|
||||
case V_ASN1_UNIVERSALSTRING:
|
||||
case V_ASN1_BMPSTRING:
|
||||
case V_ASN1_UTF8STRING:
|
||||
ASN1_STRING_free((ASN1_STRING *)a->value.ptr);
|
||||
break;
|
||||
case V_ASN1_OTHER:
|
||||
default:
|
||||
/* MEMORY LEAK */
|
||||
ASN1_STRING_free((ASN1_STRING *)a->value.ptr);
|
||||
break;
|
||||
}
|
||||
a->type=0;
|
||||
|
@@ -83,6 +83,7 @@ extern "C" {
|
||||
#define V_ASN1_PRIMATIVE_TAG 0x1f
|
||||
|
||||
#define V_ASN1_APP_CHOOSE -2 /* let the recipient choose */
|
||||
#define V_ASN1_OTHER -3 /* used in ASN1_TYPE */
|
||||
|
||||
#define V_ASN1_NEG 0x100 /* negative flag */
|
||||
|
||||
|
@@ -301,7 +301,7 @@ int asn1_GetSequence(ASN1_CTX *c, long *length)
|
||||
return(0);
|
||||
}
|
||||
if (c->inf == (1|V_ASN1_CONSTRUCTED))
|
||||
c->slen= *length+ *(c->pp)-c->p;
|
||||
c->slen= *length;
|
||||
c->eos=0;
|
||||
return(1);
|
||||
}
|
||||
|
@@ -196,6 +196,9 @@ err:\
|
||||
if ((a != NULL) && (sk_##type##_num(a) != 0)) \
|
||||
M_ASN1_I2D_put_SEQUENCE_type(type,a,f);
|
||||
|
||||
#define M_ASN1_I2D_put_SEQUENCE_opt_ex_type(type,a,f) \
|
||||
if (a) M_ASN1_I2D_put_SEQUENCE_type(type,a,f);
|
||||
|
||||
#define M_ASN1_D2I_get_IMP_set_opt(b,func,free_func,tag) \
|
||||
if ((c.slen != 0) && \
|
||||
(M_ASN1_next == \
|
||||
@@ -389,6 +392,9 @@ err:\
|
||||
if ((a != NULL) && (sk_##type##_num(a) != 0)) \
|
||||
M_ASN1_I2D_len_SEQUENCE_type(type,a,f);
|
||||
|
||||
#define M_ASN1_I2D_len_SEQUENCE_opt_ex_type(type,a,f) \
|
||||
if (a) M_ASN1_I2D_len_SEQUENCE_type(type,a,f);
|
||||
|
||||
#define M_ASN1_I2D_len_IMP_SET(a,f,x) \
|
||||
ret+=i2d_ASN1_SET(a,NULL,f,x,V_ASN1_CONTEXT_SPECIFIC,IS_SET);
|
||||
|
||||
@@ -452,6 +458,15 @@ err:\
|
||||
ret+=ASN1_object_size(1,v,mtag); \
|
||||
}
|
||||
|
||||
#define M_ASN1_I2D_len_EXP_SEQUENCE_opt_ex_type(type,a,f,mtag,tag,v) \
|
||||
if (a)\
|
||||
{ \
|
||||
v=i2d_ASN1_SET_OF_##type(a,NULL,f,tag, \
|
||||
V_ASN1_UNIVERSAL, \
|
||||
IS_SEQUENCE); \
|
||||
ret+=ASN1_object_size(1,v,mtag); \
|
||||
}
|
||||
|
||||
/* Put Macros */
|
||||
#define M_ASN1_I2D_put(a,f) f(a,&p)
|
||||
|
||||
@@ -536,6 +551,14 @@ err:\
|
||||
IS_SEQUENCE); \
|
||||
}
|
||||
|
||||
#define M_ASN1_I2D_put_EXP_SEQUENCE_opt_ex_type(type,a,f,mtag,tag,v) \
|
||||
if (a) \
|
||||
{ \
|
||||
ASN1_put_object(&p,1,v,mtag,V_ASN1_CONTEXT_SPECIFIC); \
|
||||
i2d_ASN1_SET_OF_##type(a,&p,f,tag,V_ASN1_UNIVERSAL, \
|
||||
IS_SEQUENCE); \
|
||||
}
|
||||
|
||||
#define M_ASN1_I2D_seq_total() \
|
||||
r=ASN1_object_size(1,ret,V_ASN1_SEQUENCE); \
|
||||
if (pp == NULL) return(r); \
|
||||
|
@@ -307,12 +307,14 @@ PKCS7 *d2i_PKCS7(PKCS7 **a, unsigned char **pp, long length)
|
||||
}
|
||||
if (Tinf == (1|V_ASN1_CONSTRUCTED))
|
||||
{
|
||||
c.q=c.p;
|
||||
if (!ASN1_check_infinite_end(&c.p,c.slen))
|
||||
{
|
||||
c.error=ERR_R_MISSING_ASN1_EOS;
|
||||
c.line=__LINE__;
|
||||
goto err;
|
||||
}
|
||||
c.slen-=(c.p-c.q);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@@ -349,6 +349,8 @@ int X509_NAME_print(BIO *bp, X509_NAME *name, int obase)
|
||||
ll=80-2-obase;
|
||||
|
||||
s=X509_NAME_oneline(name,buf,256);
|
||||
if (!*s)
|
||||
return 1;
|
||||
s++; /* skip the first slash */
|
||||
|
||||
l=ll;
|
||||
|
@@ -71,14 +71,14 @@ int i2d_X509_REVOKED(X509_REVOKED *a, unsigned char **pp)
|
||||
|
||||
M_ASN1_I2D_len(a->serialNumber,i2d_ASN1_INTEGER);
|
||||
M_ASN1_I2D_len(a->revocationDate,i2d_ASN1_TIME);
|
||||
M_ASN1_I2D_len_SEQUENCE_opt_type(X509_EXTENSION,a->extensions,
|
||||
M_ASN1_I2D_len_SEQUENCE_opt_ex_type(X509_EXTENSION,a->extensions,
|
||||
i2d_X509_EXTENSION);
|
||||
|
||||
M_ASN1_I2D_seq_total();
|
||||
|
||||
M_ASN1_I2D_put(a->serialNumber,i2d_ASN1_INTEGER);
|
||||
M_ASN1_I2D_put(a->revocationDate,i2d_ASN1_TIME);
|
||||
M_ASN1_I2D_put_SEQUENCE_opt_type(X509_EXTENSION,a->extensions,
|
||||
M_ASN1_I2D_put_SEQUENCE_opt_ex_type(X509_EXTENSION,a->extensions,
|
||||
i2d_X509_EXTENSION);
|
||||
|
||||
M_ASN1_I2D_finish();
|
||||
@@ -121,7 +121,7 @@ int i2d_X509_CRL_INFO(X509_CRL_INFO *a, unsigned char **pp)
|
||||
{ M_ASN1_I2D_len(a->nextUpdate,i2d_ASN1_TIME); }
|
||||
M_ASN1_I2D_len_SEQUENCE_opt_type(X509_REVOKED,a->revoked,
|
||||
i2d_X509_REVOKED);
|
||||
M_ASN1_I2D_len_EXP_SEQUENCE_opt_type(X509_EXTENSION,a->extensions,
|
||||
M_ASN1_I2D_len_EXP_SEQUENCE_opt_ex_type(X509_EXTENSION,a->extensions,
|
||||
i2d_X509_EXTENSION,0,
|
||||
V_ASN1_SEQUENCE,v1);
|
||||
|
||||
@@ -138,7 +138,7 @@ int i2d_X509_CRL_INFO(X509_CRL_INFO *a, unsigned char **pp)
|
||||
{ M_ASN1_I2D_put(a->nextUpdate,i2d_ASN1_TIME); }
|
||||
M_ASN1_I2D_put_SEQUENCE_opt_type(X509_REVOKED,a->revoked,
|
||||
i2d_X509_REVOKED);
|
||||
M_ASN1_I2D_put_EXP_SEQUENCE_opt_type(X509_EXTENSION,a->extensions,
|
||||
M_ASN1_I2D_put_EXP_SEQUENCE_opt_ex_type(X509_EXTENSION,a->extensions,
|
||||
i2d_X509_EXTENSION,0,
|
||||
V_ASN1_SEQUENCE,v1);
|
||||
|
||||
@@ -260,7 +260,7 @@ X509_CRL_INFO *X509_CRL_INFO_new(void)
|
||||
M_ASN1_New(ret->lastUpdate,M_ASN1_UTCTIME_new);
|
||||
ret->nextUpdate=NULL;
|
||||
M_ASN1_New(ret->revoked,sk_X509_REVOKED_new_null);
|
||||
M_ASN1_New(ret->extensions,sk_X509_EXTENSION_new_null);
|
||||
ret->extensions = NULL;
|
||||
sk_X509_REVOKED_set_cmp_func(ret->revoked,X509_REVOKED_cmp);
|
||||
return(ret);
|
||||
M_ASN1_New_Error(ASN1_F_X509_CRL_INFO_NEW);
|
||||
|
@@ -141,10 +141,12 @@ static int i2d_X509_NAME_entries(X509_NAME *a)
|
||||
}
|
||||
size+=i2d_X509_NAME_ENTRY(ne,NULL);
|
||||
}
|
||||
|
||||
ret+=ASN1_object_size(1,size,V_ASN1_SET);
|
||||
if (fe != NULL)
|
||||
{
|
||||
/* SET OF needed only if entries is non empty */
|
||||
ret+=ASN1_object_size(1,size,V_ASN1_SET);
|
||||
fe->size=size;
|
||||
}
|
||||
|
||||
r=ASN1_object_size(1,ret,V_ASN1_SEQUENCE);
|
||||
|
||||
|
@@ -234,7 +234,7 @@ EVP_PKEY *X509_PUBKEY_get(X509_PUBKEY *key)
|
||||
a=key->algor;
|
||||
if (ret->type == EVP_PKEY_DSA)
|
||||
{
|
||||
if (a->parameter->type == V_ASN1_SEQUENCE)
|
||||
if (a->parameter && (a->parameter->type == V_ASN1_SEQUENCE))
|
||||
{
|
||||
ret->pkey.dsa->write_params=0;
|
||||
p=a->parameter->value.sequence->data;
|
||||
|
@@ -44,7 +44,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
# elf
|
||||
|
@@ -27,11 +27,13 @@ LIBSRC= bio_lib.c bio_cb.c bio_err.c \
|
||||
bss_file.c bss_sock.c bss_conn.c \
|
||||
bf_null.c bf_buff.c b_print.c b_dump.c \
|
||||
b_sock.c bss_acpt.c bf_nbio.c bss_log.c bss_bio.c
|
||||
# bf_lbuf.c
|
||||
LIBOBJ= bio_lib.o bio_cb.o bio_err.o \
|
||||
bss_mem.o bss_null.o bss_fd.o \
|
||||
bss_file.o bss_sock.o bss_conn.o \
|
||||
bf_null.o bf_buff.o b_print.o b_dump.o \
|
||||
b_sock.o bss_acpt.o bf_nbio.o bss_log.o bss_bio.o
|
||||
# bf_lbuf.o
|
||||
|
||||
SRC= $(LIBSRC)
|
||||
|
||||
@@ -47,7 +49,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
files:
|
||||
@@ -93,13 +96,13 @@ b_dump.o: ../../include/openssl/lhash.h ../../include/openssl/opensslconf.h
|
||||
b_dump.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h
|
||||
b_dump.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
|
||||
b_dump.o: ../cryptlib.h
|
||||
b_print.o: ../../include/openssl/bio.h ../../include/openssl/buffer.h
|
||||
b_print.o: ../../include/openssl/crypto.h ../../include/openssl/e_os.h
|
||||
b_print.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
|
||||
b_print.o: ../../include/openssl/lhash.h ../../include/openssl/opensslconf.h
|
||||
b_print.o: ../../include/openssl/opensslv.h ../../include/openssl/safestack.h
|
||||
b_print.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
|
||||
b_print.o: ../cryptlib.h
|
||||
b_print.o: ../../include/openssl/bio.h ../../include/openssl/bn.h
|
||||
b_print.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h
|
||||
b_print.o: ../../include/openssl/e_os.h ../../include/openssl/e_os2.h
|
||||
b_print.o: ../../include/openssl/err.h ../../include/openssl/lhash.h
|
||||
b_print.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h
|
||||
b_print.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
|
||||
b_print.o: ../../include/openssl/symhacks.h ../cryptlib.h
|
||||
b_sock.o: ../../include/openssl/bio.h ../../include/openssl/buffer.h
|
||||
b_sock.o: ../../include/openssl/crypto.h ../../include/openssl/e_os.h
|
||||
b_sock.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
|
||||
|
@@ -69,6 +69,7 @@
|
||||
#ifndef NO_SYS_TYPES_H
|
||||
#include <sys/types.h>
|
||||
#endif
|
||||
#include <openssl/bn.h> /* To get BN_LLONG properly defined */
|
||||
#include <openssl/bio.h>
|
||||
|
||||
#ifdef BN_LLONG
|
||||
@@ -108,7 +109,11 @@
|
||||
#endif
|
||||
|
||||
#if HAVE_LONG_LONG
|
||||
#define LLONG long long
|
||||
# if defined(WIN32) && !defined(__GNUC__)
|
||||
# define LLONG _int64
|
||||
# else
|
||||
# define LLONG long long
|
||||
# endif
|
||||
#else
|
||||
#define LLONG long
|
||||
#endif
|
||||
@@ -151,7 +156,7 @@ static void _dopr(char **sbuffer, char **buffer,
|
||||
|
||||
/* some handy macros */
|
||||
#define char_to_int(p) (p - '0')
|
||||
#define MAX(p,q) ((p >= q) ? p : q)
|
||||
#define OSSL_MAX(p,q) ((p >= q) ? p : q)
|
||||
|
||||
static void
|
||||
_dopr(
|
||||
@@ -502,13 +507,13 @@ fmtint(
|
||||
convert[place] = 0;
|
||||
|
||||
zpadlen = max - place;
|
||||
spadlen = min - MAX(max, place) - (signvalue ? 1 : 0);
|
||||
spadlen = min - OSSL_MAX(max, place) - (signvalue ? 1 : 0);
|
||||
if (zpadlen < 0)
|
||||
zpadlen = 0;
|
||||
if (spadlen < 0)
|
||||
spadlen = 0;
|
||||
if (flags & DP_F_ZERO) {
|
||||
zpadlen = MAX(zpadlen, spadlen);
|
||||
zpadlen = OSSL_MAX(zpadlen, spadlen);
|
||||
spadlen = 0;
|
||||
}
|
||||
if (flags & DP_F_MINUS)
|
||||
@@ -640,7 +645,7 @@ fmtfp(
|
||||
(caps ? "0123456789ABCDEF"
|
||||
: "0123456789abcdef")[fracpart % 10];
|
||||
fracpart = (fracpart / 10);
|
||||
} while (fracpart && (fplace < 20));
|
||||
} while (fplace < max);
|
||||
if (fplace == 20)
|
||||
fplace--;
|
||||
fconvert[fplace] = 0;
|
||||
|
@@ -113,8 +113,8 @@ int BIO_get_host_ip(const char *str, unsigned char *ip)
|
||||
|
||||
/* At this point, we have something that is most probably correct
|
||||
in some way, so let's init the socket. */
|
||||
if (!BIO_sock_init())
|
||||
return(0); /* don't generate another error code here */
|
||||
if (BIO_sock_init() != 1)
|
||||
return 0; /* don't generate another error code here */
|
||||
|
||||
/* If the string actually contained an IP address, we need not do
|
||||
anything more */
|
||||
@@ -519,15 +519,15 @@ int BIO_get_accept_socket(char *host, int bind_mode)
|
||||
{
|
||||
int ret=0;
|
||||
struct sockaddr_in server,client;
|
||||
int s= -1,cs;
|
||||
int s=INVALID_SOCKET,cs;
|
||||
unsigned char ip[4];
|
||||
unsigned short port;
|
||||
char *str,*e;
|
||||
char *str=NULL,*e;
|
||||
const char *h,*p;
|
||||
unsigned long l;
|
||||
int err_num;
|
||||
|
||||
if (!BIO_sock_init()) return(INVALID_SOCKET);
|
||||
if (BIO_sock_init() != 1) return(INVALID_SOCKET);
|
||||
|
||||
if ((str=BUF_strdup(host)) == NULL) return(INVALID_SOCKET);
|
||||
|
||||
@@ -553,7 +553,7 @@ int BIO_get_accept_socket(char *host, int bind_mode)
|
||||
h="*";
|
||||
}
|
||||
|
||||
if (!BIO_get_port(p,&port)) return(INVALID_SOCKET);
|
||||
if (!BIO_get_port(p,&port)) goto err;
|
||||
|
||||
memset((char *)&server,0,sizeof(server));
|
||||
server.sin_family=AF_INET;
|
||||
@@ -563,7 +563,7 @@ int BIO_get_accept_socket(char *host, int bind_mode)
|
||||
server.sin_addr.s_addr=INADDR_ANY;
|
||||
else
|
||||
{
|
||||
if (!BIO_get_host_ip(h,&(ip[0]))) return(INVALID_SOCKET);
|
||||
if (!BIO_get_host_ip(h,&(ip[0]))) goto err;
|
||||
l=(unsigned long)
|
||||
((unsigned long)ip[0]<<24L)|
|
||||
((unsigned long)ip[1]<<16L)|
|
||||
|
@@ -70,7 +70,7 @@ static long buffer_ctrl(BIO *h, int cmd, long arg1, void *arg2);
|
||||
static int buffer_new(BIO *h);
|
||||
static int buffer_free(BIO *data);
|
||||
static long buffer_callback_ctrl(BIO *h, int cmd, bio_info_cb *fp);
|
||||
#define DEFAULT_BUFFER_SIZE 1024
|
||||
#define DEFAULT_BUFFER_SIZE 4096
|
||||
|
||||
static BIO_METHOD methods_buffer=
|
||||
{
|
||||
|
397
crypto/bio/bf_lbuf.c
Normal file
397
crypto/bio/bf_lbuf.c
Normal file
@@ -0,0 +1,397 @@
|
||||
/* crypto/bio/bf_buff.c */
|
||||
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
|
||||
* All rights reserved.
|
||||
*
|
||||
* This package is an SSL implementation written
|
||||
* by Eric Young (eay@cryptsoft.com).
|
||||
* The implementation was written so as to conform with Netscapes SSL.
|
||||
*
|
||||
* This library is free for commercial and non-commercial use as long as
|
||||
* the following conditions are aheared to. The following conditions
|
||||
* apply to all code found in this distribution, be it the RC4, RSA,
|
||||
* lhash, DES, etc., code; not just the SSL code. The SSL documentation
|
||||
* included with this distribution is covered by the same copyright terms
|
||||
* except that the holder is Tim Hudson (tjh@cryptsoft.com).
|
||||
*
|
||||
* Copyright remains Eric Young's, and as such any Copyright notices in
|
||||
* the code are not to be removed.
|
||||
* If this package is used in a product, Eric Young should be given attribution
|
||||
* as the author of the parts of the library used.
|
||||
* This can be in the form of a textual message at program startup or
|
||||
* in documentation (online or textual) provided with the package.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
* 1. Redistributions of source code must retain the copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in the
|
||||
* documentation and/or other materials provided with the distribution.
|
||||
* 3. All advertising materials mentioning features or use of this software
|
||||
* must display the following acknowledgement:
|
||||
* "This product includes cryptographic software written by
|
||||
* Eric Young (eay@cryptsoft.com)"
|
||||
* The word 'cryptographic' can be left out if the rouines from the library
|
||||
* being used are not cryptographic related :-).
|
||||
* 4. If you include any Windows specific code (or a derivative thereof) from
|
||||
* the apps directory (application code) you must include an acknowledgement:
|
||||
* "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
|
||||
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* The licence and distribution terms for any publically available version or
|
||||
* derivative of this code cannot be changed. i.e. this code cannot simply be
|
||||
* copied and put under another distribution licence
|
||||
* [including the GNU Public Licence.]
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <errno.h>
|
||||
#include "cryptlib.h"
|
||||
#include <openssl/bio.h>
|
||||
#include <openssl/evp.h>
|
||||
|
||||
static int linebuffer_write(BIO *h, const char *buf,int num);
|
||||
static int linebuffer_read(BIO *h, char *buf, int size);
|
||||
static int linebuffer_puts(BIO *h, const char *str);
|
||||
static int linebuffer_gets(BIO *h, char *str, int size);
|
||||
static long linebuffer_ctrl(BIO *h, int cmd, long arg1, void *arg2);
|
||||
static int linebuffer_new(BIO *h);
|
||||
static int linebuffer_free(BIO *data);
|
||||
static long linebuffer_callback_ctrl(BIO *h, int cmd, bio_info_cb *fp);
|
||||
|
||||
/* A 10k maximum should be enough for most purposes */
|
||||
#define DEFAULT_LINEBUFFER_SIZE 1024*10
|
||||
|
||||
/* #define DEBUG */
|
||||
|
||||
static BIO_METHOD methods_linebuffer=
|
||||
{
|
||||
BIO_TYPE_LINEBUFFER,
|
||||
"linebuffer",
|
||||
linebuffer_write,
|
||||
linebuffer_read,
|
||||
linebuffer_puts,
|
||||
linebuffer_gets,
|
||||
linebuffer_ctrl,
|
||||
linebuffer_new,
|
||||
linebuffer_free,
|
||||
linebuffer_callback_ctrl,
|
||||
};
|
||||
|
||||
BIO_METHOD *BIO_f_linebuffer(void)
|
||||
{
|
||||
return(&methods_linebuffer);
|
||||
}
|
||||
|
||||
typedef struct bio_linebuffer_ctx_struct
|
||||
{
|
||||
char *obuf; /* the output char array */
|
||||
int obuf_size; /* how big is the output buffer */
|
||||
int obuf_len; /* how many bytes are in it */
|
||||
} BIO_LINEBUFFER_CTX;
|
||||
|
||||
static int linebuffer_new(BIO *bi)
|
||||
{
|
||||
BIO_LINEBUFFER_CTX *ctx;
|
||||
|
||||
ctx=(BIO_LINEBUFFER_CTX *)OPENSSL_malloc(sizeof(BIO_LINEBUFFER_CTX));
|
||||
if (ctx == NULL) return(0);
|
||||
ctx->obuf=(char *)OPENSSL_malloc(DEFAULT_LINEBUFFER_SIZE);
|
||||
if (ctx->obuf == NULL) { OPENSSL_free(ctx); return(0); }
|
||||
ctx->obuf_size=DEFAULT_LINEBUFFER_SIZE;
|
||||
ctx->obuf_len=0;
|
||||
|
||||
bi->init=1;
|
||||
bi->ptr=(char *)ctx;
|
||||
bi->flags=0;
|
||||
return(1);
|
||||
}
|
||||
|
||||
static int linebuffer_free(BIO *a)
|
||||
{
|
||||
BIO_LINEBUFFER_CTX *b;
|
||||
|
||||
if (a == NULL) return(0);
|
||||
b=(BIO_LINEBUFFER_CTX *)a->ptr;
|
||||
if (b->obuf != NULL) OPENSSL_free(b->obuf);
|
||||
OPENSSL_free(a->ptr);
|
||||
a->ptr=NULL;
|
||||
a->init=0;
|
||||
a->flags=0;
|
||||
return(1);
|
||||
}
|
||||
|
||||
static int linebuffer_read(BIO *b, char *out, int outl)
|
||||
{
|
||||
int ret=0;
|
||||
|
||||
if (out == NULL) return(0);
|
||||
if (b->next_bio == NULL) return(0);
|
||||
ret=BIO_read(b->next_bio,out,outl);
|
||||
BIO_clear_retry_flags(b);
|
||||
BIO_copy_next_retry(b);
|
||||
return(ret);
|
||||
}
|
||||
|
||||
static int linebuffer_write(BIO *b, const char *in, int inl)
|
||||
{
|
||||
int i,num=0,foundnl;
|
||||
BIO_LINEBUFFER_CTX *ctx;
|
||||
|
||||
if ((in == NULL) || (inl <= 0)) return(0);
|
||||
ctx=(BIO_LINEBUFFER_CTX *)b->ptr;
|
||||
if ((ctx == NULL) || (b->next_bio == NULL)) return(0);
|
||||
|
||||
BIO_clear_retry_flags(b);
|
||||
|
||||
do
|
||||
{
|
||||
const char *p;
|
||||
|
||||
for(p = in; p < in + inl && *p != '\n'; p++)
|
||||
;
|
||||
if (*p == '\n')
|
||||
{
|
||||
p++;
|
||||
foundnl = 1;
|
||||
}
|
||||
else
|
||||
foundnl = 0;
|
||||
|
||||
/* If a NL was found and we already have text in the save
|
||||
buffer, concatenate them and write */
|
||||
while ((foundnl || p - in > ctx->obuf_size - ctx->obuf_len)
|
||||
&& ctx->obuf_len > 0)
|
||||
{
|
||||
int orig_olen = ctx->obuf_len;
|
||||
|
||||
i = ctx->obuf_size - ctx->obuf_len;
|
||||
if (p - in > 0)
|
||||
{
|
||||
if (i >= p - in)
|
||||
{
|
||||
memcpy(&(ctx->obuf[ctx->obuf_len]),
|
||||
in,p - in);
|
||||
ctx->obuf_len += p - in;
|
||||
inl -= p - in;
|
||||
num += p - in;
|
||||
in = p;
|
||||
}
|
||||
else
|
||||
{
|
||||
memcpy(&(ctx->obuf[ctx->obuf_len]),
|
||||
in,i);
|
||||
ctx->obuf_len += i;
|
||||
inl -= i;
|
||||
in += i;
|
||||
num += i;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
BIO_write(b->next_bio, "<*<", 3);
|
||||
#endif
|
||||
i=BIO_write(b->next_bio,
|
||||
ctx->obuf, ctx->obuf_len);
|
||||
if (i <= 0)
|
||||
{
|
||||
ctx->obuf_len = orig_olen;
|
||||
BIO_copy_next_retry(b);
|
||||
|
||||
#ifdef DEBUG
|
||||
BIO_write(b->next_bio, ">*>", 3);
|
||||
#endif
|
||||
if (i < 0) return((num > 0)?num:i);
|
||||
if (i == 0) return(num);
|
||||
}
|
||||
#ifdef DEBUG
|
||||
BIO_write(b->next_bio, ">*>", 3);
|
||||
#endif
|
||||
if (i < ctx->obuf_len)
|
||||
memmove(ctx->obuf, ctx->obuf + i,
|
||||
ctx->obuf_len - i);
|
||||
ctx->obuf_len-=i;
|
||||
}
|
||||
|
||||
/* Now that the save buffer is emptied, let's write the input
|
||||
buffer if a NL was found and there is anything to write. */
|
||||
if ((foundnl || p - in > ctx->obuf_size) && p - in > 0)
|
||||
{
|
||||
#ifdef DEBUG
|
||||
BIO_write(b->next_bio, "<*<", 3);
|
||||
#endif
|
||||
i=BIO_write(b->next_bio,in,p - in);
|
||||
if (i <= 0)
|
||||
{
|
||||
BIO_copy_next_retry(b);
|
||||
#ifdef DEBUG
|
||||
BIO_write(b->next_bio, ">*>", 3);
|
||||
#endif
|
||||
if (i < 0) return((num > 0)?num:i);
|
||||
if (i == 0) return(num);
|
||||
}
|
||||
#ifdef DEBUG
|
||||
BIO_write(b->next_bio, ">*>", 3);
|
||||
#endif
|
||||
num+=i;
|
||||
in+=i;
|
||||
inl-=i;
|
||||
}
|
||||
}
|
||||
while(foundnl && inl > 0);
|
||||
/* We've written as much as we can. The rest of the input buffer, if
|
||||
any, is text that doesn't and with a NL and therefore needs to be
|
||||
saved for the next trip. */
|
||||
if (inl > 0)
|
||||
{
|
||||
memcpy(&(ctx->obuf[ctx->obuf_len]), in, inl);
|
||||
ctx->obuf_len += inl;
|
||||
num += inl;
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
static long linebuffer_ctrl(BIO *b, int cmd, long num, void *ptr)
|
||||
{
|
||||
BIO *dbio;
|
||||
BIO_LINEBUFFER_CTX *ctx;
|
||||
long ret=1;
|
||||
char *p;
|
||||
int r;
|
||||
int obs;
|
||||
|
||||
ctx=(BIO_LINEBUFFER_CTX *)b->ptr;
|
||||
|
||||
switch (cmd)
|
||||
{
|
||||
case BIO_CTRL_RESET:
|
||||
ctx->obuf_len=0;
|
||||
if (b->next_bio == NULL) return(0);
|
||||
ret=BIO_ctrl(b->next_bio,cmd,num,ptr);
|
||||
break;
|
||||
case BIO_CTRL_INFO:
|
||||
ret=(long)ctx->obuf_len;
|
||||
break;
|
||||
case BIO_CTRL_WPENDING:
|
||||
ret=(long)ctx->obuf_len;
|
||||
if (ret == 0)
|
||||
{
|
||||
if (b->next_bio == NULL) return(0);
|
||||
ret=BIO_ctrl(b->next_bio,cmd,num,ptr);
|
||||
}
|
||||
break;
|
||||
case BIO_C_SET_BUFF_SIZE:
|
||||
obs=(int)num;
|
||||
p=ctx->obuf;
|
||||
if ((obs > DEFAULT_LINEBUFFER_SIZE) && (obs != ctx->obuf_size))
|
||||
{
|
||||
p=(char *)OPENSSL_malloc((int)num);
|
||||
if (p == NULL)
|
||||
goto malloc_error;
|
||||
}
|
||||
if (ctx->obuf != p)
|
||||
{
|
||||
if (ctx->obuf_len > obs)
|
||||
{
|
||||
ctx->obuf_len = obs;
|
||||
}
|
||||
memcpy(p, ctx->obuf, ctx->obuf_len);
|
||||
OPENSSL_free(ctx->obuf);
|
||||
ctx->obuf=p;
|
||||
ctx->obuf_size=obs;
|
||||
}
|
||||
break;
|
||||
case BIO_C_DO_STATE_MACHINE:
|
||||
if (b->next_bio == NULL) return(0);
|
||||
BIO_clear_retry_flags(b);
|
||||
ret=BIO_ctrl(b->next_bio,cmd,num,ptr);
|
||||
BIO_copy_next_retry(b);
|
||||
break;
|
||||
|
||||
case BIO_CTRL_FLUSH:
|
||||
if (b->next_bio == NULL) return(0);
|
||||
if (ctx->obuf_len <= 0)
|
||||
{
|
||||
ret=BIO_ctrl(b->next_bio,cmd,num,ptr);
|
||||
break;
|
||||
}
|
||||
|
||||
for (;;)
|
||||
{
|
||||
BIO_clear_retry_flags(b);
|
||||
if (ctx->obuf_len > 0)
|
||||
{
|
||||
r=BIO_write(b->next_bio,
|
||||
ctx->obuf, ctx->obuf_len);
|
||||
#if 0
|
||||
fprintf(stderr,"FLUSH %3d -> %3d\n",ctx->obuf_len,r);
|
||||
#endif
|
||||
BIO_copy_next_retry(b);
|
||||
if (r <= 0) return((long)r);
|
||||
if (r < ctx->obuf_len)
|
||||
memmove(ctx->obuf, ctx->obuf + r,
|
||||
ctx->obuf_len - r);
|
||||
ctx->obuf_len-=r;
|
||||
}
|
||||
else
|
||||
{
|
||||
ctx->obuf_len=0;
|
||||
ret=1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
ret=BIO_ctrl(b->next_bio,cmd,num,ptr);
|
||||
break;
|
||||
case BIO_CTRL_DUP:
|
||||
dbio=(BIO *)ptr;
|
||||
if ( !BIO_set_write_buffer_size(dbio,ctx->obuf_size))
|
||||
ret=0;
|
||||
break;
|
||||
default:
|
||||
if (b->next_bio == NULL) return(0);
|
||||
ret=BIO_ctrl(b->next_bio,cmd,num,ptr);
|
||||
break;
|
||||
}
|
||||
return(ret);
|
||||
malloc_error:
|
||||
BIOerr(BIO_F_LINEBUFFER_CTRL,ERR_R_MALLOC_FAILURE);
|
||||
return(0);
|
||||
}
|
||||
|
||||
static long linebuffer_callback_ctrl(BIO *b, int cmd, bio_info_cb *fp)
|
||||
{
|
||||
long ret=1;
|
||||
|
||||
if (b->next_bio == NULL) return(0);
|
||||
switch (cmd)
|
||||
{
|
||||
default:
|
||||
ret=BIO_callback_ctrl(b->next_bio,cmd,fp);
|
||||
break;
|
||||
}
|
||||
return(ret);
|
||||
}
|
||||
|
||||
static int linebuffer_gets(BIO *b, char *buf, int size)
|
||||
{
|
||||
if (b->next_bio == NULL) return(0);
|
||||
return(BIO_gets(b->next_bio,buf,size));
|
||||
}
|
||||
|
||||
static int linebuffer_puts(BIO *b, const char *str)
|
||||
{
|
||||
return(linebuffer_write(b,str,strlen(str)));
|
||||
}
|
||||
|
@@ -91,6 +91,7 @@ extern "C" {
|
||||
#define BIO_TYPE_NULL_FILTER (17|0x0200)
|
||||
#define BIO_TYPE_BER (18|0x0200) /* BER -> bin filter */
|
||||
#define BIO_TYPE_BIO (19|0x0400) /* (half a) BIO pair */
|
||||
#define BIO_TYPE_LINEBUFFER (20|0x0200) /* filter */
|
||||
|
||||
#define BIO_TYPE_DESCRIPTOR 0x0100 /* socket, fd, connect or accept */
|
||||
#define BIO_TYPE_FILTER 0x0200
|
||||
@@ -474,6 +475,7 @@ size_t BIO_ctrl_wpending(BIO *b);
|
||||
#define BIO_get_write_buf_size(b,size) (size_t)BIO_ctrl(b,BIO_C_GET_WRITE_BUF_SIZE,size,NULL)
|
||||
#define BIO_make_bio_pair(b1,b2) (int)BIO_ctrl(b1,BIO_C_MAKE_BIO_PAIR,0,b2)
|
||||
#define BIO_destroy_bio_pair(b) (int)BIO_ctrl(b,BIO_C_DESTROY_BIO_PAIR,0,NULL)
|
||||
#define BIO_shutdown_wr(b) (int)BIO_ctrl(b, BIO_C_SHUTDOWN_WR, 0, NULL)
|
||||
/* macros with inappropriate type -- but ...pending macros use int too: */
|
||||
#define BIO_get_write_guarantee(b) (int)BIO_ctrl(b,BIO_C_GET_WRITE_GUARANTEE,0,NULL)
|
||||
#define BIO_get_read_request(b) (int)BIO_ctrl(b,BIO_C_GET_READ_REQUEST,0,NULL)
|
||||
@@ -553,6 +555,9 @@ BIO_METHOD *BIO_s_bio(void);
|
||||
BIO_METHOD *BIO_s_null(void);
|
||||
BIO_METHOD *BIO_f_null(void);
|
||||
BIO_METHOD *BIO_f_buffer(void);
|
||||
#ifdef VMS
|
||||
BIO_METHOD *BIO_f_linebuffer(void);
|
||||
#endif
|
||||
BIO_METHOD *BIO_f_nbio_test(void);
|
||||
/* BIO_METHOD *BIO_f_ber(void); */
|
||||
|
||||
@@ -639,6 +644,7 @@ int BIO_vsnprintf(char *buf, size_t n, const char *format, va_list args);
|
||||
#define BIO_F_CONN_CTRL 127
|
||||
#define BIO_F_CONN_STATE 115
|
||||
#define BIO_F_FILE_CTRL 116
|
||||
#define BIO_F_LINEBUFFER_CTRL 129
|
||||
#define BIO_F_MEM_READ 128
|
||||
#define BIO_F_MEM_WRITE 117
|
||||
#define BIO_F_SSL_NEW 118
|
||||
|
@@ -91,6 +91,7 @@ static ERR_STRING_DATA BIO_str_functs[]=
|
||||
{ERR_PACK(0,BIO_F_CONN_CTRL,0), "CONN_CTRL"},
|
||||
{ERR_PACK(0,BIO_F_CONN_STATE,0), "CONN_STATE"},
|
||||
{ERR_PACK(0,BIO_F_FILE_CTRL,0), "FILE_CTRL"},
|
||||
{ERR_PACK(0,BIO_F_LINEBUFFER_CTRL,0), "LINEBUFFER_CTRL"},
|
||||
{ERR_PACK(0,BIO_F_MEM_READ,0), "MEM_READ"},
|
||||
{ERR_PACK(0,BIO_F_MEM_WRITE,0), "MEM_WRITE"},
|
||||
{ERR_PACK(0,BIO_F_SSL_NEW,0), "SSL_new"},
|
||||
|
@@ -236,7 +236,7 @@ static int conn_state(BIO *b, BIO_CONNECT *c)
|
||||
}
|
||||
c->state=BIO_CONN_S_CONNECT;
|
||||
|
||||
#ifdef SO_KEEPALIVE
|
||||
#if defined(SO_KEEPALIVE) && !defined(MPE)
|
||||
i=1;
|
||||
i=setsockopt(b->num,SOL_SOCKET,SO_KEEPALIVE,(char *)&i,sizeof(i));
|
||||
if (i < 0)
|
||||
|
@@ -68,7 +68,8 @@ bnbug: bnbug.c ../../libcrypto.a top
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
# elf
|
||||
|
@@ -15,9 +15,9 @@ On the 2 alpha C compilers I had access to, it was not possible to do
|
||||
were 64 bits). So the hand assember gives access to the 128 bit result and
|
||||
a 2 times speedup :-).
|
||||
|
||||
There are 2 versions of assember for the HP PA-RISC.
|
||||
pa-risc.s is the origional one which works fine.
|
||||
pa-risc2.s is a new version that often generates warnings but if the
|
||||
tests pass, it gives performance that is over 2 times faster than
|
||||
pa-risc.s.
|
||||
Both were generated using gcc :-)
|
||||
There are 3 versions of assember for the HP PA-RISC.
|
||||
|
||||
pa-risc.s is the origional one which works fine and generated using gcc :-)
|
||||
|
||||
pa-risc2W.s and pa-risc2.s are 64 and 32-bit PA-RISC 2.0 implementations
|
||||
by Chris Ruemmler from HP (with some help from the HP C compiler).
|
||||
|
@@ -1,5 +1,5 @@
|
||||
.rdata
|
||||
.asciiz "mips3.s, Version 1.0"
|
||||
.asciiz "mips3.s, Version 1.1"
|
||||
.asciiz "MIPS III/IV ISA artwork by Andy Polyakov <appro@fy.chalmers.se>"
|
||||
|
||||
/*
|
||||
@@ -586,13 +586,13 @@ LEAF(bn_div_3_words)
|
||||
ld a0,(a3)
|
||||
move ta2,a1
|
||||
ld a1,-8(a3)
|
||||
move ta3,ra
|
||||
move v1,zero
|
||||
bne a0,a2,.L_bn_div_3_words_proceed
|
||||
li v0,-1
|
||||
beq a0,a2,.L_bn_div_3_words_skip_div
|
||||
jr ra
|
||||
.L_bn_div_3_words_proceed:
|
||||
move ta3,ra
|
||||
bal bn_div_words
|
||||
move ra,ta3
|
||||
.L_bn_div_3_words_skip_div:
|
||||
dmultu ta2,v0
|
||||
ld t2,-16(a3)
|
||||
move ta0,zero
|
||||
@@ -849,6 +849,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
dmultu a_1,b_2 /* mul_add_c(a[1],b[2],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -856,7 +857,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_2,b_1 /* mul_add_c(a[2],b[1],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -884,6 +886,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
dmultu a_3,b_1 /* mul_add_c(a[3],b[1],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -891,7 +894,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_2,b_2 /* mul_add_c(a[2],b[2],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -928,6 +932,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
dmultu a_1,b_4 /* mul_add_c(a[1],b[4],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -935,7 +940,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_2,b_3 /* mul_add_c(a[2],b[3],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -981,6 +987,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
dmultu a_5,b_1 /* mul_add_c(a[5],b[1],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -988,7 +995,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_4,b_2 /* mul_add_c(a[4],b[2],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1043,6 +1051,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
dmultu a_1,b_6 /* mul_add_c(a[1],b[6],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1050,7 +1059,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_2,b_5 /* mul_add_c(a[2],b[5],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1114,6 +1124,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
dmultu a_6,b_2 /* mul_add_c(a[6],b[2],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1121,7 +1132,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_5,b_3 /* mul_add_c(a[5],b[3],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1176,6 +1188,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
dmultu a_3,b_6 /* mul_add_c(a[3],b[6],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1183,7 +1196,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_4,b_5 /* mul_add_c(a[4],b[5],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1229,6 +1243,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
dmultu a_6,b_4 /* mul_add_c(a[6],b[4],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1236,7 +1251,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_5,b_5 /* mul_add_c(a[5],b[5],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1273,6 +1289,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
dmultu a_5,b_6 /* mul_add_c(a[5],b[6],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1280,7 +1297,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_6,b_5 /* mul_add_c(a[6],b[5],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1308,6 +1326,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
dmultu a_6,b_6 /* mul_add_c(a[6],b[6],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1315,7 +1334,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_5,b_7 /* mul_add_c(a[5],b[7],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1334,6 +1354,7 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
dmultu a_7,b_6 /* mul_add_c(a[7],b[6],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1341,7 +1362,8 @@ LEAF(bn_mul_comba8)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
sd c_2,104(a0) /* r[13]=c2; */
|
||||
|
||||
dmultu a_7,b_7 /* mul_add_c(a[7],b[7],c3,c1,c2); */
|
||||
@@ -1430,6 +1452,7 @@ LEAF(bn_mul_comba4)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
dmultu a_1,b_2 /* mul_add_c(a[1],b[2],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1437,7 +1460,8 @@ LEAF(bn_mul_comba4)
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_2,b_1 /* mul_add_c(a[2],b[1],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1465,6 +1489,7 @@ LEAF(bn_mul_comba4)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
dmultu a_2,b_2 /* mul_add_c(a[2],b[2],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1472,7 +1497,8 @@ LEAF(bn_mul_comba4)
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_1,b_3 /* mul_add_c(a[1],b[3],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1491,6 +1517,7 @@ LEAF(bn_mul_comba4)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
dmultu a_3,b_2 /* mul_add_c(a[3],b[2],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1498,7 +1525,8 @@ LEAF(bn_mul_comba4)
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
sd c_3,40(a0)
|
||||
|
||||
dmultu a_3,b_3 /* mul_add_c(a[3],b[3],c1,c2,c3); */
|
||||
@@ -1543,28 +1571,30 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_0,a_1 /* mul_add_c2(a[0],b[1],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu c_3,t_2,AT
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sd c_2,8(a0)
|
||||
|
||||
dmultu a_2,a_0 /* mul_add_c2(a[2],b[0],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
slt c_2,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_1,a_1 /* mul_add_c(a[1],b[1],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1579,24 +1609,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_0,a_3 /* mul_add_c2(a[0],b[3],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
slt c_3,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_1,a_2 /* mul_add_c2(a[1],b[2],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
sltu AT,c_2,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_3,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1608,24 +1640,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_4,a_0 /* mul_add_c2(a[4],b[0],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_3,a_1 /* mul_add_c2(a[3],b[1],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
sltu AT,c_3,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_1,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1646,24 +1680,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_0,a_5 /* mul_add_c2(a[0],b[5],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
slt c_2,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_1,a_4 /* mul_add_c2(a[1],b[4],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
sltu AT,c_1,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_2,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1673,12 +1709,12 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_2,a_3 /* mul_add_c2(a[2],b[3],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
sltu AT,c_1,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_2,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1690,24 +1726,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_6,a_0 /* mul_add_c2(a[6],b[0],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
slt c_3,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_5,a_1 /* mul_add_c2(a[5],b[1],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
sltu AT,c_2,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_3,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1717,12 +1755,12 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_4,a_2 /* mul_add_c2(a[4],b[2],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
sltu AT,c_2,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_3,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1743,24 +1781,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_0,a_7 /* mul_add_c2(a[0],b[7],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_1,a_6 /* mul_add_c2(a[1],b[6],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
sltu AT,c_3,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_1,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1770,12 +1810,12 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_2,a_5 /* mul_add_c2(a[2],b[5],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
sltu AT,c_3,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_1,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1785,12 +1825,12 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_3,a_4 /* mul_add_c2(a[3],b[4],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
sltu AT,c_3,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_1,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1802,24 +1842,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_7,a_1 /* mul_add_c2(a[7],b[1],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
slt c_2,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_6,a_2 /* mul_add_c2(a[6],b[2],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
sltu AT,c_1,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_2,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1829,12 +1871,12 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_5,a_3 /* mul_add_c2(a[5],b[3],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
sltu AT,c_1,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_2,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1855,24 +1897,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_2,a_7 /* mul_add_c2(a[2],b[7],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
slt c_3,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_3,a_6 /* mul_add_c2(a[3],b[6],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
sltu AT,c_2,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_3,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1882,12 +1926,12 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_4,a_5 /* mul_add_c2(a[4],b[5],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
sltu AT,c_2,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_3,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1899,24 +1943,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_7,a_3 /* mul_add_c2(a[7],b[3],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_6,a_4 /* mul_add_c2(a[6],b[4],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
sltu AT,c_3,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_1,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1937,24 +1983,26 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_4,a_7 /* mul_add_c2(a[4],b[7],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
slt c_2,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_5,a_6 /* mul_add_c2(a[5],b[6],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
sltu AT,c_1,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_2,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
@@ -1966,15 +2014,17 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_7,a_5 /* mul_add_c2(a[7],b[5],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
slt c_3,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_6,a_6 /* mul_add_c(a[6],b[6],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -1989,15 +2039,17 @@ LEAF(bn_sqr_comba8)
|
||||
dmultu a_6,a_7 /* mul_add_c2(a[6],b[7],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
sd c_2,104(a0)
|
||||
|
||||
dmultu a_7,a_7 /* mul_add_c(a[7],b[7],c3,c1,c2); */
|
||||
@@ -2028,28 +2080,30 @@ LEAF(bn_sqr_comba4)
|
||||
dmultu a_0,a_1 /* mul_add_c2(a[0],b[1],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu c_3,t_2,AT
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sd c_2,8(a0)
|
||||
|
||||
dmultu a_2,a_0 /* mul_add_c2(a[2],b[0],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
slt c_2,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
dmultu a_1,a_1 /* mul_add_c(a[1],b[1],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -2064,24 +2118,26 @@ LEAF(bn_sqr_comba4)
|
||||
dmultu a_0,a_3 /* mul_add_c2(a[0],b[3],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
slt c_3,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_2,t_2
|
||||
sltu c_3,c_2,t_2
|
||||
sltu AT,c_2,t_2
|
||||
daddu c_3,AT
|
||||
dmultu a_1,a_2 /* mul_add_c(a2[1],b[2],c1,c2,c3); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_2,a2
|
||||
sltu AT,c_2,a2
|
||||
slt AT,t_2,zero
|
||||
daddu c_3,AT
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_1,t_1
|
||||
sltu AT,c_1,t_1
|
||||
daddu t_2,AT
|
||||
@@ -2093,15 +2149,17 @@ LEAF(bn_sqr_comba4)
|
||||
dmultu a_3,a_1 /* mul_add_c2(a[3],b[1],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_3,a2
|
||||
slt c_1,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_2,t_1
|
||||
sltu AT,c_2,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_3,t_2
|
||||
sltu c_1,c_3,t_2
|
||||
sltu AT,c_3,t_2
|
||||
daddu c_1,AT
|
||||
dmultu a_2,a_2 /* mul_add_c(a[2],b[2],c2,c3,c1); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
@@ -2116,15 +2174,17 @@ LEAF(bn_sqr_comba4)
|
||||
dmultu a_2,a_3 /* mul_add_c2(a[2],b[3],c3,c1,c2); */
|
||||
mflo t_1
|
||||
mfhi t_2
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu a2,t_2,AT
|
||||
daddu c_1,a2
|
||||
slt c_2,t_2,zero
|
||||
dsll t_2,1
|
||||
slt a2,t_1,zero
|
||||
daddu t_2,a2
|
||||
dsll t_1,1
|
||||
daddu c_3,t_1
|
||||
sltu AT,c_3,t_1
|
||||
daddu t_2,AT
|
||||
daddu c_1,t_2
|
||||
sltu c_2,c_1,t_2
|
||||
sltu AT,c_1,t_2
|
||||
daddu c_2,AT
|
||||
sd c_3,40(a0)
|
||||
|
||||
dmultu a_3,a_3 /* mul_add_c(a[3],b[3],c1,c2,c3); */
|
||||
|
File diff suppressed because it is too large
Load Diff
416
crypto/bn/asm/pa-risc2.s.old
Normal file
416
crypto/bn/asm/pa-risc2.s.old
Normal file
@@ -0,0 +1,416 @@
|
||||
.SPACE $PRIVATE$
|
||||
.SUBSPA $DATA$,QUAD=1,ALIGN=8,ACCESS=31
|
||||
.SUBSPA $BSS$,QUAD=1,ALIGN=8,ACCESS=31,ZERO,SORT=82
|
||||
.SPACE $TEXT$
|
||||
.SUBSPA $LIT$,QUAD=0,ALIGN=8,ACCESS=44
|
||||
.SUBSPA $CODE$,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY
|
||||
.IMPORT $global$,DATA
|
||||
.IMPORT $$dyncall,MILLICODE
|
||||
; gcc_compiled.:
|
||||
.SPACE $TEXT$
|
||||
.SUBSPA $CODE$
|
||||
|
||||
.align 4
|
||||
.EXPORT bn_mul_add_words,ENTRY,PRIV_LEV=3,ARGW0=GR,ARGW1=GR,ARGW2=GR,ARGW3=GR,RTNVAL=GR
|
||||
bn_mul_add_words
|
||||
.PROC
|
||||
.CALLINFO FRAME=64,CALLS,SAVE_RP,ENTRY_GR=4
|
||||
.ENTRY
|
||||
stw %r2,-20(0,%r30)
|
||||
stwm %r4,64(0,%r30)
|
||||
copy %r24,%r31
|
||||
stw %r3,-60(0,%r30)
|
||||
ldi 0,%r20
|
||||
ldo 12(%r26),%r2
|
||||
stw %r23,-16(0,%r30)
|
||||
copy %r25,%r3
|
||||
ldo 12(%r3),%r1
|
||||
fldws -16(0,%r30),%fr8L
|
||||
L$0010
|
||||
copy %r20,%r25
|
||||
ldi 0,%r24
|
||||
fldws 0(0,%r3),%fr9L
|
||||
ldw 0(0,%r26),%r19
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r19,%r23
|
||||
ldw -16(0,%r30),%r28
|
||||
ldw -12(0,%r30),%r29
|
||||
ldi 0,%r22
|
||||
add %r23,%r29,%r29
|
||||
addc %r22,%r28,%r28
|
||||
add %r25,%r29,%r29
|
||||
addc %r24,%r28,%r28
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
copy %r21,%r20
|
||||
addib,= -1,%r31,L$0011
|
||||
stw %r29,0(0,%r26)
|
||||
copy %r20,%r25
|
||||
ldi 0,%r24
|
||||
fldws -8(0,%r1),%fr9L
|
||||
ldw -8(0,%r2),%r19
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r19,%r23
|
||||
ldw -16(0,%r30),%r28
|
||||
ldw -12(0,%r30),%r29
|
||||
ldi 0,%r22
|
||||
add %r23,%r29,%r29
|
||||
addc %r22,%r28,%r28
|
||||
add %r25,%r29,%r29
|
||||
addc %r24,%r28,%r28
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
copy %r21,%r20
|
||||
addib,= -1,%r31,L$0011
|
||||
stw %r29,-8(0,%r2)
|
||||
copy %r20,%r25
|
||||
ldi 0,%r24
|
||||
fldws -4(0,%r1),%fr9L
|
||||
ldw -4(0,%r2),%r19
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r19,%r23
|
||||
ldw -16(0,%r30),%r28
|
||||
ldw -12(0,%r30),%r29
|
||||
ldi 0,%r22
|
||||
add %r23,%r29,%r29
|
||||
addc %r22,%r28,%r28
|
||||
add %r25,%r29,%r29
|
||||
addc %r24,%r28,%r28
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
copy %r21,%r20
|
||||
addib,= -1,%r31,L$0011
|
||||
stw %r29,-4(0,%r2)
|
||||
copy %r20,%r25
|
||||
ldi 0,%r24
|
||||
fldws 0(0,%r1),%fr9L
|
||||
ldw 0(0,%r2),%r19
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r19,%r23
|
||||
ldw -16(0,%r30),%r28
|
||||
ldw -12(0,%r30),%r29
|
||||
ldi 0,%r22
|
||||
add %r23,%r29,%r29
|
||||
addc %r22,%r28,%r28
|
||||
add %r25,%r29,%r29
|
||||
addc %r24,%r28,%r28
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
copy %r21,%r20
|
||||
addib,= -1,%r31,L$0011
|
||||
stw %r29,0(0,%r2)
|
||||
ldo 16(%r1),%r1
|
||||
ldo 16(%r3),%r3
|
||||
ldo 16(%r2),%r2
|
||||
bl L$0010,0
|
||||
ldo 16(%r26),%r26
|
||||
L$0011
|
||||
copy %r20,%r28
|
||||
ldw -84(0,%r30),%r2
|
||||
ldw -60(0,%r30),%r3
|
||||
bv 0(%r2)
|
||||
ldwm -64(0,%r30),%r4
|
||||
.EXIT
|
||||
.PROCEND
|
||||
.align 4
|
||||
.EXPORT bn_mul_words,ENTRY,PRIV_LEV=3,ARGW0=GR,ARGW1=GR,ARGW2=GR,ARGW3=GR,RTNVAL=GR
|
||||
bn_mul_words
|
||||
.PROC
|
||||
.CALLINFO FRAME=64,CALLS,SAVE_RP,ENTRY_GR=3
|
||||
.ENTRY
|
||||
stw %r2,-20(0,%r30)
|
||||
copy %r25,%r2
|
||||
stwm %r4,64(0,%r30)
|
||||
copy %r24,%r19
|
||||
ldi 0,%r28
|
||||
stw %r23,-16(0,%r30)
|
||||
ldo 12(%r26),%r31
|
||||
ldo 12(%r2),%r29
|
||||
fldws -16(0,%r30),%fr8L
|
||||
L$0026
|
||||
fldws 0(0,%r2),%fr9L
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
ldw -16(0,%r30),%r24
|
||||
ldw -12(0,%r30),%r25
|
||||
add %r21,%r25,%r25
|
||||
addc %r20,%r24,%r24
|
||||
copy %r24,%r23
|
||||
ldi 0,%r22
|
||||
copy %r23,%r28
|
||||
addib,= -1,%r19,L$0027
|
||||
stw %r25,0(0,%r26)
|
||||
fldws -8(0,%r29),%fr9L
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
ldw -16(0,%r30),%r24
|
||||
ldw -12(0,%r30),%r25
|
||||
add %r21,%r25,%r25
|
||||
addc %r20,%r24,%r24
|
||||
copy %r24,%r23
|
||||
ldi 0,%r22
|
||||
copy %r23,%r28
|
||||
addib,= -1,%r19,L$0027
|
||||
stw %r25,-8(0,%r31)
|
||||
fldws -4(0,%r29),%fr9L
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
ldw -16(0,%r30),%r24
|
||||
ldw -12(0,%r30),%r25
|
||||
add %r21,%r25,%r25
|
||||
addc %r20,%r24,%r24
|
||||
copy %r24,%r23
|
||||
ldi 0,%r22
|
||||
copy %r23,%r28
|
||||
addib,= -1,%r19,L$0027
|
||||
stw %r25,-4(0,%r31)
|
||||
fldws 0(0,%r29),%fr9L
|
||||
xmpyu %fr8L,%fr9L,%fr9
|
||||
fstds %fr9,-16(0,%r30)
|
||||
copy %r28,%r21
|
||||
ldi 0,%r20
|
||||
ldw -16(0,%r30),%r24
|
||||
ldw -12(0,%r30),%r25
|
||||
add %r21,%r25,%r25
|
||||
addc %r20,%r24,%r24
|
||||
copy %r24,%r23
|
||||
ldi 0,%r22
|
||||
copy %r23,%r28
|
||||
addib,= -1,%r19,L$0027
|
||||
stw %r25,0(0,%r31)
|
||||
ldo 16(%r29),%r29
|
||||
ldo 16(%r2),%r2
|
||||
ldo 16(%r31),%r31
|
||||
bl L$0026,0
|
||||
ldo 16(%r26),%r26
|
||||
L$0027
|
||||
ldw -84(0,%r30),%r2
|
||||
bv 0(%r2)
|
||||
ldwm -64(0,%r30),%r4
|
||||
.EXIT
|
||||
.PROCEND
|
||||
.align 4
|
||||
.EXPORT bn_sqr_words,ENTRY,PRIV_LEV=3,ARGW0=GR,ARGW1=GR,ARGW2=GR
|
||||
bn_sqr_words
|
||||
.PROC
|
||||
.CALLINFO FRAME=0,NO_CALLS
|
||||
.ENTRY
|
||||
ldo 28(%r26),%r19
|
||||
ldo 12(%r25),%r28
|
||||
L$0042
|
||||
fldws 0(0,%r25),%fr8L
|
||||
fldws 0(0,%r25),%fr8R
|
||||
xmpyu %fr8L,%fr8R,%fr8
|
||||
fstds %fr8,-16(0,%r30)
|
||||
ldw -16(0,%r30),%r22
|
||||
ldw -12(0,%r30),%r23
|
||||
stw %r23,0(0,%r26)
|
||||
copy %r22,%r21
|
||||
ldi 0,%r20
|
||||
addib,= -1,%r24,L$0049
|
||||
stw %r21,-24(0,%r19)
|
||||
fldws -8(0,%r28),%fr8L
|
||||
fldws -8(0,%r28),%fr8R
|
||||
xmpyu %fr8L,%fr8R,%fr8
|
||||
fstds %fr8,-16(0,%r30)
|
||||
ldw -16(0,%r30),%r22
|
||||
ldw -12(0,%r30),%r23
|
||||
stw %r23,-20(0,%r19)
|
||||
copy %r22,%r21
|
||||
ldi 0,%r20
|
||||
addib,= -1,%r24,L$0049
|
||||
stw %r21,-16(0,%r19)
|
||||
fldws -4(0,%r28),%fr8L
|
||||
fldws -4(0,%r28),%fr8R
|
||||
xmpyu %fr8L,%fr8R,%fr8
|
||||
fstds %fr8,-16(0,%r30)
|
||||
ldw -16(0,%r30),%r22
|
||||
ldw -12(0,%r30),%r23
|
||||
stw %r23,-12(0,%r19)
|
||||
copy %r22,%r21
|
||||
ldi 0,%r20
|
||||
addib,= -1,%r24,L$0049
|
||||
stw %r21,-8(0,%r19)
|
||||
fldws 0(0,%r28),%fr8L
|
||||
fldws 0(0,%r28),%fr8R
|
||||
xmpyu %fr8L,%fr8R,%fr8
|
||||
fstds %fr8,-16(0,%r30)
|
||||
ldw -16(0,%r30),%r22
|
||||
ldw -12(0,%r30),%r23
|
||||
stw %r23,-4(0,%r19)
|
||||
copy %r22,%r21
|
||||
ldi 0,%r20
|
||||
addib,= -1,%r24,L$0049
|
||||
stw %r21,0(0,%r19)
|
||||
ldo 16(%r28),%r28
|
||||
ldo 16(%r25),%r25
|
||||
ldo 32(%r19),%r19
|
||||
bl L$0042,0
|
||||
ldo 32(%r26),%r26
|
||||
L$0049
|
||||
bv,n 0(%r2)
|
||||
.EXIT
|
||||
.PROCEND
|
||||
.IMPORT BN_num_bits_word,CODE
|
||||
.IMPORT fprintf,CODE
|
||||
.IMPORT __iob,DATA
|
||||
.SPACE $TEXT$
|
||||
.SUBSPA $LIT$
|
||||
|
||||
.align 4
|
||||
L$C0000
|
||||
.STRING "Division would overflow (%d)\x0a\x00"
|
||||
.IMPORT abort,CODE
|
||||
.SPACE $TEXT$
|
||||
.SUBSPA $CODE$
|
||||
|
||||
.align 4
|
||||
.EXPORT bn_div64,ENTRY,PRIV_LEV=3,ARGW0=GR,ARGW1=GR,ARGW2=GR,RTNVAL=GR
|
||||
bn_div64
|
||||
.PROC
|
||||
.CALLINFO FRAME=128,CALLS,SAVE_RP,ENTRY_GR=8
|
||||
.ENTRY
|
||||
stw %r2,-20(0,%r30)
|
||||
stwm %r8,128(0,%r30)
|
||||
stw %r7,-124(0,%r30)
|
||||
stw %r4,-112(0,%r30)
|
||||
stw %r3,-108(0,%r30)
|
||||
copy %r26,%r3
|
||||
copy %r25,%r4
|
||||
stw %r6,-120(0,%r30)
|
||||
ldi 0,%r7
|
||||
stw %r5,-116(0,%r30)
|
||||
movb,<> %r24,%r5,L$0051
|
||||
ldi 2,%r6
|
||||
bl L$0068,0
|
||||
ldi -1,%r28
|
||||
L$0051
|
||||
.CALL ARGW0=GR
|
||||
bl BN_num_bits_word,%r2
|
||||
copy %r5,%r26
|
||||
copy %r28,%r24
|
||||
ldi 32,%r19
|
||||
comb,= %r19,%r24,L$0052
|
||||
subi 31,%r24,%r19
|
||||
mtsar %r19
|
||||
zvdepi 1,32,%r19
|
||||
comb,>>= %r19,%r3,L$0052
|
||||
addil LR'__iob-$global$+32,%r27
|
||||
ldo RR'__iob-$global$+32(%r1),%r26
|
||||
ldil LR'L$C0000,%r25
|
||||
.CALL ARGW0=GR,ARGW1=GR,ARGW2=GR
|
||||
bl fprintf,%r2
|
||||
ldo RR'L$C0000(%r25),%r25
|
||||
.CALL
|
||||
bl abort,%r2
|
||||
nop
|
||||
L$0052
|
||||
comb,>> %r5,%r3,L$0053
|
||||
subi 32,%r24,%r24
|
||||
sub %r3,%r5,%r3
|
||||
L$0053
|
||||
comib,= 0,%r24,L$0054
|
||||
subi 31,%r24,%r19
|
||||
mtsar %r19
|
||||
zvdep %r5,32,%r5
|
||||
zvdep %r3,32,%r21
|
||||
subi 32,%r24,%r20
|
||||
mtsar %r20
|
||||
vshd 0,%r4,%r20
|
||||
or %r21,%r20,%r3
|
||||
mtsar %r19
|
||||
zvdep %r4,32,%r4
|
||||
L$0054
|
||||
extru %r5,15,16,%r23
|
||||
extru %r5,31,16,%r28
|
||||
L$0055
|
||||
extru %r3,15,16,%r19
|
||||
comb,<> %r23,%r19,L$0058
|
||||
copy %r3,%r26
|
||||
bl L$0059,0
|
||||
zdepi -1,31,16,%r29
|
||||
L$0058
|
||||
.IMPORT $$divU,MILLICODE
|
||||
bl $$divU,%r31
|
||||
copy %r23,%r25
|
||||
L$0059
|
||||
stw %r29,-16(0,%r30)
|
||||
fldws -16(0,%r30),%fr10L
|
||||
stw %r28,-16(0,%r30)
|
||||
fldws -16(0,%r30),%fr10R
|
||||
stw %r23,-16(0,%r30)
|
||||
xmpyu %fr10L,%fr10R,%fr8
|
||||
fldws -16(0,%r30),%fr10R
|
||||
fstws %fr8R,-16(0,%r30)
|
||||
xmpyu %fr10L,%fr10R,%fr9
|
||||
ldw -16(0,%r30),%r8
|
||||
fstws %fr9R,-16(0,%r30)
|
||||
copy %r8,%r22
|
||||
ldw -16(0,%r30),%r8
|
||||
extru %r4,15,16,%r24
|
||||
copy %r8,%r21
|
||||
L$0060
|
||||
sub %r3,%r21,%r20
|
||||
copy %r20,%r19
|
||||
depi 0,31,16,%r19
|
||||
comib,<> 0,%r19,L$0061
|
||||
zdep %r20,15,16,%r19
|
||||
addl %r19,%r24,%r19
|
||||
comb,>>= %r19,%r22,L$0061
|
||||
sub %r22,%r28,%r22
|
||||
sub %r21,%r23,%r21
|
||||
bl L$0060,0
|
||||
ldo -1(%r29),%r29
|
||||
L$0061
|
||||
stw %r29,-16(0,%r30)
|
||||
fldws -16(0,%r30),%fr10L
|
||||
stw %r28,-16(0,%r30)
|
||||
fldws -16(0,%r30),%fr10R
|
||||
xmpyu %fr10L,%fr10R,%fr8
|
||||
fstws %fr8R,-16(0,%r30)
|
||||
ldw -16(0,%r30),%r8
|
||||
stw %r23,-16(0,%r30)
|
||||
fldws -16(0,%r30),%fr10R
|
||||
copy %r8,%r19
|
||||
xmpyu %fr10L,%fr10R,%fr8
|
||||
fstws %fr8R,-16(0,%r30)
|
||||
extru %r19,15,16,%r20
|
||||
ldw -16(0,%r30),%r8
|
||||
zdep %r19,15,16,%r19
|
||||
addl %r8,%r20,%r20
|
||||
comclr,<<= %r19,%r4,0
|
||||
addi 1,%r20,%r20
|
||||
comb,<<= %r20,%r3,L$0066
|
||||
sub %r4,%r19,%r4
|
||||
addl %r3,%r5,%r3
|
||||
ldo -1(%r29),%r29
|
||||
L$0066
|
||||
addib,= -1,%r6,L$0056
|
||||
sub %r3,%r20,%r3
|
||||
zdep %r29,15,16,%r7
|
||||
shd %r3,%r4,16,%r3
|
||||
bl L$0055,0
|
||||
zdep %r4,15,16,%r4
|
||||
L$0056
|
||||
or %r7,%r29,%r28
|
||||
L$0068
|
||||
ldw -148(0,%r30),%r2
|
||||
ldw -124(0,%r30),%r7
|
||||
ldw -120(0,%r30),%r6
|
||||
ldw -116(0,%r30),%r5
|
||||
ldw -112(0,%r30),%r4
|
||||
ldw -108(0,%r30),%r3
|
||||
bv 0(%r2)
|
||||
ldwm -128(0,%r30),%r8
|
||||
.EXIT
|
||||
.PROCEND
|
1605
crypto/bn/asm/pa-risc2W.s
Normal file
1605
crypto/bn/asm/pa-risc2W.s
Normal file
File diff suppressed because it is too large
Load Diff
@@ -239,7 +239,7 @@ typedef struct bignum_st
|
||||
} BIGNUM;
|
||||
|
||||
/* Used for temp variables */
|
||||
#define BN_CTX_NUM 12
|
||||
#define BN_CTX_NUM 16
|
||||
#define BN_CTX_NUM_POS 12
|
||||
typedef struct bignum_ctx
|
||||
{
|
||||
@@ -328,6 +328,7 @@ BIGNUM *BN_CTX_get(BN_CTX *ctx);
|
||||
void BN_CTX_end(BN_CTX *ctx);
|
||||
int BN_rand(BIGNUM *rnd, int bits, int top,int bottom);
|
||||
int BN_pseudo_rand(BIGNUM *rnd, int bits, int top,int bottom);
|
||||
int BN_rand_range(BIGNUM *rnd, BIGNUM *range);
|
||||
int BN_num_bits(const BIGNUM *a);
|
||||
int BN_num_bits_word(BN_ULONG);
|
||||
BIGNUM *BN_new(void);
|
||||
@@ -467,6 +468,8 @@ BN_ULONG bn_sub_words(BN_ULONG *rp, BN_ULONG *ap, BN_ULONG *bp,int num);
|
||||
# define bn_dump(a,b)
|
||||
#endif
|
||||
|
||||
int BN_bntest_rand(BIGNUM *rnd, int bits, int top,int bottom);
|
||||
|
||||
/* BEGIN ERROR CODES */
|
||||
/* The following lines are auto generated by the script mkerr.pl. Any changes
|
||||
* made after this point may be overwritten when the script is next run.
|
||||
@@ -493,16 +496,19 @@ BN_ULONG bn_sub_words(BN_ULONG *rp, BN_ULONG *ap, BN_ULONG *bp,int num);
|
||||
#define BN_F_BN_MPI2BN 112
|
||||
#define BN_F_BN_NEW 113
|
||||
#define BN_F_BN_RAND 114
|
||||
#define BN_F_BN_RAND_RANGE 122
|
||||
#define BN_F_BN_USUB 115
|
||||
|
||||
/* Reason codes. */
|
||||
#define BN_R_ARG2_LT_ARG3 100
|
||||
#define BN_R_BAD_RECIPROCAL 101
|
||||
#define BN_R_BIGNUM_TOO_LONG 114
|
||||
#define BN_R_CALLED_WITH_EVEN_MODULUS 102
|
||||
#define BN_R_DIV_BY_ZERO 103
|
||||
#define BN_R_ENCODING_ERROR 104
|
||||
#define BN_R_EXPAND_ON_STATIC_BIGNUM_DATA 105
|
||||
#define BN_R_INVALID_LENGTH 106
|
||||
#define BN_R_INVALID_RANGE 115
|
||||
#define BN_R_NOT_INITIALIZED 107
|
||||
#define BN_R_NO_INVERSE 108
|
||||
#define BN_R_TOO_MANY_TEMPORARY_VARIABLES 109
|
||||
|
@@ -180,13 +180,13 @@ int BN_div(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num, const BIGNUM *divisor,
|
||||
|
||||
BN_CTX_start(ctx);
|
||||
tmp=BN_CTX_get(ctx);
|
||||
tmp->neg=0;
|
||||
snum=BN_CTX_get(ctx);
|
||||
sdiv=BN_CTX_get(ctx);
|
||||
if (dv == NULL)
|
||||
res=BN_CTX_get(ctx);
|
||||
else res=dv;
|
||||
if (res == NULL) goto err;
|
||||
if (sdiv==NULL || res == NULL) goto err;
|
||||
tmp->neg=0;
|
||||
|
||||
/* First we normalise the numbers */
|
||||
norm_shift=BN_BITS2-((BN_num_bits(divisor))%BN_BITS2);
|
||||
@@ -237,7 +237,8 @@ int BN_div(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num, const BIGNUM *divisor,
|
||||
for (i=0; i<loop-1; i++)
|
||||
{
|
||||
BN_ULONG q,l0;
|
||||
#ifdef BN_DIV3W
|
||||
#if defined(BN_DIV3W) && !defined(NO_ASM)
|
||||
BN_ULONG bn_div_3_words(BN_ULONG*,BN_ULONG,BN_ULONG);
|
||||
q=bn_div_3_words(wnump,d1,d0);
|
||||
#else
|
||||
BN_ULONG n0,n1,rem=0;
|
||||
|
@@ -84,6 +84,7 @@ static ERR_STRING_DATA BN_str_functs[]=
|
||||
{ERR_PACK(0,BN_F_BN_MPI2BN,0), "BN_mpi2bn"},
|
||||
{ERR_PACK(0,BN_F_BN_NEW,0), "BN_new"},
|
||||
{ERR_PACK(0,BN_F_BN_RAND,0), "BN_rand"},
|
||||
{ERR_PACK(0,BN_F_BN_RAND_RANGE,0), "BN_rand_range"},
|
||||
{ERR_PACK(0,BN_F_BN_USUB,0), "BN_usub"},
|
||||
{0,NULL}
|
||||
};
|
||||
@@ -92,11 +93,13 @@ static ERR_STRING_DATA BN_str_reasons[]=
|
||||
{
|
||||
{BN_R_ARG2_LT_ARG3 ,"arg2 lt arg3"},
|
||||
{BN_R_BAD_RECIPROCAL ,"bad reciprocal"},
|
||||
{BN_R_BIGNUM_TOO_LONG ,"bignum too long"},
|
||||
{BN_R_CALLED_WITH_EVEN_MODULUS ,"called with even modulus"},
|
||||
{BN_R_DIV_BY_ZERO ,"div by zero"},
|
||||
{BN_R_ENCODING_ERROR ,"encoding error"},
|
||||
{BN_R_EXPAND_ON_STATIC_BIGNUM_DATA ,"expand on static bignum data"},
|
||||
{BN_R_INVALID_LENGTH ,"invalid length"},
|
||||
{BN_R_INVALID_RANGE ,"invalid range"},
|
||||
{BN_R_NOT_INITIALIZED ,"not initialized"},
|
||||
{BN_R_NO_INVERSE ,"no inverse"},
|
||||
{BN_R_TOO_MANY_TEMPORARY_VARIABLES ,"too many temporary variables"},
|
||||
|
@@ -62,6 +62,7 @@
|
||||
#endif
|
||||
|
||||
#include <assert.h>
|
||||
#include <limits.h>
|
||||
#include <stdio.h>
|
||||
#include "cryptlib.h"
|
||||
#include "bn_lcl.h"
|
||||
@@ -319,6 +320,12 @@ BIGNUM *bn_expand2(BIGNUM *b, int words)
|
||||
|
||||
if (words > b->dmax)
|
||||
{
|
||||
if (words > (INT_MAX/(4*BN_BITS2)))
|
||||
{
|
||||
BNerr(BN_F_BN_EXPAND2,BN_R_BIGNUM_TOO_LONG);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
bn_check_top(b);
|
||||
if (BN_get_flags(b,BN_FLG_STATIC_DATA))
|
||||
{
|
||||
|
@@ -85,16 +85,7 @@ int BN_mod_mul_montgomery(BIGNUM *r, BIGNUM *a, BIGNUM *b,
|
||||
|
||||
if (a == b)
|
||||
{
|
||||
#if 1
|
||||
bn_wexpand(tmp,a->top*2);
|
||||
bn_wexpand(tmp2,a->top*4);
|
||||
bn_sqr_recursive(tmp->d,a->d,a->top,tmp2->d);
|
||||
tmp->top=a->top*2;
|
||||
if (tmp->top > 0 && tmp->d[tmp->top-1] == 0)
|
||||
tmp->top--;
|
||||
#else
|
||||
if (!BN_sqr(tmp,a,ctx)) goto err;
|
||||
#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -190,6 +181,7 @@ int BN_from_montgomery(BIGNUM *ret, BIGNUM *a, BN_MONT_CTX *mont,
|
||||
#if 0
|
||||
BN_rshift(ret,r,mont->ri);
|
||||
#else
|
||||
ret->neg = r->neg;
|
||||
x=ri;
|
||||
rp=ret->d;
|
||||
ap= &(r->d[x]);
|
||||
|
@@ -76,7 +76,7 @@ static int bnrand(int pseudorand, BIGNUM *rnd, int bits, int top, int bottom)
|
||||
|
||||
bytes=(bits+7)/8;
|
||||
bit=(bits-1)%8;
|
||||
mask=0xff<<bit;
|
||||
mask=0xff<<(bit+1);
|
||||
|
||||
buf=(unsigned char *)OPENSSL_malloc(bytes);
|
||||
if (buf == NULL)
|
||||
@@ -100,25 +100,48 @@ static int bnrand(int pseudorand, BIGNUM *rnd, int bits, int top, int bottom)
|
||||
goto err;
|
||||
}
|
||||
|
||||
if (top)
|
||||
#if 1
|
||||
if (pseudorand == 2)
|
||||
{
|
||||
if (bit == 0)
|
||||
/* generate patterns that are more likely to trigger BN
|
||||
library bugs */
|
||||
int i;
|
||||
unsigned char c;
|
||||
|
||||
for (i = 0; i < bytes; i++)
|
||||
{
|
||||
buf[0]=1;
|
||||
buf[1]|=0x80;
|
||||
RAND_pseudo_bytes(&c, 1);
|
||||
if (c >= 128 && i > 0)
|
||||
buf[i] = buf[i-1];
|
||||
else if (c < 42)
|
||||
buf[i] = 0;
|
||||
else if (c < 84)
|
||||
buf[i] = 255;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (top != -1)
|
||||
{
|
||||
if (top)
|
||||
{
|
||||
if (bit == 0)
|
||||
{
|
||||
buf[0]=1;
|
||||
buf[1]|=0x80;
|
||||
}
|
||||
else
|
||||
{
|
||||
buf[0]|=(3<<(bit-1));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
buf[0]|=(3<<(bit-1));
|
||||
buf[0]&= ~(mask<<1);
|
||||
buf[0]|=(1<<bit);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
buf[0]|=(1<<bit);
|
||||
buf[0]&= ~(mask<<1);
|
||||
}
|
||||
if (bottom) /* set bottom bits to whatever odd is */
|
||||
buf[0] &= ~mask;
|
||||
if (bottom) /* set bottom bit if requested */
|
||||
buf[bytes-1]|=1;
|
||||
if (!BN_bin2bn(buf,bytes,rnd)) goto err;
|
||||
ret=1;
|
||||
@@ -140,3 +163,61 @@ int BN_pseudo_rand(BIGNUM *rnd, int bits, int top, int bottom)
|
||||
{
|
||||
return bnrand(1, rnd, bits, top, bottom);
|
||||
}
|
||||
|
||||
#if 1
|
||||
int BN_bntest_rand(BIGNUM *rnd, int bits, int top, int bottom)
|
||||
{
|
||||
return bnrand(2, rnd, bits, top, bottom);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* random number r: 0 <= r < range */
|
||||
int BN_rand_range(BIGNUM *r, BIGNUM *range)
|
||||
{
|
||||
int n;
|
||||
|
||||
if (range->neg || BN_is_zero(range))
|
||||
{
|
||||
BNerr(BN_F_BN_RAND_RANGE, BN_R_INVALID_RANGE);
|
||||
return 0;
|
||||
}
|
||||
|
||||
n = BN_num_bits(range); /* n > 0 */
|
||||
|
||||
if (n == 1)
|
||||
{
|
||||
if (!BN_zero(r)) return 0;
|
||||
}
|
||||
else if (BN_is_bit_set(range, n - 2))
|
||||
{
|
||||
do
|
||||
{
|
||||
/* range = 11..._2, so each iteration succeeds with probability >= .75 */
|
||||
if (!BN_rand(r, n, -1, 0)) return 0;
|
||||
}
|
||||
while (BN_cmp(r, range) >= 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
/* range = 10..._2,
|
||||
* so 3*range (= 11..._2) is exactly one bit longer than range */
|
||||
do
|
||||
{
|
||||
if (!BN_rand(r, n + 1, -1, 0)) return 0;
|
||||
/* If r < 3*range, use r := r MOD range
|
||||
* (which is either r, r - range, or r - 2*range).
|
||||
* Otherwise, iterate once more.
|
||||
* Since 3*range = 11..._2, each iteration succeeds with
|
||||
* probability >= .75. */
|
||||
if (BN_cmp(r ,range) >= 0)
|
||||
{
|
||||
if (!BN_sub(r, r, range)) return 0;
|
||||
if (BN_cmp(r, range) >= 0)
|
||||
if (!BN_sub(r, r, range)) return 0;
|
||||
}
|
||||
}
|
||||
while (BN_cmp(r, range) >= 0);
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
@@ -172,6 +172,11 @@ int BN_rshift(BIGNUM *r, BIGNUM *a, int n)
|
||||
r->neg=a->neg;
|
||||
if (bn_wexpand(r,a->top-nw+1) == NULL) return(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (n == 0)
|
||||
return 1; /* or the copying loop will go berserk */
|
||||
}
|
||||
|
||||
f= &(a->d[nw]);
|
||||
t=r->d;
|
||||
|
@@ -188,7 +188,7 @@ void bn_sqr_normal(BN_ULONG *r, BN_ULONG *a, int n, BN_ULONG *tmp)
|
||||
|
||||
#ifdef BN_RECURSION
|
||||
/* r is 2*n words in size,
|
||||
* a and b are both n words in size.
|
||||
* a and b are both n words in size. (There's not actually a 'b' here ...)
|
||||
* n must be a power of 2.
|
||||
* We multiply and return the result.
|
||||
* t must be 2*n words in size
|
||||
|
@@ -107,11 +107,9 @@ static const char rnd_seed[] = "string to make the random number generator think
|
||||
static void message(BIO *out, char *m)
|
||||
{
|
||||
fprintf(stderr, "test %s\n", m);
|
||||
#if defined(linux) || defined(__FreeBSD__) /* can we use GNU bc features? */
|
||||
BIO_puts(out, "print \"test ");
|
||||
BIO_puts(out, m);
|
||||
BIO_puts(out, "\\n\"\n");
|
||||
#endif
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
@@ -122,9 +120,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
results = 0;
|
||||
|
||||
RAND_seed(rnd_seed, sizeof rnd_seed); /* or BN_rand may fail, and we don't
|
||||
* even check its return value
|
||||
* (which we should) */
|
||||
RAND_seed(rnd_seed, sizeof rnd_seed); /* or BN_generate_prime may fail */
|
||||
|
||||
argc--;
|
||||
argv++;
|
||||
@@ -253,10 +249,10 @@ int test_add(BIO *bp)
|
||||
BN_init(&b);
|
||||
BN_init(&c);
|
||||
|
||||
BN_rand(&a,512,0,0);
|
||||
BN_bntest_rand(&a,512,0,0);
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
BN_rand(&b,450+i,0,0);
|
||||
BN_bntest_rand(&b,450+i,0,0);
|
||||
a.neg=rand_neg();
|
||||
b.neg=rand_neg();
|
||||
if (bp == NULL)
|
||||
@@ -305,14 +301,14 @@ int test_sub(BIO *bp)
|
||||
{
|
||||
if (i < num1)
|
||||
{
|
||||
BN_rand(&a,512,0,0);
|
||||
BN_bntest_rand(&a,512,0,0);
|
||||
BN_copy(&b,&a);
|
||||
if (BN_set_bit(&a,i)==0) return(0);
|
||||
BN_add_word(&b,i);
|
||||
}
|
||||
else
|
||||
{
|
||||
BN_rand(&b,400+i-num1,0,0);
|
||||
BN_bntest_rand(&b,400+i-num1,0,0);
|
||||
a.neg=rand_neg();
|
||||
b.neg=rand_neg();
|
||||
}
|
||||
@@ -362,13 +358,13 @@ int test_div(BIO *bp, BN_CTX *ctx)
|
||||
{
|
||||
if (i < num1)
|
||||
{
|
||||
BN_rand(&a,400,0,0);
|
||||
BN_bntest_rand(&a,400,0,0);
|
||||
BN_copy(&b,&a);
|
||||
BN_lshift(&a,&a,i);
|
||||
BN_add_word(&a,i);
|
||||
}
|
||||
else
|
||||
BN_rand(&b,50+3*(i-num1),0,0);
|
||||
BN_bntest_rand(&b,50+3*(i-num1),0,0);
|
||||
a.neg=rand_neg();
|
||||
b.neg=rand_neg();
|
||||
if (bp == NULL)
|
||||
@@ -432,13 +428,13 @@ int test_div_recp(BIO *bp, BN_CTX *ctx)
|
||||
{
|
||||
if (i < num1)
|
||||
{
|
||||
BN_rand(&a,400,0,0);
|
||||
BN_bntest_rand(&a,400,0,0);
|
||||
BN_copy(&b,&a);
|
||||
BN_lshift(&a,&a,i);
|
||||
BN_add_word(&a,i);
|
||||
}
|
||||
else
|
||||
BN_rand(&b,50+3*(i-num1),0,0);
|
||||
BN_bntest_rand(&b,50+3*(i-num1),0,0);
|
||||
a.neg=rand_neg();
|
||||
b.neg=rand_neg();
|
||||
BN_RECP_CTX_set(&recp,&b,ctx);
|
||||
@@ -509,11 +505,11 @@ int test_mul(BIO *bp)
|
||||
{
|
||||
if (i <= num1)
|
||||
{
|
||||
BN_rand(&a,100,0,0);
|
||||
BN_rand(&b,100,0,0);
|
||||
BN_bntest_rand(&a,100,0,0);
|
||||
BN_bntest_rand(&b,100,0,0);
|
||||
}
|
||||
else
|
||||
BN_rand(&b,i-num1,0,0);
|
||||
BN_bntest_rand(&b,i-num1,0,0);
|
||||
a.neg=rand_neg();
|
||||
b.neg=rand_neg();
|
||||
if (bp == NULL)
|
||||
@@ -562,7 +558,7 @@ int test_sqr(BIO *bp, BN_CTX *ctx)
|
||||
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
BN_rand(&a,40+i*10,0,0);
|
||||
BN_bntest_rand(&a,40+i*10,0,0);
|
||||
a.neg=rand_neg();
|
||||
if (bp == NULL)
|
||||
for (j=0; j<100; j++)
|
||||
@@ -613,15 +609,15 @@ int test_mont(BIO *bp, BN_CTX *ctx)
|
||||
|
||||
mont=BN_MONT_CTX_new();
|
||||
|
||||
BN_rand(&a,100,0,0); /**/
|
||||
BN_rand(&b,100,0,0); /**/
|
||||
BN_bntest_rand(&a,100,0,0); /**/
|
||||
BN_bntest_rand(&b,100,0,0); /**/
|
||||
for (i=0; i<num2; i++)
|
||||
{
|
||||
int bits = (200*(i+1))/num2;
|
||||
|
||||
if (bits == 0)
|
||||
continue;
|
||||
BN_rand(&n,bits,0,1);
|
||||
BN_bntest_rand(&n,bits,0,1);
|
||||
BN_MONT_CTX_set(mont,&n,ctx);
|
||||
|
||||
BN_to_montgomery(&A,&a,mont,ctx);
|
||||
@@ -683,10 +679,10 @@ int test_mod(BIO *bp, BN_CTX *ctx)
|
||||
d=BN_new();
|
||||
e=BN_new();
|
||||
|
||||
BN_rand(a,1024,0,0); /**/
|
||||
BN_bntest_rand(a,1024,0,0); /**/
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
BN_rand(b,450+i*10,0,0); /**/
|
||||
BN_bntest_rand(b,450+i*10,0,0); /**/
|
||||
a->neg=rand_neg();
|
||||
b->neg=rand_neg();
|
||||
if (bp == NULL)
|
||||
@@ -732,11 +728,11 @@ int test_mod_mul(BIO *bp, BN_CTX *ctx)
|
||||
d=BN_new();
|
||||
e=BN_new();
|
||||
|
||||
BN_rand(c,1024,0,0); /**/
|
||||
BN_bntest_rand(c,1024,0,0); /**/
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
BN_rand(a,475+i*10,0,0); /**/
|
||||
BN_rand(b,425+i*11,0,0); /**/
|
||||
BN_bntest_rand(a,475+i*10,0,0); /**/
|
||||
BN_bntest_rand(b,425+i*11,0,0); /**/
|
||||
a->neg=rand_neg();
|
||||
b->neg=rand_neg();
|
||||
/* if (bp == NULL)
|
||||
@@ -794,11 +790,11 @@ int test_mod_exp(BIO *bp, BN_CTX *ctx)
|
||||
d=BN_new();
|
||||
e=BN_new();
|
||||
|
||||
BN_rand(c,30,0,1); /* must be odd for montgomery */
|
||||
BN_bntest_rand(c,30,0,1); /* must be odd for montgomery */
|
||||
for (i=0; i<num2; i++)
|
||||
{
|
||||
BN_rand(a,20+i*5,0,0); /**/
|
||||
BN_rand(b,2+i,0,0); /**/
|
||||
BN_bntest_rand(a,20+i*5,0,0); /**/
|
||||
BN_bntest_rand(b,2+i,0,0); /**/
|
||||
|
||||
if (!BN_mod_exp(d,a,b,c,ctx))
|
||||
return(00);
|
||||
@@ -848,8 +844,8 @@ int test_exp(BIO *bp, BN_CTX *ctx)
|
||||
|
||||
for (i=0; i<num2; i++)
|
||||
{
|
||||
BN_rand(a,20+i*5,0,0); /**/
|
||||
BN_rand(b,2+i,0,0); /**/
|
||||
BN_bntest_rand(a,20+i*5,0,0); /**/
|
||||
BN_bntest_rand(b,2+i,0,0); /**/
|
||||
|
||||
if (!BN_exp(d,a,b,ctx))
|
||||
return(00);
|
||||
@@ -899,7 +895,7 @@ int test_lshift(BIO *bp,BN_CTX *ctx,BIGNUM *a_)
|
||||
else
|
||||
{
|
||||
a=BN_new();
|
||||
BN_rand(a,200,0,0); /**/
|
||||
BN_bntest_rand(a,200,0,0); /**/
|
||||
a->neg=rand_neg();
|
||||
}
|
||||
for (i=0; i<num0; i++)
|
||||
@@ -951,7 +947,7 @@ int test_lshift1(BIO *bp)
|
||||
b=BN_new();
|
||||
c=BN_new();
|
||||
|
||||
BN_rand(a,200,0,0); /**/
|
||||
BN_bntest_rand(a,200,0,0); /**/
|
||||
a->neg=rand_neg();
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
@@ -995,7 +991,7 @@ int test_rshift(BIO *bp,BN_CTX *ctx)
|
||||
e=BN_new();
|
||||
BN_one(c);
|
||||
|
||||
BN_rand(a,200,0,0); /**/
|
||||
BN_bntest_rand(a,200,0,0); /**/
|
||||
a->neg=rand_neg();
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
@@ -1038,7 +1034,7 @@ int test_rshift1(BIO *bp)
|
||||
b=BN_new();
|
||||
c=BN_new();
|
||||
|
||||
BN_rand(a,200,0,0); /**/
|
||||
BN_bntest_rand(a,200,0,0); /**/
|
||||
a->neg=rand_neg();
|
||||
for (i=0; i<num0; i++)
|
||||
{
|
||||
|
@@ -39,7 +39,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
files:
|
||||
|
@@ -47,7 +47,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
# elf
|
||||
|
@@ -42,7 +42,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
files:
|
||||
|
@@ -40,7 +40,8 @@ all: lib
|
||||
|
||||
lib: $(LIBOBJ)
|
||||
$(AR) $(LIB) $(LIBOBJ)
|
||||
$(RANLIB) $(LIB)
|
||||
@echo You may get an error following this line. Please ignore.
|
||||
- $(RANLIB) $(LIB)
|
||||
@touch lib
|
||||
|
||||
files:
|
||||
|
@@ -167,6 +167,8 @@ int NCONF_dump_bio(CONF *conf, BIO *out);
|
||||
#define CONF_R_MISSING_EQUAL_SIGN 101
|
||||
#define CONF_R_NO_CLOSE_BRACE 102
|
||||
#define CONF_R_NO_CONF 105
|
||||
#define CONF_R_NO_CONF_OR_ENVIRONMENT_VARIABLE 106
|
||||
#define CONF_R_NO_SECTION 107
|
||||
#define CONF_R_UNABLE_TO_CREATE_NEW_SECTION 103
|
||||
#define CONF_R_VARIABLE_HAS_NO_VALUE 104
|
||||
|
||||
|
@@ -87,6 +87,8 @@ static ERR_STRING_DATA CONF_str_reasons[]=
|
||||
{CONF_R_MISSING_EQUAL_SIGN ,"missing equal sign"},
|
||||
{CONF_R_NO_CLOSE_BRACE ,"no close brace"},
|
||||
{CONF_R_NO_CONF ,"no conf"},
|
||||
{CONF_R_NO_CONF_OR_ENVIRONMENT_VARIABLE ,"no conf or environment variable"},
|
||||
{CONF_R_NO_SECTION ,"no section"},
|
||||
{CONF_R_UNABLE_TO_CREATE_NEW_SECTION ,"unable to create new section"},
|
||||
{CONF_R_VARIABLE_HAS_NO_VALUE ,"variable has no value"},
|
||||
{0,NULL}
|
||||
|
@@ -131,38 +131,59 @@ LHASH *CONF_load_bio(LHASH *conf, BIO *bp,long *eline)
|
||||
|
||||
STACK_OF(CONF_VALUE) *CONF_get_section(LHASH *conf,char *section)
|
||||
{
|
||||
CONF ctmp;
|
||||
if (conf == NULL)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
else
|
||||
{
|
||||
CONF ctmp;
|
||||
|
||||
if (default_CONF_method == NULL)
|
||||
default_CONF_method = NCONF_default();
|
||||
if (default_CONF_method == NULL)
|
||||
default_CONF_method = NCONF_default();
|
||||
|
||||
default_CONF_method->init(&ctmp);
|
||||
ctmp.data = conf;
|
||||
return NCONF_get_section(&ctmp, section);
|
||||
default_CONF_method->init(&ctmp);
|
||||
ctmp.data = conf;
|
||||
return NCONF_get_section(&ctmp, section);
|
||||
}
|
||||
}
|
||||
|
||||
char *CONF_get_string(LHASH *conf,char *group,char *name)
|
||||
{
|
||||
CONF ctmp;
|
||||
if (conf == NULL)
|
||||
{
|
||||
return NCONF_get_string(NULL, group, name);
|
||||
}
|
||||
else
|
||||
{
|
||||
CONF ctmp;
|
||||
|
||||
if (default_CONF_method == NULL)
|
||||
default_CONF_method = NCONF_default();
|
||||
if (default_CONF_method == NULL)
|
||||
default_CONF_method = NCONF_default();
|
||||
|
||||
default_CONF_method->init(&ctmp);
|
||||
ctmp.data = conf;
|
||||
return NCONF_get_string(&ctmp, group, name);
|
||||
default_CONF_method->init(&ctmp);
|
||||
ctmp.data = conf;
|
||||
return NCONF_get_string(&ctmp, group, name);
|
||||
}
|
||||
}
|
||||
|
||||
long CONF_get_number(LHASH *conf,char *group,char *name)
|
||||
{
|
||||
CONF ctmp;
|
||||
if (conf == NULL)
|
||||
{
|
||||
return NCONF_get_number(NULL, group, name);
|
||||
}
|
||||
else
|
||||
{
|
||||
CONF ctmp;
|
||||
|
||||
if (default_CONF_method == NULL)
|
||||
default_CONF_method = NCONF_default();
|
||||
if (default_CONF_method == NULL)
|
||||
default_CONF_method = NCONF_default();
|
||||
|
||||
default_CONF_method->init(&ctmp);
|
||||
ctmp.data = conf;
|
||||
return NCONF_get_number(&ctmp, group, name);
|
||||
default_CONF_method->init(&ctmp);
|
||||
ctmp.data = conf;
|
||||
return NCONF_get_number(&ctmp, group, name);
|
||||
}
|
||||
}
|
||||
|
||||
void CONF_free(LHASH *conf)
|
||||
@@ -299,27 +320,46 @@ STACK_OF(CONF_VALUE) *NCONF_get_section(CONF *conf,char *section)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (section == NULL)
|
||||
{
|
||||
CONFerr(CONF_F_NCONF_GET_SECTION,CONF_R_NO_SECTION);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return _CONF_get_section_values(conf, section);
|
||||
}
|
||||
|
||||
char *NCONF_get_string(CONF *conf,char *group,char *name)
|
||||
{
|
||||
char *s = _CONF_get_string(conf, group, name);
|
||||
|
||||
/* Since we may get a value from an environment variable even
|
||||
if conf is NULL, let's check the value first */
|
||||
if (s) return s;
|
||||
|
||||
if (conf == NULL)
|
||||
{
|
||||
CONFerr(CONF_F_NCONF_GET_STRING,CONF_R_NO_CONF);
|
||||
CONFerr(CONF_F_NCONF_GET_STRING,
|
||||
CONF_R_NO_CONF_OR_ENVIRONMENT_VARIABLE);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return _CONF_get_string(conf, group, name);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
long NCONF_get_number(CONF *conf,char *group,char *name)
|
||||
{
|
||||
#if 0 /* As with _CONF_get_string(), we rely on the possibility of finding
|
||||
an environment variable with a suitable name. Unfortunately, there's
|
||||
no way with the current API to see if we found one or not...
|
||||
The meaning of this is that if a number is not found anywhere, it
|
||||
will always default to 0. */
|
||||
if (conf == NULL)
|
||||
{
|
||||
CONFerr(CONF_F_NCONF_GET_NUMBER,CONF_R_NO_CONF);
|
||||
CONFerr(CONF_F_NCONF_GET_NUMBER,
|
||||
CONF_R_NO_CONF_OR_ENVIRONMENT_VARIABLE);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
return _CONF_get_number(conf, group, name);
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user