Compare commits
2012 Commits
OpenSSL_0_
...
FIPS_TEST_
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3da3c85a3f | ||
|
|
d58d546e2d | ||
|
|
780b97aba6 | ||
|
|
e0ec2d772c | ||
|
|
5fbf6769fc | ||
|
|
7bf79446c8 | ||
|
|
bdee60fc1a | ||
|
|
0b62d2f4c9 | ||
|
|
4375ca95a4 | ||
|
|
acce7b5963 | ||
|
|
c5098ee16f | ||
|
|
6d0e43d555 | ||
|
|
9f32d49de9 | ||
|
|
db84c9075b | ||
|
|
e96fad9d2d | ||
|
|
0c7b06714e | ||
|
|
d893001918 | ||
|
|
b8bd781b7e | ||
|
|
bb792a485a | ||
|
|
452421d059 | ||
|
|
ea8399724e | ||
|
|
26655341fc | ||
|
|
5858d32a59 | ||
|
|
0dfe532ea9 | ||
|
|
5c567ffd4c | ||
|
|
3bc1781994 | ||
|
|
485bcc9cab | ||
|
|
bb1bbb3274 | ||
|
|
4bd7bc97e8 | ||
|
|
4d4339922c | ||
|
|
c3d03b70af | ||
|
|
e4c2c550b9 | ||
|
|
570357b7a8 | ||
|
|
7044d328a2 | ||
|
|
35d7cc8166 | ||
|
|
80790d89ec | ||
|
|
7bad200b49 | ||
|
|
6b6f64da2d | ||
|
|
31def5ae59 | ||
|
|
713407a5c7 | ||
|
|
db73333585 | ||
|
|
84c9b6edb1 | ||
|
|
e609c04994 | ||
|
|
53cfa36d37 | ||
|
|
b10bd63df3 | ||
|
|
44a287747f | ||
|
|
20a413620c | ||
|
|
e99b588f1b | ||
|
|
48a3f2818e | ||
|
|
fc0e014ca3 | ||
|
|
8baaeba881 | ||
|
|
150ebacd8a | ||
|
|
bedcd5c0bb | ||
|
|
fd86c390eb | ||
|
|
63453c025f | ||
|
|
ecb1445ce2 | ||
|
|
64c32bf9eb | ||
|
|
775e82c58d | ||
|
|
db5cbd8954 | ||
|
|
c6012b252d | ||
|
|
e1ff593dcb | ||
|
|
c4d9c13a31 | ||
|
|
00c1c6cb28 | ||
|
|
973fbfe3a3 | ||
|
|
9fc1d3f4c4 | ||
|
|
765863f0bf | ||
|
|
cbd72088ec | ||
|
|
8aabdf3505 | ||
|
|
fcec494072 | ||
|
|
88f62fb98a | ||
|
|
69488fa929 | ||
|
|
b0367dde56 | ||
|
|
ad93095f16 | ||
|
|
82b47955fc | ||
|
|
95477d36f6 | ||
|
|
eb798944b3 | ||
|
|
b1ca6f2f3d | ||
|
|
102e6481ae | ||
|
|
97949ccfc8 | ||
|
|
44e9bc81eb | ||
|
|
4b27a9feb3 | ||
|
|
0649b6f0f2 | ||
|
|
389ff2e01f | ||
|
|
8cf1846857 | ||
|
|
2dab26339d | ||
|
|
239e31f896 | ||
|
|
4bf3222d96 | ||
|
|
3380c4561e | ||
|
|
3f2f0c8892 | ||
|
|
0ee883650d | ||
|
|
70cf309517 | ||
|
|
8b5bf52ac2 | ||
|
|
73a9485081 | ||
|
|
d37a65bc81 | ||
|
|
9dc4f157bc | ||
|
|
34c7ff6dc9 | ||
|
|
647907918d | ||
|
|
cee73df3bd | ||
|
|
07481951f9 | ||
|
|
f15c448a72 | ||
|
|
fcb41c0ee8 | ||
|
|
8513320593 | ||
|
|
9b62318311 | ||
|
|
c1efb6705f | ||
|
|
5f1841cdca | ||
|
|
4b45051902 | ||
|
|
f07320eae0 | ||
|
|
9e5790ce21 | ||
|
|
a0724cb261 | ||
|
|
cdbba1067f | ||
|
|
d837ca70f7 | ||
|
|
fb64e17555 | ||
|
|
e8f245d243 | ||
|
|
fce8c6cc53 | ||
|
|
0ff469d38d | ||
|
|
73f3c281ff | ||
|
|
05338b58ce | ||
|
|
081057c3ff | ||
|
|
94c1672ef0 | ||
|
|
405d9761a5 | ||
|
|
4c3a2d64e4 | ||
|
|
6a62b2e54b | ||
|
|
98a2fd32a0 | ||
|
|
7bdeeb64ac | ||
|
|
43b45a42fd | ||
|
|
9af1bfb3d5 | ||
|
|
aed14edd12 | ||
|
|
14a948e6ad | ||
|
|
af2fcf3a65 | ||
|
|
4a676ac4f8 | ||
|
|
37e27219f2 | ||
|
|
d2284ab5d1 | ||
|
|
78e91e7574 | ||
|
|
c1668fe59d | ||
|
|
e1cc0671ac | ||
|
|
c1a8a5de13 | ||
|
|
e3d0e0a792 | ||
|
|
7c7667b86b | ||
|
|
38be5db93b | ||
|
|
6a50d0a422 | ||
|
|
7ab2d30349 | ||
|
|
d753c3f582 | ||
|
|
1897c89302 | ||
|
|
9aa260ab57 | ||
|
|
c7e7d382d5 | ||
|
|
3cc54008eb | ||
|
|
ff8bcccdd4 | ||
|
|
81170986ed | ||
|
|
a93b01be57 | ||
|
|
04b304d346 | ||
|
|
6c61726b2a | ||
|
|
cd202fe2f9 | ||
|
|
69af4faec1 | ||
|
|
4b21c202ff | ||
|
|
df9e0bf507 | ||
|
|
879b19801a | ||
|
|
6ec8e63af6 | ||
|
|
465b9f6b26 | ||
|
|
0c9c87a76e | ||
|
|
a7a90b2f00 | ||
|
|
4d6e7733fa | ||
|
|
2deadf1672 | ||
|
|
9ea862e0b3 | ||
|
|
11c9b7cfeb | ||
|
|
b08868c48a | ||
|
|
9ca46ff609 | ||
|
|
800e400de5 | ||
|
|
05886a6f77 | ||
|
|
667aef4c6a | ||
|
|
49e179cc52 | ||
|
|
aa4ce7315f | ||
|
|
c741b83762 | ||
|
|
64387788a9 | ||
|
|
480506bd49 | ||
|
|
0d5ea7613e | ||
|
|
beb056b303 | ||
|
|
4e321ffaff | ||
|
|
6ededa42db | ||
|
|
36d16f8ee0 | ||
|
|
ab781a0cb6 | ||
|
|
19c2987eb6 | ||
|
|
b09af97686 | ||
|
|
a7b1c7732f | ||
|
|
abc64463af | ||
|
|
2e7245f5a3 | ||
|
|
f76b062e16 | ||
|
|
cc1717eaa4 | ||
|
|
c5156d952e | ||
|
|
0b2d0d7d13 | ||
|
|
b732a8cf5f | ||
|
|
a7dc451ebe | ||
|
|
1e764f463e | ||
|
|
87357fc0b8 | ||
|
|
a2c96d888d | ||
|
|
a7a0af0ca4 | ||
|
|
9a6c6b99bf | ||
|
|
033c79dff1 | ||
|
|
b362536275 | ||
|
|
aa16a28631 | ||
|
|
2757c67da2 | ||
|
|
148111ff0a | ||
|
|
3d5fd31280 | ||
|
|
c7199e62f1 | ||
|
|
0b3fc6e63b | ||
|
|
c2db9cfb52 | ||
|
|
6bc8e6b898 | ||
|
|
6eb4958989 | ||
|
|
9edf4e8157 | ||
|
|
b07a7b5daa | ||
|
|
965a1cb92e | ||
|
|
e9ad6665a5 | ||
|
|
b5855b2f32 | ||
|
|
a0bee97e55 | ||
|
|
e7076c5a80 | ||
|
|
ff22e913a3 | ||
|
|
132f25950b | ||
|
|
4ed56cba63 | ||
|
|
145878ca29 | ||
|
|
a36c30136e | ||
|
|
04d0d0accf | ||
|
|
92ad8e5c37 | ||
|
|
00df894701 | ||
|
|
630e4a6e59 | ||
|
|
bf2336f478 | ||
|
|
4f6c2bacb1 | ||
|
|
384dba6edb | ||
|
|
2c45bf2bc9 | ||
|
|
836ec0c764 | ||
|
|
5e72fb063a | ||
|
|
d9536ccffa | ||
|
|
37ce8cffcc | ||
|
|
2dc08d5f5d | ||
|
|
00b8abee61 | ||
|
|
7efebab9fd | ||
|
|
a74286d636 | ||
|
|
254cfe878e | ||
|
|
ed824195a1 | ||
|
|
22c3600e4c | ||
|
|
49f386578e | ||
|
|
7c671508bd | ||
|
|
76693ca0a3 | ||
|
|
d3fdc27aa8 | ||
|
|
4182f0ffc7 | ||
|
|
40e950aed6 | ||
|
|
0ef4ec4fd4 | ||
|
|
f868b61376 | ||
|
|
987bebaf8c | ||
|
|
65f0efe198 | ||
|
|
e77d8f2ecd | ||
|
|
f68854b4c3 | ||
|
|
c61a8ad5b0 | ||
|
|
89234b1eed | ||
|
|
2ec5ebb979 | ||
|
|
863a155451 | ||
|
|
1ddce0bebf | ||
|
|
4347c0a76d | ||
|
|
f1429a972f | ||
|
|
45bc841b22 | ||
|
|
7a111bc864 | ||
|
|
1cfd258ed6 | ||
|
|
04d7d51ea2 | ||
|
|
48d0ba4a1e | ||
|
|
0e23faec0a | ||
|
|
7590f37fd7 | ||
|
|
2906dc8601 | ||
|
|
c8d5c71af5 | ||
|
|
ff990440ee | ||
|
|
0e304b7f41 | ||
|
|
f97b4a776e | ||
|
|
b99daf76a7 | ||
|
|
8fc6cb77c5 | ||
|
|
fbe6ba81e9 | ||
|
|
b219bb8f62 | ||
|
|
2b85e23d2e | ||
|
|
026bb0b96a | ||
|
|
6424498226 | ||
|
|
0b418c7d51 | ||
|
|
13051e9316 | ||
|
|
0174c56851 | ||
|
|
3ed449e94a | ||
|
|
4f1c33b430 | ||
|
|
1334462ab3 | ||
|
|
a34f2d42b4 | ||
|
|
5dc4923359 | ||
|
|
e62991a07c | ||
|
|
52272327f3 | ||
|
|
5820d87a5f | ||
|
|
1bf955920a | ||
|
|
89b1fd98ac | ||
|
|
51d28013db | ||
|
|
ee2bf876c2 | ||
|
|
8861ba355d | ||
|
|
e44f62c2b1 | ||
|
|
9e88c82703 | ||
|
|
9d2f51c086 | ||
|
|
ad0db060b1 | ||
|
|
3547478fc8 | ||
|
|
29dc350813 | ||
|
|
342b7e0458 | ||
|
|
bc3cae7e7d | ||
|
|
96534114a3 | ||
|
|
4ecd7d2b7e | ||
|
|
9d728b8d10 | ||
|
|
37942fab51 | ||
|
|
d060fc9ff2 | ||
|
|
22e5a7935f | ||
|
|
01671ab2df | ||
|
|
36521f0150 | ||
|
|
93aeac64ce | ||
|
|
9addd9b6fb | ||
|
|
0231911dec | ||
|
|
4bb61becbb | ||
|
|
b392e52050 | ||
|
|
0858b71b41 | ||
|
|
657129f748 | ||
|
|
c710c7b3a3 | ||
|
|
ff731ae3db | ||
|
|
d9bfe4f97c | ||
|
|
dc0ed30cfe | ||
|
|
e248596bac | ||
|
|
6049399baf | ||
|
|
f763e0b5ae | ||
|
|
eb3eab20a8 | ||
|
|
6d69d74bb8 | ||
|
|
4848cbf1cf | ||
|
|
9f2027e56d | ||
|
|
4d2b407ba2 | ||
|
|
e1d51de41f | ||
|
|
81ee80ab88 | ||
|
|
7d727231b7 | ||
|
|
69740c2b3f | ||
|
|
119d1a1dd4 | ||
|
|
afe01cd3f6 | ||
|
|
70f34a5841 | ||
|
|
c2e40d0f9a | ||
|
|
0abfd60604 | ||
|
|
e5dbccc182 | ||
|
|
f8fa22d826 | ||
|
|
c393222280 | ||
|
|
631bae4723 | ||
|
|
f6bfb559f7 | ||
|
|
60fd574cdf | ||
|
|
73705abc34 | ||
|
|
12bdb64375 | ||
|
|
7bdf8eed69 | ||
|
|
bbc0ac37b0 | ||
|
|
48c832b6b7 | ||
|
|
8298632d14 | ||
|
|
f3e427f6f9 | ||
|
|
62a25c6129 | ||
|
|
8bb826ee53 | ||
|
|
ce53d920fb | ||
|
|
884b3fc23c | ||
|
|
5d1430f390 | ||
|
|
45d10efc35 | ||
|
|
db3cb0e97a | ||
|
|
41a15c4f0f | ||
|
|
fea4280a8b | ||
|
|
e852b8533f | ||
|
|
20a3439ea9 | ||
|
|
a273a2824c | ||
|
|
24c97c819d | ||
|
|
42ba5d2329 | ||
|
|
c3e6402857 | ||
|
|
0821bcd4de | ||
|
|
c3e28480d7 | ||
|
|
4a6a2032ed | ||
|
|
e72b9658f8 | ||
|
|
c01d2b974e | ||
|
|
8c04994bfe | ||
|
|
989c0f8215 | ||
|
|
b0ef321cc8 | ||
|
|
7a8c728860 | ||
|
|
4cf8f9369c | ||
|
|
6141b86a49 | ||
|
|
2950db5995 | ||
|
|
801fea5f11 | ||
|
|
da26bcb5de | ||
|
|
23fadaa084 | ||
|
|
d99382039c | ||
|
|
9c29e781a8 | ||
|
|
93acf33440 | ||
|
|
5c1fd5e316 | ||
|
|
f42a82777d | ||
|
|
0c7ceb3748 | ||
|
|
e27a259696 | ||
|
|
41e455bfc4 | ||
|
|
e54e4bcf1f | ||
|
|
fe8b77753c | ||
|
|
d5c2bc4bff | ||
|
|
59b6836ab2 | ||
|
|
61823b6a74 | ||
|
|
9fc9b55237 | ||
|
|
ab0def8152 | ||
|
|
689c6f2542 | ||
|
|
f4bfd357e5 | ||
|
|
6d2a7098d6 | ||
|
|
130db968b8 | ||
|
|
8d274837e5 | ||
|
|
5855038049 | ||
|
|
b43b9de9e4 | ||
|
|
d18685d959 | ||
|
|
9f6715d4bb | ||
|
|
ab185b6038 | ||
|
|
6286bbecef | ||
|
|
1642000707 | ||
|
|
9d14506f29 | ||
|
|
7ec40a480b | ||
|
|
aa0d4ed5fa | ||
|
|
2cf68c0b1a | ||
|
|
f7f2125522 | ||
|
|
2b61034b0b | ||
|
|
97d49cdd6f | ||
|
|
80c808b90b | ||
|
|
af1048c25c | ||
|
|
ecc5ef8793 | ||
|
|
c9a112f540 | ||
|
|
5286db697f | ||
|
|
126179aad0 | ||
|
|
f69a8aebab | ||
|
|
e22e6bf0be | ||
|
|
2ecf923286 | ||
|
|
9d10b15ef9 | ||
|
|
da30c74a27 | ||
|
|
67ea999d4a | ||
|
|
e1892f2370 | ||
|
|
fe28866d71 | ||
|
|
b7fd453675 | ||
|
|
de4ab1e629 | ||
|
|
216ddfaf6b | ||
|
|
086dd3032f | ||
|
|
20e5177105 | ||
|
|
8aa36bcac9 | ||
|
|
bb987c73a9 | ||
|
|
485e30dbe1 | ||
|
|
515ac3debb | ||
|
|
877dbcb8a0 | ||
|
|
43509de33d | ||
|
|
62d27939c2 | ||
|
|
dbaa6f91aa | ||
|
|
01b62dca25 | ||
|
|
66d68327cb | ||
|
|
ecc3d2734d | ||
|
|
11536fbac8 | ||
|
|
7cfcca8ba3 | ||
|
|
8c3c570134 | ||
|
|
0cae19f5ef | ||
|
|
97a1630e81 | ||
|
|
6be00c7e16 | ||
|
|
bf746f0f46 | ||
|
|
532d936be8 | ||
|
|
a229e3038e | ||
|
|
d88edf1447 | ||
|
|
4aca9297dc | ||
|
|
f60fc19a69 | ||
|
|
d0edffc7da | ||
|
|
b2c5960935 | ||
|
|
12dfa84310 | ||
|
|
fbdce13e5a | ||
|
|
e532a6c449 | ||
|
|
14bcdb087f | ||
|
|
b7efa56a4a | ||
|
|
8359421d90 | ||
|
|
efde5230f1 | ||
|
|
f5ffad9d1d | ||
|
|
57a68b2129 | ||
|
|
bac252a5e3 | ||
|
|
a963395a7b | ||
|
|
d8863f0bdb | ||
|
|
addb6e16a8 | ||
|
|
4d27c4c960 | ||
|
|
ed65fab910 | ||
|
|
90cc40911b | ||
|
|
134d6a44ec | ||
|
|
a7201e9a1b | ||
|
|
420eb6a306 | ||
|
|
fcd5cca418 | ||
|
|
9222bc6b4e | ||
|
|
e9ddd85965 | ||
|
|
ea28f93c2d | ||
|
|
adeb20b6b7 | ||
|
|
086b64d0d3 | ||
|
|
e6d27baf52 | ||
|
|
e7e1150706 | ||
|
|
5d727078ac | ||
|
|
108159ffcc | ||
|
|
c4d423511a | ||
|
|
b15a93a9c5 | ||
|
|
47c88d7413 | ||
|
|
630b9d70fb | ||
|
|
c4929fb841 | ||
|
|
97c2c819b3 | ||
|
|
954f3c3126 | ||
|
|
d9248e5780 | ||
|
|
0b52f89b81 | ||
|
|
528584c595 | ||
|
|
5cdf5e3308 | ||
|
|
7de4b5b060 | ||
|
|
02a00bb054 | ||
|
|
b58560b915 | ||
|
|
76d088046c | ||
|
|
83f69163fd | ||
|
|
3b4de6e4cc | ||
|
|
bdbc9b4d1a | ||
|
|
5ca3a0aa86 | ||
|
|
702be727c0 | ||
|
|
09ef94d2c9 | ||
|
|
8336cec34d | ||
|
|
3ffb8d42bc | ||
|
|
1c8415fdf3 | ||
|
|
25866e3982 | ||
|
|
3b3df98ca6 | ||
|
|
2e4a99f38b | ||
|
|
e90faddaf8 | ||
|
|
370d418a7b | ||
|
|
f1ce306f30 | ||
|
|
37b11ca78e | ||
|
|
a17af9e277 | ||
|
|
6951c23afd | ||
|
|
4aaa4f267d | ||
|
|
de421076a5 | ||
|
|
f709ffe832 | ||
|
|
bd16cd6bcc | ||
|
|
0c51600203 | ||
|
|
9e34e806a2 | ||
|
|
2d16a957e0 | ||
|
|
9850f7f6b2 | ||
|
|
131e064e4a | ||
|
|
556b8f3f77 | ||
|
|
045d3285e2 | ||
|
|
d1df5b4339 | ||
|
|
25558bf743 | ||
|
|
713147109c | ||
|
|
76ef6ac956 | ||
|
|
fe707c3260 | ||
|
|
fb39cd850c | ||
|
|
560f01fff9 | ||
|
|
15bbc1574f | ||
|
|
1acf071cd0 | ||
|
|
3ae613e34f | ||
|
|
a842df6659 | ||
|
|
c05a7f5dfd | ||
|
|
627bd6709c | ||
|
|
fbf218b8c3 | ||
|
|
3c97bd833b | ||
|
|
37ece6156a | ||
|
|
abbc186bd2 | ||
|
|
de6859e442 | ||
|
|
965574039b | ||
|
|
5e8904f289 | ||
|
|
535178f415 | ||
|
|
a4a88eea03 | ||
|
|
a661c1728f | ||
|
|
13e387c3fe | ||
|
|
0c0788ba0a | ||
|
|
3dd16fb7fd | ||
|
|
ab09133881 | ||
|
|
90ec459be0 | ||
|
|
3d5d6f9658 | ||
|
|
bd5a2195de | ||
|
|
5868130e7a | ||
|
|
905fd45b36 | ||
|
|
c162b132eb | ||
|
|
a4c9668f3c | ||
|
|
f1ca15dd69 | ||
|
|
b4e0ce5165 | ||
|
|
17f0e916db | ||
|
|
3d4c78e7f5 | ||
|
|
95f5b1fdae | ||
|
|
c78b389cb3 | ||
|
|
3dfa23cbc4 | ||
|
|
b0ab906524 | ||
|
|
a37e22d866 | ||
|
|
41c70d47d7 | ||
|
|
ec46cd8bb8 | ||
|
|
da8534693c | ||
|
|
a0e7c8eede | ||
|
|
b56b02dc75 | ||
|
|
a8e00b17ce | ||
|
|
c98175bf88 | ||
|
|
3e66ee9f01 | ||
|
|
3384bdd6fe | ||
|
|
5b40d7dd97 | ||
|
|
8db8893cd7 | ||
|
|
8f284faaec | ||
|
|
3010b1730e | ||
|
|
f670069a19 | ||
|
|
575dbdc965 | ||
|
|
f774accdbf | ||
|
|
8544a80776 | ||
|
|
2e1366366e | ||
|
|
fda344ece8 | ||
|
|
280e3bd2c9 | ||
|
|
7c69478064 | ||
|
|
41191d14ce | ||
|
|
1862dae862 | ||
|
|
62c19d2dd9 | ||
|
|
2d1a37bc9f | ||
|
|
24e85c3dee | ||
|
|
b7b46c9a87 | ||
|
|
e6e1f4cb5e | ||
|
|
5073ff0346 | ||
|
|
fa032a6941 | ||
|
|
fc7fc5678f | ||
|
|
7a3240e319 | ||
|
|
5022e4ecdf | ||
|
|
d133618ce2 | ||
|
|
30b415b076 | ||
|
|
cd52956357 | ||
|
|
914c2a28c0 | ||
|
|
6826d26ea7 | ||
|
|
18ad97bbe7 | ||
|
|
ea681ba872 | ||
|
|
bc3e7fabe7 | ||
|
|
d675c74d14 | ||
|
|
ee3f520276 | ||
|
|
59c7029862 | ||
|
|
9199bd0cd7 | ||
|
|
4443f44012 | ||
|
|
1582a4073e | ||
|
|
401ee37a3e | ||
|
|
cb26a20cb1 | ||
|
|
82c4674e47 | ||
|
|
dfcf822c65 | ||
|
|
9d2996b82f | ||
|
|
14c8986f75 | ||
|
|
3fee255102 | ||
|
|
6237528c82 | ||
|
|
16df5f066a | ||
|
|
959f9b1158 | ||
|
|
376729e130 | ||
|
|
2b354390b8 | ||
|
|
00dd8f6d6e | ||
|
|
5dd87981bf | ||
|
|
37dccd8ff2 | ||
|
|
826a42a088 | ||
|
|
19f39703f7 | ||
|
|
1ec0d15e54 | ||
|
|
151368ccba | ||
|
|
4451c2558e | ||
|
|
ce165addd2 | ||
|
|
b207a73ca6 | ||
|
|
4a64f3d665 | ||
|
|
5fee606442 | ||
|
|
22a7a3b91b | ||
|
|
ced27cc681 | ||
|
|
ffec31f1ac | ||
|
|
521aaafc6a | ||
|
|
e510c62a38 | ||
|
|
78df5a2f1e | ||
|
|
671c1bcfce | ||
|
|
6c9f57d629 | ||
|
|
382342ce1d | ||
|
|
28a896f7fe | ||
|
|
69c922f5d2 | ||
|
|
f6549efa61 | ||
|
|
10c8505734 | ||
|
|
4ae135eb0d | ||
|
|
10f92aac33 | ||
|
|
9262f5a3fa | ||
|
|
f94481196c | ||
|
|
68d9e764cb | ||
|
|
17f847af21 | ||
|
|
8de69cf2c6 | ||
|
|
a2ac429da2 | ||
|
|
a2617f727d | ||
|
|
ffd0f93f14 | ||
|
|
15aa44d230 | ||
|
|
3955a76946 | ||
|
|
ee478901b0 | ||
|
|
1a4b8e7cee | ||
|
|
a28e18219b | ||
|
|
871080b94b | ||
|
|
c133cb8974 | ||
|
|
03386677ed | ||
|
|
559f90ff60 | ||
|
|
2f547d2c1c | ||
|
|
bfb7bac83b | ||
|
|
ac4fb4a138 | ||
|
|
c284f20f00 | ||
|
|
75f7141ab4 | ||
|
|
58ae65cd1a | ||
|
|
23a6dd83b5 | ||
|
|
450b38c05b | ||
|
|
0286cccbc1 | ||
|
|
dc26d1193a | ||
|
|
64892df03e | ||
|
|
9e57ab615c | ||
|
|
5b0f1f7d13 | ||
|
|
b16fee0aa7 | ||
|
|
70bfcc895e | ||
|
|
785e827323 | ||
|
|
2f605e8d24 | ||
|
|
8de8bcbe2c | ||
|
|
5e2216bfa1 | ||
|
|
14e21742d5 | ||
|
|
175ac6811a | ||
|
|
44963e4af7 | ||
|
|
07d488daf6 | ||
|
|
d1360f6ecc | ||
|
|
125a86113f | ||
|
|
c38ff58b6b | ||
|
|
c29ef588dc | ||
|
|
968c31bd84 | ||
|
|
c743966156 | ||
|
|
bb09fd2bb6 | ||
|
|
280eb33b59 | ||
|
|
f79110c633 | ||
|
|
6ef2ff62fc | ||
|
|
980aea7860 | ||
|
|
d06db8ad9e | ||
|
|
ffa8e7b74c | ||
|
|
bd9327baa9 | ||
|
|
85e8decc16 | ||
|
|
6f9bafafa3 | ||
|
|
422a4a33a5 | ||
|
|
3216de1ee5 | ||
|
|
8f349c58f7 | ||
|
|
cfafb6a73d | ||
|
|
58606421ae | ||
|
|
d813ff2ac1 | ||
|
|
36734b2bab | ||
|
|
c85c5c408a | ||
|
|
2c1677d703 | ||
|
|
72348cbb8d | ||
|
|
c431798e82 | ||
|
|
fb80794568 | ||
|
|
4ec3d785e5 | ||
|
|
5d7c222db8 | ||
|
|
d993addbed | ||
|
|
818c0b2e42 | ||
|
|
aef8807e76 | ||
|
|
476b6ab541 | ||
|
|
16760a3089 | ||
|
|
2b247cf81f | ||
|
|
746fc2526f | ||
|
|
a8c65b400c | ||
|
|
526975906b | ||
|
|
4157fae6fe | ||
|
|
14fa6ad9f9 | ||
|
|
e544b0dc2a | ||
|
|
15902f8341 | ||
|
|
2549564009 | ||
|
|
bb1a915c24 | ||
|
|
8bcd746e84 | ||
|
|
56fe40191d | ||
|
|
b94f886b22 | ||
|
|
97c802588c | ||
|
|
6ef7b78e7c | ||
|
|
8c172bce1c | ||
|
|
e08aad1d14 | ||
|
|
4fa9664f5e | ||
|
|
483b312391 | ||
|
|
1033449613 | ||
|
|
f992081682 | ||
|
|
5ad93a12b2 | ||
|
|
b5a93e2250 | ||
|
|
efeb352163 | ||
|
|
44dd6865b9 | ||
|
|
bb82123707 | ||
|
|
c128bb0fa2 | ||
|
|
30fe028f07 | ||
|
|
b88606c28e | ||
|
|
2ea6abf6e5 | ||
|
|
f8c469de73 | ||
|
|
42096e05f7 | ||
|
|
7d15a556f8 | ||
|
|
5b17246324 | ||
|
|
eb7bb58471 | ||
|
|
c77094415f | ||
|
|
34413fca84 | ||
|
|
ec38ddc765 | ||
|
|
8aae01e223 | ||
|
|
00555c2f2f | ||
|
|
7f9c37457a | ||
|
|
86022a79a5 | ||
|
|
88a8ae6aee | ||
|
|
07d80f6f35 | ||
|
|
b58e24ac57 | ||
|
|
496c4e1033 | ||
|
|
0b948f3677 | ||
|
|
7f911c668d | ||
|
|
4591850561 | ||
|
|
e81ef01a0a | ||
|
|
d2033156c5 | ||
|
|
e4c1c03c5b | ||
|
|
a25aca2943 | ||
|
|
48c524827b | ||
|
|
5edd0f51e3 | ||
|
|
ebaec63e3e | ||
|
|
14e21f863a | ||
|
|
f10725a6e1 | ||
|
|
0f71b77d5c | ||
|
|
d6bb6a88be | ||
|
|
3205db2bfe | ||
|
|
6f86850eec | ||
|
|
16ab8a93bc | ||
|
|
c88f8f76b5 | ||
|
|
fbf96849e9 | ||
|
|
d70e2507f8 | ||
|
|
2fcf435d73 | ||
|
|
da2ee71de5 | ||
|
|
8611934352 | ||
|
|
1ecb88b95a | ||
|
|
01e94efd46 | ||
|
|
33c3ecf741 | ||
|
|
5bd4c26057 | ||
|
|
4aa5889e1a | ||
|
|
bafcc7e060 | ||
|
|
afe67fb28e | ||
|
|
03ecfadf3d | ||
|
|
f744f92adb | ||
|
|
64c6865427 | ||
|
|
75f134c077 | ||
|
|
d8d25c9603 | ||
|
|
f1bdf1d518 | ||
|
|
d58caee734 | ||
|
|
e39c2548f5 | ||
|
|
8169dd73f9 | ||
|
|
765e231a7c | ||
|
|
43894f9c0d | ||
|
|
40007ad24d | ||
|
|
c6e27dcf31 | ||
|
|
89c53672c2 | ||
|
|
64ba6cf222 | ||
|
|
210a4f78ae | ||
|
|
334ef04949 | ||
|
|
a47e836efe | ||
|
|
859ceeeb51 | ||
|
|
22edcae7fa | ||
|
|
d0590fe6b2 | ||
|
|
370358dfb4 | ||
|
|
2232b10f5a | ||
|
|
e34794dd1b | ||
|
|
a77b16abd4 | ||
|
|
061c8f977d | ||
|
|
0210065bbd | ||
|
|
7f5b4dd1e8 | ||
|
|
d70f5891da | ||
|
|
901959c945 | ||
|
|
5906e8d5fe | ||
|
|
5545607c4f | ||
|
|
6ac1571296 | ||
|
|
a857495d17 | ||
|
|
ca74b76f3e | ||
|
|
2b6174c478 | ||
|
|
2b002273f3 | ||
|
|
15d155e45a | ||
|
|
b0841348b6 | ||
|
|
090e81d4aa | ||
|
|
e4528e48e3 | ||
|
|
b1640e47e4 | ||
|
|
235dee1421 | ||
|
|
d28f7bc74d | ||
|
|
4083a229b4 | ||
|
|
a2400fcab8 | ||
|
|
5358bc44f4 | ||
|
|
dc56eb5079 | ||
|
|
a7f14cb4c6 | ||
|
|
531b538df5 | ||
|
|
637ff35ef6 | ||
|
|
ace3ebd661 | ||
|
|
eea674567c | ||
|
|
c39c32dd65 | ||
|
|
49ede900fa | ||
|
|
7c6cf1b176 | ||
|
|
0efea28dcb | ||
|
|
4bab9b763d | ||
|
|
fa5cea169a | ||
|
|
70696f4525 | ||
|
|
80bbc9ceaf | ||
|
|
51ce5230cd | ||
|
|
b6d8ba11e9 | ||
|
|
e2f2a9af2c | ||
|
|
28a8003467 | ||
|
|
83f22920c2 | ||
|
|
bec15f2109 | ||
|
|
43c0d77296 | ||
|
|
563cd0f2b0 | ||
|
|
46b7624b8e | ||
|
|
3ac0f28837 | ||
|
|
47c1735acd | ||
|
|
9e356100d0 | ||
|
|
7d3932e8cf | ||
|
|
8a60547896 | ||
|
|
7ca482062f | ||
|
|
ef4c5802ec | ||
|
|
fee38dcb9a | ||
|
|
c116de76ad | ||
|
|
6069bdbe27 | ||
|
|
871fe9107d | ||
|
|
d459e39012 | ||
|
|
2663f39ff9 | ||
|
|
9f0856208b | ||
|
|
fb4de3deed | ||
|
|
4d4716dc03 | ||
|
|
b5e4469150 | ||
|
|
340f5856ec | ||
|
|
df11e1e921 | ||
|
|
6a6592962c | ||
|
|
1275c4569e | ||
|
|
afbe74d386 | ||
|
|
f18ea6cae9 | ||
|
|
c9ff40cecd | ||
|
|
9088d5f24f | ||
|
|
cf9056cfda | ||
|
|
f7fc4ca1dd | ||
|
|
3e00d6c4bb | ||
|
|
132fc53223 | ||
|
|
b3b6720944 | ||
|
|
9f6ea7163b | ||
|
|
5e86220660 | ||
|
|
385c8e89f4 | ||
|
|
263e3151e2 | ||
|
|
9081980565 | ||
|
|
393b704d28 | ||
|
|
bef26f1158 | ||
|
|
bc1ca8605c | ||
|
|
ad5003409d | ||
|
|
057cfaf2f8 | ||
|
|
914d36ba19 | ||
|
|
31c2ac1cdc | ||
|
|
6bca8e3886 | ||
|
|
63ba7e293f | ||
|
|
31e9b9b2e9 | ||
|
|
7997b13aa3 | ||
|
|
a2eb9688a4 | ||
|
|
af2bf07404 | ||
|
|
8c5dfa4c99 | ||
|
|
8d9fb0f04a | ||
|
|
15fd2de37c | ||
|
|
1a83c37294 | ||
|
|
674ee8b72d | ||
|
|
1809e858bb | ||
|
|
2bbc970e10 | ||
|
|
da8348e938 | ||
|
|
4313847660 | ||
|
|
3844adbf58 | ||
|
|
d8e2073449 | ||
|
|
e9f7ebd674 | ||
|
|
ef16f45081 | ||
|
|
4d692e1ba0 | ||
|
|
6577e16920 | ||
|
|
3fc378aa0b | ||
|
|
f2bfbcef76 | ||
|
|
6713a4835f | ||
|
|
46ceb15c39 | ||
|
|
109d3123c3 | ||
|
|
63077bd40c | ||
|
|
df364f1b00 | ||
|
|
bc767216d9 | ||
|
|
cacd830f02 | ||
|
|
eda52e175a | ||
|
|
665560e9a4 | ||
|
|
c4fc8b5bf4 | ||
|
|
5affe206e1 | ||
|
|
9c52d2cc75 | ||
|
|
0f814687b9 | ||
|
|
f0eae953e2 | ||
|
|
298a2f9e58 | ||
|
|
ac0d0a5ecd | ||
|
|
f15390bdb4 | ||
|
|
d095b68d63 | ||
|
|
508999fa7d | ||
|
|
210a21bc8d | ||
|
|
678c1e025b | ||
|
|
1ab61a9179 | ||
|
|
1f4eccaaa5 | ||
|
|
07bf82a71d | ||
|
|
43d6233a22 | ||
|
|
736ce650c6 | ||
|
|
a8bb3d0e15 | ||
|
|
f27a152f69 | ||
|
|
63d494b22c | ||
|
|
d6dda126b7 | ||
|
|
7771b6c5b5 | ||
|
|
4843acc868 | ||
|
|
9ac9a29407 | ||
|
|
bdb4a7e092 | ||
|
|
0163602573 | ||
|
|
9e0aad9fd6 | ||
|
|
1c7a0e2856 | ||
|
|
bac2e26a9e | ||
|
|
10eae14f9b | ||
|
|
745c7356c2 | ||
|
|
e31c121315 | ||
|
|
dbf2ac31c9 | ||
|
|
abd23881c1 | ||
|
|
d1739eb2d6 | ||
|
|
4108d365bf | ||
|
|
2faa930bb0 | ||
|
|
03ef2c333c | ||
|
|
e14f4aab0a | ||
|
|
c842261b1b | ||
|
|
7922ba2feb | ||
|
|
df368ecce4 | ||
|
|
d94b22235f | ||
|
|
72d75ee206 | ||
|
|
49bc4c1023 | ||
|
|
0e92f7738a | ||
|
|
d529f2a8f7 | ||
|
|
141a64faff | ||
|
|
035dcd3724 | ||
|
|
3e9c37a386 | ||
|
|
00a59641ee | ||
|
|
90cce79346 | ||
|
|
4eeaf52ed9 | ||
|
|
3642f632d3 | ||
|
|
1e6bccc240 | ||
|
|
d3adc3d3ed | ||
|
|
10e7d6d526 | ||
|
|
aaa16d0001 | ||
|
|
8d472bdd84 | ||
|
|
430d7afd80 | ||
|
|
3b8ba6b610 | ||
|
|
ca982e4870 | ||
|
|
d5f686d808 | ||
|
|
535aef9def | ||
|
|
08e1cbc62c | ||
|
|
b6b4fdc9e2 | ||
|
|
dd55880644 | ||
|
|
bd1640bb01 | ||
|
|
081991ac01 | ||
|
|
8a85c341fe | ||
|
|
bcfea9fb25 | ||
|
|
f3f52d7f45 | ||
|
|
8845420f4e | ||
|
|
d735c64905 | ||
|
|
6e308baf5a | ||
|
|
5a9d2d9081 | ||
|
|
955d465c2c | ||
|
|
688791b22b | ||
|
|
8c521c7a34 | ||
|
|
77475142ec | ||
|
|
90fac84066 | ||
|
|
64674bcc8c | ||
|
|
1dc2d655ad | ||
|
|
863d2b196f | ||
|
|
c57bc2dc51 | ||
|
|
6c0dcdc211 | ||
|
|
28ded31b97 | ||
|
|
0fc07a0f9c | ||
|
|
823a67b0a9 | ||
|
|
60a938c6bc | ||
|
|
3a87a9b9db | ||
|
|
8e94e99ccb | ||
|
|
ae44fc1ec4 | ||
|
|
e20db94948 | ||
|
|
462a286eeb | ||
|
|
28722cf212 | ||
|
|
a110d01771 | ||
|
|
7ef7a1b3de | ||
|
|
2749276b95 | ||
|
|
b6a5fdb8a7 | ||
|
|
bf5773fa2d | ||
|
|
ecf139917d | ||
|
|
ab23d5ffda | ||
|
|
1a979201d5 | ||
|
|
216659eb87 | ||
|
|
5d6383c83f | ||
|
|
f36f469430 | ||
|
|
e07d3a021d | ||
|
|
e1a27eb34a | ||
|
|
6446e0c3c8 | ||
|
|
beedea2fef | ||
|
|
34be34fdd0 | ||
|
|
0020502a07 | ||
|
|
5cf7908a86 | ||
|
|
d530017c00 | ||
|
|
b7e3c73d7c | ||
|
|
fd9fa844e2 | ||
|
|
e6784a47e9 | ||
|
|
c2dc3ee8d9 | ||
|
|
482c2acf02 | ||
|
|
a481b4b52c | ||
|
|
a87228031f | ||
|
|
b79c82eaab | ||
|
|
69d1d5e6ce | ||
|
|
c86f2054f3 | ||
|
|
5c98b2caf5 | ||
|
|
5148710994 | ||
|
|
ea77fc3380 | ||
|
|
46ef873f0b | ||
|
|
2d2a5ba32a | ||
|
|
2bd4e3379f | ||
|
|
032c3ecb18 | ||
|
|
a0cac0ff75 | ||
|
|
817089b66d | ||
|
|
e703b46598 | ||
|
|
0fa793bc7b | ||
|
|
ba5477eb1a | ||
|
|
5c42f62e48 | ||
|
|
a08e05d1be | ||
|
|
d342ec3335 | ||
|
|
3d8b8860cf | ||
|
|
a0b5ebeac6 | ||
|
|
8ee18dd520 | ||
|
|
50f482374d | ||
|
|
f46e76ef50 | ||
|
|
ff60944b28 | ||
|
|
e725a9660b | ||
|
|
d7eed1929b | ||
|
|
4acc3e907d | ||
|
|
00294d0df7 | ||
|
|
9449e38504 | ||
|
|
fba03c479f | ||
|
|
b8b0b5d856 | ||
|
|
27bf518087 | ||
|
|
ec5d8a54e9 | ||
|
|
96a99d63c2 | ||
|
|
18a6333180 | ||
|
|
a9d9b07167 | ||
|
|
7f663ce430 | ||
|
|
e042540f6b | ||
|
|
494593845c | ||
|
|
82d63d3028 | ||
|
|
4e8172d6da | ||
|
|
8e6a84e730 | ||
|
|
875a644a90 | ||
|
|
95475b1c7a | ||
|
|
ec37635c94 | ||
|
|
fd836aeee0 | ||
|
|
560f7abb7e | ||
|
|
b6358c89a1 | ||
|
|
5d735465d1 | ||
|
|
9e051bac13 | ||
|
|
30fbcaa213 | ||
|
|
86f941c936 | ||
|
|
387fd00c47 | ||
|
|
93825dddad | ||
|
|
a8aa764d3c | ||
|
|
e7716b7a19 | ||
|
|
a4e3150f00 | ||
|
|
edec614efd | ||
|
|
00b9c1be7d | ||
|
|
051bb5c457 | ||
|
|
2457c19df1 | ||
|
|
5fa5eb71a4 | ||
|
|
931a031916 | ||
|
|
3f39976da3 | ||
|
|
be21fe59aa | ||
|
|
216ad9ef58 | ||
|
|
ef3565aed2 | ||
|
|
bc50157010 | ||
|
|
01fc051e8a | ||
|
|
ae43f344af | ||
|
|
91180d45f9 | ||
|
|
0902c559fb | ||
|
|
58b6a165a5 | ||
|
|
d9f40bbe55 | ||
|
|
ec7c9ee8b8 | ||
|
|
f82bb9cb9c | ||
|
|
641c55342b | ||
|
|
5a8922aed5 | ||
|
|
e390f5d684 | ||
|
|
078a97791d | ||
|
|
f2c1812560 | ||
|
|
4d6b383680 | ||
|
|
4cfa4ae820 | ||
|
|
489885cf84 | ||
|
|
850be8f18d | ||
|
|
a30af36c77 | ||
|
|
5075521e75 | ||
|
|
a22d40dde2 | ||
|
|
ee3a47a994 | ||
|
|
ee121033dc | ||
|
|
f727266ae8 | ||
|
|
4090b56b4d | ||
|
|
8bb0c8522a | ||
|
|
c6700d2746 | ||
|
|
1b06804491 | ||
|
|
33ad6eca7a | ||
|
|
dc90f64d56 | ||
|
|
6c43032121 | ||
|
|
dd10343e75 | ||
|
|
37ead9be0b | ||
|
|
1751034669 | ||
|
|
ad55502092 | ||
|
|
d4575825f1 | ||
|
|
31edde3edc | ||
|
|
d04b1b4656 | ||
|
|
1247092776 | ||
|
|
7e22a1df55 | ||
|
|
bb5810d21d | ||
|
|
381a693c39 | ||
|
|
86cb571e28 | ||
|
|
319a2c5f65 | ||
|
|
61a88c31c0 | ||
|
|
9d0e895120 | ||
|
|
b86ed8d18f | ||
|
|
44ee32ed30 | ||
|
|
5922128732 | ||
|
|
e5886a2388 | ||
|
|
8d1ebe0bd1 | ||
|
|
1fb724449d | ||
|
|
cb37947a71 | ||
|
|
721a5e83f9 | ||
|
|
6df617a59d | ||
|
|
8c6336b0aa | ||
|
|
4668056fc9 | ||
|
|
87203dc99a | ||
|
|
de23af982a | ||
|
|
3a5a176ea0 | ||
|
|
4de65cbc06 | ||
|
|
27b2b78f90 | ||
|
|
3a160f1dc6 | ||
|
|
7f24b1c3e9 | ||
|
|
a5e8bcfb7b | ||
|
|
a1d37a96df | ||
|
|
9d5c3c1939 | ||
|
|
815d7057be | ||
|
|
6bff79629e | ||
|
|
db452cdba0 | ||
|
|
d435752b0a | ||
|
|
c8b14ca177 | ||
|
|
30cb9ec715 | ||
|
|
af6dab9b00 | ||
|
|
8ba5c63de9 | ||
|
|
cdb42bcf0c | ||
|
|
3a0ede0ffd | ||
|
|
9cde81c2dd | ||
|
|
fc56b52924 | ||
|
|
62bd487421 | ||
|
|
4ef740a632 | ||
|
|
7f36acd8fe | ||
|
|
a32fc687de | ||
|
|
09d7c42a7c | ||
|
|
c0017a5a65 | ||
|
|
3fbbd1e1d7 | ||
|
|
344e86645d | ||
|
|
075521725d | ||
|
|
faa9c5cbdc | ||
|
|
5fdf06666c | ||
|
|
d2c786db37 | ||
|
|
f28e8bd300 | ||
|
|
3e786f4b0d | ||
|
|
de02ec2767 | ||
|
|
4b66e713de | ||
|
|
90dd4d34bb | ||
|
|
112341031b | ||
|
|
7cf803230b | ||
|
|
2d6452cdf9 | ||
|
|
cc056d6395 | ||
|
|
79b42e7654 | ||
|
|
f0c5db92f7 | ||
|
|
394178c94c | ||
|
|
d420ac2c7d | ||
|
|
61590d8945 | ||
|
|
b79aa47a0c | ||
|
|
ec2a595627 | ||
|
|
8f5c833f3c | ||
|
|
e88c577738 | ||
|
|
ffe966b0fa | ||
|
|
a2b0de98af | ||
|
|
bb3de147b3 | ||
|
|
4775944f81 | ||
|
|
95ec1a717b | ||
|
|
2abd5b7aa0 | ||
|
|
380e145daf | ||
|
|
a9f2330f43 | ||
|
|
ce38bb1a8c | ||
|
|
919f8bcd21 | ||
|
|
325829a9bc | ||
|
|
2bfd2c74d2 | ||
|
|
82b2f57e30 | ||
|
|
2ae1ea3788 | ||
|
|
34066d741a | ||
|
|
b74cc0776b | ||
|
|
e7e5fe4705 | ||
|
|
998ae048e7 | ||
|
|
e65c2b9872 | ||
|
|
b0ea8b160c | ||
|
|
2fe9ab8e20 | ||
|
|
bb569f97b9 | ||
|
|
1145e03870 | ||
|
|
31670c94bc | ||
|
|
6781efb92f | ||
|
|
0bf1c1d80d | ||
|
|
67e5d33dd7 | ||
|
|
6ed474ca66 | ||
|
|
46cb8d3689 | ||
|
|
23fc5ac646 | ||
|
|
5734bebe05 | ||
|
|
657a919598 | ||
|
|
da17495b65 | ||
|
|
6859bb1a22 | ||
|
|
b64614adfe | ||
|
|
3822740ce3 | ||
|
|
0d78bc3356 | ||
|
|
d87b79bf31 | ||
|
|
6a6a08cbea | ||
|
|
70ef9c5a3d | ||
|
|
753cbc2857 | ||
|
|
b727907ae8 | ||
|
|
444c3a8492 | ||
|
|
0b352c58db | ||
|
|
9d68b289a0 | ||
|
|
03ddbdd9b9 | ||
|
|
eb5f555ffb | ||
|
|
5ebdb39084 | ||
|
|
d45a098472 | ||
|
|
6d5ffb591b | ||
|
|
7ce9e425bc | ||
|
|
4d8743f490 | ||
|
|
4c8b4f9d03 | ||
|
|
04dc4edb44 | ||
|
|
81ba5f6713 | ||
|
|
6defae04f3 | ||
|
|
e1064adfd3 | ||
|
|
d7559f16cd | ||
|
|
d161f5a9b2 | ||
|
|
9e989810ba | ||
|
|
28474e26f4 | ||
|
|
ec2179cf81 | ||
|
|
a8287a90ea | ||
|
|
85421c7148 | ||
|
|
ad5f0ed509 | ||
|
|
0a4c8baf5e | ||
|
|
77cc150b61 | ||
|
|
95de3d204f | ||
|
|
890b2abf19 | ||
|
|
31182ad39b | ||
|
|
6b051c4ebc | ||
|
|
f35232e6f3 | ||
|
|
fda5e38551 | ||
|
|
a601df36f3 | ||
|
|
ac9c6e10a4 | ||
|
|
1a01733047 | ||
|
|
d2cd46127c | ||
|
|
9dde17e8b4 | ||
|
|
37af03d311 | ||
|
|
f7a397cc8d | ||
|
|
cd2e8a6f2d | ||
|
|
2d4b834926 | ||
|
|
c22e6753ef | ||
|
|
d18b993c43 | ||
|
|
e6e81c5894 | ||
|
|
f75abcefed | ||
|
|
18f62d4b82 | ||
|
|
5c0c22803e | ||
|
|
0ef85c7f45 | ||
|
|
078dd1a0f9 | ||
|
|
2b96c95197 | ||
|
|
c5f1c7b4d8 | ||
|
|
d870740cd7 | ||
|
|
d8ec0dcf45 | ||
|
|
c465e7941e | ||
|
|
933398f110 | ||
|
|
cfd06a6223 | ||
|
|
a9fd78f9da | ||
|
|
5f747c7f4b | ||
|
|
c4db1a8b5c | ||
|
|
f7939fcd9a | ||
|
|
d531c9014d | ||
|
|
aca95e0b2f | ||
|
|
bc3c578208 | ||
|
|
06e4024d98 | ||
|
|
8087d8f7ea | ||
|
|
31166ec8f3 | ||
|
|
2754597013 | ||
|
|
2ce90b9b74 | ||
|
|
db5b10fab5 | ||
|
|
4e952ae4fc | ||
|
|
db59141467 | ||
|
|
8a66d17899 | ||
|
|
2eeaa0261e | ||
|
|
8dc344ccbf | ||
|
|
6bcd3f903a | ||
|
|
40f935f5b4 | ||
|
|
0991f07034 | ||
|
|
2aaec9cced | ||
|
|
9d473aa2e4 | ||
|
|
6145b0b183 | ||
|
|
2a85f77146 | ||
|
|
66b82f5aad | ||
|
|
12bdceac8a | ||
|
|
aea293e3bc | ||
|
|
8ad7e3ad2a | ||
|
|
fa5846e58b | ||
|
|
0b6956b474 | ||
|
|
0bb6187e71 | ||
|
|
c5a5546389 | ||
|
|
79e4022a33 | ||
|
|
77fe058c10 | ||
|
|
8d9086dfa2 | ||
|
|
0602abf5bd | ||
|
|
caf044cb3e | ||
|
|
80986c9ced | ||
|
|
a08ced78c8 | ||
|
|
ede7c28eb7 | ||
|
|
83eb412da8 | ||
|
|
4d1c443123 | ||
|
|
f44e184ec6 | ||
|
|
377dcdba44 | ||
|
|
8242354952 | ||
|
|
c40b9bdefb | ||
|
|
6895cca89d | ||
|
|
c9d3957986 | ||
|
|
f82ab534c6 | ||
|
|
05e962ddf8 | ||
|
|
f6e8c19ed1 | ||
|
|
cf89b40584 | ||
|
|
d680c13060 | ||
|
|
c076599c18 | ||
|
|
a510e9e4fc | ||
|
|
4d8148fa98 | ||
|
|
1a9e663b20 | ||
|
|
aed29ce5ea | ||
|
|
0dd675509c | ||
|
|
9ad82c123a | ||
|
|
144aa3c56e | ||
|
|
eeff6bb6b3 | ||
|
|
202892dfd6 | ||
|
|
d90e74c50c | ||
|
|
2990244980 | ||
|
|
0c6fa13fee | ||
|
|
68f0bcfbc3 | ||
|
|
662ede2370 | ||
|
|
d0edf6e593 | ||
|
|
c93f908f7f | ||
|
|
16d2a7caef | ||
|
|
c798868d96 | ||
|
|
057a04398d | ||
|
|
b7b5cd6132 | ||
|
|
71583fb0d7 | ||
|
|
7f3ba9428f | ||
|
|
058f86e9e0 | ||
|
|
3c02e24bb3 | ||
|
|
4509102cb9 | ||
|
|
1be02dd842 | ||
|
|
87c99c59bd | ||
|
|
3d7c4a5a6d | ||
|
|
732d1bf43a | ||
|
|
11171f3c74 | ||
|
|
88fd7424f6 | ||
|
|
ba9f80c5d5 | ||
|
|
30a452ab32 | ||
|
|
e59659dc41 | ||
|
|
9c90f27dac | ||
|
|
ec4e600da6 | ||
|
|
253e893c2b | ||
|
|
4097dce455 | ||
|
|
0ad2c4f85b | ||
|
|
0e6c20da46 | ||
|
|
f6b659cba4 | ||
|
|
c9b552534e | ||
|
|
f0ad5fc2ab | ||
|
|
6bd27f8644 | ||
|
|
dfe399e7d9 | ||
|
|
7068c8b1a6 | ||
|
|
5f444c8fcd | ||
|
|
82384690e2 | ||
|
|
e6fa67fa93 | ||
|
|
62afa8bd58 | ||
|
|
9ea72d3705 | ||
|
|
a907751350 | ||
|
|
2689b8f326 | ||
|
|
560dfd2a02 | ||
|
|
bd69ac5c93 | ||
|
|
14f3d7c5cc | ||
|
|
33ed371ec9 | ||
|
|
510dc1ecd0 | ||
|
|
3b07c32fe7 | ||
|
|
563c05e2dc | ||
|
|
9cc513a000 | ||
|
|
cac32e5acd | ||
|
|
643ecd2ed6 | ||
|
|
0e9edc98d4 | ||
|
|
27bd937cc0 | ||
|
|
f56c451143 | ||
|
|
05a1f76093 | ||
|
|
4ed9388e5d | ||
|
|
94a1183fab | ||
|
|
88401ed449 | ||
|
|
30e4269241 | ||
|
|
59315df637 | ||
|
|
3aa8d3a7f1 | ||
|
|
3659df7d15 | ||
|
|
16f1fdbc8b | ||
|
|
98c1a4900c | ||
|
|
5b6e7c8c65 | ||
|
|
2541f58309 | ||
|
|
6b063f32d9 | ||
|
|
693f2e3625 | ||
|
|
afab06d3f5 | ||
|
|
8fb97c9acd | ||
|
|
7312a38d9e | ||
|
|
475e8d3d1d | ||
|
|
c5f070d5d5 | ||
|
|
1b9e855744 | ||
|
|
f3b2ea53e2 | ||
|
|
ed71769948 | ||
|
|
e1c0a9c416 | ||
|
|
0b8c5413a4 | ||
|
|
c473d53898 | ||
|
|
e8f8249319 | ||
|
|
e2ced802b4 | ||
|
|
9163658aa8 | ||
|
|
d3a15e132d | ||
|
|
47954f114c | ||
|
|
3ef747c8b6 | ||
|
|
75622f1ece | ||
|
|
a052dd6532 | ||
|
|
f96d1af449 | ||
|
|
968766cad8 | ||
|
|
652ae06bad | ||
|
|
5cc2658cff | ||
|
|
ddc38679ce | ||
|
|
2f4335ec2b | ||
|
|
02e0559477 | ||
|
|
ada0e717fa | ||
|
|
2c789c82be | ||
|
|
d143dce03c | ||
|
|
f9d183c209 | ||
|
|
2ab0740785 | ||
|
|
182cd19dea | ||
|
|
61f00386ab | ||
|
|
82f676c633 | ||
|
|
5f24adda77 | ||
|
|
2ae0352b0f | ||
|
|
94805c84d1 | ||
|
|
900f062d1f | ||
|
|
6f2f534b58 | ||
|
|
ba64c2cc8f | ||
|
|
da6c44fc97 | ||
|
|
29e62e487f | ||
|
|
da0d33560f | ||
|
|
ec28f9c12c | ||
|
|
9d19fbc4fc | ||
|
|
4e6480faf8 | ||
|
|
aa5ae4841e | ||
|
|
eb3d68c454 | ||
|
|
c89f31def0 | ||
|
|
ed5fae580e | ||
|
|
d55141ed7a | ||
|
|
a99ce1a574 | ||
|
|
c687a3d5d5 | ||
|
|
dfc3151925 | ||
|
|
0fbffe7a71 | ||
|
|
00dc2d7551 | ||
|
|
037f6e73f1 | ||
|
|
cf82439de8 | ||
|
|
37fcd48f86 | ||
|
|
27346c53b1 | ||
|
|
e2491c45ab | ||
|
|
cf9a88cad7 | ||
|
|
398cd7276f | ||
|
|
4f1cd8324c | ||
|
|
873ddf7c0c | ||
|
|
ed7f1d0bc6 | ||
|
|
4aae637f6c | ||
|
|
f6b9cd7f82 | ||
|
|
8fbb2af392 | ||
|
|
c5aba56c5b | ||
|
|
705d0f5c8d | ||
|
|
fd4ef69913 | ||
|
|
844df66895 | ||
|
|
834ac33a37 | ||
|
|
4e9023f4d2 | ||
|
|
d3a28e8b8d | ||
|
|
0bd71d3b7e | ||
|
|
d97322f0e6 | ||
|
|
b52d512dfa | ||
|
|
a3a2ff4cd9 | ||
|
|
0d5b4f594d | ||
|
|
5a1fd87ec1 | ||
|
|
8c2786fff7 | ||
|
|
8645c415cf | ||
|
|
66ce343361 | ||
|
|
700d86ea18 | ||
|
|
1b9f21fdc8 | ||
|
|
54bbde3c3f | ||
|
|
f3031b106d | ||
|
|
c14b337570 | ||
|
|
e666c4599f | ||
|
|
98cec7fc7b | ||
|
|
fadd2246a0 | ||
|
|
c78b4f1d3d | ||
|
|
6e260c4093 | ||
|
|
33862b90bb | ||
|
|
36bad5cdfd | ||
|
|
54f6451670 | ||
|
|
f19d064087 | ||
|
|
490967195a | ||
|
|
25a1259911 | ||
|
|
606c8048a0 | ||
|
|
e66d863cd0 | ||
|
|
f63f51dc22 | ||
|
|
a069460015 | ||
|
|
4eebab0d22 | ||
|
|
55b12f8641 | ||
|
|
40e5b9abeb | ||
|
|
bc63a2ee0e | ||
|
|
dcfb57c736 | ||
|
|
2ee67f1dad | ||
|
|
4af3184662 | ||
|
|
e31047744a | ||
|
|
f6eba601b0 | ||
|
|
f796dc5c06 | ||
|
|
476f09712c | ||
|
|
50078051bd | ||
|
|
db01746978 | ||
|
|
fe0444b17e | ||
|
|
63b815583b | ||
|
|
16c9148220 | ||
|
|
ca82ac1fee | ||
|
|
9d92486cfb | ||
|
|
aff0542844 | ||
|
|
bb41fdb5ec | ||
|
|
beab098d53 | ||
|
|
3410aa1aa8 | ||
|
|
f50b911a3f | ||
|
|
02b95b7499 | ||
|
|
2a948bd306 | ||
|
|
c4d471552f | ||
|
|
d4e35514ba | ||
|
|
01fc834bc9 | ||
|
|
f7f8d82aaa | ||
|
|
3fd6b9f6d4 | ||
|
|
4f17dfcd75 | ||
|
|
a598524ad6 | ||
|
|
83b4f49c0a | ||
|
|
828ce10ce7 | ||
|
|
8939adbad9 | ||
|
|
60790aff6f | ||
|
|
ff160dba54 | ||
|
|
e19d0ef068 | ||
|
|
f5f7dffdd1 | ||
|
|
fb5b7317a7 | ||
|
|
edd55d08f5 | ||
|
|
457f692eab | ||
|
|
83743ad039 | ||
|
|
163f5b236c | ||
|
|
e077b5452f | ||
|
|
513c01a591 | ||
|
|
d9a2a89a17 | ||
|
|
31939f1544 | ||
|
|
11ce33a71d | ||
|
|
9acef3bbd7 | ||
|
|
164bc7dae8 | ||
|
|
f59c941950 | ||
|
|
0239876511 | ||
|
|
93c929e411 | ||
|
|
c2dac35a02 | ||
|
|
a9cfd20da7 | ||
|
|
727ef76ebd | ||
|
|
22e6c2524e | ||
|
|
bca52f7d4e | ||
|
|
48c36fdb2a | ||
|
|
6d8cbdcb53 | ||
|
|
9b2042fac3 | ||
|
|
54a7ea6f36 | ||
|
|
816d785721 | ||
|
|
742b139f54 | ||
|
|
0e2f5ec2d2 | ||
|
|
3b30121bd9 | ||
|
|
9ee789e6c3 | ||
|
|
8c5e375c8e | ||
|
|
b9d2d20086 | ||
|
|
b9d7ca9748 | ||
|
|
5b194dfbd5 | ||
|
|
7f6af7d9db | ||
|
|
42b2b6a2d5 | ||
|
|
d1465bac90 | ||
|
|
3bbb0212f3 | ||
|
|
a5db6fa576 | ||
|
|
9236b5b013 | ||
|
|
535fba4907 | ||
|
|
7e4140f73f | ||
|
|
1ae0a83bdd | ||
|
|
7ae46c6761 | ||
|
|
d584fd6b66 | ||
|
|
54dbdd9837 | ||
|
|
9d6c32d6d1 | ||
|
|
26851b6b42 | ||
|
|
ea5240a5ed | ||
|
|
ce8a202831 | ||
|
|
eec7968f18 | ||
|
|
0ece1d304d | ||
|
|
1cc087fe4f | ||
|
|
7f0f9f1934 | ||
|
|
040c687ce4 | ||
|
|
8f09a154e3 | ||
|
|
cd1226bc6a | ||
|
|
7a04fdd87f | ||
|
|
4e7566579e | ||
|
|
fba1cfa06d | ||
|
|
138f970e6e | ||
|
|
110c6f72ec | ||
|
|
27f7d430ce | ||
|
|
5964e95c0a | ||
|
|
1a0c1f9052 | ||
|
|
f78ae9c0f2 | ||
|
|
e072e16e92 | ||
|
|
1774e22d6f | ||
|
|
7a79b5601a | ||
|
|
26abc8f01a | ||
|
|
74b0c41e47 | ||
|
|
5924c21608 | ||
|
|
bbfbd4b270 | ||
|
|
c93fbfaebc | ||
|
|
88ec5a637f | ||
|
|
0b1c00abeb | ||
|
|
75fcbb43a7 | ||
|
|
e4e049e489 | ||
|
|
225e35bd36 | ||
|
|
9f81f23742 | ||
|
|
0ae4ad9e9f | ||
|
|
721688c2f8 | ||
|
|
a109220107 | ||
|
|
4a4a04622e | ||
|
|
d6fd88fffd | ||
|
|
e96133e4cf | ||
|
|
f65a75786b | ||
|
|
a157379adc | ||
|
|
1ed3815650 | ||
|
|
0b55368306 | ||
|
|
27310553b1 | ||
|
|
43eb3b0130 | ||
|
|
78490b9cc2 | ||
|
|
0a861ab7f3 | ||
|
|
7b36590b17 | ||
|
|
a8b728445c | ||
|
|
af0f0f3e8f | ||
|
|
86ccb91ddb | ||
|
|
8d570498a2 | ||
|
|
4c771796d5 | ||
|
|
8e4552ed30 | ||
|
|
d6df2b281f | ||
|
|
bc4a5ed341 | ||
|
|
6fcf735497 | ||
|
|
b5f96e8818 | ||
|
|
3ae70939ba | ||
|
|
d5157a6244 | ||
|
|
c433d72593 | ||
|
|
68b42986cb | ||
|
|
57544ee224 | ||
|
|
83b23ed967 | ||
|
|
4342c5c1a0 | ||
|
|
16b1b03543 | ||
|
|
e6526fbf4d | ||
|
|
d07e7c32c2 | ||
|
|
8152d88799 | ||
|
|
8f35294c1b | ||
|
|
4ce4884a5b | ||
|
|
db598fbce2 | ||
|
|
8382ec5d37 | ||
|
|
0998cfaadd | ||
|
|
2bdcfbd7a3 | ||
|
|
c4448f60d6 | ||
|
|
63b6fe2bf6 | ||
|
|
f85b68cd49 | ||
|
|
46b695d850 | ||
|
|
5679bcce07 | ||
|
|
6076f21f5e | ||
|
|
24692fc5d7 | ||
|
|
4390d66179 | ||
|
|
be34231656 | ||
|
|
d678cc07ed | ||
|
|
54e73364f1 | ||
|
|
6dd6da6005 | ||
|
|
c6b220d933 | ||
|
|
03eeb07152 | ||
|
|
1a15c89988 | ||
|
|
d1c5c168b5 | ||
|
|
d0a4bd00b6 | ||
|
|
423b1a840c | ||
|
|
931756b833 | ||
|
|
a47789e849 | ||
|
|
39e76bc454 | ||
|
|
e5b0508a14 | ||
|
|
961b565690 | ||
|
|
c4d00669a0 | ||
|
|
142cdf5ec9 | ||
|
|
d6cab100fa | ||
|
|
81bd0446a9 | ||
|
|
520b76ffd9 | ||
|
|
1e2b14e9ca | ||
|
|
4fe70c7812 | ||
|
|
1c2d141238 | ||
|
|
32e75dd3f0 | ||
|
|
21eb91c79e | ||
|
|
abfc6a3a9b | ||
|
|
5cc5ec1bba | ||
|
|
f80153e20b | ||
|
|
33b34a9d8f | ||
|
|
9b94f215b1 | ||
|
|
8b5bcef798 | ||
|
|
ea17e1f00f | ||
|
|
543105ac17 | ||
|
|
3789284807 | ||
|
|
be9bec9bc7 | ||
|
|
9c35452842 | ||
|
|
69104cdf34 | ||
|
|
dfefdb41f7 | ||
|
|
cd6ab56da0 | ||
|
|
c988c9b839 | ||
|
|
bff8e1dddb | ||
|
|
641e6ef2cb | ||
|
|
9e9e8cb6a8 | ||
|
|
f118514501 | ||
|
|
39c4b7092c | ||
|
|
c7e7fc3ee4 | ||
|
|
786b0075d5 | ||
|
|
fb10590910 | ||
|
|
abf21308d2 | ||
|
|
8c84b677e2 | ||
|
|
d5ef144222 | ||
|
|
741dae576f | ||
|
|
59ade20500 | ||
|
|
c11b9af75e | ||
|
|
08a54f6e6a | ||
|
|
8305477157 | ||
|
|
e8cc7de4f4 | ||
|
|
3b6aa36c77 | ||
|
|
03829b2b47 | ||
|
|
87c9c659de | ||
|
|
751ff1d376 | ||
|
|
d3ae5b1c8a | ||
|
|
0f3879455b | ||
|
|
0c7d61ee0e | ||
|
|
78951e7711 | ||
|
|
9ba4cc007b | ||
|
|
7b5a6c7a62 | ||
|
|
44deca977d | ||
|
|
536b73e78e | ||
|
|
940767b03f | ||
|
|
d4a47a5778 | ||
|
|
b24668626e | ||
|
|
ea3675b5b6 | ||
|
|
c554155b58 | ||
|
|
a1d12daed2 | ||
|
|
6f528cac5a | ||
|
|
10a66ad389 | ||
|
|
9d80973ea1 | ||
|
|
e986704d24 | ||
|
|
ce06265a37 | ||
|
|
e4fb312330 | ||
|
|
439909a068 | ||
|
|
1296e72d1d | ||
|
|
d177e6180d | ||
|
|
f077cf68af | ||
|
|
48f1fa7482 | ||
|
|
a69cc10af1 | ||
|
|
aa9d896b0d | ||
|
|
2dd060d94e | ||
|
|
42a559163d | ||
|
|
546490c00e | ||
|
|
3285eb336c | ||
|
|
409a5de586 | ||
|
|
02da5bcd83 | ||
|
|
84b1e84af1 | ||
|
|
5250725ba5 | ||
|
|
9ed1fa4813 | ||
|
|
500df82a96 | ||
|
|
84d5ad6181 | ||
|
|
96c15b8aad | ||
|
|
4fc2bf07b5 | ||
|
|
e8e0e3716a | ||
|
|
bc441b739b | ||
|
|
2007fe63f8 | ||
|
|
ee435c0d9c | ||
|
|
e6539fe22d | ||
|
|
ba5df66a8b | ||
|
|
12d4e7b8c8 | ||
|
|
3f691235da | ||
|
|
bba2cb3ada | ||
|
|
86a925b27e | ||
|
|
52c4c51f02 | ||
|
|
954d8e4f79 | ||
|
|
767712fa62 | ||
|
|
b575dff21a | ||
|
|
90e8a3102b | ||
|
|
b35ca7b257 | ||
|
|
879650b866 | ||
|
|
176f31ddec | ||
|
|
fe14ee96db | ||
|
|
0102bb94cb | ||
|
|
57376542a0 | ||
|
|
57bc7769b7 | ||
|
|
b8dc9693a7 | ||
|
|
0461b8c90b | ||
|
|
6ac26a5ce5 | ||
|
|
155bd1137e | ||
|
|
f0dc08e656 | ||
|
|
e9ec63961b | ||
|
|
0185803cc2 | ||
|
|
bd8e228d60 | ||
|
|
5c9a9c9c33 | ||
|
|
bad99f6a9d | ||
|
|
63ff3e83fc | ||
|
|
5600a9cba1 | ||
|
|
607ae30be8 | ||
|
|
b4f43344d5 | ||
|
|
c8c5cec1f9 | ||
|
|
37d9503a67 | ||
|
|
66ecdf3bfb | ||
|
|
a1033894d7 | ||
|
|
7841edc9c1 | ||
|
|
132eaa59da | ||
|
|
5562cfaca4 | ||
|
|
0480574310 | ||
|
|
c8252b71b5 | ||
|
|
94949a50aa | ||
|
|
0214893e6a | ||
|
|
5be4a42e99 | ||
|
|
f2aa055ec6 | ||
|
|
62e3163b1b | ||
|
|
8214e74f76 | ||
|
|
542a1b1a2e | ||
|
|
5672e3a321 | ||
|
|
fbbfd86b67 | ||
|
|
d8cbc93585 | ||
|
|
dab0aaa612 | ||
|
|
5b0b0e98ce | ||
|
|
d5234c7b3a | ||
|
|
77e270d10e | ||
|
|
c893bffae7 | ||
|
|
988e8458ad | ||
|
|
758f942b88 | ||
|
|
26e9724458 | ||
|
|
4879ec7bf3 | ||
|
|
b653327d47 | ||
|
|
4cadedef57 | ||
|
|
27068df7e0 | ||
|
|
b12753dffc | ||
|
|
79221bc265 | ||
|
|
ffa49dc3d9 | ||
|
|
b7bbac72c4 | ||
|
|
c1269c81fd | ||
|
|
794a386af3 | ||
|
|
e270cf9c5e | ||
|
|
7e38616d1f | ||
|
|
85d686e723 | ||
|
|
2d3de726c5 | ||
|
|
4989f0599f | ||
|
|
e4b52ac353 | ||
|
|
abd22c9c46 | ||
|
|
ba729265a8 | ||
|
|
9ec1d35f29 | ||
|
|
cf56663fb7 | ||
|
|
ea513641d0 | ||
|
|
8537943e8b | ||
|
|
a8f5b2ed50 | ||
|
|
33075f229e | ||
|
|
28f573a28d | ||
|
|
e2c9c91b5b | ||
|
|
d42d2d1ab6 | ||
|
|
65b254e8c0 | ||
|
|
82871eaa17 | ||
|
|
24893ca999 | ||
|
|
27a9bf17c7 | ||
|
|
37c660ff9b | ||
|
|
772ec4135c | ||
|
|
0e9035ac98 | ||
|
|
4e5d3a7f98 | ||
|
|
379e568950 | ||
|
|
c09a297892 | ||
|
|
2619676256 | ||
|
|
33cc07f79a | ||
|
|
c029841e36 | ||
|
|
bfa3555081 | ||
|
|
5d780babe3 | ||
|
|
5cd48abf9f | ||
|
|
db5006df04 | ||
|
|
3d6a84c42a | ||
|
|
5fe11c7533 | ||
|
|
a1d57849b3 | ||
|
|
0b13e9f055 | ||
|
|
96f7065f63 | ||
|
|
f3c22ef10d | ||
|
|
a85bef1899 | ||
|
|
bb3e67f315 | ||
|
|
c0a93e31ab | ||
|
|
2e60ea7634 | ||
|
|
4e78074b39 | ||
|
|
b637670f03 | ||
|
|
bd1217a176 | ||
|
|
da45180de4 | ||
|
|
82516e3baf | ||
|
|
c1862f9136 | ||
|
|
9048c7245b | ||
|
|
02bf9a151a | ||
|
|
d3b5cb5343 | ||
|
|
97e6bf6b22 | ||
|
|
04da4558dd | ||
|
|
0c3426da86 | ||
|
|
9b3f03d5a2 | ||
|
|
9abff96b2f | ||
|
|
722d17cbac | ||
|
|
59b846c515 | ||
|
|
42bf2a5cdc | ||
|
|
80bcbaa02f | ||
|
|
7c4e24af38 | ||
|
|
726c223143 | ||
|
|
59ae8c9419 | ||
|
|
0bdd2da5d2 | ||
|
|
2f09524501 | ||
|
|
06492aef01 | ||
|
|
c00cee00fd | ||
|
|
8228f302dd | ||
|
|
018c56fdca | ||
|
|
d745af4b0c | ||
|
|
44ea41cfff | ||
|
|
acad5755a2 | ||
|
|
28b958f732 | ||
|
|
4e59cd3bb6 | ||
|
|
a74333f905 | ||
|
|
365e14622a | ||
|
|
8ec16ce711 | ||
|
|
0e4aa0d2d2 | ||
|
|
08cb96bba2 |
@@ -1,5 +1,5 @@
|
|||||||
openssl.pc
|
openssl.pc
|
||||||
Makefile.ssl
|
Makefile
|
||||||
MINFO
|
MINFO
|
||||||
makefile.one
|
makefile.one
|
||||||
tmp
|
tmp
|
||||||
@@ -14,3 +14,7 @@ cctest.c
|
|||||||
cctest.a
|
cctest.a
|
||||||
libcrypto.so.*
|
libcrypto.so.*
|
||||||
libssl.so.*
|
libssl.so.*
|
||||||
|
libcrypto.sha1
|
||||||
|
libcrypto.a.sha1
|
||||||
|
*.flc
|
||||||
|
semantic.cache
|
||||||
|
|||||||
354
CHANGES
354
CHANGES
@@ -2,6 +2,292 @@
|
|||||||
OpenSSL CHANGES
|
OpenSSL CHANGES
|
||||||
_______________
|
_______________
|
||||||
|
|
||||||
|
Changes between 0.9.7g and 0.9.7h [XX xxx XXXX]
|
||||||
|
|
||||||
|
*) Minimal support for X9.31 signatures and PSS padding modes. This is
|
||||||
|
mainly for FIPS compliance and not fully integrated at this stage.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) For DSA signing, unless DSA_FLAG_NO_EXP_CONSTTIME is set, perform
|
||||||
|
the exponentiation using a fixed-length exponent. (Otherwise,
|
||||||
|
the information leaked through timing could expose the secret key
|
||||||
|
after many signatures; cf. Bleichenbacher's attack on DSA with
|
||||||
|
biased k.)
|
||||||
|
[Bodo Moeller]
|
||||||
|
|
||||||
|
*) Make a new fixed-window mod_exp implementation the default for
|
||||||
|
RSA, DSA, and DH private-key operations so that the sequence of
|
||||||
|
squares and multiplies and the memory access pattern are
|
||||||
|
independent of the particular secret key. This will mitigate
|
||||||
|
cache-timing and potential related attacks.
|
||||||
|
|
||||||
|
BN_mod_exp_mont_consttime() is the new exponentiation implementation,
|
||||||
|
and this is automatically used by BN_mod_exp_mont() if the new flag
|
||||||
|
BN_FLG_EXP_CONSTTIME is set for the exponent. RSA, DSA, and DH
|
||||||
|
will use this BN flag for private exponents unless the flag
|
||||||
|
RSA_FLAG_NO_EXP_CONSTTIME, DSA_FLAG_NO_EXP_CONSTTIME, or
|
||||||
|
DH_FLAG_NO_EXP_CONSTTIME, respectively, is set.
|
||||||
|
|
||||||
|
[Matthew D Wood (Intel Corp), with some changes by Bodo Moeller]
|
||||||
|
|
||||||
|
*) Change the client implementation for SSLv23_method() and
|
||||||
|
SSLv23_client_method() so that is uses the SSL 3.0/TLS 1.0
|
||||||
|
Client Hello message format if the SSL_OP_NO_SSLv2 option is set.
|
||||||
|
(Previously, the SSL 2.0 backwards compatible Client Hello
|
||||||
|
message format would be used even with SSL_OP_NO_SSLv2.)
|
||||||
|
[Bodo Moeller]
|
||||||
|
|
||||||
|
*) Add support for smime-type MIME parameter in S/MIME messages which some
|
||||||
|
clients need.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) New function BN_MONT_CTX_set_locked() to set montgomery parameters in
|
||||||
|
a threadsafe manner. Modify rsa code to use new function and add calls
|
||||||
|
to dsa and dh code (which had race conditions before).
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Include the fixed error library code in the C error file definitions
|
||||||
|
instead of fixing them up at runtime. This keeps the error code
|
||||||
|
structures constant.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
Changes between 0.9.7f and 0.9.7g [11 Apr 2005]
|
||||||
|
|
||||||
|
*) Fixes for newer kerberos headers. NB: the casts are needed because
|
||||||
|
the 'length' field is signed on one version and unsigned on another
|
||||||
|
with no (?) obvious way to tell the difference, without these VC++
|
||||||
|
complains. Also the "definition" of FAR (blank) is no longer included
|
||||||
|
nor is the error ENOMEM. KRB5_PRIVATE has to be set to 1 to pick up
|
||||||
|
some needed definitions.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Undo Cygwin change.
|
||||||
|
[Ulf M<>ller]
|
||||||
|
|
||||||
|
*) Added support for proxy certificates according to RFC 3820.
|
||||||
|
Because they may be a security thread to unaware applications,
|
||||||
|
they must be explicitely allowed in run-time. See
|
||||||
|
docs/HOWTO/proxy_certificates.txt for further information.
|
||||||
|
[Richard Levitte]
|
||||||
|
|
||||||
|
Changes between 0.9.7e and 0.9.7f [22 Mar 2005]
|
||||||
|
|
||||||
|
*) Use (SSL_RANDOM_VALUE - 4) bytes of pseudo random data when generating
|
||||||
|
server and client random values. Previously
|
||||||
|
(SSL_RANDOM_VALUE - sizeof(time_t)) would be used which would result in
|
||||||
|
less random data when sizeof(time_t) > 4 (some 64 bit platforms).
|
||||||
|
|
||||||
|
This change has negligible security impact because:
|
||||||
|
|
||||||
|
1. Server and client random values still have 24 bytes of pseudo random
|
||||||
|
data.
|
||||||
|
|
||||||
|
2. Server and client random values are sent in the clear in the initial
|
||||||
|
handshake.
|
||||||
|
|
||||||
|
3. The master secret is derived using the premaster secret (48 bytes in
|
||||||
|
size for static RSA ciphersuites) as well as client server and random
|
||||||
|
values.
|
||||||
|
|
||||||
|
The OpenSSL team would like to thank the UK NISCC for bringing this issue
|
||||||
|
to our attention.
|
||||||
|
|
||||||
|
[Stephen Henson, reported by UK NISCC]
|
||||||
|
|
||||||
|
*) Use Windows randomness collection on Cygwin.
|
||||||
|
[Ulf M<>ller]
|
||||||
|
|
||||||
|
*) Fix hang in EGD/PRNGD query when communication socket is closed
|
||||||
|
prematurely by EGD/PRNGD.
|
||||||
|
[Darren Tucker <dtucker@zip.com.au> via Lutz J<>nicke, resolves #1014]
|
||||||
|
|
||||||
|
*) Prompt for pass phrases when appropriate for PKCS12 input format.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Back-port of selected performance improvements from development
|
||||||
|
branch, as well as improved support for PowerPC platforms.
|
||||||
|
[Andy Polyakov]
|
||||||
|
|
||||||
|
*) Add lots of checks for memory allocation failure, error codes to indicate
|
||||||
|
failure and freeing up memory if a failure occurs.
|
||||||
|
[Nauticus Networks SSL Team <openssl@nauticusnet.com>, Steve Henson]
|
||||||
|
|
||||||
|
*) Add new -passin argument to dgst.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Perform some character comparisons of different types in X509_NAME_cmp:
|
||||||
|
this is needed for some certificates that reencode DNs into UTF8Strings
|
||||||
|
(in violation of RFC3280) and can't or wont issue name rollover
|
||||||
|
certificates.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Make an explicit check during certificate validation to see that
|
||||||
|
the CA setting in each certificate on the chain is correct. As a
|
||||||
|
side effect always do the following basic checks on extensions,
|
||||||
|
not just when there's an associated purpose to the check:
|
||||||
|
|
||||||
|
- if there is an unhandled critical extension (unless the user
|
||||||
|
has chosen to ignore this fault)
|
||||||
|
- if the path length has been exceeded (if one is set at all)
|
||||||
|
- that certain extensions fit the associated purpose (if one has
|
||||||
|
been given)
|
||||||
|
[Richard Levitte]
|
||||||
|
|
||||||
|
Changes between 0.9.7d and 0.9.7e [25 Oct 2004]
|
||||||
|
|
||||||
|
*) Avoid a race condition when CRLs are checked in a multi threaded
|
||||||
|
environment. This would happen due to the reordering of the revoked
|
||||||
|
entries during signature checking and serial number lookup. Now the
|
||||||
|
encoding is cached and the serial number sort performed under a lock.
|
||||||
|
Add new STACK function sk_is_sorted().
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Add Delta CRL to the extension code.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Various fixes to s3_pkt.c so alerts are sent properly.
|
||||||
|
[David Holmes <d.holmes@f5.com>]
|
||||||
|
|
||||||
|
*) Reduce the chances of duplicate issuer name and serial numbers (in
|
||||||
|
violation of RFC3280) using the OpenSSL certificate creation utilities.
|
||||||
|
This is done by creating a random 64 bit value for the initial serial
|
||||||
|
number when a serial number file is created or when a self signed
|
||||||
|
certificate is created using 'openssl req -x509'. The initial serial
|
||||||
|
number file is created using 'openssl x509 -next_serial' in CA.pl
|
||||||
|
rather than being initialized to 1.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
Changes between 0.9.7c and 0.9.7d [17 Mar 2004]
|
||||||
|
|
||||||
|
*) Fix null-pointer assignment in do_change_cipher_spec() revealed
|
||||||
|
by using the Codenomicon TLS Test Tool (CAN-2004-0079)
|
||||||
|
[Joe Orton, Steve Henson]
|
||||||
|
|
||||||
|
*) Fix flaw in SSL/TLS handshaking when using Kerberos ciphersuites
|
||||||
|
(CAN-2004-0112)
|
||||||
|
[Joe Orton, Steve Henson]
|
||||||
|
|
||||||
|
*) Make it possible to have multiple active certificates with the same
|
||||||
|
subject in the CA index file. This is done only if the keyword
|
||||||
|
'unique_subject' is set to 'no' in the main CA section (default
|
||||||
|
if 'CA_default') of the configuration file. The value is saved
|
||||||
|
with the database itself in a separate index attribute file,
|
||||||
|
named like the index file with '.attr' appended to the name.
|
||||||
|
[Richard Levitte]
|
||||||
|
|
||||||
|
*) X509 verify fixes. Disable broken certificate workarounds when
|
||||||
|
X509_V_FLAGS_X509_STRICT is set. Check CRL issuer has cRLSign set if
|
||||||
|
keyUsage extension present. Don't accept CRLs with unhandled critical
|
||||||
|
extensions: since verify currently doesn't process CRL extensions this
|
||||||
|
rejects a CRL with *any* critical extensions. Add new verify error codes
|
||||||
|
for these cases.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) When creating an OCSP nonce use an OCTET STRING inside the extnValue.
|
||||||
|
A clarification of RFC2560 will require the use of OCTET STRINGs and
|
||||||
|
some implementations cannot handle the current raw format. Since OpenSSL
|
||||||
|
copies and compares OCSP nonces as opaque blobs without any attempt at
|
||||||
|
parsing them this should not create any compatibility issues.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) New md flag EVP_MD_CTX_FLAG_REUSE this allows md_data to be reused when
|
||||||
|
calling EVP_MD_CTX_copy_ex() to avoid calling OPENSSL_malloc(). Without
|
||||||
|
this HMAC (and other) operations are several times slower than OpenSSL
|
||||||
|
< 0.9.7.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Print out GeneralizedTime and UTCTime in ASN1_STRING_print_ex().
|
||||||
|
[Peter Sylvester <Peter.Sylvester@EdelWeb.fr>]
|
||||||
|
|
||||||
|
*) Use the correct content when signing type "other".
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
Changes between 0.9.7b and 0.9.7c [30 Sep 2003]
|
||||||
|
|
||||||
|
*) Fix various bugs revealed by running the NISCC test suite:
|
||||||
|
|
||||||
|
Stop out of bounds reads in the ASN1 code when presented with
|
||||||
|
invalid tags (CAN-2003-0543 and CAN-2003-0544).
|
||||||
|
|
||||||
|
Free up ASN1_TYPE correctly if ANY type is invalid (CAN-2003-0545).
|
||||||
|
|
||||||
|
If verify callback ignores invalid public key errors don't try to check
|
||||||
|
certificate signature with the NULL public key.
|
||||||
|
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) New -ignore_err option in ocsp application to stop the server
|
||||||
|
exiting on the first error in a request.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) In ssl3_accept() (ssl/s3_srvr.c) only accept a client certificate
|
||||||
|
if the server requested one: as stated in TLS 1.0 and SSL 3.0
|
||||||
|
specifications.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) In ssl3_get_client_hello() (ssl/s3_srvr.c), tolerate additional
|
||||||
|
extra data after the compression methods not only for TLS 1.0
|
||||||
|
but also for SSL 3.0 (as required by the specification).
|
||||||
|
[Bodo Moeller; problem pointed out by Matthias Loepfe]
|
||||||
|
|
||||||
|
*) Change X509_certificate_type() to mark the key as exported/exportable
|
||||||
|
when it's 512 *bits* long, not 512 bytes.
|
||||||
|
[Richard Levitte]
|
||||||
|
|
||||||
|
*) Change AES_cbc_encrypt() so it outputs exact multiple of
|
||||||
|
blocks during encryption.
|
||||||
|
[Richard Levitte]
|
||||||
|
|
||||||
|
*) Various fixes to base64 BIO and non blocking I/O. On write
|
||||||
|
flushes were not handled properly if the BIO retried. On read
|
||||||
|
data was not being buffered properly and had various logic bugs.
|
||||||
|
This also affects blocking I/O when the data being decoded is a
|
||||||
|
certain size.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) Various S/MIME bugfixes and compatibility changes:
|
||||||
|
output correct application/pkcs7 MIME type if
|
||||||
|
PKCS7_NOOLDMIMETYPE is set. Tolerate some broken signatures.
|
||||||
|
Output CR+LF for EOL if PKCS7_CRLFEOL is set (this makes opening
|
||||||
|
of files as .eml work). Correctly handle very long lines in MIME
|
||||||
|
parser.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
Changes between 0.9.7a and 0.9.7b [10 Apr 2003]
|
||||||
|
|
||||||
|
*) Countermeasure against the Klima-Pokorny-Rosa extension of
|
||||||
|
Bleichbacher's attack on PKCS #1 v1.5 padding: treat
|
||||||
|
a protocol version number mismatch like a decryption error
|
||||||
|
in ssl3_get_client_key_exchange (ssl/s3_srvr.c).
|
||||||
|
[Bodo Moeller]
|
||||||
|
|
||||||
|
*) Turn on RSA blinding by default in the default implementation
|
||||||
|
to avoid a timing attack. Applications that don't want it can call
|
||||||
|
RSA_blinding_off() or use the new flag RSA_FLAG_NO_BLINDING.
|
||||||
|
They would be ill-advised to do so in most cases.
|
||||||
|
[Ben Laurie, Steve Henson, Geoff Thorpe, Bodo Moeller]
|
||||||
|
|
||||||
|
*) Change RSA blinding code so that it works when the PRNG is not
|
||||||
|
seeded (in this case, the secret RSA exponent is abused as
|
||||||
|
an unpredictable seed -- if it is not unpredictable, there
|
||||||
|
is no point in blinding anyway). Make RSA blinding thread-safe
|
||||||
|
by remembering the creator's thread ID in rsa->blinding and
|
||||||
|
having all other threads use local one-time blinding factors
|
||||||
|
(this requires more computation than sharing rsa->blinding, but
|
||||||
|
avoids excessive locking; and if an RSA object is not shared
|
||||||
|
between threads, blinding will still be very fast).
|
||||||
|
[Bodo Moeller]
|
||||||
|
|
||||||
|
*) Fixed a typo bug that would cause ENGINE_set_default() to set an
|
||||||
|
ENGINE as defaults for all supported algorithms irrespective of
|
||||||
|
the 'flags' parameter. 'flags' is now honoured, so applications
|
||||||
|
should make sure they are passing it correctly.
|
||||||
|
[Geoff Thorpe]
|
||||||
|
|
||||||
|
*) Target "mingw" now allows native Windows code to be generated in
|
||||||
|
the Cygwin environment as well as with the MinGW compiler.
|
||||||
|
[Ulf Moeller]
|
||||||
|
|
||||||
Changes between 0.9.7 and 0.9.7a [19 Feb 2003]
|
Changes between 0.9.7 and 0.9.7a [19 Feb 2003]
|
||||||
|
|
||||||
*) In ssl3_get_record (ssl/s3_pkt.c), minimize information leaked
|
*) In ssl3_get_record (ssl/s3_pkt.c), minimize information leaked
|
||||||
@@ -85,6 +371,9 @@
|
|||||||
|
|
||||||
Changes between 0.9.6h and 0.9.7 [31 Dec 2002]
|
Changes between 0.9.6h and 0.9.7 [31 Dec 2002]
|
||||||
|
|
||||||
|
[NB: OpenSSL 0.9.6i and later 0.9.6 patch levels were released after
|
||||||
|
OpenSSL 0.9.7.]
|
||||||
|
|
||||||
*) Fix session ID handling in SSLv2 client code: the SERVER FINISHED
|
*) Fix session ID handling in SSLv2 client code: the SERVER FINISHED
|
||||||
code (06) was taken as the first octet of the session ID and the last
|
code (06) was taken as the first octet of the session ID and the last
|
||||||
octet was ignored consequently. As a result SSLv2 client side session
|
octet was ignored consequently. As a result SSLv2 client side session
|
||||||
@@ -1903,6 +2192,71 @@ des-cbc 3624.96k 5258.21k 5530.91k 5624.30k 5628.26k
|
|||||||
*) Clean old EAY MD5 hack from e_os.h.
|
*) Clean old EAY MD5 hack from e_os.h.
|
||||||
[Richard Levitte]
|
[Richard Levitte]
|
||||||
|
|
||||||
|
Changes between 0.9.6l and 0.9.6m [17 Mar 2004]
|
||||||
|
|
||||||
|
*) Fix null-pointer assignment in do_change_cipher_spec() revealed
|
||||||
|
by using the Codenomicon TLS Test Tool (CAN-2004-0079)
|
||||||
|
[Joe Orton, Steve Henson]
|
||||||
|
|
||||||
|
Changes between 0.9.6k and 0.9.6l [04 Nov 2003]
|
||||||
|
|
||||||
|
*) Fix additional bug revealed by the NISCC test suite:
|
||||||
|
|
||||||
|
Stop bug triggering large recursion when presented with
|
||||||
|
certain ASN.1 tags (CAN-2003-0851)
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
Changes between 0.9.6j and 0.9.6k [30 Sep 2003]
|
||||||
|
|
||||||
|
*) Fix various bugs revealed by running the NISCC test suite:
|
||||||
|
|
||||||
|
Stop out of bounds reads in the ASN1 code when presented with
|
||||||
|
invalid tags (CAN-2003-0543 and CAN-2003-0544).
|
||||||
|
|
||||||
|
If verify callback ignores invalid public key errors don't try to check
|
||||||
|
certificate signature with the NULL public key.
|
||||||
|
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) In ssl3_accept() (ssl/s3_srvr.c) only accept a client certificate
|
||||||
|
if the server requested one: as stated in TLS 1.0 and SSL 3.0
|
||||||
|
specifications.
|
||||||
|
[Steve Henson]
|
||||||
|
|
||||||
|
*) In ssl3_get_client_hello() (ssl/s3_srvr.c), tolerate additional
|
||||||
|
extra data after the compression methods not only for TLS 1.0
|
||||||
|
but also for SSL 3.0 (as required by the specification).
|
||||||
|
[Bodo Moeller; problem pointed out by Matthias Loepfe]
|
||||||
|
|
||||||
|
*) Change X509_certificate_type() to mark the key as exported/exportable
|
||||||
|
when it's 512 *bits* long, not 512 bytes.
|
||||||
|
[Richard Levitte]
|
||||||
|
|
||||||
|
Changes between 0.9.6i and 0.9.6j [10 Apr 2003]
|
||||||
|
|
||||||
|
*) Countermeasure against the Klima-Pokorny-Rosa extension of
|
||||||
|
Bleichbacher's attack on PKCS #1 v1.5 padding: treat
|
||||||
|
a protocol version number mismatch like a decryption error
|
||||||
|
in ssl3_get_client_key_exchange (ssl/s3_srvr.c).
|
||||||
|
[Bodo Moeller]
|
||||||
|
|
||||||
|
*) Turn on RSA blinding by default in the default implementation
|
||||||
|
to avoid a timing attack. Applications that don't want it can call
|
||||||
|
RSA_blinding_off() or use the new flag RSA_FLAG_NO_BLINDING.
|
||||||
|
They would be ill-advised to do so in most cases.
|
||||||
|
[Ben Laurie, Steve Henson, Geoff Thorpe, Bodo Moeller]
|
||||||
|
|
||||||
|
*) Change RSA blinding code so that it works when the PRNG is not
|
||||||
|
seeded (in this case, the secret RSA exponent is abused as
|
||||||
|
an unpredictable seed -- if it is not unpredictable, there
|
||||||
|
is no point in blinding anyway). Make RSA blinding thread-safe
|
||||||
|
by remembering the creator's thread ID in rsa->blinding and
|
||||||
|
having all other threads use local one-time blinding factors
|
||||||
|
(this requires more computation than sharing rsa->blinding, but
|
||||||
|
avoids excessive locking; and if an RSA object is not shared
|
||||||
|
between threads, blinding will still be very fast).
|
||||||
|
[Bodo Moeller]
|
||||||
|
|
||||||
Changes between 0.9.6h and 0.9.6i [19 Feb 2003]
|
Changes between 0.9.6h and 0.9.6i [19 Feb 2003]
|
||||||
|
|
||||||
*) In ssl3_get_record (ssl/s3_pkt.c), minimize information leaked
|
*) In ssl3_get_record (ssl/s3_pkt.c), minimize information leaked
|
||||||
|
|||||||
217
Configure
217
Configure
@@ -10,7 +10,7 @@ use strict;
|
|||||||
|
|
||||||
# see INSTALL for instructions.
|
# see INSTALL for instructions.
|
||||||
|
|
||||||
my $usage="Usage: Configure [no-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [no-engine] [no-hw-xxx|no-hw] [[no-]threads] [[no-]shared] [[no-]zlib|zlib-dynamic] [no-asm] [no-dso] [no-krb5] [386] [--prefix=DIR] [--openssldir=OPENSSLDIR] [--with-xxx[=vvv]] [--test-sanity] os/compiler[:flags]\n";
|
my $usage="Usage: Configure [no-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [no-engine] [no-hw-xxx|no-hw] [[no-]threads] [[no-]shared] [[no-]zlib|zlib-dynamic] [no-asm] [no-dso] [no-krb5] [386] [[no-]fips] [debug] [--prefix=DIR] [--openssldir=OPENSSLDIR] [--with-xxx[=vvv]] [--test-sanity] os/compiler[:flags]\n";
|
||||||
|
|
||||||
# Options:
|
# Options:
|
||||||
#
|
#
|
||||||
@@ -135,26 +135,33 @@ my %table=(
|
|||||||
# Our development configs
|
# Our development configs
|
||||||
"purify", "purify gcc:-g -DPURIFY -Wall::(unknown)::-lsocket -lnsl::::",
|
"purify", "purify gcc:-g -DPURIFY -Wall::(unknown)::-lsocket -lnsl::::",
|
||||||
"debug", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -ggdb -g2 -Wformat -Wshadow -Wmissing-prototypes -Wmissing-declarations -Werror::(unknown)::-lefence::::",
|
"debug", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -ggdb -g2 -Wformat -Wshadow -Wmissing-prototypes -Wmissing-declarations -Werror::(unknown)::-lefence::::",
|
||||||
"debug-ben", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::asm/bn86-elf.o asm/co86-elf.o",
|
"debug-ben", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -O2 -Wall -Wshadow -Werror -pipe::(unknown)::::asm/bn86-elf.o asm/co86-elf.o",
|
||||||
"debug-ben-openbsd","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DOPENSSL_OPENBSD_DEV_CRYPTO -DOPENSSL_NO_ASM -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::",
|
"debug-ben-openbsd","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DOPENSSL_OPENBSD_DEV_CRYPTO -DOPENSSL_NO_ASM -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::",
|
||||||
"debug-ben-openbsd-debug","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DOPENSSL_OPENBSD_DEV_CRYPTO -DOPENSSL_NO_ASM -g3 -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::",
|
"debug-ben-openbsd-debug","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DOPENSSL_OPENBSD_DEV_CRYPTO -DOPENSSL_NO_ASM -g3 -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::",
|
||||||
"debug-ben-debug", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -g3 -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::::",
|
"debug-ben-debug", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -g3 -O2 -Wall -Wshadow -Werror -pipe::(unknown)::::::",
|
||||||
"debug-ben-strict", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DCONST_STRICT -O2 -Wall -Wshadow -Werror -Wpointer-arith -Wcast-qual -Wwrite-strings -pipe::(unknown)::::::",
|
"debug-ben-strict", "gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DCONST_STRICT -O2 -Wall -Wshadow -Werror -Wpointer-arith -Wcast-qual -Wwrite-strings -pipe::(unknown)::::::",
|
||||||
|
"debug-ben-fips-debug","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DOPENSSL_FIPS -g3 -O2 -pedantic -Wall -Wshadow -Werror -pipe::(unknown)::::asm/bn86-elf.o asm/co86-elf.o",
|
||||||
"debug-rse","cc:-DTERMIOS -DL_ENDIAN -pipe -O -g -ggdb3 -Wall::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
"debug-rse","cc:-DTERMIOS -DL_ENDIAN -pipe -O -g -ggdb3 -Wall::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
||||||
"debug-bodo", "gcc:-DL_ENDIAN -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DBIO_PAIR_DEBUG -DPEDANTIC -g -m486 -pedantic -Wshadow -Wall::-D_REENTRANT:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
"debug-bodo", "gcc:-DL_ENDIAN -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DBIO_PAIR_DEBUG -DPEDANTIC -g -m486 -pedantic -Wshadow -Wall::-D_REENTRANT:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
||||||
"debug-ulf", "gcc:-DL_ENDIAN -DREF_CHECK -DCONF_DEBUG -DBN_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -g -O2 -m486 -Wall -Werror -Wshadow -pipe::-D_REENTRANT:::${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
"debug-ulf", "gcc:-DL_ENDIAN -DREF_CHECK -DCONF_DEBUG -DBN_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG_ALL -g -O2 -m486 -Wall -Werror -Wshadow -pipe::-D_REENTRANT:::${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
||||||
"debug-steve", "gcc:-DL_ENDIAN -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DDEBUG_SAFESTACK -DCRYPTO_MDEBUG_ALL -DPEDANTIC -g -mcpu=i486 -pedantic -Wall -Werror -Wshadow -pipe::-D_REENTRANT::-rdynamic -ldl:${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
"debug-steve", "gcc:-DL_ENDIAN -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DDEBUG_SAFESTACK -DCRYPTO_MDEBUG_ALL -DPEDANTIC -g -mcpu=i486 -pedantic -Wno-long-long -Wall -Werror -Wshadow -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||||
"debug-steve-linux-pseudo64", "gcc:-DL_ENDIAN -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DDEBUG_SAFESTACK -DCRYPTO_MDEBUG_ALL -DOPENSSL_NO_ASM -g -mcpu=i486 -Wall -Werror -Wshadow -pipe::-D_REENTRANT::-rdynamic -ldl:SIXTY_FOUR_BIT::dlfcn",
|
"debug-steve-linux-pseudo64", "gcc:-DL_ENDIAN -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DDEBUG_SAFESTACK -DCRYPTO_MDEBUG_ALL -DOPENSSL_NO_ASM -g -mcpu=i486 -Wall -Werror -Wshadow -pipe::-D_REENTRANT::-rdynamic -ldl:SIXTY_FOUR_BIT::dlfcn",
|
||||||
"debug-levitte-linux-elf","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-levitte-linux-elf","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -Wshadow -Wcast-align -Wmissing-prototypes -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-levitte-linux-noasm","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-levitte-linux-noasm","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -Wshadow -Wcast-align -Wmissing-prototypes -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-levitte-linux-elf-extreme","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wconversion -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-levitte-linux-elf-extreme","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wmissing-prototypes -Wconversion -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-levitte-linux-noasm-extreme","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wconversion -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-levitte-linux-noasm-extreme","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wmissing-prototypes -Wconversion -Wno-long-long -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"dist", "cc:-O::(unknown)::::::",
|
"dist", "cc:-O::(unknown)::::::",
|
||||||
|
|
||||||
# Basic configs that should work on any (32 and less bit) box
|
# Basic configs that should work on any (32 and less bit) box
|
||||||
"gcc", "gcc:-O3::(unknown):::BN_LLONG:::",
|
"gcc", "gcc:-O3::(unknown):::BN_LLONG:::",
|
||||||
"cc", "cc:-O::(unknown)::::::",
|
"cc", "cc:-O::(unknown)::::::",
|
||||||
|
|
||||||
|
####VOS Configurations
|
||||||
|
"vos-gcc","gcc:-b hppa1.1-stratus-vos -O3 -Wall -Wuninitialized -D_POSIX_C_SOURCE=200112L -D_BSD::(unknown):VOS:-Wl,-map:BN_LLONG:::::::::::::.so:",
|
||||||
|
"debug-vos-gcc","gcc:-b hppa1.1-stratus-vos -O0 -g -Wall -D_POSIX_C_SOURCE=200112L -D_BSD -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG::(unknown):VOS:-Wl,-map:BN_LLONG:::::::::::::.so:",
|
||||||
|
"vos-vcc","vcc:-b i386-stratus-vos -O3 -D_POSIX_C_SOURCE=200112L -D_BSD::(unknown):VOS:-Wl,-map::::::::::::::.so:",
|
||||||
|
"debug-vos-vcc","vcc:-b i386-stratus-vos -O0 -g -D_POSIX_C_SOURCE=200112L -D_BSD -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG::(unknown):VOS:-Wl,-map::::::::::::::.so:",
|
||||||
|
|
||||||
#### Solaris x86 with GNU C setups
|
#### Solaris x86 with GNU C setups
|
||||||
# -DOPENSSL_NO_INLINE_ASM switches off inline assembler. We have to do it
|
# -DOPENSSL_NO_INLINE_ASM switches off inline assembler. We have to do it
|
||||||
# here because whenever GNU C instantiates an assembler template it
|
# here because whenever GNU C instantiates an assembler template it
|
||||||
@@ -162,9 +169,19 @@ my %table=(
|
|||||||
# 7_x86) /usr/ccs/bin/as fails to assemble with "Illegal mnemonic"
|
# 7_x86) /usr/ccs/bin/as fails to assemble with "Illegal mnemonic"
|
||||||
# error message.
|
# error message.
|
||||||
"solaris-x86-gcc","gcc:-O3 -fomit-frame-pointer -m486 -Wall -DL_ENDIAN -DOPENSSL_NO_INLINE_ASM::-D_REENTRANT::-lsocket -lnsl -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:solaris-shared:-fPIC:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"solaris-x86-gcc","gcc:-O3 -fomit-frame-pointer -m486 -Wall -DL_ENDIAN -DOPENSSL_NO_INLINE_ASM::-D_REENTRANT::-lsocket -lnsl -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:solaris-shared:-fPIC:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
# -shared -static-libgcc might appear controversial, but modules taken
|
||||||
|
# from static libgcc do not have relocations and linking them into our
|
||||||
|
# shared objects doesn't have any negative side-effects. On the contrary,
|
||||||
|
# doing so makes it possible to use gcc shared build with Sun C. Given
|
||||||
|
# that gcc generates faster code [thanks to inline assembler], I would
|
||||||
|
# actually recommend to consider using gcc shared build even with vendor
|
||||||
|
# compiler:-)
|
||||||
|
# <appro@fy.chalmers.se>
|
||||||
|
"solaris64-x86_64-gcc","gcc:-m64 -O3 -Wall -DL_ENDIAN -DMD32_REG_T=int::-D_REENTRANT::-lsocket -lnsl -ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR BF_PTR2 DES_INT DES_UNROLL:asm/x86_64-gcc.o::::::asm/rc4-x86_64.o:::dlfcn:solaris-shared:-fPIC:-m64 -shared -static-libgcc:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
#### Solaris x86 with Sun C setups
|
#### 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)",
|
"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:-G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"solaris64-x86_64-cc","cc:-fast -xarch=amd64 -xstrconst -Xa -DL_ENDIAN::-D_REENTRANT::-lsocket -lnsl -ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR BF_PTR2 DES_INT DES_UNROLL::::::::::dlfcn:solaris-shared:-KPIC:-xarch=amd64 -G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
#### SPARC Solaris with GNU C setups
|
#### 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:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
@@ -183,17 +200,17 @@ my %table=(
|
|||||||
|
|
||||||
#### SPARC Solaris with Sun C setups
|
#### 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
|
# 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::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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:-G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# SC4.0 doesn't pass 'make test', upgrade to SC5.0 or SC4.2.
|
# 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
|
# 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!
|
# 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::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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:-G -dy -z text:.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-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::-D_REENTRANT:ULTRASPARC:-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)",
|
"solaris-sparcv9-cc","cc:-xtarget=ultra -xarch=v8plus -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT:ULTRASPARC:-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:-G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"solaris64-sparcv9-cc","cc:-xtarget=ultra -xarch=v9 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN::-D_REENTRANT:ULTRASPARC:-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:-xarch=v9:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):/usr/ccs/bin/ar rs",
|
"solaris64-sparcv9-cc","cc:-xtarget=ultra -xarch=v9 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN::-D_REENTRANT:ULTRASPARC:-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:-xarch=v9 -G -dy -z text:.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::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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:-G -dy -z text:.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::-D_REENTRANT:ULTRASPARC:-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)",
|
"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::-D_REENTRANT:ULTRASPARC:-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:-G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
#### SPARC Linux setups
|
#### 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::",
|
"linux-sparcv7","gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT:::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR::",
|
||||||
@@ -216,13 +233,13 @@ my %table=(
|
|||||||
"irix-cc", "cc:-O2 -use_readonly_const -DTERMIOS -DB_ENDIAN::(unknown):::BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC2 DES_UNROLL BF_PTR::::::::::dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"irix-cc", "cc:-O2 -use_readonly_const -DTERMIOS -DB_ENDIAN::(unknown):::BN_LLONG RC4_CHAR RC4_CHUNK DES_PTR DES_RISC2 DES_UNROLL BF_PTR::::::::::dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
#### IRIX 6.x configs
|
#### IRIX 6.x configs
|
||||||
# Only N32 and N64 ABIs are supported. If you need O32 ABI build, invoke
|
# Only N32 and N64 ABIs are supported. If you need O32 ABI build, invoke
|
||||||
# './Configure irix-[g]cc' manually.
|
# './Configure irix-cc -o32' manually.
|
||||||
# -mips4 flag is added by ./config when appropriate.
|
# -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:${mips3_irix_asm}:dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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}:dlfcn:irix-shared::-mabi=n32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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}:dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"irix-mips3-cc", "cc:-n32 -mips3 -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}:dlfcn:irix-shared::-n32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# N64 ABI builds.
|
# 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:${mips3_irix_asm}:dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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}:dlfcn:irix-shared::-mabi=64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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}:dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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}:dlfcn:irix-shared::-64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
#### Unified HP-UX ANSI C configs.
|
#### Unified HP-UX ANSI C configs.
|
||||||
# Special notes:
|
# Special notes:
|
||||||
@@ -254,55 +271,56 @@ my %table=(
|
|||||||
#
|
#
|
||||||
#!#"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
|
# 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-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc-cc-o4","cc:-Ae +O4 +ESlit -z -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY::::-Wl,+cdp,../%3a,+cdp,./%3a,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"hpux-parisc-gcc","gcc:-O3 -DB_ENDIAN -DBN_DIV2W::::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc-gcc","gcc:-O3 -DB_ENDIAN -DBN_DIV2W::::-Wl,+cdp,../%3a,+cdp,./%3a,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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:hpux64-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux64-parisc-cc","cc:-Ae +DD64 +O3 +ESlit -z -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dlfcn:hpux-shared:+Z:+DD64 -b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# 64bit PARISC for GCC without optimization, which seems to make problems.
|
# 64bit PARISC for GCC without optimization, which seems to make problems.
|
||||||
# Submitted by <ross.alexander@uk.neceur.com>
|
# Submitted by <ross.alexander@uk.neceur.com>
|
||||||
"hpux64-parisc-gcc","gcc:-DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dlfcn:hpux64-shared:-fpic::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux64-parisc-gcc","gcc:-DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dlfcn:hpux-shared:-fpic:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"hpux64-parisc2-gcc","gcc:-O3 -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/pa-risc2W.o:::::::::dlfcn:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# IA-64 targets
|
# IA-64 targets
|
||||||
"hpux-ia64-cc","cc:-Ae +DD32 +O3 +Olit=all -z -DB_ENDIAN::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/ia64-cpp.o:::::::::dlfcn:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-ia64-cc","cc:-Ae +DD32 +O3 +Olit=all -z -DB_ENDIAN::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldl:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX DES_UNROLL DES_RISC1 DES_INT:asm/ia64-cpp.o::::asm/sha1-ia64.o::asm/rc4-ia64.o:::dlfcn:hpux-shared:+Z:-b:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# Frank Geurts <frank.geurts@nl.abnamro.com> has patiently assisted with
|
# Frank Geurts <frank.geurts@nl.abnamro.com> has patiently assisted with
|
||||||
# with debugging of the following config.
|
# with debugging of the following config.
|
||||||
"hpux64-ia64-cc","cc:-Ae +DD64 +O3 +Olit=all -z -DB_ENDIAN::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/ia64-cpp.o:::::::::dlfcn:hpux64-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux64-ia64-cc","cc:-Ae +DD64 +O3 +Olit=all -z -DB_ENDIAN::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX DES_UNROLL DES_RISC1 DES_INT:asm/ia64-cpp.o::::asm/sha1-ia64.o::asm/rc4-ia64.o:::dlfcn:hpux-shared:+Z:+DD64 -b:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# More attempts at unified 10.X and 11.X targets for HP C compiler.
|
# More attempts at unified 10.X and 11.X targets for HP C compiler.
|
||||||
#
|
#
|
||||||
# Chris Ruemmler <ruemmler@cup.hp.com>
|
# Chris Ruemmler <ruemmler@cup.hp.com>
|
||||||
# Kevin Steves <ks@hp.se>
|
# Kevin Steves <ks@hp.se>
|
||||||
"hpux-parisc-cc","cc:+O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY::-D_REENTRANT::-Wl,+s -ldld:MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc-cc","cc:+O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY::-D_REENTRANT::-Wl,+cdp,../%3a,+cdp,./%3a,+s,+b,\$(INSTALLTOP)/lib -ldld:MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"hpux-parisc2-cc","cc:+DA2.0 +DS2.0 +O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+s -ldld:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/pa-risc2.o:::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc2-cc","cc:+DA2.0 +DS2.0 +O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+cdp,../%3a,+cdp,./%3a,+s,+b,\$(INSTALLTOP)/lib -ldld:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/pa-risc2.o:::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"hpux64-parisc2-cc","cc:+DD64 +O3 +Optrs_strongly_typed -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:hpux64-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux64-parisc2-cc","cc:+DD64 +O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT:asm/pa-risc2W.o:::::::::dlfcn:hpux-shared:+Z:+DD64 -b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# Isn't the line below meaningless? HP-UX cc optimizes for host by default.
|
# Isn't the line below meaningless? HP-UX cc optimizes for host by default.
|
||||||
# hpux-parisc1_0-cc with +DAportable flag would make more sense. <appro>
|
# hpux-parisc1_0-cc with +DAportable flag would make more sense. <appro>
|
||||||
"hpux-parisc1_1-cc","cc:+DA1.1 +DS1.1 +O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+s -ldld:MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc1_1-cc","cc:+DA1.1 +DS1.1 +O3 +Optrs_strongly_typed -Ae +ESlit -DB_ENDIAN -DMD32_XARRAY::-D_REENTRANT::-Wl,+cdp,../%3a,+cdp,./%3a,+s,+b,\$(INSTALLTOP)/lib -ldld:MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# HPUX 9.X config.
|
# HPUX 9.X config.
|
||||||
# Don't use the bundled cc. It is broken. Use HP ANSI C if possible, or
|
# Don't use the bundled cc. It is broken. Use HP ANSI C if possible, or
|
||||||
# egcs. gcc 2.8.1 is also broken.
|
# egcs. gcc 2.8.1 is also broken.
|
||||||
|
|
||||||
"hpux-cc", "cc:-DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY -Ae +ESlit +O3 -z::(unknown)::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-cc", "cc:-DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY -Ae +ESlit +O3 -z::(unknown)::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# If hpux-cc fails (e.g. during "make test"), try the next one; otherwise,
|
# If hpux-cc fails (e.g. during "make test"), try the next one; otherwise,
|
||||||
# please report your OS and compiler version to the openssl-bugs@openssl.org
|
# please report your OS and compiler version to the openssl-bugs@openssl.org
|
||||||
# mailing list.
|
# mailing list.
|
||||||
"hpux-brokencc", "cc:-DB_ENDIAN -DBN_DIV2W -Ae +ESlit +O2 -z::(unknown)::-Wl,+s -ldld:DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-brokencc", "cc:-DB_ENDIAN -DBN_DIV2W -Ae +ESlit +O2 -z::(unknown)::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
"hpux-gcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::(unknown)::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-gcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::(unknown)::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# If hpux-gcc fails, try this one:
|
# If hpux-gcc fails, try this one:
|
||||||
"hpux-brokengcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::(unknown)::-Wl,+s -ldld:DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-brokengcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::(unknown)::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# HPUX 9.X on Motorola 68k platforms with gcc
|
# HPUX 9.X on Motorola 68k platforms with gcc
|
||||||
"hpux-m68k-gcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::(unknown):::BN_LLONG DES_PTR DES_UNROLL:::::::::::::",
|
"hpux-m68k-gcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::(unknown):::BN_LLONG DES_PTR DES_UNROLL:::::::::::::",
|
||||||
|
|
||||||
# HPUX 10.X config. Supports threads.
|
# HPUX 10.X config. Supports threads.
|
||||||
"hpux10-cc", "cc:-DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY -Ae +ESlit +O3 -z::-D_REENTRANT::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux10-cc", "cc:-DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY -Ae +ESlit +O3 -z::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# If hpux10-cc fails, try this one (if still fails, try deleting BN_LLONG):
|
# If hpux10-cc fails, try this one (if still fails, try deleting BN_LLONG):
|
||||||
"hpux10-brokencc", "cc:-DB_ENDIAN -DBN_DIV2W -Ae +ESlit +O2 -z::-D_REENTRANT::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux10-brokencc", "cc:-DB_ENDIAN -DBN_DIV2W -Ae +ESlit +O2 -z::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
"hpux10-gcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::-D_REENTRANT::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux10-gcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
# If hpux10-gcc fails, try this one:
|
# If hpux10-gcc fails, try this one:
|
||||||
"hpux10-brokengcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::-D_REENTRANT::-Wl,+s -ldld:DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC::.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux10-brokengcc", "gcc:-DB_ENDIAN -DBN_DIV2W -O3::-D_REENTRANT::-Wl,+s,+b,\$(INSTALLTOP)/lib -ldld:DES_PTR DES_UNROLL DES_RISC1::::::::::dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# HPUX 11.X from www.globus.org.
|
# HPUX 11.X from www.globus.org.
|
||||||
# Only works on PA-RISC 2.0 cpus, and not optimized. Why?
|
# Only works on PA-RISC 2.0 cpus, and not optimized. Why?
|
||||||
@@ -381,16 +399,19 @@ my %table=(
|
|||||||
"debug-linux-pentium","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -mcpu=pentium -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
"debug-linux-pentium","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -mcpu=pentium -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||||
"debug-linux-ppro","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -mcpu=pentiumpro -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
"debug-linux-ppro","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -mcpu=pentiumpro -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn",
|
||||||
"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: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:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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",
|
"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-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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-aout", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486 -Wall::(unknown):::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}",
|
||||||
"linux-mipsel", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-mipsel", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-mips", "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-mips", "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL DES_RISC2::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-ppc", "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-ppc", "gcc:-DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:asm/linux_ppc32.o:::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
# -bpowerpc64-linux is transient option, -m64 should be the one to use...
|
||||||
|
"linux-ppc64", "gcc:-bpowerpc64-linux -DB_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_RISC1 DES_UNROLL:asm/linux_ppc64.o:::::::::dlfcn:linux-shared:-fPIC:-bpowerpc64-linux:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-m68k", "gcc:-DB_ENDIAN -DTERMIO -O2 -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 -DNO_ASM -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-s390", "gcc:-DB_ENDIAN -DTERMIO -DNO_ASM -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-s390x", "gcc:-DB_ENDIAN -DTERMIO -DNO_ASM -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-s390x", "gcc:-DB_ENDIAN -DTERMIO -DNO_ASM -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-ia64", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR:asm/ia64.o:::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-ia64", "gcc:-DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK:asm/ia64.o::::asm/sha1-ia64.o::asm/rc4-ia64.o:::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-x86_64", "gcc:-m64 -DL_ENDIAN -DTERMIO -O3 -Wall -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR BF_PTR2 DES_INT DES_UNROLL:asm/x86_64-gcc.o:::::::::dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-ia64-ecc", "ecc:-DL_ENDIAN -DTERMIO -O2 -Wall -no_cpprt::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK:asm/ia64.o::::asm/sha1-ia64.o::asm/rc4-ia64.o:::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"linux-x86_64", "gcc:-m64 -DL_ENDIAN -DTERMIO -O3 -Wall -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK RC4_CHAR BF_PTR2 DES_INT DES_UNROLL:asm/x86_64-gcc.o::::::asm/rc4-x86_64.o:::dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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-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-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)",
|
"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)",
|
||||||
@@ -413,7 +434,9 @@ my %table=(
|
|||||||
"qnx6", "cc:-DL_ENDIAN -DTERMIOS::(unknown)::-lsocket:${x86_gcc_des} ${x86_gcc_opts}:",
|
"qnx6", "cc:-DL_ENDIAN -DTERMIOS::(unknown)::-lsocket:${x86_gcc_des} ${x86_gcc_opts}:",
|
||||||
|
|
||||||
# Linux on ARM
|
# Linux on ARM
|
||||||
"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)",
|
# ARM comes in both little- and big-endian flavors. The following line is
|
||||||
|
# endian neutral, but ./config is free to throw in -D[BL]_ENDIAN...
|
||||||
|
"linux-elf-arm","gcc:-DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG::::::::::dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# SCO/Caldera targets.
|
# SCO/Caldera targets.
|
||||||
#
|
#
|
||||||
@@ -440,11 +463,10 @@ my %table=(
|
|||||||
|
|
||||||
|
|
||||||
# IBM's AIX.
|
# IBM's AIX.
|
||||||
"aix-cc", "cc:-O -DB_ENDIAN -qmaxmem=16384::(unknown):AIX::BN_LLONG RC4_CHAR:::",
|
"aix3-cc", "cc:-O -DB_ENDIAN -qmaxmem=16384::(unknown):AIX::BN_LLONG RC4_CHAR:::",
|
||||||
"aix-gcc", "gcc:-O3 -DB_ENDIAN::(unknown):AIX::BN_LLONG RC4_CHAR:::",
|
"aix-gcc", "gcc:-O3 -DB_ENDIAN::-D_THREAD_SAFE:AIX::BN_LLONG RC4_CHAR:asm/aix_ppc32.o:::::::::dlfcn:",
|
||||||
"aix43-cc", "cc:-O -DAIX -DB_ENDIAN -qmaxmem=16384::(unknown):::BN_LLONG RC4_CHAR::::::::::dlfcn:aix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::",
|
"aix-cc", "cc:-q32 -O -DB_ENDIAN -qmaxmem=16384::-qthreaded:AIX::BN_LLONG RC4_CHAR:asm/aix_ppc32.o:::::::::dlfcn:aix-shared::-q32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 32",
|
||||||
"aix43-gcc", "gcc:-O1 -DAIX -DB_ENDIAN::(unknown):::BN_LLONG RC4_CHAR::::::::::dlfcn:",
|
"aix64-cc", "cc:-q64 -O -DB_ENDIAN -qmaxmem=16384::-qthreaded:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:asm/aix_ppc64.o:::::::::dlfcn:aix-shared::-q64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 64",
|
||||||
"aix64-cc", "cc:-O -DAIX -DB_ENDIAN -qmaxmem=16384 -q64::(unknown):::SIXTY_FOUR_BIT_LONG RC4_CHAR::::::::::dlfcn:aix-shared::-q64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 64",
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Cray T90 and similar (SDSC)
|
# Cray T90 and similar (SDSC)
|
||||||
@@ -506,20 +528,18 @@ my %table=(
|
|||||||
"BC-32","bcc32::::WIN32::BN_LLONG DES_PTR RC4_INDEX EXPORT_VAR_AS_FN::::::::::win32",
|
"BC-32","bcc32::::WIN32::BN_LLONG DES_PTR RC4_INDEX EXPORT_VAR_AS_FN::::::::::win32",
|
||||||
"BC-16","bcc:::(unknown):WIN16::BN_LLONG DES_PTR RC4_INDEX SIXTEEN_BIT:::",
|
"BC-16","bcc:::(unknown):WIN16::BN_LLONG DES_PTR RC4_INDEX SIXTEEN_BIT:::",
|
||||||
|
|
||||||
# Mingw32
|
# MinGW
|
||||||
# (Note: the real CFLAGS for Windows builds are defined by util/mk1mf.pl
|
"mingw", "gcc:-DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -mno-cygwin -Wall -D_WIN32_WINNT=0x333:::MINGW32:-lwsock32 -lgdi32:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts} EXPORT_VAR_AS_FN:${x86_out_asm}:win32:cygwin-shared:-D_WINDLL:-mno-cygwin:.dll.a",
|
||||||
# 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}::::::::::win32",
|
|
||||||
|
|
||||||
# UWIN
|
# UWIN
|
||||||
"UWIN", "cc:-DTERMIOS -DL_ENDIAN -O -Wall:::UWIN::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::win32",
|
"UWIN", "cc:-DTERMIOS -DL_ENDIAN -O -Wall:::UWIN::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::win32",
|
||||||
|
|
||||||
# Cygwin
|
# Cygwin
|
||||||
"Cygwin-pre1.3", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown):CYGWIN32::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::win32",
|
"Cygwin-pre1.3", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -m486 -Wall::(unknown):CYGWIN32::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::win32",
|
||||||
"Cygwin", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall:::CYGWIN32::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}:win32:cygwin-shared:::.dll",
|
"Cygwin", "gcc:-DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall:::CYGWIN32::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_out_asm}:dlfcn:cygwin-shared:-D_WINDLL::.dll.a",
|
||||||
|
|
||||||
# DJGPP
|
# DJGPP
|
||||||
"DJGPP", "gcc:-I/dev/env/WATT_ROOT/inc -DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O2 -Wall:::MSDOS:-L/dev/env/WATT_ROOT/lib -lwatt:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::",
|
"DJGPP", "gcc:-I/dev/env/WATT_ROOT/inc -DTERMIOS -DL_ENDIAN -fomit-frame-pointer -O2 -Wall -DDEVRANDOM=\"/dev/urandom\\x24\":::MSDOS:-L/dev/env/WATT_ROOT/lib -lwatt:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}::::::::::",
|
||||||
|
|
||||||
# Ultrix from Bernhard Simon <simon@zid.tuwien.ac.at>
|
# Ultrix from Bernhard Simon <simon@zid.tuwien.ac.at>
|
||||||
"ultrix-cc","cc:-std1 -O -Olimit 2500 -DL_ENDIAN::(unknown):::::::",
|
"ultrix-cc","cc:-std1 -O -Olimit 2500 -DL_ENDIAN::(unknown):::::::",
|
||||||
@@ -542,7 +562,7 @@ my %table=(
|
|||||||
|
|
||||||
##### MacOS X (a.k.a. Rhapsody or Darwin) setup
|
##### MacOS X (a.k.a. Rhapsody or Darwin) setup
|
||||||
"rhapsody-ppc-cc","cc:-O3 -DB_ENDIAN::(unknown):MACOSX_RHAPSODY::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::",
|
"rhapsody-ppc-cc","cc:-O3 -DB_ENDIAN::(unknown):MACOSX_RHAPSODY::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::",
|
||||||
"darwin-ppc-cc","cc:-O3 -fomit-frame-pointer -fno-common -DB_ENDIAN::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::::::::::darwin-shared:-fPIC::.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"darwin-ppc-cc","cc:-O3 -fomit-frame-pointer -DB_ENDIAN::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:asm/osx_ppc32.o:::::::::dlfcn:darwin-shared:-fPIC -fno-common::.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"darwin-i386-cc","cc:-O3 -fomit-frame-pointer -fno-common -DB_ENDIAN::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::::::::::darwin-shared:-fPIC::.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"darwin-i386-cc","cc:-O3 -fomit-frame-pointer -fno-common -DB_ENDIAN::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::::::::::darwin-shared:-fPIC::.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
|
|
||||||
##### A/UX
|
##### A/UX
|
||||||
@@ -561,6 +581,8 @@ my %table=(
|
|||||||
"vxworks-ppc405","ccppc:-g -msoft-float -mlongcall -DCPU=PPC405 -I\$(WIND_BASE)/target/h:::VXWORKS:-r:::::",
|
"vxworks-ppc405","ccppc:-g -msoft-float -mlongcall -DCPU=PPC405 -I\$(WIND_BASE)/target/h:::VXWORKS:-r:::::",
|
||||||
"vxworks-ppc750","ccppc:-ansi -nostdinc -DPPC750 -D_REENTRANT -fvolatile -fno-builtin -fno-for-scope -fsigned-char -Wall -msoft-float -mlongcall -DCPU=PPC604 -I\$(WIND_BASE)/target/h \$(DEBUG_FLAG):::VXWORKS:-r:::::",
|
"vxworks-ppc750","ccppc:-ansi -nostdinc -DPPC750 -D_REENTRANT -fvolatile -fno-builtin -fno-for-scope -fsigned-char -Wall -msoft-float -mlongcall -DCPU=PPC604 -I\$(WIND_BASE)/target/h \$(DEBUG_FLAG):::VXWORKS:-r:::::",
|
||||||
"vxworks-ppc750-debug","ccppc:-ansi -nostdinc -DPPC750 -D_REENTRANT -fvolatile -fno-builtin -fno-for-scope -fsigned-char -Wall -msoft-float -mlongcall -DCPU=PPC604 -I\$(WIND_BASE)/target/h -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DDEBUG -g:::VXWORKS:-r:::::",
|
"vxworks-ppc750-debug","ccppc:-ansi -nostdinc -DPPC750 -D_REENTRANT -fvolatile -fno-builtin -fno-for-scope -fsigned-char -Wall -msoft-float -mlongcall -DCPU=PPC604 -I\$(WIND_BASE)/target/h -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DPEDANTIC -DDEBUG_SAFESTACK -DDEBUG -g:::VXWORKS:-r:::::",
|
||||||
|
"vxworks-ppc860","ccppc:-nostdinc -msoft-float -DCPU=PPC860 -DNO_STRINGS_H -I\$(WIND_BASE)/target/h:::VXWORKS:-r:::::",
|
||||||
|
"vxworks-mipsle","ccmips:-B\$(WIND_BASE)/host/\$(WIND_HOST_TYPE)/lib/gcc-lib/ -DL_ENDIAN -EL -Wl,-EL -mips2 -mno-branch-likely -G 0 -fno-builtin -msoft-float -DCPU=MIPS32 -DMIPSEL -DNO_STRINGS_H -I\$(WIND_BASE)/target/h:::VXWORKS:-r::::::::::::::::ranlibmips:",
|
||||||
|
|
||||||
##### Compaq Non-Stop Kernel (Tandem)
|
##### Compaq Non-Stop Kernel (Tandem)
|
||||||
"tandem-c89","c89:-Ww -D__TANDEM -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1 -D_TANDEM_SOURCE -DB_ENDIAN::(unknown):::THIRTY_TWO_BIT:::",
|
"tandem-c89","c89:-Ww -D__TANDEM -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1 -D_TANDEM_SOURCE -DB_ENDIAN::(unknown):::THIRTY_TWO_BIT:::",
|
||||||
@@ -607,7 +629,7 @@ my $threads=0;
|
|||||||
my $no_asm=0;
|
my $no_asm=0;
|
||||||
my $no_dso=0;
|
my $no_dso=0;
|
||||||
my @skip=();
|
my @skip=();
|
||||||
my $Makefile="Makefile.ssl";
|
my $Makefile="Makefile";
|
||||||
my $des_locl="crypto/des/des_locl.h";
|
my $des_locl="crypto/des/des_locl.h";
|
||||||
my $des ="crypto/des/des.h";
|
my $des ="crypto/des/des.h";
|
||||||
my $bn ="crypto/bn/bn.h";
|
my $bn ="crypto/bn/bn.h";
|
||||||
@@ -619,6 +641,7 @@ my $rc2 ="crypto/rc2/rc2.h";
|
|||||||
my $bf ="crypto/bf/bf_locl.h";
|
my $bf ="crypto/bf/bf_locl.h";
|
||||||
my $bn_asm ="bn_asm.o";
|
my $bn_asm ="bn_asm.o";
|
||||||
my $des_enc="des_enc.o fcrypt_b.o";
|
my $des_enc="des_enc.o fcrypt_b.o";
|
||||||
|
my $fips_des_enc="fips_des_enc.o";
|
||||||
my $bf_enc ="bf_enc.o";
|
my $bf_enc ="bf_enc.o";
|
||||||
my $cast_enc="c_enc.o";
|
my $cast_enc="c_enc.o";
|
||||||
my $rc4_enc="rc4_enc.o";
|
my $rc4_enc="rc4_enc.o";
|
||||||
@@ -629,6 +652,8 @@ my $rmd160_obj="";
|
|||||||
my $processor="";
|
my $processor="";
|
||||||
my $default_ranlib;
|
my $default_ranlib;
|
||||||
my $perl;
|
my $perl;
|
||||||
|
my $fips=0;
|
||||||
|
my $debug=0;
|
||||||
|
|
||||||
my $no_ssl2=0;
|
my $no_ssl2=0;
|
||||||
my $no_ssl3=0;
|
my $no_ssl3=0;
|
||||||
@@ -638,10 +663,6 @@ my $no_sha=0;
|
|||||||
my $no_rsa=0;
|
my $no_rsa=0;
|
||||||
my $no_dh=0;
|
my $no_dh=0;
|
||||||
|
|
||||||
$default_ranlib= &which("ranlib") or $default_ranlib="true";
|
|
||||||
$perl=$ENV{'PERL'} or $perl=&which("perl5") or $perl=&which("perl")
|
|
||||||
or $perl="perl";
|
|
||||||
|
|
||||||
&usage if ($#ARGV < 0);
|
&usage if ($#ARGV < 0);
|
||||||
|
|
||||||
my $flags;
|
my $flags;
|
||||||
@@ -737,6 +758,8 @@ PROCESS_ARGS:
|
|||||||
{ $no_ssl3 = 1; }
|
{ $no_ssl3 = 1; }
|
||||||
elsif (/^no-tls1?$/)
|
elsif (/^no-tls1?$/)
|
||||||
{ $no_tls1 = 1; }
|
{ $no_tls1 = 1; }
|
||||||
|
elsif (/^no-fips$/)
|
||||||
|
{ $fips = 0; }
|
||||||
elsif (/^no-(.+)$/)
|
elsif (/^no-(.+)$/)
|
||||||
{
|
{
|
||||||
my $algo=$1;
|
my $algo=$1;
|
||||||
@@ -802,6 +825,14 @@ PROCESS_ARGS:
|
|||||||
}
|
}
|
||||||
elsif (/^386$/)
|
elsif (/^386$/)
|
||||||
{ $processor=386; }
|
{ $processor=386; }
|
||||||
|
elsif (/^fips$/)
|
||||||
|
{
|
||||||
|
$fips=1;
|
||||||
|
}
|
||||||
|
elsif (/^debug$/)
|
||||||
|
{
|
||||||
|
$debug=1;
|
||||||
|
}
|
||||||
elsif (/^rsaref$/)
|
elsif (/^rsaref$/)
|
||||||
{
|
{
|
||||||
# No RSAref support any more since it's not needed.
|
# No RSAref support any more since it's not needed.
|
||||||
@@ -918,11 +949,15 @@ print "Configuring for $target\n";
|
|||||||
|
|
||||||
my $IsWindows=scalar grep /^$target$/,@WinTargets;
|
my $IsWindows=scalar grep /^$target$/,@WinTargets;
|
||||||
|
|
||||||
$exe_ext=".exe" if ($target eq "Cygwin");
|
$exe_ext=".exe" if ($target eq "Cygwin" || $target eq "DJGPP" || $target eq "mingw");
|
||||||
$exe_ext=".exe" if ($target eq "DJGPP");
|
$exe_ext=".pm" if ($target eq "vos-gcc" or $target eq "debug-vos-gcc" or $target eq "vos-vcc" or $target eq "debug-vos-vcc");
|
||||||
$openssldir="/usr/local/ssl" if ($openssldir eq "" and $prefix eq "");
|
$openssldir="/usr/local/ssl" if ($openssldir eq "" and $prefix eq "");
|
||||||
$prefix=$openssldir if $prefix eq "";
|
$prefix=$openssldir if $prefix eq "";
|
||||||
|
|
||||||
|
$default_ranlib= &which("ranlib") or $default_ranlib="true";
|
||||||
|
$perl=$ENV{'PERL'} or $perl=&which("perl5") or $perl=&which("perl")
|
||||||
|
or $perl="perl";
|
||||||
|
|
||||||
chop $openssldir if $openssldir =~ /\/$/;
|
chop $openssldir if $openssldir =~ /\/$/;
|
||||||
chop $prefix if $prefix =~ /\/$/;
|
chop $prefix if $prefix =~ /\/$/;
|
||||||
|
|
||||||
@@ -933,6 +968,7 @@ $openssldir=$prefix . "/" . $openssldir if $openssldir !~ /(^\/|^[a-zA-Z]:[\\\/]
|
|||||||
print "IsWindows=$IsWindows\n";
|
print "IsWindows=$IsWindows\n";
|
||||||
|
|
||||||
my @fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
my @fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||||
|
for (@fields) { s/%([\dA-Fa-f]{2})/chr(hex($1))/eg; }
|
||||||
my $cc = $fields[$idx_cc];
|
my $cc = $fields[$idx_cc];
|
||||||
my $cflags = $fields[$idx_cflags];
|
my $cflags = $fields[$idx_cflags];
|
||||||
my $unistd = $fields[$idx_unistd];
|
my $unistd = $fields[$idx_unistd];
|
||||||
@@ -991,7 +1027,7 @@ else
|
|||||||
if $withargs{"krb5-dir"} eq "";
|
if $withargs{"krb5-dir"} eq "";
|
||||||
$withargs{"krb5-lib"} = "-L".$withargs{"krb5-dir"}.
|
$withargs{"krb5-lib"} = "-L".$withargs{"krb5-dir"}.
|
||||||
"/lib -lgssapi -lkrb5 -lcom_err"
|
"/lib -lgssapi -lkrb5 -lcom_err"
|
||||||
if $withargs{"krb5-lib"} eq "";
|
if $withargs{"krb5-lib"} eq "" && !$IsWindows;
|
||||||
$cflags="-DKRB5_HEIMDAL $cflags";
|
$cflags="-DKRB5_HEIMDAL $cflags";
|
||||||
}
|
}
|
||||||
if ($withargs{"krb5-flavor"} =~ /^[Mm][Ii][Tt]/)
|
if ($withargs{"krb5-flavor"} =~ /^[Mm][Ii][Tt]/)
|
||||||
@@ -1000,7 +1036,7 @@ else
|
|||||||
if $withargs{"krb5-dir"} eq "";
|
if $withargs{"krb5-dir"} eq "";
|
||||||
$withargs{"krb5-lib"} = "-L".$withargs{"krb5-dir"}.
|
$withargs{"krb5-lib"} = "-L".$withargs{"krb5-dir"}.
|
||||||
"/lib -lgssapi_krb5 -lkrb5 -lcom_err -lk5crypto"
|
"/lib -lgssapi_krb5 -lkrb5 -lcom_err -lk5crypto"
|
||||||
if $withargs{"krb5-lib"} eq "";
|
if $withargs{"krb5-lib"} eq "" && !$IsWindows;
|
||||||
$cflags="-DKRB5_MIT $cflags";
|
$cflags="-DKRB5_MIT $cflags";
|
||||||
$withargs{"krb5-flavor"} =~ s/^[Mm][Ii][Tt][._-]*//;
|
$withargs{"krb5-flavor"} =~ s/^[Mm][Ii][Tt][._-]*//;
|
||||||
if ($withargs{"krb5-flavor"} =~ /^1[._-]*[01]/)
|
if ($withargs{"krb5-flavor"} =~ /^1[._-]*[01]/)
|
||||||
@@ -1019,7 +1055,7 @@ else
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
$withargs{"krb5-lib"} .= " -lresolv"
|
$withargs{"krb5-lib"} .= " -lresolv"
|
||||||
if ("$lresolv" ne "");
|
if ("$lresolv" ne "" && !$IsWindows);
|
||||||
$withargs{"krb5-include"} = "-I".$withargs{"krb5-dir"}."/include"
|
$withargs{"krb5-include"} = "-I".$withargs{"krb5-dir"}."/include"
|
||||||
if $withargs{"krb5-include"} eq "" &&
|
if $withargs{"krb5-include"} eq "" &&
|
||||||
$withargs{"krb5-dir"} ne "";
|
$withargs{"krb5-dir"} ne "";
|
||||||
@@ -1115,7 +1151,7 @@ if (!$no_shared)
|
|||||||
{
|
{
|
||||||
if ($shared_cflag ne "")
|
if ($shared_cflag ne "")
|
||||||
{
|
{
|
||||||
$cflags = "$shared_cflag $cflags";
|
$cflags = "$shared_cflag -DOPENSSL_PIC $cflags";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1137,12 +1173,32 @@ if ($ranlib eq "")
|
|||||||
|
|
||||||
$bn_obj = $bn_asm unless $bn_obj ne "";
|
$bn_obj = $bn_asm unless $bn_obj ne "";
|
||||||
|
|
||||||
|
my $fips_des_obj;
|
||||||
|
my $fips_aes_obj;
|
||||||
|
my $fips_sha1_obj;
|
||||||
|
if ($fips)
|
||||||
|
{
|
||||||
|
if ($des_obj =~ /\-elf\.o$/)
|
||||||
|
{
|
||||||
|
$fips_des_obj='asm/fips-dx86-elf.o';
|
||||||
|
$openssl_other_defines.="#define OPENSSL_FIPS_DES_ASM\n";
|
||||||
|
$fips_aes_obj='asm/fips-ax86-elf.o';
|
||||||
|
$openssl_other_defines.="#define OPENSSL_FIPS_AES_ASM\n";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$fips_des_obj=$fips_des_enc;
|
||||||
|
$fips_aes_obj='fips_aes_core.o';
|
||||||
|
}
|
||||||
|
$fips_sha1_obj='asm/fips-sx86-elf.o' if ($sha1_obj =~ /\-elf\.o$/);
|
||||||
|
$des_obj=$sha1_obj="";
|
||||||
|
$openssl_other_defines.="#define OPENSSL_FIPS\n";
|
||||||
|
}
|
||||||
$des_obj=$des_enc unless ($des_obj =~ /\.o$/);
|
$des_obj=$des_enc unless ($des_obj =~ /\.o$/);
|
||||||
$bf_obj=$bf_enc unless ($bf_obj =~ /\.o$/);
|
$bf_obj=$bf_enc unless ($bf_obj =~ /\.o$/);
|
||||||
$cast_obj=$cast_enc unless ($cast_obj =~ /\.o$/);
|
$cast_obj=$cast_enc unless ($cast_obj =~ /\.o$/);
|
||||||
$rc4_obj=$rc4_enc unless ($rc4_obj =~ /\.o$/);
|
$rc4_obj=$rc4_enc unless ($rc4_obj =~ /\.o$/);
|
||||||
$rc5_obj=$rc5_enc unless ($rc5_obj =~ /\.o$/);
|
$rc5_obj=$rc5_enc unless ($rc5_obj =~ /\.o$/);
|
||||||
if ($sha1_obj =~ /\.o$/)
|
if ($sha1_obj =~ /\.o$/ || $fips_sha1_obj =~ /\.o$/)
|
||||||
{
|
{
|
||||||
# $sha1_obj=$sha1_enc;
|
# $sha1_obj=$sha1_enc;
|
||||||
$cflags.=" -DSHA1_ASM";
|
$cflags.=" -DSHA1_ASM";
|
||||||
@@ -1158,6 +1214,12 @@ if ($rmd160_obj =~ /\.o$/)
|
|||||||
$cflags.=" -DRMD160_ASM";
|
$cflags.=" -DRMD160_ASM";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($debug)
|
||||||
|
{
|
||||||
|
$cflags.=" -g";
|
||||||
|
$cflags=~s/-fomit-frame-pointer//;
|
||||||
|
}
|
||||||
|
|
||||||
# "Stringify" the C flags string. This permits it to be made part of a string
|
# "Stringify" the C flags string. This permits it to be made part of a string
|
||||||
# and works as well on command lines.
|
# and works as well on command lines.
|
||||||
$cflags =~ s/([\\\"])/\\\1/g;
|
$cflags =~ s/([\\\"])/\\\1/g;
|
||||||
@@ -1230,12 +1292,15 @@ while (<IN>)
|
|||||||
s/^EXE_EXT=.*$/EXE_EXT= $exe_ext/;
|
s/^EXE_EXT=.*$/EXE_EXT= $exe_ext/;
|
||||||
s/^BN_ASM=.*$/BN_ASM= $bn_obj/;
|
s/^BN_ASM=.*$/BN_ASM= $bn_obj/;
|
||||||
s/^DES_ENC=.*$/DES_ENC= $des_obj/;
|
s/^DES_ENC=.*$/DES_ENC= $des_obj/;
|
||||||
|
s/^FIPS_DES_ENC=.*$/FIPS_DES_ENC= $fips_des_obj/;
|
||||||
|
s/^FIPS_AES_ENC=.*$/FIPS_AES_ENC= $fips_aes_obj/;
|
||||||
s/^BF_ENC=.*$/BF_ENC= $bf_obj/;
|
s/^BF_ENC=.*$/BF_ENC= $bf_obj/;
|
||||||
s/^CAST_ENC=.*$/CAST_ENC= $cast_obj/;
|
s/^CAST_ENC=.*$/CAST_ENC= $cast_obj/;
|
||||||
s/^RC4_ENC=.*$/RC4_ENC= $rc4_obj/;
|
s/^RC4_ENC=.*$/RC4_ENC= $rc4_obj/;
|
||||||
s/^RC5_ENC=.*$/RC5_ENC= $rc5_obj/;
|
s/^RC5_ENC=.*$/RC5_ENC= $rc5_obj/;
|
||||||
s/^MD5_ASM_OBJ=.*$/MD5_ASM_OBJ= $md5_obj/;
|
s/^MD5_ASM_OBJ=.*$/MD5_ASM_OBJ= $md5_obj/;
|
||||||
s/^SHA1_ASM_OBJ=.*$/SHA1_ASM_OBJ= $sha1_obj/;
|
s/^SHA1_ASM_OBJ=.*$/SHA1_ASM_OBJ= $sha1_obj/;
|
||||||
|
s/^FIPS_SHA1_ASM_OBJ=.*$/FIPS_SHA1_ASM_OBJ= $fips_sha1_obj/;
|
||||||
s/^RMD160_ASM_OBJ=.*$/RMD160_ASM_OBJ= $rmd160_obj/;
|
s/^RMD160_ASM_OBJ=.*$/RMD160_ASM_OBJ= $rmd160_obj/;
|
||||||
s/^PROCESSOR=.*/PROCESSOR= $processor/;
|
s/^PROCESSOR=.*/PROCESSOR= $processor/;
|
||||||
s/^RANLIB=.*/RANLIB= $ranlib/;
|
s/^RANLIB=.*/RANLIB= $ranlib/;
|
||||||
@@ -1468,7 +1533,7 @@ if($IsWindows) {
|
|||||||
printf OUT <<EOF;
|
printf OUT <<EOF;
|
||||||
#ifndef MK1MF_BUILD
|
#ifndef MK1MF_BUILD
|
||||||
/* auto-generated by Configure for crypto/cversion.c:
|
/* auto-generated by Configure for crypto/cversion.c:
|
||||||
* for Unix builds, crypto/Makefile.ssl generates functional definitions;
|
* for Unix builds, crypto/Makefile generates functional definitions;
|
||||||
* Windows builds (and other mk1mf builds) compile cversion.c with
|
* Windows builds (and other mk1mf builds) compile cversion.c with
|
||||||
* -DMK1MF_BUILD and use definitions added to this file by util/mk1mf.pl. */
|
* -DMK1MF_BUILD and use definitions added to this file by util/mk1mf.pl. */
|
||||||
#error "Windows builds (PLATFORM=$target) use mk1mf.pl-created Makefiles"
|
#error "Windows builds (PLATFORM=$target) use mk1mf.pl-created Makefiles"
|
||||||
@@ -1476,7 +1541,7 @@ if($IsWindows) {
|
|||||||
EOF
|
EOF
|
||||||
close(OUT);
|
close(OUT);
|
||||||
} else {
|
} else {
|
||||||
my $make_command = "make -f Makefile.ssl PERL=\'$perl\'";
|
my $make_command = "make PERL=\'$perl\'";
|
||||||
my $make_targets = "";
|
my $make_targets = "";
|
||||||
$make_targets .= " links" if $symlink;
|
$make_targets .= " links" if $symlink;
|
||||||
$make_targets .= " depend" if $depflags ne "" && $make_depend;
|
$make_targets .= " depend" if $depflags ne "" && $make_depend;
|
||||||
@@ -1485,12 +1550,10 @@ EOF
|
|||||||
if $make_targets ne "";
|
if $make_targets ne "";
|
||||||
if ( $perl =~ m@^/@) {
|
if ( $perl =~ m@^/@) {
|
||||||
&dofile("tools/c_rehash",$perl,'^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";');
|
&dofile("tools/c_rehash",$perl,'^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";');
|
||||||
&dofile("apps/der_chop",$perl,'^#!/', '#!%s');
|
|
||||||
&dofile("apps/CA.pl",$perl,'^#!/', '#!%s');
|
&dofile("apps/CA.pl",$perl,'^#!/', '#!%s');
|
||||||
} else {
|
} else {
|
||||||
# No path for Perl known ...
|
# No path for Perl known ...
|
||||||
&dofile("tools/c_rehash",'/usr/local/bin/perl','^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";');
|
&dofile("tools/c_rehash",'/usr/local/bin/perl','^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";');
|
||||||
&dofile("apps/der_chop",'/usr/local/bin/perl','^#!/', '#!%s');
|
|
||||||
&dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s');
|
&dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s');
|
||||||
}
|
}
|
||||||
if ($depflags ne "" && !$make_depend) {
|
if ($depflags ne "" && !$make_depend) {
|
||||||
@@ -1567,10 +1630,10 @@ sub which
|
|||||||
my $path;
|
my $path;
|
||||||
foreach $path (split /:/, $ENV{PATH})
|
foreach $path (split /:/, $ENV{PATH})
|
||||||
{
|
{
|
||||||
if (-f "$path/$name" and -x _)
|
if (-f "$path/$name$exe_ext" and -x _)
|
||||||
{
|
{
|
||||||
return "$path/$name" unless ($name eq "perl" and
|
return "$path/$name$exe_ext" unless ($name eq "perl" and
|
||||||
system("$path/$name -e " . '\'exit($]<5.0);\''));
|
system("$path/$name$exe_ext -e " . '\'exit($]<5.0);\''));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1598,12 +1661,13 @@ sub print_table_entry
|
|||||||
{
|
{
|
||||||
my $target = shift;
|
my $target = shift;
|
||||||
|
|
||||||
|
my @fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||||
|
for (@fields) { s/%([\dA-Fa-f]{2})/chr(hex($1))/eg; }
|
||||||
(my $cc,my $cflags,my $unistd,my $thread_cflag,my $sys_id,my $lflags,
|
(my $cc,my $cflags,my $unistd,my $thread_cflag,my $sys_id,my $lflags,
|
||||||
my $bn_ops,my $bn_obj,my $des_obj,my $bf_obj,
|
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 $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,
|
my $rc5_obj,my $dso_scheme,my $shared_target,my $shared_cflag,
|
||||||
my $shared_ldflag,my $shared_extension,my $ranlib,my $arflags)=
|
my $shared_ldflag,my $shared_extension,my $ranlib,my $arflags)=@fields;
|
||||||
split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
|
||||||
|
|
||||||
print <<EOF
|
print <<EOF
|
||||||
|
|
||||||
@@ -1646,6 +1710,7 @@ sub test_sanity
|
|||||||
foreach $target (sort keys %table)
|
foreach $target (sort keys %table)
|
||||||
{
|
{
|
||||||
@fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
@fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||||
|
for (@fields) { s/%([\dA-Fa-f]{2})/chr(hex($1))/eg; }
|
||||||
|
|
||||||
if ($fields[$idx_dso_scheme-1] =~ /^(dl|dlfcn|win32|vms)$/)
|
if ($fields[$idx_dso_scheme-1] =~ /^(dl|dlfcn|win32|vms)$/)
|
||||||
{
|
{
|
||||||
|
|||||||
53
FAQ
53
FAQ
@@ -52,6 +52,7 @@ OpenSSL - Frequently Asked Questions
|
|||||||
* Is OpenSSL thread-safe?
|
* Is OpenSSL thread-safe?
|
||||||
* I've compiled a program under Windows and it crashes: why?
|
* 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?
|
* How do I read or write a DER encoded buffer using the ASN1 functions?
|
||||||
|
* OpenSSL uses DER but I need BER format: does OpenSSL support BER?
|
||||||
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
||||||
* I've called <some function> and it fails, 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?
|
* I just get a load of numbers for the error output, what do they mean?
|
||||||
@@ -60,6 +61,7 @@ OpenSSL - Frequently Asked Questions
|
|||||||
* Can I use OpenSSL's SSL library with non-blocking I/O?
|
* Can I use OpenSSL's SSL library with non-blocking I/O?
|
||||||
* Why doesn't my server application receive a client certificate?
|
* Why doesn't my server application receive a client certificate?
|
||||||
* Why does compilation fail due to an undefined symbol NID_uniqueIdentifier?
|
* Why does compilation fail due to an undefined symbol NID_uniqueIdentifier?
|
||||||
|
* I think I've detected a memory leak, is this a bug?
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
|
|
||||||
@@ -68,7 +70,7 @@ OpenSSL - Frequently Asked Questions
|
|||||||
* Which is the current version of OpenSSL?
|
* Which is the current version of OpenSSL?
|
||||||
|
|
||||||
The current version is available from <URL: http://www.openssl.org>.
|
The current version is available from <URL: http://www.openssl.org>.
|
||||||
OpenSSL 0.9.7a was released on February 19, 2003.
|
OpenSSL 0.9.7g was released on April 11, 2005.
|
||||||
|
|
||||||
In addition to the current stable release, you can also access daily
|
In addition to the current stable release, you can also access daily
|
||||||
snapshots of the OpenSSL development version at <URL:
|
snapshots of the OpenSSL development version at <URL:
|
||||||
@@ -116,11 +118,14 @@ OpenSSL. Information on the OpenSSL mailing lists is available from
|
|||||||
|
|
||||||
* Where can I get a compiled version of OpenSSL?
|
* Where can I get a compiled version of OpenSSL?
|
||||||
|
|
||||||
|
You can finder pointers to binary distributions in
|
||||||
|
http://www.openssl.org/related/binaries.html .
|
||||||
|
|
||||||
Some applications that use OpenSSL are distributed in binary form.
|
Some applications that use OpenSSL are distributed in binary form.
|
||||||
When using such an application, you don't need to install OpenSSL
|
When using such an application, you don't need to install OpenSSL
|
||||||
yourself; the application will include the required parts (e.g. DLLs).
|
yourself; the application will include the required parts (e.g. DLLs).
|
||||||
|
|
||||||
If you want to install OpenSSL on a Windows system and you don't have
|
If you want to build OpenSSL on a Windows system and you don't have
|
||||||
a C compiler, read the "Mingw32" section of INSTALL.W32 for information
|
a C compiler, read the "Mingw32" section of INSTALL.W32 for information
|
||||||
on how to obtain and install the free GNU C compiler.
|
on how to obtain and install the free GNU C compiler.
|
||||||
|
|
||||||
@@ -457,7 +462,7 @@ get the best result from OpenSSL. A bit more complicated solution is the
|
|||||||
following:
|
following:
|
||||||
|
|
||||||
----- snip:start -----
|
----- snip:start -----
|
||||||
make DIRS=crypto SDIRS=sha "`grep '^CFLAG=' Makefile.ssl | \
|
make DIRS=crypto SDIRS=sha "`grep '^CFLAG=' Makefile | \
|
||||||
sed -e 's/ -O[0-9] / -O0 /'`"
|
sed -e 's/ -O[0-9] / -O0 /'`"
|
||||||
rm `ls crypto/*.o crypto/sha/*.o | grep -v 'sha_dgst\.o'`
|
rm `ls crypto/*.o crypto/sha/*.o | grep -v 'sha_dgst\.o'`
|
||||||
make
|
make
|
||||||
@@ -467,6 +472,10 @@ This will only compile sha_dgst.c with -O0, the rest with the optimization
|
|||||||
level chosen by the configuration process. When the above is done, do the
|
level chosen by the configuration process. When the above is done, do the
|
||||||
test and installation and you're set.
|
test and installation and you're set.
|
||||||
|
|
||||||
|
3. Reconfigure the toolkit with no-sha0 option to leave out SHA0. It
|
||||||
|
should not be used and is not used in SSL/TLS nor any other recognized
|
||||||
|
protocol in either case.
|
||||||
|
|
||||||
|
|
||||||
* Why does the OpenSSL compilation fail with "ar: command not found"?
|
* Why does the OpenSSL compilation fail with "ar: command not found"?
|
||||||
|
|
||||||
@@ -680,6 +689,20 @@ and attempts to free the buffer will have unpredictable results
|
|||||||
because it no longer points to the same address.
|
because it no longer points to the same address.
|
||||||
|
|
||||||
|
|
||||||
|
* OpenSSL uses DER but I need BER format: does OpenSSL support BER?
|
||||||
|
|
||||||
|
The short answer is yes, because DER is a special case of BER and OpenSSL
|
||||||
|
ASN1 decoders can process BER.
|
||||||
|
|
||||||
|
The longer answer is that ASN1 structures can be encoded in a number of
|
||||||
|
different ways. One set of ways is the Basic Encoding Rules (BER) with various
|
||||||
|
permissible encodings. A restriction of BER is the Distinguished Encoding
|
||||||
|
Rules (DER): these uniquely specify how a given structure is encoded.
|
||||||
|
|
||||||
|
Therefore, because DER is a special case of BER, DER is an acceptable encoding
|
||||||
|
for BER.
|
||||||
|
|
||||||
|
|
||||||
* I've tried using <M_some_evil_pkcs12_macro> and I get errors why?
|
* 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
|
This usually happens when you try compiling something using the PKCS#12
|
||||||
@@ -732,6 +755,7 @@ The general answer is to check the config.log file generated when running
|
|||||||
the OpenSSH configure script. It should contain the detailed information
|
the OpenSSH configure script. It should contain the detailed information
|
||||||
on why the OpenSSL library was not detected or considered incompatible.
|
on why the OpenSSL library was not detected or considered incompatible.
|
||||||
|
|
||||||
|
|
||||||
* Can I use OpenSSL's SSL library with non-blocking I/O?
|
* Can I use OpenSSL's SSL library with non-blocking I/O?
|
||||||
|
|
||||||
Yes; make sure to read the SSL_get_error(3) manual page!
|
Yes; make sure to read the SSL_get_error(3) manual page!
|
||||||
@@ -761,5 +785,28 @@ The correct name according to RFC2256 (LDAP) is x500UniqueIdentifier.
|
|||||||
Change your code to use the new name when compiling against OpenSSL 0.9.7.
|
Change your code to use the new name when compiling against OpenSSL 0.9.7.
|
||||||
|
|
||||||
|
|
||||||
|
* I think I've detected a memory leak, is this a bug?
|
||||||
|
|
||||||
|
In most cases the cause of an apparent memory leak is an OpenSSL internal table
|
||||||
|
that is allocated when an application starts up. Since such tables do not grow
|
||||||
|
in size over time they are harmless.
|
||||||
|
|
||||||
|
These internal tables can be freed up when an application closes using various
|
||||||
|
functions. Currently these include following:
|
||||||
|
|
||||||
|
Thread-local cleanup functions:
|
||||||
|
|
||||||
|
ERR_remove_state()
|
||||||
|
|
||||||
|
Application-global cleanup functions that are aware of usage (and therefore
|
||||||
|
thread-safe):
|
||||||
|
|
||||||
|
ENGINE_cleanup() and CONF_modules_unload()
|
||||||
|
|
||||||
|
"Brutal" (thread-unsafe) Application-global cleanup functions:
|
||||||
|
|
||||||
|
ERR_free_strings(), EVP_cleanup() and CRYPTO_cleanup_all_ex_data().
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
|
|
||||||
|
|||||||
4
INSTALL
4
INSTALL
@@ -123,7 +123,7 @@
|
|||||||
generic configurations "cc" or "gcc" should usually work on 32 bit
|
generic configurations "cc" or "gcc" should usually work on 32 bit
|
||||||
systems.
|
systems.
|
||||||
|
|
||||||
Configure creates the file Makefile.ssl from Makefile.org and
|
Configure creates the file Makefile from Makefile.org and
|
||||||
defines various macros in crypto/opensslconf.h (generated from
|
defines various macros in crypto/opensslconf.h (generated from
|
||||||
crypto/opensslconf.h.in).
|
crypto/opensslconf.h.in).
|
||||||
|
|
||||||
@@ -159,7 +159,7 @@
|
|||||||
the failure that isn't a problem in OpenSSL itself (like a missing
|
the failure that isn't a problem in OpenSSL itself (like a missing
|
||||||
or malfunctioning bc). If it is a problem with OpenSSL itself,
|
or malfunctioning bc). If it is a problem with OpenSSL itself,
|
||||||
try removing any compiler optimization flags from the CFLAG line
|
try removing any compiler optimization flags from the CFLAG line
|
||||||
in Makefile.ssl and run "make clean; make". Please send a bug
|
in Makefile and run "make clean; make". Please send a bug
|
||||||
report to <openssl-bugs@openssl.org>, including the output of
|
report to <openssl-bugs@openssl.org>, including the output of
|
||||||
"make report" in order to be added to the request tracker at
|
"make report" in order to be added to the request tracker at
|
||||||
http://www.openssl.org/support/rt2.html.
|
http://www.openssl.org/support/rt2.html.
|
||||||
|
|||||||
@@ -3,32 +3,45 @@
|
|||||||
INSTALLATION ON THE DOS PLATFORM WITH DJGPP
|
INSTALLATION ON THE DOS PLATFORM WITH DJGPP
|
||||||
-------------------------------------------
|
-------------------------------------------
|
||||||
|
|
||||||
Openssl has been ported to DOS, but only with long filename support. If
|
OpenSSL has been ported to DJGPP, a Unix look-alike 32-bit run-time
|
||||||
you wish to compile on native DOS with 8+3 filenames, you will have to
|
environment for 16-bit DOS, but only with long filename support.
|
||||||
tweak the installation yourself, including renaming files with illegal
|
If you wish to compile on native DOS with 8+3 filenames, you will
|
||||||
or duplicate names.
|
have to tweak the installation yourself, including renaming files
|
||||||
|
with illegal or duplicate names.
|
||||||
|
|
||||||
You should have a full DJGPP environment installed, including the
|
You should have a full DJGPP environment installed, including the
|
||||||
latest versions of DJGPP, GCC, BINUTILS, BASH, etc. This package
|
latest versions of DJGPP, GCC, BINUTILS, BASH, etc. This package
|
||||||
requires that PERL and BC also be installed.
|
requires that PERL and BC also be installed.
|
||||||
|
|
||||||
All of these can be obtained from the usual DJGPP mirror sites, such
|
All of these can be obtained from the usual DJGPP mirror sites or
|
||||||
as "ftp://ftp.simtel.net/pub/simtelnet/gnu/djgpp". You also need to
|
directly at "http://www.delorie.com/pub/djgpp". For help on which
|
||||||
have the WATT-32 networking package installed before you try to compile
|
files to download, see the DJGPP "ZIP PICKER" page at
|
||||||
openssl. This can be obtained from "http://www.bgnett.no/~giva/".
|
"http://www.delorie.com/djgpp/zip-picker.html". You also need to have
|
||||||
|
the WATT-32 networking package installed before you try to compile
|
||||||
|
OpenSSL. This can be obtained from "http://www.bgnett.no/~giva/".
|
||||||
The Makefile assumes that the WATT-32 code is in the directory
|
The Makefile assumes that the WATT-32 code is in the directory
|
||||||
specified by the environment variable WATT_ROOT. If you have watt-32
|
specified by the environment variable WATT_ROOT. If you have watt-32
|
||||||
in directory "watt32" under your main DJGPP directory, specify
|
in directory "watt32" under your main DJGPP directory, specify
|
||||||
WATT_ROOT="/dev/env/DJDIR/watt32".
|
WATT_ROOT="/dev/env/DJDIR/watt32".
|
||||||
|
|
||||||
To compile openssl, start your BASH shell. Then configure for DOS by
|
To compile OpenSSL, start your BASH shell, then configure for DJGPP by
|
||||||
running "./Configure" with appropriate arguments. The basic syntax for
|
running "./Configure" with appropriate arguments:
|
||||||
DOS is:
|
|
||||||
./Configure no-threads --prefix=/dev/env/DJDIR DJGPP
|
|
||||||
|
|
||||||
You may run out of DPMI selectors when running in a DOS box under
|
./Configure no-threads --prefix=/dev/env/DJDIR DJGPP
|
||||||
Windows. If so, just close the BASH shell, go back to Windows, and
|
|
||||||
restart BASH. Then run "make" again.
|
|
||||||
|
|
||||||
Building openssl under DJGPP has been tested with DJGPP 2.03,
|
And finally fire up "make". You may run out of DPMI selectors when
|
||||||
GCC 2.952, GCC 2.953, perl 5.005_02 and perl 5.006_01.
|
running in a DOS box under Windows. If so, just close the BASH
|
||||||
|
shell, go back to Windows, and restart BASH. Then run "make" again.
|
||||||
|
|
||||||
|
RUN-TIME CAVEAT LECTOR
|
||||||
|
--------------
|
||||||
|
|
||||||
|
Quoting FAQ:
|
||||||
|
|
||||||
|
"Cryptographic software needs a source of unpredictable data to work
|
||||||
|
correctly. Many open source operating systems provide a "randomness
|
||||||
|
device" (/dev/urandom or /dev/random) that serves this purpose."
|
||||||
|
|
||||||
|
As of version 0.9.7f DJGPP port checks upon /dev/urandom$ for a 3rd
|
||||||
|
party "randomness" DOS driver. One such driver, NOISE.SYS, can be
|
||||||
|
obtained from "http://www.rahul.net/dkaufman/index.html".
|
||||||
|
|||||||
127
INSTALL.W32
127
INSTALL.W32
@@ -10,13 +10,20 @@
|
|||||||
|
|
||||||
You need Perl for Win32. Unless you will build on Cygwin, you will need
|
You need Perl for Win32. Unless you will build on Cygwin, you will need
|
||||||
ActiveState Perl, available from http://www.activestate.com/ActivePerl.
|
ActiveState Perl, available from http://www.activestate.com/ActivePerl.
|
||||||
For Cygwin users, there's more info in the Cygwin section.
|
|
||||||
|
|
||||||
and one of the following C compilers:
|
and one of the following C compilers:
|
||||||
|
|
||||||
* Visual C++
|
* Visual C++
|
||||||
* Borland C
|
* Borland C
|
||||||
* GNU C (Mingw32 or Cygwin)
|
* GNU C (Cygwin or MinGW)
|
||||||
|
|
||||||
|
If you are compiling from a tarball or a CVS snapshot then the Win32 files
|
||||||
|
may well be not up to date. This may mean that some "tweaking" is required to
|
||||||
|
get it all to work. See the trouble shooting section later on for if (when?)
|
||||||
|
it goes wrong.
|
||||||
|
|
||||||
|
Visual C++
|
||||||
|
----------
|
||||||
|
|
||||||
If you want to compile in the assembly language routines with Visual C++ then
|
If you want to compile in the assembly language routines with Visual C++ then
|
||||||
you will need an assembler. This is worth doing because it will result in
|
you will need an assembler. This is worth doing because it will result in
|
||||||
@@ -39,20 +46,13 @@
|
|||||||
http://www.kernel.org/pub/software/devel/nasm/binaries/win32/
|
http://www.kernel.org/pub/software/devel/nasm/binaries/win32/
|
||||||
The NASM binary nasmw.exe needs to be installed anywhere on your PATH.
|
The NASM binary nasmw.exe needs to be installed anywhere on your PATH.
|
||||||
|
|
||||||
If you are compiling from a tarball or a CVS snapshot then the Win32 files
|
Firstly you should run Configure (to build a FIPS-certified variant of
|
||||||
may well be not up to date. This may mean that some "tweaking" is required to
|
OpenSSL, add the option "fips"):
|
||||||
get it all to work. See the trouble shooting section later on for if (when?)
|
|
||||||
it goes wrong.
|
|
||||||
|
|
||||||
Visual C++
|
|
||||||
----------
|
|
||||||
|
|
||||||
Firstly you should run Configure:
|
|
||||||
|
|
||||||
> perl Configure VC-WIN32
|
> perl Configure VC-WIN32
|
||||||
|
|
||||||
Next you need to build the Makefiles and optionally the assembly language
|
Next you need to build the Makefiles and optionally the assembly language
|
||||||
files:
|
files (to build a FIPS-certified variant of OpenSSL, add the argument "fips"):
|
||||||
|
|
||||||
- If you are using MASM then run:
|
- If you are using MASM then run:
|
||||||
|
|
||||||
@@ -101,10 +101,12 @@
|
|||||||
Borland C++ builder 5
|
Borland C++ builder 5
|
||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
* Configure for building with Borland Builder:
|
* Configure for building with Borland Builder (to build a FIPS-certified
|
||||||
|
variant of OpenSSL, add the option "fips"):
|
||||||
> perl Configure BC-32
|
> perl Configure BC-32
|
||||||
|
|
||||||
* Create the appropriate makefile
|
* Create the appropriate makefile (to build a FIPS-certified variant of
|
||||||
|
OpenSSL, add the argument "fips")
|
||||||
> ms\do_nasm
|
> ms\do_nasm
|
||||||
|
|
||||||
* Build
|
* Build
|
||||||
@@ -120,62 +122,35 @@
|
|||||||
* Run make:
|
* Run make:
|
||||||
> make -f bcb.mak
|
> make -f bcb.mak
|
||||||
|
|
||||||
GNU C (Mingw32)
|
|
||||||
---------------
|
|
||||||
|
|
||||||
To build OpenSSL, you need the Mingw32 package and GNU make.
|
|
||||||
|
|
||||||
* Compiler installation:
|
|
||||||
|
|
||||||
Mingw32 is available from <ftp://ftp.xraylith.wisc.edu/pub/khan/
|
|
||||||
gnu-win32/mingw32/gcc-2.95.2/gcc-2.95.2-msvcrt.exe>. Extract it
|
|
||||||
to a directory such as C:\gcc-2.95.2 and add c:\gcc-2.95.2\bin to
|
|
||||||
the PATH environment variable in "System Properties"; or edit and
|
|
||||||
run C:\gcc-2.95.2\mingw32.bat to set the PATH.
|
|
||||||
|
|
||||||
* Compile OpenSSL:
|
|
||||||
|
|
||||||
> ms\mingw32
|
|
||||||
|
|
||||||
This will create the library and binaries in out. In case any problems
|
|
||||||
occur, try
|
|
||||||
> ms\mingw32 no-asm
|
|
||||||
instead.
|
|
||||||
|
|
||||||
libcrypto.a and libssl.a are the static libraries. To use the DLLs,
|
|
||||||
link with libeay32.a and libssl32.a instead.
|
|
||||||
|
|
||||||
See troubleshooting if you get error messages about functions not having
|
|
||||||
a number assigned.
|
|
||||||
|
|
||||||
* You can now try the tests:
|
|
||||||
|
|
||||||
> cd out
|
|
||||||
> ..\ms\test
|
|
||||||
|
|
||||||
GNU C (Cygwin)
|
GNU C (Cygwin)
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
Cygwin provides a bash shell and GNU tools environment running
|
Cygwin provides a bash shell and GNU tools environment running
|
||||||
on NT 4.0, Windows 9x, Windows ME, Windows 2000, and Windows XP.
|
on NT 4.0, Windows 9x, Windows ME, Windows 2000, and Windows XP.
|
||||||
Consequently, a make of OpenSSL with Cygwin is closer to a GNU
|
Consequently, a make of OpenSSL with Cygwin is closer to a GNU
|
||||||
bash environment such as Linux than to other W32 makes which are
|
bash environment such as Linux than to other the other Win32
|
||||||
based on a single makefile approach. Cygwin implements Posix/Unix
|
makes.
|
||||||
calls through cygwin1.dll, and is contrasted to Mingw32 which links
|
|
||||||
dynamically to msvcrt.dll or crtdll.dll.
|
Cygwin implements a Posix/Unix runtime system (cygwin1.dll).
|
||||||
|
It is also possible to create Win32 binaries that only use the
|
||||||
|
Microsoft C runtime system (msvcrt.dll or crtdll.dll) using
|
||||||
|
MinGW. MinGW can be used in the Cygwin development environment
|
||||||
|
or in a standalone setup as described in the following section.
|
||||||
|
|
||||||
To build OpenSSL using Cygwin:
|
To build OpenSSL using Cygwin:
|
||||||
|
|
||||||
* Install Cygwin (see http://cygwin.com/)
|
* Install Cygwin (see http://cygwin.com/)
|
||||||
|
|
||||||
* Install Perl and ensure it is in the path (recent Cygwin perl
|
* Install Perl and ensure it is in the path. Both Cygwin perl
|
||||||
(version 5.6.1-2 of the latter has been reported to work) or
|
(5.6.1-2 or newer) and ActivePerl work.
|
||||||
ActivePerl)
|
|
||||||
|
|
||||||
* Run the Cygwin bash shell
|
* Run the Cygwin bash shell
|
||||||
|
|
||||||
* $ tar zxvf openssl-x.x.x.tar.gz
|
* $ tar zxvf openssl-x.x.x.tar.gz
|
||||||
$ cd openssl-x.x.x
|
$ cd openssl-x.x.x
|
||||||
|
|
||||||
|
To build the Cygwin version of OpenSSL:
|
||||||
|
|
||||||
$ ./config
|
$ ./config
|
||||||
[...]
|
[...]
|
||||||
$ make
|
$ make
|
||||||
@@ -183,7 +158,16 @@
|
|||||||
$ make test
|
$ make test
|
||||||
$ make install
|
$ make install
|
||||||
|
|
||||||
This will create a default install in /usr/local/ssl.
|
This will create a default install in /usr/local/ssl.
|
||||||
|
|
||||||
|
To build the MinGW version (native Windows) in Cygwin:
|
||||||
|
|
||||||
|
$ ./Configure mingw
|
||||||
|
[...]
|
||||||
|
$ make
|
||||||
|
[...]
|
||||||
|
$ make test
|
||||||
|
$ make install
|
||||||
|
|
||||||
Cygwin Notes:
|
Cygwin Notes:
|
||||||
|
|
||||||
@@ -196,6 +180,37 @@
|
|||||||
non-fatal error in "make test" but is otherwise harmless. If
|
non-fatal error in "make test" but is otherwise harmless. If
|
||||||
desired and needed, GNU bc can be built with Cygwin without change.
|
desired and needed, GNU bc can be built with Cygwin without change.
|
||||||
|
|
||||||
|
GNU C (MinGW)
|
||||||
|
-------------
|
||||||
|
|
||||||
|
* Compiler installation:
|
||||||
|
|
||||||
|
MinGW is available from http://www.mingw.org. Run the installer and
|
||||||
|
set the MinGW bin directory to the PATH in "System Properties" or
|
||||||
|
autoexec.bat.
|
||||||
|
|
||||||
|
* Compile OpenSSL:
|
||||||
|
|
||||||
|
> ms\mingw32
|
||||||
|
|
||||||
|
This will create the library and binaries in out. In case any problems
|
||||||
|
occur, try
|
||||||
|
> ms\mingw32 no-asm
|
||||||
|
instead.
|
||||||
|
If you want to build a FIPS-certified variant of OpenSSL, add the argument
|
||||||
|
"fips"
|
||||||
|
|
||||||
|
libcrypto.a and libssl.a are the static libraries. To use the DLLs,
|
||||||
|
link with libeay32.a and libssl32.a instead.
|
||||||
|
|
||||||
|
See troubleshooting if you get error messages about functions not having
|
||||||
|
a number assigned.
|
||||||
|
|
||||||
|
* You can now try the tests:
|
||||||
|
|
||||||
|
> cd out
|
||||||
|
> ..\ms\test
|
||||||
|
|
||||||
|
|
||||||
Installation
|
Installation
|
||||||
------------
|
------------
|
||||||
@@ -215,7 +230,7 @@
|
|||||||
$ md c:\openssl\lib
|
$ md c:\openssl\lib
|
||||||
$ md c:\openssl\include
|
$ md c:\openssl\include
|
||||||
$ md c:\openssl\include\openssl
|
$ md c:\openssl\include\openssl
|
||||||
$ copy /b inc32\* c:\openssl\include\openssl
|
$ copy /b inc32\openssl\* c:\openssl\include\openssl
|
||||||
$ copy /b out32dll\ssleay32.lib c:\openssl\lib
|
$ copy /b out32dll\ssleay32.lib c:\openssl\lib
|
||||||
$ copy /b out32dll\libeay32.lib c:\openssl\lib
|
$ copy /b out32dll\libeay32.lib c:\openssl\lib
|
||||||
$ copy /b out32dll\ssleay32.dll c:\openssl\bin
|
$ copy /b out32dll\ssleay32.dll c:\openssl\bin
|
||||||
|
|||||||
2
LICENSE
2
LICENSE
@@ -12,7 +12,7 @@
|
|||||||
---------------
|
---------------
|
||||||
|
|
||||||
/* ====================================================================
|
/* ====================================================================
|
||||||
* Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved.
|
* Copyright (c) 1998-2005 The OpenSSL Project. All rights reserved.
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
* modification, are permitted provided that the following conditions
|
* modification, are permitted provided that the following conditions
|
||||||
|
|||||||
235
Makefile.org
235
Makefile.org
@@ -78,7 +78,7 @@ MAKEDEPPROG=makedepend
|
|||||||
# gcc, then the driver will automatically translate it to -xarch=v8plus
|
# gcc, then the driver will automatically translate it to -xarch=v8plus
|
||||||
# and pass it down to assembler.
|
# and pass it down to assembler.
|
||||||
AS=$(CC) -c
|
AS=$(CC) -c
|
||||||
ASFLAGS=$(CFLAG)
|
ASFLAG=$(CFLAG)
|
||||||
|
|
||||||
# Set BN_ASM to bn_asm.o if you want to use the C version
|
# Set BN_ASM to bn_asm.o if you want to use the C version
|
||||||
BN_ASM= bn_asm.o
|
BN_ASM= bn_asm.o
|
||||||
@@ -101,6 +101,8 @@ PROCESSOR=
|
|||||||
|
|
||||||
# Set DES_ENC to des_enc.o if you want to use the C version
|
# Set DES_ENC to des_enc.o if you want to use the C version
|
||||||
#There are 4 x86 assember options.
|
#There are 4 x86 assember options.
|
||||||
|
FIPS_DES_ENC= des_enc.o fcrypt_b.o
|
||||||
|
FIPS_AES_ENC= fips_aes_core.o
|
||||||
DES_ENC= asm/dx86-out.o asm/yx86-out.o
|
DES_ENC= asm/dx86-out.o asm/yx86-out.o
|
||||||
#DES_ENC= des_enc.o fcrypt_b.o # C
|
#DES_ENC= des_enc.o fcrypt_b.o # C
|
||||||
#DES_ENC= asm/dx86-elf.o asm/yx86-elf.o # elf
|
#DES_ENC= asm/dx86-elf.o asm/yx86-elf.o # elf
|
||||||
@@ -153,6 +155,7 @@ MD5_ASM_OBJ= asm/mx86-out.o
|
|||||||
|
|
||||||
# Also need SHA1_ASM defined
|
# Also need SHA1_ASM defined
|
||||||
SHA1_ASM_OBJ= asm/sx86-out.o
|
SHA1_ASM_OBJ= asm/sx86-out.o
|
||||||
|
FIPS_SHA1_ASM_OBJ= asm/sx86-out.o
|
||||||
#SHA1_ASM_OBJ= asm/sx86-elf.o # elf
|
#SHA1_ASM_OBJ= asm/sx86-elf.o # elf
|
||||||
#SHA1_ASM_OBJ= asm/sx86-sol.o # solaris
|
#SHA1_ASM_OBJ= asm/sx86-sol.o # solaris
|
||||||
#SHA1_ASM_OBJ= asm/sx86-out.o # a.out, FreeBSD
|
#SHA1_ASM_OBJ= asm/sx86-out.o # a.out, FreeBSD
|
||||||
@@ -173,27 +176,29 @@ LIBKRB5=
|
|||||||
# we might set SHLIB_MARK to '$(SHARED_LIBS)'.
|
# we might set SHLIB_MARK to '$(SHARED_LIBS)'.
|
||||||
SHLIB_MARK=
|
SHLIB_MARK=
|
||||||
|
|
||||||
DIRS= crypto ssl $(SHLIB_MARK) apps test tools
|
DIRS= crypto fips ssl $(SHLIB_MARK) sigs apps test tools
|
||||||
SHLIBDIRS= crypto ssl
|
SHLIBDIRS= crypto ssl
|
||||||
|
|
||||||
# dirs in crypto to build
|
# dirs in crypto to build
|
||||||
SDIRS= \
|
SDIRS= objects \
|
||||||
md2 md4 md5 sha mdc2 hmac ripemd \
|
md2 md4 md5 sha mdc2 hmac ripemd \
|
||||||
des rc2 rc4 rc5 idea bf cast \
|
des rc2 rc4 rc5 idea bf cast \
|
||||||
bn ec rsa dsa dh dso engine aes \
|
bn ec rsa dsa dh dso engine aes \
|
||||||
buffer bio stack lhash rand err objects \
|
buffer bio stack lhash rand err \
|
||||||
evp asn1 pem x509 x509v3 conf txt_db pkcs7 pkcs12 comp ocsp ui krb5
|
evp asn1 pem x509 x509v3 conf txt_db pkcs7 pkcs12 comp ocsp ui krb5
|
||||||
|
|
||||||
|
FDIRS= sha rand des aes dsa rsa dh hmac
|
||||||
|
|
||||||
# tests to perform. "alltests" is a special word indicating that all tests
|
# tests to perform. "alltests" is a special word indicating that all tests
|
||||||
# should be performed.
|
# should be performed.
|
||||||
TESTS = alltests
|
TESTS = alltests
|
||||||
|
|
||||||
MAKEFILE= Makefile.ssl
|
MAKEFILE= Makefile
|
||||||
MAKE= make -f Makefile.ssl
|
|
||||||
|
|
||||||
MANDIR=$(OPENSSLDIR)/man
|
MANDIR=$(OPENSSLDIR)/man
|
||||||
MAN1=1
|
MAN1=1
|
||||||
MAN3=3
|
MAN3=3
|
||||||
|
MANSUFFIX=
|
||||||
SHELL=/bin/sh
|
SHELL=/bin/sh
|
||||||
|
|
||||||
TOP= .
|
TOP= .
|
||||||
@@ -201,6 +206,7 @@ ONEDIRS=out tmp
|
|||||||
EDIRS= times doc bugs util include certs ms shlib mt demos perl sf dep VMS
|
EDIRS= times doc bugs util include certs ms shlib mt demos perl sf dep VMS
|
||||||
WDIRS= windows
|
WDIRS= windows
|
||||||
LIBS= libcrypto.a libssl.a
|
LIBS= libcrypto.a libssl.a
|
||||||
|
SIGS= libcrypto.a.sha1
|
||||||
SHARED_CRYPTO=libcrypto$(SHLIB_EXT)
|
SHARED_CRYPTO=libcrypto$(SHLIB_EXT)
|
||||||
SHARED_SSL=libssl$(SHLIB_EXT)
|
SHARED_SSL=libssl$(SHLIB_EXT)
|
||||||
SHARED_LIBS=
|
SHARED_LIBS=
|
||||||
@@ -218,14 +224,32 @@ HEADER= e_os.h
|
|||||||
# When we're prepared to use shared libraries in the programs we link here
|
# 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
|
# we might remove 'clean-shared' from the targets to perform at this stage
|
||||||
|
|
||||||
all: Makefile.ssl sub_all openssl.pc
|
all: Makefile sub_all openssl.pc
|
||||||
|
|
||||||
|
sigs: $(SIGS)
|
||||||
|
libcrypto.a.sha1: libcrypto.a
|
||||||
|
@if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
|
||||||
|
$(RANLIB) libcrypto.a; \
|
||||||
|
fips/sha/fips_standalone_sha1 libcrypto.a > libcrypto.a.sha1; \
|
||||||
|
fi
|
||||||
|
|
||||||
sub_all:
|
sub_all:
|
||||||
@for i in $(DIRS); \
|
@for i in $(DIRS); \
|
||||||
do \
|
do \
|
||||||
if [ -d "$$i" ]; then \
|
if [ -d "$$i" ]; then \
|
||||||
(cd $$i && echo "making all in $$i..." && \
|
(cd $$i && echo "making all in $$i..." && \
|
||||||
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' AS='${AS}' ASFLAGS='${ASFLAGS}' 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}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' all ) || exit 1; \
|
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' AS='${AS}' ASFLAG='${ASFLAG}' SDIRS='$(SDIRS)' FDIRS='$(FDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' FIPS_DES_ENC='${FIPS_DES_ENC}' FIPS_AES_ENC='${FIPS_AES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' FIPS_SHA1_ASM_OBJ='${FIPS_SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' all ) || exit 1; \
|
||||||
|
else \
|
||||||
|
$(MAKE) $$i; \
|
||||||
|
fi; \
|
||||||
|
done;
|
||||||
|
|
||||||
|
sub_target:
|
||||||
|
@for i in $(DIRS); \
|
||||||
|
do \
|
||||||
|
if [ -d "$$i" ]; then \
|
||||||
|
(cd $$i && echo "making $(TARGET) in $$i..." && \
|
||||||
|
$(MAKE) CC='${CC}' PLATFORM='${PLATFORM}' CFLAG='${CFLAG}' AS='${AS}' ASFLAG='${ASFLAG}' SDIRS='$(SDIRS)' FDIRS='$(FDIRS)' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' FIPS_DES_ENC='${FIPS_DES_ENC}' FIPS_AES_ENC='${FIPS_AES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' FIPS_SHA1_ASM_OBJ='${FIPS_SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' TARGET='$(TARGET)' sub_target ) || exit 1; \
|
||||||
else \
|
else \
|
||||||
$(MAKE) $$i; \
|
$(MAKE) $$i; \
|
||||||
fi; \
|
fi; \
|
||||||
@@ -234,6 +258,9 @@ sub_all:
|
|||||||
libcrypto$(SHLIB_EXT): libcrypto.a
|
libcrypto$(SHLIB_EXT): libcrypto.a
|
||||||
@if [ "$(SHLIB_TARGET)" != "" ]; then \
|
@if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||||
$(MAKE) SHLIBDIRS=crypto build-shared; \
|
$(MAKE) SHLIBDIRS=crypto build-shared; \
|
||||||
|
if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
|
||||||
|
fips/sha/fips_standalone_sha1 -binary $@ > $@.$${HMAC_EXT:-sha1}; \
|
||||||
|
fi; \
|
||||||
else \
|
else \
|
||||||
echo "There's no support for shared libraries on this platform" >&2; \
|
echo "There's no support for shared libraries on this platform" >&2; \
|
||||||
fi
|
fi
|
||||||
@@ -286,7 +313,7 @@ do_gnu-shared:
|
|||||||
-Wl,-soname=lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-Wl,-soname=lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-Wl,-Bsymbolic \
|
-Wl,-Bsymbolic \
|
||||||
-Wl,--whole-archive lib$$i.a \
|
-Wl,--whole-archive lib$$i.a \
|
||||||
-Wl,--no-whole-archive $$libs ${EX_LIBS} -lc ) || exit 1; \
|
-Wl,--no-whole-archive $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -298,7 +325,8 @@ do_darwin-shared:
|
|||||||
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
( set -x; ${CC} --verbose -dynamiclib -o lib$$i${SHLIB_EXT} \
|
( set -x; ${CC} ${SHARED_LDFLAGS}
|
||||||
|
--verbose -dynamiclib -o lib$$i${SHLIB_EXT} \
|
||||||
lib$$i.a $$libs -all_load -current_version ${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
lib$$i.a $$libs -all_load -current_version ${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-compatibility_version ${SHLIB_MAJOR}.`echo ${SHLIB_MINOR} | cut -d. -f1` \
|
-compatibility_version ${SHLIB_MAJOR}.`echo ${SHLIB_MINOR} | cut -d. -f1` \
|
||||||
-install_name ${INSTALLTOP}/lib/lib$$i${SHLIB_EXT} ) || exit 1; \
|
-install_name ${INSTALLTOP}/lib/lib$$i${SHLIB_EXT} ) || exit 1; \
|
||||||
@@ -311,11 +339,18 @@ do_cygwin-shared:
|
|||||||
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
( set -x; ${CC} -shared -o cyg$$i-$(SHLIB_VERSION_NUMBER).dll \
|
shlib=cyg$${i}-$(SHLIB_VERSION_NUMBER).dll; \
|
||||||
|
[ "$(PLATFORM)" = "mingw" ] && shlib=$${i}eay32.dll; \
|
||||||
|
[ -f apps/$$shlib ] && rm apps/$$shlib; \
|
||||||
|
[ -f test/$$shlib ] && rm test/$$shlib; \
|
||||||
|
base=; [ $$i = "crypto" ] && base=-Wl,--image-base,0x61200000; \
|
||||||
|
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
|
-shared $$base -o $$shlib \
|
||||||
-Wl,-Bsymbolic \
|
-Wl,-Bsymbolic \
|
||||||
-Wl,--whole-archive lib$$i.a \
|
-Wl,--whole-archive lib$$i.a \
|
||||||
-Wl,--out-implib,lib$$i.dll.a \
|
-Wl,--out-implib,lib$$i.dll.a \
|
||||||
-Wl,--no-whole-archive $$libs ) || exit 1; \
|
-Wl,--no-whole-archive $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
|
cp -p $$shlib apps/; cp -p $$shlib test/; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -331,7 +366,7 @@ do_alpha-osf1-shared:
|
|||||||
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
-shared -o lib$$i.so \
|
-shared -o lib$$i.so \
|
||||||
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
||||||
-all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \
|
-all lib$$i.a -none $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done; \
|
done; \
|
||||||
fi
|
fi
|
||||||
@@ -350,7 +385,7 @@ do_tru64-shared:
|
|||||||
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
-shared -msym -o lib$$i.so \
|
-shared -msym -o lib$$i.so \
|
||||||
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
||||||
-all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \
|
-all lib$$i.a -none $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done; \
|
done; \
|
||||||
fi
|
fi
|
||||||
@@ -370,7 +405,7 @@ do_tru64-shared-rpath:
|
|||||||
-shared -msym -o lib$$i.so \
|
-shared -msym -o lib$$i.so \
|
||||||
-rpath ${INSTALLTOP}/lib \
|
-rpath ${INSTALLTOP}/lib \
|
||||||
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
-set_version "${SHLIB_VERSION_HISTORY}${SHLIB_VERSION_NUMBER}" \
|
||||||
-all lib$$i.a -none $$libs ${EX_LIBS} -lc ) || exit 1; \
|
-all lib$$i.a -none $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done; \
|
done; \
|
||||||
fi
|
fi
|
||||||
@@ -388,11 +423,12 @@ do_solaris-shared:
|
|||||||
( PATH=/usr/ccs/bin:$$PATH ; export PATH; \
|
( PATH=/usr/ccs/bin:$$PATH ; export PATH; \
|
||||||
MINUSZ='-z '; \
|
MINUSZ='-z '; \
|
||||||
(${CC} -v 2>&1 | grep gcc) > /dev/null && MINUSZ='-Wl,-z,'; \
|
(${CC} -v 2>&1 | grep gcc) > /dev/null && MINUSZ='-Wl,-z,'; \
|
||||||
set -x; ${CC} ${SHARED_LDFLAGS} -G -dy -z text \
|
set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
-o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
|
-Wl,-Bsymbolic \
|
||||||
$${MINUSZ}allextract lib$$i.a $${MINUSZ}defaultextract \
|
$${MINUSZ}allextract lib$$i.a $${MINUSZ}defaultextract \
|
||||||
$$libs ${EX_LIBS} -lc ) || exit 1; \
|
$$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done; \
|
done; \
|
||||||
fi
|
fi
|
||||||
@@ -410,9 +446,10 @@ do_svr3-shared:
|
|||||||
find . -name "*.o" -print > allobjs ; \
|
find . -name "*.o" -print > allobjs ; \
|
||||||
OBJS= ; export OBJS ; \
|
OBJS= ; export OBJS ; \
|
||||||
for obj in `ar t lib$$i.a` ; do \
|
for obj in `ar t lib$$i.a` ; do \
|
||||||
OBJS="$${OBJS} `grep $$obj allobjs`" ; \
|
OBJS="$${OBJS} `grep /$$obj allobjs`" ; \
|
||||||
done ; \
|
done ; \
|
||||||
set -x; ${CC} -G -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
|
-G -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
$${OBJS} $$libs ${EX_LIBS} ) || exit 1; \
|
$${OBJS} $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
@@ -429,13 +466,16 @@ do_svr5-shared:
|
|||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
( PATH=/usr/ccs/bin:$$PATH ; export PATH; \
|
( PATH=/usr/ccs/bin:$$PATH ; export PATH; \
|
||||||
|
SHARE_FLAG='-G'; \
|
||||||
|
(${CC} -v 2>&1 | grep gcc) > /dev/null && SHARE_FLAG='-shared'; \
|
||||||
find . -name "*.o" -print > allobjs ; \
|
find . -name "*.o" -print > allobjs ; \
|
||||||
OBJS= ; export OBJS ; \
|
OBJS= ; export OBJS ; \
|
||||||
for obj in `ar t lib$$i.a` ; do \
|
for obj in `ar t lib$$i.a` ; do \
|
||||||
OBJS="$${OBJS} `grep $$obj allobjs`" ; \
|
OBJS="$${OBJS} `grep /$$obj allobjs`" ; \
|
||||||
done ; \
|
done ; \
|
||||||
set -x; ${CC} ${SHARED_LDFLAGS} \
|
set -x; LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH \
|
||||||
-G -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
${CC} ${SHARED_LDFLAGS} \
|
||||||
|
$${SHARE_FLAG} -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-h lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
$${OBJS} $$libs ${EX_LIBS} ) || exit 1; \
|
$${OBJS} $$libs ${EX_LIBS} ) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
@@ -451,59 +491,35 @@ do_irix-shared:
|
|||||||
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
( WHOLELIB="-all lib$$i.a -none"; \
|
||||||
|
(${CC} -v 2>&1 | grep gcc) > /dev/null && WHOLELIB="-Wl,-all,lib$$i.a,-none"; \
|
||||||
|
set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
-shared -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-shared -o lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-Wl,-soname,lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
-Wl,-soname,lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
||||||
-all lib$$i.a $$libs ${EX_LIBS} -lc) || exit 1; \
|
$${WHOLELIB} $$libs ${EX_LIBS}) || exit 1; \
|
||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done; \
|
done; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# This assumes that GNU utilities are *not* used
|
# This assumes that GNU utilities are *not* used
|
||||||
# HP-UX includes the full pathname of libs we depend on, so we would get
|
|
||||||
# ./libcrypto (with ./ as path information) compiled into libssl, hence
|
|
||||||
# we omit the SHLIBDEPS. Applications must be linked with -lssl -lcrypto
|
|
||||||
# anyway.
|
|
||||||
# The object modules are loaded from lib$i.a using the undocumented -Fl
|
|
||||||
# option.
|
|
||||||
#
|
|
||||||
# WARNING: Until DSO is fixed to support a search path, we support SHLIB_PATH
|
|
||||||
# by temporarily specifying "+s"!
|
|
||||||
#
|
#
|
||||||
do_hpux-shared:
|
do_hpux-shared:
|
||||||
for i in ${SHLIBDIRS}; do \
|
for i in ${SHLIBDIRS}; do \
|
||||||
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
( set -x; /usr/ccs/bin/ld ${SHARED_LDFLAGS} \
|
if expr $(PLATFORM) : '.*ia64' > /dev/null; then \
|
||||||
+vnocompatwarnings \
|
shlib=lib$$i.so.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
||||||
-b -z +s \
|
else \
|
||||||
-o lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
shlib=lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
||||||
+h lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
|
||||||
-Fl lib$$i.a -ldld -lc ) || exit 1; \
|
|
||||||
chmod a=rx lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
|
||||||
done
|
|
||||||
|
|
||||||
# This assumes that GNU utilities are *not* used
|
|
||||||
# HP-UX includes the full pathname of libs we depend on, so we would get
|
|
||||||
# ./libcrypto (with ./ as path information) compiled into libssl, hence
|
|
||||||
# we omit the SHLIBDEPS. Applications must be linked with -lssl -lcrypto
|
|
||||||
# anyway.
|
|
||||||
#
|
|
||||||
# HP-UX in 64bit mode has "+s" enabled by default; it will search for
|
|
||||||
# shared libraries along LD_LIBRARY_PATH _and_ SHLIB_PATH.
|
|
||||||
#
|
|
||||||
do_hpux64-shared:
|
|
||||||
for i in ${SHLIBDIRS}; do \
|
|
||||||
if [ "${SHLIBDIRS}" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
|
||||||
libs="$(LIBKRB5) $$libs"; \
|
|
||||||
fi; \
|
fi; \
|
||||||
( set -x; /usr/ccs/bin/ld ${SHARED_LDFLAGS} \
|
[ -f $$shlib ] && rm -f $$shlib; \
|
||||||
-b -z \
|
ALLSYMSFLAGS='-Wl,-Fl'; \
|
||||||
-o lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
expr $(PLATFORM) : 'hpux64' > /dev/null && ALLSYMSFLAGS='-Wl,+forceload'; \
|
||||||
+h lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR} \
|
( set -x; ${CC} ${SHARED_LDFLAGS} \
|
||||||
+forceload lib$$i.a -ldl -lc ) || exit 1; \
|
-Wl,-B,symbolic,+vnocompatwarnings,-z,+h,$$shlib \
|
||||||
chmod a=rx lib$$i.sl.${SHLIB_MAJOR}.${SHLIB_MINOR}; \
|
-o $$shlib $$ALLSYMSFLAGS lib$$i.a -ldld ) || exit 1; \
|
||||||
|
chmod a=rx $$shlib; \
|
||||||
done
|
done
|
||||||
|
|
||||||
# The following method is said to work on all platforms. Tests will
|
# The following method is said to work on all platforms. Tests will
|
||||||
@@ -544,6 +560,8 @@ do_aix-shared:
|
|||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
( set -x; \
|
( set -x; \
|
||||||
|
OBJECT_MODE=`expr x${SHARED_LDFLAGS} : 'x\-[a-z]\([0-9]*\)'`; \
|
||||||
|
OBJECT_MODE=$${OBJECT_MODE:-32}; export OBJECT_MODE; \
|
||||||
ld -r -o lib$$i.o $(ALLSYMSFLAG) lib$$i.a && \
|
ld -r -o lib$$i.o $(ALLSYMSFLAG) lib$$i.a && \
|
||||||
( nm -Pg lib$$i.o | grep ' [BD] ' | cut -f1 -d' ' > lib$$i.exp; \
|
( nm -Pg lib$$i.o | grep ' [BD] ' | cut -f1 -d' ' > lib$$i.exp; \
|
||||||
$(SHAREDCMD) $(SHAREDFLAGS) \
|
$(SHAREDCMD) $(SHAREDFLAGS) \
|
||||||
@@ -570,7 +588,7 @@ do_reliantunix-shared:
|
|||||||
libs="-l$$i $$libs"; \
|
libs="-l$$i $$libs"; \
|
||||||
done
|
done
|
||||||
|
|
||||||
openssl.pc: Makefile.ssl
|
openssl.pc: Makefile
|
||||||
@ ( echo 'prefix=$(INSTALLTOP)'; \
|
@ ( echo 'prefix=$(INSTALLTOP)'; \
|
||||||
echo 'exec_prefix=$${prefix}'; \
|
echo 'exec_prefix=$${prefix}'; \
|
||||||
echo 'libdir=$${exec_prefix}/lib'; \
|
echo 'libdir=$${exec_prefix}/lib'; \
|
||||||
@@ -583,26 +601,26 @@ openssl.pc: Makefile.ssl
|
|||||||
echo 'Libs: -L$${libdir} -lssl -lcrypto $(LIBKRB5) $(EX_LIBS)'; \
|
echo 'Libs: -L$${libdir} -lssl -lcrypto $(LIBKRB5) $(EX_LIBS)'; \
|
||||||
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > openssl.pc
|
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > openssl.pc
|
||||||
|
|
||||||
Makefile.ssl: Makefile.org
|
Makefile: Makefile.org
|
||||||
@echo "Makefile.ssl is older than Makefile.org."
|
@echo "Makefile is older than Makefile.org."
|
||||||
@echo "Reconfigure the source tree (via './config' or 'perl Configure'), please."
|
@echo "Reconfigure the source tree (via './config' or 'perl Configure'), please."
|
||||||
@false
|
@false
|
||||||
|
|
||||||
libclean:
|
libclean:
|
||||||
rm -f *.a */lib */*/lib
|
rm -f *.map *.so *.so.* engines/*.so *.a */lib */*/lib
|
||||||
|
|
||||||
clean:
|
clean: libclean
|
||||||
rm -f shlib/*.o *.o core a.out fluff *.map rehash.time testlog make.log cctest cctest.c
|
rm -f shlib/*.o *.o core a.out fluff rehash.time testlog make.log cctest cctest.c
|
||||||
@for i in $(DIRS) ;\
|
@for i in $(DIRS) ;\
|
||||||
do \
|
do \
|
||||||
if [ -d "$$i" ]; then \
|
if [ -d "$$i" ]; then \
|
||||||
(cd $$i && echo "making clean in $$i..." && \
|
(cd $$i && echo "making clean in $$i..." && \
|
||||||
$(MAKE) SDIRS='${SDIRS}' clean ) || exit 1; \
|
$(MAKE) EXE_EXT='${EXE_EXT}' SDIRS='${SDIRS}' clean ) || exit 1; \
|
||||||
rm -f $(LIBS); \
|
rm -f $(LIBS); \
|
||||||
fi; \
|
fi; \
|
||||||
done;
|
done;
|
||||||
rm -f openssl.pc
|
rm -f openssl.pc
|
||||||
rm -f *.a *.o speed.* *.map *.so .pure core
|
rm -f speed.* .pure
|
||||||
rm -f $(TARFILE)
|
rm -f $(TARFILE)
|
||||||
@for i in $(ONEDIRS) ;\
|
@for i in $(ONEDIRS) ;\
|
||||||
do \
|
do \
|
||||||
@@ -614,7 +632,7 @@ makefile.one: files
|
|||||||
sh util/do_ms.sh
|
sh util/do_ms.sh
|
||||||
|
|
||||||
files:
|
files:
|
||||||
$(PERL) $(TOP)/util/files.pl Makefile.ssl > $(TOP)/MINFO
|
$(PERL) $(TOP)/util/files.pl Makefile > $(TOP)/MINFO
|
||||||
@for i in $(DIRS) ;\
|
@for i in $(DIRS) ;\
|
||||||
do \
|
do \
|
||||||
if [ -d "$$i" ]; then \
|
if [ -d "$$i" ]; then \
|
||||||
@@ -624,19 +642,18 @@ files:
|
|||||||
done;
|
done;
|
||||||
|
|
||||||
links:
|
links:
|
||||||
@$(TOP)/util/point.sh Makefile.ssl Makefile
|
|
||||||
@$(PERL) $(TOP)/util/mkdir-p.pl include/openssl
|
@$(PERL) $(TOP)/util/mkdir-p.pl include/openssl
|
||||||
@$(PERL) $(TOP)/util/mklink.pl include/openssl $(EXHEADER)
|
@$(PERL) $(TOP)/util/mklink.pl include/openssl $(EXHEADER)
|
||||||
@for i in $(DIRS); do \
|
@for i in $(DIRS); do \
|
||||||
if [ -d "$$i" ]; then \
|
if [ -d "$$i" ]; then \
|
||||||
(cd $$i && echo "making links in $$i..." && \
|
(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}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' links ) || 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}' FIPS_DES_ENC='${FIPS_DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' FIPS_SHA1_ASM_OBJ='${FIPS_SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PERL='${PERL}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' links ) || exit 1; \
|
||||||
fi; \
|
fi; \
|
||||||
done;
|
done;
|
||||||
|
|
||||||
gentests:
|
gentests:
|
||||||
@(cd test && echo "generating dummy tests (if needed)..." && \
|
@(cd test && echo "generating dummy tests (if needed)..." && \
|
||||||
$(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}' TESTS='${TESTS}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' TESTS='${TESTS}' OPENSSL_DEBUG_MEMORY=on generate );
|
$(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}' FIPS_DES_ENC='${FIPS_DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' FIPS_SHA1_ASM_OBJ='${FIPS_SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' TESTS='${TESTS}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' TESTS='${TESTS}' OPENSSL_DEBUG_MEMORY=on generate );
|
||||||
|
|
||||||
dclean:
|
dclean:
|
||||||
rm -f *.bak
|
rm -f *.bak
|
||||||
@@ -650,23 +667,18 @@ dclean:
|
|||||||
|
|
||||||
rehash: rehash.time
|
rehash: rehash.time
|
||||||
rehash.time: certs
|
rehash.time: certs
|
||||||
@(OPENSSL="`pwd`/apps/openssl"; OPENSSL_DEBUG_MEMORY=on; \
|
@(OPENSSL="`pwd`/util/opensslwrap.sh"; \
|
||||||
export OPENSSL OPENSSL_DEBUG_MEMORY; \
|
OPENSSL_DEBUG_MEMORY=on; \
|
||||||
LD_LIBRARY_PATH="`pwd`"; DYLD_LIBRARY_PATH="`pwd`"; SHLIB_PATH="`pwd`"; LIBPATH="`pwd`"; \
|
export OPENSSL OPENSSL_DEBUG_MEMORY; \
|
||||||
if [ "$(PLATFORM)" = "Cygwin" ]; then PATH="`pwd`:$$PATH"; fi; \
|
$(PERL) tools/c_rehash certs)
|
||||||
export LD_LIBRARY_PATH DYLD_LIBRARY_PATH SHLIB_PATH LIBPATH PATH; \
|
|
||||||
$(PERL) tools/c_rehash certs)
|
|
||||||
touch rehash.time
|
touch rehash.time
|
||||||
|
|
||||||
test: tests
|
test: tests
|
||||||
|
|
||||||
tests: rehash
|
tests: rehash
|
||||||
@(cd test && echo "testing..." && \
|
@(cd test && echo "testing..." && \
|
||||||
$(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}' TESTS='${TESTS}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' TESTS='${TESTS}' OPENSSL_DEBUG_MEMORY=on tests );
|
$(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}' FIPS_DES_ENC='${FIPS_DES_ENC}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' FIPS_SHA1_ASM_OBJ='${FIPS_SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' AR='${AR}' PROCESSOR='${PROCESSOR}' PERL='${PERL}' RANLIB='${RANLIB}' TESTS='${TESTS}' KRB5_INCLUDES='${KRB5_INCLUDES}' LIBKRB5='${LIBKRB5}' EXE_EXT='${EXE_EXT}' SHARED_LIBS='${SHARED_LIBS}' SHLIB_EXT='${SHLIB_EXT}' SHLIB_TARGET='${SHLIB_TARGET}' TESTS='${TESTS}' OPENSSL_DEBUG_MEMORY=on tests );
|
||||||
@LD_LIBRARY_PATH="`pwd`"; DYLD_LIBRARY_PATH="`pwd`"; SHLIB_PATH="`pwd`"; LIBPATH="`pwd`"; \
|
util/shlib_wrap.sh apps/openssl version -a
|
||||||
if [ "$(PLATFORM)" = "Cygwin" ]; then PATH="`pwd`:$$PATH"; fi; \
|
|
||||||
export LD_LIBRARY_PATH DYLD_LIBRARY_PATH SHLIB_PATH LIBPATH PATH; \
|
|
||||||
apps/openssl version -a
|
|
||||||
|
|
||||||
report:
|
report:
|
||||||
@$(PERL) util/selftest.pl
|
@$(PERL) util/selftest.pl
|
||||||
@@ -690,13 +702,8 @@ lint:
|
|||||||
done;
|
done;
|
||||||
|
|
||||||
tags:
|
tags:
|
||||||
@for i in $(DIRS) ;\
|
rm -f TAGS
|
||||||
do \
|
find . -name '[^.]*.[ch]' | xargs etags -a
|
||||||
if [ -d "$$i" ]; then \
|
|
||||||
(cd $$i && echo "making tags $$i..." && \
|
|
||||||
$(MAKE) SDIRS='${SDIRS}' tags ) || exit 1; \
|
|
||||||
fi; \
|
|
||||||
done;
|
|
||||||
|
|
||||||
errors:
|
errors:
|
||||||
$(PERL) util/mkerr.pl -recurse -write
|
$(PERL) util/mkerr.pl -recurse -write
|
||||||
@@ -716,11 +723,14 @@ crypto/objects/obj_dat.h: crypto/objects/obj_dat.pl crypto/objects/obj_mac.h
|
|||||||
crypto/objects/obj_mac.h: crypto/objects/objects.pl crypto/objects/objects.txt crypto/objects/obj_mac.num
|
crypto/objects/obj_mac.h: crypto/objects/objects.pl crypto/objects/objects.txt crypto/objects/obj_mac.num
|
||||||
$(PERL) crypto/objects/objects.pl crypto/objects/objects.txt crypto/objects/obj_mac.num crypto/objects/obj_mac.h
|
$(PERL) crypto/objects/objects.pl crypto/objects/objects.txt crypto/objects/obj_mac.num crypto/objects/obj_mac.h
|
||||||
|
|
||||||
|
apps/openssl-vms.cnf: apps/openssl.cnf
|
||||||
|
$(PERL) VMS/VMSify-conf.pl < apps/openssl.cnf > apps/openssl-vms.cnf
|
||||||
|
|
||||||
TABLE: Configure
|
TABLE: Configure
|
||||||
(echo 'Output of `Configure TABLE'"':"; \
|
(echo 'Output of `Configure TABLE'"':"; \
|
||||||
$(PERL) Configure TABLE) > TABLE
|
$(PERL) Configure TABLE) > TABLE
|
||||||
|
|
||||||
update: depend errors stacks util/libeay.num util/ssleay.num crypto/objects/obj_dat.h TABLE
|
update: depend errors stacks util/libeay.num util/ssleay.num crypto/objects/obj_dat.h apps/openssl-vms.cnf TABLE
|
||||||
|
|
||||||
# Build distribution tar-file. As the list of files returned by "find" is
|
# Build distribution tar-file. As the list of files returned by "find" is
|
||||||
# pretty long, on several platforms a "too many arguments" error or similar
|
# pretty long, on several platforms a "too many arguments" error or similar
|
||||||
@@ -757,16 +767,17 @@ dist:
|
|||||||
dist_pem_h:
|
dist_pem_h:
|
||||||
(cd crypto/pem; $(MAKE) CC='${CC}' SDIRS='${SDIRS}' CFLAG='${CFLAG}' pem.h; $(MAKE) clean)
|
(cd crypto/pem; $(MAKE) CC='${CC}' SDIRS='${SDIRS}' CFLAG='${CFLAG}' pem.h; $(MAKE) clean)
|
||||||
|
|
||||||
install: all install_docs
|
install: all install_docs install_sw
|
||||||
|
|
||||||
|
install_sw:
|
||||||
@$(PERL) $(TOP)/util/mkdir-p.pl $(INSTALL_PREFIX)$(INSTALLTOP)/bin \
|
@$(PERL) $(TOP)/util/mkdir-p.pl $(INSTALL_PREFIX)$(INSTALLTOP)/bin \
|
||||||
$(INSTALL_PREFIX)$(INSTALLTOP)/lib \
|
$(INSTALL_PREFIX)$(INSTALLTOP)/lib \
|
||||||
$(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig \
|
$(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig \
|
||||||
$(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl \
|
$(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl \
|
||||||
$(INSTALL_PREFIX)$(OPENSSLDIR)/misc \
|
$(INSTALL_PREFIX)$(OPENSSLDIR)/misc \
|
||||||
$(INSTALL_PREFIX)$(OPENSSLDIR)/certs \
|
$(INSTALL_PREFIX)$(OPENSSLDIR)/certs \
|
||||||
$(INSTALL_PREFIX)$(OPENSSLDIR)/private \
|
$(INSTALL_PREFIX)$(OPENSSLDIR)/private
|
||||||
$(INSTALL_PREFIX)$(OPENSSLDIR)/lib
|
@headerlist="$(EXHEADER)"; for i in $$headerlist ;\
|
||||||
@for i in $(EXHEADER) ;\
|
|
||||||
do \
|
do \
|
||||||
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
||||||
@@ -783,7 +794,11 @@ install: all install_docs
|
|||||||
if [ -f "$$i" ]; then \
|
if [ -f "$$i" ]; then \
|
||||||
( echo installing $$i; \
|
( echo installing $$i; \
|
||||||
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
||||||
$(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
|
||||||
|
: ; \
|
||||||
|
else \
|
||||||
|
$(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
||||||
|
fi; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
||||||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
|
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
|
||||||
fi; \
|
fi; \
|
||||||
@@ -820,7 +835,17 @@ install: all install_docs
|
|||||||
sed -e '1,/^$$/d' doc/openssl-shared.txt; \
|
sed -e '1,/^$$/d' doc/openssl-shared.txt; \
|
||||||
fi; \
|
fi; \
|
||||||
fi
|
fi
|
||||||
|
@for i in $(SIGS) ;\
|
||||||
|
do \
|
||||||
|
if [ -f "$$i" ]; then \
|
||||||
|
( echo installing $$i; \
|
||||||
|
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
||||||
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
||||||
|
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
|
||||||
|
fi; \
|
||||||
|
done;
|
||||||
cp openssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig
|
cp openssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig
|
||||||
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig/openssl.pc
|
||||||
|
|
||||||
install_docs:
|
install_docs:
|
||||||
@$(PERL) $(TOP)/util/mkdir-p.pl \
|
@$(PERL) $(TOP)/util/mkdir-p.pl \
|
||||||
@@ -831,39 +856,41 @@ install_docs:
|
|||||||
@pod2man="`cd util; ./pod2mantest $(PERL)`"; \
|
@pod2man="`cd util; ./pod2mantest $(PERL)`"; \
|
||||||
here="`pwd`"; \
|
here="`pwd`"; \
|
||||||
filecase=; \
|
filecase=; \
|
||||||
if [ "$(PLATFORM)" = "DJGPP" -o "$(PLATFORM)" = "Cygwin" ]; then \
|
if [ "$(PLATFORM)" = "DJGPP" -o "$(PLATFORM)" = "Cygwin" -o "$(PLATFORM)" = "mingw" ]; then \
|
||||||
filecase=-i; \
|
filecase=-i; \
|
||||||
fi; \
|
fi; \
|
||||||
for i in doc/apps/*.pod; do \
|
for i in doc/apps/*.pod; do \
|
||||||
fn=`basename $$i .pod`; \
|
fn=`basename $$i .pod`; \
|
||||||
if [ "$$fn" = "config" ]; then sec=5; else sec=1; fi; \
|
if [ "$$fn" = "config" ]; then sec=5; else sec=1; fi; \
|
||||||
echo "installing man$$sec/$$fn.$$sec"; \
|
echo "installing man$$sec/$$fn.$${sec}$(MANSUFFIX)"; \
|
||||||
(cd `$(PERL) util/dirname.pl $$i`; \
|
(cd `$(PERL) util/dirname.pl $$i`; \
|
||||||
sh -c "$$pod2man \
|
sh -c "$$pod2man \
|
||||||
--section=$$sec --center=OpenSSL \
|
--section=$$sec --center=OpenSSL \
|
||||||
--release=$(VERSION) `basename $$i`") \
|
--release=$(VERSION) `basename $$i`") \
|
||||||
> $(INSTALL_PREFIX)$(MANDIR)/man$$sec/$$fn.$$sec; \
|
> $(INSTALL_PREFIX)$(MANDIR)/man$$sec/$$fn.$${sec}$(MANSUFFIX); \
|
||||||
$(PERL) util/extract-names.pl < $$i | \
|
$(PERL) util/extract-names.pl < $$i | \
|
||||||
grep -v $$filecase "^$$fn\$$" | \
|
grep -v $$filecase "^$$fn\$$" | \
|
||||||
|
grep -v "[ ]" | \
|
||||||
(cd $(INSTALL_PREFIX)$(MANDIR)/man$$sec/; \
|
(cd $(INSTALL_PREFIX)$(MANDIR)/man$$sec/; \
|
||||||
while read n; do \
|
while read n; do \
|
||||||
$$here/util/point.sh $$fn.$$sec $$n.$$sec; \
|
$$here/util/point.sh $$fn.$${sec}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
|
||||||
done); \
|
done); \
|
||||||
done; \
|
done; \
|
||||||
for i in doc/crypto/*.pod doc/ssl/*.pod; do \
|
for i in doc/crypto/*.pod doc/ssl/*.pod; do \
|
||||||
fn=`basename $$i .pod`; \
|
fn=`basename $$i .pod`; \
|
||||||
if [ "$$fn" = "des_modes" ]; then sec=7; else sec=3; fi; \
|
if [ "$$fn" = "des_modes" ]; then sec=7; else sec=3; fi; \
|
||||||
echo "installing man$$sec/$$fn.$$sec"; \
|
echo "installing man$$sec/$$fn.$${sec}$(MANSUFFIX)"; \
|
||||||
(cd `$(PERL) util/dirname.pl $$i`; \
|
(cd `$(PERL) util/dirname.pl $$i`; \
|
||||||
sh -c "$$pod2man \
|
sh -c "$$pod2man \
|
||||||
--section=$$sec --center=OpenSSL \
|
--section=$$sec --center=OpenSSL \
|
||||||
--release=$(VERSION) `basename $$i`") \
|
--release=$(VERSION) `basename $$i`") \
|
||||||
> $(INSTALL_PREFIX)$(MANDIR)/man$$sec/$$fn.$$sec; \
|
> $(INSTALL_PREFIX)$(MANDIR)/man$$sec/$$fn.$${sec}$(MANSUFFIX); \
|
||||||
$(PERL) util/extract-names.pl < $$i | \
|
$(PERL) util/extract-names.pl < $$i | \
|
||||||
grep -v $$filecase "^$$fn\$$" | \
|
grep -v $$filecase "^$$fn\$$" | \
|
||||||
|
grep -v "[ ]" | \
|
||||||
(cd $(INSTALL_PREFIX)$(MANDIR)/man$$sec/; \
|
(cd $(INSTALL_PREFIX)$(MANDIR)/man$$sec/; \
|
||||||
while read n; do \
|
while read n; do \
|
||||||
$$here/util/point.sh $$fn.$$sec $$n.$$sec; \
|
$$here/util/point.sh $$fn.$${sec}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
|
||||||
done); \
|
done); \
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|||||||
60
NEWS
60
NEWS
@@ -5,6 +5,54 @@
|
|||||||
This file gives a brief overview of the major changes between each OpenSSL
|
This file gives a brief overview of the major changes between each OpenSSL
|
||||||
release. For more details please read the CHANGES file.
|
release. For more details please read the CHANGES file.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.7f and OpenSSL 0.9.7g:
|
||||||
|
|
||||||
|
o More compilation issues fixed.
|
||||||
|
o Adaptation to more modern Kerberos API.
|
||||||
|
o Enhanced or corrected configuration for Solaris64, Mingw and Cygwin.
|
||||||
|
o Enhanced x86_64 assembler BIGNUM module.
|
||||||
|
o More constification.
|
||||||
|
o Added processing of proxy certificates (RFC 3820).
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.7e and OpenSSL 0.9.7f:
|
||||||
|
|
||||||
|
o Several compilation issues fixed.
|
||||||
|
o Many memory allocation failure checks added.
|
||||||
|
o Improved comparison of X509 Name type.
|
||||||
|
o Mandatory basic checks on certificates.
|
||||||
|
o Performance improvements.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.7d and OpenSSL 0.9.7e:
|
||||||
|
|
||||||
|
o Fix race condition in CRL checking code.
|
||||||
|
o Fixes to PKCS#7 (S/MIME) code.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.7c and OpenSSL 0.9.7d:
|
||||||
|
|
||||||
|
o Security: Fix Kerberos ciphersuite SSL/TLS handshaking bug
|
||||||
|
o Security: Fix null-pointer assignment in do_change_cipher_spec()
|
||||||
|
o Allow multiple active certificates with same subject in CA index
|
||||||
|
o Multiple X509 verification fixes
|
||||||
|
o Speed up HMAC and other operations
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.7b and OpenSSL 0.9.7c:
|
||||||
|
|
||||||
|
o Security: fix various ASN1 parsing bugs.
|
||||||
|
o New -ignore_err option to OCSP utility.
|
||||||
|
o Various interop and bug fixes in S/MIME code.
|
||||||
|
o SSL/TLS protocol fix for unrequested client certificates.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.7a and OpenSSL 0.9.7b:
|
||||||
|
|
||||||
|
o Security: counter the Klima-Pokorny-Rosa extension of
|
||||||
|
Bleichbacher's attack
|
||||||
|
o Security: make RSA blinding default.
|
||||||
|
o Configuration: Irix fixes, AIX fixes, better mingw support.
|
||||||
|
o Support for new platforms: linux-ia64-ecc.
|
||||||
|
o Build: shared library support fixes.
|
||||||
|
o ASN.1: treat domainComponent correctly.
|
||||||
|
o Documentation: fixes and additions.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7 and OpenSSL 0.9.7a:
|
Major changes between OpenSSL 0.9.7 and OpenSSL 0.9.7a:
|
||||||
|
|
||||||
o Security: Important security related bugfixes.
|
o Security: Important security related bugfixes.
|
||||||
@@ -62,6 +110,18 @@
|
|||||||
o SSL/TLS: add callback to retrieve SSL/TLS messages.
|
o SSL/TLS: add callback to retrieve SSL/TLS messages.
|
||||||
o SSL/TLS: support AES cipher suites (RFC3268).
|
o SSL/TLS: support AES cipher suites (RFC3268).
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.6j and OpenSSL 0.9.6k:
|
||||||
|
|
||||||
|
o Security: fix various ASN1 parsing bugs.
|
||||||
|
o SSL/TLS protocol fix for unrequested client certificates.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.6i and OpenSSL 0.9.6j:
|
||||||
|
|
||||||
|
o Security: counter the Klima-Pokorny-Rosa extension of
|
||||||
|
Bleichbacher's attack
|
||||||
|
o Security: make RSA blinding default.
|
||||||
|
o Build: shared library support fixes.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6h and OpenSSL 0.9.6i:
|
Major changes between OpenSSL 0.9.6h and OpenSSL 0.9.6i:
|
||||||
|
|
||||||
o Important security related bugfixes.
|
o Important security related bugfixes.
|
||||||
|
|||||||
96
PROBLEMS
96
PROBLEMS
@@ -12,8 +12,8 @@ along the whole library path before it bothers looking for .a libraries. This
|
|||||||
means that -L switches won't matter unless OpenSSL is built with shared
|
means that -L switches won't matter unless OpenSSL is built with shared
|
||||||
library support.
|
library support.
|
||||||
|
|
||||||
The workaround may be to change the following lines in apps/Makefile.ssl and
|
The workaround may be to change the following lines in apps/Makefile and
|
||||||
test/Makefile.ssl:
|
test/Makefile:
|
||||||
|
|
||||||
LIBCRYPTO=-L.. -lcrypto
|
LIBCRYPTO=-L.. -lcrypto
|
||||||
LIBSSL=-L.. -lssl
|
LIBSSL=-L.. -lssl
|
||||||
@@ -48,20 +48,28 @@ will interfere with each other and lead to test failure.
|
|||||||
The solution is simple for now: don't run parallell make when testing.
|
The solution is simple for now: don't run parallell make when testing.
|
||||||
|
|
||||||
|
|
||||||
* Bugs in gcc 3.0 triggered
|
* Bugs in gcc triggered
|
||||||
|
|
||||||
According to a problem report, there are bugs in gcc 3.0 that are
|
- According to a problem report, there are bugs in gcc 3.0 that are
|
||||||
triggered by some of the code in OpenSSL, more specifically in
|
triggered by some of the code in OpenSSL, more specifically in
|
||||||
PEM_get_EVP_CIPHER_INFO(). The triggering code is the following:
|
PEM_get_EVP_CIPHER_INFO(). The triggering code is the following:
|
||||||
|
|
||||||
header+=11;
|
header+=11;
|
||||||
if (*header != '4') return(0); header++;
|
if (*header != '4') return(0); header++;
|
||||||
if (*header != ',') return(0); header++;
|
if (*header != ',') return(0); header++;
|
||||||
|
|
||||||
What happens is that gcc might optimize a little too agressively, and
|
What happens is that gcc might optimize a little too agressively, and
|
||||||
you end up with an extra incrementation when *header != '4'.
|
you end up with an extra incrementation when *header != '4'.
|
||||||
|
|
||||||
We recommend that you upgrade gcc to as high a 3.x version as you can.
|
We recommend that you upgrade gcc to as high a 3.x version as you can.
|
||||||
|
|
||||||
|
- According to multiple problem reports, some of our message digest
|
||||||
|
implementations trigger bug[s] in code optimizer in gcc 3.3 for sparc64
|
||||||
|
and gcc 2.96 for ppc. Former fails to complete RIPEMD160 test, while
|
||||||
|
latter - SHA one.
|
||||||
|
|
||||||
|
The recomendation is to upgrade your compiler. This naturally applies to
|
||||||
|
other similar cases.
|
||||||
|
|
||||||
* solaris64-sparcv9-cc SHA-1 performance with WorkShop 6 compiler.
|
* solaris64-sparcv9-cc SHA-1 performance with WorkShop 6 compiler.
|
||||||
|
|
||||||
@@ -90,11 +98,67 @@ failures in other parts of the code.
|
|||||||
|
|
||||||
Workaround: modify the target to +O2 when building with no-asm.
|
Workaround: modify the target to +O2 when building with no-asm.
|
||||||
|
|
||||||
* Poor support for AIX shared builds.
|
* Problems building shared libraries on SCO OpenServer Release 5.0.6
|
||||||
|
with gcc 2.95.3
|
||||||
|
|
||||||
do_aix-shared rule is not flexible enough to parameterize through a
|
The symptoms appear when running the test suite, more specifically
|
||||||
config-line. './Configure aix43-cc shared' is working, but not
|
test/ectest, with the following result:
|
||||||
'./Configure aix64-gcc shared'. In latter case make fails to create shared
|
|
||||||
libraries. It's possible to build 64-bit shared libraries by running
|
OSSL_LIBPATH="`cd ..; pwd`"; LD_LIBRARY_PATH="$OSSL_LIBPATH:$LD_LIBRARY_PATH"; DYLD_LIBRARY_PATH="$OSSL_LIBPATH:$DYLD_LIBRARY_PATH"; SHLIB_PATH="$OSSL_LIBPATH:$SHLIB_PATH"; LIBPATH="$OSSL_LIBPATH:$LIBPATH"; if [ "debug-sco5-gcc" = "Cygwin" ]; then PATH="${LIBPATH}:$PATH"; fi; export LD_LIBRARY_PATH DYLD_LIBRARY_PATH SHLIB_PATH LIBPATH PATH; ./ectest
|
||||||
'env OBJECT_MODE=64 make', but we need more elegant solution. Preferably one
|
ectest.c:186: ABORT
|
||||||
supporting even gcc shared builds. See RT#463 for background information.
|
|
||||||
|
The cause of the problem seems to be that isxdigit(), called from
|
||||||
|
BN_hex2bn(), returns 0 on a perfectly legitimate hex digit. Further
|
||||||
|
investigation shows that any of the isxxx() macros return 0 on any
|
||||||
|
input. A direct look in the information array that the isxxx() use,
|
||||||
|
called __ctype, shows that it contains all zeroes...
|
||||||
|
|
||||||
|
Taking a look at the newly created libcrypto.so with nm, one can see
|
||||||
|
that the variable __ctype is defined in libcrypto's .bss (which
|
||||||
|
explains why it is filled with zeroes):
|
||||||
|
|
||||||
|
$ nm -Pg libcrypto.so | grep __ctype
|
||||||
|
__ctype B 0011659c
|
||||||
|
__ctype2 U
|
||||||
|
|
||||||
|
Curiously, __ctype2 is undefined, in spite of being declared in
|
||||||
|
/usr/include/ctype.h in exactly the same way as __ctype.
|
||||||
|
|
||||||
|
Any information helping to solve this issue would be deeply
|
||||||
|
appreciated.
|
||||||
|
|
||||||
|
NOTE: building non-shared doesn't come with this problem.
|
||||||
|
|
||||||
|
* ULTRIX build fails with shell errors, such as "bad substitution"
|
||||||
|
and "test: argument expected"
|
||||||
|
|
||||||
|
The problem is caused by ULTRIX /bin/sh supporting only original
|
||||||
|
Bourne shell syntax/semantics, and the trouble is that the vast
|
||||||
|
majority is so accustomed to more modern syntax, that very few
|
||||||
|
people [if any] would recognize the ancient syntax even as valid.
|
||||||
|
This inevitably results in non-trivial scripts breaking on ULTRIX,
|
||||||
|
and OpenSSL isn't an exclusion. Fortunately there is workaround,
|
||||||
|
hire /bin/ksh to do the job /bin/sh fails to do.
|
||||||
|
|
||||||
|
1. Trick make(1) to use /bin/ksh by setting up following environ-
|
||||||
|
ment variables *prior* you execute ./Configure and make:
|
||||||
|
|
||||||
|
PROG_ENV=POSIX
|
||||||
|
MAKESHELL=/bin/ksh
|
||||||
|
export PROG_ENV MAKESHELL
|
||||||
|
|
||||||
|
or if your shell is csh-compatible:
|
||||||
|
|
||||||
|
setenv PROG_ENV POSIX
|
||||||
|
setenv MAKESHELL /bin/ksh
|
||||||
|
|
||||||
|
2. Trick /bin/sh to use alternative expression evaluator. Create
|
||||||
|
following 'test' script for example in /tmp:
|
||||||
|
|
||||||
|
#!/bin/ksh
|
||||||
|
${0##*/} "$@"
|
||||||
|
|
||||||
|
Then 'chmod a+x /tmp/test; ln /tmp/test /tmp/[' and *prepend*
|
||||||
|
your $PATH with chosen location, e.g. PATH=/tmp:$PATH. Alter-
|
||||||
|
natively just replace system /bin/test and /bin/[ with the
|
||||||
|
above script.
|
||||||
|
|||||||
21
README
21
README
@@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
OpenSSL 0.9.7a Feb 19 2003
|
OpenSSL 0.9.7h-dev XX xxx XXXX
|
||||||
|
|
||||||
Copyright (c) 1998-2003 The OpenSSL Project
|
Copyright (c) 1998-2005 The OpenSSL Project
|
||||||
Copyright (c) 1995-1998 Eric A. Young, Tim J. Hudson
|
Copyright (c) 1995-1998 Eric A. Young, Tim J. Hudson
|
||||||
All rights reserved.
|
All rights reserved.
|
||||||
|
|
||||||
@@ -111,6 +111,8 @@
|
|||||||
should be contacted if that algorithm is to be used; their web page is
|
should be contacted if that algorithm is to be used; their web page is
|
||||||
http://www.ascom.ch/.
|
http://www.ascom.ch/.
|
||||||
|
|
||||||
|
The MDC2 algorithm is patented by IBM.
|
||||||
|
|
||||||
INSTALLATION
|
INSTALLATION
|
||||||
------------
|
------------
|
||||||
|
|
||||||
@@ -173,11 +175,17 @@
|
|||||||
textual explanation of what your patch does.
|
textual explanation of what your patch does.
|
||||||
|
|
||||||
Note: For legal reasons, contributions from the US can be accepted only
|
Note: For legal reasons, contributions from the US can be accepted only
|
||||||
if a TSA notification and a copy of the patch is sent to crypt@bis.doc.gov;
|
if a TSU notification and a copy of the patch are sent to crypt@bis.doc.gov
|
||||||
see http://www.bis.doc.gov/Encryption/PubAvailEncSourceCodeNofify.html [sic]
|
(formerly BXA) with a copy to the ENC Encryption Request Coordinator;
|
||||||
and http://w3.access.gpo.gov/bis/ear/pdf/740.pdf (EAR Section 740.13(e)).
|
please take some time to look at
|
||||||
|
http://www.bis.doc.gov/Encryption/PubAvailEncSourceCodeNofify.html [sic]
|
||||||
|
and
|
||||||
|
http://w3.access.gpo.gov/bis/ear/pdf/740.pdf (EAR Section 740.13(e))
|
||||||
|
for the details. If "your encryption source code is too large to serve as
|
||||||
|
an email attachment", they are glad to receive it by fax instead; hope you
|
||||||
|
have a cheap long-distance plan.
|
||||||
|
|
||||||
The preferred format for changes is "diff -u" output. You might
|
Our preferred format for changes is "diff -u" output. You might
|
||||||
generate it like this:
|
generate it like this:
|
||||||
|
|
||||||
# cd openssl-work
|
# cd openssl-work
|
||||||
@@ -185,3 +193,4 @@
|
|||||||
# ./Configure dist; make clean
|
# ./Configure dist; make clean
|
||||||
# cd ..
|
# cd ..
|
||||||
# diff -ur openssl-orig openssl-work > mydiffs.patch
|
# diff -ur openssl-orig openssl-work > mydiffs.patch
|
||||||
|
|
||||||
|
|||||||
24
STATUS
24
STATUS
@@ -1,12 +1,22 @@
|
|||||||
|
|
||||||
OpenSSL STATUS Last modified at
|
OpenSSL STATUS Last modified at
|
||||||
______________ $Date: 2003/02/19 12:33:52 $
|
______________ $Date: 2005/04/11 15:10:06 $
|
||||||
|
|
||||||
DEVELOPMENT STATE
|
DEVELOPMENT STATE
|
||||||
|
|
||||||
o OpenSSL 0.9.8: Under development...
|
o OpenSSL 0.9.8: Under development...
|
||||||
|
o OpenSSL 0.9.7g: Released on April 11th, 2005
|
||||||
|
o OpenSSL 0.9.7f: Released on March 22nd, 2005
|
||||||
|
o OpenSSL 0.9.7e: Released on October 25th, 2004
|
||||||
|
o OpenSSL 0.9.7d: Released on March 17th, 2004
|
||||||
|
o OpenSSL 0.9.7c: Released on September 30th, 2003
|
||||||
|
o OpenSSL 0.9.7b: Released on April 10th, 2003
|
||||||
o OpenSSL 0.9.7a: Released on February 19th, 2003
|
o OpenSSL 0.9.7a: Released on February 19th, 2003
|
||||||
o OpenSSL 0.9.7: Released on December 31st, 2002
|
o OpenSSL 0.9.7: Released on December 31st, 2002
|
||||||
|
o OpenSSL 0.9.6m: Released on March 17th, 2004
|
||||||
|
o OpenSSL 0.9.6l: Released on November 4th, 2003
|
||||||
|
o OpenSSL 0.9.6k: Released on September 30th, 2003
|
||||||
|
o OpenSSL 0.9.6j: Released on April 10th, 2003
|
||||||
o OpenSSL 0.9.6i: Released on February 19th, 2003
|
o OpenSSL 0.9.6i: Released on February 19th, 2003
|
||||||
o OpenSSL 0.9.6h: Released on December 5th, 2002
|
o OpenSSL 0.9.6h: Released on December 5th, 2002
|
||||||
o OpenSSL 0.9.6g: Released on August 9th, 2002
|
o OpenSSL 0.9.6g: Released on August 9th, 2002
|
||||||
@@ -29,17 +39,7 @@
|
|||||||
|
|
||||||
RELEASE SHOWSTOPPERS
|
RELEASE SHOWSTOPPERS
|
||||||
|
|
||||||
o [2002-11-21]
|
o
|
||||||
PR 343 mentions that scrubbing memory with 'memset(ptr, 0, n)' may
|
|
||||||
be optimized away in modern compilers. This is definitely not good
|
|
||||||
and needs to be fixed immediately. The formula to use is presented
|
|
||||||
in:
|
|
||||||
|
|
||||||
http://online.securityfocus.com/archive/82/297918/2002-10-27/2002-11-02/0
|
|
||||||
|
|
||||||
The problem report that mentions this is:
|
|
||||||
|
|
||||||
https://www.aet.TU-Cottbus.DE/rt2/Ticket/Display.html?id=343
|
|
||||||
|
|
||||||
AVAILABLE PATCHES
|
AVAILABLE PATCHES
|
||||||
|
|
||||||
|
|||||||
34
VMS/VMSify-conf.pl
Normal file
34
VMS/VMSify-conf.pl
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
#! /usr/bin/perl
|
||||||
|
|
||||||
|
use strict;
|
||||||
|
use warnings;
|
||||||
|
|
||||||
|
my @directory_vars = ( "dir", "certs", "crl_dir", "new_certs_dir" );
|
||||||
|
my @file_vars = ( "database", "certificate", "serial", "crlnumber",
|
||||||
|
"crl", "private_key", "RANDFILE" );
|
||||||
|
while(<STDIN>) {
|
||||||
|
chomp;
|
||||||
|
foreach my $d (@directory_vars) {
|
||||||
|
if (/^(\s*\#?\s*${d}\s*=\s*)\.\/([^\s\#]*)([\s\#].*)$/) {
|
||||||
|
$_ = "$1sys\\\$disk:\[.$2$3";
|
||||||
|
} elsif (/^(\s*\#?\s*${d}\s*=\s*)(\w[^\s\#]*)([\s\#].*)$/) {
|
||||||
|
$_ = "$1sys\\\$disk:\[.$2$3";
|
||||||
|
}
|
||||||
|
s/^(\s*\#?\s*${d}\s*=\s*\$\w+)\/([^\s\#]*)([\s\#].*)$/$1.$2\]$3/;
|
||||||
|
while(/^(\s*\#?\s*${d}\s*=\s*(\$\w+\.|sys\\\$disk:\[\.)[\w\.]+)\/([^\]]*)\](.*)$/) {
|
||||||
|
$_ = "$1.$3]$4";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
foreach my $f (@file_vars) {
|
||||||
|
s/^(\s*\#?\s*${f}\s*=\s*)\.\/(.*)$/$1sys\\\$disk:\[\/$2/;
|
||||||
|
while(/^(\s*\#?\s*${f}\s*=\s*(\$\w+|sys\\\$disk:\[)[^\/]*)\/(\w+\/[^\s\#]*)([\s\#].*)$/) {
|
||||||
|
$_ = "$1.$3$4";
|
||||||
|
}
|
||||||
|
if (/^(\s*\#?\s*${f}\s*=\s*(\$\w+|sys\\\$disk:\[)[^\/]*)\/(\w+)([\s\#].*)$/) {
|
||||||
|
$_ = "$1]$3.$4";
|
||||||
|
} elsif (/^(\s*\#?\s*${f}\s*=\s*(\$\w+|sys\\\$disk:\[)[^\/]*)\/([^\s\#]*)([\s\#].*)$/) {
|
||||||
|
$_ = "$1]$3$4";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
print $_,"\n";
|
||||||
|
}
|
||||||
@@ -266,6 +266,14 @@ $ falsesum = falsesum + 1
|
|||||||
$ endif
|
$ endif
|
||||||
$ if plat_entry .eqs. "VMS" then truesum = truesum + 1
|
$ if plat_entry .eqs. "VMS" then truesum = truesum + 1
|
||||||
$ if plat_entry .eqs. "!VMS" then falsesum = falsesum + 1
|
$ if plat_entry .eqs. "!VMS" then falsesum = falsesum + 1
|
||||||
|
$ if f$trnlnm("OPENSSL_FIPS") .nes. ""
|
||||||
|
$ then
|
||||||
|
$ if plat_entry .eqs. "OPENSSL_FIPS" then truesum = truesum + 1
|
||||||
|
$ if plat_entry .eqs. "!OPENSSL_FIPS" then falsesum = falsesum + 1
|
||||||
|
$ else
|
||||||
|
$ if plat_entry .eqs. "OPENSSL_FIPS" then falsesum = falsesum + 1
|
||||||
|
$ if plat_entry .eqs. "!OPENSSL_FIPS" then truesum = truesum + 1
|
||||||
|
$ endif
|
||||||
$ goto loop1
|
$ goto loop1
|
||||||
$ endif
|
$ endif
|
||||||
$ endloop1:
|
$ endloop1:
|
||||||
|
|||||||
@@ -3,3 +3,6 @@ Makefile.save
|
|||||||
der_chop
|
der_chop
|
||||||
der_chop.bak
|
der_chop.bak
|
||||||
CA.pl
|
CA.pl
|
||||||
|
openssl.sha1
|
||||||
|
*.flc
|
||||||
|
semantic.cache
|
||||||
|
|||||||
@@ -36,13 +36,21 @@
|
|||||||
# default openssl.cnf file has setup as per the following
|
# default openssl.cnf file has setup as per the following
|
||||||
# demoCA ... where everything is stored
|
# demoCA ... where everything is stored
|
||||||
|
|
||||||
|
my $openssl;
|
||||||
|
if(defined $ENV{OPENSSL}) {
|
||||||
|
$openssl = $ENV{OPENSSL};
|
||||||
|
} else {
|
||||||
|
$openssl = "openssl";
|
||||||
|
$ENV{OPENSSL} = $openssl;
|
||||||
|
}
|
||||||
|
|
||||||
$SSLEAY_CONFIG=$ENV{"SSLEAY_CONFIG"};
|
$SSLEAY_CONFIG=$ENV{"SSLEAY_CONFIG"};
|
||||||
$DAYS="-days 365";
|
$DAYS="-days 365";
|
||||||
$REQ="openssl req $SSLEAY_CONFIG";
|
$REQ="$openssl req $SSLEAY_CONFIG";
|
||||||
$CA="openssl ca $SSLEAY_CONFIG";
|
$CA="$openssl ca $SSLEAY_CONFIG";
|
||||||
$VERIFY="openssl verify";
|
$VERIFY="$openssl verify";
|
||||||
$X509="openssl x509";
|
$X509="$openssl x509";
|
||||||
$PKCS12="openssl pkcs12";
|
$PKCS12="$openssl pkcs12";
|
||||||
|
|
||||||
$CATOP="./demoCA";
|
$CATOP="./demoCA";
|
||||||
$CAKEY="cakey.pem";
|
$CAKEY="cakey.pem";
|
||||||
@@ -82,9 +90,6 @@ foreach (@ARGV) {
|
|||||||
mkdir "${CATOP}/crl", $DIRMODE ;
|
mkdir "${CATOP}/crl", $DIRMODE ;
|
||||||
mkdir "${CATOP}/newcerts", $DIRMODE;
|
mkdir "${CATOP}/newcerts", $DIRMODE;
|
||||||
mkdir "${CATOP}/private", $DIRMODE;
|
mkdir "${CATOP}/private", $DIRMODE;
|
||||||
open OUT, ">${CATOP}/serial";
|
|
||||||
print OUT "01\n";
|
|
||||||
close OUT;
|
|
||||||
open OUT, ">${CATOP}/index.txt";
|
open OUT, ">${CATOP}/index.txt";
|
||||||
close OUT;
|
close OUT;
|
||||||
}
|
}
|
||||||
@@ -106,6 +111,10 @@ foreach (@ARGV) {
|
|||||||
$RET=$?;
|
$RET=$?;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (! -f "${CATOP}/serial" ) {
|
||||||
|
system ("$X509 -in ${CATOP}/$CACERT -noout "
|
||||||
|
. "-next_serial -out ${CATOP}/serial");
|
||||||
|
}
|
||||||
} elsif (/^-pkcs12$/) {
|
} elsif (/^-pkcs12$/) {
|
||||||
my $cname = $ARGV[1];
|
my $cname = $ARGV[1];
|
||||||
$cname = "My Certificate" unless defined $cname;
|
$cname = "My Certificate" unless defined $cname;
|
||||||
|
|||||||
10
apps/CA.sh
10
apps/CA.sh
@@ -30,11 +30,13 @@
|
|||||||
# default openssl.cnf file has setup as per the following
|
# default openssl.cnf file has setup as per the following
|
||||||
# demoCA ... where everything is stored
|
# demoCA ... where everything is stored
|
||||||
|
|
||||||
|
if [ -z "$OPENSSL" ]; then OPENSSL=openssl; fi
|
||||||
|
|
||||||
DAYS="-days 365"
|
DAYS="-days 365"
|
||||||
REQ="openssl req $SSLEAY_CONFIG"
|
REQ="$OPENSSL req $SSLEAY_CONFIG"
|
||||||
CA="openssl ca $SSLEAY_CONFIG"
|
CA="$OPENSSL ca $SSLEAY_CONFIG"
|
||||||
VERIFY="openssl verify"
|
VERIFY="$OPENSSL verify"
|
||||||
X509="openssl x509"
|
X509="$OPENSSL x509"
|
||||||
|
|
||||||
CATOP=./demoCA
|
CATOP=./demoCA
|
||||||
CAKEY=./cakey.pem
|
CAKEY=./cakey.pem
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#
|
#
|
||||||
# apps/Makefile.ssl
|
# apps/Makefile
|
||||||
#
|
#
|
||||||
|
|
||||||
DIR= apps
|
DIR= apps
|
||||||
@@ -10,10 +10,9 @@ CFLAG= -g -static
|
|||||||
INSTALL_PREFIX=
|
INSTALL_PREFIX=
|
||||||
INSTALLTOP= /usr/local/ssl
|
INSTALLTOP= /usr/local/ssl
|
||||||
OPENSSLDIR= /usr/local/ssl
|
OPENSSLDIR= /usr/local/ssl
|
||||||
MAKE= make -f Makefile.ssl
|
|
||||||
MAKEDEPPROG= makedepend
|
MAKEDEPPROG= makedepend
|
||||||
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
||||||
MAKEFILE= Makefile.ssl
|
MAKEFILE= Makefile
|
||||||
PERL= perl
|
PERL= perl
|
||||||
RM= rm -f
|
RM= rm -f
|
||||||
# KRB5 stuff
|
# KRB5 stuff
|
||||||
@@ -37,7 +36,7 @@ LIBSSL=-L.. -lssl
|
|||||||
|
|
||||||
PROGRAM= openssl
|
PROGRAM= openssl
|
||||||
|
|
||||||
SCRIPTS=CA.sh CA.pl der_chop
|
SCRIPTS=CA.sh CA.pl
|
||||||
|
|
||||||
EXE= $(PROGRAM)$(EXE_EXT)
|
EXE= $(PROGRAM)$(EXE_EXT)
|
||||||
|
|
||||||
@@ -45,7 +44,7 @@ E_EXE= verify asn1pars req dgst dh dhparam enc passwd gendh errstr \
|
|||||||
ca crl rsa rsautl dsa dsaparam \
|
ca crl rsa rsautl dsa dsaparam \
|
||||||
x509 genrsa gendsa s_server s_client speed \
|
x509 genrsa gendsa s_server s_client speed \
|
||||||
s_time version pkcs7 crl2pkcs7 sess_id ciphers nseq pkcs12 \
|
s_time version pkcs7 crl2pkcs7 sess_id ciphers nseq pkcs12 \
|
||||||
pkcs8 spkac smime rand engine ocsp
|
pkcs8 spkac smime rand engine ocsp prime
|
||||||
|
|
||||||
PROGS= $(PROGRAM).c
|
PROGS= $(PROGRAM).c
|
||||||
|
|
||||||
@@ -61,14 +60,14 @@ E_OBJ= verify.o asn1pars.o req.o dgst.o dh.o dhparam.o enc.o passwd.o gendh.o er
|
|||||||
rsa.o rsautl.o dsa.o dsaparam.o \
|
rsa.o rsautl.o dsa.o dsaparam.o \
|
||||||
x509.o genrsa.o gendsa.o s_server.o s_client.o speed.o \
|
x509.o genrsa.o gendsa.o s_server.o s_client.o speed.o \
|
||||||
s_time.o $(A_OBJ) $(S_OBJ) $(RAND_OBJ) version.o sess_id.o \
|
s_time.o $(A_OBJ) $(S_OBJ) $(RAND_OBJ) version.o sess_id.o \
|
||||||
ciphers.o nseq.o pkcs12.o pkcs8.o spkac.o smime.o rand.o engine.o ocsp.o
|
ciphers.o nseq.o pkcs12.o pkcs8.o spkac.o smime.o rand.o engine.o ocsp.o prime.o
|
||||||
|
|
||||||
E_SRC= verify.c asn1pars.c req.c dgst.c dh.c enc.c passwd.c gendh.c errstr.c ca.c \
|
E_SRC= verify.c asn1pars.c req.c dgst.c dh.c enc.c passwd.c gendh.c errstr.c ca.c \
|
||||||
pkcs7.c crl2p7.c crl.c \
|
pkcs7.c crl2p7.c crl.c \
|
||||||
rsa.c rsautl.c dsa.c dsaparam.c \
|
rsa.c rsautl.c dsa.c dsaparam.c \
|
||||||
x509.c genrsa.c gendsa.c s_server.c s_client.c speed.c \
|
x509.c genrsa.c gendsa.c s_server.c s_client.c speed.c \
|
||||||
s_time.c $(A_SRC) $(S_SRC) $(RAND_SRC) version.c sess_id.c \
|
s_time.c $(A_SRC) $(S_SRC) $(RAND_SRC) version.c sess_id.c \
|
||||||
ciphers.c nseq.c pkcs12.c pkcs8.c spkac.c smime.c rand.c engine.c ocsp.c
|
ciphers.c nseq.c pkcs12.c pkcs8.c spkac.c smime.c rand.c engine.c ocsp.c prime.c
|
||||||
|
|
||||||
SRC=$(E_SRC)
|
SRC=$(E_SRC)
|
||||||
|
|
||||||
@@ -84,16 +83,17 @@ top:
|
|||||||
|
|
||||||
all: exe
|
all: exe
|
||||||
|
|
||||||
exe: $(PROGRAM)
|
exe: $(EXE)
|
||||||
|
|
||||||
req: sreq.o $(A_OBJ) $(DLIBCRYPTO)
|
req: sreq.o $(A_OBJ) $(DLIBCRYPTO)
|
||||||
|
LD_LIBRARY_PATH=..:$$LD_LIBRARY_PATH \
|
||||||
$(CC) -o req $(CFLAG) sreq.o $(A_OBJ) $(RAND_OBJ) $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS)
|
$(CC) -o req $(CFLAG) sreq.o $(A_OBJ) $(RAND_OBJ) $(PEX_LIBS) $(LIBCRYPTO) $(EX_LIBS)
|
||||||
|
|
||||||
sreq.o: req.c
|
sreq.o: req.c
|
||||||
$(CC) -c $(INCLUDES) $(CFLAG) -o sreq.o req.c
|
$(CC) -c $(INCLUDES) $(CFLAG) -o sreq.o req.c
|
||||||
|
|
||||||
files:
|
files:
|
||||||
$(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
|
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
|
||||||
|
|
||||||
install:
|
install:
|
||||||
@for i in $(EXE); \
|
@for i in $(EXE); \
|
||||||
@@ -120,7 +120,6 @@ tags:
|
|||||||
tests:
|
tests:
|
||||||
|
|
||||||
links:
|
links:
|
||||||
@$(TOP)/util/point.sh Makefile.ssl Makefile
|
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
lint -DLINT $(INCLUDES) $(SRC)>fluff
|
lint -DLINT $(INCLUDES) $(SRC)>fluff
|
||||||
@@ -142,18 +141,22 @@ $(DLIBSSL):
|
|||||||
$(DLIBCRYPTO):
|
$(DLIBCRYPTO):
|
||||||
(cd ..; $(MAKE) DIRS=crypto all)
|
(cd ..; $(MAKE) DIRS=crypto all)
|
||||||
|
|
||||||
$(PROGRAM): progs.h $(E_OBJ) $(PROGRAM).o $(DLIBCRYPTO) $(DLIBSSL)
|
$(EXE): progs.h $(E_OBJ) $(PROGRAM).o $(DLIBCRYPTO) $(DLIBSSL)
|
||||||
$(RM) $(PROGRAM)
|
$(RM) $(EXE)
|
||||||
if [ "$(SHLIB_TARGET)" = "hpux-shared" -o "$(SHLIB_TARGET)" = "darwin-shared" ] ; then \
|
if [ "$(SHLIB_TARGET)" = "darwin-shared" ] ; then \
|
||||||
$(CC) -o $(PROGRAM) $(CFLAGS) $(PROGRAM).o $(E_OBJ) $(PEX_LIBS) $(DLIBSSL) $(LIBKRB5) $(DLIBCRYPTO) $(EX_LIBS) ; \
|
set -x; $${CC:-$(CC)} -o $(EXE) $(CFLAGS) $(PROGRAM).o $(E_OBJ) $(PEX_LIBS) $(DLIBSSL) $(LIBKRB5) $(DLIBCRYPTO) $(EX_LIBS) ; \
|
||||||
|
elif [ -z "$(SHARED_LIBS)" ]; then \
|
||||||
|
set -x; $${CC:-$(CC)} -o $(EXE) $(CFLAGS) $(PROGRAM).o $(E_OBJ) $(PEX_LIBS) $(LIBSSL) $(LIBKRB5) $(LIBCRYPTO) $(EX_LIBS) ; \
|
||||||
else \
|
else \
|
||||||
$(CC) -o $(PROGRAM) $(CFLAGS) $(PROGRAM).o $(E_OBJ) $(PEX_LIBS) $(LIBSSL) $(LIBKRB5) $(LIBCRYPTO) $(EX_LIBS) ; \
|
set -x; LD_LIBRARY_PATH=..:$$LD_LIBRARY_PATH \
|
||||||
|
$(CC) -o $(EXE) $(CFLAGS) $(PROGRAM).o $(E_OBJ) $(PEX_LIBS) $(LIBSSL) $(LIBKRB5) $(LIBCRYPTO) $(EX_LIBS) ; \
|
||||||
fi
|
fi
|
||||||
-(cd ..; OPENSSL="`pwd`/apps/openssl"; export OPENSSL; \
|
if egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null; then \
|
||||||
LIBPATH="`pwd`"; LD_LIBRARY_PATH="`pwd`"; DYLD_LIBRARY_PATH="`pwd`"; SHLIB_PATH="`pwd`"; \
|
TOP=$(TOP) $(TOP)/fips/openssl_fips_fingerprint $(TOP)/libcrypto.a $(EXE); \
|
||||||
if [ "$(PLATFORM)" = "Cygwin" ]; then PATH="`pwd`:$$PATH"; fi; \
|
fi
|
||||||
export LD_LIBRARY_PATH DYLD_LIBRARY_PATH SHLIB_PATH LIBPATH PATH; \
|
-(cd ..; \
|
||||||
$(PERL) tools/c_rehash certs)
|
OPENSSL="`pwd`/util/opensslwrap.sh"; export OPENSSL; \
|
||||||
|
$(PERL) tools/c_rehash certs)
|
||||||
|
|
||||||
progs.h: progs.pl
|
progs.h: progs.pl
|
||||||
$(PERL) progs.pl $(E_EXE) >progs.h
|
$(PERL) progs.pl $(E_EXE) >progs.h
|
||||||
@@ -339,21 +342,22 @@ dgst.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
|||||||
dgst.o: ../include/openssl/des_old.h ../include/openssl/dh.h
|
dgst.o: ../include/openssl/des_old.h ../include/openssl/dh.h
|
||||||
dgst.o: ../include/openssl/dsa.h ../include/openssl/e_os2.h
|
dgst.o: ../include/openssl/dsa.h ../include/openssl/e_os2.h
|
||||||
dgst.o: ../include/openssl/engine.h ../include/openssl/err.h
|
dgst.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||||
dgst.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
dgst.o: ../include/openssl/evp.h ../include/openssl/hmac.h
|
||||||
dgst.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
dgst.o: ../include/openssl/idea.h ../include/openssl/lhash.h
|
||||||
dgst.o: ../include/openssl/md4.h ../include/openssl/md5.h
|
dgst.o: ../include/openssl/md2.h ../include/openssl/md4.h
|
||||||
dgst.o: ../include/openssl/mdc2.h ../include/openssl/obj_mac.h
|
dgst.o: ../include/openssl/md5.h ../include/openssl/mdc2.h
|
||||||
dgst.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h
|
dgst.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
||||||
dgst.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
dgst.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
dgst.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
dgst.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
dgst.o: ../include/openssl/pkcs7.h ../include/openssl/rand.h
|
dgst.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
dgst.o: ../include/openssl/rc2.h ../include/openssl/rc4.h
|
dgst.o: ../include/openssl/rand.h ../include/openssl/rc2.h
|
||||||
dgst.o: ../include/openssl/rc5.h ../include/openssl/ripemd.h
|
dgst.o: ../include/openssl/rc4.h ../include/openssl/rc5.h
|
||||||
dgst.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
|
dgst.o: ../include/openssl/ripemd.h ../include/openssl/rsa.h
|
||||||
dgst.o: ../include/openssl/sha.h ../include/openssl/stack.h
|
dgst.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
||||||
dgst.o: ../include/openssl/symhacks.h ../include/openssl/txt_db.h
|
dgst.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
dgst.o: ../include/openssl/ui.h ../include/openssl/ui_compat.h
|
dgst.o: ../include/openssl/txt_db.h ../include/openssl/ui.h
|
||||||
dgst.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h dgst.c
|
dgst.o: ../include/openssl/ui_compat.h ../include/openssl/x509.h
|
||||||
|
dgst.o: ../include/openssl/x509_vfy.h apps.h dgst.c
|
||||||
dh.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
dh.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
||||||
dh.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
dh.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
||||||
dh.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
dh.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
@@ -632,24 +636,25 @@ openssl.o: ../include/openssl/des.h ../include/openssl/des_old.h
|
|||||||
openssl.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
openssl.o: ../include/openssl/dh.h ../include/openssl/dsa.h
|
||||||
openssl.o: ../include/openssl/e_os2.h ../include/openssl/engine.h
|
openssl.o: ../include/openssl/e_os2.h ../include/openssl/engine.h
|
||||||
openssl.o: ../include/openssl/err.h ../include/openssl/evp.h
|
openssl.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||||
openssl.o: ../include/openssl/idea.h ../include/openssl/kssl.h
|
openssl.o: ../include/openssl/fips.h ../include/openssl/idea.h
|
||||||
openssl.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
openssl.o: ../include/openssl/kssl.h ../include/openssl/lhash.h
|
||||||
openssl.o: ../include/openssl/md4.h ../include/openssl/md5.h
|
openssl.o: ../include/openssl/md2.h ../include/openssl/md4.h
|
||||||
openssl.o: ../include/openssl/mdc2.h ../include/openssl/obj_mac.h
|
openssl.o: ../include/openssl/md5.h ../include/openssl/mdc2.h
|
||||||
openssl.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h
|
openssl.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
||||||
openssl.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
openssl.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
openssl.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
openssl.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
openssl.o: ../include/openssl/pkcs7.h ../include/openssl/rand.h
|
openssl.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
openssl.o: ../include/openssl/rc2.h ../include/openssl/rc4.h
|
openssl.o: ../include/openssl/rand.h ../include/openssl/rc2.h
|
||||||
openssl.o: ../include/openssl/rc5.h ../include/openssl/ripemd.h
|
openssl.o: ../include/openssl/rc4.h ../include/openssl/rc5.h
|
||||||
openssl.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
|
openssl.o: ../include/openssl/ripemd.h ../include/openssl/rsa.h
|
||||||
openssl.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
openssl.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
||||||
openssl.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
openssl.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
openssl.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
openssl.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
openssl.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
openssl.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
openssl.o: ../include/openssl/txt_db.h ../include/openssl/ui.h
|
openssl.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
||||||
openssl.o: ../include/openssl/ui_compat.h ../include/openssl/x509.h
|
openssl.o: ../include/openssl/ui.h ../include/openssl/ui_compat.h
|
||||||
openssl.o: ../include/openssl/x509_vfy.h apps.h openssl.c progs.h s_apps.h
|
openssl.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h
|
||||||
|
openssl.o: openssl.c progs.h s_apps.h
|
||||||
passwd.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
passwd.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
||||||
passwd.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
passwd.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
||||||
passwd.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
passwd.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
@@ -744,6 +749,28 @@ pkcs8.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
|||||||
pkcs8.o: ../include/openssl/txt_db.h ../include/openssl/ui.h
|
pkcs8.o: ../include/openssl/txt_db.h ../include/openssl/ui.h
|
||||||
pkcs8.o: ../include/openssl/ui_compat.h ../include/openssl/x509.h
|
pkcs8.o: ../include/openssl/ui_compat.h ../include/openssl/x509.h
|
||||||
pkcs8.o: ../include/openssl/x509_vfy.h apps.h pkcs8.c
|
pkcs8.o: ../include/openssl/x509_vfy.h apps.h pkcs8.c
|
||||||
|
prime.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
||||||
|
prime.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
||||||
|
prime.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
|
prime.o: ../include/openssl/cast.h ../include/openssl/conf.h
|
||||||
|
prime.o: ../include/openssl/crypto.h ../include/openssl/des.h
|
||||||
|
prime.o: ../include/openssl/des_old.h ../include/openssl/dh.h
|
||||||
|
prime.o: ../include/openssl/dsa.h ../include/openssl/e_os2.h
|
||||||
|
prime.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||||
|
prime.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||||
|
prime.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
||||||
|
prime.o: ../include/openssl/md4.h ../include/openssl/md5.h
|
||||||
|
prime.o: ../include/openssl/mdc2.h ../include/openssl/obj_mac.h
|
||||||
|
prime.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h
|
||||||
|
prime.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
||||||
|
prime.o: ../include/openssl/pkcs7.h ../include/openssl/rand.h
|
||||||
|
prime.o: ../include/openssl/rc2.h ../include/openssl/rc4.h
|
||||||
|
prime.o: ../include/openssl/rc5.h ../include/openssl/ripemd.h
|
||||||
|
prime.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
|
||||||
|
prime.o: ../include/openssl/sha.h ../include/openssl/stack.h
|
||||||
|
prime.o: ../include/openssl/symhacks.h ../include/openssl/txt_db.h
|
||||||
|
prime.o: ../include/openssl/ui.h ../include/openssl/ui_compat.h
|
||||||
|
prime.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h apps.h prime.c
|
||||||
rand.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
rand.o: ../e_os.h ../include/openssl/aes.h ../include/openssl/asn1.h
|
||||||
rand.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
rand.o: ../include/openssl/bio.h ../include/openssl/blowfish.h
|
||||||
rand.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
rand.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
761
apps/apps.c
761
apps/apps.c
@@ -126,24 +126,10 @@
|
|||||||
#include <openssl/engine.h>
|
#include <openssl/engine.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
|
||||||
#define strcasecmp _stricmp
|
|
||||||
#else
|
|
||||||
# ifdef NO_STRINGS_H
|
|
||||||
int strcasecmp();
|
|
||||||
# else
|
|
||||||
# include <strings.h>
|
|
||||||
# endif /* NO_STRINGS_H */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define NON_MAIN
|
#define NON_MAIN
|
||||||
#include "apps.h"
|
#include "apps.h"
|
||||||
#undef NON_MAIN
|
#undef NON_MAIN
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
|
||||||
# include "bss_file.c"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
char *name;
|
char *name;
|
||||||
unsigned long flag;
|
unsigned long flag;
|
||||||
@@ -344,60 +330,6 @@ void program_name(char *in, char *out, int size)
|
|||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WIN32
|
|
||||||
int WIN32_rename(char *from, char *to)
|
|
||||||
{
|
|
||||||
#ifndef OPENSSL_SYS_WINCE
|
|
||||||
/* Windows rename gives an error if 'to' exists, so delete it
|
|
||||||
* first and ignore file not found errror
|
|
||||||
*/
|
|
||||||
if((remove(to) != 0) && (errno != ENOENT))
|
|
||||||
return -1;
|
|
||||||
#undef rename
|
|
||||||
return rename(from, to);
|
|
||||||
#else
|
|
||||||
/* convert strings to UNICODE */
|
|
||||||
{
|
|
||||||
BOOL result = FALSE;
|
|
||||||
WCHAR* wfrom;
|
|
||||||
WCHAR* wto;
|
|
||||||
int i;
|
|
||||||
wfrom = malloc((strlen(from)+1)*2);
|
|
||||||
wto = malloc((strlen(to)+1)*2);
|
|
||||||
if (wfrom != NULL && wto != NULL)
|
|
||||||
{
|
|
||||||
for (i=0; i<(int)strlen(from)+1; i++)
|
|
||||||
wfrom[i] = (short)from[i];
|
|
||||||
for (i=0; i<(int)strlen(to)+1; i++)
|
|
||||||
wto[i] = (short)to[i];
|
|
||||||
result = MoveFile(wfrom, wto);
|
|
||||||
}
|
|
||||||
if (wfrom != NULL)
|
|
||||||
free(wfrom);
|
|
||||||
if (wto != NULL)
|
|
||||||
free(wto);
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
|
||||||
int VMS_strcasecmp(const char *str1, const char *str2)
|
|
||||||
{
|
|
||||||
while (*str1 && *str2)
|
|
||||||
{
|
|
||||||
int res = toupper(*str1) - toupper(*str2);
|
|
||||||
if (res) return res < 0 ? -1 : 1;
|
|
||||||
}
|
|
||||||
if (*str1)
|
|
||||||
return 1;
|
|
||||||
if (*str2)
|
|
||||||
return -1;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int chopup_args(ARGS *arg, char *buf, int *argc, char **argv[])
|
int chopup_args(ARGS *arg, char *buf, int *argc, char **argv[])
|
||||||
{
|
{
|
||||||
int num,len,i;
|
int num,len,i;
|
||||||
@@ -505,7 +437,7 @@ static int ui_read(UI *ui, UI_STRING *uis)
|
|||||||
{
|
{
|
||||||
const char *password =
|
const char *password =
|
||||||
((PW_CB_DATA *)UI_get0_user_data(ui))->password;
|
((PW_CB_DATA *)UI_get0_user_data(ui))->password;
|
||||||
if (password[0] != '\0')
|
if (password && password[0] != '\0')
|
||||||
{
|
{
|
||||||
UI_set_result(ui, uis, password);
|
UI_set_result(ui, uis, password);
|
||||||
return 1;
|
return 1;
|
||||||
@@ -529,7 +461,7 @@ static int ui_write(UI *ui, UI_STRING *uis)
|
|||||||
{
|
{
|
||||||
const char *password =
|
const char *password =
|
||||||
((PW_CB_DATA *)UI_get0_user_data(ui))->password;
|
((PW_CB_DATA *)UI_get0_user_data(ui))->password;
|
||||||
if (password[0] != '\0')
|
if (password && password[0] != '\0')
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
@@ -594,7 +526,7 @@ int password_callback(char *buf, int bufsiz, int verify,
|
|||||||
char *prompt = NULL;
|
char *prompt = NULL;
|
||||||
|
|
||||||
prompt = UI_construct_prompt(ui, "pass phrase",
|
prompt = UI_construct_prompt(ui, "pass phrase",
|
||||||
cb_data->prompt_info);
|
prompt_info);
|
||||||
|
|
||||||
ui_flags |= UI_INPUT_FLAG_DEFAULT_PWD;
|
ui_flags |= UI_INPUT_FLAG_DEFAULT_PWD;
|
||||||
UI_ctrl(ui, UI_CTRL_PRINT_ERRORS, 1, 0, 0);
|
UI_ctrl(ui, UI_CTRL_PRINT_ERRORS, 1, 0, 0);
|
||||||
@@ -743,6 +675,51 @@ int add_oid_section(BIO *err, CONF *conf)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int load_pkcs12(BIO *err, BIO *in, const char *desc,
|
||||||
|
pem_password_cb *pem_cb, void *cb_data,
|
||||||
|
EVP_PKEY **pkey, X509 **cert, STACK_OF(X509) **ca)
|
||||||
|
{
|
||||||
|
const char *pass;
|
||||||
|
char tpass[PEM_BUFSIZE];
|
||||||
|
int len, ret = 0;
|
||||||
|
PKCS12 *p12;
|
||||||
|
p12 = d2i_PKCS12_bio(in, NULL);
|
||||||
|
if (p12 == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(err, "Error loading PKCS12 file for %s\n", desc);
|
||||||
|
goto die;
|
||||||
|
}
|
||||||
|
/* See if an empty password will do */
|
||||||
|
if (PKCS12_verify_mac(p12, "", 0) || PKCS12_verify_mac(p12, NULL, 0))
|
||||||
|
pass = "";
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (!pem_cb)
|
||||||
|
pem_cb = (pem_password_cb *)password_callback;
|
||||||
|
len = pem_cb(tpass, PEM_BUFSIZE, 0, cb_data);
|
||||||
|
if (len < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(err, "Passpharse callback error for %s\n",
|
||||||
|
desc);
|
||||||
|
goto die;
|
||||||
|
}
|
||||||
|
if (len < PEM_BUFSIZE)
|
||||||
|
tpass[len] = 0;
|
||||||
|
if (!PKCS12_verify_mac(p12, tpass, len))
|
||||||
|
{
|
||||||
|
BIO_printf(err,
|
||||||
|
"Mac verify error (wrong password?) in PKCS12 file for %s\n", desc);
|
||||||
|
goto die;
|
||||||
|
}
|
||||||
|
pass = tpass;
|
||||||
|
}
|
||||||
|
ret = PKCS12_parse(p12, pass, pkey, cert, ca);
|
||||||
|
die:
|
||||||
|
if (p12)
|
||||||
|
PKCS12_free(p12);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
X509 *load_cert(BIO *err, const char *file, int format,
|
X509 *load_cert(BIO *err, const char *file, int format,
|
||||||
const char *pass, ENGINE *e, const char *cert_descrip)
|
const char *pass, ENGINE *e, const char *cert_descrip)
|
||||||
{
|
{
|
||||||
@@ -823,11 +800,9 @@ X509 *load_cert(BIO *err, const char *file, int format,
|
|||||||
(pem_password_cb *)password_callback, NULL);
|
(pem_password_cb *)password_callback, NULL);
|
||||||
else if (format == FORMAT_PKCS12)
|
else if (format == FORMAT_PKCS12)
|
||||||
{
|
{
|
||||||
PKCS12 *p12 = d2i_PKCS12_bio(cert, NULL);
|
if (!load_pkcs12(err, cert,cert_descrip, NULL, NULL,
|
||||||
|
NULL, &x, NULL))
|
||||||
PKCS12_parse(p12, NULL, NULL, &x, NULL);
|
goto end;
|
||||||
PKCS12_free(p12);
|
|
||||||
p12 = NULL;
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
BIO_printf(err,"bad input format specified for %s\n",
|
BIO_printf(err,"bad input format specified for %s\n",
|
||||||
@@ -906,11 +881,10 @@ EVP_PKEY *load_key(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
#endif
|
#endif
|
||||||
else if (format == FORMAT_PKCS12)
|
else if (format == FORMAT_PKCS12)
|
||||||
{
|
{
|
||||||
PKCS12 *p12 = d2i_PKCS12_bio(key, NULL);
|
if (!load_pkcs12(err, key, key_descrip,
|
||||||
|
(pem_password_cb *)password_callback, &cb_data,
|
||||||
PKCS12_parse(p12, pass, &pkey, NULL, NULL);
|
&pkey, NULL, NULL))
|
||||||
PKCS12_free(p12);
|
goto end;
|
||||||
p12 = NULL;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -1415,14 +1389,631 @@ int load_config(BIO *err, CONF *cnf)
|
|||||||
char *make_config_name()
|
char *make_config_name()
|
||||||
{
|
{
|
||||||
const char *t=X509_get_default_cert_area();
|
const char *t=X509_get_default_cert_area();
|
||||||
|
size_t len;
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
p=OPENSSL_malloc(strlen(t)+strlen(OPENSSL_CONF)+2);
|
len=strlen(t)+strlen(OPENSSL_CONF)+2;
|
||||||
strcpy(p,t);
|
p=OPENSSL_malloc(len);
|
||||||
|
BUF_strlcpy(p,t,len);
|
||||||
#ifndef OPENSSL_SYS_VMS
|
#ifndef OPENSSL_SYS_VMS
|
||||||
strcat(p,"/");
|
BUF_strlcat(p,"/",len);
|
||||||
#endif
|
#endif
|
||||||
strcat(p,OPENSSL_CONF);
|
BUF_strlcat(p,OPENSSL_CONF,len);
|
||||||
|
|
||||||
return p;
|
return p;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static unsigned long index_serial_hash(const char **a)
|
||||||
|
{
|
||||||
|
const char *n;
|
||||||
|
|
||||||
|
n=a[DB_serial];
|
||||||
|
while (*n == '0') n++;
|
||||||
|
return(lh_strhash(n));
|
||||||
|
}
|
||||||
|
|
||||||
|
static int index_serial_cmp(const char **a, const char **b)
|
||||||
|
{
|
||||||
|
const char *aa,*bb;
|
||||||
|
|
||||||
|
for (aa=a[DB_serial]; *aa == '0'; aa++);
|
||||||
|
for (bb=b[DB_serial]; *bb == '0'; bb++);
|
||||||
|
return(strcmp(aa,bb));
|
||||||
|
}
|
||||||
|
|
||||||
|
static int index_name_qual(char **a)
|
||||||
|
{ return(a[0][0] == 'V'); }
|
||||||
|
|
||||||
|
static unsigned long index_name_hash(const char **a)
|
||||||
|
{ return(lh_strhash(a[DB_name])); }
|
||||||
|
|
||||||
|
int index_name_cmp(const char **a, const char **b)
|
||||||
|
{ return(strcmp(a[DB_name],
|
||||||
|
b[DB_name])); }
|
||||||
|
|
||||||
|
static IMPLEMENT_LHASH_HASH_FN(index_serial_hash,const char **)
|
||||||
|
static IMPLEMENT_LHASH_COMP_FN(index_serial_cmp,const char **)
|
||||||
|
static IMPLEMENT_LHASH_HASH_FN(index_name_hash,const char **)
|
||||||
|
static IMPLEMENT_LHASH_COMP_FN(index_name_cmp,const char **)
|
||||||
|
|
||||||
|
#undef BSIZE
|
||||||
|
#define BSIZE 256
|
||||||
|
|
||||||
|
BIGNUM *load_serial(char *serialfile, int create, ASN1_INTEGER **retai)
|
||||||
|
{
|
||||||
|
BIO *in=NULL;
|
||||||
|
BIGNUM *ret=NULL;
|
||||||
|
MS_STATIC char buf[1024];
|
||||||
|
ASN1_INTEGER *ai=NULL;
|
||||||
|
|
||||||
|
ai=ASN1_INTEGER_new();
|
||||||
|
if (ai == NULL) goto err;
|
||||||
|
|
||||||
|
if ((in=BIO_new(BIO_s_file())) == NULL)
|
||||||
|
{
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (BIO_read_filename(in,serialfile) <= 0)
|
||||||
|
{
|
||||||
|
if (!create)
|
||||||
|
{
|
||||||
|
perror(serialfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
ret=BN_new();
|
||||||
|
if (ret == NULL || !rand_serial(ret, ai))
|
||||||
|
BIO_printf(bio_err, "Out of memory\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (!a2i_ASN1_INTEGER(in,ai,buf,1024))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"unable to load number from %s\n",
|
||||||
|
serialfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
ret=ASN1_INTEGER_to_BN(ai,NULL);
|
||||||
|
if (ret == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"error converting number from bin to BIGNUM\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ret && retai)
|
||||||
|
{
|
||||||
|
*retai = ai;
|
||||||
|
ai = NULL;
|
||||||
|
}
|
||||||
|
err:
|
||||||
|
if (in != NULL) BIO_free(in);
|
||||||
|
if (ai != NULL) ASN1_INTEGER_free(ai);
|
||||||
|
return(ret);
|
||||||
|
}
|
||||||
|
|
||||||
|
int save_serial(char *serialfile, char *suffix, BIGNUM *serial, ASN1_INTEGER **retai)
|
||||||
|
{
|
||||||
|
char buf[1][BSIZE];
|
||||||
|
BIO *out = NULL;
|
||||||
|
int ret=0;
|
||||||
|
ASN1_INTEGER *ai=NULL;
|
||||||
|
int j;
|
||||||
|
|
||||||
|
if (suffix == NULL)
|
||||||
|
j = strlen(serialfile);
|
||||||
|
else
|
||||||
|
j = strlen(serialfile) + strlen(suffix) + 1;
|
||||||
|
if (j >= BSIZE)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"file name too long\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (suffix == NULL)
|
||||||
|
BUF_strlcpy(buf[0], serialfile, BSIZE);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s.%s", serialfile, suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s-%s", serialfile, suffix);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: writing \"%s\"\n", buf[0]);
|
||||||
|
#endif
|
||||||
|
out=BIO_new(BIO_s_file());
|
||||||
|
if (out == NULL)
|
||||||
|
{
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
if (BIO_write_filename(out,buf[0]) <= 0)
|
||||||
|
{
|
||||||
|
perror(serialfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((ai=BN_to_ASN1_INTEGER(serial,NULL)) == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"error converting serial to ASN.1 format\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
i2a_ASN1_INTEGER(out,ai);
|
||||||
|
BIO_puts(out,"\n");
|
||||||
|
ret=1;
|
||||||
|
if (retai)
|
||||||
|
{
|
||||||
|
*retai = ai;
|
||||||
|
ai = NULL;
|
||||||
|
}
|
||||||
|
err:
|
||||||
|
if (out != NULL) BIO_free_all(out);
|
||||||
|
if (ai != NULL) ASN1_INTEGER_free(ai);
|
||||||
|
return(ret);
|
||||||
|
}
|
||||||
|
|
||||||
|
int rotate_serial(char *serialfile, char *new_suffix, char *old_suffix)
|
||||||
|
{
|
||||||
|
char buf[5][BSIZE];
|
||||||
|
int i,j;
|
||||||
|
struct stat sb;
|
||||||
|
|
||||||
|
i = strlen(serialfile) + strlen(old_suffix);
|
||||||
|
j = strlen(serialfile) + strlen(new_suffix);
|
||||||
|
if (i > j) j = i;
|
||||||
|
if (j + 1 >= BSIZE)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"file name too long\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s.%s",
|
||||||
|
serialfile, new_suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s-%s",
|
||||||
|
serialfile, new_suffix);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[1], sizeof buf[1], "%s.%s",
|
||||||
|
serialfile, old_suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[1], sizeof buf[1], "%s-%s",
|
||||||
|
serialfile, old_suffix);
|
||||||
|
#endif
|
||||||
|
if (stat(serialfile,&sb) < 0)
|
||||||
|
{
|
||||||
|
if (errno != ENOENT
|
||||||
|
#ifdef ENOTDIR
|
||||||
|
&& errno != ENOTDIR)
|
||||||
|
#endif
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: renaming \"%s\" to \"%s\"\n",
|
||||||
|
serialfile, buf[1]);
|
||||||
|
#endif
|
||||||
|
if (rename(serialfile,buf[1]) < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"unable to rename %s to %s\n",
|
||||||
|
serialfile, buf[1]);
|
||||||
|
perror("reason");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: renaming \"%s\" to \"%s\"\n",
|
||||||
|
buf[0],serialfile);
|
||||||
|
#endif
|
||||||
|
if (rename(buf[0],serialfile) < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"unable to rename %s to %s\n",
|
||||||
|
buf[0],serialfile);
|
||||||
|
perror("reason");
|
||||||
|
rename(buf[1],serialfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
err:
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int rand_serial(BIGNUM *b, ASN1_INTEGER *ai)
|
||||||
|
{
|
||||||
|
BIGNUM *btmp;
|
||||||
|
int ret = 0;
|
||||||
|
if (b)
|
||||||
|
btmp = b;
|
||||||
|
else
|
||||||
|
btmp = BN_new();
|
||||||
|
|
||||||
|
if (!btmp)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
if (!BN_pseudo_rand(btmp, SERIAL_RAND_BITS, 0, 0))
|
||||||
|
goto error;
|
||||||
|
if (ai && !BN_to_ASN1_INTEGER(btmp, ai))
|
||||||
|
goto error;
|
||||||
|
|
||||||
|
ret = 1;
|
||||||
|
|
||||||
|
error:
|
||||||
|
|
||||||
|
if (!b)
|
||||||
|
BN_free(btmp);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
CA_DB *load_index(char *dbfile, DB_ATTR *db_attr)
|
||||||
|
{
|
||||||
|
CA_DB *retdb = NULL;
|
||||||
|
TXT_DB *tmpdb = NULL;
|
||||||
|
BIO *in = BIO_new(BIO_s_file());
|
||||||
|
CONF *dbattr_conf = NULL;
|
||||||
|
char buf[1][BSIZE];
|
||||||
|
long errorline= -1;
|
||||||
|
|
||||||
|
if (in == NULL)
|
||||||
|
{
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
if (BIO_read_filename(in,dbfile) <= 0)
|
||||||
|
{
|
||||||
|
perror(dbfile);
|
||||||
|
BIO_printf(bio_err,"unable to open '%s'\n",dbfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
if ((tmpdb = TXT_DB_read(in,DB_NUMBER)) == NULL)
|
||||||
|
{
|
||||||
|
if (tmpdb != NULL) TXT_DB_free(tmpdb);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
BIO_snprintf(buf[0], sizeof buf[0], "%s.attr", dbfile);
|
||||||
|
#else
|
||||||
|
BIO_snprintf(buf[0], sizeof buf[0], "%s-attr", dbfile);
|
||||||
|
#endif
|
||||||
|
dbattr_conf = NCONF_new(NULL);
|
||||||
|
if (NCONF_load(dbattr_conf,buf[0],&errorline) <= 0)
|
||||||
|
{
|
||||||
|
if (errorline > 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"error on line %ld of db attribute file '%s'\n"
|
||||||
|
,errorline,buf[0]);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
NCONF_free(dbattr_conf);
|
||||||
|
dbattr_conf = NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((retdb = OPENSSL_malloc(sizeof(CA_DB))) == NULL)
|
||||||
|
{
|
||||||
|
fprintf(stderr, "Out of memory\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
retdb->db = tmpdb;
|
||||||
|
tmpdb = NULL;
|
||||||
|
if (db_attr)
|
||||||
|
retdb->attributes = *db_attr;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
retdb->attributes.unique_subject = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (dbattr_conf)
|
||||||
|
{
|
||||||
|
char *p = NCONF_get_string(dbattr_conf,NULL,"unique_subject");
|
||||||
|
if (p)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "DEBUG[load_index]: unique_subject = \"%s\"\n", p);
|
||||||
|
switch(*p)
|
||||||
|
{
|
||||||
|
case 'f': /* false */
|
||||||
|
case 'F': /* FALSE */
|
||||||
|
case 'n': /* no */
|
||||||
|
case 'N': /* NO */
|
||||||
|
retdb->attributes.unique_subject = 0;
|
||||||
|
break;
|
||||||
|
case 't': /* true */
|
||||||
|
case 'T': /* TRUE */
|
||||||
|
case 'y': /* yes */
|
||||||
|
case 'Y': /* YES */
|
||||||
|
default:
|
||||||
|
retdb->attributes.unique_subject = 1;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
err:
|
||||||
|
if (dbattr_conf) NCONF_free(dbattr_conf);
|
||||||
|
if (tmpdb) TXT_DB_free(tmpdb);
|
||||||
|
if (in) BIO_free_all(in);
|
||||||
|
return retdb;
|
||||||
|
}
|
||||||
|
|
||||||
|
int index_index(CA_DB *db)
|
||||||
|
{
|
||||||
|
if (!TXT_DB_create_index(db->db, DB_serial, NULL,
|
||||||
|
LHASH_HASH_FN(index_serial_hash),
|
||||||
|
LHASH_COMP_FN(index_serial_cmp)))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"error creating serial number index:(%ld,%ld,%ld)\n",
|
||||||
|
db->db->error,db->db->arg1,db->db->arg2);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (db->attributes.unique_subject
|
||||||
|
&& !TXT_DB_create_index(db->db, DB_name, index_name_qual,
|
||||||
|
LHASH_HASH_FN(index_name_hash),
|
||||||
|
LHASH_COMP_FN(index_name_cmp)))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"error creating name index:(%ld,%ld,%ld)\n",
|
||||||
|
db->db->error,db->db->arg1,db->db->arg2);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int save_index(char *dbfile, char *suffix, CA_DB *db)
|
||||||
|
{
|
||||||
|
char buf[3][BSIZE];
|
||||||
|
BIO *out = BIO_new(BIO_s_file());
|
||||||
|
int j;
|
||||||
|
|
||||||
|
if (out == NULL)
|
||||||
|
{
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
j = strlen(dbfile) + strlen(suffix);
|
||||||
|
if (j + 6 >= BSIZE)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"file name too long\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[2], sizeof buf[2], "%s.attr", dbfile);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[2], sizeof buf[2], "%s-attr", dbfile);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[1], sizeof buf[1], "%s.attr.%s", dbfile, suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[1], sizeof buf[1], "%s-attr-%s", dbfile, suffix);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s.%s", dbfile, suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s-%s", dbfile, suffix);
|
||||||
|
#endif
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: writing \"%s\"\n", buf[0]);
|
||||||
|
#endif
|
||||||
|
if (BIO_write_filename(out,buf[0]) <= 0)
|
||||||
|
{
|
||||||
|
perror(dbfile);
|
||||||
|
BIO_printf(bio_err,"unable to open '%s'\n", dbfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
j=TXT_DB_write(out,db->db);
|
||||||
|
if (j <= 0) goto err;
|
||||||
|
|
||||||
|
BIO_free(out);
|
||||||
|
|
||||||
|
out = BIO_new(BIO_s_file());
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: writing \"%s\"\n", buf[1]);
|
||||||
|
#endif
|
||||||
|
if (BIO_write_filename(out,buf[1]) <= 0)
|
||||||
|
{
|
||||||
|
perror(buf[2]);
|
||||||
|
BIO_printf(bio_err,"unable to open '%s'\n", buf[2]);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
BIO_printf(out,"unique_subject = %s\n",
|
||||||
|
db->attributes.unique_subject ? "yes" : "no");
|
||||||
|
BIO_free(out);
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
err:
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int rotate_index(char *dbfile, char *new_suffix, char *old_suffix)
|
||||||
|
{
|
||||||
|
char buf[5][BSIZE];
|
||||||
|
int i,j;
|
||||||
|
struct stat sb;
|
||||||
|
|
||||||
|
i = strlen(dbfile) + strlen(old_suffix);
|
||||||
|
j = strlen(dbfile) + strlen(new_suffix);
|
||||||
|
if (i > j) j = i;
|
||||||
|
if (j + 6 >= BSIZE)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"file name too long\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[4], sizeof buf[4], "%s.attr", dbfile);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[4], sizeof buf[4], "%s-attr", dbfile);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[2], sizeof buf[2], "%s.attr.%s",
|
||||||
|
dbfile, new_suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[2], sizeof buf[2], "%s-attr-%s",
|
||||||
|
dbfile, new_suffix);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s.%s",
|
||||||
|
dbfile, new_suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[0], sizeof buf[0], "%s-%s",
|
||||||
|
dbfile, new_suffix);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[1], sizeof buf[1], "%s.%s",
|
||||||
|
dbfile, old_suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[1], sizeof buf[1], "%s-%s",
|
||||||
|
dbfile, old_suffix);
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_SYS_VMS
|
||||||
|
j = BIO_snprintf(buf[3], sizeof buf[3], "%s.attr.%s",
|
||||||
|
dbfile, old_suffix);
|
||||||
|
#else
|
||||||
|
j = BIO_snprintf(buf[3], sizeof buf[3], "%s-attr-%s",
|
||||||
|
dbfile, old_suffix);
|
||||||
|
#endif
|
||||||
|
if (stat(dbfile,&sb) < 0)
|
||||||
|
{
|
||||||
|
if (errno != ENOENT
|
||||||
|
#ifdef ENOTDIR
|
||||||
|
&& errno != ENOTDIR)
|
||||||
|
#endif
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: renaming \"%s\" to \"%s\"\n",
|
||||||
|
dbfile, buf[1]);
|
||||||
|
#endif
|
||||||
|
if (rename(dbfile,buf[1]) < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"unable to rename %s to %s\n",
|
||||||
|
dbfile, buf[1]);
|
||||||
|
perror("reason");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: renaming \"%s\" to \"%s\"\n",
|
||||||
|
buf[0],dbfile);
|
||||||
|
#endif
|
||||||
|
if (rename(buf[0],dbfile) < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"unable to rename %s to %s\n",
|
||||||
|
buf[0],dbfile);
|
||||||
|
perror("reason");
|
||||||
|
rename(buf[1],dbfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
if (stat(buf[4],&sb) < 0)
|
||||||
|
{
|
||||||
|
if (errno != ENOENT
|
||||||
|
#ifdef ENOTDIR
|
||||||
|
&& errno != ENOTDIR)
|
||||||
|
#endif
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: renaming \"%s\" to \"%s\"\n",
|
||||||
|
buf[4],buf[3]);
|
||||||
|
#endif
|
||||||
|
if (rename(buf[4],buf[3]) < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"unable to rename %s to %s\n",
|
||||||
|
buf[4], buf[3]);
|
||||||
|
perror("reason");
|
||||||
|
rename(dbfile,buf[0]);
|
||||||
|
rename(buf[1],dbfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: renaming \"%s\" to \"%s\"\n",
|
||||||
|
buf[2],buf[4]);
|
||||||
|
#endif
|
||||||
|
if (rename(buf[2],buf[4]) < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"unable to rename %s to %s\n",
|
||||||
|
buf[2],buf[4]);
|
||||||
|
perror("reason");
|
||||||
|
rename(buf[3],buf[4]);
|
||||||
|
rename(dbfile,buf[0]);
|
||||||
|
rename(buf[1],dbfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
err:
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
void free_index(CA_DB *db)
|
||||||
|
{
|
||||||
|
if (db)
|
||||||
|
{
|
||||||
|
if (db->db) TXT_DB_free(db->db);
|
||||||
|
OPENSSL_free(db);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* This code MUST COME AFTER anything that uses rename() */
|
||||||
|
#ifdef OPENSSL_SYS_WIN32
|
||||||
|
int WIN32_rename(char *from, char *to)
|
||||||
|
{
|
||||||
|
#ifndef OPENSSL_SYS_WINCE
|
||||||
|
/* Windows rename gives an error if 'to' exists, so delete it
|
||||||
|
* first and ignore file not found errror
|
||||||
|
*/
|
||||||
|
if((remove(to) != 0) && (errno != ENOENT))
|
||||||
|
return -1;
|
||||||
|
#undef rename
|
||||||
|
return rename(from, to);
|
||||||
|
#else
|
||||||
|
/* convert strings to UNICODE */
|
||||||
|
{
|
||||||
|
BOOL result = FALSE;
|
||||||
|
WCHAR* wfrom;
|
||||||
|
WCHAR* wto;
|
||||||
|
int i;
|
||||||
|
wfrom = malloc((strlen(from)+1)*2);
|
||||||
|
wto = malloc((strlen(to)+1)*2);
|
||||||
|
if (wfrom != NULL && wto != NULL)
|
||||||
|
{
|
||||||
|
for (i=0; i<(int)strlen(from)+1; i++)
|
||||||
|
wfrom[i] = (short)from[i];
|
||||||
|
for (i=0; i<(int)strlen(to)+1; i++)
|
||||||
|
wto[i] = (short)to[i];
|
||||||
|
result = MoveFile(wfrom, wto);
|
||||||
|
}
|
||||||
|
if (wfrom != NULL)
|
||||||
|
free(wfrom);
|
||||||
|
if (wto != NULL)
|
||||||
|
free(wto);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|||||||
45
apps/apps.h
45
apps/apps.h
@@ -141,12 +141,6 @@ long app_RAND_load_files(char *file); /* `file' is a list of files to read,
|
|||||||
int WIN32_rename(char *oldname,char *newname);
|
int WIN32_rename(char *oldname,char *newname);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* VMS below version 7.0 doesn't have strcasecmp() */
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
|
||||||
#define strcasecmp(str1,str2) VMS_strcasecmp((str1),(str2))
|
|
||||||
int VMS_strcasecmp(const char *str1, const char *str2);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef MONOLITH
|
#ifndef MONOLITH
|
||||||
|
|
||||||
#define MAIN(a,v) main(a,v)
|
#define MAIN(a,v) main(a,v)
|
||||||
@@ -154,9 +148,11 @@ int VMS_strcasecmp(const char *str1, const char *str2);
|
|||||||
#ifndef NON_MAIN
|
#ifndef NON_MAIN
|
||||||
CONF *config=NULL;
|
CONF *config=NULL;
|
||||||
BIO *bio_err=NULL;
|
BIO *bio_err=NULL;
|
||||||
|
int in_FIPS_mode=0;
|
||||||
#else
|
#else
|
||||||
extern CONF *config;
|
extern CONF *config;
|
||||||
extern BIO *bio_err;
|
extern BIO *bio_err;
|
||||||
|
extern int in_FIPS_mode;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#else
|
#else
|
||||||
@@ -165,6 +161,7 @@ extern BIO *bio_err;
|
|||||||
extern CONF *config;
|
extern CONF *config;
|
||||||
extern char *default_config_file;
|
extern char *default_config_file;
|
||||||
extern BIO *bio_err;
|
extern BIO *bio_err;
|
||||||
|
extern int in_FIPS_mode;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -287,7 +284,39 @@ char *make_config_name(void);
|
|||||||
/* Functions defined in ca.c and also used in ocsp.c */
|
/* Functions defined in ca.c and also used in ocsp.c */
|
||||||
int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold,
|
int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold,
|
||||||
ASN1_GENERALIZEDTIME **pinvtm, char *str);
|
ASN1_GENERALIZEDTIME **pinvtm, char *str);
|
||||||
int make_serial_index(TXT_DB *db);
|
|
||||||
|
#define DB_type 0
|
||||||
|
#define DB_exp_date 1
|
||||||
|
#define DB_rev_date 2
|
||||||
|
#define DB_serial 3 /* index - unique */
|
||||||
|
#define DB_file 4
|
||||||
|
#define DB_name 5 /* index - unique when active and not disabled */
|
||||||
|
#define DB_NUMBER 6
|
||||||
|
|
||||||
|
#define DB_TYPE_REV 'R'
|
||||||
|
#define DB_TYPE_EXP 'E'
|
||||||
|
#define DB_TYPE_VAL 'V'
|
||||||
|
|
||||||
|
typedef struct db_attr_st
|
||||||
|
{
|
||||||
|
int unique_subject;
|
||||||
|
} DB_ATTR;
|
||||||
|
typedef struct ca_db_st
|
||||||
|
{
|
||||||
|
DB_ATTR attributes;
|
||||||
|
TXT_DB *db;
|
||||||
|
} CA_DB;
|
||||||
|
|
||||||
|
BIGNUM *load_serial(char *serialfile, int create, ASN1_INTEGER **retai);
|
||||||
|
int save_serial(char *serialfile, char *suffix, BIGNUM *serial, ASN1_INTEGER **retai);
|
||||||
|
int rotate_serial(char *serialfile, char *new_suffix, char *old_suffix);
|
||||||
|
int rand_serial(BIGNUM *b, ASN1_INTEGER *ai);
|
||||||
|
CA_DB *load_index(char *dbfile, DB_ATTR *dbattr);
|
||||||
|
int index_index(CA_DB *db);
|
||||||
|
int save_index(char *dbfile, char *suffix, CA_DB *db);
|
||||||
|
int rotate_index(char *dbfile, char *new_suffix, char *old_suffix);
|
||||||
|
void free_index(CA_DB *db);
|
||||||
|
int index_name_cmp(const char **a, const char **b);
|
||||||
|
|
||||||
X509_NAME *do_subject(char *str, long chtype);
|
X509_NAME *do_subject(char *str, long chtype);
|
||||||
|
|
||||||
@@ -310,4 +339,6 @@ X509_NAME *do_subject(char *str, long chtype);
|
|||||||
|
|
||||||
#define APP_PASS_LEN 1024
|
#define APP_PASS_LEN 1024
|
||||||
|
|
||||||
|
#define SERIAL_RAND_BITS 64
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -278,6 +278,7 @@ bad:
|
|||||||
tmplen=num;
|
tmplen=num;
|
||||||
for (i=0; i<sk_num(osk); i++)
|
for (i=0; i<sk_num(osk); i++)
|
||||||
{
|
{
|
||||||
|
int typ;
|
||||||
ASN1_TYPE *atmp;
|
ASN1_TYPE *atmp;
|
||||||
j=atoi(sk_value(osk,i));
|
j=atoi(sk_value(osk,i));
|
||||||
if (j == 0)
|
if (j == 0)
|
||||||
@@ -296,6 +297,15 @@ bad:
|
|||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
typ = ASN1_TYPE_get(at);
|
||||||
|
if ((typ == V_ASN1_OBJECT)
|
||||||
|
|| (typ == V_ASN1_NULL))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Can't parse %s type\n",
|
||||||
|
typ == V_ASN1_NULL ? "NULL" : "OBJECT");
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
/* hmm... this is a little evil but it works */
|
/* hmm... this is a little evil but it works */
|
||||||
tmpbuf=at->value.asn1_string->data;
|
tmpbuf=at->value.asn1_string->data;
|
||||||
tmplen=at->value.asn1_string->length;
|
tmplen=at->value.asn1_string->length;
|
||||||
@@ -304,7 +314,15 @@ bad:
|
|||||||
num=tmplen;
|
num=tmplen;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (length == 0) length=(unsigned int)num;
|
if (offset >= num)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error: offset too large\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
num -= offset;
|
||||||
|
|
||||||
|
if ((length == 0) || ((long)length > num)) length=(unsigned int)num;
|
||||||
if(derout) {
|
if(derout) {
|
||||||
if(BIO_write(derout, str + offset, length) != (int)length) {
|
if(BIO_write(derout, str + offset, length) != (int)length) {
|
||||||
BIO_printf(bio_err, "Error writing output\n");
|
BIO_printf(bio_err, "Error writing output\n");
|
||||||
|
|||||||
611
apps/ca.c
611
apps/ca.c
@@ -76,16 +76,6 @@
|
|||||||
#include <openssl/ocsp.h>
|
#include <openssl/ocsp.h>
|
||||||
#include <openssl/pem.h>
|
#include <openssl/pem.h>
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
|
||||||
#define strcasecmp _stricmp
|
|
||||||
#else
|
|
||||||
# ifdef NO_STRINGS_H
|
|
||||||
int strcasecmp();
|
|
||||||
# else
|
|
||||||
# include <strings.h>
|
|
||||||
# endif /* NO_STRINGS_H */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef W_OK
|
#ifndef W_OK
|
||||||
# ifdef OPENSSL_SYS_VMS
|
# ifdef OPENSSL_SYS_VMS
|
||||||
# if defined(__DECC)
|
# if defined(__DECC)
|
||||||
@@ -122,6 +112,7 @@
|
|||||||
#define ENV_NEW_CERTS_DIR "new_certs_dir"
|
#define ENV_NEW_CERTS_DIR "new_certs_dir"
|
||||||
#define ENV_CERTIFICATE "certificate"
|
#define ENV_CERTIFICATE "certificate"
|
||||||
#define ENV_SERIAL "serial"
|
#define ENV_SERIAL "serial"
|
||||||
|
#define ENV_CRLNUMBER "crlnumber"
|
||||||
#define ENV_CRL "crl"
|
#define ENV_CRL "crl"
|
||||||
#define ENV_PRIVATE_KEY "private_key"
|
#define ENV_PRIVATE_KEY "private_key"
|
||||||
#define ENV_RANDFILE "RANDFILE"
|
#define ENV_RANDFILE "RANDFILE"
|
||||||
@@ -143,18 +134,6 @@
|
|||||||
|
|
||||||
#define ENV_DATABASE "database"
|
#define ENV_DATABASE "database"
|
||||||
|
|
||||||
#define DB_type 0
|
|
||||||
#define DB_exp_date 1
|
|
||||||
#define DB_rev_date 2
|
|
||||||
#define DB_serial 3 /* index - unique */
|
|
||||||
#define DB_file 4
|
|
||||||
#define DB_name 5 /* index - unique for active */
|
|
||||||
#define DB_NUMBER 6
|
|
||||||
|
|
||||||
#define DB_TYPE_REV 'R'
|
|
||||||
#define DB_TYPE_EXP 'E'
|
|
||||||
#define DB_TYPE_VAL 'V'
|
|
||||||
|
|
||||||
/* Additional revocation information types */
|
/* Additional revocation information types */
|
||||||
|
|
||||||
#define REV_NONE 0 /* No addditional information */
|
#define REV_NONE 0 /* No addditional information */
|
||||||
@@ -211,43 +190,36 @@ extern int EF_ALIGNMENT;
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
static void lookup_fail(char *name,char *tag);
|
static void lookup_fail(char *name,char *tag);
|
||||||
static unsigned long index_serial_hash(const char **a);
|
|
||||||
static int index_serial_cmp(const char **a, const char **b);
|
|
||||||
static unsigned long index_name_hash(const char **a);
|
|
||||||
static int index_name_qual(char **a);
|
|
||||||
static int index_name_cmp(const char **a,const char **b);
|
|
||||||
static BIGNUM *load_serial(char *serialfile);
|
|
||||||
static int save_serial(char *serialfile, BIGNUM *serial);
|
|
||||||
static int certify(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509,
|
static int certify(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509,
|
||||||
const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,TXT_DB *db,
|
const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,CA_DB *db,
|
||||||
BIGNUM *serial, char *subj, int email_dn, char *startdate,
|
BIGNUM *serial, char *subj, int email_dn, char *startdate,
|
||||||
char *enddate, long days, int batch, char *ext_sect, CONF *conf,
|
char *enddate, long days, int batch, char *ext_sect, CONF *conf,
|
||||||
int verbose, unsigned long certopt, unsigned long nameopt,
|
int verbose, unsigned long certopt, unsigned long nameopt,
|
||||||
int default_op, int ext_copy);
|
int default_op, int ext_copy);
|
||||||
static int certify_cert(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509,
|
static int certify_cert(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509,
|
||||||
const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,
|
const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,
|
||||||
TXT_DB *db, BIGNUM *serial, char *subj, int email_dn,
|
CA_DB *db, BIGNUM *serial, char *subj, int email_dn,
|
||||||
char *startdate, char *enddate, long days, int batch,
|
char *startdate, char *enddate, long days, int batch,
|
||||||
char *ext_sect, CONF *conf,int verbose, unsigned long certopt,
|
char *ext_sect, CONF *conf,int verbose, unsigned long certopt,
|
||||||
unsigned long nameopt, int default_op, int ext_copy,
|
unsigned long nameopt, int default_op, int ext_copy,
|
||||||
ENGINE *e);
|
ENGINE *e);
|
||||||
static int certify_spkac(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509,
|
static int certify_spkac(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509,
|
||||||
const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,
|
const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,
|
||||||
TXT_DB *db, BIGNUM *serial,char *subj, int email_dn,
|
CA_DB *db, BIGNUM *serial,char *subj, int email_dn,
|
||||||
char *startdate, char *enddate, long days, char *ext_sect,
|
char *startdate, char *enddate, long days, char *ext_sect,
|
||||||
CONF *conf, int verbose, unsigned long certopt,
|
CONF *conf, int verbose, unsigned long certopt,
|
||||||
unsigned long nameopt, int default_op, int ext_copy);
|
unsigned long nameopt, int default_op, int ext_copy);
|
||||||
static int fix_data(int nid, int *type);
|
static int fix_data(int nid, int *type);
|
||||||
static void write_new_certificate(BIO *bp, X509 *x, int output_der, int notext);
|
static void write_new_certificate(BIO *bp, X509 *x, int output_der, int notext);
|
||||||
static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst,
|
static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst,
|
||||||
STACK_OF(CONF_VALUE) *policy, TXT_DB *db, BIGNUM *serial,char *subj,
|
STACK_OF(CONF_VALUE) *policy, CA_DB *db, BIGNUM *serial,char *subj,
|
||||||
int email_dn, char *startdate, char *enddate, long days, int batch,
|
int email_dn, char *startdate, char *enddate, long days, int batch,
|
||||||
int verbose, X509_REQ *req, char *ext_sect, CONF *conf,
|
int verbose, X509_REQ *req, char *ext_sect, CONF *conf,
|
||||||
unsigned long certopt, unsigned long nameopt, int default_op,
|
unsigned long certopt, unsigned long nameopt, int default_op,
|
||||||
int ext_copy);
|
int ext_copy);
|
||||||
static int do_revoke(X509 *x509, TXT_DB *db, int ext, char *extval);
|
static int do_revoke(X509 *x509, CA_DB *db, int ext, char *extval);
|
||||||
static int get_certificate_status(const char *ser_status, TXT_DB *db);
|
static int get_certificate_status(const char *ser_status, CA_DB *db);
|
||||||
static int do_updatedb(TXT_DB *db);
|
static int do_updatedb(CA_DB *db);
|
||||||
static int check_time_format(char *str);
|
static int check_time_format(char *str);
|
||||||
char *make_revocation_str(int rev_type, char *rev_arg);
|
char *make_revocation_str(int rev_type, char *rev_arg);
|
||||||
int make_revoked(X509_REVOKED *rev, char *str);
|
int make_revoked(X509_REVOKED *rev, char *str);
|
||||||
@@ -259,11 +231,6 @@ static char *section=NULL;
|
|||||||
static int preserve=0;
|
static int preserve=0;
|
||||||
static int msie_hack=0;
|
static int msie_hack=0;
|
||||||
|
|
||||||
static IMPLEMENT_LHASH_HASH_FN(index_serial_hash,const char **)
|
|
||||||
static IMPLEMENT_LHASH_COMP_FN(index_serial_cmp,const char **)
|
|
||||||
static IMPLEMENT_LHASH_HASH_FN(index_name_hash,const char **)
|
|
||||||
static IMPLEMENT_LHASH_COMP_FN(index_name_cmp,const char **)
|
|
||||||
|
|
||||||
|
|
||||||
int MAIN(int, char **);
|
int MAIN(int, char **);
|
||||||
|
|
||||||
@@ -271,6 +238,7 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
ENGINE *e = NULL;
|
ENGINE *e = NULL;
|
||||||
char *key=NULL,*passargin=NULL;
|
char *key=NULL,*passargin=NULL;
|
||||||
|
int create_ser = 0;
|
||||||
int free_key = 0;
|
int free_key = 0;
|
||||||
int total=0;
|
int total=0;
|
||||||
int total_done=0;
|
int total_done=0;
|
||||||
@@ -300,6 +268,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *outfile=NULL;
|
char *outfile=NULL;
|
||||||
char *outdir=NULL;
|
char *outdir=NULL;
|
||||||
char *serialfile=NULL;
|
char *serialfile=NULL;
|
||||||
|
char *crlnumberfile=NULL;
|
||||||
char *extensions=NULL;
|
char *extensions=NULL;
|
||||||
char *extfile=NULL;
|
char *extfile=NULL;
|
||||||
char *subj=NULL;
|
char *subj=NULL;
|
||||||
@@ -308,6 +277,7 @@ int MAIN(int argc, char **argv)
|
|||||||
int rev_type = REV_NONE;
|
int rev_type = REV_NONE;
|
||||||
char *rev_arg = NULL;
|
char *rev_arg = NULL;
|
||||||
BIGNUM *serial=NULL;
|
BIGNUM *serial=NULL;
|
||||||
|
BIGNUM *crlnumber=NULL;
|
||||||
char *startdate=NULL;
|
char *startdate=NULL;
|
||||||
char *enddate=NULL;
|
char *enddate=NULL;
|
||||||
long days=0;
|
long days=0;
|
||||||
@@ -320,14 +290,13 @@ int MAIN(int argc, char **argv)
|
|||||||
X509 *x=NULL;
|
X509 *x=NULL;
|
||||||
BIO *in=NULL,*out=NULL,*Sout=NULL,*Cout=NULL;
|
BIO *in=NULL,*out=NULL,*Sout=NULL,*Cout=NULL;
|
||||||
char *dbfile=NULL;
|
char *dbfile=NULL;
|
||||||
TXT_DB *db=NULL;
|
CA_DB *db=NULL;
|
||||||
X509_CRL *crl=NULL;
|
X509_CRL *crl=NULL;
|
||||||
X509_REVOKED *r=NULL;
|
X509_REVOKED *r=NULL;
|
||||||
ASN1_TIME *tmptm;
|
ASN1_TIME *tmptm;
|
||||||
ASN1_INTEGER *tmpser;
|
ASN1_INTEGER *tmpser;
|
||||||
char **pp,*p,*f;
|
char **pp,*p,*f;
|
||||||
int i,j;
|
int i,j;
|
||||||
long l;
|
|
||||||
const EVP_MD *dgst=NULL;
|
const EVP_MD *dgst=NULL;
|
||||||
STACK_OF(CONF_VALUE) *attribs=NULL;
|
STACK_OF(CONF_VALUE) *attribs=NULL;
|
||||||
STACK_OF(X509) *cert_sk=NULL;
|
STACK_OF(X509) *cert_sk=NULL;
|
||||||
@@ -339,6 +308,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *engine = NULL;
|
char *engine = NULL;
|
||||||
#endif
|
#endif
|
||||||
char *tofree=NULL;
|
char *tofree=NULL;
|
||||||
|
DB_ATTR db_attr;
|
||||||
|
|
||||||
#ifdef EFENCE
|
#ifdef EFENCE
|
||||||
EF_PROTECT_FREE=1;
|
EF_PROTECT_FREE=1;
|
||||||
@@ -568,10 +538,6 @@ bad:
|
|||||||
|
|
||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
e = setup_engine(bio_err, engine, 0);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*****************************************************************/
|
/*****************************************************************/
|
||||||
tofree=NULL;
|
tofree=NULL;
|
||||||
if (configfile == NULL) configfile = getenv("OPENSSL_CONF");
|
if (configfile == NULL) configfile = getenv("OPENSSL_CONF");
|
||||||
@@ -579,16 +545,19 @@ bad:
|
|||||||
if (configfile == NULL)
|
if (configfile == NULL)
|
||||||
{
|
{
|
||||||
const char *s=X509_get_default_cert_area();
|
const char *s=X509_get_default_cert_area();
|
||||||
|
size_t len;
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
#ifdef OPENSSL_SYS_VMS
|
||||||
tofree=OPENSSL_malloc(strlen(s)+sizeof(CONFIG_FILE));
|
len = strlen(s)+sizeof(CONFIG_FILE);
|
||||||
|
tofree=OPENSSL_malloc(len);
|
||||||
strcpy(tofree,s);
|
strcpy(tofree,s);
|
||||||
#else
|
#else
|
||||||
tofree=OPENSSL_malloc(strlen(s)+sizeof(CONFIG_FILE)+1);
|
len = strlen(s)+sizeof(CONFIG_FILE)+1;
|
||||||
strcpy(tofree,s);
|
tofree=OPENSSL_malloc(len);
|
||||||
strcat(tofree,"/");
|
BUF_strlcpy(tofree,s,len);
|
||||||
|
BUF_strlcat(tofree,"/",len);
|
||||||
#endif
|
#endif
|
||||||
strcat(tofree,CONFIG_FILE);
|
BUF_strlcat(tofree,CONFIG_FILE,len);
|
||||||
configfile=tofree;
|
configfile=tofree;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -613,6 +582,10 @@ bad:
|
|||||||
if (!load_config(bio_err, conf))
|
if (!load_config(bio_err, conf))
|
||||||
goto err;
|
goto err;
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
|
e = setup_engine(bio_err, engine, 0);
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Lets get the config section we are using */
|
/* Lets get the config section we are using */
|
||||||
if (section == NULL)
|
if (section == NULL)
|
||||||
{
|
{
|
||||||
@@ -660,6 +633,41 @@ bad:
|
|||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
app_RAND_load_file(randfile, bio_err, 0);
|
app_RAND_load_file(randfile, bio_err, 0);
|
||||||
|
|
||||||
|
db_attr.unique_subject = 1;
|
||||||
|
p = NCONF_get_string(conf, section, "unique_subject");
|
||||||
|
if (p)
|
||||||
|
{
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: unique_subject = \"%s\"\n", p);
|
||||||
|
#endif
|
||||||
|
switch(*p)
|
||||||
|
{
|
||||||
|
case 'f': /* false */
|
||||||
|
case 'F': /* FALSE */
|
||||||
|
case 'n': /* no */
|
||||||
|
case 'N': /* NO */
|
||||||
|
db_attr.unique_subject = 0;
|
||||||
|
break;
|
||||||
|
case 't': /* true */
|
||||||
|
case 'T': /* TRUE */
|
||||||
|
case 'y': /* yes */
|
||||||
|
case 'Y': /* YES */
|
||||||
|
default:
|
||||||
|
db_attr.unique_subject = 1;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
ERR_clear_error();
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
if (!p)
|
||||||
|
BIO_printf(bio_err, "DEBUG: unique_subject undefined\n", p);
|
||||||
|
#endif
|
||||||
|
#ifdef RL_DEBUG
|
||||||
|
BIO_printf(bio_err, "DEBUG: configured unique_subject is %d\n",
|
||||||
|
db_attr.unique_subject);
|
||||||
|
#endif
|
||||||
|
|
||||||
in=BIO_new(BIO_s_file());
|
in=BIO_new(BIO_s_file());
|
||||||
out=BIO_new(BIO_s_file());
|
out=BIO_new(BIO_s_file());
|
||||||
Sout=BIO_new(BIO_s_file());
|
Sout=BIO_new(BIO_s_file());
|
||||||
@@ -679,17 +687,10 @@ bad:
|
|||||||
lookup_fail(section,ENV_DATABASE);
|
lookup_fail(section,ENV_DATABASE);
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
if (BIO_read_filename(in,dbfile) <= 0)
|
db = load_index(dbfile,&db_attr);
|
||||||
{
|
|
||||||
perror(dbfile);
|
|
||||||
BIO_printf(bio_err,"unable to open '%s'\n",dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
db=TXT_DB_read(in,DB_NUMBER);
|
|
||||||
if (db == NULL) goto err;
|
if (db == NULL) goto err;
|
||||||
|
|
||||||
if (!make_serial_index(db))
|
if (!index_index(db)) goto err;
|
||||||
goto err;
|
|
||||||
|
|
||||||
if (get_certificate_status(ser_status,db) != 1)
|
if (get_certificate_status(ser_status,db) != 1)
|
||||||
BIO_printf(bio_err,"Error verifying serial %s!\n",
|
BIO_printf(bio_err,"Error verifying serial %s!\n",
|
||||||
@@ -849,19 +850,13 @@ bad:
|
|||||||
lookup_fail(section,ENV_DATABASE);
|
lookup_fail(section,ENV_DATABASE);
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
if (BIO_read_filename(in,dbfile) <= 0)
|
db = load_index(dbfile, &db_attr);
|
||||||
{
|
|
||||||
perror(dbfile);
|
|
||||||
BIO_printf(bio_err,"unable to open '%s'\n",dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
db=TXT_DB_read(in,DB_NUMBER);
|
|
||||||
if (db == NULL) goto err;
|
if (db == NULL) goto err;
|
||||||
|
|
||||||
/* Lets check some fields */
|
/* Lets check some fields */
|
||||||
for (i=0; i<sk_num(db->data); i++)
|
for (i=0; i<sk_num(db->db->data); i++)
|
||||||
{
|
{
|
||||||
pp=(char **)sk_value(db->data,i);
|
pp=(char **)sk_value(db->db->data,i);
|
||||||
if ((pp[DB_type][0] != DB_TYPE_REV) &&
|
if ((pp[DB_type][0] != DB_TYPE_REV) &&
|
||||||
(pp[DB_rev_date][0] != '\0'))
|
(pp[DB_rev_date][0] != '\0'))
|
||||||
{
|
{
|
||||||
@@ -912,23 +907,13 @@ bad:
|
|||||||
out = BIO_push(tmpbio, out);
|
out = BIO_push(tmpbio, out);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
TXT_DB_write(out,db);
|
TXT_DB_write(out,db->db);
|
||||||
BIO_printf(bio_err,"%d entries loaded from the database\n",
|
BIO_printf(bio_err,"%d entries loaded from the database\n",
|
||||||
db->data->num);
|
db->db->data->num);
|
||||||
BIO_printf(bio_err,"generating index\n");
|
BIO_printf(bio_err,"generating index\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!make_serial_index(db))
|
if (!index_index(db)) goto err;
|
||||||
goto err;
|
|
||||||
|
|
||||||
if (!TXT_DB_create_index(db, DB_name, index_name_qual,
|
|
||||||
LHASH_HASH_FN(index_name_hash),
|
|
||||||
LHASH_COMP_FN(index_name_cmp)))
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"error creating name index:(%ld,%ld,%ld)\n",
|
|
||||||
db->error,db->arg1,db->arg2);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*****************************************************************/
|
/*****************************************************************/
|
||||||
/* Update the db file for expired certificates */
|
/* Update the db file for expired certificates */
|
||||||
@@ -951,62 +936,9 @@ bad:
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
out = BIO_new(BIO_s_file());
|
if (!save_index(dbfile,"new",db)) goto err;
|
||||||
if (out == NULL)
|
|
||||||
{
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifndef OPENSSL_SYS_VMS
|
if (!rotate_index(dbfile,"new","old")) goto err;
|
||||||
j = BIO_snprintf(buf[0], sizeof buf[0], "%s.new", dbfile);
|
|
||||||
#else
|
|
||||||
j = BIO_snprintf(buf[0], sizeof buf[0], "%s-new", dbfile);
|
|
||||||
#endif
|
|
||||||
if (j < 0 || j >= sizeof buf[0])
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err, "file name too long\n");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (BIO_write_filename(out,buf[0]) <= 0)
|
|
||||||
{
|
|
||||||
perror(dbfile);
|
|
||||||
BIO_printf(bio_err,"unable to open '%s'\n",
|
|
||||||
dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
j=TXT_DB_write(out,db);
|
|
||||||
if (j <= 0) goto err;
|
|
||||||
|
|
||||||
BIO_free(out);
|
|
||||||
out = NULL;
|
|
||||||
#ifndef OPENSSL_SYS_VMS
|
|
||||||
j = BIO_snprintf(buf[1], sizeof buf[1], "%s.old", dbfile);
|
|
||||||
#else
|
|
||||||
j = BIO_snprintf(buf[1], sizeof buf[1], "%s-old", dbfile);
|
|
||||||
#endif
|
|
||||||
if (j < 0 || j >= sizeof buf[1])
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err, "file name too long\n");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (rename(dbfile,buf[1]) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,
|
|
||||||
"unable to rename %s to %s\n",
|
|
||||||
dbfile, buf[1]);
|
|
||||||
perror("reason");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (rename(buf[0],dbfile) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,
|
|
||||||
"unable to rename %s to %s\n",
|
|
||||||
buf[0],dbfile);
|
|
||||||
perror("reason");
|
|
||||||
rename(buf[1],dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (verbose) BIO_printf(bio_err,
|
if (verbose) BIO_printf(bio_err,
|
||||||
"Done. %d entries marked as expired\n",i);
|
"Done. %d entries marked as expired\n",i);
|
||||||
@@ -1062,25 +994,27 @@ bad:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ((md == NULL) && ((md=NCONF_get_string(conf,
|
||||||
|
section,ENV_DEFAULT_MD)) == NULL))
|
||||||
|
{
|
||||||
|
lookup_fail(section,ENV_DEFAULT_MD);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((dgst=EVP_get_digestbyname(md)) == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"%s is an unsupported message digest type\n",md);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
if (req)
|
if (req)
|
||||||
{
|
{
|
||||||
if ((md == NULL) && ((md=NCONF_get_string(conf,
|
|
||||||
section,ENV_DEFAULT_MD)) == NULL))
|
|
||||||
{
|
|
||||||
lookup_fail(section,ENV_DEFAULT_MD);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if ((email_dn == 1) && ((tmp_email_dn=NCONF_get_string(conf,
|
if ((email_dn == 1) && ((tmp_email_dn=NCONF_get_string(conf,
|
||||||
section,ENV_DEFAULT_EMAIL_DN)) != NULL ))
|
section,ENV_DEFAULT_EMAIL_DN)) != NULL ))
|
||||||
{
|
{
|
||||||
if(strcmp(tmp_email_dn,"no") == 0)
|
if(strcmp(tmp_email_dn,"no") == 0)
|
||||||
email_dn=0;
|
email_dn=0;
|
||||||
}
|
}
|
||||||
if ((dgst=EVP_get_digestbyname(md)) == NULL)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"%s is an unsupported message digest type\n",md);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (verbose)
|
if (verbose)
|
||||||
BIO_printf(bio_err,"message digest is %s\n",
|
BIO_printf(bio_err,"message digest is %s\n",
|
||||||
OBJ_nid2ln(dgst->type));
|
OBJ_nid2ln(dgst->type));
|
||||||
@@ -1167,7 +1101,7 @@ bad:
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((serial=load_serial(serialfile)) == NULL)
|
if ((serial=load_serial(serialfile, create_ser, NULL)) == NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"error while loading serial number\n");
|
BIO_printf(bio_err,"error while loading serial number\n");
|
||||||
goto err;
|
goto err;
|
||||||
@@ -1301,38 +1235,9 @@ bad:
|
|||||||
|
|
||||||
BIO_printf(bio_err,"Write out database with %d new entries\n",sk_X509_num(cert_sk));
|
BIO_printf(bio_err,"Write out database with %d new entries\n",sk_X509_num(cert_sk));
|
||||||
|
|
||||||
if(strlen(serialfile) > BSIZE-5 || strlen(dbfile) > BSIZE-5)
|
if (!save_serial(serialfile,"new",serial,NULL)) goto err;
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"file name too long\n");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
strcpy(buf[0],serialfile);
|
if (!save_index(dbfile, "new", db)) goto err;
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
|
||||||
strcat(buf[0],"-new");
|
|
||||||
#else
|
|
||||||
strcat(buf[0],".new");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (!save_serial(buf[0],serial)) goto err;
|
|
||||||
|
|
||||||
strcpy(buf[1],dbfile);
|
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
|
||||||
strcat(buf[1],"-new");
|
|
||||||
#else
|
|
||||||
strcat(buf[1],".new");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (BIO_write_filename(out,buf[1]) <= 0)
|
|
||||||
{
|
|
||||||
perror(dbfile);
|
|
||||||
BIO_printf(bio_err,"unable to open '%s'\n",dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
l=TXT_DB_write(out,db);
|
|
||||||
if (l <= 0) goto err;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (verbose)
|
if (verbose)
|
||||||
@@ -1340,7 +1245,7 @@ bad:
|
|||||||
for (i=0; i<sk_X509_num(cert_sk); i++)
|
for (i=0; i<sk_X509_num(cert_sk); i++)
|
||||||
{
|
{
|
||||||
int k;
|
int k;
|
||||||
unsigned char *n;
|
char *n;
|
||||||
|
|
||||||
x=sk_X509_value(cert_sk,i);
|
x=sk_X509_value(cert_sk,i);
|
||||||
|
|
||||||
@@ -1356,15 +1261,19 @@ bad:
|
|||||||
strcpy(buf[2],outdir);
|
strcpy(buf[2],outdir);
|
||||||
|
|
||||||
#ifndef OPENSSL_SYS_VMS
|
#ifndef OPENSSL_SYS_VMS
|
||||||
strcat(buf[2],"/");
|
BUF_strlcat(buf[2],"/",sizeof(buf[2]));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
n=(unsigned char *)&(buf[2][strlen(buf[2])]);
|
n=(char *)&(buf[2][strlen(buf[2])]);
|
||||||
if (j > 0)
|
if (j > 0)
|
||||||
{
|
{
|
||||||
for (k=0; k<j; k++)
|
for (k=0; k<j; k++)
|
||||||
{
|
{
|
||||||
sprintf((char *)n,"%02X",(unsigned char)*(p++));
|
if (n >= &(buf[2][sizeof(buf[2])]))
|
||||||
|
break;
|
||||||
|
BIO_snprintf(n,
|
||||||
|
&buf[2][0] + sizeof(buf[2]) - n,
|
||||||
|
"%02X",(unsigned char)*(p++));
|
||||||
n+=2;
|
n+=2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1390,59 +1299,10 @@ bad:
|
|||||||
if (sk_X509_num(cert_sk))
|
if (sk_X509_num(cert_sk))
|
||||||
{
|
{
|
||||||
/* Rename the database and the serial file */
|
/* Rename the database and the serial file */
|
||||||
strncpy(buf[2],serialfile,BSIZE-4);
|
if (!rotate_serial(serialfile,"new","old")) goto err;
|
||||||
buf[2][BSIZE-4]='\0';
|
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
if (!rotate_index(dbfile,"new","old")) goto err;
|
||||||
strcat(buf[2],"-old");
|
|
||||||
#else
|
|
||||||
strcat(buf[2],".old");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
BIO_free(in);
|
|
||||||
BIO_free_all(out);
|
|
||||||
in=NULL;
|
|
||||||
out=NULL;
|
|
||||||
if (rename(serialfile,buf[2]) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to rename %s to %s\n",
|
|
||||||
serialfile,buf[2]);
|
|
||||||
perror("reason");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (rename(buf[0],serialfile) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to rename %s to %s\n",
|
|
||||||
buf[0],serialfile);
|
|
||||||
perror("reason");
|
|
||||||
rename(buf[2],serialfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
strncpy(buf[2],dbfile,BSIZE-4);
|
|
||||||
buf[2][BSIZE-4]='\0';
|
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_VMS
|
|
||||||
strcat(buf[2],"-old");
|
|
||||||
#else
|
|
||||||
strcat(buf[2],".old");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (rename(dbfile,buf[2]) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to rename %s to %s\n",
|
|
||||||
dbfile,buf[2]);
|
|
||||||
perror("reason");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (rename(buf[1],dbfile) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to rename %s to %s\n",
|
|
||||||
buf[1],dbfile);
|
|
||||||
perror("reason");
|
|
||||||
rename(buf[2],dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
BIO_printf(bio_err,"Data Base Updated\n");
|
BIO_printf(bio_err,"Data Base Updated\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1473,6 +1333,14 @@ bad:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ((crlnumberfile=NCONF_get_string(conf,section,ENV_CRLNUMBER))
|
||||||
|
!= NULL)
|
||||||
|
if ((crlnumber=load_serial(crlnumberfile,0,NULL)) == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"error while loading CRL number\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
if (!crldays && !crlhours)
|
if (!crldays && !crlhours)
|
||||||
{
|
{
|
||||||
if (!NCONF_get_number(conf,section,
|
if (!NCONF_get_number(conf,section,
|
||||||
@@ -1501,9 +1369,9 @@ bad:
|
|||||||
|
|
||||||
ASN1_TIME_free(tmptm);
|
ASN1_TIME_free(tmptm);
|
||||||
|
|
||||||
for (i=0; i<sk_num(db->data); i++)
|
for (i=0; i<sk_num(db->db->data); i++)
|
||||||
{
|
{
|
||||||
pp=(char **)sk_value(db->data,i);
|
pp=(char **)sk_value(db->db->data,i);
|
||||||
if (pp[DB_type][0] == DB_TYPE_REV)
|
if (pp[DB_type][0] == DB_TYPE_REV)
|
||||||
{
|
{
|
||||||
if ((r=X509_REVOKED_new()) == NULL) goto err;
|
if ((r=X509_REVOKED_new()) == NULL) goto err;
|
||||||
@@ -1529,34 +1397,31 @@ bad:
|
|||||||
|
|
||||||
/* we now have a CRL */
|
/* we now have a CRL */
|
||||||
if (verbose) BIO_printf(bio_err,"signing CRL\n");
|
if (verbose) BIO_printf(bio_err,"signing CRL\n");
|
||||||
if (md != NULL)
|
|
||||||
{
|
|
||||||
if ((dgst=EVP_get_digestbyname(md)) == NULL)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"%s is an unsupported message digest type\n",md);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
#ifndef OPENSSL_NO_DSA
|
#ifndef OPENSSL_NO_DSA
|
||||||
if (pkey->type == EVP_PKEY_DSA)
|
if (pkey->type == EVP_PKEY_DSA)
|
||||||
dgst=EVP_dss1();
|
dgst=EVP_dss1();
|
||||||
else
|
|
||||||
#endif
|
#endif
|
||||||
dgst=EVP_md5();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Add any extensions asked for */
|
/* Add any extensions asked for */
|
||||||
|
|
||||||
if (crl_ext)
|
if (crl_ext || crlnumberfile != NULL)
|
||||||
{
|
{
|
||||||
X509V3_CTX crlctx;
|
X509V3_CTX crlctx;
|
||||||
X509V3_set_ctx(&crlctx, x509, NULL, NULL, crl, 0);
|
X509V3_set_ctx(&crlctx, x509, NULL, NULL, crl, 0);
|
||||||
X509V3_set_nconf(&crlctx, conf);
|
X509V3_set_nconf(&crlctx, conf);
|
||||||
|
|
||||||
if (!X509V3_EXT_CRL_add_nconf(conf, &crlctx,
|
if (crl_ext)
|
||||||
crl_ext, crl)) goto err;
|
if (!X509V3_EXT_CRL_add_nconf(conf, &crlctx,
|
||||||
|
crl_ext, crl)) goto err;
|
||||||
|
if (crlnumberfile != NULL)
|
||||||
|
{
|
||||||
|
tmpser = BN_to_ASN1_INTEGER(crlnumber, NULL);
|
||||||
|
if (!tmpser) goto err;
|
||||||
|
X509_CRL_add1_ext_i2d(crl,NID_crl_number,tmpser,0,0);
|
||||||
|
ASN1_INTEGER_free(tmpser);
|
||||||
|
crl_v2 = 1;
|
||||||
|
if (!BN_add_word(crlnumber,1)) goto err;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (crl_ext || crl_v2)
|
if (crl_ext || crl_v2)
|
||||||
{
|
{
|
||||||
@@ -1564,9 +1429,17 @@ bad:
|
|||||||
goto err; /* version 2 CRL */
|
goto err; /* version 2 CRL */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (crlnumberfile != NULL) /* we have a CRL number that need updating */
|
||||||
|
if (!save_serial(crlnumberfile,"new",crlnumber,NULL)) goto err;
|
||||||
|
|
||||||
if (!X509_CRL_sign(crl,pkey,dgst)) goto err;
|
if (!X509_CRL_sign(crl,pkey,dgst)) goto err;
|
||||||
|
|
||||||
PEM_write_bio_X509_CRL(Sout,crl);
|
PEM_write_bio_X509_CRL(Sout,crl);
|
||||||
|
|
||||||
|
if (crlnumberfile != NULL) /* Rename the crlnumber file */
|
||||||
|
if (!rotate_serial(crlnumberfile,"new","old")) goto err;
|
||||||
|
|
||||||
}
|
}
|
||||||
/*****************************************************************/
|
/*****************************************************************/
|
||||||
if (dorevoke)
|
if (dorevoke)
|
||||||
@@ -1587,50 +1460,10 @@ bad:
|
|||||||
if (j <= 0) goto err;
|
if (j <= 0) goto err;
|
||||||
X509_free(revcert);
|
X509_free(revcert);
|
||||||
|
|
||||||
if(strlen(dbfile) > BSIZE-5)
|
if (!save_index(dbfile, "new", db)) goto err;
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"filename too long\n");
|
if (!rotate_index(dbfile, "new", "old")) goto err;
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
strcpy(buf[0],dbfile);
|
|
||||||
#ifndef OPENSSL_SYS_VMS
|
|
||||||
strcat(buf[0],".new");
|
|
||||||
#else
|
|
||||||
strcat(buf[0],"-new");
|
|
||||||
#endif
|
|
||||||
if (BIO_write_filename(out,buf[0]) <= 0)
|
|
||||||
{
|
|
||||||
perror(dbfile);
|
|
||||||
BIO_printf(bio_err,"unable to open '%s'\n",dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
j=TXT_DB_write(out,db);
|
|
||||||
if (j <= 0) goto err;
|
|
||||||
BIO_free_all(out);
|
|
||||||
out = NULL;
|
|
||||||
BIO_free_all(in);
|
|
||||||
in = NULL;
|
|
||||||
strncpy(buf[1],dbfile,BSIZE-4);
|
|
||||||
buf[1][BSIZE-4]='\0';
|
|
||||||
#ifndef OPENSSL_SYS_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]);
|
|
||||||
perror("reason");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (rename(buf[0],dbfile) < 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to rename %s to %s\n", buf[0],dbfile);
|
|
||||||
perror("reason");
|
|
||||||
rename(buf[1],dbfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
BIO_printf(bio_err,"Data Base Updated\n");
|
BIO_printf(bio_err,"Data Base Updated\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1652,7 +1485,7 @@ err:
|
|||||||
if (free_key && key)
|
if (free_key && key)
|
||||||
OPENSSL_free(key);
|
OPENSSL_free(key);
|
||||||
BN_free(serial);
|
BN_free(serial);
|
||||||
TXT_DB_free(db);
|
free_index(db);
|
||||||
EVP_PKEY_free(pkey);
|
EVP_PKEY_free(pkey);
|
||||||
X509_free(x509);
|
X509_free(x509);
|
||||||
X509_CRL_free(crl);
|
X509_CRL_free(crl);
|
||||||
@@ -1667,106 +1500,8 @@ static void lookup_fail(char *name, char *tag)
|
|||||||
BIO_printf(bio_err,"variable lookup failed for %s::%s\n",name,tag);
|
BIO_printf(bio_err,"variable lookup failed for %s::%s\n",name,tag);
|
||||||
}
|
}
|
||||||
|
|
||||||
static unsigned long index_serial_hash(const char **a)
|
|
||||||
{
|
|
||||||
const char *n;
|
|
||||||
|
|
||||||
n=a[DB_serial];
|
|
||||||
while (*n == '0') n++;
|
|
||||||
return(lh_strhash(n));
|
|
||||||
}
|
|
||||||
|
|
||||||
static int index_serial_cmp(const char **a, const char **b)
|
|
||||||
{
|
|
||||||
const char *aa,*bb;
|
|
||||||
|
|
||||||
for (aa=a[DB_serial]; *aa == '0'; aa++);
|
|
||||||
for (bb=b[DB_serial]; *bb == '0'; bb++);
|
|
||||||
return(strcmp(aa,bb));
|
|
||||||
}
|
|
||||||
|
|
||||||
static unsigned long index_name_hash(const char **a)
|
|
||||||
{ return(lh_strhash(a[DB_name])); }
|
|
||||||
|
|
||||||
static int index_name_qual(char **a)
|
|
||||||
{ return(a[0][0] == 'V'); }
|
|
||||||
|
|
||||||
static int index_name_cmp(const char **a, const char **b)
|
|
||||||
{ return(strcmp(a[DB_name],
|
|
||||||
b[DB_name])); }
|
|
||||||
|
|
||||||
static BIGNUM *load_serial(char *serialfile)
|
|
||||||
{
|
|
||||||
BIO *in=NULL;
|
|
||||||
BIGNUM *ret=NULL;
|
|
||||||
MS_STATIC char buf[1024];
|
|
||||||
ASN1_INTEGER *ai=NULL;
|
|
||||||
|
|
||||||
if ((in=BIO_new(BIO_s_file())) == NULL)
|
|
||||||
{
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (BIO_read_filename(in,serialfile) <= 0)
|
|
||||||
{
|
|
||||||
perror(serialfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
ai=ASN1_INTEGER_new();
|
|
||||||
if (ai == NULL) goto err;
|
|
||||||
if (!a2i_ASN1_INTEGER(in,ai,buf,1024))
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to load number from %s\n",
|
|
||||||
serialfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
ret=ASN1_INTEGER_to_BN(ai,NULL);
|
|
||||||
if (ret == NULL)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"error converting number from bin to BIGNUM\n");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
err:
|
|
||||||
if (in != NULL) BIO_free(in);
|
|
||||||
if (ai != NULL) ASN1_INTEGER_free(ai);
|
|
||||||
return(ret);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int save_serial(char *serialfile, BIGNUM *serial)
|
|
||||||
{
|
|
||||||
BIO *out;
|
|
||||||
int ret=0;
|
|
||||||
ASN1_INTEGER *ai=NULL;
|
|
||||||
|
|
||||||
out=BIO_new(BIO_s_file());
|
|
||||||
if (out == NULL)
|
|
||||||
{
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
if (BIO_write_filename(out,serialfile) <= 0)
|
|
||||||
{
|
|
||||||
perror(serialfile);
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((ai=BN_to_ASN1_INTEGER(serial,NULL)) == NULL)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"error converting serial to ASN.1 format\n");
|
|
||||||
goto err;
|
|
||||||
}
|
|
||||||
i2a_ASN1_INTEGER(out,ai);
|
|
||||||
BIO_puts(out,"\n");
|
|
||||||
ret=1;
|
|
||||||
err:
|
|
||||||
if (out != NULL) BIO_free_all(out);
|
|
||||||
if (ai != NULL) ASN1_INTEGER_free(ai);
|
|
||||||
return(ret);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int certify(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
static int certify(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
||||||
const EVP_MD *dgst, STACK_OF(CONF_VALUE) *policy, TXT_DB *db,
|
const EVP_MD *dgst, STACK_OF(CONF_VALUE) *policy, CA_DB *db,
|
||||||
BIGNUM *serial, char *subj, int email_dn, char *startdate, char *enddate,
|
BIGNUM *serial, char *subj, int email_dn, char *startdate, char *enddate,
|
||||||
long days, int batch, char *ext_sect, CONF *lconf, int verbose,
|
long days, int batch, char *ext_sect, CONF *lconf, int verbose,
|
||||||
unsigned long certopt, unsigned long nameopt, int default_op,
|
unsigned long certopt, unsigned long nameopt, int default_op,
|
||||||
@@ -1828,7 +1563,7 @@ err:
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int certify_cert(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
static int certify_cert(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
||||||
const EVP_MD *dgst, STACK_OF(CONF_VALUE) *policy, TXT_DB *db,
|
const EVP_MD *dgst, STACK_OF(CONF_VALUE) *policy, CA_DB *db,
|
||||||
BIGNUM *serial, char *subj, int email_dn, char *startdate, char *enddate,
|
BIGNUM *serial, char *subj, int email_dn, char *startdate, char *enddate,
|
||||||
long days, int batch, char *ext_sect, CONF *lconf, int verbose,
|
long days, int batch, char *ext_sect, CONF *lconf, int verbose,
|
||||||
unsigned long certopt, unsigned long nameopt, int default_op,
|
unsigned long certopt, unsigned long nameopt, int default_op,
|
||||||
@@ -1882,7 +1617,7 @@ err:
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst,
|
static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst,
|
||||||
STACK_OF(CONF_VALUE) *policy, TXT_DB *db, BIGNUM *serial, char *subj,
|
STACK_OF(CONF_VALUE) *policy, CA_DB *db, BIGNUM *serial, char *subj,
|
||||||
int email_dn, char *startdate, char *enddate, long days, int batch,
|
int email_dn, char *startdate, char *enddate, long days, int batch,
|
||||||
int verbose, X509_REQ *req, char *ext_sect, CONF *lconf,
|
int verbose, X509_REQ *req, char *ext_sect, CONF *lconf,
|
||||||
unsigned long certopt, unsigned long nameopt, int default_op,
|
unsigned long certopt, unsigned long nameopt, int default_op,
|
||||||
@@ -1900,7 +1635,7 @@ static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst,
|
|||||||
int ok= -1,i,j,last,nid;
|
int ok= -1,i,j,last,nid;
|
||||||
char *p;
|
char *p;
|
||||||
CONF_VALUE *cv;
|
CONF_VALUE *cv;
|
||||||
char *row[DB_NUMBER],**rrow,**irow=NULL;
|
char *row[DB_NUMBER],**rrow=NULL,**irow=NULL;
|
||||||
char buf[25];
|
char buf[25];
|
||||||
|
|
||||||
tmptm=ASN1_UTCTIME_new();
|
tmptm=ASN1_UTCTIME_new();
|
||||||
@@ -2137,15 +1872,19 @@ again2:
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
rrow=TXT_DB_get_by_index(db,DB_name,row);
|
if (db->attributes.unique_subject)
|
||||||
if (rrow != NULL)
|
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"ERROR:There is already a certificate for %s\n",
|
rrow=TXT_DB_get_by_index(db->db,DB_name,row);
|
||||||
row[DB_name]);
|
if (rrow != NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"ERROR:There is already a certificate for %s\n",
|
||||||
|
row[DB_name]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
if (rrow == NULL)
|
||||||
{
|
{
|
||||||
rrow=TXT_DB_get_by_index(db,DB_serial,row);
|
rrow=TXT_DB_get_by_index(db->db,DB_serial,row);
|
||||||
if (rrow != NULL)
|
if (rrow != NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"ERROR:Serial number %s has already been issued,\n",
|
BIO_printf(bio_err,"ERROR:Serial number %s has already been issued,\n",
|
||||||
@@ -2193,7 +1932,7 @@ again2:
|
|||||||
|
|
||||||
#ifdef X509_V3
|
#ifdef X509_V3
|
||||||
/* Make it an X509 v3 certificate. */
|
/* Make it an X509 v3 certificate. */
|
||||||
if (!X509_set_version(x509,2)) goto err;
|
if (!X509_set_version(ret,2)) goto err;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (BN_to_ASN1_INTEGER(serial,ci->serialNumber) == NULL)
|
if (BN_to_ASN1_INTEGER(serial,ci->serialNumber) == NULL)
|
||||||
@@ -2352,7 +2091,7 @@ again2:
|
|||||||
BIO_printf(bio_err,"Memory allocation failure\n");
|
BIO_printf(bio_err,"Memory allocation failure\n");
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
strcpy(row[DB_file],"unknown");
|
BUF_strlcpy(row[DB_file],"unknown",8);
|
||||||
row[DB_type][0]='V';
|
row[DB_type][0]='V';
|
||||||
row[DB_type][1]='\0';
|
row[DB_type][1]='\0';
|
||||||
|
|
||||||
@@ -2369,10 +2108,10 @@ again2:
|
|||||||
}
|
}
|
||||||
irow[DB_NUMBER]=NULL;
|
irow[DB_NUMBER]=NULL;
|
||||||
|
|
||||||
if (!TXT_DB_insert(db,irow))
|
if (!TXT_DB_insert(db->db,irow))
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"failed to update database\n");
|
BIO_printf(bio_err,"failed to update database\n");
|
||||||
BIO_printf(bio_err,"TXT_DB error number %ld\n",db->error);
|
BIO_printf(bio_err,"TXT_DB error number %ld\n",db->db->error);
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
ok=1;
|
ok=1;
|
||||||
@@ -2423,7 +2162,7 @@ static void write_new_certificate(BIO *bp, X509 *x, int output_der, int notext)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int certify_spkac(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
static int certify_spkac(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
||||||
const EVP_MD *dgst, STACK_OF(CONF_VALUE) *policy, TXT_DB *db,
|
const EVP_MD *dgst, STACK_OF(CONF_VALUE) *policy, CA_DB *db,
|
||||||
BIGNUM *serial, char *subj, int email_dn, char *startdate, char *enddate,
|
BIGNUM *serial, char *subj, int email_dn, char *startdate, char *enddate,
|
||||||
long days, char *ext_sect, CONF *lconf, int verbose, unsigned long certopt,
|
long days, char *ext_sect, CONF *lconf, int verbose, unsigned long certopt,
|
||||||
unsigned long nameopt, int default_op, int ext_copy)
|
unsigned long nameopt, int default_op, int ext_copy)
|
||||||
@@ -2602,7 +2341,7 @@ static int check_time_format(char *str)
|
|||||||
return(ASN1_UTCTIME_check(&tm));
|
return(ASN1_UTCTIME_check(&tm));
|
||||||
}
|
}
|
||||||
|
|
||||||
static int do_revoke(X509 *x509, TXT_DB *db, int type, char *value)
|
static int do_revoke(X509 *x509, CA_DB *db, int type, char *value)
|
||||||
{
|
{
|
||||||
ASN1_UTCTIME *tm=NULL;
|
ASN1_UTCTIME *tm=NULL;
|
||||||
char *row[DB_NUMBER],**rrow,**irow;
|
char *row[DB_NUMBER],**rrow,**irow;
|
||||||
@@ -2627,10 +2366,10 @@ static int do_revoke(X509 *x509, TXT_DB *db, int type, char *value)
|
|||||||
/* We have to lookup by serial number because name lookup
|
/* We have to lookup by serial number because name lookup
|
||||||
* skips revoked certs
|
* skips revoked certs
|
||||||
*/
|
*/
|
||||||
rrow=TXT_DB_get_by_index(db,DB_serial,row);
|
rrow=TXT_DB_get_by_index(db->db,DB_serial,row);
|
||||||
if (rrow == NULL)
|
if (rrow == NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Adding Entry to DB for %s\n", row[DB_name]);
|
BIO_printf(bio_err,"Adding Entry with serial number %s to DB for %s\n", row[DB_serial], row[DB_name]);
|
||||||
|
|
||||||
/* We now just add it to the database */
|
/* We now just add it to the database */
|
||||||
row[DB_type]=(char *)OPENSSL_malloc(2);
|
row[DB_type]=(char *)OPENSSL_malloc(2);
|
||||||
@@ -2653,7 +2392,7 @@ static int do_revoke(X509 *x509, TXT_DB *db, int type, char *value)
|
|||||||
BIO_printf(bio_err,"Memory allocation failure\n");
|
BIO_printf(bio_err,"Memory allocation failure\n");
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
strcpy(row[DB_file],"unknown");
|
BUF_strlcpy(row[DB_file],"unknown",8);
|
||||||
row[DB_type][0]='V';
|
row[DB_type][0]='V';
|
||||||
row[DB_type][1]='\0';
|
row[DB_type][1]='\0';
|
||||||
|
|
||||||
@@ -2670,10 +2409,10 @@ static int do_revoke(X509 *x509, TXT_DB *db, int type, char *value)
|
|||||||
}
|
}
|
||||||
irow[DB_NUMBER]=NULL;
|
irow[DB_NUMBER]=NULL;
|
||||||
|
|
||||||
if (!TXT_DB_insert(db,irow))
|
if (!TXT_DB_insert(db->db,irow))
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"failed to update database\n");
|
BIO_printf(bio_err,"failed to update database\n");
|
||||||
BIO_printf(bio_err,"TXT_DB error number %ld\n",db->error);
|
BIO_printf(bio_err,"TXT_DB error number %ld\n",db->db->error);
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2718,7 +2457,7 @@ err:
|
|||||||
return(ok);
|
return(ok);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int get_certificate_status(const char *serial, TXT_DB *db)
|
static int get_certificate_status(const char *serial, CA_DB *db)
|
||||||
{
|
{
|
||||||
char *row[DB_NUMBER],**rrow;
|
char *row[DB_NUMBER],**rrow;
|
||||||
int ok=-1,i;
|
int ok=-1,i;
|
||||||
@@ -2759,7 +2498,7 @@ static int get_certificate_status(const char *serial, TXT_DB *db)
|
|||||||
ok=1;
|
ok=1;
|
||||||
|
|
||||||
/* Search for the certificate */
|
/* Search for the certificate */
|
||||||
rrow=TXT_DB_get_by_index(db,DB_serial,row);
|
rrow=TXT_DB_get_by_index(db->db,DB_serial,row);
|
||||||
if (rrow == NULL)
|
if (rrow == NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Serial %s not present in db.\n",
|
BIO_printf(bio_err,"Serial %s not present in db.\n",
|
||||||
@@ -2806,7 +2545,7 @@ err:
|
|||||||
return(ok);
|
return(ok);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int do_updatedb (TXT_DB *db)
|
static int do_updatedb (CA_DB *db)
|
||||||
{
|
{
|
||||||
ASN1_UTCTIME *a_tm = NULL;
|
ASN1_UTCTIME *a_tm = NULL;
|
||||||
int i, cnt = 0;
|
int i, cnt = 0;
|
||||||
@@ -2832,9 +2571,9 @@ static int do_updatedb (TXT_DB *db)
|
|||||||
else
|
else
|
||||||
a_y2k = 0;
|
a_y2k = 0;
|
||||||
|
|
||||||
for (i = 0; i < sk_num(db->data); i++)
|
for (i = 0; i < sk_num(db->db->data); i++)
|
||||||
{
|
{
|
||||||
rrow = (char **) sk_value(db->data, i);
|
rrow = (char **) sk_value(db->db->data, i);
|
||||||
|
|
||||||
if (rrow[DB_type][0] == 'V')
|
if (rrow[DB_type][0] == 'V')
|
||||||
{
|
{
|
||||||
@@ -2977,16 +2716,16 @@ char *make_revocation_str(int rev_type, char *rev_arg)
|
|||||||
|
|
||||||
if (!str) return NULL;
|
if (!str) return NULL;
|
||||||
|
|
||||||
strcpy(str, (char *)revtm->data);
|
BUF_strlcpy(str, (char *)revtm->data, i);
|
||||||
if (reason)
|
if (reason)
|
||||||
{
|
{
|
||||||
strcat(str, ",");
|
BUF_strlcat(str, ",", i);
|
||||||
strcat(str, reason);
|
BUF_strlcat(str, reason, i);
|
||||||
}
|
}
|
||||||
if (other)
|
if (other)
|
||||||
{
|
{
|
||||||
strcat(str, ",");
|
BUF_strlcat(str, ",", i);
|
||||||
strcat(str, other);
|
BUF_strlcat(str, other, i);
|
||||||
}
|
}
|
||||||
ASN1_UTCTIME_free(revtm);
|
ASN1_UTCTIME_free(revtm);
|
||||||
return str;
|
return str;
|
||||||
@@ -3321,17 +3060,3 @@ int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_G
|
|||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
int make_serial_index(TXT_DB *db)
|
|
||||||
{
|
|
||||||
if (!TXT_DB_create_index(db, DB_serial, NULL,
|
|
||||||
LHASH_HASH_FN(index_serial_hash),
|
|
||||||
LHASH_COMP_FN(index_serial_cmp)))
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,
|
|
||||||
"error creating serial number index:(%ld,%ld,%ld)\n",
|
|
||||||
db->error,db->arg1,db->arg2);
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -81,6 +81,7 @@ static char *crl_usage[]={
|
|||||||
" -in arg - input file - default stdin\n",
|
" -in arg - input file - default stdin\n",
|
||||||
" -out arg - output file - default stdout\n",
|
" -out arg - output file - default stdout\n",
|
||||||
" -hash - print hash value\n",
|
" -hash - print hash value\n",
|
||||||
|
" -fingerprint - print the crl fingerprint\n",
|
||||||
" -issuer - print issuer DN\n",
|
" -issuer - print issuer DN\n",
|
||||||
" -lastupdate - lastUpdate field\n",
|
" -lastupdate - lastUpdate field\n",
|
||||||
" -nextupdate - nextUpdate field\n",
|
" -nextupdate - nextUpdate field\n",
|
||||||
@@ -354,7 +355,11 @@ bad:
|
|||||||
|
|
||||||
if (text) X509_CRL_print(out, x);
|
if (text) X509_CRL_print(out, x);
|
||||||
|
|
||||||
if (noout) goto end;
|
if (noout)
|
||||||
|
{
|
||||||
|
ret = 0;
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
if (outformat == FORMAT_ASN1)
|
if (outformat == FORMAT_ASN1)
|
||||||
i=(int)i2d_X509_CRL_bio(out,x);
|
i=(int)i2d_X509_CRL_bio(out,x);
|
||||||
|
|||||||
305
apps/der_chop.in
305
apps/der_chop.in
@@ -1,305 +0,0 @@
|
|||||||
#!/usr/local/bin/perl
|
|
||||||
#
|
|
||||||
# der_chop ... this is one total hack that Eric is really not proud of
|
|
||||||
# so don't look at it and don't ask for support
|
|
||||||
#
|
|
||||||
# The "documentation" for this (i.e. all the comments) are my fault --tjh
|
|
||||||
#
|
|
||||||
# This program takes the "raw" output of derparse/asn1parse and
|
|
||||||
# converts it into tokens and then runs regular expression matches
|
|
||||||
# to try to figure out what to grab to get the things that are needed
|
|
||||||
# and it is possible that this will do the wrong thing as it is a *hack*
|
|
||||||
#
|
|
||||||
# SSLeay 0.5.2+ should have direct read support for x509 (via -inform NET)
|
|
||||||
# [I know ... promises promises :-)]
|
|
||||||
#
|
|
||||||
# To convert a Netscape Certificate:
|
|
||||||
# der_chop < ServerCert.der > cert.pem
|
|
||||||
# To convert a Netscape Key (and encrypt it again to protect it)
|
|
||||||
# rsa -inform NET -in ServerKey.der -des > key.pem
|
|
||||||
#
|
|
||||||
# 23-Apr-96 eay Added the extra ASN.1 string types, I still think this
|
|
||||||
# is an evil hack. If nothing else the parsing should
|
|
||||||
# be relative, not absolute.
|
|
||||||
# 19-Apr-96 tjh hacked (with eay) into 0.5.x format
|
|
||||||
#
|
|
||||||
# Tim Hudson
|
|
||||||
# tjh@cryptsoft.com
|
|
||||||
#
|
|
||||||
|
|
||||||
|
|
||||||
require 'getopts.pl';
|
|
||||||
|
|
||||||
$debug=0;
|
|
||||||
|
|
||||||
# this was the 0.4.x way of doing things ...
|
|
||||||
$cmd="derparse";
|
|
||||||
$x509_cmd="x509";
|
|
||||||
$crl_cmd="crl";
|
|
||||||
$rc4_cmd="rc4";
|
|
||||||
$md2_cmd="md2";
|
|
||||||
$md4_cmd="md4";
|
|
||||||
$rsa_cmd="rsa -des -inform der ";
|
|
||||||
|
|
||||||
# this was the 0.5.x way of doing things ...
|
|
||||||
$cmd="openssl asn1parse";
|
|
||||||
$x509_cmd="openssl x509";
|
|
||||||
$crl_cmd="openssl crl";
|
|
||||||
$rc4_cmd="openssl rc4";
|
|
||||||
$md2_cmd="openssl md2";
|
|
||||||
$md4_cmd="openssl md4";
|
|
||||||
$rsa_cmd="openssl rsa -des -inform der ";
|
|
||||||
|
|
||||||
&Getopts('vd:') || die "usage:$0 [-v] [-d num] file";
|
|
||||||
$depth=($opt_d =~ /^\d+$/)?$opt_d:0;
|
|
||||||
|
|
||||||
&init_der();
|
|
||||||
|
|
||||||
if ($#ARGV != -1)
|
|
||||||
{
|
|
||||||
foreach $file (@ARGV)
|
|
||||||
{
|
|
||||||
print STDERR "doing $file\n";
|
|
||||||
&dofile($file);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$file="/tmp/a$$.DER";
|
|
||||||
open(OUT,">$file") || die "unable to open $file:$!\n";
|
|
||||||
for (;;)
|
|
||||||
{
|
|
||||||
$i=sysread(STDIN,$b,1024*10);
|
|
||||||
last if ($i <= 0);
|
|
||||||
$i=syswrite(OUT,$b,$i);
|
|
||||||
}
|
|
||||||
&dofile($file);
|
|
||||||
unlink($file);
|
|
||||||
}
|
|
||||||
|
|
||||||
sub dofile
|
|
||||||
{
|
|
||||||
local($file)=@_;
|
|
||||||
local(@p);
|
|
||||||
|
|
||||||
$b=&load_file($file);
|
|
||||||
@p=&load_file_parse($file);
|
|
||||||
|
|
||||||
foreach $_ (@p)
|
|
||||||
{
|
|
||||||
($off,$d,$hl,$len)=&parse_line($_);
|
|
||||||
$d-=$depth;
|
|
||||||
next if ($d != 0);
|
|
||||||
next if ($len == 0);
|
|
||||||
|
|
||||||
$o=substr($b,$off,$len+$hl);
|
|
||||||
($str,@data)=&der_str($o);
|
|
||||||
print "$str\n" if ($opt_v);
|
|
||||||
if ($str =~ /^$crl/)
|
|
||||||
{
|
|
||||||
open(OUT,"|$crl_cmd -inform d -hash -issuer") ||
|
|
||||||
die "unable to run $crl_cmd:$!\n";
|
|
||||||
print OUT $o;
|
|
||||||
close(OUT);
|
|
||||||
}
|
|
||||||
elsif ($str =~ /^$x509/)
|
|
||||||
{
|
|
||||||
open(OUT,"|$x509_cmd -inform d -hash -subject -issuer")
|
|
||||||
|| die "unable to run $x509_cmd:$!\n";
|
|
||||||
print OUT $o;
|
|
||||||
close(OUT);
|
|
||||||
}
|
|
||||||
elsif ($str =~ /^$rsa/)
|
|
||||||
{
|
|
||||||
($type)=($data[3] =~ /OBJECT_IDENTIFIER :(.*)\s*$/);
|
|
||||||
next unless ($type eq "rsaEncryption");
|
|
||||||
($off,$d,$hl,$len)=&parse_line($data[5]);
|
|
||||||
$os=substr($o,$off+$hl,$len);
|
|
||||||
open(OUT,"|$rsa_cmd")
|
|
||||||
|| die "unable to run $rsa_cmd:$!\n";
|
|
||||||
print OUT $os;
|
|
||||||
close(OUT);
|
|
||||||
}
|
|
||||||
elsif ($str =~ /^0G-1D-1G/)
|
|
||||||
{
|
|
||||||
($off,$d,$hl,$len)=&parse_line($data[1]);
|
|
||||||
$os=substr($o,$off+$hl,$len);
|
|
||||||
print STDERR "<$os>\n" if $opt_v;
|
|
||||||
&do_certificate($o,@data)
|
|
||||||
if (($os eq "certificate") &&
|
|
||||||
($str =! /^0G-1D-1G-2G-3F-3E-2D/));
|
|
||||||
&do_private_key($o,@data)
|
|
||||||
if (($os eq "private-key") &&
|
|
||||||
($str =! /^0G-1D-1G-2G-3F-3E-2D/));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
sub der_str
|
|
||||||
{
|
|
||||||
local($str)=@_;
|
|
||||||
local(*OUT,*IN,@a,$t,$d,$ret);
|
|
||||||
local($file)="/tmp/b$$.DER";
|
|
||||||
local(@ret);
|
|
||||||
|
|
||||||
open(OUT,">$file");
|
|
||||||
print OUT $str;
|
|
||||||
close(OUT);
|
|
||||||
open(IN,"$cmd -inform 'd' -in $file |") ||
|
|
||||||
die "unable to run $cmd:$!\n";
|
|
||||||
$ret="";
|
|
||||||
while (<IN>)
|
|
||||||
{
|
|
||||||
chop;
|
|
||||||
push(@ret,$_);
|
|
||||||
|
|
||||||
print STDERR "$_\n" if ($debug);
|
|
||||||
|
|
||||||
@a=split(/\s*:\s*/);
|
|
||||||
($d)=($a[1] =~ /d=\s*(\d+)/);
|
|
||||||
$a[2] =~ s/\s+$//;
|
|
||||||
$t=$DER_s2i{$a[2]};
|
|
||||||
$ret.="$d$t-";
|
|
||||||
}
|
|
||||||
close(IN);
|
|
||||||
unlink($file);
|
|
||||||
chop $ret;
|
|
||||||
$ret =~ s/(-3H(-4G-5F-5[IJKMQRS])+)+/-NAME/g;
|
|
||||||
$ret =~ s/(-3G-4B-4L)+/-RCERT/g;
|
|
||||||
return($ret,@ret);
|
|
||||||
}
|
|
||||||
|
|
||||||
sub init_der
|
|
||||||
{
|
|
||||||
$crl= "0G-1G-2G-3F-3E-2G-NAME-2L-2L-2G-RCERT-1G-2F-2E-1C";
|
|
||||||
$x509="0G-1G-2B-2G-3F-3E-2G-NAME-2G-3L-3L-2G-NAME-2G-3G-4F-4E-3C-1G-2F-2E-1C";
|
|
||||||
$rsa= "0G-1B-1G-2F-2E-1D";
|
|
||||||
|
|
||||||
%DER_i2s=(
|
|
||||||
# SSLeay 0.4.x has this list
|
|
||||||
"A","EOC",
|
|
||||||
"B","INTEGER",
|
|
||||||
"C","BIT STRING",
|
|
||||||
"D","OCTET STRING",
|
|
||||||
"E","NULL",
|
|
||||||
"F","OBJECT",
|
|
||||||
"G","SEQUENCE",
|
|
||||||
"H","SET",
|
|
||||||
"I","PRINTABLESTRING",
|
|
||||||
"J","T61STRING",
|
|
||||||
"K","IA5STRING",
|
|
||||||
"L","UTCTIME",
|
|
||||||
"M","NUMERICSTRING",
|
|
||||||
"N","VIDEOTEXSTRING",
|
|
||||||
"O","GENERALIZEDTIME",
|
|
||||||
"P","GRAPHICSTRING",
|
|
||||||
"Q","ISO64STRING",
|
|
||||||
"R","GENERALSTRING",
|
|
||||||
"S","UNIVERSALSTRING",
|
|
||||||
|
|
||||||
# SSLeay 0.5.x changed some things ... and I'm
|
|
||||||
# leaving in the old stuff but adding in these
|
|
||||||
# to handle the new as well --tjh
|
|
||||||
# - Well I've just taken them out and added the extra new
|
|
||||||
# ones :-) - eay
|
|
||||||
);
|
|
||||||
|
|
||||||
foreach (keys %DER_i2s)
|
|
||||||
{ $DER_s2i{$DER_i2s{$_}}=$_; }
|
|
||||||
}
|
|
||||||
|
|
||||||
sub parse_line
|
|
||||||
{
|
|
||||||
local($_)=@_;
|
|
||||||
|
|
||||||
return(/\s*(\d+):d=\s*(\d+)\s+hl=\s*(\d+)\s+l=\s*(\d+|inf)\s/);
|
|
||||||
}
|
|
||||||
|
|
||||||
# 0:d=0 hl=4 l=377 cons: univ: SEQUENCE
|
|
||||||
# 4:d=1 hl=2 l= 11 prim: univ: OCTET_STRING
|
|
||||||
# 17:d=1 hl=4 l=360 cons: univ: SEQUENCE
|
|
||||||
# 21:d=2 hl=2 l= 12 cons: univ: SEQUENCE
|
|
||||||
# 23:d=3 hl=2 l= 8 prim: univ: OBJECT_IDENTIFIER :rc4
|
|
||||||
# 33:d=3 hl=2 l= 0 prim: univ: NULL
|
|
||||||
# 35:d=2 hl=4 l=342 prim: univ: OCTET_STRING
|
|
||||||
sub do_private_key
|
|
||||||
{
|
|
||||||
local($data,@struct)=@_;
|
|
||||||
local($file)="/tmp/b$$.DER";
|
|
||||||
local($off,$d,$hl,$len,$_,$b,@p,$s);
|
|
||||||
|
|
||||||
($type)=($struct[4] =~ /OBJECT_IDENTIFIER :(.*)\s*$/);
|
|
||||||
if ($type eq "rc4")
|
|
||||||
{
|
|
||||||
($off,$d,$hl,$len)=&parse_line($struct[6]);
|
|
||||||
open(OUT,"|$rc4_cmd >$file") ||
|
|
||||||
die "unable to run $rc4_cmd:$!\n";
|
|
||||||
print OUT substr($data,$off+$hl,$len);
|
|
||||||
close(OUT);
|
|
||||||
|
|
||||||
$b=&load_file($file);
|
|
||||||
unlink($file);
|
|
||||||
|
|
||||||
($s,@p)=&der_str($b);
|
|
||||||
die "unknown rsa key type\n$s\n"
|
|
||||||
if ($s ne '0G-1B-1G-2F-2E-1D');
|
|
||||||
local($off,$d,$hl,$len)=&parse_line($p[5]);
|
|
||||||
$b=substr($b,$off+$hl,$len);
|
|
||||||
($s,@p)=&der_str($b);
|
|
||||||
open(OUT,"|$rsa_cmd") || die "unable to run $rsa_cmd:$!\n";
|
|
||||||
print OUT $b;
|
|
||||||
close(OUT);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
print "'$type' is unknown\n";
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
sub do_certificate
|
|
||||||
{
|
|
||||||
local($data,@struct)=@_;
|
|
||||||
local($file)="/tmp/b$$.DER";
|
|
||||||
local($off,$d,$hl,$len,$_,$b,@p,$s);
|
|
||||||
|
|
||||||
($off,$d,$hl,$len)=&parse_line($struct[2]);
|
|
||||||
$b=substr($data,$off,$len+$hl);
|
|
||||||
|
|
||||||
open(OUT,"|$x509_cmd -inform d") || die "unable to run $x509_cmd:$!\n";
|
|
||||||
print OUT $b;
|
|
||||||
close(OUT);
|
|
||||||
}
|
|
||||||
|
|
||||||
sub load_file
|
|
||||||
{
|
|
||||||
local($file)=@_;
|
|
||||||
local(*IN,$r,$b,$i);
|
|
||||||
|
|
||||||
$r="";
|
|
||||||
open(IN,"<$file") || die "unable to open $file:$!\n";
|
|
||||||
for (;;)
|
|
||||||
{
|
|
||||||
$i=sysread(IN,$b,10240);
|
|
||||||
last if ($i <= 0);
|
|
||||||
$r.=$b;
|
|
||||||
}
|
|
||||||
close(IN);
|
|
||||||
return($r);
|
|
||||||
}
|
|
||||||
|
|
||||||
sub load_file_parse
|
|
||||||
{
|
|
||||||
local($file)=@_;
|
|
||||||
local(*IN,$r,@ret,$_,$i,$n,$b);
|
|
||||||
|
|
||||||
open(IN,"$cmd -inform d -in $file|")
|
|
||||||
|| die "unable to run der_parse\n";
|
|
||||||
while (<IN>)
|
|
||||||
{
|
|
||||||
chop;
|
|
||||||
push(@ret,$_);
|
|
||||||
}
|
|
||||||
return($r,@ret);
|
|
||||||
}
|
|
||||||
|
|
||||||
89
apps/dgst.c
89
apps/dgst.c
@@ -66,6 +66,7 @@
|
|||||||
#include <openssl/objects.h>
|
#include <openssl/objects.h>
|
||||||
#include <openssl/x509.h>
|
#include <openssl/x509.h>
|
||||||
#include <openssl/pem.h>
|
#include <openssl/pem.h>
|
||||||
|
#include <openssl/hmac.h>
|
||||||
|
|
||||||
#undef BUFSIZE
|
#undef BUFSIZE
|
||||||
#define BUFSIZE 1024*8
|
#define BUFSIZE 1024*8
|
||||||
@@ -73,9 +74,11 @@
|
|||||||
#undef PROG
|
#undef PROG
|
||||||
#define PROG dgst_main
|
#define PROG dgst_main
|
||||||
|
|
||||||
|
static HMAC_CTX hmac_ctx;
|
||||||
|
|
||||||
int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
||||||
EVP_PKEY *key, unsigned char *sigin, int siglen, const char *title,
|
EVP_PKEY *key, unsigned char *sigin, int siglen, const char *title,
|
||||||
const char *file);
|
const char *file,BIO *bmd,const char *hmac_key, int non_fips_allow);
|
||||||
|
|
||||||
int MAIN(int, char **);
|
int MAIN(int, char **);
|
||||||
|
|
||||||
@@ -100,9 +103,12 @@ int MAIN(int argc, char **argv)
|
|||||||
EVP_PKEY *sigkey = NULL;
|
EVP_PKEY *sigkey = NULL;
|
||||||
unsigned char *sigbuf = NULL;
|
unsigned char *sigbuf = NULL;
|
||||||
int siglen = 0;
|
int siglen = 0;
|
||||||
|
char *passargin = NULL, *passin = NULL;
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
char *engine=NULL;
|
char *engine=NULL;
|
||||||
#endif
|
#endif
|
||||||
|
char *hmac_key=NULL;
|
||||||
|
int non_fips_allow = 0;
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
|
|
||||||
@@ -145,6 +151,12 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) break;
|
if (--argc < 1) break;
|
||||||
keyfile=*(++argv);
|
keyfile=*(++argv);
|
||||||
}
|
}
|
||||||
|
else if (!strcmp(*argv,"-passin"))
|
||||||
|
{
|
||||||
|
if (--argc < 1)
|
||||||
|
break;
|
||||||
|
passargin=*++argv;
|
||||||
|
}
|
||||||
else if (strcmp(*argv,"-verify") == 0)
|
else if (strcmp(*argv,"-verify") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) break;
|
if (--argc < 1) break;
|
||||||
@@ -181,6 +193,14 @@ int MAIN(int argc, char **argv)
|
|||||||
out_bin = 1;
|
out_bin = 1;
|
||||||
else if (strcmp(*argv,"-d") == 0)
|
else if (strcmp(*argv,"-d") == 0)
|
||||||
debug=1;
|
debug=1;
|
||||||
|
else if (strcmp(*argv,"-non-fips-allow") == 0)
|
||||||
|
non_fips_allow=1;
|
||||||
|
else if (!strcmp(*argv,"-hmac"))
|
||||||
|
{
|
||||||
|
if (--argc < 1)
|
||||||
|
break;
|
||||||
|
hmac_key=*++argv;
|
||||||
|
}
|
||||||
else if ((m=EVP_get_digestbyname(&((*argv)[1]))) != NULL)
|
else if ((m=EVP_get_digestbyname(&((*argv)[1]))) != NULL)
|
||||||
md=m;
|
md=m;
|
||||||
else
|
else
|
||||||
@@ -235,7 +255,7 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
e = setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
in=BIO_new(BIO_s_file());
|
in=BIO_new(BIO_s_file());
|
||||||
@@ -247,6 +267,12 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_set_callback_arg(in,bio_err);
|
BIO_set_callback_arg(in,bio_err);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!app_passwd(bio_err, passargin, NULL, &passin, NULL))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error getting password\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
if ((in == NULL) || (bmd == NULL))
|
if ((in == NULL) || (bmd == NULL))
|
||||||
{
|
{
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
@@ -288,7 +314,7 @@ int MAIN(int argc, char **argv)
|
|||||||
sigkey = load_pubkey(bio_err, keyfile, keyform, 0, NULL,
|
sigkey = load_pubkey(bio_err, keyfile, keyform, 0, NULL,
|
||||||
e, "key file");
|
e, "key file");
|
||||||
else
|
else
|
||||||
sigkey = load_key(bio_err, keyfile, keyform, 0, NULL,
|
sigkey = load_key(bio_err, keyfile, keyform, 0, passin,
|
||||||
e, "key file");
|
e, "key file");
|
||||||
if (!sigkey)
|
if (!sigkey)
|
||||||
{
|
{
|
||||||
@@ -319,17 +345,29 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (non_fips_allow)
|
||||||
|
{
|
||||||
|
EVP_MD_CTX *md_ctx;
|
||||||
|
BIO_get_md_ctx(bmd,&md_ctx);
|
||||||
|
EVP_MD_CTX_set_flags(md_ctx, EVP_MD_CTX_FLAG_NON_FIPS_ALLOW);
|
||||||
|
}
|
||||||
|
|
||||||
/* we use md as a filter, reading from 'in' */
|
/* we use md as a filter, reading from 'in' */
|
||||||
BIO_set_md(bmd,md);
|
if (!BIO_set_md(bmd,md))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error setting digest %s\n",
|
||||||
|
EVP_MD_name(md));
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
inp=BIO_push(bmd,in);
|
inp=BIO_push(bmd,in);
|
||||||
|
|
||||||
if (argc == 0)
|
if (argc == 0)
|
||||||
{
|
{
|
||||||
BIO_set_fp(in,stdin,BIO_NOCLOSE);
|
BIO_set_fp(in,stdin,BIO_NOCLOSE);
|
||||||
err=do_fp(out, buf,inp,separator, out_bin, sigkey, sigbuf,
|
err=do_fp(out, buf,inp,separator, out_bin, sigkey, sigbuf,
|
||||||
siglen,"","(stdin)");
|
siglen,"","(stdin)",bmd,hmac_key, non_fips_allow);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -347,13 +385,15 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
if(!out_bin)
|
if(!out_bin)
|
||||||
{
|
{
|
||||||
tmp=tofree=OPENSSL_malloc(strlen(name)+strlen(argv[i])+5);
|
size_t len = strlen(name)+strlen(argv[i])+(hmac_key ? 5 : 0)+5;
|
||||||
sprintf(tmp,"%s(%s)= ",name,argv[i]);
|
tmp=tofree=OPENSSL_malloc(len);
|
||||||
|
BIO_snprintf(tmp,len,"%s%s(%s)= ",
|
||||||
|
hmac_key ? "HMAC-" : "",name,argv[i]);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
tmp="";
|
tmp="";
|
||||||
r=do_fp(out,buf,inp,separator,out_bin,sigkey,sigbuf,
|
r=do_fp(out,buf,inp,separator,out_bin,sigkey,sigbuf,
|
||||||
siglen,tmp,argv[i]);
|
siglen,tmp,argv[i],bmd,hmac_key,non_fips_allow);
|
||||||
if(r)
|
if(r)
|
||||||
err=r;
|
err=r;
|
||||||
if(tofree)
|
if(tofree)
|
||||||
@@ -368,6 +408,8 @@ end:
|
|||||||
OPENSSL_free(buf);
|
OPENSSL_free(buf);
|
||||||
}
|
}
|
||||||
if (in != NULL) BIO_free(in);
|
if (in != NULL) BIO_free(in);
|
||||||
|
if (passin)
|
||||||
|
OPENSSL_free(passin);
|
||||||
BIO_free_all(out);
|
BIO_free_all(out);
|
||||||
EVP_PKEY_free(sigkey);
|
EVP_PKEY_free(sigkey);
|
||||||
if(sigbuf) OPENSSL_free(sigbuf);
|
if(sigbuf) OPENSSL_free(sigbuf);
|
||||||
@@ -378,11 +420,25 @@ end:
|
|||||||
|
|
||||||
int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
||||||
EVP_PKEY *key, unsigned char *sigin, int siglen, const char *title,
|
EVP_PKEY *key, unsigned char *sigin, int siglen, const char *title,
|
||||||
const char *file)
|
const char *file,BIO *bmd,const char *hmac_key, int non_fips_allow)
|
||||||
{
|
{
|
||||||
int len;
|
unsigned int len;
|
||||||
int i;
|
int i;
|
||||||
|
EVP_MD_CTX *md_ctx;
|
||||||
|
|
||||||
|
if (hmac_key)
|
||||||
|
{
|
||||||
|
EVP_MD *md;
|
||||||
|
|
||||||
|
BIO_get_md(bmd,&md);
|
||||||
|
HMAC_CTX_init(&hmac_ctx);
|
||||||
|
if (non_fips_allow)
|
||||||
|
HMAC_CTX_set_flags(&hmac_ctx,
|
||||||
|
EVP_MD_CTX_FLAG_NON_FIPS_ALLOW);
|
||||||
|
HMAC_Init_ex(&hmac_ctx,hmac_key,strlen(hmac_key),md, NULL);
|
||||||
|
BIO_get_md_ctx(bmd,&md_ctx);
|
||||||
|
BIO_set_md_ctx(bmd,&hmac_ctx.md_ctx);
|
||||||
|
}
|
||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
i=BIO_read(bp,(char *)buf,BUFSIZE);
|
i=BIO_read(bp,(char *)buf,BUFSIZE);
|
||||||
@@ -425,6 +481,11 @@ int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if(hmac_key)
|
||||||
|
{
|
||||||
|
HMAC_Final(&hmac_ctx,buf,&len);
|
||||||
|
HMAC_CTX_cleanup(&hmac_ctx);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
len=BIO_gets(bp,(char *)buf,BUFSIZE);
|
len=BIO_gets(bp,(char *)buf,BUFSIZE);
|
||||||
|
|
||||||
@@ -432,7 +493,7 @@ int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
BIO_write(out,title,strlen(title));
|
BIO_write(out,title,strlen(title));
|
||||||
for (i=0; i<len; i++)
|
for (i=0; (unsigned int)i<len; i++)
|
||||||
{
|
{
|
||||||
if (sep && (i != 0))
|
if (sep && (i != 0))
|
||||||
BIO_printf(out, ":");
|
BIO_printf(out, ":");
|
||||||
@@ -440,6 +501,10 @@ int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
|||||||
}
|
}
|
||||||
BIO_printf(out, "\n");
|
BIO_printf(out, "\n");
|
||||||
}
|
}
|
||||||
|
if (hmac_key)
|
||||||
|
{
|
||||||
|
BIO_set_md_ctx(bmd,md_ctx);
|
||||||
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
79
apps/enc.c
79
apps/enc.c
@@ -114,9 +114,11 @@ int MAIN(int argc, char **argv)
|
|||||||
unsigned char salt[PKCS5_SALT_LEN];
|
unsigned char salt[PKCS5_SALT_LEN];
|
||||||
char *str=NULL, *passarg = NULL, *pass = NULL;
|
char *str=NULL, *passarg = NULL, *pass = NULL;
|
||||||
char *hkey=NULL,*hiv=NULL,*hsalt = NULL;
|
char *hkey=NULL,*hiv=NULL,*hsalt = NULL;
|
||||||
|
char *md=NULL;
|
||||||
int enc=1,printkey=0,i,base64=0;
|
int enc=1,printkey=0,i,base64=0;
|
||||||
int debug=0,olb64=0,nosalt=0;
|
int debug=0,olb64=0,nosalt=0;
|
||||||
const EVP_CIPHER *cipher=NULL,*c;
|
const EVP_CIPHER *cipher=NULL,*c;
|
||||||
|
EVP_CIPHER_CTX *ctx = NULL;
|
||||||
char *inf=NULL,*outf=NULL;
|
char *inf=NULL,*outf=NULL;
|
||||||
BIO *in=NULL,*out=NULL,*b64=NULL,*benc=NULL,*rbio=NULL,*wbio=NULL;
|
BIO *in=NULL,*out=NULL,*b64=NULL,*benc=NULL,*rbio=NULL,*wbio=NULL;
|
||||||
#define PROG_NAME_SIZE 39
|
#define PROG_NAME_SIZE 39
|
||||||
@@ -124,6 +126,8 @@ int MAIN(int argc, char **argv)
|
|||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
char *engine = NULL;
|
char *engine = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
const EVP_MD *dgst=NULL;
|
||||||
|
int non_fips_allow = 0;
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
|
|
||||||
@@ -253,6 +257,13 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
hiv= *(++argv);
|
hiv= *(++argv);
|
||||||
}
|
}
|
||||||
|
else if (strcmp(*argv,"-md") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
md= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-non-fips-allow") == 0)
|
||||||
|
non_fips_allow = 1;
|
||||||
else if ((argv[0][0] == '-') &&
|
else if ((argv[0][0] == '-') &&
|
||||||
((c=EVP_get_cipherbyname(&(argv[0][1]))) != NULL))
|
((c=EVP_get_cipherbyname(&(argv[0][1]))) != NULL))
|
||||||
{
|
{
|
||||||
@@ -271,8 +282,10 @@ bad:
|
|||||||
BIO_printf(bio_err,"%-14s encrypt\n","-e");
|
BIO_printf(bio_err,"%-14s encrypt\n","-e");
|
||||||
BIO_printf(bio_err,"%-14s decrypt\n","-d");
|
BIO_printf(bio_err,"%-14s decrypt\n","-d");
|
||||||
BIO_printf(bio_err,"%-14s base64 encode/decode, depending on encryption flag\n","-a/-base64");
|
BIO_printf(bio_err,"%-14s base64 encode/decode, depending on encryption flag\n","-a/-base64");
|
||||||
BIO_printf(bio_err,"%-14s key is the next argument\n","-k");
|
BIO_printf(bio_err,"%-14s passphrase is the next argument\n","-k");
|
||||||
BIO_printf(bio_err,"%-14s key is the first line of the file argument\n","-kfile");
|
BIO_printf(bio_err,"%-14s passphrase is the first line of the file argument\n","-kfile");
|
||||||
|
BIO_printf(bio_err,"%-14s the next argument is the md to use to create a key\n","-md");
|
||||||
|
BIO_printf(bio_err,"%-14s from a passphrase. One of md2, md5, sha or sha1\n","");
|
||||||
BIO_printf(bio_err,"%-14s key/iv in hex is the next argument\n","-K/-iv");
|
BIO_printf(bio_err,"%-14s key/iv in hex is the next argument\n","-K/-iv");
|
||||||
BIO_printf(bio_err,"%-14s print the iv/key (then exit if -P)\n","-[pP]");
|
BIO_printf(bio_err,"%-14s print the iv/key (then exit if -P)\n","-[pP]");
|
||||||
BIO_printf(bio_err,"%-14s buffer size\n","-bufsize <n>");
|
BIO_printf(bio_err,"%-14s buffer size\n","-bufsize <n>");
|
||||||
@@ -296,6 +309,20 @@ bad:
|
|||||||
e = setup_engine(bio_err, engine, 0);
|
e = setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
if (md && (dgst=EVP_get_digestbyname(md)) == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"%s is an unsupported message digest type\n",md);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (dgst == NULL)
|
||||||
|
{
|
||||||
|
if (in_FIPS_mode)
|
||||||
|
dgst = EVP_sha1();
|
||||||
|
else
|
||||||
|
dgst = EVP_md5();
|
||||||
|
}
|
||||||
|
|
||||||
if (bufsize != NULL)
|
if (bufsize != NULL)
|
||||||
{
|
{
|
||||||
unsigned long n;
|
unsigned long n;
|
||||||
@@ -373,9 +400,9 @@ bad:
|
|||||||
{
|
{
|
||||||
char buf[200];
|
char buf[200];
|
||||||
|
|
||||||
sprintf(buf,"enter %s %s password:",
|
BIO_snprintf(buf,sizeof buf,"enter %s %s password:",
|
||||||
OBJ_nid2ln(EVP_CIPHER_nid(cipher)),
|
OBJ_nid2ln(EVP_CIPHER_nid(cipher)),
|
||||||
(enc)?"encryption":"decryption");
|
(enc)?"encryption":"decryption");
|
||||||
strbuf[0]='\0';
|
strbuf[0]='\0';
|
||||||
i=EVP_read_pw_string((char *)strbuf,SIZE,buf,enc);
|
i=EVP_read_pw_string((char *)strbuf,SIZE,buf,enc);
|
||||||
if (i == 0)
|
if (i == 0)
|
||||||
@@ -483,7 +510,7 @@ bad:
|
|||||||
sptr = salt;
|
sptr = salt;
|
||||||
}
|
}
|
||||||
|
|
||||||
EVP_BytesToKey(cipher,EVP_md5(),sptr,
|
EVP_BytesToKey(cipher,dgst,sptr,
|
||||||
(unsigned char *)str,
|
(unsigned char *)str,
|
||||||
strlen(str),1,key,iv);
|
strlen(str),1,key,iv);
|
||||||
/* zero the complete buffer or the string
|
/* zero the complete buffer or the string
|
||||||
@@ -516,13 +543,43 @@ bad:
|
|||||||
|
|
||||||
if ((benc=BIO_new(BIO_f_cipher())) == NULL)
|
if ((benc=BIO_new(BIO_f_cipher())) == NULL)
|
||||||
goto end;
|
goto end;
|
||||||
BIO_set_cipher(benc,cipher,key,iv,enc);
|
|
||||||
if (nopad)
|
/* Since we may be changing parameters work on the encryption
|
||||||
|
* context rather than calling BIO_set_cipher().
|
||||||
|
*/
|
||||||
|
|
||||||
|
BIO_get_cipher_ctx(benc, &ctx);
|
||||||
|
if (!EVP_CipherInit_ex(ctx, cipher, NULL, NULL, NULL, enc))
|
||||||
{
|
{
|
||||||
EVP_CIPHER_CTX *ctx;
|
BIO_printf(bio_err, "Error setting cipher %s\n",
|
||||||
BIO_get_cipher_ctx(benc, &ctx);
|
EVP_CIPHER_name(cipher));
|
||||||
EVP_CIPHER_CTX_set_padding(ctx, 0);
|
ERR_print_errors(bio_err);
|
||||||
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (non_fips_allow)
|
||||||
|
EVP_CIPHER_CTX_set_flags(ctx,
|
||||||
|
EVP_CIPH_FLAG_NON_FIPS_ALLOW);
|
||||||
|
|
||||||
|
if (!EVP_CipherInit_ex(ctx, NULL, NULL, key, iv, enc))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error setting cipher %s\n",
|
||||||
|
EVP_CIPHER_name(cipher));
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (nopad)
|
||||||
|
EVP_CIPHER_CTX_set_padding(ctx, 0);
|
||||||
|
|
||||||
|
if (!EVP_CipherInit_ex(ctx, NULL, NULL, key, iv, enc))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error setting cipher %s\n",
|
||||||
|
EVP_CIPHER_name(cipher));
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
if (debug)
|
if (debug)
|
||||||
{
|
{
|
||||||
BIO_set_callback(benc,BIO_debug_callback);
|
BIO_set_callback(benc,BIO_debug_callback);
|
||||||
|
|||||||
@@ -122,8 +122,8 @@ static int append_buf(char **buf, const char *s, int *size, int step)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
if (**buf != '\0')
|
if (**buf != '\0')
|
||||||
strcat(*buf, ", ");
|
BUF_strlcat(*buf, ", ", *size);
|
||||||
strcat(*buf, s);
|
BUF_strlcat(*buf, s, *size);
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
@@ -387,11 +387,15 @@ int MAIN(int argc, char **argv)
|
|||||||
else if (strcmp(*argv,"-pre") == 0)
|
else if (strcmp(*argv,"-pre") == 0)
|
||||||
{
|
{
|
||||||
argc--; argv++;
|
argc--; argv++;
|
||||||
|
if (argc == 0)
|
||||||
|
goto skip_arg_loop;
|
||||||
sk_push(pre_cmds,*argv);
|
sk_push(pre_cmds,*argv);
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-post") == 0)
|
else if (strcmp(*argv,"-post") == 0)
|
||||||
{
|
{
|
||||||
argc--; argv++;
|
argc--; argv++;
|
||||||
|
if (argc == 0)
|
||||||
|
goto skip_arg_loop;
|
||||||
sk_push(post_cmds,*argv);
|
sk_push(post_cmds,*argv);
|
||||||
}
|
}
|
||||||
else if ((strncmp(*argv,"-h",2) == 0) ||
|
else if ((strncmp(*argv,"-h",2) == 0) ||
|
||||||
@@ -520,4 +524,10 @@ end:
|
|||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -88,6 +88,9 @@ int MAIN(int argc, char **argv)
|
|||||||
RSA *rsa=NULL;
|
RSA *rsa=NULL;
|
||||||
int i,num=DEFBITS;
|
int i,num=DEFBITS;
|
||||||
long l;
|
long l;
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
int use_x931 = 0;
|
||||||
|
#endif
|
||||||
const EVP_CIPHER *enc=NULL;
|
const EVP_CIPHER *enc=NULL;
|
||||||
unsigned long f4=RSA_F4;
|
unsigned long f4=RSA_F4;
|
||||||
char *outfile=NULL;
|
char *outfile=NULL;
|
||||||
@@ -126,6 +129,10 @@ int MAIN(int argc, char **argv)
|
|||||||
f4=3;
|
f4=3;
|
||||||
else if (strcmp(*argv,"-F4") == 0 || strcmp(*argv,"-f4") == 0)
|
else if (strcmp(*argv,"-F4") == 0 || strcmp(*argv,"-f4") == 0)
|
||||||
f4=RSA_F4;
|
f4=RSA_F4;
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
else if (strcmp(*argv,"-x931") == 0)
|
||||||
|
use_x931 = 1;
|
||||||
|
#endif
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
else if (strcmp(*argv,"-engine") == 0)
|
else if (strcmp(*argv,"-engine") == 0)
|
||||||
{
|
{
|
||||||
@@ -233,11 +240,27 @@ bad:
|
|||||||
|
|
||||||
BIO_printf(bio_err,"Generating RSA private key, %d bit long modulus\n",
|
BIO_printf(bio_err,"Generating RSA private key, %d bit long modulus\n",
|
||||||
num);
|
num);
|
||||||
rsa=RSA_generate_key(num,f4,genrsa_cb,bio_err);
|
#ifdef OPENSSL_FIPS
|
||||||
|
if (use_x931)
|
||||||
|
{
|
||||||
|
BIGNUM *pubexp;
|
||||||
|
pubexp = BN_new();
|
||||||
|
BN_set_word(pubexp, f4);
|
||||||
|
rsa = RSA_X931_generate_key(num, pubexp, genrsa_cb, bio_err);
|
||||||
|
BN_free(pubexp);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
#endif
|
||||||
|
rsa=RSA_generate_key(num,f4,genrsa_cb,bio_err);
|
||||||
|
|
||||||
app_RAND_write_file(NULL, bio_err);
|
app_RAND_write_file(NULL, bio_err);
|
||||||
|
|
||||||
if (rsa == NULL) goto err;
|
if (rsa == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Key Generation error\n");
|
||||||
|
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
/* We need to do the following for when the base number size is <
|
/* We need to do the following for when the base number size is <
|
||||||
* long, esp windows 3.1 :-(. */
|
* long, esp windows 3.1 :-(. */
|
||||||
|
|||||||
@@ -142,13 +142,13 @@ $ LIB_FILES = "VERIFY;ASN1PARS;REQ;DGST;DH;DHPARAM;ENC;PASSWD;GENDH;ERRSTR;"+-
|
|||||||
"RSA;RSAUTL;DSA;DSAPARAM;"+-
|
"RSA;RSAUTL;DSA;DSAPARAM;"+-
|
||||||
"X509;GENRSA;GENDSA;S_SERVER;S_CLIENT;SPEED;"+-
|
"X509;GENRSA;GENDSA;S_SERVER;S_CLIENT;SPEED;"+-
|
||||||
"S_TIME;APPS;S_CB;S_SOCKET;APP_RAND;VERSION;SESS_ID;"+-
|
"S_TIME;APPS;S_CB;S_SOCKET;APP_RAND;VERSION;SESS_ID;"+-
|
||||||
"CIPHERS;NSEQ;PKCS12;PKCS8;SPKAC;SMIME;RAND;ENGINE;OCSP"
|
"CIPHERS;NSEQ;PKCS12;PKCS8;SPKAC;SMIME;RAND;ENGINE;OCSP;PRIME"
|
||||||
$ APP_FILES := OPENSSL,'OBJ_DIR'VERIFY.OBJ,ASN1PARS.OBJ,REQ.OBJ,DGST.OBJ,DH.OBJ,DHPARAM.OBJ,ENC.OBJ,PASSWD.OBJ,GENDH.OBJ,ERRSTR.OBJ,-
|
$ APP_FILES := OPENSSL,'OBJ_DIR'VERIFY.OBJ,ASN1PARS.OBJ,REQ.OBJ,DGST.OBJ,DH.OBJ,DHPARAM.OBJ,ENC.OBJ,PASSWD.OBJ,GENDH.OBJ,ERRSTR.OBJ,-
|
||||||
CA.OBJ,PKCS7.OBJ,CRL2P7.OBJ,CRL.OBJ,-
|
CA.OBJ,PKCS7.OBJ,CRL2P7.OBJ,CRL.OBJ,-
|
||||||
RSA.OBJ,RSAUTL.OBJ,DSA.OBJ,DSAPARAM.OBJ,-
|
RSA.OBJ,RSAUTL.OBJ,DSA.OBJ,DSAPARAM.OBJ,-
|
||||||
X509.OBJ,GENRSA.OBJ,GENDSA.OBJ,S_SERVER.OBJ,S_CLIENT.OBJ,SPEED.OBJ,-
|
X509.OBJ,GENRSA.OBJ,GENDSA.OBJ,S_SERVER.OBJ,S_CLIENT.OBJ,SPEED.OBJ,-
|
||||||
S_TIME.OBJ,APPS.OBJ,S_CB.OBJ,S_SOCKET.OBJ,APP_RAND.OBJ,VERSION.OBJ,SESS_ID.OBJ,-
|
S_TIME.OBJ,APPS.OBJ,S_CB.OBJ,S_SOCKET.OBJ,APP_RAND.OBJ,VERSION.OBJ,SESS_ID.OBJ,-
|
||||||
CIPHERS.OBJ,NSEQ.OBJ,PKCS12.OBJ,PKCS8.OBJ,SPKAC.OBJ,SMIME.OBJ,RAND.OBJ,ENGINE.OBJ,OCSP.OBJ
|
CIPHERS.OBJ,NSEQ.OBJ,PKCS12.OBJ,PKCS8.OBJ,SPKAC.OBJ,SMIME.OBJ,RAND.OBJ,ENGINE.OBJ,OCSP.OBJ,PRIME.OBJ
|
||||||
$ TCPIP_PROGRAMS = ",,"
|
$ TCPIP_PROGRAMS = ",,"
|
||||||
$ IF COMPILER .EQS. "VAXC" THEN -
|
$ IF COMPILER .EQS. "VAXC" THEN -
|
||||||
TCPIP_PROGRAMS = ",OPENSSL,"
|
TCPIP_PROGRAMS = ",OPENSSL,"
|
||||||
@@ -650,7 +650,7 @@ $ CCDEFS = "MONOLITH"
|
|||||||
$ IF F$TYPE(USER_CCDEFS) .NES. "" THEN CCDEFS = CCDEFS + "," + USER_CCDEFS
|
$ IF F$TYPE(USER_CCDEFS) .NES. "" THEN CCDEFS = CCDEFS + "," + USER_CCDEFS
|
||||||
$ CCEXTRAFLAGS = ""
|
$ CCEXTRAFLAGS = ""
|
||||||
$ IF F$TYPE(USER_CCFLAGS) .NES. "" THEN CCEXTRAFLAGS = USER_CCFLAGS
|
$ IF F$TYPE(USER_CCFLAGS) .NES. "" THEN CCEXTRAFLAGS = USER_CCFLAGS
|
||||||
$ CCDISABLEWARNINGS = "LONGLONGTYPE,LONGLONGSUFX"
|
$ CCDISABLEWARNINGS = "LONGLONGTYPE,LONGLONGSUFX,FOUNDCR"
|
||||||
$ IF F$TYPE(USER_CCDISABLEWARNINGS) .NES. "" THEN -
|
$ IF F$TYPE(USER_CCDISABLEWARNINGS) .NES. "" THEN -
|
||||||
CCDISABLEWARNINGS = CCDISABLEWARNINGS + "," + USER_CCDISABLEWARNINGS
|
CCDISABLEWARNINGS = CCDISABLEWARNINGS + "," + USER_CCDISABLEWARNINGS
|
||||||
$!
|
$!
|
||||||
@@ -679,7 +679,7 @@ $ IF ARCH.EQS."VAX" .AND. F$TRNLNM("DECC$CC_DEFAULT").NES."/DECC" -
|
|||||||
THEN CC = "CC/DECC"
|
THEN CC = "CC/DECC"
|
||||||
$ CC = CC + "/''CC_OPTIMIZE'/''DEBUGGER'/STANDARD=ANSI89" + -
|
$ CC = CC + "/''CC_OPTIMIZE'/''DEBUGGER'/STANDARD=ANSI89" + -
|
||||||
"/NOLIST/PREFIX=ALL" + -
|
"/NOLIST/PREFIX=ALL" + -
|
||||||
"/INCLUDE=(SYS$DISK:[-])" + CCEXTRAFLAGS
|
"/INCLUDE=(SYS$DISK:[-],SYS$DISK:[-.CRYPTO])" + CCEXTRAFLAGS
|
||||||
$!
|
$!
|
||||||
$! Define The Linker Options File Name.
|
$! Define The Linker Options File Name.
|
||||||
$!
|
$!
|
||||||
@@ -711,7 +711,7 @@ $ EXIT
|
|||||||
$ ENDIF
|
$ ENDIF
|
||||||
$ IF F$TRNLNM("DECC$CC_DEFAULT").EQS."/DECC" THEN CC = "CC/VAXC"
|
$ IF F$TRNLNM("DECC$CC_DEFAULT").EQS."/DECC" THEN CC = "CC/VAXC"
|
||||||
$ CC = CC + "/''CC_OPTIMIZE'/''DEBUGGER'/NOLIST" + -
|
$ CC = CC + "/''CC_OPTIMIZE'/''DEBUGGER'/NOLIST" + -
|
||||||
"/INCLUDE=(SYS$DISK:[-])" + CCEXTRAFLAGS
|
"/INCLUDE=(SYS$DISK:[-],SYS$DISK:[-.CRYPTO])" + CCEXTRAFLAGS
|
||||||
$ CCDEFS = CCDEFS + ",""VAXC"""
|
$ CCDEFS = CCDEFS + ",""VAXC"""
|
||||||
$!
|
$!
|
||||||
$! Define <sys> As SYS$COMMON:[SYSLIB]
|
$! Define <sys> As SYS$COMMON:[SYSLIB]
|
||||||
@@ -743,7 +743,7 @@ $! Use GNU C...
|
|||||||
$!
|
$!
|
||||||
$ IF F$TYPE(GCC) .EQS. "" THEN GCC := GCC
|
$ IF F$TYPE(GCC) .EQS. "" THEN GCC := GCC
|
||||||
$ CC = GCC+"/NOCASE_HACK/''GCC_OPTIMIZE'/''DEBUGGER'/NOLIST" + -
|
$ CC = GCC+"/NOCASE_HACK/''GCC_OPTIMIZE'/''DEBUGGER'/NOLIST" + -
|
||||||
"/INCLUDE=(SYS$DISK:[-])" + CCEXTRAFLAGS
|
"/INCLUDE=(SYS$DISK:[-],SYS$DISK:[-.CRYPTO])" + CCEXTRAFLAGS
|
||||||
$!
|
$!
|
||||||
$! Define The Linker Options File Name.
|
$! Define The Linker Options File Name.
|
||||||
$!
|
$!
|
||||||
|
|||||||
57
apps/ocsp.c
57
apps/ocsp.c
@@ -68,19 +68,6 @@
|
|||||||
/* Maximum leeway in validity period: default 5 minutes */
|
/* Maximum leeway in validity period: default 5 minutes */
|
||||||
#define MAX_VALIDITY_PERIOD (5 * 60)
|
#define MAX_VALIDITY_PERIOD (5 * 60)
|
||||||
|
|
||||||
/* CA index.txt definitions */
|
|
||||||
#define DB_type 0
|
|
||||||
#define DB_exp_date 1
|
|
||||||
#define DB_rev_date 2
|
|
||||||
#define DB_serial 3 /* index - unique */
|
|
||||||
#define DB_file 4
|
|
||||||
#define DB_name 5 /* index - unique for active */
|
|
||||||
#define DB_NUMBER 6
|
|
||||||
|
|
||||||
#define DB_TYPE_REV 'R'
|
|
||||||
#define DB_TYPE_EXP 'E'
|
|
||||||
#define DB_TYPE_VAL 'V'
|
|
||||||
|
|
||||||
static int add_ocsp_cert(OCSP_REQUEST **req, X509 *cert, X509 *issuer,
|
static int add_ocsp_cert(OCSP_REQUEST **req, X509 *cert, X509 *issuer,
|
||||||
STACK_OF(OCSP_CERTID) *ids);
|
STACK_OF(OCSP_CERTID) *ids);
|
||||||
static int add_ocsp_serial(OCSP_REQUEST **req, char *serial, X509 *issuer,
|
static int add_ocsp_serial(OCSP_REQUEST **req, char *serial, X509 *issuer,
|
||||||
@@ -89,12 +76,12 @@ static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
|||||||
STACK *names, STACK_OF(OCSP_CERTID) *ids,
|
STACK *names, STACK_OF(OCSP_CERTID) *ids,
|
||||||
long nsec, long maxage);
|
long nsec, long maxage);
|
||||||
|
|
||||||
static int make_ocsp_response(OCSP_RESPONSE **resp, OCSP_REQUEST *req, TXT_DB *db,
|
static int make_ocsp_response(OCSP_RESPONSE **resp, OCSP_REQUEST *req, CA_DB *db,
|
||||||
X509 *ca, X509 *rcert, EVP_PKEY *rkey,
|
X509 *ca, X509 *rcert, EVP_PKEY *rkey,
|
||||||
STACK_OF(X509) *rother, unsigned long flags,
|
STACK_OF(X509) *rother, unsigned long flags,
|
||||||
int nmin, int ndays);
|
int nmin, int ndays);
|
||||||
|
|
||||||
static char **lookup_serial(TXT_DB *db, ASN1_INTEGER *ser);
|
static char **lookup_serial(CA_DB *db, ASN1_INTEGER *ser);
|
||||||
static BIO *init_responder(char *port);
|
static BIO *init_responder(char *port);
|
||||||
static int do_responder(OCSP_REQUEST **preq, BIO **pcbio, BIO *acbio, char *port);
|
static int do_responder(OCSP_REQUEST **preq, BIO **pcbio, BIO *acbio, char *port);
|
||||||
static int send_ocsp_response(BIO *cbio, OCSP_RESPONSE *resp);
|
static int send_ocsp_response(BIO *cbio, OCSP_RESPONSE *resp);
|
||||||
@@ -136,13 +123,14 @@ int MAIN(int argc, char **argv)
|
|||||||
int accept_count = -1;
|
int accept_count = -1;
|
||||||
int badarg = 0;
|
int badarg = 0;
|
||||||
int i;
|
int i;
|
||||||
|
int ignore_err = 0;
|
||||||
STACK *reqnames = NULL;
|
STACK *reqnames = NULL;
|
||||||
STACK_OF(OCSP_CERTID) *ids = NULL;
|
STACK_OF(OCSP_CERTID) *ids = NULL;
|
||||||
|
|
||||||
X509 *rca_cert = NULL;
|
X509 *rca_cert = NULL;
|
||||||
char *ridx_filename = NULL;
|
char *ridx_filename = NULL;
|
||||||
char *rca_filename = NULL;
|
char *rca_filename = NULL;
|
||||||
TXT_DB *rdb = NULL;
|
CA_DB *rdb = NULL;
|
||||||
int nmin = 0, ndays = -1;
|
int nmin = 0, ndays = -1;
|
||||||
|
|
||||||
if (bio_err == NULL) bio_err = BIO_new_fp(stderr, BIO_NOCLOSE);
|
if (bio_err == NULL) bio_err = BIO_new_fp(stderr, BIO_NOCLOSE);
|
||||||
@@ -195,6 +183,8 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
else badarg = 1;
|
else badarg = 1;
|
||||||
}
|
}
|
||||||
|
else if (!strcmp(*args, "-ignore_err"))
|
||||||
|
ignore_err = 1;
|
||||||
else if (!strcmp(*args, "-noverify"))
|
else if (!strcmp(*args, "-noverify"))
|
||||||
noverify = 1;
|
noverify = 1;
|
||||||
else if (!strcmp(*args, "-nonce"))
|
else if (!strcmp(*args, "-nonce"))
|
||||||
@@ -524,7 +514,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf (bio_err, "-serial n serial number to check\n");
|
BIO_printf (bio_err, "-serial n serial number to check\n");
|
||||||
BIO_printf (bio_err, "-signer file certificate to sign OCSP request with\n");
|
BIO_printf (bio_err, "-signer file certificate to sign OCSP request with\n");
|
||||||
BIO_printf (bio_err, "-signkey file private key to sign OCSP request with\n");
|
BIO_printf (bio_err, "-signkey file private key to sign OCSP request with\n");
|
||||||
BIO_printf (bio_err, "-sign_certs file additional certificates to include in signed request\n");
|
BIO_printf (bio_err, "-sign_other file additional certificates to include in signed request\n");
|
||||||
BIO_printf (bio_err, "-no_certs don't include any certificates in signed request\n");
|
BIO_printf (bio_err, "-no_certs don't include any certificates in signed request\n");
|
||||||
BIO_printf (bio_err, "-req_text print text form of request\n");
|
BIO_printf (bio_err, "-req_text print text form of request\n");
|
||||||
BIO_printf (bio_err, "-resp_text print text form of response\n");
|
BIO_printf (bio_err, "-resp_text print text form of response\n");
|
||||||
@@ -544,10 +534,10 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf (bio_err, "-validity_period n maximum validity discrepancy in seconds\n");
|
BIO_printf (bio_err, "-validity_period n maximum validity discrepancy in seconds\n");
|
||||||
BIO_printf (bio_err, "-status_age n maximum status age in seconds\n");
|
BIO_printf (bio_err, "-status_age n maximum status age in seconds\n");
|
||||||
BIO_printf (bio_err, "-noverify don't verify response at all\n");
|
BIO_printf (bio_err, "-noverify don't verify response at all\n");
|
||||||
BIO_printf (bio_err, "-verify_certs file additional certificates to search for signer\n");
|
BIO_printf (bio_err, "-verify_other file additional certificates to search for signer\n");
|
||||||
BIO_printf (bio_err, "-trust_other don't verify additional certificates\n");
|
BIO_printf (bio_err, "-trust_other don't verify additional certificates\n");
|
||||||
BIO_printf (bio_err, "-no_intern don't search certificates contained in response for signer\n");
|
BIO_printf (bio_err, "-no_intern don't search certificates contained in response for signer\n");
|
||||||
BIO_printf (bio_err, "-no_sig_verify don't check signature on response\n");
|
BIO_printf (bio_err, "-no_signature_verify don't check signature on response\n");
|
||||||
BIO_printf (bio_err, "-no_cert_verify don't check signing certificate\n");
|
BIO_printf (bio_err, "-no_cert_verify don't check signing certificate\n");
|
||||||
BIO_printf (bio_err, "-no_chain don't chain verify response\n");
|
BIO_printf (bio_err, "-no_chain don't chain verify response\n");
|
||||||
BIO_printf (bio_err, "-no_cert_checks don't do additional checks on signing certificate\n");
|
BIO_printf (bio_err, "-no_cert_checks don't do additional checks on signing certificate\n");
|
||||||
@@ -697,22 +687,9 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
if (ridx_filename && !rdb)
|
if (ridx_filename && !rdb)
|
||||||
{
|
{
|
||||||
BIO *db_bio = NULL;
|
rdb = load_index(ridx_filename, NULL);
|
||||||
db_bio = BIO_new_file(ridx_filename, "r");
|
if (!rdb) goto end;
|
||||||
if (!db_bio)
|
if (!index_index(rdb)) goto end;
|
||||||
{
|
|
||||||
BIO_printf(bio_err, "Error opening index file %s\n", ridx_filename);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
rdb = TXT_DB_read(db_bio, DB_NUMBER);
|
|
||||||
BIO_free(db_bio);
|
|
||||||
if (!rdb)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err, "Error reading index file %s\n", ridx_filename);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
if (!make_serial_index(rdb))
|
|
||||||
goto end;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rdb)
|
if (rdb)
|
||||||
@@ -809,6 +786,8 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
BIO_printf(out, "Responder Error: %s (%ld)\n",
|
BIO_printf(out, "Responder Error: %s (%ld)\n",
|
||||||
OCSP_response_status_str(i), i);
|
OCSP_response_status_str(i), i);
|
||||||
|
if (ignore_err)
|
||||||
|
goto redo_accept;
|
||||||
ret = 0;
|
ret = 0;
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
@@ -894,7 +873,7 @@ end:
|
|||||||
X509_free(cert);
|
X509_free(cert);
|
||||||
X509_free(rsigner);
|
X509_free(rsigner);
|
||||||
X509_free(rca_cert);
|
X509_free(rca_cert);
|
||||||
TXT_DB_free(rdb);
|
free_index(rdb);
|
||||||
BIO_free_all(cbio);
|
BIO_free_all(cbio);
|
||||||
BIO_free_all(acbio);
|
BIO_free_all(acbio);
|
||||||
BIO_free(out);
|
BIO_free(out);
|
||||||
@@ -1036,7 +1015,7 @@ static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static int make_ocsp_response(OCSP_RESPONSE **resp, OCSP_REQUEST *req, TXT_DB *db,
|
static int make_ocsp_response(OCSP_RESPONSE **resp, OCSP_REQUEST *req, CA_DB *db,
|
||||||
X509 *ca, X509 *rcert, EVP_PKEY *rkey,
|
X509 *ca, X509 *rcert, EVP_PKEY *rkey,
|
||||||
STACK_OF(X509) *rother, unsigned long flags,
|
STACK_OF(X509) *rother, unsigned long flags,
|
||||||
int nmin, int ndays)
|
int nmin, int ndays)
|
||||||
@@ -1128,7 +1107,7 @@ static int make_ocsp_response(OCSP_RESPONSE **resp, OCSP_REQUEST *req, TXT_DB *d
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static char **lookup_serial(TXT_DB *db, ASN1_INTEGER *ser)
|
static char **lookup_serial(CA_DB *db, ASN1_INTEGER *ser)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
BIGNUM *bn = NULL;
|
BIGNUM *bn = NULL;
|
||||||
@@ -1141,7 +1120,7 @@ static char **lookup_serial(TXT_DB *db, ASN1_INTEGER *ser)
|
|||||||
itmp = BN_bn2hex(bn);
|
itmp = BN_bn2hex(bn);
|
||||||
row[DB_serial] = itmp;
|
row[DB_serial] = itmp;
|
||||||
BN_free(bn);
|
BN_free(bn);
|
||||||
rrow=TXT_DB_get_by_index(db,DB_serial,row);
|
rrow=TXT_DB_get_by_index(db->db,DB_serial,row);
|
||||||
OPENSSL_free(itmp);
|
OPENSSL_free(itmp);
|
||||||
return rrow;
|
return rrow;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,8 +3,13 @@
|
|||||||
# This is mostly being used for generation of certificate requests.
|
# This is mostly being used for generation of certificate requests.
|
||||||
#
|
#
|
||||||
|
|
||||||
|
# This definition stops the following lines choking if HOME isn't
|
||||||
|
# defined.
|
||||||
|
HOME = .
|
||||||
RANDFILE = $ENV::HOME/.rnd
|
RANDFILE = $ENV::HOME/.rnd
|
||||||
oid_file = $ENV::HOME/.oid
|
|
||||||
|
# Extra OBJECT IDENTIFIER info:
|
||||||
|
#oid_file = $ENV::HOME/.oid
|
||||||
oid_section = new_oids
|
oid_section = new_oids
|
||||||
|
|
||||||
# To use this configuration file with the "-extfile" option of the
|
# To use this configuration file with the "-extfile" option of the
|
||||||
@@ -29,22 +34,35 @@ default_ca = CA_default # The default ca section
|
|||||||
####################################################################
|
####################################################################
|
||||||
[ CA_default ]
|
[ CA_default ]
|
||||||
|
|
||||||
dir = sys\$disk:[.demoCA # Where everything is kept
|
dir = sys\$disk:[.demoCA # Where everything is kept
|
||||||
certs = $dir.certs] # Where the issued certs are kept
|
certs = $dir.certs] # Where the issued certs are kept
|
||||||
crl_dir = $dir.crl] # Where the issued crl are kept
|
crl_dir = $dir.crl] # Where the issued crl are kept
|
||||||
database = $dir]index.txt # database index file.
|
database = $dir]index.txt # database index file.
|
||||||
new_certs_dir = $dir.newcerts] # default place for new certs.
|
#unique_subject = no # Set to 'no' to allow creation of
|
||||||
|
# several ctificates with same subject.
|
||||||
|
new_certs_dir = $dir.newcerts] # default place for new certs.
|
||||||
|
|
||||||
certificate = $dir]cacert.pem # The CA certificate
|
certificate = $dir]cacert.pem # The CA certificate
|
||||||
serial = $dir]serial. # The current serial number
|
serial = $dir]serial. # The current serial number
|
||||||
|
#crlnumber = $dir]crlnumber. # the current crl number must be
|
||||||
|
# commented out to leave a V1 CRL
|
||||||
crl = $dir]crl.pem # The current CRL
|
crl = $dir]crl.pem # The current CRL
|
||||||
private_key = $dir.private]cakey.pem# The private key
|
private_key = $dir.private]cakey.pem# The private key
|
||||||
RANDFILE = $dir.private].rand # private random number file
|
RANDFILE = $dir.private].rand # private random number file
|
||||||
|
|
||||||
x509_extensions = usr_cert # The extentions to add to the cert
|
x509_extensions = usr_cert # The extentions to add to the cert
|
||||||
|
|
||||||
|
# Comment out the following two lines for the "traditional"
|
||||||
|
# (and highly broken) format.
|
||||||
|
name_opt = ca_default # Subject Name options
|
||||||
|
cert_opt = ca_default # Certificate field options
|
||||||
|
|
||||||
|
# Extension copying option: use with caution.
|
||||||
|
# copy_extensions = copy
|
||||||
|
|
||||||
# Extensions to add to a CRL. Note: Netscape communicator chokes on V2 CRLs
|
# Extensions to add to a CRL. Note: Netscape communicator chokes on V2 CRLs
|
||||||
# so this is commented out by default to leave a V1 CRL.
|
# so this is commented out by default to leave a V1 CRL.
|
||||||
|
# crlnumber must also be commented out to leave a V1 CRL.
|
||||||
# crl_extensions = crl_ext
|
# crl_extensions = crl_ext
|
||||||
|
|
||||||
default_days = 365 # how long to certify for
|
default_days = 365 # how long to certify for
|
||||||
@@ -86,16 +104,19 @@ distinguished_name = req_distinguished_name
|
|||||||
attributes = req_attributes
|
attributes = req_attributes
|
||||||
x509_extensions = v3_ca # The extentions to add to the self signed cert
|
x509_extensions = v3_ca # The extentions to add to the self signed cert
|
||||||
|
|
||||||
# This sets the permitted types in a DirectoryString. There are several
|
# Passwords for private keys if not present they will be prompted for
|
||||||
# options.
|
# input_password = secret
|
||||||
|
# output_password = secret
|
||||||
|
|
||||||
|
# This sets a mask for permitted string types. There are several options.
|
||||||
# default: PrintableString, T61String, BMPString.
|
# default: PrintableString, T61String, BMPString.
|
||||||
# pkix : PrintableString, BMPString.
|
# pkix : PrintableString, BMPString.
|
||||||
# utf8only: only UTF8Strings.
|
# utf8only: only UTF8Strings.
|
||||||
# nobmp : PrintableString, T61String (no BMPStrings).
|
# nombstr : PrintableString, T61String (no BMPStrings or UTF8Strings).
|
||||||
# MASK:XXXX a literal mask value.
|
# MASK:XXXX a literal mask value.
|
||||||
# WARNING: current versions of Netscape crash on BMPStrings or UTF8Strings
|
# WARNING: current versions of Netscape crash on BMPStrings or UTF8Strings
|
||||||
# so use this option with caution!
|
# so use this option with caution!
|
||||||
dirstring_type = nobmp
|
string_mask = nombstr
|
||||||
|
|
||||||
# req_extensions = v3_req # The extensions to add to a certificate request
|
# req_extensions = v3_req # The extensions to add to a certificate request
|
||||||
|
|
||||||
@@ -124,7 +145,7 @@ commonName = Common Name (eg, YOUR name)
|
|||||||
commonName_max = 64
|
commonName_max = 64
|
||||||
|
|
||||||
emailAddress = Email Address
|
emailAddress = Email Address
|
||||||
emailAddress_max = 40
|
emailAddress_max = 64
|
||||||
|
|
||||||
# SET-ex3 = SET extension number 3
|
# SET-ex3 = SET extension number 3
|
||||||
|
|
||||||
@@ -172,6 +193,9 @@ authorityKeyIdentifier=keyid,issuer:always
|
|||||||
# This stuff is for subjectAltName and issuerAltname.
|
# This stuff is for subjectAltName and issuerAltname.
|
||||||
# Import the email address.
|
# Import the email address.
|
||||||
# subjectAltName=email:copy
|
# subjectAltName=email:copy
|
||||||
|
# An alternative to produce certificates that aren't
|
||||||
|
# deprecated according to PKIX.
|
||||||
|
# subjectAltName=email:move
|
||||||
|
|
||||||
# Copy subject details
|
# Copy subject details
|
||||||
# issuerAltName=issuer:copy
|
# issuerAltName=issuer:copy
|
||||||
@@ -234,3 +258,56 @@ basicConstraints = CA:true
|
|||||||
|
|
||||||
# issuerAltName=issuer:copy
|
# issuerAltName=issuer:copy
|
||||||
authorityKeyIdentifier=keyid:always,issuer:always
|
authorityKeyIdentifier=keyid:always,issuer:always
|
||||||
|
|
||||||
|
[ proxy_cert_ext ]
|
||||||
|
# These extensions should be added when creating a proxy certificate
|
||||||
|
|
||||||
|
# This goes against PKIX guidelines but some CAs do it and some software
|
||||||
|
# requires this to avoid interpreting an end user certificate as a CA.
|
||||||
|
|
||||||
|
basicConstraints=CA:FALSE
|
||||||
|
|
||||||
|
# Here are some examples of the usage of nsCertType. If it is omitted
|
||||||
|
# the certificate can be used for anything *except* object signing.
|
||||||
|
|
||||||
|
# This is OK for an SSL server.
|
||||||
|
# nsCertType = server
|
||||||
|
|
||||||
|
# For an object signing certificate this would be used.
|
||||||
|
# nsCertType = objsign
|
||||||
|
|
||||||
|
# For normal client use this is typical
|
||||||
|
# nsCertType = client, email
|
||||||
|
|
||||||
|
# and for everything including object signing:
|
||||||
|
# nsCertType = client, email, objsign
|
||||||
|
|
||||||
|
# This is typical in keyUsage for a client certificate.
|
||||||
|
# keyUsage = nonRepudiation, digitalSignature, keyEncipherment
|
||||||
|
|
||||||
|
# This will be displayed in Netscape's comment listbox.
|
||||||
|
nsComment = "OpenSSL Generated Certificate"
|
||||||
|
|
||||||
|
# PKIX recommendations harmless if included in all certificates.
|
||||||
|
subjectKeyIdentifier=hash
|
||||||
|
authorityKeyIdentifier=keyid,issuer:always
|
||||||
|
|
||||||
|
# This stuff is for subjectAltName and issuerAltname.
|
||||||
|
# Import the email address.
|
||||||
|
# subjectAltName=email:copy
|
||||||
|
# An alternative to produce certificates that aren't
|
||||||
|
# deprecated according to PKIX.
|
||||||
|
# subjectAltName=email:move
|
||||||
|
|
||||||
|
# Copy subject details
|
||||||
|
# issuerAltName=issuer:copy
|
||||||
|
|
||||||
|
#nsCaRevocationUrl = http://www.domain.dom/ca-crl.pem
|
||||||
|
#nsBaseUrl
|
||||||
|
#nsRevocationUrl
|
||||||
|
#nsRenewalUrl
|
||||||
|
#nsCaPolicyUrl
|
||||||
|
#nsSslServerName
|
||||||
|
|
||||||
|
# This really needs to be in place for it to be a proxy certificate.
|
||||||
|
proxyCertInfo=critical,language:id-ppl-anyLanguage,pathlen:3,policy:foo
|
||||||
|
|||||||
@@ -129,6 +129,7 @@
|
|||||||
#include "progs.h"
|
#include "progs.h"
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
|
#include <openssl/fips.h>
|
||||||
|
|
||||||
/* The LHASH callbacks ("hash" & "cmp") have been replaced by functions with the
|
/* The LHASH callbacks ("hash" & "cmp") have been replaced by functions with the
|
||||||
* base prototypes (we cast each variable inside the function to the required
|
* base prototypes (we cast each variable inside the function to the required
|
||||||
@@ -147,6 +148,7 @@ char *default_config_file=NULL;
|
|||||||
#ifdef MONOLITH
|
#ifdef MONOLITH
|
||||||
CONF *config=NULL;
|
CONF *config=NULL;
|
||||||
BIO *bio_err=NULL;
|
BIO *bio_err=NULL;
|
||||||
|
int in_FIPS_mode=0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
@@ -163,7 +165,7 @@ static void lock_dbg_cb(int mode, int type, const char *file, int line)
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (type < 0 || type > CRYPTO_NUM_LOCKS)
|
if (type < 0 || type >= CRYPTO_NUM_LOCKS)
|
||||||
{
|
{
|
||||||
errstr = "type out of bounds";
|
errstr = "type out of bounds";
|
||||||
goto err;
|
goto err;
|
||||||
@@ -231,6 +233,25 @@ int main(int Argc, char *Argv[])
|
|||||||
arg.data=NULL;
|
arg.data=NULL;
|
||||||
arg.count=0;
|
arg.count=0;
|
||||||
|
|
||||||
|
in_FIPS_mode = 0;
|
||||||
|
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
if(getenv("OPENSSL_FIPS")) {
|
||||||
|
#if defined(_WIN32)
|
||||||
|
char filename[MAX_PATH] = "";
|
||||||
|
GetModuleFileNameA( NULL, filename, MAX_PATH) ;
|
||||||
|
p = filename;
|
||||||
|
#else
|
||||||
|
p = Argv[0];
|
||||||
|
#endif
|
||||||
|
if (!FIPS_mode_set(1,p)) {
|
||||||
|
ERR_load_crypto_strings();
|
||||||
|
ERR_print_errors(BIO_new_fp(stderr,BIO_NOCLOSE));
|
||||||
|
EXIT(1);
|
||||||
|
}
|
||||||
|
in_FIPS_mode = 1;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
if (bio_err == NULL)
|
if (bio_err == NULL)
|
||||||
if ((bio_err=BIO_new(BIO_s_file())) != NULL)
|
if ((bio_err=BIO_new(BIO_s_file())) != NULL)
|
||||||
BIO_set_fp(bio_err,stderr,BIO_NOCLOSE|BIO_FP_TEXT);
|
BIO_set_fp(bio_err,stderr,BIO_NOCLOSE|BIO_FP_TEXT);
|
||||||
|
|||||||
@@ -38,10 +38,14 @@ dir = ./demoCA # Where everything is kept
|
|||||||
certs = $dir/certs # Where the issued certs are kept
|
certs = $dir/certs # Where the issued certs are kept
|
||||||
crl_dir = $dir/crl # Where the issued crl are kept
|
crl_dir = $dir/crl # Where the issued crl are kept
|
||||||
database = $dir/index.txt # database index file.
|
database = $dir/index.txt # database index file.
|
||||||
|
#unique_subject = no # Set to 'no' to allow creation of
|
||||||
|
# several ctificates with same subject.
|
||||||
new_certs_dir = $dir/newcerts # default place for new certs.
|
new_certs_dir = $dir/newcerts # default place for new certs.
|
||||||
|
|
||||||
certificate = $dir/cacert.pem # The CA certificate
|
certificate = $dir/cacert.pem # The CA certificate
|
||||||
serial = $dir/serial # The current serial number
|
serial = $dir/serial # The current serial number
|
||||||
|
#crlnumber = $dir/crlnumber # the current crl number must be
|
||||||
|
# commented out to leave a V1 CRL
|
||||||
crl = $dir/crl.pem # The current CRL
|
crl = $dir/crl.pem # The current CRL
|
||||||
private_key = $dir/private/cakey.pem# The private key
|
private_key = $dir/private/cakey.pem# The private key
|
||||||
RANDFILE = $dir/private/.rand # private random number file
|
RANDFILE = $dir/private/.rand # private random number file
|
||||||
@@ -58,6 +62,7 @@ cert_opt = ca_default # Certificate field options
|
|||||||
|
|
||||||
# Extensions to add to a CRL. Note: Netscape communicator chokes on V2 CRLs
|
# Extensions to add to a CRL. Note: Netscape communicator chokes on V2 CRLs
|
||||||
# so this is commented out by default to leave a V1 CRL.
|
# so this is commented out by default to leave a V1 CRL.
|
||||||
|
# crlnumber must also be commented out to leave a V1 CRL.
|
||||||
# crl_extensions = crl_ext
|
# crl_extensions = crl_ext
|
||||||
|
|
||||||
default_days = 365 # how long to certify for
|
default_days = 365 # how long to certify for
|
||||||
@@ -253,3 +258,56 @@ basicConstraints = CA:true
|
|||||||
|
|
||||||
# issuerAltName=issuer:copy
|
# issuerAltName=issuer:copy
|
||||||
authorityKeyIdentifier=keyid:always,issuer:always
|
authorityKeyIdentifier=keyid:always,issuer:always
|
||||||
|
|
||||||
|
[ proxy_cert_ext ]
|
||||||
|
# These extensions should be added when creating a proxy certificate
|
||||||
|
|
||||||
|
# This goes against PKIX guidelines but some CAs do it and some software
|
||||||
|
# requires this to avoid interpreting an end user certificate as a CA.
|
||||||
|
|
||||||
|
basicConstraints=CA:FALSE
|
||||||
|
|
||||||
|
# Here are some examples of the usage of nsCertType. If it is omitted
|
||||||
|
# the certificate can be used for anything *except* object signing.
|
||||||
|
|
||||||
|
# This is OK for an SSL server.
|
||||||
|
# nsCertType = server
|
||||||
|
|
||||||
|
# For an object signing certificate this would be used.
|
||||||
|
# nsCertType = objsign
|
||||||
|
|
||||||
|
# For normal client use this is typical
|
||||||
|
# nsCertType = client, email
|
||||||
|
|
||||||
|
# and for everything including object signing:
|
||||||
|
# nsCertType = client, email, objsign
|
||||||
|
|
||||||
|
# This is typical in keyUsage for a client certificate.
|
||||||
|
# keyUsage = nonRepudiation, digitalSignature, keyEncipherment
|
||||||
|
|
||||||
|
# This will be displayed in Netscape's comment listbox.
|
||||||
|
nsComment = "OpenSSL Generated Certificate"
|
||||||
|
|
||||||
|
# PKIX recommendations harmless if included in all certificates.
|
||||||
|
subjectKeyIdentifier=hash
|
||||||
|
authorityKeyIdentifier=keyid,issuer:always
|
||||||
|
|
||||||
|
# This stuff is for subjectAltName and issuerAltname.
|
||||||
|
# Import the email address.
|
||||||
|
# subjectAltName=email:copy
|
||||||
|
# An alternative to produce certificates that aren't
|
||||||
|
# deprecated according to PKIX.
|
||||||
|
# subjectAltName=email:move
|
||||||
|
|
||||||
|
# Copy subject details
|
||||||
|
# issuerAltName=issuer:copy
|
||||||
|
|
||||||
|
#nsCaRevocationUrl = http://www.domain.dom/ca-crl.pem
|
||||||
|
#nsBaseUrl
|
||||||
|
#nsRevocationUrl
|
||||||
|
#nsRenewalUrl
|
||||||
|
#nsCaPolicyUrl
|
||||||
|
#nsSslServerName
|
||||||
|
|
||||||
|
# This really needs to be in place for it to be a proxy certificate.
|
||||||
|
proxyCertInfo=critical,language:id-ppl-anyLanguage,pathlen:3,policy:foo
|
||||||
|
|||||||
@@ -109,7 +109,7 @@ int MAIN(int argc, char **argv)
|
|||||||
int maciter = PKCS12_DEFAULT_ITER;
|
int maciter = PKCS12_DEFAULT_ITER;
|
||||||
int twopass = 0;
|
int twopass = 0;
|
||||||
int keytype = 0;
|
int keytype = 0;
|
||||||
int cert_pbe = NID_pbe_WithSHA1And40BitRC2_CBC;
|
int cert_pbe;
|
||||||
int key_pbe = NID_pbe_WithSHA1And3_Key_TripleDES_CBC;
|
int key_pbe = NID_pbe_WithSHA1And3_Key_TripleDES_CBC;
|
||||||
int ret = 1;
|
int ret = 1;
|
||||||
int macver = 1;
|
int macver = 1;
|
||||||
@@ -126,6 +126,13 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
|
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
if (FIPS_mode())
|
||||||
|
cert_pbe = NID_pbe_WithSHA1And3_Key_TripleDES_CBC;
|
||||||
|
else
|
||||||
|
#endif
|
||||||
|
cert_pbe = NID_pbe_WithSHA1And40BitRC2_CBC;
|
||||||
|
|
||||||
enc = EVP_des_ede3_cbc();
|
enc = EVP_des_ede3_cbc();
|
||||||
if (bio_err == NULL ) bio_err = BIO_new_fp (stderr, BIO_NOCLOSE);
|
if (bio_err == NULL ) bio_err = BIO_new_fp (stderr, BIO_NOCLOSE);
|
||||||
|
|
||||||
@@ -557,7 +564,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf (bio_err, "Can't read Password\n");
|
BIO_printf (bio_err, "Can't read Password\n");
|
||||||
goto export_end;
|
goto export_end;
|
||||||
}
|
}
|
||||||
if (!twopass) strcpy(macpass, pass);
|
if (!twopass) BUF_strlcpy(macpass, pass, sizeof macpass);
|
||||||
/* Turn certbags into encrypted authsafe */
|
/* Turn certbags into encrypted authsafe */
|
||||||
authsafe = PKCS12_pack_p7encdata(cert_pbe, cpass, -1, NULL, 0,
|
authsafe = PKCS12_pack_p7encdata(cert_pbe, cpass, -1, NULL, 0,
|
||||||
iter, bags);
|
iter, bags);
|
||||||
@@ -658,7 +665,7 @@ int MAIN(int argc, char **argv)
|
|||||||
CRYPTO_pop_info();
|
CRYPTO_pop_info();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (!twopass) strcpy(macpass, pass);
|
if (!twopass) BUF_strlcpy(macpass, pass, sizeof macpass);
|
||||||
|
|
||||||
if (options & INFO) BIO_printf (bio_err, "MAC Iteration %ld\n", p12->mac->iter ? ASN1_INTEGER_get (p12->mac->iter) : 1);
|
if (options & INFO) BIO_printf (bio_err, "MAC Iteration %ld\n", p12->mac->iter ? ASN1_INTEGER_get (p12->mac->iter) : 1);
|
||||||
if(macver) {
|
if(macver) {
|
||||||
@@ -666,7 +673,7 @@ int MAIN(int argc, char **argv)
|
|||||||
CRYPTO_push_info("verify MAC");
|
CRYPTO_push_info("verify MAC");
|
||||||
#endif
|
#endif
|
||||||
/* If we enter empty password try no password first */
|
/* If we enter empty password try no password first */
|
||||||
if(!macpass[0] && PKCS12_verify_mac(p12, NULL, 0)) {
|
if(!mpass[0] && PKCS12_verify_mac(p12, NULL, 0)) {
|
||||||
/* If mac and crypto pass the same set it to NULL too */
|
/* If mac and crypto pass the same set it to NULL too */
|
||||||
if(!twopass) cpass = NULL;
|
if(!twopass) cpass = NULL;
|
||||||
} else if (!PKCS12_verify_mac(p12, mpass, -1)) {
|
} else if (!PKCS12_verify_mac(p12, mpass, -1)) {
|
||||||
@@ -710,9 +717,10 @@ int MAIN(int argc, char **argv)
|
|||||||
int dump_certs_keys_p12 (BIO *out, PKCS12 *p12, char *pass,
|
int dump_certs_keys_p12 (BIO *out, PKCS12 *p12, char *pass,
|
||||||
int passlen, int options, char *pempass)
|
int passlen, int options, char *pempass)
|
||||||
{
|
{
|
||||||
STACK_OF(PKCS7) *asafes;
|
STACK_OF(PKCS7) *asafes = NULL;
|
||||||
STACK_OF(PKCS12_SAFEBAG) *bags;
|
STACK_OF(PKCS12_SAFEBAG) *bags;
|
||||||
int i, bagnid;
|
int i, bagnid;
|
||||||
|
int ret = 0;
|
||||||
PKCS7 *p7;
|
PKCS7 *p7;
|
||||||
|
|
||||||
if (!( asafes = PKCS12_unpack_authsafes(p12))) return 0;
|
if (!( asafes = PKCS12_unpack_authsafes(p12))) return 0;
|
||||||
@@ -730,16 +738,22 @@ int dump_certs_keys_p12 (BIO *out, PKCS12 *p12, char *pass,
|
|||||||
}
|
}
|
||||||
bags = PKCS12_unpack_p7encdata(p7, pass, passlen);
|
bags = PKCS12_unpack_p7encdata(p7, pass, passlen);
|
||||||
} else continue;
|
} else continue;
|
||||||
if (!bags) return 0;
|
if (!bags) goto err;
|
||||||
if (!dump_certs_pkeys_bags (out, bags, pass, passlen,
|
if (!dump_certs_pkeys_bags (out, bags, pass, passlen,
|
||||||
options, pempass)) {
|
options, pempass)) {
|
||||||
sk_PKCS12_SAFEBAG_pop_free (bags, PKCS12_SAFEBAG_free);
|
sk_PKCS12_SAFEBAG_pop_free (bags, PKCS12_SAFEBAG_free);
|
||||||
return 0;
|
goto err;
|
||||||
}
|
}
|
||||||
sk_PKCS12_SAFEBAG_pop_free (bags, PKCS12_SAFEBAG_free);
|
sk_PKCS12_SAFEBAG_pop_free (bags, PKCS12_SAFEBAG_free);
|
||||||
|
bags = NULL;
|
||||||
}
|
}
|
||||||
sk_PKCS7_pop_free (asafes, PKCS7_free);
|
ret = 1;
|
||||||
return 1;
|
|
||||||
|
err:
|
||||||
|
|
||||||
|
if (asafes)
|
||||||
|
sk_PKCS7_pop_free (asafes, PKCS7_free);
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
int dump_certs_pkeys_bags (BIO *out, STACK_OF(PKCS12_SAFEBAG) *bags,
|
int dump_certs_pkeys_bags (BIO *out, STACK_OF(PKCS12_SAFEBAG) *bags,
|
||||||
|
|||||||
@@ -102,6 +102,9 @@ int MAIN(int argc, char **argv)
|
|||||||
if ((bio_err=BIO_new(BIO_s_file())) != NULL)
|
if ((bio_err=BIO_new(BIO_s_file())) != NULL)
|
||||||
BIO_set_fp(bio_err,stderr,BIO_NOCLOSE|BIO_FP_TEXT);
|
BIO_set_fp(bio_err,stderr,BIO_NOCLOSE|BIO_FP_TEXT);
|
||||||
|
|
||||||
|
if (!load_config(bio_err, NULL))
|
||||||
|
goto end;
|
||||||
|
|
||||||
infile=NULL;
|
infile=NULL;
|
||||||
outfile=NULL;
|
outfile=NULL;
|
||||||
informat=FORMAT_PEM;
|
informat=FORMAT_PEM;
|
||||||
|
|||||||
310
apps/pkcs8.c
310
apps/pkcs8.c
@@ -1,6 +1,6 @@
|
|||||||
/* pkcs8.c */
|
/* pkcs8.c */
|
||||||
/* Written by Dr Stephen N Henson (shenson@bigfoot.com) for the OpenSSL
|
/* Written by Dr Stephen N Henson (shenson@bigfoot.com) for the OpenSSL
|
||||||
* project 1999.
|
* project 1999-2004.
|
||||||
*/
|
*/
|
||||||
/* ====================================================================
|
/* ====================================================================
|
||||||
* Copyright (c) 1999 The OpenSSL Project. All rights reserved.
|
* Copyright (c) 1999 The OpenSSL Project. All rights reserved.
|
||||||
@@ -68,7 +68,7 @@
|
|||||||
int MAIN(int, char **);
|
int MAIN(int, char **);
|
||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
ENGINE *e = NULL;
|
ENGINE *e = NULL;
|
||||||
char **args, *infile = NULL, *outfile = NULL;
|
char **args, *infile = NULL, *outfile = NULL;
|
||||||
char *passargin = NULL, *passargout = NULL;
|
char *passargin = NULL, *passargout = NULL;
|
||||||
@@ -100,43 +100,70 @@ int MAIN(int argc, char **argv)
|
|||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
OpenSSL_add_all_algorithms();
|
OpenSSL_add_all_algorithms();
|
||||||
args = argv + 1;
|
args = argv + 1;
|
||||||
while (!badarg && *args && *args[0] == '-') {
|
while (!badarg && *args && *args[0] == '-')
|
||||||
if (!strcmp(*args,"-v2")) {
|
{
|
||||||
if (args[1]) {
|
if (!strcmp(*args,"-v2"))
|
||||||
|
{
|
||||||
|
if (args[1])
|
||||||
|
{
|
||||||
args++;
|
args++;
|
||||||
cipher=EVP_get_cipherbyname(*args);
|
cipher=EVP_get_cipherbyname(*args);
|
||||||
if(!cipher) {
|
if (!cipher)
|
||||||
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
"Unknown cipher %s\n", *args);
|
"Unknown cipher %s\n", *args);
|
||||||
badarg = 1;
|
badarg = 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else badarg = 1;
|
else
|
||||||
} else if (!strcmp(*args,"-v1")) {
|
badarg = 1;
|
||||||
if (args[1]) {
|
}
|
||||||
|
else if (!strcmp(*args,"-v1"))
|
||||||
|
{
|
||||||
|
if (args[1])
|
||||||
|
{
|
||||||
args++;
|
args++;
|
||||||
pbe_nid=OBJ_txt2nid(*args);
|
pbe_nid=OBJ_txt2nid(*args);
|
||||||
if(pbe_nid == NID_undef) {
|
if (pbe_nid == NID_undef)
|
||||||
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
"Unknown PBE algorithm %s\n", *args);
|
"Unknown PBE algorithm %s\n", *args);
|
||||||
badarg = 1;
|
badarg = 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else badarg = 1;
|
else
|
||||||
} else if (!strcmp(*args,"-inform")) {
|
badarg = 1;
|
||||||
if (args[1]) {
|
}
|
||||||
|
else if (!strcmp(*args,"-inform"))
|
||||||
|
{
|
||||||
|
if (args[1])
|
||||||
|
{
|
||||||
args++;
|
args++;
|
||||||
informat=str2fmt(*args);
|
informat=str2fmt(*args);
|
||||||
} else badarg = 1;
|
}
|
||||||
} else if (!strcmp(*args,"-outform")) {
|
else badarg = 1;
|
||||||
if (args[1]) {
|
}
|
||||||
|
else if (!strcmp(*args,"-outform"))
|
||||||
|
{
|
||||||
|
if (args[1])
|
||||||
|
{
|
||||||
args++;
|
args++;
|
||||||
outformat=str2fmt(*args);
|
outformat=str2fmt(*args);
|
||||||
} else badarg = 1;
|
}
|
||||||
} else if (!strcmp (*args, "-topk8")) topk8 = 1;
|
else badarg = 1;
|
||||||
else if (!strcmp (*args, "-noiter")) iter = 1;
|
}
|
||||||
else if (!strcmp (*args, "-nocrypt")) nocrypt = 1;
|
else if (!strcmp (*args, "-topk8"))
|
||||||
else if (!strcmp (*args, "-nooct")) p8_broken = PKCS8_NO_OCTET;
|
topk8 = 1;
|
||||||
else if (!strcmp (*args, "-nsdb")) p8_broken = PKCS8_NS_DB;
|
else if (!strcmp (*args, "-noiter"))
|
||||||
else if (!strcmp (*args, "-embed")) p8_broken = PKCS8_EMBEDDED_PARAM;
|
iter = 1;
|
||||||
|
else if (!strcmp (*args, "-nocrypt"))
|
||||||
|
nocrypt = 1;
|
||||||
|
else if (!strcmp (*args, "-nooct"))
|
||||||
|
p8_broken = PKCS8_NO_OCTET;
|
||||||
|
else if (!strcmp (*args, "-nsdb"))
|
||||||
|
p8_broken = PKCS8_NS_DB;
|
||||||
|
else if (!strcmp (*args, "-embed"))
|
||||||
|
p8_broken = PKCS8_EMBEDDED_PARAM;
|
||||||
else if (!strcmp(*args,"-passin"))
|
else if (!strcmp(*args,"-passin"))
|
||||||
{
|
{
|
||||||
if (!args[1]) goto bad;
|
if (!args[1]) goto bad;
|
||||||
@@ -154,21 +181,30 @@ int MAIN(int argc, char **argv)
|
|||||||
engine= *(++args);
|
engine= *(++args);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
else if (!strcmp (*args, "-in")) {
|
else if (!strcmp (*args, "-in"))
|
||||||
if (args[1]) {
|
{
|
||||||
|
if (args[1])
|
||||||
|
{
|
||||||
args++;
|
args++;
|
||||||
infile = *args;
|
infile = *args;
|
||||||
} else badarg = 1;
|
}
|
||||||
} else if (!strcmp (*args, "-out")) {
|
else badarg = 1;
|
||||||
if (args[1]) {
|
}
|
||||||
|
else if (!strcmp (*args, "-out"))
|
||||||
|
{
|
||||||
|
if (args[1])
|
||||||
|
{
|
||||||
args++;
|
args++;
|
||||||
outfile = *args;
|
outfile = *args;
|
||||||
} else badarg = 1;
|
}
|
||||||
} else badarg = 1;
|
else badarg = 1;
|
||||||
|
}
|
||||||
|
else badarg = 1;
|
||||||
args++;
|
args++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (badarg) {
|
if (badarg)
|
||||||
|
{
|
||||||
bad:
|
bad:
|
||||||
BIO_printf(bio_err, "Usage pkcs8 [options]\n");
|
BIO_printf(bio_err, "Usage pkcs8 [options]\n");
|
||||||
BIO_printf(bio_err, "where options are\n");
|
BIO_printf(bio_err, "where options are\n");
|
||||||
@@ -189,148 +225,199 @@ int MAIN(int argc, char **argv)
|
|||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
BIO_printf(bio_err," -engine e use engine e, possibly a hardware device.\n");
|
BIO_printf(bio_err," -engine e use engine e, possibly a hardware device.\n");
|
||||||
#endif
|
#endif
|
||||||
return (1);
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
e = setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if(!app_passwd(bio_err, passargin, passargout, &passin, &passout)) {
|
if (!app_passwd(bio_err, passargin, passargout, &passin, &passout))
|
||||||
|
{
|
||||||
BIO_printf(bio_err, "Error getting passwords\n");
|
BIO_printf(bio_err, "Error getting passwords\n");
|
||||||
return (1);
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((pbe_nid == -1) && !cipher) pbe_nid = NID_pbeWithMD5AndDES_CBC;
|
if ((pbe_nid == -1) && !cipher)
|
||||||
|
pbe_nid = NID_pbeWithMD5AndDES_CBC;
|
||||||
|
|
||||||
if (infile) {
|
if (infile)
|
||||||
if (!(in = BIO_new_file(infile, "rb"))) {
|
{
|
||||||
|
if (!(in = BIO_new_file(infile, "rb")))
|
||||||
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
"Can't open input file %s\n", infile);
|
"Can't open input file %s\n", infile);
|
||||||
return (1);
|
return (1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else in = BIO_new_fp (stdin, BIO_NOCLOSE);
|
else
|
||||||
|
in = BIO_new_fp (stdin, BIO_NOCLOSE);
|
||||||
|
|
||||||
if (outfile) {
|
if (outfile)
|
||||||
if (!(out = BIO_new_file (outfile, "wb"))) {
|
{
|
||||||
|
if (!(out = BIO_new_file (outfile, "wb")))
|
||||||
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
"Can't open output file %s\n", outfile);
|
"Can't open output file %s\n", outfile);
|
||||||
return (1);
|
return (1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
else
|
||||||
|
{
|
||||||
out = BIO_new_fp (stdout, BIO_NOCLOSE);
|
out = BIO_new_fp (stdout, BIO_NOCLOSE);
|
||||||
#ifdef OPENSSL_SYS_VMS
|
#ifdef OPENSSL_SYS_VMS
|
||||||
{
|
{
|
||||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||||
out = BIO_push(tmpbio, out);
|
out = BIO_push(tmpbio, out);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
if (topk8)
|
if (topk8)
|
||||||
{
|
{
|
||||||
BIO_free(in); /* Not needed in this section */
|
BIO_free(in); /* Not needed in this section */
|
||||||
pkey = load_key(bio_err, infile, informat, 1,
|
pkey = load_key(bio_err, infile, informat, 1,
|
||||||
passin, e, "key");
|
passin, e, "key");
|
||||||
if (!pkey) {
|
if (!pkey)
|
||||||
return (1);
|
{
|
||||||
}
|
BIO_free_all(out);
|
||||||
if (!(p8inf = EVP_PKEY2PKCS8_broken(pkey, p8_broken))) {
|
return 1;
|
||||||
BIO_printf(bio_err, "Error converting key\n", outfile);
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
return (1);
|
|
||||||
}
|
|
||||||
if(nocrypt) {
|
|
||||||
if(outformat == FORMAT_PEM)
|
|
||||||
PEM_write_bio_PKCS8_PRIV_KEY_INFO(out, p8inf);
|
|
||||||
else if(outformat == FORMAT_ASN1)
|
|
||||||
i2d_PKCS8_PRIV_KEY_INFO_bio(out, p8inf);
|
|
||||||
else {
|
|
||||||
BIO_printf(bio_err, "Bad format specified for key\n");
|
|
||||||
return (1);
|
|
||||||
}
|
}
|
||||||
} else {
|
if (!(p8inf = EVP_PKEY2PKCS8_broken(pkey, p8_broken)))
|
||||||
if(passout) p8pass = passout;
|
{
|
||||||
else {
|
BIO_printf(bio_err, "Error converting key\n");
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
EVP_PKEY_free(pkey);
|
||||||
|
BIO_free_all(out);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
if (nocrypt)
|
||||||
|
{
|
||||||
|
if (outformat == FORMAT_PEM)
|
||||||
|
PEM_write_bio_PKCS8_PRIV_KEY_INFO(out, p8inf);
|
||||||
|
else if (outformat == FORMAT_ASN1)
|
||||||
|
i2d_PKCS8_PRIV_KEY_INFO_bio(out, p8inf);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Bad format specified for key\n");
|
||||||
|
PKCS8_PRIV_KEY_INFO_free(p8inf);
|
||||||
|
EVP_PKEY_free(pkey);
|
||||||
|
BIO_free_all(out);
|
||||||
|
return (1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (passout)
|
||||||
|
p8pass = passout;
|
||||||
|
else
|
||||||
|
{
|
||||||
p8pass = pass;
|
p8pass = pass;
|
||||||
if (EVP_read_pw_string(pass, sizeof pass, "Enter Encryption Password:", 1))
|
if (EVP_read_pw_string(pass, sizeof pass, "Enter Encryption Password:", 1))
|
||||||
|
{
|
||||||
|
PKCS8_PRIV_KEY_INFO_free(p8inf);
|
||||||
|
EVP_PKEY_free(pkey);
|
||||||
|
BIO_free_all(out);
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
app_RAND_load_file(NULL, bio_err, 0);
|
app_RAND_load_file(NULL, bio_err, 0);
|
||||||
if (!(p8 = PKCS8_encrypt(pbe_nid, cipher,
|
if (!(p8 = PKCS8_encrypt(pbe_nid, cipher,
|
||||||
p8pass, strlen(p8pass),
|
p8pass, strlen(p8pass),
|
||||||
NULL, 0, iter, p8inf))) {
|
NULL, 0, iter, p8inf)))
|
||||||
BIO_printf(bio_err, "Error encrypting key\n",
|
{
|
||||||
outfile);
|
BIO_printf(bio_err, "Error encrypting key\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
|
PKCS8_PRIV_KEY_INFO_free(p8inf);
|
||||||
|
EVP_PKEY_free(pkey);
|
||||||
|
BIO_free_all(out);
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
app_RAND_write_file(NULL, bio_err);
|
app_RAND_write_file(NULL, bio_err);
|
||||||
if(outformat == FORMAT_PEM)
|
if (outformat == FORMAT_PEM)
|
||||||
PEM_write_bio_PKCS8(out, p8);
|
PEM_write_bio_PKCS8(out, p8);
|
||||||
else if(outformat == FORMAT_ASN1)
|
else if (outformat == FORMAT_ASN1)
|
||||||
i2d_PKCS8_bio(out, p8);
|
i2d_PKCS8_bio(out, p8);
|
||||||
else {
|
else
|
||||||
|
{
|
||||||
BIO_printf(bio_err, "Bad format specified for key\n");
|
BIO_printf(bio_err, "Bad format specified for key\n");
|
||||||
|
PKCS8_PRIV_KEY_INFO_free(p8inf);
|
||||||
|
EVP_PKEY_free(pkey);
|
||||||
|
BIO_free_all(out);
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
X509_SIG_free(p8);
|
X509_SIG_free(p8);
|
||||||
}
|
}
|
||||||
|
|
||||||
PKCS8_PRIV_KEY_INFO_free (p8inf);
|
PKCS8_PRIV_KEY_INFO_free (p8inf);
|
||||||
EVP_PKEY_free(pkey);
|
EVP_PKEY_free(pkey);
|
||||||
BIO_free_all(out);
|
BIO_free_all(out);
|
||||||
if(passin) OPENSSL_free(passin);
|
if (passin)
|
||||||
if(passout) OPENSSL_free(passout);
|
OPENSSL_free(passin);
|
||||||
|
if (passout)
|
||||||
|
OPENSSL_free(passout);
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(nocrypt) {
|
if (nocrypt)
|
||||||
if(informat == FORMAT_PEM)
|
{
|
||||||
|
if (informat == FORMAT_PEM)
|
||||||
p8inf = PEM_read_bio_PKCS8_PRIV_KEY_INFO(in,NULL,NULL, NULL);
|
p8inf = PEM_read_bio_PKCS8_PRIV_KEY_INFO(in,NULL,NULL, NULL);
|
||||||
else if(informat == FORMAT_ASN1)
|
else if (informat == FORMAT_ASN1)
|
||||||
p8inf = d2i_PKCS8_PRIV_KEY_INFO_bio(in, NULL);
|
p8inf = d2i_PKCS8_PRIV_KEY_INFO_bio(in, NULL);
|
||||||
else {
|
else
|
||||||
|
{
|
||||||
BIO_printf(bio_err, "Bad format specified for key\n");
|
BIO_printf(bio_err, "Bad format specified for key\n");
|
||||||
return (1);
|
return (1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
else
|
||||||
if(informat == FORMAT_PEM)
|
{
|
||||||
|
if (informat == FORMAT_PEM)
|
||||||
p8 = PEM_read_bio_PKCS8(in, NULL, NULL, NULL);
|
p8 = PEM_read_bio_PKCS8(in, NULL, NULL, NULL);
|
||||||
else if(informat == FORMAT_ASN1)
|
else if (informat == FORMAT_ASN1)
|
||||||
p8 = d2i_PKCS8_bio(in, NULL);
|
p8 = d2i_PKCS8_bio(in, NULL);
|
||||||
else {
|
else
|
||||||
|
{
|
||||||
BIO_printf(bio_err, "Bad format specified for key\n");
|
BIO_printf(bio_err, "Bad format specified for key\n");
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!p8) {
|
if (!p8)
|
||||||
BIO_printf (bio_err, "Error reading key\n", outfile);
|
{
|
||||||
|
BIO_printf (bio_err, "Error reading key\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
if(passin) p8pass = passin;
|
if (passin)
|
||||||
else {
|
p8pass = passin;
|
||||||
|
else
|
||||||
|
{
|
||||||
p8pass = pass;
|
p8pass = pass;
|
||||||
EVP_read_pw_string(pass, sizeof pass, "Enter Password:", 0);
|
EVP_read_pw_string(pass, sizeof pass, "Enter Password:", 0);
|
||||||
}
|
}
|
||||||
p8inf = PKCS8_decrypt(p8, p8pass, strlen(p8pass));
|
p8inf = PKCS8_decrypt(p8, p8pass, strlen(p8pass));
|
||||||
X509_SIG_free(p8);
|
X509_SIG_free(p8);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!p8inf) {
|
if (!p8inf)
|
||||||
BIO_printf(bio_err, "Error decrypting key\n", outfile);
|
{
|
||||||
|
BIO_printf(bio_err, "Error decrypting key\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(pkey = EVP_PKCS82PKEY(p8inf))) {
|
if (!(pkey = EVP_PKCS82PKEY(p8inf)))
|
||||||
BIO_printf(bio_err, "Error converting key\n", outfile);
|
{
|
||||||
|
BIO_printf(bio_err, "Error converting key\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (p8inf->broken) {
|
if (p8inf->broken)
|
||||||
|
{
|
||||||
BIO_printf(bio_err, "Warning: broken key encoding: ");
|
BIO_printf(bio_err, "Warning: broken key encoding: ");
|
||||||
switch (p8inf->broken) {
|
switch (p8inf->broken)
|
||||||
|
{
|
||||||
case PKCS8_NO_OCTET:
|
case PKCS8_NO_OCTET:
|
||||||
BIO_printf(bio_err, "No Octet String in PrivateKey\n");
|
BIO_printf(bio_err, "No Octet String in PrivateKey\n");
|
||||||
break;
|
break;
|
||||||
@@ -350,21 +437,24 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
PKCS8_PRIV_KEY_INFO_free(p8inf);
|
PKCS8_PRIV_KEY_INFO_free(p8inf);
|
||||||
if(outformat == FORMAT_PEM)
|
if (outformat == FORMAT_PEM)
|
||||||
PEM_write_bio_PrivateKey(out, pkey, NULL, NULL, 0, NULL, passout);
|
PEM_write_bio_PrivateKey(out, pkey, NULL, NULL, 0, NULL, passout);
|
||||||
else if(outformat == FORMAT_ASN1)
|
else if (outformat == FORMAT_ASN1)
|
||||||
i2d_PrivateKey_bio(out, pkey);
|
i2d_PrivateKey_bio(out, pkey);
|
||||||
else {
|
else
|
||||||
|
{
|
||||||
BIO_printf(bio_err, "Bad format specified for key\n");
|
BIO_printf(bio_err, "Bad format specified for key\n");
|
||||||
return (1);
|
return (1);
|
||||||
}
|
}
|
||||||
|
|
||||||
end:
|
end:
|
||||||
EVP_PKEY_free(pkey);
|
EVP_PKEY_free(pkey);
|
||||||
BIO_free_all(out);
|
BIO_free_all(out);
|
||||||
BIO_free(in);
|
BIO_free(in);
|
||||||
if(passin) OPENSSL_free(passin);
|
if (passin)
|
||||||
if(passout) OPENSSL_free(passout);
|
OPENSSL_free(passin);
|
||||||
|
if (passout)
|
||||||
|
OPENSSL_free(passout);
|
||||||
|
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
|||||||
128
apps/prime.c
Normal file
128
apps/prime.c
Normal file
@@ -0,0 +1,128 @@
|
|||||||
|
/* ====================================================================
|
||||||
|
* Copyright (c) 2004 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
|
||||||
|
* are met:
|
||||||
|
*
|
||||||
|
* 1. Redistributions of source code must retain the above 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 acknowledgment:
|
||||||
|
* "This product includes software developed by the OpenSSL Project
|
||||||
|
* for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
|
||||||
|
*
|
||||||
|
* 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
|
||||||
|
* endorse or promote products derived from this software without
|
||||||
|
* prior written permission. For written permission, please contact
|
||||||
|
* openssl-core@openssl.org.
|
||||||
|
*
|
||||||
|
* 5. Products derived from this software may not be called "OpenSSL"
|
||||||
|
* nor may "OpenSSL" appear in their names without prior written
|
||||||
|
* permission of the OpenSSL Project.
|
||||||
|
*
|
||||||
|
* 6. Redistributions of any form whatsoever must retain the following
|
||||||
|
* acknowledgment:
|
||||||
|
* "This product includes software developed by the OpenSSL Project
|
||||||
|
* for use in the OpenSSL Toolkit (http://www.openssl.org/)"
|
||||||
|
*
|
||||||
|
* THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
|
||||||
|
* EXPRESSED 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 OpenSSL PROJECT OR
|
||||||
|
* ITS 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.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
#include "apps.h"
|
||||||
|
#include <openssl/bn.h>
|
||||||
|
|
||||||
|
|
||||||
|
#undef PROG
|
||||||
|
#define PROG prime_main
|
||||||
|
|
||||||
|
int MAIN(int argc, char **argv)
|
||||||
|
{
|
||||||
|
int hex=0;
|
||||||
|
int checks=20;
|
||||||
|
BIGNUM *bn=NULL;
|
||||||
|
BIO *bio_out;
|
||||||
|
|
||||||
|
apps_startup();
|
||||||
|
|
||||||
|
if (bio_err == NULL)
|
||||||
|
if ((bio_err=BIO_new(BIO_s_file())) != NULL)
|
||||||
|
BIO_set_fp(bio_err,stderr,BIO_NOCLOSE|BIO_FP_TEXT);
|
||||||
|
|
||||||
|
--argc;
|
||||||
|
++argv;
|
||||||
|
while (argc >= 1 && **argv == '-')
|
||||||
|
{
|
||||||
|
if(!strcmp(*argv,"-hex"))
|
||||||
|
hex=1;
|
||||||
|
else if(!strcmp(*argv,"-checks"))
|
||||||
|
if(--argc < 1)
|
||||||
|
goto bad;
|
||||||
|
else
|
||||||
|
checks=atoi(*++argv);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"Unknown option '%s'\n",*argv);
|
||||||
|
goto bad;
|
||||||
|
}
|
||||||
|
--argc;
|
||||||
|
++argv;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (argv[0] == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"No prime specified\n");
|
||||||
|
goto bad;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((bio_out=BIO_new(BIO_s_file())) != NULL)
|
||||||
|
{
|
||||||
|
BIO_set_fp(bio_out,stdout,BIO_NOCLOSE);
|
||||||
|
#ifdef OPENSSL_SYS_VMS
|
||||||
|
{
|
||||||
|
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||||
|
bio_out = BIO_push(tmpbio, bio_out);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
if(hex)
|
||||||
|
BN_hex2bn(&bn,argv[0]);
|
||||||
|
else
|
||||||
|
BN_dec2bn(&bn,argv[0]);
|
||||||
|
|
||||||
|
BN_print(bio_out,bn);
|
||||||
|
BIO_printf(bio_out," is %sprime\n",
|
||||||
|
BN_is_prime(bn,checks,NULL,NULL,NULL) ? "" : "not ");
|
||||||
|
|
||||||
|
BN_free(bn);
|
||||||
|
BIO_free_all(bio_out);
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
bad:
|
||||||
|
BIO_printf(bio_err,"options are\n");
|
||||||
|
BIO_printf(bio_err,"%-14s hex\n","-hex");
|
||||||
|
BIO_printf(bio_err,"%-14s number of checks\n","-checks <n>");
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
@@ -35,6 +35,7 @@ extern int pkcs8_main(int argc,char *argv[]);
|
|||||||
extern int spkac_main(int argc,char *argv[]);
|
extern int spkac_main(int argc,char *argv[]);
|
||||||
extern int smime_main(int argc,char *argv[]);
|
extern int smime_main(int argc,char *argv[]);
|
||||||
extern int rand_main(int argc,char *argv[]);
|
extern int rand_main(int argc,char *argv[]);
|
||||||
|
extern int prime_main(int argc,char *argv[]);
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
extern int engine_main(int argc,char *argv[]);
|
extern int engine_main(int argc,char *argv[]);
|
||||||
#endif
|
#endif
|
||||||
@@ -115,6 +116,7 @@ FUNCTION functions[] = {
|
|||||||
{FUNC_TYPE_GENERAL,"spkac",spkac_main},
|
{FUNC_TYPE_GENERAL,"spkac",spkac_main},
|
||||||
{FUNC_TYPE_GENERAL,"smime",smime_main},
|
{FUNC_TYPE_GENERAL,"smime",smime_main},
|
||||||
{FUNC_TYPE_GENERAL,"rand",rand_main},
|
{FUNC_TYPE_GENERAL,"rand",rand_main},
|
||||||
|
{FUNC_TYPE_GENERAL,"prime",prime_main},
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
{FUNC_TYPE_GENERAL,"engine",engine_main},
|
{FUNC_TYPE_GENERAL,"engine",engine_main},
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
66
apps/req.c
66
apps/req.c
@@ -175,7 +175,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *passin = NULL, *passout = NULL;
|
char *passin = NULL, *passout = NULL;
|
||||||
char *p;
|
char *p;
|
||||||
char *subj = NULL;
|
char *subj = NULL;
|
||||||
const EVP_MD *md_alg=NULL,*digest=EVP_md5();
|
const EVP_MD *md_alg=NULL,*digest;
|
||||||
unsigned long chtype = MBSTRING_ASC;
|
unsigned long chtype = MBSTRING_ASC;
|
||||||
#ifndef MONOLITH
|
#ifndef MONOLITH
|
||||||
char *to_free;
|
char *to_free;
|
||||||
@@ -197,6 +197,13 @@ int MAIN(int argc, char **argv)
|
|||||||
informat=FORMAT_PEM;
|
informat=FORMAT_PEM;
|
||||||
outformat=FORMAT_PEM;
|
outformat=FORMAT_PEM;
|
||||||
|
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
if (FIPS_mode())
|
||||||
|
digest = EVP_sha1();
|
||||||
|
else
|
||||||
|
#endif
|
||||||
|
digest = EVP_md5();
|
||||||
|
|
||||||
prog=argv[0];
|
prog=argv[0];
|
||||||
argc--;
|
argc--;
|
||||||
argv++;
|
argv++;
|
||||||
@@ -499,13 +506,16 @@ bad:
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
req_conf=config;
|
req_conf=config;
|
||||||
if( verbose )
|
|
||||||
BIO_printf(bio_err,"Using configuration from %s\n",
|
|
||||||
default_config_file);
|
|
||||||
if (req_conf == NULL)
|
if (req_conf == NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Unable to load config info\n");
|
BIO_printf(bio_err,"Unable to load config info from %s\n", default_config_file);
|
||||||
|
if (newreq)
|
||||||
|
goto end;
|
||||||
}
|
}
|
||||||
|
else if( verbose )
|
||||||
|
BIO_printf(bio_err,"Using configuration from %s\n",
|
||||||
|
default_config_file);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (req_conf != NULL)
|
if (req_conf != NULL)
|
||||||
@@ -824,14 +834,16 @@ loop:
|
|||||||
if ((x509ss=X509_new()) == NULL) goto end;
|
if ((x509ss=X509_new()) == NULL) goto end;
|
||||||
|
|
||||||
/* Set version to V3 */
|
/* Set version to V3 */
|
||||||
if(!X509_set_version(x509ss, 2)) goto end;
|
if(extensions && !X509_set_version(x509ss, 2)) goto end;
|
||||||
if (serial)
|
if (serial)
|
||||||
{
|
{
|
||||||
if (!X509_set_serialNumber(x509ss, serial)) goto end;
|
if (!X509_set_serialNumber(x509ss, serial)) goto end;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!ASN1_INTEGER_set(X509_get_serialNumber(x509ss),0L)) goto end;
|
if (!rand_serial(NULL,
|
||||||
|
X509_get_serialNumber(x509ss)))
|
||||||
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!X509_set_issuer_name(x509ss, X509_REQ_get_subject_name(req))) goto end;
|
if (!X509_set_issuer_name(x509ss, X509_REQ_get_subject_name(req))) goto end;
|
||||||
@@ -1223,34 +1235,34 @@ start: for (;;)
|
|||||||
}
|
}
|
||||||
/* If OBJ not recognised ignore it */
|
/* If OBJ not recognised ignore it */
|
||||||
if ((nid=OBJ_txt2nid(type)) == NID_undef) goto start;
|
if ((nid=OBJ_txt2nid(type)) == NID_undef) goto start;
|
||||||
|
if (BIO_snprintf(buf,sizeof buf,"%s_default",v->name)
|
||||||
if(strlen(v->name) > sizeof buf-9)
|
>= sizeof buf)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Name '%s' too long\n",v->name);
|
BIO_printf(bio_err,"Name '%s' too long\n",v->name);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(buf,"%s_default",v->name);
|
|
||||||
if ((def=NCONF_get_string(req_conf,dn_sect,buf)) == NULL)
|
if ((def=NCONF_get_string(req_conf,dn_sect,buf)) == NULL)
|
||||||
{
|
{
|
||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
def="";
|
def="";
|
||||||
}
|
}
|
||||||
sprintf(buf,"%s_value",v->name);
|
|
||||||
|
BIO_snprintf(buf,sizeof buf,"%s_value",v->name);
|
||||||
if ((value=NCONF_get_string(req_conf,dn_sect,buf)) == NULL)
|
if ((value=NCONF_get_string(req_conf,dn_sect,buf)) == NULL)
|
||||||
{
|
{
|
||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
value=NULL;
|
value=NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(buf,"%s_min",v->name);
|
BIO_snprintf(buf,sizeof buf,"%s_min",v->name);
|
||||||
if (!NCONF_get_number(req_conf,dn_sect,buf, &n_min))
|
if (!NCONF_get_number(req_conf,dn_sect,buf, &n_min))
|
||||||
{
|
{
|
||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
n_min = -1;
|
n_min = -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(buf,"%s_max",v->name);
|
BIO_snprintf(buf,sizeof buf,"%s_max",v->name);
|
||||||
if (!NCONF_get_number(req_conf,dn_sect,buf, &n_max))
|
if (!NCONF_get_number(req_conf,dn_sect,buf, &n_max))
|
||||||
{
|
{
|
||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
@@ -1288,13 +1300,13 @@ start2: for (;;)
|
|||||||
if ((nid=OBJ_txt2nid(type)) == NID_undef)
|
if ((nid=OBJ_txt2nid(type)) == NID_undef)
|
||||||
goto start2;
|
goto start2;
|
||||||
|
|
||||||
if(strlen(v->name) > sizeof buf-9)
|
if (BIO_snprintf(buf,sizeof buf,"%s_default",type)
|
||||||
|
>= sizeof buf)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Name '%s' too long\n",v->name);
|
BIO_printf(bio_err,"Name '%s' too long\n",v->name);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(buf,"%s_default",type);
|
|
||||||
if ((def=NCONF_get_string(req_conf,attr_sect,buf))
|
if ((def=NCONF_get_string(req_conf,attr_sect,buf))
|
||||||
== NULL)
|
== NULL)
|
||||||
{
|
{
|
||||||
@@ -1303,7 +1315,7 @@ start2: for (;;)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
sprintf(buf,"%s_value",type);
|
BIO_snprintf(buf,sizeof buf,"%s_value",type);
|
||||||
if ((value=NCONF_get_string(req_conf,attr_sect,buf))
|
if ((value=NCONF_get_string(req_conf,attr_sect,buf))
|
||||||
== NULL)
|
== NULL)
|
||||||
{
|
{
|
||||||
@@ -1311,11 +1323,11 @@ start2: for (;;)
|
|||||||
value=NULL;
|
value=NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(buf,"%s_min",type);
|
BIO_snprintf(buf,sizeof buf,"%s_min",type);
|
||||||
if (!NCONF_get_number(req_conf,attr_sect,buf, &n_min))
|
if (!NCONF_get_number(req_conf,attr_sect,buf, &n_min))
|
||||||
n_min = -1;
|
n_min = -1;
|
||||||
|
|
||||||
sprintf(buf,"%s_max",type);
|
BIO_snprintf(buf,sizeof buf,"%s_max",type);
|
||||||
if (!NCONF_get_number(req_conf,attr_sect,buf, &n_max))
|
if (!NCONF_get_number(req_conf,attr_sect,buf, &n_max))
|
||||||
n_max = -1;
|
n_max = -1;
|
||||||
|
|
||||||
@@ -1397,9 +1409,8 @@ start:
|
|||||||
(void)BIO_flush(bio_err);
|
(void)BIO_flush(bio_err);
|
||||||
if(value != NULL)
|
if(value != NULL)
|
||||||
{
|
{
|
||||||
OPENSSL_assert(strlen(value) < sizeof buf-2);
|
BUF_strlcpy(buf,value,sizeof buf);
|
||||||
strcpy(buf,value);
|
BUF_strlcat(buf,"\n",sizeof buf);
|
||||||
strcat(buf,"\n");
|
|
||||||
BIO_printf(bio_err,"%s\n",value);
|
BIO_printf(bio_err,"%s\n",value);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -1421,8 +1432,8 @@ start:
|
|||||||
{
|
{
|
||||||
if ((def == NULL) || (def[0] == '\0'))
|
if ((def == NULL) || (def[0] == '\0'))
|
||||||
return(1);
|
return(1);
|
||||||
strcpy(buf,def);
|
BUF_strlcpy(buf,def,sizeof buf);
|
||||||
strcat(buf,"\n");
|
BUF_strlcat(buf,"\n",sizeof buf);
|
||||||
}
|
}
|
||||||
else if ((buf[0] == '.') && (buf[1] == '\n')) return(1);
|
else if ((buf[0] == '.') && (buf[1] == '\n')) return(1);
|
||||||
|
|
||||||
@@ -1456,9 +1467,8 @@ start:
|
|||||||
(void)BIO_flush(bio_err);
|
(void)BIO_flush(bio_err);
|
||||||
if (value != NULL)
|
if (value != NULL)
|
||||||
{
|
{
|
||||||
OPENSSL_assert(strlen(value) < sizeof buf-2);
|
BUF_strlcpy(buf,value,sizeof buf);
|
||||||
strcpy(buf,value);
|
BUF_strlcat(buf,"\n",sizeof buf);
|
||||||
strcat(buf,"\n");
|
|
||||||
BIO_printf(bio_err,"%s\n",value);
|
BIO_printf(bio_err,"%s\n",value);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -1480,8 +1490,8 @@ start:
|
|||||||
{
|
{
|
||||||
if ((def == NULL) || (def[0] == '\0'))
|
if ((def == NULL) || (def[0] == '\0'))
|
||||||
return(1);
|
return(1);
|
||||||
strcpy(buf,def);
|
BUF_strlcpy(buf,def,sizeof buf);
|
||||||
strcat(buf,"\n");
|
BUF_strlcat(buf,"\n",sizeof buf);
|
||||||
}
|
}
|
||||||
else if ((buf[0] == '.') && (buf[1] == '\n')) return(1);
|
else if ((buf[0] == '.') && (buf[1] == '\n')) return(1);
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
* project 2000.
|
* project 2000.
|
||||||
*/
|
*/
|
||||||
/* ====================================================================
|
/* ====================================================================
|
||||||
* Copyright (c) 2000 The OpenSSL Project. All rights reserved.
|
* Copyright (c) 2000-2005 The OpenSSL Project. All rights reserved.
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
* modification, are permitted provided that the following conditions
|
* modification, are permitted provided that the following conditions
|
||||||
@@ -97,6 +97,7 @@ int MAIN(int argc, char **argv)
|
|||||||
EVP_PKEY *pkey = NULL;
|
EVP_PKEY *pkey = NULL;
|
||||||
RSA *rsa = NULL;
|
RSA *rsa = NULL;
|
||||||
unsigned char *rsa_in = NULL, *rsa_out = NULL, pad;
|
unsigned char *rsa_in = NULL, *rsa_out = NULL, pad;
|
||||||
|
char *passargin = NULL, *passin = NULL;
|
||||||
int rsa_inlen, rsa_outlen = 0;
|
int rsa_inlen, rsa_outlen = 0;
|
||||||
int keysize;
|
int keysize;
|
||||||
|
|
||||||
@@ -124,6 +125,9 @@ int MAIN(int argc, char **argv)
|
|||||||
} else if(!strcmp(*argv, "-inkey")) {
|
} else if(!strcmp(*argv, "-inkey")) {
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
keyfile = *(++argv);
|
keyfile = *(++argv);
|
||||||
|
} else if (!strcmp(*argv,"-passin")) {
|
||||||
|
if (--argc < 1) badarg = 1;
|
||||||
|
passargin= *(++argv);
|
||||||
} else if (strcmp(*argv,"-keyform") == 0) {
|
} else if (strcmp(*argv,"-keyform") == 0) {
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
keyform=str2fmt(*(++argv));
|
keyform=str2fmt(*(++argv));
|
||||||
@@ -143,6 +147,7 @@ int MAIN(int argc, char **argv)
|
|||||||
else if(!strcmp(*argv, "-oaep")) pad = RSA_PKCS1_OAEP_PADDING;
|
else if(!strcmp(*argv, "-oaep")) pad = RSA_PKCS1_OAEP_PADDING;
|
||||||
else if(!strcmp(*argv, "-ssl")) pad = RSA_SSLV23_PADDING;
|
else if(!strcmp(*argv, "-ssl")) pad = RSA_SSLV23_PADDING;
|
||||||
else if(!strcmp(*argv, "-pkcs")) pad = RSA_PKCS1_PADDING;
|
else if(!strcmp(*argv, "-pkcs")) pad = RSA_PKCS1_PADDING;
|
||||||
|
else if(!strcmp(*argv, "-x931")) pad = RSA_X931_PADDING;
|
||||||
else if(!strcmp(*argv, "-sign")) {
|
else if(!strcmp(*argv, "-sign")) {
|
||||||
rsa_mode = RSA_SIGN;
|
rsa_mode = RSA_SIGN;
|
||||||
need_priv = 1;
|
need_priv = 1;
|
||||||
@@ -169,6 +174,10 @@ int MAIN(int argc, char **argv)
|
|||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
e = setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
if(!app_passwd(bio_err, passargin, NULL, &passin, NULL)) {
|
||||||
|
BIO_printf(bio_err, "Error getting password\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
/* FIXME: seed PRNG only if needed */
|
/* FIXME: seed PRNG only if needed */
|
||||||
app_RAND_load_file(NULL, bio_err, 0);
|
app_RAND_load_file(NULL, bio_err, 0);
|
||||||
@@ -176,7 +185,7 @@ int MAIN(int argc, char **argv)
|
|||||||
switch(key_type) {
|
switch(key_type) {
|
||||||
case KEY_PRIVKEY:
|
case KEY_PRIVKEY:
|
||||||
pkey = load_key(bio_err, keyfile, keyform, 0,
|
pkey = load_key(bio_err, keyfile, keyform, 0,
|
||||||
NULL, e, "Private Key");
|
passin, e, "Private Key");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case KEY_PUBKEY:
|
case KEY_PUBKEY:
|
||||||
@@ -290,6 +299,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_free_all(out);
|
BIO_free_all(out);
|
||||||
if(rsa_in) OPENSSL_free(rsa_in);
|
if(rsa_in) OPENSSL_free(rsa_in);
|
||||||
if(rsa_out) OPENSSL_free(rsa_out);
|
if(rsa_out) OPENSSL_free(rsa_out);
|
||||||
|
if(passin) OPENSSL_free(passin);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -313,6 +323,7 @@ static void usage()
|
|||||||
BIO_printf(bio_err, "-hexdump hex dump output\n");
|
BIO_printf(bio_err, "-hexdump hex dump output\n");
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n");
|
BIO_printf(bio_err, "-engine e use engine e, possibly a hardware device.\n");
|
||||||
|
BIO_printf (bio_err, "-passin arg pass phrase source\n");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -112,6 +112,14 @@
|
|||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <openssl/opensslconf.h>
|
#include <openssl/opensslconf.h>
|
||||||
|
|
||||||
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS)
|
||||||
|
#include <conio.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef OPENSSL_SYS_MSDOS
|
||||||
|
#define _kbhit kbhit
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(OPENSSL_SYS_VMS) && !defined(FD_SET)
|
#if defined(OPENSSL_SYS_VMS) && !defined(FD_SET)
|
||||||
/* VAX C does not defined fd_set and friends, but it's actually quite simple */
|
/* VAX C does not defined fd_set and friends, but it's actually quite simple */
|
||||||
/* These definitions are borrowed from SOCKETSHR. /Richard Levitte */
|
/* These definitions are borrowed from SOCKETSHR. /Richard Levitte */
|
||||||
|
|||||||
@@ -136,10 +136,6 @@ typedef unsigned int u_int;
|
|||||||
#include <openssl/rand.h>
|
#include <openssl/rand.h>
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
|
||||||
#include <conio.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINCE
|
#ifdef OPENSSL_SYS_WINCE
|
||||||
/* Windows CE incorrectly defines fileno as returning void*, so to avoid problems below... */
|
/* Windows CE incorrectly defines fileno as returning void*, so to avoid problems below... */
|
||||||
#ifdef fileno
|
#ifdef fileno
|
||||||
@@ -201,6 +197,9 @@ static void sc_usage(void)
|
|||||||
BIO_printf(bio_err," -pause - sleep(1) after each read(2) and write(2) system call\n");
|
BIO_printf(bio_err," -pause - sleep(1) after each read(2) and write(2) system call\n");
|
||||||
BIO_printf(bio_err," -showcerts - show all certificates in the chain\n");
|
BIO_printf(bio_err," -showcerts - show all certificates in the chain\n");
|
||||||
BIO_printf(bio_err," -debug - extra output\n");
|
BIO_printf(bio_err," -debug - extra output\n");
|
||||||
|
#ifdef WATT32
|
||||||
|
BIO_printf(bio_err," -wdebug - WATT-32 tcp debugging\n");
|
||||||
|
#endif
|
||||||
BIO_printf(bio_err," -msg - Show protocol messages\n");
|
BIO_printf(bio_err," -msg - Show protocol messages\n");
|
||||||
BIO_printf(bio_err," -nbio_test - more ssl protocol testing\n");
|
BIO_printf(bio_err," -nbio_test - more ssl protocol testing\n");
|
||||||
BIO_printf(bio_err," -state - print the 'ssl' states\n");
|
BIO_printf(bio_err," -state - print the 'ssl' states\n");
|
||||||
@@ -221,7 +220,7 @@ static void sc_usage(void)
|
|||||||
BIO_printf(bio_err," -starttls prot - use the STARTTLS command before starting TLS\n");
|
BIO_printf(bio_err," -starttls prot - use the STARTTLS command before starting TLS\n");
|
||||||
BIO_printf(bio_err," for those protocols that support it, where\n");
|
BIO_printf(bio_err," for those protocols that support it, where\n");
|
||||||
BIO_printf(bio_err," 'prot' defines which one to assume. Currently,\n");
|
BIO_printf(bio_err," 'prot' defines which one to assume. Currently,\n");
|
||||||
BIO_printf(bio_err," only \"smtp\" is supported.\n");
|
BIO_printf(bio_err," only \"smtp\" and \"pop3\" are supported.\n");
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
BIO_printf(bio_err," -engine id - Initialise and use the specified engine\n");
|
BIO_printf(bio_err," -engine id - Initialise and use the specified engine\n");
|
||||||
#endif
|
#endif
|
||||||
@@ -251,7 +250,7 @@ int MAIN(int argc, char **argv)
|
|||||||
int write_tty,read_tty,write_ssl,read_ssl,tty_on,ssl_pending;
|
int write_tty,read_tty,write_ssl,read_ssl,tty_on,ssl_pending;
|
||||||
SSL_CTX *ctx=NULL;
|
SSL_CTX *ctx=NULL;
|
||||||
int ret=1,in_init=1,i,nbio_test=0;
|
int ret=1,in_init=1,i,nbio_test=0;
|
||||||
int smtp_starttls = 0;
|
int starttls_proto = 0;
|
||||||
int prexit = 0, vflags = 0;
|
int prexit = 0, vflags = 0;
|
||||||
SSL_METHOD *meth=NULL;
|
SSL_METHOD *meth=NULL;
|
||||||
BIO *sbio;
|
BIO *sbio;
|
||||||
@@ -260,7 +259,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *engine_id=NULL;
|
char *engine_id=NULL;
|
||||||
ENGINE *e=NULL;
|
ENGINE *e=NULL;
|
||||||
#endif
|
#endif
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS)
|
||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -352,6 +351,10 @@ int MAIN(int argc, char **argv)
|
|||||||
c_Pause=1;
|
c_Pause=1;
|
||||||
else if (strcmp(*argv,"-debug") == 0)
|
else if (strcmp(*argv,"-debug") == 0)
|
||||||
c_debug=1;
|
c_debug=1;
|
||||||
|
#ifdef WATT32
|
||||||
|
else if (strcmp(*argv,"-wdebug") == 0)
|
||||||
|
dbug_init();
|
||||||
|
#endif
|
||||||
else if (strcmp(*argv,"-msg") == 0)
|
else if (strcmp(*argv,"-msg") == 0)
|
||||||
c_msg=1;
|
c_msg=1;
|
||||||
else if (strcmp(*argv,"-showcerts") == 0)
|
else if (strcmp(*argv,"-showcerts") == 0)
|
||||||
@@ -415,7 +418,9 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
++argv;
|
++argv;
|
||||||
if (strcmp(*argv,"smtp") == 0)
|
if (strcmp(*argv,"smtp") == 0)
|
||||||
smtp_starttls = 1;
|
starttls_proto = 1;
|
||||||
|
else if (strcmp(*argv,"pop3") == 0)
|
||||||
|
starttls_proto = 2;
|
||||||
else
|
else
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
@@ -587,12 +592,20 @@ re_start:
|
|||||||
sbuf_off=0;
|
sbuf_off=0;
|
||||||
|
|
||||||
/* This is an ugly hack that does a lot of assumptions */
|
/* This is an ugly hack that does a lot of assumptions */
|
||||||
if (smtp_starttls)
|
if (starttls_proto == 1)
|
||||||
{
|
{
|
||||||
BIO_read(sbio,mbuf,BUFSIZZ);
|
BIO_read(sbio,mbuf,BUFSIZZ);
|
||||||
|
BIO_printf(sbio,"EHLO some.host.name\r\n");
|
||||||
|
BIO_read(sbio,mbuf,BUFSIZZ);
|
||||||
BIO_printf(sbio,"STARTTLS\r\n");
|
BIO_printf(sbio,"STARTTLS\r\n");
|
||||||
BIO_read(sbio,sbuf,BUFSIZZ);
|
BIO_read(sbio,sbuf,BUFSIZZ);
|
||||||
}
|
}
|
||||||
|
if (starttls_proto == 2)
|
||||||
|
{
|
||||||
|
BIO_read(sbio,mbuf,BUFSIZZ);
|
||||||
|
BIO_printf(sbio,"STLS\r\n");
|
||||||
|
BIO_read(sbio,sbuf,BUFSIZZ);
|
||||||
|
}
|
||||||
|
|
||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
@@ -613,11 +626,11 @@ re_start:
|
|||||||
print_stuff(bio_c_out,con,full_log);
|
print_stuff(bio_c_out,con,full_log);
|
||||||
if (full_log > 0) full_log--;
|
if (full_log > 0) full_log--;
|
||||||
|
|
||||||
if (smtp_starttls)
|
if (starttls_proto)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"%s",mbuf);
|
BIO_printf(bio_err,"%s",mbuf);
|
||||||
/* We don't need to know any more */
|
/* We don't need to know any more */
|
||||||
smtp_starttls = 0;
|
starttls_proto = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (reconnect)
|
if (reconnect)
|
||||||
@@ -636,7 +649,7 @@ re_start:
|
|||||||
|
|
||||||
if (!ssl_pending)
|
if (!ssl_pending)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_SYS_WINDOWS
|
#if !defined(OPENSSL_SYS_WINDOWS) && !defined(OPENSSL_SYS_MSDOS)
|
||||||
if (tty_on)
|
if (tty_on)
|
||||||
{
|
{
|
||||||
if (read_tty) FD_SET(fileno(stdin),&readfds);
|
if (read_tty) FD_SET(fileno(stdin),&readfds);
|
||||||
@@ -663,8 +676,8 @@ re_start:
|
|||||||
* will choke the compiler: if you do have a cast then
|
* will choke the compiler: if you do have a cast then
|
||||||
* you can either go for (int *) or (void *).
|
* you can either go for (int *) or (void *).
|
||||||
*/
|
*/
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS)
|
||||||
/* Under Windows we make the assumption that we can
|
/* Under Windows/DOS we make the assumption that we can
|
||||||
* always write to the tty: therefore if we need to
|
* always write to the tty: therefore if we need to
|
||||||
* write to the tty we just fall through. Otherwise
|
* write to the tty we just fall through. Otherwise
|
||||||
* we timeout the select every second and see if there
|
* we timeout the select every second and see if there
|
||||||
@@ -678,7 +691,7 @@ re_start:
|
|||||||
tv.tv_usec = 0;
|
tv.tv_usec = 0;
|
||||||
i=select(width,(void *)&readfds,(void *)&writefds,
|
i=select(width,(void *)&readfds,(void *)&writefds,
|
||||||
NULL,&tv);
|
NULL,&tv);
|
||||||
#ifdef OPENSSL_SYS_WINCE
|
#if defined(OPENSSL_SYS_WINCE) || defined(OPENSSL_SYS_MSDOS)
|
||||||
if(!i && (!_kbhit() || !read_tty) ) continue;
|
if(!i && (!_kbhit() || !read_tty) ) continue;
|
||||||
#else
|
#else
|
||||||
if(!i && (!((_kbhit()) || (WAIT_OBJECT_0 == WaitForSingleObject(GetStdHandle(STD_INPUT_HANDLE), 0))) || !read_tty) ) continue;
|
if(!i && (!((_kbhit()) || (WAIT_OBJECT_0 == WaitForSingleObject(GetStdHandle(STD_INPUT_HANDLE), 0))) || !read_tty) ) continue;
|
||||||
@@ -847,8 +860,8 @@ printf("read=%d pending=%d peek=%d\n",k,SSL_pending(con),SSL_peek(con,zbuf,10240
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS)
|
||||||
#ifdef OPENSSL_SYS_WINCE
|
#if defined(OPENSSL_SYS_WINCE) || defined(OPENSSL_SYS_MSDOS)
|
||||||
else if (_kbhit())
|
else if (_kbhit())
|
||||||
#else
|
#else
|
||||||
else if ((_kbhit()) || (WAIT_OBJECT_0 == WaitForSingleObject(GetStdHandle(STD_INPUT_HANDLE), 0)))
|
else if ((_kbhit()) || (WAIT_OBJECT_0 == WaitForSingleObject(GetStdHandle(STD_INPUT_HANDLE), 0)))
|
||||||
|
|||||||
@@ -140,10 +140,6 @@ typedef unsigned int u_int;
|
|||||||
#include <openssl/rand.h>
|
#include <openssl/rand.h>
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
|
||||||
#include <conio.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef OPENSSL_SYS_WINCE
|
#ifdef OPENSSL_SYS_WINCE
|
||||||
/* Windows CE incorrectly defines fileno as returning void*, so to avoid problems below... */
|
/* Windows CE incorrectly defines fileno as returning void*, so to avoid problems below... */
|
||||||
#ifdef fileno
|
#ifdef fileno
|
||||||
@@ -917,7 +913,7 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
unsigned long l;
|
unsigned long l;
|
||||||
SSL *con=NULL;
|
SSL *con=NULL;
|
||||||
BIO *sbio;
|
BIO *sbio;
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS)
|
||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -991,7 +987,7 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
if (!read_from_sslcon)
|
if (!read_from_sslcon)
|
||||||
{
|
{
|
||||||
FD_ZERO(&readfds);
|
FD_ZERO(&readfds);
|
||||||
#ifndef OPENSSL_SYS_WINDOWS
|
#if !defined(OPENSSL_SYS_WINDOWS) && !defined(OPENSSL_SYS_MSDOS)
|
||||||
FD_SET(fileno(stdin),&readfds);
|
FD_SET(fileno(stdin),&readfds);
|
||||||
#endif
|
#endif
|
||||||
FD_SET(s,&readfds);
|
FD_SET(s,&readfds);
|
||||||
@@ -1001,8 +997,8 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
* the compiler: if you do have a cast then you can either
|
* the compiler: if you do have a cast then you can either
|
||||||
* go for (int *) or (void *).
|
* go for (int *) or (void *).
|
||||||
*/
|
*/
|
||||||
#ifdef OPENSSL_SYS_WINDOWS
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS)
|
||||||
/* Under Windows we can't select on stdin: only
|
/* Under DOS (non-djgpp) and Windows we can't select on stdin: only
|
||||||
* on sockets. As a workaround we timeout the select every
|
* on sockets. As a workaround we timeout the select every
|
||||||
* second and check for any keypress. In a proper Windows
|
* second and check for any keypress. In a proper Windows
|
||||||
* application we wouldn't do this because it is inefficient.
|
* application we wouldn't do this because it is inefficient.
|
||||||
@@ -1263,7 +1259,13 @@ static int init_ssl_connection(SSL *con)
|
|||||||
if (SSL_ctrl(con,SSL_CTRL_GET_FLAGS,0,NULL) &
|
if (SSL_ctrl(con,SSL_CTRL_GET_FLAGS,0,NULL) &
|
||||||
TLS1_FLAGS_TLS_PADDING_BUG)
|
TLS1_FLAGS_TLS_PADDING_BUG)
|
||||||
BIO_printf(bio_s_out,"Peer has incorrect TLSv1 block padding\n");
|
BIO_printf(bio_s_out,"Peer has incorrect TLSv1 block padding\n");
|
||||||
|
#ifndef OPENSSL_NO_KRB5
|
||||||
|
if (con->kssl_ctx->client_princ != NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out,"Kerberos peer principal is %s\n",
|
||||||
|
con->kssl_ctx->client_princ);
|
||||||
|
}
|
||||||
|
#endif /* OPENSSL_NO_KRB5 */
|
||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -153,7 +153,6 @@ static int ssl_sock_init(void)
|
|||||||
#ifdef WATT32
|
#ifdef WATT32
|
||||||
extern int _watt_do_exit;
|
extern int _watt_do_exit;
|
||||||
_watt_do_exit = 0;
|
_watt_do_exit = 0;
|
||||||
dbug_init();
|
|
||||||
if (sock_init())
|
if (sock_init())
|
||||||
return (0);
|
return (0);
|
||||||
#elif defined(OPENSSL_SYS_WINDOWS)
|
#elif defined(OPENSSL_SYS_WINDOWS)
|
||||||
@@ -389,7 +388,7 @@ redoit:
|
|||||||
perror("OPENSSL_malloc");
|
perror("OPENSSL_malloc");
|
||||||
return(0);
|
return(0);
|
||||||
}
|
}
|
||||||
strcpy(*host,h1->h_name);
|
BUF_strlcpy(*host,h1->h_name,strlen(h1->h_name)+1);
|
||||||
|
|
||||||
h2=GetHostByName(*host);
|
h2=GetHostByName(*host);
|
||||||
if (h2 == NULL)
|
if (h2 == NULL)
|
||||||
|
|||||||
@@ -502,7 +502,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
if (s_www_path != NULL)
|
if (s_www_path != NULL)
|
||||||
{
|
{
|
||||||
sprintf(buf,"GET %s HTTP/1.0\r\n\r\n",s_www_path);
|
BIO_snprintf(buf,sizeof buf,"GET %s HTTP/1.0\r\n\r\n",s_www_path);
|
||||||
SSL_write(scon,buf,strlen(buf));
|
SSL_write(scon,buf,strlen(buf));
|
||||||
while ((i=SSL_read(scon,buf,sizeof(buf))) > 0)
|
while ((i=SSL_read(scon,buf,sizeof(buf))) > 0)
|
||||||
bytes_read+=i;
|
bytes_read+=i;
|
||||||
@@ -557,7 +557,7 @@ next:
|
|||||||
|
|
||||||
if (s_www_path != NULL)
|
if (s_www_path != NULL)
|
||||||
{
|
{
|
||||||
sprintf(buf,"GET %s HTTP/1.0\r\n\r\n",s_www_path);
|
BIO_snprintf(buf,sizeof buf,"GET %s HTTP/1.0\r\n\r\n",s_www_path);
|
||||||
SSL_write(scon,buf,strlen(buf));
|
SSL_write(scon,buf,strlen(buf));
|
||||||
while (SSL_read(scon,buf,sizeof(buf)) > 0)
|
while (SSL_read(scon,buf,sizeof(buf)) > 0)
|
||||||
;
|
;
|
||||||
@@ -595,7 +595,7 @@ next:
|
|||||||
|
|
||||||
if (s_www_path)
|
if (s_www_path)
|
||||||
{
|
{
|
||||||
sprintf(buf,"GET %s HTTP/1.0\r\n\r\n",s_www_path);
|
BIO_snprintf(buf,sizeof buf,"GET %s HTTP/1.0\r\n\r\n",s_www_path);
|
||||||
SSL_write(scon,buf,strlen(buf));
|
SSL_write(scon,buf,strlen(buf));
|
||||||
while ((i=SSL_read(scon,buf,sizeof(buf))) > 0)
|
while ((i=SSL_read(scon,buf,sizeof(buf))) > 0)
|
||||||
bytes_read+=i;
|
bytes_read+=i;
|
||||||
|
|||||||
@@ -168,6 +168,10 @@ int MAIN(int argc, char **argv)
|
|||||||
flags |= PKCS7_BINARY;
|
flags |= PKCS7_BINARY;
|
||||||
else if (!strcmp (*args, "-nosigs"))
|
else if (!strcmp (*args, "-nosigs"))
|
||||||
flags |= PKCS7_NOSIGS;
|
flags |= PKCS7_NOSIGS;
|
||||||
|
else if (!strcmp (*args, "-nooldmime"))
|
||||||
|
flags |= PKCS7_NOOLDMIMETYPE;
|
||||||
|
else if (!strcmp (*args, "-crlfeol"))
|
||||||
|
flags |= PKCS7_CRLFEOL;
|
||||||
else if (!strcmp (*args, "-crl_check"))
|
else if (!strcmp (*args, "-crl_check"))
|
||||||
store_flags |= X509_V_FLAG_CRL_CHECK;
|
store_flags |= X509_V_FLAG_CRL_CHECK;
|
||||||
else if (!strcmp (*args, "-crl_check_all"))
|
else if (!strcmp (*args, "-crl_check_all"))
|
||||||
|
|||||||
12
apps/speed.c
12
apps/speed.c
@@ -773,6 +773,7 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
dsa_doit[R_DSA_512]=1;
|
dsa_doit[R_DSA_512]=1;
|
||||||
dsa_doit[R_DSA_1024]=1;
|
dsa_doit[R_DSA_1024]=1;
|
||||||
|
dsa_doit[R_DSA_2048]=1;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
@@ -1006,6 +1007,9 @@ int MAIN(int argc, char **argv)
|
|||||||
c[D_CBC_RC5][0]=count;
|
c[D_CBC_RC5][0]=count;
|
||||||
c[D_CBC_BF][0]=count;
|
c[D_CBC_BF][0]=count;
|
||||||
c[D_CBC_CAST][0]=count;
|
c[D_CBC_CAST][0]=count;
|
||||||
|
c[D_CBC_128_AES][0]=count;
|
||||||
|
c[D_CBC_192_AES][0]=count;
|
||||||
|
c[D_CBC_256_AES][0]=count;
|
||||||
|
|
||||||
for (i=1; i<SIZE_NUM; i++)
|
for (i=1; i<SIZE_NUM; i++)
|
||||||
{
|
{
|
||||||
@@ -1031,6 +1035,9 @@ int MAIN(int argc, char **argv)
|
|||||||
c[D_CBC_RC5][i]=c[D_CBC_RC5][i-1]*l0/l1;
|
c[D_CBC_RC5][i]=c[D_CBC_RC5][i-1]*l0/l1;
|
||||||
c[D_CBC_BF][i]=c[D_CBC_BF][i-1]*l0/l1;
|
c[D_CBC_BF][i]=c[D_CBC_BF][i-1]*l0/l1;
|
||||||
c[D_CBC_CAST][i]=c[D_CBC_CAST][i-1]*l0/l1;
|
c[D_CBC_CAST][i]=c[D_CBC_CAST][i-1]*l0/l1;
|
||||||
|
c[D_CBC_128_AES][i]=c[D_CBC_128_AES][i-1]*l0/l1;
|
||||||
|
c[D_CBC_192_AES][i]=c[D_CBC_192_AES][i-1]*l0/l1;
|
||||||
|
c[D_CBC_256_AES][i]=c[D_CBC_256_AES][i-1]*l0/l1;
|
||||||
}
|
}
|
||||||
#ifndef OPENSSL_NO_RSA
|
#ifndef OPENSSL_NO_RSA
|
||||||
rsa_c[R_RSA_512][0]=count/2000;
|
rsa_c[R_RSA_512][0]=count/2000;
|
||||||
@@ -1388,6 +1395,7 @@ int MAIN(int argc, char **argv)
|
|||||||
EVP_DecryptInit_ex(&ctx,evp_cipher,NULL,key16,iv);
|
EVP_DecryptInit_ex(&ctx,evp_cipher,NULL,key16,iv);
|
||||||
else
|
else
|
||||||
EVP_EncryptInit_ex(&ctx,evp_cipher,NULL,key16,iv);
|
EVP_EncryptInit_ex(&ctx,evp_cipher,NULL,key16,iv);
|
||||||
|
EVP_CIPHER_CTX_set_padding(&ctx, 0);
|
||||||
|
|
||||||
Time_F(START);
|
Time_F(START);
|
||||||
if(decrypt)
|
if(decrypt)
|
||||||
@@ -1698,7 +1706,7 @@ show_res:
|
|||||||
k,rsa_bits[k],rsa_results[k][0],
|
k,rsa_bits[k],rsa_results[k][0],
|
||||||
rsa_results[k][1]);
|
rsa_results[k][1]);
|
||||||
else
|
else
|
||||||
fprintf(stdout,"rsa %4u bits %8.4fs %8.4fs %8.1f %8.1f\n",
|
fprintf(stdout,"rsa %4u bits %8.6fs %8.6fs %8.1f %8.1f\n",
|
||||||
rsa_bits[k],rsa_results[k][0],rsa_results[k][1],
|
rsa_bits[k],rsa_results[k][0],rsa_results[k][1],
|
||||||
1.0/rsa_results[k][0],1.0/rsa_results[k][1]);
|
1.0/rsa_results[k][0],1.0/rsa_results[k][1]);
|
||||||
}
|
}
|
||||||
@@ -1717,7 +1725,7 @@ show_res:
|
|||||||
fprintf(stdout,"+F3:%u:%u:%f:%f\n",
|
fprintf(stdout,"+F3:%u:%u:%f:%f\n",
|
||||||
k,dsa_bits[k],dsa_results[k][0],dsa_results[k][1]);
|
k,dsa_bits[k],dsa_results[k][0],dsa_results[k][1]);
|
||||||
else
|
else
|
||||||
fprintf(stdout,"dsa %4u bits %8.4fs %8.4fs %8.1f %8.1f\n",
|
fprintf(stdout,"dsa %4u bits %8.6fs %8.6fs %8.1f %8.1f\n",
|
||||||
dsa_bits[k],dsa_results[k][0],dsa_results[k][1],
|
dsa_bits[k],dsa_results[k][0],dsa_results[k][1],
|
||||||
1.0/dsa_results[k][0],1.0/dsa_results[k][1]);
|
1.0/dsa_results[k][0],1.0/dsa_results[k][1]);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -354,6 +354,7 @@ static int MS_CALLBACK cb(int ok, X509_STORE_CTX *ctx)
|
|||||||
if (ctx->error == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) ok=1;
|
if (ctx->error == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) ok=1;
|
||||||
/* Continue after extension errors too */
|
/* Continue after extension errors too */
|
||||||
if (ctx->error == X509_V_ERR_INVALID_CA) ok=1;
|
if (ctx->error == X509_V_ERR_INVALID_CA) ok=1;
|
||||||
|
if (ctx->error == X509_V_ERR_INVALID_NON_CA) ok=1;
|
||||||
if (ctx->error == X509_V_ERR_PATH_LENGTH_EXCEEDED) ok=1;
|
if (ctx->error == X509_V_ERR_PATH_LENGTH_EXCEEDED) ok=1;
|
||||||
if (ctx->error == X509_V_ERR_INVALID_PURPOSE) ok=1;
|
if (ctx->error == X509_V_ERR_INVALID_PURPOSE) ok=1;
|
||||||
if (ctx->error == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) ok=1;
|
if (ctx->error == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) ok=1;
|
||||||
|
|||||||
149
apps/x509.c
149
apps/x509.c
@@ -168,7 +168,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *CAkeyfile=NULL,*CAserial=NULL;
|
char *CAkeyfile=NULL,*CAserial=NULL;
|
||||||
char *alias=NULL;
|
char *alias=NULL;
|
||||||
int text=0,serial=0,hash=0,subject=0,issuer=0,startdate=0,enddate=0;
|
int text=0,serial=0,hash=0,subject=0,issuer=0,startdate=0,enddate=0;
|
||||||
int ocspid=0;
|
int next_serial=0,ocspid=0;
|
||||||
int noout=0,sign_flag=0,CA_flag=0,CA_createserial=0,email=0;
|
int noout=0,sign_flag=0,CA_flag=0,CA_createserial=0,email=0;
|
||||||
int trustout=0,clrtrust=0,clrreject=0,aliasout=0,clrext=0;
|
int trustout=0,clrtrust=0,clrreject=0,aliasout=0,clrext=0;
|
||||||
int C=0;
|
int C=0;
|
||||||
@@ -179,7 +179,7 @@ int MAIN(int argc, char **argv)
|
|||||||
X509_REQ *rq=NULL;
|
X509_REQ *rq=NULL;
|
||||||
int fingerprint=0;
|
int fingerprint=0;
|
||||||
char buf[256];
|
char buf[256];
|
||||||
const EVP_MD *md_alg,*digest=EVP_md5();
|
const EVP_MD *md_alg,*digest;
|
||||||
CONF *extconf = NULL;
|
CONF *extconf = NULL;
|
||||||
char *extsect = NULL, *extfile = NULL, *passin = NULL, *passargin = NULL;
|
char *extsect = NULL, *extfile = NULL, *passin = NULL, *passargin = NULL;
|
||||||
int need_rand = 0;
|
int need_rand = 0;
|
||||||
@@ -216,6 +216,13 @@ int MAIN(int argc, char **argv)
|
|||||||
if (ctx == NULL) goto end;
|
if (ctx == NULL) goto end;
|
||||||
X509_STORE_set_verify_cb_func(ctx,callb);
|
X509_STORE_set_verify_cb_func(ctx,callb);
|
||||||
|
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
if (FIPS_mode())
|
||||||
|
digest = EVP_sha1();
|
||||||
|
else
|
||||||
|
#endif
|
||||||
|
digest = EVP_md5();
|
||||||
|
|
||||||
argc--;
|
argc--;
|
||||||
argv++;
|
argv++;
|
||||||
num=0;
|
num=0;
|
||||||
@@ -358,12 +365,6 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
if (!set_name_ex(&nmflag, *(++argv))) goto bad;
|
if (!set_name_ex(&nmflag, *(++argv))) goto bad;
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-setalias") == 0)
|
|
||||||
{
|
|
||||||
if (--argc < 1) goto bad;
|
|
||||||
alias= *(++argv);
|
|
||||||
trustout = 1;
|
|
||||||
}
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
else if (strcmp(*argv,"-engine") == 0)
|
else if (strcmp(*argv,"-engine") == 0)
|
||||||
{
|
{
|
||||||
@@ -377,6 +378,8 @@ int MAIN(int argc, char **argv)
|
|||||||
email= ++num;
|
email= ++num;
|
||||||
else if (strcmp(*argv,"-serial") == 0)
|
else if (strcmp(*argv,"-serial") == 0)
|
||||||
serial= ++num;
|
serial= ++num;
|
||||||
|
else if (strcmp(*argv,"-next_serial") == 0)
|
||||||
|
next_serial= ++num;
|
||||||
else if (strcmp(*argv,"-modulus") == 0)
|
else if (strcmp(*argv,"-modulus") == 0)
|
||||||
modulus= ++num;
|
modulus= ++num;
|
||||||
else if (strcmp(*argv,"-pubkey") == 0)
|
else if (strcmp(*argv,"-pubkey") == 0)
|
||||||
@@ -597,12 +600,19 @@ bad:
|
|||||||
if ((x=X509_new()) == NULL) goto end;
|
if ((x=X509_new()) == NULL) goto end;
|
||||||
ci=x->cert_info;
|
ci=x->cert_info;
|
||||||
|
|
||||||
if (sno)
|
if (sno == NULL)
|
||||||
{
|
{
|
||||||
|
sno = ASN1_INTEGER_new();
|
||||||
|
if (!sno || !rand_serial(NULL, sno))
|
||||||
|
goto end;
|
||||||
if (!X509_set_serialNumber(x, sno))
|
if (!X509_set_serialNumber(x, sno))
|
||||||
goto end;
|
goto end;
|
||||||
|
ASN1_INTEGER_free(sno);
|
||||||
|
sno = NULL;
|
||||||
}
|
}
|
||||||
else if (!ASN1_INTEGER_set(X509_get_serialNumber(x),0)) goto end;
|
else if (!X509_set_serialNumber(x, sno))
|
||||||
|
goto end;
|
||||||
|
|
||||||
if (!X509_set_issuer_name(x,req->req_info->subject)) goto end;
|
if (!X509_set_issuer_name(x,req->req_info->subject)) goto end;
|
||||||
if (!X509_set_subject_name(x,req->req_info->subject)) goto end;
|
if (!X509_set_subject_name(x,req->req_info->subject)) goto end;
|
||||||
|
|
||||||
@@ -623,7 +633,7 @@ bad:
|
|||||||
if (xca == NULL) goto end;
|
if (xca == NULL) goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!noout || text)
|
if (!noout || text || next_serial)
|
||||||
{
|
{
|
||||||
OBJ_create("2.99999.3",
|
OBJ_create("2.99999.3",
|
||||||
"SET.ex3","SET x509v3 extension 3");
|
"SET.ex3","SET x509v3 extension 3");
|
||||||
@@ -697,6 +707,24 @@ bad:
|
|||||||
i2a_ASN1_INTEGER(STDout,x->cert_info->serialNumber);
|
i2a_ASN1_INTEGER(STDout,x->cert_info->serialNumber);
|
||||||
BIO_printf(STDout,"\n");
|
BIO_printf(STDout,"\n");
|
||||||
}
|
}
|
||||||
|
else if (next_serial == i)
|
||||||
|
{
|
||||||
|
BIGNUM *bnser;
|
||||||
|
ASN1_INTEGER *ser;
|
||||||
|
ser = X509_get_serialNumber(x);
|
||||||
|
bnser = ASN1_INTEGER_to_BN(ser, NULL);
|
||||||
|
if (!bnser)
|
||||||
|
goto end;
|
||||||
|
if (!BN_add_word(bnser, 1))
|
||||||
|
goto end;
|
||||||
|
ser = BN_to_ASN1_INTEGER(bnser, NULL);
|
||||||
|
if (!ser)
|
||||||
|
goto end;
|
||||||
|
BN_free(bnser);
|
||||||
|
i2a_ASN1_INTEGER(out, ser);
|
||||||
|
ASN1_INTEGER_free(ser);
|
||||||
|
BIO_puts(out, "\n");
|
||||||
|
}
|
||||||
else if (email == i)
|
else if (email == i)
|
||||||
{
|
{
|
||||||
int j;
|
int j;
|
||||||
@@ -953,9 +981,9 @@ bad:
|
|||||||
|
|
||||||
if (checkend)
|
if (checkend)
|
||||||
{
|
{
|
||||||
time_t tnow=time(NULL);
|
time_t tcheck=time(NULL) + checkoffset;
|
||||||
|
|
||||||
if (ASN1_UTCTIME_cmp_time_t(X509_get_notAfter(x), tnow+checkoffset) == -1)
|
if (X509_cmp_time(X509_get_notAfter(x), &tcheck) < 0)
|
||||||
{
|
{
|
||||||
BIO_printf(out,"Certificate will expire\n");
|
BIO_printf(out,"Certificate will expire\n");
|
||||||
ret=1;
|
ret=1;
|
||||||
@@ -1028,105 +1056,44 @@ end:
|
|||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
|
||||||
static ASN1_INTEGER *load_serial(char *CAfile, char *serialfile, int create)
|
static ASN1_INTEGER *x509_load_serial(char *CAfile, char *serialfile, int create)
|
||||||
{
|
{
|
||||||
char *buf = NULL, *p;
|
char *buf = NULL, *p;
|
||||||
MS_STATIC char buf2[1024];
|
ASN1_INTEGER *bs = NULL;
|
||||||
ASN1_INTEGER *bs = NULL, *bs2 = NULL;
|
|
||||||
BIO *io = NULL;
|
|
||||||
BIGNUM *serial = NULL;
|
BIGNUM *serial = NULL;
|
||||||
|
size_t len;
|
||||||
|
|
||||||
buf=OPENSSL_malloc( ((serialfile == NULL)
|
len = ((serialfile == NULL)
|
||||||
?(strlen(CAfile)+strlen(POSTFIX)+1)
|
?(strlen(CAfile)+strlen(POSTFIX)+1)
|
||||||
:(strlen(serialfile)))+1);
|
:(strlen(serialfile)))+1;
|
||||||
|
buf=OPENSSL_malloc(len);
|
||||||
if (buf == NULL) { BIO_printf(bio_err,"out of mem\n"); goto end; }
|
if (buf == NULL) { BIO_printf(bio_err,"out of mem\n"); goto end; }
|
||||||
if (serialfile == NULL)
|
if (serialfile == NULL)
|
||||||
{
|
{
|
||||||
strcpy(buf,CAfile);
|
BUF_strlcpy(buf,CAfile,len);
|
||||||
for (p=buf; *p; p++)
|
for (p=buf; *p; p++)
|
||||||
if (*p == '.')
|
if (*p == '.')
|
||||||
{
|
{
|
||||||
*p='\0';
|
*p='\0';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
strcat(buf,POSTFIX);
|
BUF_strlcat(buf,POSTFIX,len);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
strcpy(buf,serialfile);
|
BUF_strlcpy(buf,serialfile,len);
|
||||||
serial=BN_new();
|
|
||||||
bs=ASN1_INTEGER_new();
|
|
||||||
if ((serial == NULL) || (bs == NULL))
|
|
||||||
{
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
|
|
||||||
io=BIO_new(BIO_s_file());
|
serial = load_serial(buf, create, NULL);
|
||||||
if (io == NULL)
|
if (serial == NULL) goto end;
|
||||||
{
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (BIO_read_filename(io,buf) <= 0)
|
|
||||||
{
|
|
||||||
if (!create)
|
|
||||||
{
|
|
||||||
perror(buf);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
ASN1_INTEGER_set(bs,1);
|
|
||||||
BN_one(serial);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (!a2i_ASN1_INTEGER(io,bs,buf2,sizeof buf2))
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"unable to load serial number from %s\n",buf);
|
|
||||||
ERR_print_errors(bio_err);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
serial=BN_bin2bn(bs->data,bs->length,serial);
|
|
||||||
if (serial == NULL)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"error converting bin 2 bn");
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!BN_add_word(serial,1))
|
if (!BN_add_word(serial,1))
|
||||||
{ BIO_printf(bio_err,"add_word failure\n"); goto end; }
|
{ BIO_printf(bio_err,"add_word failure\n"); goto end; }
|
||||||
if (!(bs2 = BN_to_ASN1_INTEGER(serial, NULL)))
|
|
||||||
{ BIO_printf(bio_err,"error converting bn 2 asn1_integer\n"); goto end; }
|
|
||||||
if (BIO_write_filename(io,buf) <= 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,"error attempting to write serial number file\n");
|
|
||||||
perror(buf);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
i2a_ASN1_INTEGER(io,bs2);
|
|
||||||
BIO_puts(io,"\n");
|
|
||||||
|
|
||||||
BIO_free(io);
|
if (!save_serial(buf, NULL, serial, &bs)) goto end;
|
||||||
|
|
||||||
|
end:
|
||||||
if (buf) OPENSSL_free(buf);
|
if (buf) OPENSSL_free(buf);
|
||||||
ASN1_INTEGER_free(bs2);
|
|
||||||
BN_free(serial);
|
BN_free(serial);
|
||||||
io=NULL;
|
|
||||||
return bs;
|
return bs;
|
||||||
|
|
||||||
end:
|
|
||||||
if (buf) OPENSSL_free(buf);
|
|
||||||
BIO_free(io);
|
|
||||||
ASN1_INTEGER_free(bs);
|
|
||||||
BN_free(serial);
|
|
||||||
return NULL;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int x509_certify(X509_STORE *ctx, char *CAfile, const EVP_MD *digest,
|
static int x509_certify(X509_STORE *ctx, char *CAfile, const EVP_MD *digest,
|
||||||
@@ -1148,10 +1115,10 @@ static int x509_certify(X509_STORE *ctx, char *CAfile, const EVP_MD *digest,
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
if (sno) bs = sno;
|
if (sno) bs = sno;
|
||||||
else if (!(bs = load_serial(CAfile, serialfile, create)))
|
else if (!(bs = x509_load_serial(CAfile, serialfile, create)))
|
||||||
goto end;
|
goto end;
|
||||||
|
|
||||||
if (!X509_STORE_add_cert(ctx,x)) goto end;
|
/* if (!X509_STORE_add_cert(ctx,x)) goto end;*/
|
||||||
|
|
||||||
/* NOTE: this certificate can/should be self signed, unless it was
|
/* NOTE: this certificate can/should be self signed, unless it was
|
||||||
* a certificate request in which case it is not. */
|
* a certificate request in which case it is not. */
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ RC4-MD5, but a re-connect tries to use DES-CBC-SHA. So netscape, when
|
|||||||
doing a re-connect, always takes the first cipher in the cipher list.
|
doing a re-connect, always takes the first cipher in the cipher list.
|
||||||
|
|
||||||
If we accept a netscape connection, demand a client cert, have a
|
If we accept a netscape connection, demand a client cert, have a
|
||||||
non-self-sighed CA which does not have it's CA in netscape, and the
|
non-self-signed CA which does not have it's CA in netscape, and the
|
||||||
browser has a cert, it will crash/hang. Works for 3.x and 4.xbeta
|
browser has a cert, it will crash/hang. Works for 3.x and 4.xbeta
|
||||||
|
|
||||||
Netscape browsers do not really notice the server sending a
|
Netscape browsers do not really notice the server sending a
|
||||||
|
|||||||
@@ -1,59 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 1 (0x1)
|
|
||||||
Signature Algorithm: md5WithRSAEncryption
|
|
||||||
Issuer: O=European ICE-TEL project, OU=V3-Certification Authority
|
|
||||||
Validity
|
|
||||||
Not Before: Apr 2 17:35:53 1997 GMT
|
|
||||||
Not After : Apr 2 17:35:53 1998 GMT
|
|
||||||
Subject: O=European ICE-TEL project, OU=V3-Certification Authority, L=Darmstadt
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsa
|
|
||||||
RSA Public Key: (512 bit)
|
|
||||||
Modulus (512 bit):
|
|
||||||
00:82:75:ba:f6:d1:60:b5:f9:15:b3:6a:dd:29:8f:
|
|
||||||
8b:a4:6f:1a:88:e0:50:43:40:0b:79:41:d5:d3:16:
|
|
||||||
44:7d:74:65:17:42:06:52:0b:e9:50:c8:10:cd:24:
|
|
||||||
e2:ae:8d:22:30:73:e6:b4:b7:93:1f:e5:6e:a2:ae:
|
|
||||||
49:11:a5:c9:45
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Authority Key Identifier:
|
|
||||||
0.........z.."p......e..
|
|
||||||
X509v3 Subject Key Identifier:
|
|
||||||
..~r..:..B.44fu......3
|
|
||||||
X509v3 Key Usage: critical
|
|
||||||
....
|
|
||||||
X509v3 Certificate Policies: critical
|
|
||||||
0.0...*...
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
0!..secude-support@darmstadt.gmd.de
|
|
||||||
X509v3 Issuer Alternative Name:
|
|
||||||
0I..ice-tel-ca@darmstadt.gmd.de.*http://www.darmstadt.gmd.de/ice-tel/euroca
|
|
||||||
X509v3 Basic Constraints: critical
|
|
||||||
0....
|
|
||||||
X509v3 CRL Distribution Points:
|
|
||||||
0200...,.*http://www.darmstadt.gmd.de/ice-tel/euroca
|
|
||||||
Signature Algorithm: md5WithRSAEncryption
|
|
||||||
17:a2:88:b7:99:5a:05:41:e4:13:34:67:e6:1f:3e:26:ec:4b:
|
|
||||||
69:f9:3e:28:22:be:9d:1c:ab:41:6f:0c:00:85:fe:45:74:f6:
|
|
||||||
98:f0:ce:9b:65:53:4a:50:42:c7:d4:92:bd:d7:a2:a8:3d:98:
|
|
||||||
88:73:cd:60:28:79:a3:fc:48:7a
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICzDCCAnagAwIBAgIBATANBgkqhkiG9w0BAQQFADBIMSEwHwYDVQQKExhFdXJv
|
|
||||||
cGVhbiBJQ0UtVEVMIHByb2plY3QxIzAhBgNVBAsTGlYzLUNlcnRpZmljYXRpb24g
|
|
||||||
QXV0aG9yaXR5MB4XDTk3MDQwMjE3MzU1M1oXDTk4MDQwMjE3MzU1M1owXDEhMB8G
|
|
||||||
A1UEChMYRXVyb3BlYW4gSUNFLVRFTCBwcm9qZWN0MSMwIQYDVQQLExpWMy1DZXJ0
|
|
||||||
aWZpY2F0aW9uIEF1dGhvcml0eTESMBAGA1UEBxMJRGFybXN0YWR0MFkwCgYEVQgB
|
|
||||||
AQICAgADSwAwSAJBAIJ1uvbRYLX5FbNq3SmPi6RvGojgUENAC3lB1dMWRH10ZRdC
|
|
||||||
BlIL6VDIEM0k4q6NIjBz5rS3kx/lbqKuSRGlyUUCAwEAAaOCATgwggE0MB8GA1Ud
|
|
||||||
IwQYMBaAFIr3yNUOx3ro1yJw4AuJ1bbsZbzPMB0GA1UdDgQWBBR+cvL4OoacQog0
|
|
||||||
NGZ1w9T80aIRMzAOBgNVHQ8BAf8EBAMCAfYwFAYDVR0gAQH/BAowCDAGBgQqAwQF
|
|
||||||
MCoGA1UdEQQjMCGBH3NlY3VkZS1zdXBwb3J0QGRhcm1zdGFkdC5nbWQuZGUwUgYD
|
|
||||||
VR0SBEswSYEbaWNlLXRlbC1jYUBkYXJtc3RhZHQuZ21kLmRlhipodHRwOi8vd3d3
|
|
||||||
LmRhcm1zdGFkdC5nbWQuZGUvaWNlLXRlbC9ldXJvY2EwDwYDVR0TAQH/BAUwAwEB
|
|
||||||
/zA7BgNVHR8ENDAyMDCgLqAshipodHRwOi8vd3d3LmRhcm1zdGFkdC5nbWQuZGUv
|
|
||||||
aWNlLXRlbC9ldXJvY2EwDQYJKoZIhvcNAQEEBQADQQAXooi3mVoFQeQTNGfmHz4m
|
|
||||||
7Etp+T4oIr6dHKtBbwwAhf5FdPaY8M6bZVNKUELH1JK916KoPZiIc81gKHmj/Eh6
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 0 (0x0)
|
|
||||||
Signature Algorithm: md5WithRSAEncryption
|
|
||||||
Issuer: O=European ICE-TEL project, OU=V3-Certification Authority
|
|
||||||
Validity
|
|
||||||
Not Before: Apr 2 17:33:36 1997 GMT
|
|
||||||
Not After : Apr 2 17:33:36 1998 GMT
|
|
||||||
Subject: O=European ICE-TEL project, OU=V3-Certification Authority
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsa
|
|
||||||
RSA Public Key: (512 bit)
|
|
||||||
Modulus (512 bit):
|
|
||||||
00:80:3e:eb:ae:47:a9:fe:10:54:0b:81:8b:9c:2b:
|
|
||||||
82:ab:3a:61:36:65:8b:f3:73:9f:ac:ac:7a:15:a7:
|
|
||||||
13:8f:b4:c4:ba:a3:0f:bc:a5:58:8d:cc:b1:93:31:
|
|
||||||
9e:81:9e:8c:19:61:86:fa:52:73:54:d1:97:76:22:
|
|
||||||
e7:c7:9f:41:cd
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Key Identifier:
|
|
||||||
........z.."p......e..
|
|
||||||
X509v3 Key Usage: critical
|
|
||||||
....
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
0I.*http://www.darmstadt.gmd.de/ice-tel/euroca..ice-tel-ca@darmstadt.gmd.de
|
|
||||||
X509v3 Basic Constraints: critical
|
|
||||||
0....
|
|
||||||
Signature Algorithm: md5WithRSAEncryption
|
|
||||||
76:69:61:db:b7:cf:8b:06:9e:d8:8c:96:53:d2:4d:a8:23:a6:
|
|
||||||
03:44:e8:8f:24:a5:c0:84:a8:4b:77:d4:2d:2b:7d:37:91:67:
|
|
||||||
f2:2c:ce:02:31:4c:6b:cc:ce:f2:68:a6:11:11:ab:7d:88:b8:
|
|
||||||
7e:22:9f:25:06:60:bd:79:30:3d
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICFjCCAcCgAwIBAgIBADANBgkqhkiG9w0BAQQFADBIMSEwHwYDVQQKExhFdXJv
|
|
||||||
cGVhbiBJQ0UtVEVMIHByb2plY3QxIzAhBgNVBAsTGlYzLUNlcnRpZmljYXRpb24g
|
|
||||||
QXV0aG9yaXR5MB4XDTk3MDQwMjE3MzMzNloXDTk4MDQwMjE3MzMzNlowSDEhMB8G
|
|
||||||
A1UEChMYRXVyb3BlYW4gSUNFLVRFTCBwcm9qZWN0MSMwIQYDVQQLExpWMy1DZXJ0
|
|
||||||
aWZpY2F0aW9uIEF1dGhvcml0eTBZMAoGBFUIAQECAgIAA0sAMEgCQQCAPuuuR6n+
|
|
||||||
EFQLgYucK4KrOmE2ZYvzc5+srHoVpxOPtMS6ow+8pViNzLGTMZ6BnowZYYb6UnNU
|
|
||||||
0Zd2IufHn0HNAgMBAAGjgZcwgZQwHQYDVR0OBBYEFIr3yNUOx3ro1yJw4AuJ1bbs
|
|
||||||
ZbzPMA4GA1UdDwEB/wQEAwIB9jBSBgNVHREESzBJhipodHRwOi8vd3d3LmRhcm1z
|
|
||||||
dGFkdC5nbWQuZGUvaWNlLXRlbC9ldXJvY2GBG2ljZS10ZWwtY2FAZGFybXN0YWR0
|
|
||||||
LmdtZC5kZTAPBgNVHRMBAf8EBTADAQH/MA0GCSqGSIb3DQEBBAUAA0EAdmlh27fP
|
|
||||||
iwae2IyWU9JNqCOmA0TojySlwISoS3fULSt9N5Fn8izOAjFMa8zO8mimERGrfYi4
|
|
||||||
fiKfJQZgvXkwPQ==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@@ -1,63 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 1 (0x1)
|
|
||||||
Signature Algorithm: md5WithRSAEncryption
|
|
||||||
Issuer: O=European ICE-TEL project, OU=V3-Certification Authority, L=Darmstadt
|
|
||||||
Validity
|
|
||||||
Not Before: Apr 2 17:35:59 1997 GMT
|
|
||||||
Not After : Apr 2 17:35:59 1998 GMT
|
|
||||||
Subject: O=European ICE-TEL project, OU=V3-Certification Authority, L=Darmstadt, CN=USER
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsa
|
|
||||||
RSA Public Key: (512 bit)
|
|
||||||
Modulus (512 bit):
|
|
||||||
00:a8:a8:53:63:49:1b:93:c3:c3:0b:6c:88:11:55:
|
|
||||||
de:7e:6a:e2:f9:52:a0:dc:69:25:c4:c8:bf:55:e1:
|
|
||||||
31:a8:ce:e4:a9:29:85:99:8a:15:9a:de:f6:2f:e1:
|
|
||||||
b4:50:5f:5e:04:75:a6:f4:76:dc:3c:0e:39:dc:3a:
|
|
||||||
be:3e:a4:61:8b
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Authority Key Identifier:
|
|
||||||
0...~r..:..B.44fu......3
|
|
||||||
X509v3 Subject Key Identifier:
|
|
||||||
...... .*...1.*.......
|
|
||||||
X509v3 Key Usage: critical
|
|
||||||
....
|
|
||||||
X509v3 Certificate Policies: critical
|
|
||||||
0.0...*...0.......
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
0:..user@darmstadt.gmd.de.!http://www.darmstadt.gmd.de/~user
|
|
||||||
X509v3 Issuer Alternative Name:
|
|
||||||
0....gmdca@gmd.de..http://www.gmd.de..saturn.darmstadt.gmd.de.\1!0...U.
|
|
||||||
..European ICE-TEL project1#0!..U....V3-Certification Authority1.0...U....Darmstadt..141.12.62.26
|
|
||||||
X509v3 Basic Constraints: critical
|
|
||||||
0.
|
|
||||||
X509v3 CRL Distribution Points:
|
|
||||||
0.0.......gmdca@gmd.de
|
|
||||||
Signature Algorithm: md5WithRSAEncryption
|
|
||||||
69:0c:e1:b7:a7:f2:d8:fb:e8:69:c0:13:cd:37:ad:21:06:22:
|
|
||||||
4d:e8:c6:db:f1:04:0b:b7:e0:b3:d6:0c:81:03:ce:c3:6a:3e:
|
|
||||||
c7:e7:24:24:a4:92:64:c2:83:83:06:42:53:0e:6f:09:1e:84:
|
|
||||||
9a:f7:6f:63:9b:94:99:83:d6:a4
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDTzCCAvmgAwIBAgIBATANBgkqhkiG9w0BAQQFADBcMSEwHwYDVQQKExhFdXJv
|
|
||||||
cGVhbiBJQ0UtVEVMIHByb2plY3QxIzAhBgNVBAsTGlYzLUNlcnRpZmljYXRpb24g
|
|
||||||
QXV0aG9yaXR5MRIwEAYDVQQHEwlEYXJtc3RhZHQwHhcNOTcwNDAyMTczNTU5WhcN
|
|
||||||
OTgwNDAyMTczNTU5WjBrMSEwHwYDVQQKExhFdXJvcGVhbiBJQ0UtVEVMIHByb2pl
|
|
||||||
Y3QxIzAhBgNVBAsTGlYzLUNlcnRpZmljYXRpb24gQXV0aG9yaXR5MRIwEAYDVQQH
|
|
||||||
EwlEYXJtc3RhZHQxDTALBgNVBAMTBFVTRVIwWTAKBgRVCAEBAgICAANLADBIAkEA
|
|
||||||
qKhTY0kbk8PDC2yIEVXefmri+VKg3GklxMi/VeExqM7kqSmFmYoVmt72L+G0UF9e
|
|
||||||
BHWm9HbcPA453Dq+PqRhiwIDAQABo4IBmDCCAZQwHwYDVR0jBBgwFoAUfnLy+DqG
|
|
||||||
nEKINDRmdcPU/NGiETMwHQYDVR0OBBYEFJfc4B8gjSoRmLUx4Sq/ucIYiMrPMA4G
|
|
||||||
A1UdDwEB/wQEAwIB8DAcBgNVHSABAf8EEjAQMAYGBCoDBAUwBgYECQgHBjBDBgNV
|
|
||||||
HREEPDA6gRV1c2VyQGRhcm1zdGFkdC5nbWQuZGWGIWh0dHA6Ly93d3cuZGFybXN0
|
|
||||||
YWR0LmdtZC5kZS9+dXNlcjCBsQYDVR0SBIGpMIGmgQxnbWRjYUBnbWQuZGWGEWh0
|
|
||||||
dHA6Ly93d3cuZ21kLmRlghdzYXR1cm4uZGFybXN0YWR0LmdtZC5kZaRcMSEwHwYD
|
|
||||||
VQQKExhFdXJvcGVhbiBJQ0UtVEVMIHByb2plY3QxIzAhBgNVBAsTGlYzLUNlcnRp
|
|
||||||
ZmljYXRpb24gQXV0aG9yaXR5MRIwEAYDVQQHEwlEYXJtc3RhZHSHDDE0MS4xMi42
|
|
||||||
Mi4yNjAMBgNVHRMBAf8EAjAAMB0GA1UdHwQWMBQwEqAQoA6BDGdtZGNhQGdtZC5k
|
|
||||||
ZTANBgkqhkiG9w0BAQQFAANBAGkM4ben8tj76GnAE803rSEGIk3oxtvxBAu34LPW
|
|
||||||
DIEDzsNqPsfnJCSkkmTCg4MGQlMObwkehJr3b2OblJmD1qQ=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
-----BEGIN X509 CRL-----
|
|
||||||
MIIBNDCBnjANBgkqhkiG9w0BAQIFADBFMSEwHwYDVQQKExhFdXJvcGVhbiBJQ0Ut
|
|
||||||
VEVMIFByb2plY3QxIDAeBgNVBAsTF0NlcnRpZmljYXRpb24gQXV0aG9yaXR5Fw05
|
|
||||||
NzA2MDkxNDQyNDNaFw05NzA3MDkxNDQyNDNaMCgwEgIBChcNOTcwMzAzMTQ0MjU0
|
|
||||||
WjASAgEJFw05NjEwMDIxMjI5MjdaMA0GCSqGSIb3DQEBAgUAA4GBAH4vgWo2Tej/
|
|
||||||
i7kbiw4Imd30If91iosjClNpBFwvwUDBclPEeMuYimHbLOk4H8Nofc0fw11+U/IO
|
|
||||||
KSNouUDcqG7B64oY7c4SXKn+i1MWOb5OJiWeodX3TehHjBlyWzoNMWCnYA8XqFP1
|
|
||||||
mOKp8Jla1BibEZf14+/HqCi2hnZUiEXh
|
|
||||||
-----END X509 CRL-----
|
|
||||||
23
certs/eng1.pem
Normal file
23
certs/eng1.pem
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIID3TCCAsWgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBqDELMAkGA1UEBhMCQ0Ex
|
||||||
|
CzAJBgNVBAgTAk9OMRAwDgYDVQQHEwdUb3JvbnRvMRgwFgYDVQQKEw9CYW5rRW5n
|
||||||
|
aW5lIEluYy4xKTAnBgNVBAsTIENlcnRpZmljYXRpb24gQXV0aG9yaXR5IERpdmlz
|
||||||
|
aW9uMRMwEQYDVQQDEwpiYW5rZW5naW5lMSAwHgYJKoZIhvcNAQkBFhFjYUBiYW5r
|
||||||
|
ZW5naW5lLmNvbTAeFw05ODAxMDEwMDAwMDBaFw0zODAxMTcwMDAwMDBaMIGoMQsw
|
||||||
|
CQYDVQQGEwJDQTELMAkGA1UECBMCT04xEDAOBgNVBAcTB1Rvcm9udG8xGDAWBgNV
|
||||||
|
BAoTD0JhbmtFbmdpbmUgSW5jLjEpMCcGA1UECxMgQ2VydGlmaWNhdGlvbiBBdXRo
|
||||||
|
b3JpdHkgRGl2aXNpb24xEzARBgNVBAMTCmJhbmtlbmdpbmUxIDAeBgkqhkiG9w0B
|
||||||
|
CQEWEWNhQGJhbmtlbmdpbmUuY29tMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
|
||||||
|
CgKCAQEA14LoTUAl1/hEy+Kh1kLHiBdW2zD3V4IhM7xxTVKsYsIH56nr69ATTIxU
|
||||||
|
P36eRzeZ137qt1AxHFjDCidk3m1Ul6l59ProPexdslLLM2npM3f2cteg+toyiYiS
|
||||||
|
EJKjyzIu1xF1j9qzGkymSY/4DsXLZNk9FaczxMk/Ooc6Os1M3AverL4VG4rYIb6f
|
||||||
|
eR32cIKJ9Q1fGuyKk7ipq1XQfPW8a8TgZdbHbe7U9Gk3iasGMHHvpR9Ep3mGbgdT
|
||||||
|
uQ98SBEuIwe1BUCGg/MXpVy48MNXfAMotBgGw4pl9yqSjMni2FB+E9Q9DHFs2RgX
|
||||||
|
MqzKuo8zcPxKx2kZ6Arj8+27dw2clQIDAQABoxAwDjAMBgNVHRMEBTADAQH/MA0G
|
||||||
|
CSqGSIb3DQEBBQUAA4IBAQBauupHX9EhpC/r57d6b5kkeWvognxIP9//TO4iw3qb
|
||||||
|
zIXEkPXmJmwVzlzoKJWqiya+aw19SP0+G6CzsFOBo/9ehmz+hZ8bhYX4MjlWzX5u
|
||||||
|
Tnkhz172j9fOBUmrTVPkcRIs6zjCD5PQAGoBPP1/Zdy2N36lZ0U7lg07Opirj/yJ
|
||||||
|
PSJeM2j0fwIFAroiVckvdT0BVwB6S/cPaAQGPghbbr1YGSmYrMriSv825ILJUfxz
|
||||||
|
rJYunGR9FiY9Ob7+jwJwiZMS4CxSPktutxr/3hOvr1+ALS7IcVakhhA3PuZAJbdH
|
||||||
|
FRclR9qMM8aBnBZmf+Uv3K3uhT+UBzzY654U9Yi1JYnA
|
||||||
|
-----END CERTIFICATE-----
|
||||||
23
certs/eng2.pem
Normal file
23
certs/eng2.pem
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIID3TCCAsWgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBqDELMAkGA1UEBhMCQ0Ex
|
||||||
|
CzAJBgNVBAgTAk9OMRAwDgYDVQQHEwdUb3JvbnRvMRgwFgYDVQQKEw9DZXJ0RW5n
|
||||||
|
aW5lIEluYy4xKTAnBgNVBAsTIENlcnRpZmljYXRpb24gQXV0aG9yaXR5IERpdmlz
|
||||||
|
aW9uMRMwEQYDVQQDEwpjZXJ0ZW5naW5lMSAwHgYJKoZIhvcNAQkBFhFjYUBjZXJ0
|
||||||
|
ZW5naW5lLmNvbTAeFw05ODAxMDEwMDAwMDBaFw0zODAxMTcwMDAwMDBaMIGoMQsw
|
||||||
|
CQYDVQQGEwJDQTELMAkGA1UECBMCT04xEDAOBgNVBAcTB1Rvcm9udG8xGDAWBgNV
|
||||||
|
BAoTD0NlcnRFbmdpbmUgSW5jLjEpMCcGA1UECxMgQ2VydGlmaWNhdGlvbiBBdXRo
|
||||||
|
b3JpdHkgRGl2aXNpb24xEzARBgNVBAMTCmNlcnRlbmdpbmUxIDAeBgkqhkiG9w0B
|
||||||
|
CQEWEWNhQGNlcnRlbmdpbmUuY29tMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
|
||||||
|
CgKCAQEA7aTXURShaeVt9u/dP3Q2dVib3jTCZvEyc6yfpGgaYWewXWuP4HOSfI4h
|
||||||
|
GZblbpl+dzJc6RjhR+pguIRtbT5FJB8SJGjRqoujBEOQOxtVtc2fjM9Dqh0iOvMW
|
||||||
|
WS6buxHG55GVrHAQaO5HXEScKQBa9ZyNmpSXPTEBrDMej1OAGOkc524/TZrgFPF4
|
||||||
|
AiJLLkxCcP8NuzUKlW3WzNMSSoCtjkUKy4wjSLlAWCFM0T9Df6/+Z8ZUQTzHoKCD
|
||||||
|
ncH5Qnynd7DlOwKQ2JwwxRhYGiGVTUN0GUq7qA11kW3+vnbFesKQXoF6o2PVx9s2
|
||||||
|
YXviI2NXXUjZ0pVnsnFCc45Pm8XojwIDAQABoxAwDjAMBgNVHRMEBTADAQH/MA0G
|
||||||
|
CSqGSIb3DQEBBQUAA4IBAQBP/aHOKJ00Akzc9HWM1X30hlWZFBaQi4pqD4Uhk8+p
|
||||||
|
KzzwFP5DRLBOz8TYBbtdXrS6hxVMr2sqWmhVkuyepWhHZazKGyHY/y0FbOXsewAV
|
||||||
|
1QxxSyx7ve89pCKv4/w0rQcP916iHc8Y/TCpmz7eITa3GId+8H/XTaBi8GBp9X9O
|
||||||
|
w8m25FmEB1NT+eJwefvfdKowjy4tSorKdW/eJspxNuTSRGmUy8G71W5dYvgpAlx6
|
||||||
|
mdnHyzxEGvRYNNI2bS0ifXgbEFNWqSas9q34ea5KOpkJu8T/KyXfSb6rPOsBSb0t
|
||||||
|
wMowwGtCVH2C4Lw/8zo0EjhMpTOsPaub408PrZ+NQ2bl
|
||||||
|
-----END CERTIFICATE-----
|
||||||
34
certs/eng3.pem
Normal file
34
certs/eng3.pem
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIIF3TCCA8WgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBqDELMAkGA1UEBhMCQ0Ex
|
||||||
|
CzAJBgNVBAgTAk9OMRAwDgYDVQQHEwdUb3JvbnRvMRgwFgYDVQQKEw9Gb3J0RW5n
|
||||||
|
aW5lIEluYy4xKTAnBgNVBAsTIENlcnRpZmljYXRpb24gQXV0aG9yaXR5IERpdmlz
|
||||||
|
aW9uMRMwEQYDVQQDEwpmb3J0ZW5naW5lMSAwHgYJKoZIhvcNAQkBFhFjYUBmb3J0
|
||||||
|
ZW5naW5lLmNvbTAeFw05ODAxMDEwMDAwMDBaFw0zODAxMTcwMDAwMDBaMIGoMQsw
|
||||||
|
CQYDVQQGEwJDQTELMAkGA1UECBMCT04xEDAOBgNVBAcTB1Rvcm9udG8xGDAWBgNV
|
||||||
|
BAoTD0ZvcnRFbmdpbmUgSW5jLjEpMCcGA1UECxMgQ2VydGlmaWNhdGlvbiBBdXRo
|
||||||
|
b3JpdHkgRGl2aXNpb24xEzARBgNVBAMTCmZvcnRlbmdpbmUxIDAeBgkqhkiG9w0B
|
||||||
|
CQEWEWNhQGZvcnRlbmdpbmUuY29tMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIIC
|
||||||
|
CgKCAgEAyr7GbpwDxx1v3EYbo0gcO+ligEhlDqG2e7u/AbWGoVAqc8+q6auUJUtz
|
||||||
|
4i7oh0yNadu1o9kpXW+znkgO0zlrgjGskqqMO1ooppzTJdFy/P8gR6x1Iuv3kWtX
|
||||||
|
OuzwPPEjv09LWlhyJsN+oU4ztTVf07I0Q9zYupcoDQ58XKRheI9KdDB2DYSmxywA
|
||||||
|
WSLQwIeG0Qa7gvokeQlpkgkEC7viEecJ3752KXBJHnh7As51mxnlpmG6sDy67Eli
|
||||||
|
HDw5tHETRqbtnscGBjskGQBqR5xt7+QnnthZrN8HJHDoa9zgGephwizhkL44lXLF
|
||||||
|
YK9W5XhFbblw2c+mAcHkokRiwD7CPeIoyD2a/Jcw3n5hegKTlNhd4BFGVF6JR7gF
|
||||||
|
OFk2QfHXit5uthsij9Xhl7WAgQUqLgggD9MphqPf4nY66OZUJV9ZsmB+Qfp8UizB
|
||||||
|
0WAOegactKVyRqHtRa+KIEXQXNtZgjcmMk9CYkP0nIbKtgKXaH6+9VMHNOryCnFE
|
||||||
|
7pSsuPUkypncFWCHGSeiFO3w4w4J4csltxBADQzxfRu5KZnlToQN7bVpI/Q31tVX
|
||||||
|
E5bjrJcq6Oj/OTqZ3ID+OqbkUdAg0ggjRKcTgxnLHd/AbMzJ6PsclDDf7cLs0WSl
|
||||||
|
xMxQR/z5bNST1rNtT9rsiv2TOhfvCBxO9AOjBioO8PLO032HTNECAwEAAaMQMA4w
|
||||||
|
DAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQUFAAOCAgEAVyBpPWfT2VOyvVpslGKx
|
||||||
|
8h0+CWP8cilygGRtZJ5dAJzc//1REAHdvK+TgZ4Foz3dqHhXI+RNN0FpzuWaYMjW
|
||||||
|
ZTS0kAmcOQuGY1Oo4PGlPHI21pNz29oFDTJr0ZmLBJ4JKVsE2soJg55jdk9MZHA7
|
||||||
|
K//7HH9RsmrWZOE5DZDlrxp6+naixhMwnlPKKisIy9GNZUPqGdUWABMdB/BUVVNl
|
||||||
|
NU5TtWpIXUClMd8a+eoKcItBeYXowkHOBpinPkDX3clFDIUfWiw0Ro08s8SrrFqR
|
||||||
|
8Szwbrj52Xv1RM56oGqCjnkvJctxihODV7NcpxoAFjIZokDom0q6zPrrTUsLFQov
|
||||||
|
Plovc3w5hmALiDMshaTvE1nm3Psn4yQ+FlRE8epTZrQiIGypZkZC6lcz0mYawueW
|
||||||
|
cThYWGFhVG4ktQzOjjNRsNxopW+W7cF1zQTxiWUDnxIKSj7gtdQ2jiubxEEhfVag
|
||||||
|
r8DMtAccNVTZVURpGi56TptOOuotrTqqC+2GviW4hlxvdvmuQN0OlXlUwzz2Trxc
|
||||||
|
FamNnuA54lZw/8arLtxsFmHrcnPw53+1spumLD0S5UkxHNu40h6LIVpZz3H+0rLz
|
||||||
|
uFofTfiyMjcfK2AyHQTgUCbsrvgNuLDQUbyFGVchdFUkhztX3DhEVnxnnrpY4BVj
|
||||||
|
QdTqWIvw7lGlSuDCjxEQAOc=
|
||||||
|
-----END CERTIFICATE-----
|
||||||
23
certs/eng4.pem
Normal file
23
certs/eng4.pem
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIID3TCCAsWgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBqDELMAkGA1UEBhMCQ0Ex
|
||||||
|
CzAJBgNVBAgTAk9OMRAwDgYDVQQHEwdUb3JvbnRvMRgwFgYDVQQKEw9NYWlsRW5n
|
||||||
|
aW5lIEluYy4xKTAnBgNVBAsTIENlcnRpZmljYXRpb24gQXV0aG9yaXR5IERpdmlz
|
||||||
|
aW9uMRMwEQYDVQQDEwptYWlsZW5naW5lMSAwHgYJKoZIhvcNAQkBFhFjYUBtYWls
|
||||||
|
ZW5naW5lLmNvbTAeFw05ODAxMDEwMDAwMDBaFw0zODAxMTcwMDAwMDBaMIGoMQsw
|
||||||
|
CQYDVQQGEwJDQTELMAkGA1UECBMCT04xEDAOBgNVBAcTB1Rvcm9udG8xGDAWBgNV
|
||||||
|
BAoTD01haWxFbmdpbmUgSW5jLjEpMCcGA1UECxMgQ2VydGlmaWNhdGlvbiBBdXRo
|
||||||
|
b3JpdHkgRGl2aXNpb24xEzARBgNVBAMTCm1haWxlbmdpbmUxIDAeBgkqhkiG9w0B
|
||||||
|
CQEWEWNhQG1haWxlbmdpbmUuY29tMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
|
||||||
|
CgKCAQEAqXmfsU+lx+NFmn6tN17RTOyaddHqLnr/3rzEDIyT9TN+tF9TG7jmK7lJ
|
||||||
|
Jrj5arQ3nTFaLF8JuND2U1z/cLPw6/TX+1tE3v3CNUDSjaisyUDiUyp3TE8hMMMz
|
||||||
|
zfZQn0JsGgNhhWxqyzjhRQGtKL4+xtn8VsF/8zGgZYke7nlmVKz/FslDFTnNoodL
|
||||||
|
BAEGiu9JQS9qqpbSs20NdZ6LXPL2A4iTjnsNFBW3jIMVIn/JVVyaycU7ue2oFviD
|
||||||
|
vLNpkVZcR7A+jjIdIumOc5VSF0y7y74cQC5YwkR2mLK7UBYDK6NCY3ta/C4M8NsM
|
||||||
|
0FpmvRl0+A1ivZtVwqI98dxDtp7HeQIDAQABoxAwDjAMBgNVHRMEBTADAQH/MA0G
|
||||||
|
CSqGSIb3DQEBBQUAA4IBAQAjfNn5BCzxylBDakFQGWKE/P43PRibMOEzfd7+DzbY
|
||||||
|
WIekoz3i00DwoH3b6j4gwlDJRAOq4dF6/Pt/uBOHDo/op+ef+9ErmKPd+ehXN9h3
|
||||||
|
7QbccTgz7DtVwA4iRlDRLru+JuXzT+OsCHuFZMOLJ+KD2JAGh3W68JjdcLkrlcpt
|
||||||
|
AU0wc5aOHPPfEBdIah8y8QtNzXRVzoBt8zzvgCARkXxTS2u/9QaXR1hML0JtDgQS
|
||||||
|
SdZ6Kd8SN6yzqxD+buYD5sOfJmjBF/n3lqFHNMHnnGXy2TAXZtIAWzffU3A0cGPB
|
||||||
|
N6FZ026a86HbF1X4k+xszhbJu/ikczyuWnCJIg3fTYSD
|
||||||
|
-----END CERTIFICATE-----
|
||||||
23
certs/eng5.pem
Normal file
23
certs/eng5.pem
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIID6TCCAtGgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBrjELMAkGA1UEBhMCQ0Ex
|
||||||
|
CzAJBgNVBAgTAk9OMRAwDgYDVQQHEwdUb3JvbnRvMRowGAYDVQQKExFUcmFkZXJF
|
||||||
|
bmdpbmUgSW5jLjEpMCcGA1UECxMgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgRGl2
|
||||||
|
aXNpb24xFTATBgNVBAMTDHRyYWRlcmVuZ2luZTEiMCAGCSqGSIb3DQEJARYTY2FA
|
||||||
|
dHJhZGVyZW5naW5lLmNvbTAeFw05ODAxMDEwMDAwMDBaFw0zODAxMTcwMDAwMDBa
|
||||||
|
MIGuMQswCQYDVQQGEwJDQTELMAkGA1UECBMCT04xEDAOBgNVBAcTB1Rvcm9udG8x
|
||||||
|
GjAYBgNVBAoTEVRyYWRlckVuZ2luZSBJbmMuMSkwJwYDVQQLEyBDZXJ0aWZpY2F0
|
||||||
|
aW9uIEF1dGhvcml0eSBEaXZpc2lvbjEVMBMGA1UEAxMMdHJhZGVyZW5naW5lMSIw
|
||||||
|
IAYJKoZIhvcNAQkBFhNjYUB0cmFkZXJlbmdpbmUuY29tMIIBIjANBgkqhkiG9w0B
|
||||||
|
AQEFAAOCAQ8AMIIBCgKCAQEAzyX5QE+5SN+zgNn1v3zp9HmP4hQOWW8WuEVItZVP
|
||||||
|
9bt/xj5NeJd1kyPL/SqnF2qHcL3o/74r0Ga55aKHniwKYgQTlp5ELGfQ568QQeN9
|
||||||
|
xNIHtUXeStI9zCNZyZC+4YqObdMR/ivKA/WsLfUVMl2lV5JzJJz1BOE0gKEYiEyz
|
||||||
|
gIq5oLzkP/mOXoHRvWSZD2D0eHYIO7ovV2epVFK7g7p+dC4QoeIUEli+GF/Myg88
|
||||||
|
dV/qmi+Sybck2RLPXa8Nh27/ETVQ7kE1Eafmx7EyCqIhG+5lwJAy3HwHUBwAYuzj
|
||||||
|
iuZz5lD8aQmr8SKuvy3eOH9SVN5wh3YBlrNGwTStkESVLwIDAQABoxAwDjAMBgNV
|
||||||
|
HRMEBTADAQH/MA0GCSqGSIb3DQEBBQUAA4IBAQAWOPAUhZd3x9EQiFJcuxFTMd9q
|
||||||
|
axgcriCzJsM6D96sYGko9xTeLhX/lr1bliVYI5AlupoLXAdMzGHJkOgaTirKjQXr
|
||||||
|
F9nymDdUWKe3TmwGob5016nQlH7qRKvGO3hka0rOGRK2U/2JT/4Qp8iH/DFi6cyM
|
||||||
|
uP0q8n64SAkxZXLzUuFQXqf7U/SNjzb9XJQEIAdjp7eYd3Qb4jDsDcX0FrKMF1aV
|
||||||
|
r0dCDnS7am7WTXPYCDGdSkPgEHEtLYIYH3lZp5sKdVZ9wl4F0WNFkRWRUr7AXPjw
|
||||||
|
50uLmUNmKCd8JZLMGA1TRNSTi7U9EcrWt0OkMWm74T2WVnAgNsDv2WrWsGfj
|
||||||
|
-----END CERTIFICATE-----
|
||||||
18
certs/expired/vsign3.pem
Normal file
18
certs/expired/vsign3.pem
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
subject=/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
||||||
|
notBefore=Jan 29 00:00:00 1996 GMT
|
||||||
|
notAfter=Jan 7 23:59:59 2004 GMT
|
||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIICPTCCAaYCEQDknv3zOugOz6URPhmkJAIyMA0GCSqGSIb3DQEBAgUAMF8xCzAJ
|
||||||
|
BgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xh
|
||||||
|
c3MgMyBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05
|
||||||
|
NjAxMjkwMDAwMDBaFw0wNDAxMDcyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYD
|
||||||
|
VQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMgUHJp
|
||||||
|
bWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOB
|
||||||
|
jQAwgYkCgYEAyVxZnvIbigEUtBDfBEDb41evakVAj4QMC9Ez2dkRz+4CWB8l9yqo
|
||||||
|
RAWq7AMfeH+ek7maAKojfdashaJjRcdyJ8z0TMZ1cdI5709C8HXfCpDGjiBvmA/4
|
||||||
|
rCNfcCk2pMmG57GaIMtTpYXnPb59mv4kRTPcdhXtD6JxZExlLoFoRacCAwEAATAN
|
||||||
|
BgkqhkiG9w0BAQIFAAOBgQBhcOwvP579K+ZoVCGwZ3kIDCCWMYoNer62Jt95LCJp
|
||||||
|
STbjl3diYaIy13pUITa6Ask05yXaRDWw0lyAXbOU+Pms7qRgdSoflUkjsUp89LNH
|
||||||
|
ciFbfperVKxi513srpvSybIk+4Kt6WcVS7qqpvCXoPawl1cAyAw8CaCCBLpB2veZ
|
||||||
|
pA==
|
||||||
|
-----END CERTIFICATE-----
|
||||||
@@ -1,18 +1,17 @@
|
|||||||
subject=/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
subject=/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
||||||
notBefore=Jan 29 00:00:00 1996 GMT
|
notBefore=Jan 29 00:00:00 1996 GMT
|
||||||
notAfter=Jan 7 23:59:59 2004 GMT
|
notAfter=Aug 1 23:59:59 2028 GMT
|
||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
MIICPTCCAaYCEQDknv3zOugOz6URPhmkJAIyMA0GCSqGSIb3DQEBAgUAMF8xCzAJ
|
MIICPDCCAaUCEHC65B0Q2Sk0tjjKewPMur8wDQYJKoZIhvcNAQECBQAwXzELMAkG
|
||||||
BgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xh
|
A1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTcwNQYDVQQLEy5DbGFz
|
||||||
c3MgMyBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05
|
cyAzIFB1YmxpYyBQcmltYXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTk2
|
||||||
NjAxMjkwMDAwMDBaFw0wNDAxMDcyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYD
|
MDEyOTAwMDAwMFoXDTI4MDgwMTIzNTk1OVowXzELMAkGA1UEBhMCVVMxFzAVBgNV
|
||||||
VQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMgUHJp
|
BAoTDlZlcmlTaWduLCBJbmMuMTcwNQYDVQQLEy5DbGFzcyAzIFB1YmxpYyBQcmlt
|
||||||
bWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOB
|
YXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIGfMA0GCSqGSIb3DQEBAQUAA4GN
|
||||||
jQAwgYkCgYEAyVxZnvIbigEUtBDfBEDb41evakVAj4QMC9Ez2dkRz+4CWB8l9yqo
|
ADCBiQKBgQDJXFme8huKARS0EN8EQNvjV69qRUCPhAwL0TPZ2RHP7gJYHyX3KqhE
|
||||||
RAWq7AMfeH+ek7maAKojfdashaJjRcdyJ8z0TMZ1cdI5709C8HXfCpDGjiBvmA/4
|
BarsAx94f56TuZoAqiN91qyFomNFx3InzPRMxnVx0jnvT0Lwdd8KkMaOIG+YD/is
|
||||||
rCNfcCk2pMmG57GaIMtTpYXnPb59mv4kRTPcdhXtD6JxZExlLoFoRacCAwEAATAN
|
I19wKTakyYbnsZogy1Olhec9vn2a/iRFM9x2Fe0PonFkTGUugWhFpwIDAQABMA0G
|
||||||
BgkqhkiG9w0BAQIFAAOBgQBhcOwvP579K+ZoVCGwZ3kIDCCWMYoNer62Jt95LCJp
|
CSqGSIb3DQEBAgUAA4GBALtMEivPLCYATxQT3ab7/AoRhIzzKBxnki98tsX63/Do
|
||||||
STbjl3diYaIy13pUITa6Ask05yXaRDWw0lyAXbOU+Pms7qRgdSoflUkjsUp89LNH
|
lbwdj2wsqFHMc9ikwFPwTtYmwHYBV4GSXiHx0bH/59AhWM1pF+NEHJwZRDmJXNyc
|
||||||
ciFbfperVKxi513srpvSybIk+4Kt6WcVS7qqpvCXoPawl1cAyAw8CaCCBLpB2veZ
|
AA9WjQKZ7aKQRUzkuxCkPfAyAw7xzvjoyVGM5mKf5p/AfbdynMk2OmufTqj/ZA1k
|
||||||
pA==
|
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
|
|||||||
23
certs/wellsfgo.pem
Normal file
23
certs/wellsfgo.pem
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
-----BEGIN CERTIFICATE-----
|
||||||
|
MIID5TCCAs2gAwIBAgIEOeSXnjANBgkqhkiG9w0BAQUFADCBgjELMAkGA1UEBhMC
|
||||||
|
VVMxFDASBgNVBAoTC1dlbGxzIEZhcmdvMSwwKgYDVQQLEyNXZWxscyBGYXJnbyBD
|
||||||
|
ZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTEvMC0GA1UEAxMmV2VsbHMgRmFyZ28gUm9v
|
||||||
|
dCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwHhcNMDAxMDExMTY0MTI4WhcNMjEwMTE0
|
||||||
|
MTY0MTI4WjCBgjELMAkGA1UEBhMCVVMxFDASBgNVBAoTC1dlbGxzIEZhcmdvMSww
|
||||||
|
KgYDVQQLEyNXZWxscyBGYXJnbyBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTEvMC0G
|
||||||
|
A1UEAxMmV2VsbHMgRmFyZ28gUm9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwggEi
|
||||||
|
MA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDVqDM7Jvk0/82bfuUER84A4n13
|
||||||
|
5zHCLielTWi5MbqNQ1mXx3Oqfz1cQJ4F5aHiidlMuD+b+Qy0yGIZLEWukR5zcUHE
|
||||||
|
SxP9cMIlrCL1dQu3U+SlK93OvRw6esP3E48mVJwWa2uv+9iWsWCaSOAlIiR5NM4O
|
||||||
|
JgALTqv9i86C1y8IcGjBqAr5dE8Hq6T54oN+J3N0Prj5OEL8pahbSCOz6+MlsoCu
|
||||||
|
ltQKnMJ4msZoGK43YjdeUXWoWGPAUe5AeH6orxqg4bB4nVCMe+ez/I4jsNtlAHCE
|
||||||
|
AQgAFG5Uhpq6zPk3EPbg3oQtnaSFN9OH4xXQwReQfhkhahKpdv0SAulPIV4XAgMB
|
||||||
|
AAGjYTBfMA8GA1UdEwEB/wQFMAMBAf8wTAYDVR0gBEUwQzBBBgtghkgBhvt7hwcB
|
||||||
|
CzAyMDAGCCsGAQUFBwIBFiRodHRwOi8vd3d3LndlbGxzZmFyZ28uY29tL2NlcnRw
|
||||||
|
b2xpY3kwDQYJKoZIhvcNAQEFBQADggEBANIn3ZwKdyu7IvICtUpKkfnRLb7kuxpo
|
||||||
|
7w6kAOnu5+/u9vnldKTC2FJYxHT7zmu1Oyl5GFrvm+0fazbuSCUlFLZWohDo7qd/
|
||||||
|
0D+j0MNdJu4HzMPBJCGHHt8qElNvQRbn7a6U+oxy+hNH8Dx+rn0ROhPs7fpvcmR7
|
||||||
|
nX1/Jv16+yWt6j4pf0zjAFcysLPp7VMX2YuyFA4w6OXVE8Zkr8QA1dhYJPz1j+zx
|
||||||
|
x32l2w8n0cbyQIjmH/ZhqPRCyLk306m+LFZ4wnKbWV01QIroTmMatukgalHizqSQ
|
||||||
|
33ZwmVxwQ023tqcZZE6St8WRPH9IFmV7Fv3L/PvZ1dZPIWU7Sn9Ho/s=
|
||||||
|
-----END CERTIFICATE-----
|
||||||
157
config
157
config
@@ -23,6 +23,7 @@
|
|||||||
PREFIX=""
|
PREFIX=""
|
||||||
SUFFIX=""
|
SUFFIX=""
|
||||||
TEST="false"
|
TEST="false"
|
||||||
|
EXE=""
|
||||||
|
|
||||||
# pick up any command line args to config
|
# pick up any command line args to config
|
||||||
for i
|
for i
|
||||||
@@ -110,16 +111,16 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
|||||||
echo "m68k-apple-aux3"; exit 0
|
echo "m68k-apple-aux3"; exit 0
|
||||||
;;
|
;;
|
||||||
|
|
||||||
AIX:[3456789]:4:*)
|
AIX:[3-9]:4:*)
|
||||||
echo "${MACHINE}-ibm-aix43"; exit 0
|
echo "${MACHINE}-ibm-aix"; exit 0
|
||||||
;;
|
;;
|
||||||
|
|
||||||
AIX:*:[56789]:*)
|
AIX:*:[5-9]:*)
|
||||||
echo "${MACHINE}-ibm-aix43"; exit 0
|
echo "${MACHINE}-ibm-aix"; exit 0
|
||||||
;;
|
;;
|
||||||
|
|
||||||
AIX:*)
|
AIX:*)
|
||||||
echo "${MACHINE}-ibm-aix"; exit 0
|
echo "${MACHINE}-ibm-aix3"; exit 0
|
||||||
;;
|
;;
|
||||||
|
|
||||||
dgux:*)
|
dgux:*)
|
||||||
@@ -134,7 +135,7 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
|||||||
HPUXVER=`echo ${RELEASE}|sed -e 's/[^.]*.[0B]*//'`
|
HPUXVER=`echo ${RELEASE}|sed -e 's/[^.]*.[0B]*//'`
|
||||||
case "$HPUXVER" in
|
case "$HPUXVER" in
|
||||||
1[0-9].*) # HPUX 10 and 11 targets are unified
|
1[0-9].*) # HPUX 10 and 11 targets are unified
|
||||||
echo "${MACHINE}-hp-hpux10"; exit 0
|
echo "${MACHINE}-hp-hpux1x"; exit 0
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
echo "${MACHINE}-hp-hpux"; exit 0
|
echo "${MACHINE}-hp-hpux"; exit 0
|
||||||
@@ -288,6 +289,14 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
|||||||
echo "${MACHINE}-whatever-sysv4"; exit 0
|
echo "${MACHINE}-whatever-sysv4"; exit 0
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
VOS:*:*:i786)
|
||||||
|
echo "i386-stratus-vos"; exit 0
|
||||||
|
;;
|
||||||
|
|
||||||
|
VOS:*:*:*)
|
||||||
|
echo "hppa1.1-stratus-vos"; exit 0
|
||||||
|
;;
|
||||||
|
|
||||||
*:4*:R4*:m88k)
|
*:4*:R4*:m88k)
|
||||||
echo "${MACHINE}-whatever-sysv4"; exit 0
|
echo "${MACHINE}-whatever-sysv4"; exit 0
|
||||||
;;
|
;;
|
||||||
@@ -328,6 +337,9 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
|||||||
echo "mips-sony-newsos4"; exit 0;
|
echo "mips-sony-newsos4"; exit 0;
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
MINGW*)
|
||||||
|
echo "${MACHINE}-whatever-mingw"; echo 0;
|
||||||
|
;;
|
||||||
CYGWIN*)
|
CYGWIN*)
|
||||||
case "$RELEASE" in
|
case "$RELEASE" in
|
||||||
[bB]*|1.0|1.[12].*)
|
[bB]*|1.0|1.[12].*)
|
||||||
@@ -410,9 +422,10 @@ if [ "$SYSTEM" = "HP-UX" ];then
|
|||||||
GCC_BITS="32"
|
GCC_BITS="32"
|
||||||
if [ $GCCVER -ge 30 ]; then
|
if [ $GCCVER -ge 30 ]; then
|
||||||
# PA64 support only came in with gcc 3.0.x.
|
# PA64 support only came in with gcc 3.0.x.
|
||||||
# We look for the preprocessor symbol __LP64__ indicating
|
# We check if the preprocessor symbol __LP64__ is defined...
|
||||||
# 64bit bit long and pointer. sizeof(int) == 32 on HPUX64.
|
if echo "__LP64__" | gcc -v -E -x c - 2>/dev/null | grep "^__LP64__" 2>&1 > /dev/null; then
|
||||||
if gcc -v -E -x c /dev/null 2>&1 | grep __LP64__ > /dev/null; then
|
: # __LP64__ has slipped through, it therefore is not defined
|
||||||
|
else
|
||||||
GCC_BITS="64"
|
GCC_BITS="64"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
@@ -432,7 +445,7 @@ if [ "$SYSTEM" = "SunOS" ]; then
|
|||||||
egrep -e '^cc: .* C [0-9]\.[0-9]' | \
|
egrep -e '^cc: .* C [0-9]\.[0-9]' | \
|
||||||
sed 's/.* C \([0-9]\)\.\([0-9]\).*/\1\2/'`
|
sed 's/.* C \([0-9]\)\.\([0-9]\).*/\1\2/'`
|
||||||
CCVER=${CCVER:-0}
|
CCVER=${CCVER:-0}
|
||||||
if [ $CCVER -gt 40 ]; then
|
if [ $MACHINE != i86pc -a $CCVER -gt 40 ]; then
|
||||||
CC=cc # overrides gcc!!!
|
CC=cc # overrides gcc!!!
|
||||||
if [ $CCVER -eq 50 ]; then
|
if [ $CCVER -eq 50 ]; then
|
||||||
echo "WARNING! Detected WorkShop C 5.0. Do make sure you have"
|
echo "WARNING! Detected WorkShop C 5.0. Do make sure you have"
|
||||||
@@ -458,7 +471,7 @@ if [ "${SYSTEM}-${MACHINE}" = "Linux-alpha" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "${SYSTEM}" = "AIX" ]; then # favor vendor cc over gcc
|
if [ "${SYSTEM}" = "AIX" ]; then # favor vendor cc over gcc
|
||||||
(cc) 2>&1 | grep -iv "command not found" > /dev/null && CC=cc
|
(cc) 2>&1 | grep -iv "not found" > /dev/null && CC=cc
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CCVER=${CCVER:-0}
|
CCVER=${CCVER:-0}
|
||||||
@@ -473,7 +486,7 @@ echo Operating system: $GUESSOS
|
|||||||
# more time that I want to waste at the moment
|
# more time that I want to waste at the moment
|
||||||
case "$GUESSOS" in
|
case "$GUESSOS" in
|
||||||
mips2-sgi-irix)
|
mips2-sgi-irix)
|
||||||
CPU=`(hinv -t cpu) 2>/dev/null | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
CPU=`(hinv -t cpu) 2>/dev/null | head -1 | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
||||||
CPU=${CPU:-0}
|
CPU=${CPU:-0}
|
||||||
if [ $CPU -ge 4000 ]; then
|
if [ $CPU -ge 4000 ]; then
|
||||||
options="$options -mips2"
|
options="$options -mips2"
|
||||||
@@ -481,29 +494,29 @@ case "$GUESSOS" in
|
|||||||
OUT="irix-$CC"
|
OUT="irix-$CC"
|
||||||
;;
|
;;
|
||||||
mips3-sgi-irix)
|
mips3-sgi-irix)
|
||||||
CPU=`(hinv -t cpu) 2>/dev/null | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
#CPU=`(hinv -t cpu) 2>/dev/null | head -1 | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
||||||
CPU=${CPU:-0}
|
#CPU=${CPU:-0}
|
||||||
if [ $CPU -ge 5000 ]; then
|
#if [ $CPU -ge 5000 ]; then
|
||||||
options="$options -mips4"
|
# options="$options -mips4"
|
||||||
else
|
#else
|
||||||
options="$options -mips3"
|
# options="$options -mips3"
|
||||||
fi
|
#fi
|
||||||
OUT="irix-mips3-$CC"
|
OUT="irix-mips3-$CC"
|
||||||
;;
|
;;
|
||||||
mips4-sgi-irix64)
|
mips4-sgi-irix64)
|
||||||
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
||||||
echo " invoke './Configure irix64-mips4-$CC' *manually*."
|
echo " invoke './Configure irix64-mips4-$CC' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
CPU=`(hinv -t cpu) 2>/dev/null | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
#CPU=`(hinv -t cpu) 2>/dev/null | head -1 | sed 's/^CPU:[^R]*R\([0-9]*\).*/\1/'`
|
||||||
CPU=${CPU:-0}
|
#CPU=${CPU:-0}
|
||||||
if [ $CPU -ge 5000 ]; then
|
#if [ $CPU -ge 5000 ]; then
|
||||||
options="$options -mips4"
|
# options="$options -mips4"
|
||||||
else
|
#else
|
||||||
options="$options -mips3"
|
# options="$options -mips3"
|
||||||
fi
|
#fi
|
||||||
OUT="irix-mips3-$CC"
|
OUT="irix-mips3-$CC"
|
||||||
;;
|
;;
|
||||||
alpha-*-linux2)
|
alpha-*-linux2)
|
||||||
@@ -537,9 +550,14 @@ EOF
|
|||||||
rm dummy dummy.c
|
rm dummy dummy.c
|
||||||
;;
|
;;
|
||||||
ppc64-*-linux2)
|
ppc64-*-linux2)
|
||||||
#Use the standard target for PPC architecture until we create a
|
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
||||||
#special one for the 64bit architecture.
|
echo " invoke './Configure linux-ppc64' *manually*."
|
||||||
OUT="linux-ppc" ;;
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
|
fi
|
||||||
|
OUT="linux-ppc"
|
||||||
|
;;
|
||||||
ppc-*-linux2) OUT="linux-ppc" ;;
|
ppc-*-linux2) OUT="linux-ppc" ;;
|
||||||
m68k-*-linux*) OUT="linux-m68k" ;;
|
m68k-*-linux*) OUT="linux-m68k" ;;
|
||||||
ia64-*-linux?) OUT="linux-ia64" ;;
|
ia64-*-linux?) OUT="linux-ia64" ;;
|
||||||
@@ -550,9 +568,9 @@ EOF
|
|||||||
echo "WARNING! If you *know* that your GNU C supports 64-bit/V9 ABI"
|
echo "WARNING! If you *know* that your GNU C supports 64-bit/V9 ABI"
|
||||||
echo " and wish to build 64-bit library, then you have to"
|
echo " and wish to build 64-bit library, then you have to"
|
||||||
echo " invoke './Configure linux64-sparcv9' *manually*."
|
echo " invoke './Configure linux64-sparcv9' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
OUT="linux-sparcv9" ;;
|
OUT="linux-sparcv9" ;;
|
||||||
sparc-*-linux2)
|
sparc-*-linux2)
|
||||||
@@ -583,7 +601,9 @@ EOF
|
|||||||
|
|
||||||
options="$options -mschedule=$CPUSCHEDULE -march=$CPUARCH"
|
options="$options -mschedule=$CPUSCHEDULE -march=$CPUARCH"
|
||||||
OUT="linux-parisc" ;;
|
OUT="linux-parisc" ;;
|
||||||
arm*-*-linux2) OUT="linux-elf-arm" ;;
|
arm*b-*-linux2) OUT="linux-elf-arm"; options="$options -DB_ENDIAN" ;;
|
||||||
|
arm*l-*-linux2) OUT="linux-elf-arm"; options="$options -DL_ENDIAN" ;;
|
||||||
|
arm*-*-linux2) OUT="linux-elf-arm" ;;
|
||||||
s390-*-linux2) OUT="linux-s390" ;;
|
s390-*-linux2) OUT="linux-s390" ;;
|
||||||
s390x-*-linux?) OUT="linux-s390x" ;;
|
s390x-*-linux?) OUT="linux-s390x" ;;
|
||||||
x86_64-*-linux?) OUT="linux-x86_64" ;;
|
x86_64-*-linux?) OUT="linux-x86_64" ;;
|
||||||
@@ -607,9 +627,9 @@ EOF
|
|||||||
if [ "$CC" = "cc" -a $CCVER -ge 50 ]; then
|
if [ "$CC" = "cc" -a $CCVER -ge 50 ]; then
|
||||||
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
echo "WARNING! If you wish to build 64-bit library, then you have to"
|
||||||
echo " invoke './Configure solaris64-sparcv9-cc' *manually*."
|
echo " invoke './Configure solaris64-sparcv9-cc' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
elif [ "$CC" = "gcc" -a "$GCC_ARCH" = "-m64" ]; then
|
elif [ "$CC" = "gcc" -a "$GCC_ARCH" = "-m64" ]; then
|
||||||
# $GCC_ARCH denotes default ABI chosen by compiler driver
|
# $GCC_ARCH denotes default ABI chosen by compiler driver
|
||||||
@@ -619,17 +639,17 @@ EOF
|
|||||||
OUT="solaris64-sparcv9-gcc"
|
OUT="solaris64-sparcv9-gcc"
|
||||||
echo "WARNING! If you wish to build 32-bit library, then you have to"
|
echo "WARNING! If you wish to build 32-bit library, then you have to"
|
||||||
echo " invoke './Configure solaris-sparcv9-gcc' *manually*."
|
echo " invoke './Configure solaris-sparcv9-gcc' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
elif [ "$GCC_ARCH" = "-m32" ]; then
|
elif [ "$GCC_ARCH" = "-m32" ]; then
|
||||||
echo "NOTICE! If you *know* that your GNU C supports 64-bit/V9 ABI"
|
echo "NOTICE! If you *know* that your GNU C supports 64-bit/V9 ABI"
|
||||||
echo " and wish to build 64-bit library, then you have to"
|
echo " and wish to build 64-bit library, then you have to"
|
||||||
echo " invoke './Configure solaris64-sparcv9-gcc' *manually*."
|
echo " invoke './Configure solaris64-sparcv9-gcc' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
@@ -637,7 +657,14 @@ EOF
|
|||||||
sun4m-*-solaris2) OUT="solaris-sparcv8-$CC" ;;
|
sun4m-*-solaris2) OUT="solaris-sparcv8-$CC" ;;
|
||||||
sun4d-*-solaris2) OUT="solaris-sparcv8-$CC" ;;
|
sun4d-*-solaris2) OUT="solaris-sparcv8-$CC" ;;
|
||||||
sun4*-*-solaris2) OUT="solaris-sparcv7-$CC" ;;
|
sun4*-*-solaris2) OUT="solaris-sparcv7-$CC" ;;
|
||||||
*86*-*-solaris2) OUT="solaris-x86-$CC" ;;
|
*86*-*-solaris2)
|
||||||
|
ISA64=`(isalist) 2>/dev/null | grep amd64`
|
||||||
|
if [ "$ISA64" != "" ]; then
|
||||||
|
OUT="solaris64-x86_64-$CC"
|
||||||
|
else
|
||||||
|
OUT="solaris-x86-$CC"
|
||||||
|
fi
|
||||||
|
;;
|
||||||
*-*-sunos4) OUT="sunos-$CC" ;;
|
*-*-sunos4) OUT="sunos-$CC" ;;
|
||||||
alpha*-*-freebsd*) OUT="FreeBSD-alpha" ;;
|
alpha*-*-freebsd*) OUT="FreeBSD-alpha" ;;
|
||||||
sparc64-*-freebsd*) OUT="FreeBSD-sparc64" ;;
|
sparc64-*-freebsd*) OUT="FreeBSD-sparc64" ;;
|
||||||
@@ -678,6 +705,10 @@ EOF
|
|||||||
*-*-UnixWare21*) OUT="unixware-2.1" ;;
|
*-*-UnixWare21*) OUT="unixware-2.1" ;;
|
||||||
*-*-Unixware20*) OUT="unixware-2.0" ;;
|
*-*-Unixware20*) OUT="unixware-2.0" ;;
|
||||||
*-*-Unixware21*) OUT="unixware-2.1" ;;
|
*-*-Unixware21*) OUT="unixware-2.1" ;;
|
||||||
|
*-*-vos)
|
||||||
|
options="$options no-threads no-shared no-asm no-dso"
|
||||||
|
EXE=".pm"
|
||||||
|
OUT="vos-$CC" ;;
|
||||||
BS2000-siemens-sysv4) OUT="BS2000-OSD" ;;
|
BS2000-siemens-sysv4) OUT="BS2000-OSD" ;;
|
||||||
RM*-siemens-sysv4) OUT="ReliantUNIX" ;;
|
RM*-siemens-sysv4) OUT="ReliantUNIX" ;;
|
||||||
*-siemens-sysv4) OUT="SINIX" ;;
|
*-siemens-sysv4) OUT="SINIX" ;;
|
||||||
@@ -685,7 +716,7 @@ EOF
|
|||||||
if [ $CC = "gcc" ];
|
if [ $CC = "gcc" ];
|
||||||
then
|
then
|
||||||
if [ $GCC_BITS = "64" ]; then
|
if [ $GCC_BITS = "64" ]; then
|
||||||
OUT="hpux64-parisc-gcc"
|
OUT="hpux64-parisc2-gcc"
|
||||||
else
|
else
|
||||||
OUT="hpux-parisc-gcc"
|
OUT="hpux-parisc-gcc"
|
||||||
fi
|
fi
|
||||||
@@ -700,10 +731,10 @@ EOF
|
|||||||
if [ $CPU_VERSION -ge 768 ]; then # IA-64 CPU
|
if [ $CPU_VERSION -ge 768 ]; then # IA-64 CPU
|
||||||
echo "WARNING! 64-bit ABI is the default configured ABI on HP-UXi."
|
echo "WARNING! 64-bit ABI is the default configured ABI on HP-UXi."
|
||||||
echo " If you wish to build 32-bit library, the you have to"
|
echo " If you wish to build 32-bit library, the you have to"
|
||||||
echo " invoke './Configure hpux-ia32-cc' *manually*."
|
echo " invoke './Configure hpux-ia64-cc' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
OUT="hpux64-ia64-cc"
|
OUT="hpux64-ia64-cc"
|
||||||
elif [ $CPU_VERSION -ge 532 ]; then # PA-RISC 2.x CPU
|
elif [ $CPU_VERSION -ge 532 ]; then # PA-RISC 2.x CPU
|
||||||
@@ -713,9 +744,9 @@ EOF
|
|||||||
if [ $KERNEL_BITS -eq 64 -a "$CC" = "cc" ]; then
|
if [ $KERNEL_BITS -eq 64 -a "$CC" = "cc" ]; then
|
||||||
echo "WARNING! If you wish to build 64-bit library then you have to"
|
echo "WARNING! If you wish to build 64-bit library then you have to"
|
||||||
echo " invoke './Configure hpux64-parisc2-cc' *manually*."
|
echo " invoke './Configure hpux64-parisc2-cc' *manually*."
|
||||||
if [ "$TEST" = "false" ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
echo " You have about 5 seconds to press Ctrl-C to abort."
|
||||||
(stty -icanon min 0 time 50; read waste) < /dev/tty
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
elif [ $CPU_VERSION -ge 528 ]; then # PA-RISC 1.1+ CPU
|
elif [ $CPU_VERSION -ge 528 ]; then # PA-RISC 1.1+ CPU
|
||||||
@@ -727,8 +758,28 @@ EOF
|
|||||||
fi
|
fi
|
||||||
options="$options -D_REENTRANT" ;;
|
options="$options -D_REENTRANT" ;;
|
||||||
*-hpux) OUT="hpux-parisc-$CC" ;;
|
*-hpux) OUT="hpux-parisc-$CC" ;;
|
||||||
|
*-aix)
|
||||||
|
KERNEL_BITS=`(getconf KERNEL_BITMODE) 2>/dev/null`
|
||||||
|
KERNEL_BITS=${KERNEL_BITS:-32}
|
||||||
|
OBJECT_MODE=${OBJECT_MODE:-32}
|
||||||
|
if [ "$CC" = "gcc" ]; then
|
||||||
|
OUT="aix-gcc"
|
||||||
|
elif [ $OBJECT_MODE -eq 64 ]; then
|
||||||
|
echo 'Your $OBJECT_MODE was found to be set to 64'
|
||||||
|
OUT="aix64-cc"
|
||||||
|
else
|
||||||
|
OUT="aix-cc"
|
||||||
|
if [ $KERNEL_BITS -eq 64 ]; then
|
||||||
|
echo "WARNING! If you wish to build 64-bit kit, then you have to"
|
||||||
|
echo " invoke './Configure aix64-cc' *manually*."
|
||||||
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
|
echo " You have ~5 seconds to press Ctrl-C to abort."
|
||||||
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
;;
|
||||||
# these are all covered by the catchall below
|
# these are all covered by the catchall below
|
||||||
# *-aix) OUT="aix-$CC" ;;
|
|
||||||
# *-dgux) OUT="dgux" ;;
|
# *-dgux) OUT="dgux" ;;
|
||||||
mips-sony-newsos4) OUT="newsos4-gcc" ;;
|
mips-sony-newsos4) OUT="newsos4-gcc" ;;
|
||||||
*-*-cygwin_pre1.3) OUT="Cygwin-pre1.3" ;;
|
*-*-cygwin_pre1.3) OUT="Cygwin-pre1.3" ;;
|
||||||
@@ -805,8 +856,8 @@ fi
|
|||||||
|
|
||||||
if [ ".$PERL" = . ] ; then
|
if [ ".$PERL" = . ] ; then
|
||||||
for i in . `echo $PATH | sed 's/:/ /g'`; do
|
for i in . `echo $PATH | sed 's/:/ /g'`; do
|
||||||
if [ -f "$i/perl5" ] ; then
|
if [ -f "$i/perl5$EXE" ] ; then
|
||||||
PERL="$i/perl5"
|
PERL="$i/perl5$EXE"
|
||||||
break;
|
break;
|
||||||
fi;
|
fi;
|
||||||
done
|
done
|
||||||
@@ -814,9 +865,9 @@ fi
|
|||||||
|
|
||||||
if [ ".$PERL" = . ] ; then
|
if [ ".$PERL" = . ] ; then
|
||||||
for i in . `echo $PATH | sed 's/:/ /g'`; do
|
for i in . `echo $PATH | sed 's/:/ /g'`; do
|
||||||
if [ -f "$i/perl" ] ; then
|
if [ -f "$i/perl$EXE" ] ; then
|
||||||
if "$i/perl" -e 'exit($]<5.0)'; then
|
if "$i/perl$EXE" -e 'exit($]<5.0)'; then
|
||||||
PERL="$i/perl"
|
PERL="$i/perl$EXE"
|
||||||
break;
|
break;
|
||||||
fi;
|
fi;
|
||||||
fi;
|
fi;
|
||||||
|
|||||||
@@ -2,3 +2,5 @@ lib
|
|||||||
buildinf.h
|
buildinf.h
|
||||||
opensslconf.h
|
opensslconf.h
|
||||||
Makefile.save
|
Makefile.save
|
||||||
|
*.flc
|
||||||
|
semantic.cache
|
||||||
|
|||||||
@@ -11,10 +11,9 @@ CFLAG= -g
|
|||||||
INSTALL_PREFIX=
|
INSTALL_PREFIX=
|
||||||
OPENSSLDIR= /usr/local/ssl
|
OPENSSLDIR= /usr/local/ssl
|
||||||
INSTALLTOP= /usr/local/ssl
|
INSTALLTOP= /usr/local/ssl
|
||||||
MAKE= make -f Makefile.ssl
|
|
||||||
MAKEDEPPROG= makedepend
|
MAKEDEPPROG= makedepend
|
||||||
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
||||||
MAKEFILE= Makefile.ssl
|
MAKEFILE= Makefile
|
||||||
RM= rm -f
|
RM= rm -f
|
||||||
AR= ar r
|
AR= ar r
|
||||||
|
|
||||||
@@ -36,25 +35,25 @@ GENERAL=Makefile README crypto-lib.com install.com
|
|||||||
|
|
||||||
LIB= $(TOP)/libcrypto.a
|
LIB= $(TOP)/libcrypto.a
|
||||||
SHARED_LIB= libcrypto$(SHLIB_EXT)
|
SHARED_LIB= libcrypto$(SHLIB_EXT)
|
||||||
LIBSRC= cryptlib.c mem.c mem_clr.c mem_dbg.c cversion.c ex_data.c tmdiff.c cpt_err.c ebcdic.c uid.c o_time.c
|
LIBSRC= cryptlib.c mem.c mem_clr.c mem_dbg.c cversion.c ex_data.c tmdiff.c cpt_err.c ebcdic.c uid.c o_time.c o_str.c
|
||||||
LIBOBJ= cryptlib.o mem.o mem_clr.o mem_dbg.o cversion.o ex_data.o tmdiff.o cpt_err.o ebcdic.o uid.o o_time.o
|
LIBOBJ= cryptlib.o mem.o mem_clr.o mem_dbg.o cversion.o ex_data.o tmdiff.o cpt_err.o ebcdic.o uid.o o_time.o o_str.o
|
||||||
|
|
||||||
SRC= $(LIBSRC)
|
SRC= $(LIBSRC)
|
||||||
|
|
||||||
EXHEADER= crypto.h tmdiff.h opensslv.h opensslconf.h ebcdic.h symhacks.h \
|
EXHEADER= crypto.h tmdiff.h opensslv.h opensslconf.h ebcdic.h symhacks.h \
|
||||||
ossl_typ.h
|
ossl_typ.h
|
||||||
HEADER= cryptlib.h buildinf.h md32_common.h o_time.h $(EXHEADER)
|
HEADER= cryptlib.h buildinf.h md32_common.h o_time.h o_str.h $(EXHEADER)
|
||||||
|
|
||||||
ALL= $(GENERAL) $(SRC) $(HEADER)
|
ALL= $(GENERAL) $(SRC) $(HEADER)
|
||||||
|
|
||||||
top:
|
top:
|
||||||
@(cd ..; $(MAKE) DIRS=$(DIR) all)
|
@(cd ..; $(MAKE) DIRS=$(DIR) all)
|
||||||
|
|
||||||
all: buildinf.h lib subdirs shared
|
all: shared
|
||||||
|
|
||||||
buildinf.h: ../Makefile.ssl
|
buildinf.h: ../Makefile
|
||||||
( echo "#ifndef MK1MF_BUILD"; \
|
( echo "#ifndef MK1MF_BUILD"; \
|
||||||
echo ' /* auto-generated by crypto/Makefile.ssl for crypto/cversion.c */'; \
|
echo ' /* auto-generated by crypto/Makefile for crypto/cversion.c */'; \
|
||||||
echo ' #define CFLAGS "$(CC) $(CFLAG)"'; \
|
echo ' #define CFLAGS "$(CC) $(CFLAG)"'; \
|
||||||
echo ' #define PLATFORM "$(PLATFORM)"'; \
|
echo ' #define PLATFORM "$(PLATFORM)"'; \
|
||||||
echo " #define DATE \"`LC_ALL=C LC_TIME=C date`\""; \
|
echo " #define DATE \"`LC_ALL=C LC_TIME=C date`\""; \
|
||||||
@@ -73,7 +72,7 @@ subdirs:
|
|||||||
done;
|
done;
|
||||||
|
|
||||||
files:
|
files:
|
||||||
$(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
|
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
|
||||||
@for i in $(SDIRS) ;\
|
@for i in $(SDIRS) ;\
|
||||||
do \
|
do \
|
||||||
(cd $$i && echo "making 'files' in crypto/$$i..." && \
|
(cd $$i && echo "making 'files' in crypto/$$i..." && \
|
||||||
@@ -81,11 +80,9 @@ files:
|
|||||||
done;
|
done;
|
||||||
|
|
||||||
links:
|
links:
|
||||||
@$(TOP)/util/point.sh Makefile.ssl Makefile
|
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../include/openssl $(EXHEADER)
|
@$(PERL) $(TOP)/util/mklink.pl ../include/openssl $(EXHEADER)
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../test $(TEST)
|
@$(PERL) $(TOP)/util/mklink.pl ../test $(TEST)
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../apps $(APPS)
|
@$(PERL) $(TOP)/util/mklink.pl ../apps $(APPS)
|
||||||
@$(TOP)/util/point.sh Makefile.ssl Makefile
|
|
||||||
@for i in $(SDIRS); do \
|
@for i in $(SDIRS); do \
|
||||||
(cd $$i && echo "making links in crypto/$$i..." && \
|
(cd $$i && echo "making links in crypto/$$i..." && \
|
||||||
$(MAKE) CC='$(CC)' INCLUDES='${INCLUDES}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' AR='${AR}' PERL='${PERL}' links ); \
|
$(MAKE) CC='$(CC)' INCLUDES='${INCLUDES}' CFLAG='${CFLAG}' INSTALLTOP='${INSTALLTOP}' PEX_LIBS='${PEX_LIBS}' EX_LIBS='${EX_LIBS}' BN_ASM='${BN_ASM}' DES_ENC='${DES_ENC}' SHA1_ASM_OBJ='${SHA1_ASM_OBJ}' MD5_ASM_OBJ='${MD5_ASM_OBJ}' RMD160_ASM_OBJ='${RMD160_ASM_OBJ}' BF_ENC='${BF_ENC}' CAST_ENC='${CAST_ENC}' RC4_ENC='${RC4_ENC}' RC5_ENC='${RC5_ENC}' AR='${AR}' PERL='${PERL}' links ); \
|
||||||
@@ -96,8 +93,9 @@ lib: $(LIBOBJ)
|
|||||||
$(RANLIB) $(LIB) || echo Never mind.
|
$(RANLIB) $(LIB) || echo Never mind.
|
||||||
@touch lib
|
@touch lib
|
||||||
|
|
||||||
shared:
|
shared: buildinf.h lib subdirs
|
||||||
if [ -n "$(SHARED_LIBS)" ]; then \
|
@if [ -n "$(SHARED_LIBS)" ]; then \
|
||||||
|
egrep 'define OPENSSL_FIPS' $(TOP)/include/openssl/opensslconf.h > /dev/null || \
|
||||||
(cd ..; $(MAKE) $(SHARED_LIB)); \
|
(cd ..; $(MAKE) $(SHARED_LIB)); \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -116,7 +114,7 @@ tests:
|
|||||||
done;
|
done;
|
||||||
|
|
||||||
install:
|
install:
|
||||||
@for i in $(EXHEADER) ;\
|
@headerlist="$(EXHEADER)"; for i in $$headerlist ;\
|
||||||
do \
|
do \
|
||||||
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
||||||
@@ -203,6 +201,8 @@ mem_dbg.o: ../include/openssl/err.h ../include/openssl/lhash.h
|
|||||||
mem_dbg.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
mem_dbg.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
mem_dbg.o: ../include/openssl/safestack.h ../include/openssl/stack.h
|
mem_dbg.o: ../include/openssl/safestack.h ../include/openssl/stack.h
|
||||||
mem_dbg.o: ../include/openssl/symhacks.h cryptlib.h mem_dbg.c
|
mem_dbg.o: ../include/openssl/symhacks.h cryptlib.h mem_dbg.c
|
||||||
|
o_str.o: ../e_os.h ../include/openssl/e_os2.h ../include/openssl/opensslconf.h
|
||||||
|
o_str.o: o_str.c o_str.h
|
||||||
o_time.o: ../include/openssl/e_os2.h ../include/openssl/opensslconf.h o_time.c
|
o_time.o: ../include/openssl/e_os2.h ../include/openssl/opensslconf.h o_time.c
|
||||||
o_time.o: o_time.h
|
o_time.o: o_time.h
|
||||||
tmdiff.o: ../e_os.h ../include/openssl/bio.h ../include/openssl/buffer.h
|
tmdiff.o: ../e_os.h ../include/openssl/bio.h ../include/openssl/buffer.h
|
||||||
@@ -1,2 +1,4 @@
|
|||||||
lib
|
lib
|
||||||
Makefile.save
|
Makefile.save
|
||||||
|
*.flc
|
||||||
|
semantic.cache
|
||||||
|
|||||||
@@ -11,10 +11,9 @@ CFLAG=-g
|
|||||||
INSTALL_PREFIX=
|
INSTALL_PREFIX=
|
||||||
OPENSSLDIR= /usr/local/ssl
|
OPENSSLDIR= /usr/local/ssl
|
||||||
INSTALLTOP= /usr/local/ssl
|
INSTALLTOP= /usr/local/ssl
|
||||||
MAKE= make -f Makefile.ssl
|
|
||||||
MAKEDEPPROG= makedepend
|
MAKEDEPPROG= makedepend
|
||||||
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
||||||
MAKEFILE= Makefile.ssl
|
MAKEFILE= Makefile
|
||||||
AR= ar r
|
AR= ar r
|
||||||
|
|
||||||
# CFLAGS= -mpentiumpro $(INCLUDES) $(CFLAG) -O3 -fexpensive-optimizations -funroll-loops -fforce-addr
|
# CFLAGS= -mpentiumpro $(INCLUDES) $(CFLAG) -O3 -fexpensive-optimizations -funroll-loops -fforce-addr
|
||||||
@@ -49,10 +48,9 @@ lib: $(LIBOBJ)
|
|||||||
$(LIBOBJ): $(LIBSRC)
|
$(LIBOBJ): $(LIBSRC)
|
||||||
|
|
||||||
files:
|
files:
|
||||||
$(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
|
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
|
||||||
|
|
||||||
links:
|
links:
|
||||||
@$(TOP)/util/point.sh Makefile.ssl Makefile
|
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
|
@$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
|
@$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
|
@$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
|
||||||
@@ -60,7 +58,7 @@ links:
|
|||||||
install: installs
|
install: installs
|
||||||
|
|
||||||
installs:
|
installs:
|
||||||
@for i in $(EXHEADER) ; \
|
@headerlist="$(EXHEADER)"; for i in $$headerlist ; \
|
||||||
do \
|
do \
|
||||||
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
||||||
@@ -88,10 +86,12 @@ clean:
|
|||||||
|
|
||||||
aes_cbc.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
aes_cbc.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
||||||
aes_cbc.o: ../../include/openssl/opensslconf.h aes_cbc.c aes_locl.h
|
aes_cbc.o: ../../include/openssl/opensslconf.h aes_cbc.c aes_locl.h
|
||||||
aes_cfb.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
aes_cfb.o: ../../e_os.h ../../include/openssl/aes.h
|
||||||
aes_cfb.o: ../../include/openssl/opensslconf.h aes_cfb.c aes_locl.h
|
aes_cfb.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
|
||||||
|
aes_cfb.o: aes_cfb.c aes_locl.h
|
||||||
aes_core.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
aes_core.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
||||||
aes_core.o: ../../include/openssl/opensslconf.h aes_core.c aes_locl.h
|
aes_core.o: ../../include/openssl/fips.h ../../include/openssl/opensslconf.h
|
||||||
|
aes_core.o: aes_core.c aes_locl.h
|
||||||
aes_ctr.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
aes_ctr.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
||||||
aes_ctr.o: ../../include/openssl/opensslconf.h aes_ctr.c aes_locl.h
|
aes_ctr.o: ../../include/openssl/opensslconf.h aes_ctr.c aes_locl.h
|
||||||
aes_ecb.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
aes_ecb.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
||||||
@@ -52,6 +52,8 @@
|
|||||||
#ifndef HEADER_AES_H
|
#ifndef HEADER_AES_H
|
||||||
#define HEADER_AES_H
|
#define HEADER_AES_H
|
||||||
|
|
||||||
|
#include <openssl/e_os2.h>
|
||||||
|
|
||||||
#ifdef OPENSSL_NO_AES
|
#ifdef OPENSSL_NO_AES
|
||||||
#error AES is disabled.
|
#error AES is disabled.
|
||||||
#endif
|
#endif
|
||||||
@@ -64,6 +66,10 @@
|
|||||||
#define AES_MAXNR 14
|
#define AES_MAXNR 14
|
||||||
#define AES_BLOCK_SIZE 16
|
#define AES_BLOCK_SIZE 16
|
||||||
|
|
||||||
|
#if defined(OPENSSL_FIPS)
|
||||||
|
#define FIPS_AES_SIZE_T int
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
@@ -95,12 +101,21 @@ void AES_cbc_encrypt(const unsigned char *in, unsigned char *out,
|
|||||||
void AES_cfb128_encrypt(const unsigned char *in, unsigned char *out,
|
void AES_cfb128_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
const unsigned long length, const AES_KEY *key,
|
const unsigned long length, const AES_KEY *key,
|
||||||
unsigned char *ivec, int *num, const int enc);
|
unsigned char *ivec, int *num, const int enc);
|
||||||
|
void AES_cfb1_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
|
const unsigned long length, const AES_KEY *key,
|
||||||
|
unsigned char *ivec, int *num, const int enc);
|
||||||
|
void AES_cfb8_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
|
const unsigned long length, const AES_KEY *key,
|
||||||
|
unsigned char *ivec, int *num, const int enc);
|
||||||
|
void AES_cfbr_encrypt_block(const unsigned char *in,unsigned char *out,
|
||||||
|
const int nbits,const AES_KEY *key,
|
||||||
|
unsigned char *ivec,const int enc);
|
||||||
void AES_ofb128_encrypt(const unsigned char *in, unsigned char *out,
|
void AES_ofb128_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
const unsigned long length, const AES_KEY *key,
|
const unsigned long length, const AES_KEY *key,
|
||||||
unsigned char *ivec, int *num);
|
unsigned char *ivec, int *num);
|
||||||
void AES_ctr128_encrypt(const unsigned char *in, unsigned char *out,
|
void AES_ctr128_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
const unsigned long length, const AES_KEY *key,
|
const unsigned long length, const AES_KEY *key,
|
||||||
unsigned char counter[AES_BLOCK_SIZE],
|
unsigned char ivec[AES_BLOCK_SIZE],
|
||||||
unsigned char ecount_buf[AES_BLOCK_SIZE],
|
unsigned char ecount_buf[AES_BLOCK_SIZE],
|
||||||
unsigned int *num);
|
unsigned int *num);
|
||||||
|
|
||||||
|
|||||||
@@ -59,6 +59,7 @@
|
|||||||
#include <openssl/aes.h>
|
#include <openssl/aes.h>
|
||||||
#include "aes_locl.h"
|
#include "aes_locl.h"
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_FIPS_AES_ASM)
|
||||||
void AES_cbc_encrypt(const unsigned char *in, unsigned char *out,
|
void AES_cbc_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
const unsigned long length, const AES_KEY *key,
|
const unsigned long length, const AES_KEY *key,
|
||||||
unsigned char *ivec, const int enc) {
|
unsigned char *ivec, const int enc) {
|
||||||
@@ -66,32 +67,50 @@ void AES_cbc_encrypt(const unsigned char *in, unsigned char *out,
|
|||||||
unsigned long n;
|
unsigned long n;
|
||||||
unsigned long len = length;
|
unsigned long len = length;
|
||||||
unsigned char tmp[AES_BLOCK_SIZE];
|
unsigned char tmp[AES_BLOCK_SIZE];
|
||||||
|
const unsigned char *iv = ivec;
|
||||||
|
|
||||||
assert(in && out && key && ivec);
|
assert(in && out && key && ivec);
|
||||||
assert((AES_ENCRYPT == enc)||(AES_DECRYPT == enc));
|
assert((AES_ENCRYPT == enc)||(AES_DECRYPT == enc));
|
||||||
|
|
||||||
if (AES_ENCRYPT == enc) {
|
if (AES_ENCRYPT == enc) {
|
||||||
while (len >= AES_BLOCK_SIZE) {
|
while (len >= AES_BLOCK_SIZE) {
|
||||||
for(n=0; n < sizeof tmp; ++n)
|
for(n=0; n < AES_BLOCK_SIZE; ++n)
|
||||||
tmp[n] = in[n] ^ ivec[n];
|
out[n] = in[n] ^ iv[n];
|
||||||
AES_encrypt(tmp, out, key);
|
AES_encrypt(out, out, key);
|
||||||
memcpy(ivec, out, AES_BLOCK_SIZE);
|
iv = out;
|
||||||
len -= AES_BLOCK_SIZE;
|
len -= AES_BLOCK_SIZE;
|
||||||
in += AES_BLOCK_SIZE;
|
in += AES_BLOCK_SIZE;
|
||||||
out += AES_BLOCK_SIZE;
|
out += AES_BLOCK_SIZE;
|
||||||
}
|
}
|
||||||
if (len) {
|
if (len) {
|
||||||
for(n=0; n < len; ++n)
|
for(n=0; n < len; ++n)
|
||||||
tmp[n] = in[n] ^ ivec[n];
|
out[n] = in[n] ^ iv[n];
|
||||||
for(n=len; n < AES_BLOCK_SIZE; ++n)
|
for(n=len; n < AES_BLOCK_SIZE; ++n)
|
||||||
tmp[n] = ivec[n];
|
out[n] = iv[n];
|
||||||
AES_encrypt(tmp, tmp, key);
|
AES_encrypt(out, out, key);
|
||||||
memcpy(out, tmp, len);
|
iv = out;
|
||||||
memcpy(ivec, tmp, sizeof tmp);
|
|
||||||
}
|
}
|
||||||
|
memcpy(ivec,iv,AES_BLOCK_SIZE);
|
||||||
|
} else if (in != out) {
|
||||||
|
while (len >= AES_BLOCK_SIZE) {
|
||||||
|
AES_decrypt(in, out, key);
|
||||||
|
for(n=0; n < AES_BLOCK_SIZE; ++n)
|
||||||
|
out[n] ^= iv[n];
|
||||||
|
iv = in;
|
||||||
|
len -= AES_BLOCK_SIZE;
|
||||||
|
in += AES_BLOCK_SIZE;
|
||||||
|
out += AES_BLOCK_SIZE;
|
||||||
|
}
|
||||||
|
if (len) {
|
||||||
|
AES_decrypt(in,tmp,key);
|
||||||
|
for(n=0; n < len; ++n)
|
||||||
|
out[n] = tmp[n] ^ iv[n];
|
||||||
|
iv = in;
|
||||||
|
}
|
||||||
|
memcpy(ivec,iv,AES_BLOCK_SIZE);
|
||||||
} else {
|
} else {
|
||||||
while (len >= AES_BLOCK_SIZE) {
|
while (len >= AES_BLOCK_SIZE) {
|
||||||
memcpy(tmp, in, sizeof tmp);
|
memcpy(tmp, in, AES_BLOCK_SIZE);
|
||||||
AES_decrypt(in, out, key);
|
AES_decrypt(in, out, key);
|
||||||
for(n=0; n < AES_BLOCK_SIZE; ++n)
|
for(n=0; n < AES_BLOCK_SIZE; ++n)
|
||||||
out[n] ^= ivec[n];
|
out[n] ^= ivec[n];
|
||||||
@@ -101,11 +120,14 @@ void AES_cbc_encrypt(const unsigned char *in, unsigned char *out,
|
|||||||
out += AES_BLOCK_SIZE;
|
out += AES_BLOCK_SIZE;
|
||||||
}
|
}
|
||||||
if (len) {
|
if (len) {
|
||||||
memcpy(tmp, in, sizeof tmp);
|
memcpy(tmp, in, AES_BLOCK_SIZE);
|
||||||
AES_decrypt(tmp, tmp, key);
|
AES_decrypt(tmp, out, key);
|
||||||
for(n=0; n < len; ++n)
|
for(n=0; n < len; ++n)
|
||||||
out[n] ^= ivec[n];
|
out[n] ^= ivec[n];
|
||||||
memcpy(ivec, tmp, sizeof tmp);
|
for(n=len; n < AES_BLOCK_SIZE; ++n)
|
||||||
|
out[n] = tmp[n];
|
||||||
|
memcpy(ivec, tmp, AES_BLOCK_SIZE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|||||||
@@ -114,6 +114,7 @@
|
|||||||
|
|
||||||
#include <openssl/aes.h>
|
#include <openssl/aes.h>
|
||||||
#include "aes_locl.h"
|
#include "aes_locl.h"
|
||||||
|
#include "e_os.h"
|
||||||
|
|
||||||
/* The input and output encrypted as though 128bit cfb mode is being
|
/* The input and output encrypted as though 128bit cfb mode is being
|
||||||
* used. The extra state information to record how much of the
|
* used. The extra state information to record how much of the
|
||||||
@@ -155,3 +156,70 @@ void AES_cfb128_encrypt(const unsigned char *in, unsigned char *out,
|
|||||||
*num=n;
|
*num=n;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* This expects a single block of size nbits for both in and out. Note that
|
||||||
|
it corrupts any extra bits in the last byte of out */
|
||||||
|
void AES_cfbr_encrypt_block(const unsigned char *in,unsigned char *out,
|
||||||
|
const int nbits,const AES_KEY *key,
|
||||||
|
unsigned char *ivec,const int enc)
|
||||||
|
{
|
||||||
|
int n,rem,num;
|
||||||
|
unsigned char ovec[AES_BLOCK_SIZE*2];
|
||||||
|
|
||||||
|
if (nbits<=0 || nbits>128) return;
|
||||||
|
|
||||||
|
/* fill in the first half of the new IV with the current IV */
|
||||||
|
memcpy(ovec,ivec,AES_BLOCK_SIZE);
|
||||||
|
/* construct the new IV */
|
||||||
|
AES_encrypt(ivec,ivec,key);
|
||||||
|
num = (nbits+7)/8;
|
||||||
|
if (enc) /* encrypt the input */
|
||||||
|
for(n=0 ; n < num ; ++n)
|
||||||
|
out[n] = (ovec[AES_BLOCK_SIZE+n] = in[n] ^ ivec[n]);
|
||||||
|
else /* decrypt the input */
|
||||||
|
for(n=0 ; n < num ; ++n)
|
||||||
|
out[n] = (ovec[AES_BLOCK_SIZE+n] = in[n]) ^ ivec[n];
|
||||||
|
/* shift ovec left... */
|
||||||
|
rem = nbits%8;
|
||||||
|
num = nbits/8;
|
||||||
|
if(rem==0)
|
||||||
|
memcpy(ivec,ovec+num,AES_BLOCK_SIZE);
|
||||||
|
else
|
||||||
|
for(n=0 ; n < AES_BLOCK_SIZE ; ++n)
|
||||||
|
ivec[n] = ovec[n+num]<<rem | ovec[n+num+1]>>(8-rem);
|
||||||
|
|
||||||
|
/* it is not necessary to cleanse ovec, since the IV is not secret */
|
||||||
|
}
|
||||||
|
|
||||||
|
/* N.B. This expects the input to be packed, MS bit first */
|
||||||
|
void AES_cfb1_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
|
const unsigned long length, const AES_KEY *key,
|
||||||
|
unsigned char *ivec, int *num, const int enc)
|
||||||
|
{
|
||||||
|
unsigned int n;
|
||||||
|
unsigned char c[1],d[1];
|
||||||
|
|
||||||
|
assert(in && out && key && ivec && num);
|
||||||
|
assert(*num == 0);
|
||||||
|
|
||||||
|
memset(out,0,(length+7)/8);
|
||||||
|
for(n=0 ; n < length ; ++n)
|
||||||
|
{
|
||||||
|
c[0]=(in[n/8]&(1 << (7-n%8))) ? 0x80 : 0;
|
||||||
|
AES_cfbr_encrypt_block(c,d,1,key,ivec,enc);
|
||||||
|
out[n/8]=(out[n/8]&~(1 << (7-n%8)))|((d[0]&0x80) >> (n%8));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void AES_cfb8_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
|
const unsigned long length, const AES_KEY *key,
|
||||||
|
unsigned char *ivec, int *num, const int enc)
|
||||||
|
{
|
||||||
|
unsigned int n;
|
||||||
|
|
||||||
|
assert(in && out && key && ivec && num);
|
||||||
|
assert(*num == 0);
|
||||||
|
|
||||||
|
for(n=0 ; n < length ; ++n)
|
||||||
|
AES_cfbr_encrypt_block(&in[n],&out[n],8,key,ivec,enc);
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -37,8 +37,11 @@
|
|||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <openssl/aes.h>
|
#include <openssl/aes.h>
|
||||||
|
#include <openssl/fips.h>
|
||||||
#include "aes_locl.h"
|
#include "aes_locl.h"
|
||||||
|
|
||||||
|
#ifndef OPENSSL_FIPS
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Te0[x] = S [x].[02, 01, 01, 03];
|
Te0[x] = S [x].[02, 01, 01, 03];
|
||||||
Te1[x] = S [x].[03, 02, 01, 01];
|
Te1[x] = S [x].[03, 02, 01, 01];
|
||||||
@@ -1255,3 +1258,4 @@ void AES_decrypt(const unsigned char *in, unsigned char *out,
|
|||||||
PUTU32(out + 12, s3);
|
PUTU32(out + 12, s3);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif /* ndef OPENSSL_FIPS */
|
||||||
|
|||||||
@@ -59,39 +59,44 @@
|
|||||||
#include <openssl/aes.h>
|
#include <openssl/aes.h>
|
||||||
#include "aes_locl.h"
|
#include "aes_locl.h"
|
||||||
|
|
||||||
/* NOTE: CTR mode is big-endian. The rest of the AES code
|
/* NOTE: the IV/counter CTR mode is big-endian. The rest of the AES code
|
||||||
* is endian-neutral. */
|
* is endian-neutral. */
|
||||||
|
|
||||||
/* increment counter (128-bit int) by 2^64 */
|
/* increment counter (128-bit int) by 1 */
|
||||||
static void AES_ctr128_inc(unsigned char *counter) {
|
static void AES_ctr128_inc(unsigned char *counter) {
|
||||||
unsigned long c;
|
unsigned long c;
|
||||||
|
|
||||||
/* Grab 3rd dword of counter and increment */
|
/* Grab bottom dword of counter and increment */
|
||||||
#ifdef L_ENDIAN
|
c = GETU32(counter + 12);
|
||||||
c = GETU32(counter + 8);
|
c++; c &= 0xFFFFFFFF;
|
||||||
c++;
|
PUTU32(counter + 12, c);
|
||||||
PUTU32(counter + 8, c);
|
|
||||||
#else
|
/* if no overflow, we're done */
|
||||||
c = GETU32(counter + 4);
|
if (c)
|
||||||
c++;
|
return;
|
||||||
PUTU32(counter + 4, c);
|
|
||||||
#endif
|
/* Grab 1st dword of counter and increment */
|
||||||
|
c = GETU32(counter + 8);
|
||||||
|
c++; c &= 0xFFFFFFFF;
|
||||||
|
PUTU32(counter + 8, c);
|
||||||
|
|
||||||
|
/* if no overflow, we're done */
|
||||||
|
if (c)
|
||||||
|
return;
|
||||||
|
|
||||||
|
/* Grab 2nd dword of counter and increment */
|
||||||
|
c = GETU32(counter + 4);
|
||||||
|
c++; c &= 0xFFFFFFFF;
|
||||||
|
PUTU32(counter + 4, c);
|
||||||
|
|
||||||
/* if no overflow, we're done */
|
/* if no overflow, we're done */
|
||||||
if (c)
|
if (c)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* Grab top dword of counter and increment */
|
/* Grab top dword of counter and increment */
|
||||||
#ifdef L_ENDIAN
|
|
||||||
c = GETU32(counter + 12);
|
|
||||||
c++;
|
|
||||||
PUTU32(counter + 12, c);
|
|
||||||
#else
|
|
||||||
c = GETU32(counter + 0);
|
c = GETU32(counter + 0);
|
||||||
c++;
|
c++; c &= 0xFFFFFFFF;
|
||||||
PUTU32(counter + 0, c);
|
PUTU32(counter + 0, c);
|
||||||
#endif
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* The input encrypted as though 128bit counter mode is being
|
/* The input encrypted as though 128bit counter mode is being
|
||||||
@@ -100,10 +105,16 @@ static void AES_ctr128_inc(unsigned char *counter) {
|
|||||||
* encrypted counter is kept in ecount_buf. Both *num and
|
* encrypted counter is kept in ecount_buf. Both *num and
|
||||||
* ecount_buf must be initialised with zeros before the first
|
* ecount_buf must be initialised with zeros before the first
|
||||||
* call to AES_ctr128_encrypt().
|
* call to AES_ctr128_encrypt().
|
||||||
|
*
|
||||||
|
* This algorithm assumes that the counter is in the x lower bits
|
||||||
|
* of the IV (ivec), and that the application has full control over
|
||||||
|
* overflow and the rest of the IV. This implementation takes NO
|
||||||
|
* responsability for checking that the counter doesn't overflow
|
||||||
|
* into the rest of the IV when incremented.
|
||||||
*/
|
*/
|
||||||
void AES_ctr128_encrypt(const unsigned char *in, unsigned char *out,
|
void AES_ctr128_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
const unsigned long length, const AES_KEY *key,
|
const unsigned long length, const AES_KEY *key,
|
||||||
unsigned char counter[AES_BLOCK_SIZE],
|
unsigned char ivec[AES_BLOCK_SIZE],
|
||||||
unsigned char ecount_buf[AES_BLOCK_SIZE],
|
unsigned char ecount_buf[AES_BLOCK_SIZE],
|
||||||
unsigned int *num) {
|
unsigned int *num) {
|
||||||
|
|
||||||
@@ -117,8 +128,8 @@ void AES_ctr128_encrypt(const unsigned char *in, unsigned char *out,
|
|||||||
|
|
||||||
while (l--) {
|
while (l--) {
|
||||||
if (n == 0) {
|
if (n == 0) {
|
||||||
AES_encrypt(counter, ecount_buf, key);
|
AES_encrypt(ivec, ecount_buf, key);
|
||||||
AES_ctr128_inc(counter);
|
AES_ctr128_inc(ivec);
|
||||||
}
|
}
|
||||||
*(out++) = *(in++) ^ ecount_buf[n];
|
*(out++) = *(in++) ^ ecount_buf[n];
|
||||||
n = (n+1) % AES_BLOCK_SIZE;
|
n = (n+1) % AES_BLOCK_SIZE;
|
||||||
|
|||||||
@@ -62,7 +62,7 @@
|
|||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#if defined(_MSC_VER) && !defined(OPENSSL_SYS_WINCE)
|
#if defined(_MSC_VER) && !defined(_M_IA64) && !defined(OPENSSL_SYS_WINCE)
|
||||||
# define SWAP(x) (_lrotl(x, 8) & 0x00ff00ff | _lrotr(x, 8) & 0xff00ff00)
|
# define SWAP(x) (_lrotl(x, 8) & 0x00ff00ff | _lrotr(x, 8) & 0xff00ff00)
|
||||||
# define GETU32(p) SWAP(*((u32 *)(p)))
|
# define GETU32(p) SWAP(*((u32 *)(p)))
|
||||||
# define PUTU32(ct, st) { *((u32 *)(ct)) = SWAP((st)); }
|
# define PUTU32(ct, st) { *((u32 *)(ct)) = SWAP((st)); }
|
||||||
|
|||||||
@@ -1,2 +1,4 @@
|
|||||||
lib
|
lib
|
||||||
Makefile.save
|
Makefile.save
|
||||||
|
*.flc
|
||||||
|
semantic.cache
|
||||||
|
|||||||
@@ -10,10 +10,9 @@ CFLAG=-g
|
|||||||
INSTALL_PREFIX=
|
INSTALL_PREFIX=
|
||||||
OPENSSLDIR= /usr/local/ssl
|
OPENSSLDIR= /usr/local/ssl
|
||||||
INSTALLTOP=/usr/local/ssl
|
INSTALLTOP=/usr/local/ssl
|
||||||
MAKE= make -f Makefile.ssl
|
|
||||||
MAKEDEPPROG= makedepend
|
MAKEDEPPROG= makedepend
|
||||||
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
||||||
MAKEFILE= Makefile.ssl
|
MAKEFILE= Makefile
|
||||||
AR= ar r
|
AR= ar r
|
||||||
|
|
||||||
CFLAGS= $(INCLUDES) $(CFLAG)
|
CFLAGS= $(INCLUDES) $(CFLAG)
|
||||||
@@ -74,16 +73,15 @@ lib: $(LIBOBJ)
|
|||||||
@touch lib
|
@touch lib
|
||||||
|
|
||||||
files:
|
files:
|
||||||
$(PERL) $(TOP)/util/files.pl Makefile.ssl >> $(TOP)/MINFO
|
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
|
||||||
|
|
||||||
links:
|
links:
|
||||||
@$(TOP)/util/point.sh Makefile.ssl Makefile
|
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
|
@$(PERL) $(TOP)/util/mklink.pl ../../include/openssl $(EXHEADER)
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
|
@$(PERL) $(TOP)/util/mklink.pl ../../test $(TEST)
|
||||||
@$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
|
@$(PERL) $(TOP)/util/mklink.pl ../../apps $(APPS)
|
||||||
|
|
||||||
install:
|
install:
|
||||||
@for i in $(EXHEADER) ; \
|
@headerlist="$(EXHEADER)"; for i in $$headerlist ; \
|
||||||
do \
|
do \
|
||||||
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
(cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
||||||
@@ -194,8 +194,12 @@ int ASN1_BIT_STRING_set_bit(ASN1_BIT_STRING *a, int n, int value)
|
|||||||
c=(unsigned char *)OPENSSL_realloc_clean(a->data,
|
c=(unsigned char *)OPENSSL_realloc_clean(a->data,
|
||||||
a->length,
|
a->length,
|
||||||
w+1);
|
w+1);
|
||||||
if (c == NULL) return(0);
|
if (c == NULL)
|
||||||
if (w+1-a->length > 0) memset(c+a->length, 0, w+1-a->length);
|
{
|
||||||
|
ASN1err(ASN1_F_ASN1_BIT_STRING_SET_BIT,ERR_R_MALLOC_FAILURE);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
if (w+1-a->length > 0) memset(c+a->length, 0, w+1-a->length);
|
||||||
a->data=c;
|
a->data=c;
|
||||||
a->length=w+1;
|
a->length=w+1;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -65,6 +65,7 @@
|
|||||||
# include <sys/types.h>
|
# include <sys/types.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include <openssl/err.h>
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
#include <openssl/buffer.h>
|
#include <openssl/buffer.h>
|
||||||
#include <openssl/x509.h>
|
#include <openssl/x509.h>
|
||||||
@@ -78,7 +79,11 @@ int ASN1_digest(int (*i2d)(), const EVP_MD *type, char *data,
|
|||||||
unsigned char *str,*p;
|
unsigned char *str,*p;
|
||||||
|
|
||||||
i=i2d(data,NULL);
|
i=i2d(data,NULL);
|
||||||
if ((str=(unsigned char *)OPENSSL_malloc(i)) == NULL) return(0);
|
if ((str=(unsigned char *)OPENSSL_malloc(i)) == NULL)
|
||||||
|
{
|
||||||
|
ASN1err(ASN1_F_ASN1_DIGEST,ERR_R_MALLOC_FAILURE);
|
||||||
|
return(0);
|
||||||
|
}
|
||||||
p=str;
|
p=str;
|
||||||
i2d(data,&p);
|
i2d(data,&p);
|
||||||
|
|
||||||
|
|||||||
@@ -156,7 +156,7 @@ ASN1_ENUMERATED *BN_to_ASN1_ENUMERATED(BIGNUM *bn, ASN1_ENUMERATED *ai)
|
|||||||
unsigned char *new_data=OPENSSL_realloc(ret->data, len+4);
|
unsigned char *new_data=OPENSSL_realloc(ret->data, len+4);
|
||||||
if (!new_data)
|
if (!new_data)
|
||||||
{
|
{
|
||||||
ASN1err(ASN1_F_BN_TO_ASN1_INTEGER,ERR_R_MALLOC_FAILURE);
|
ASN1err(ASN1_F_BN_TO_ASN1_ENUMERATED,ERR_R_MALLOC_FAILURE);
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
ret->data=new_data;
|
ret->data=new_data;
|
||||||
|
|||||||
@@ -192,8 +192,9 @@ int ASN1_GENERALIZEDTIME_set_string(ASN1_GENERALIZEDTIME *s, char *str)
|
|||||||
{
|
{
|
||||||
if (s != NULL)
|
if (s != NULL)
|
||||||
{
|
{
|
||||||
ASN1_STRING_set((ASN1_STRING *)s,
|
if (!ASN1_STRING_set((ASN1_STRING *)s,
|
||||||
(unsigned char *)str,t.length);
|
(unsigned char *)str,t.length))
|
||||||
|
return 0;
|
||||||
s->type=V_ASN1_GENERALIZEDTIME;
|
s->type=V_ASN1_GENERALIZEDTIME;
|
||||||
}
|
}
|
||||||
return(1);
|
return(1);
|
||||||
@@ -208,6 +209,7 @@ ASN1_GENERALIZEDTIME *ASN1_GENERALIZEDTIME_set(ASN1_GENERALIZEDTIME *s,
|
|||||||
char *p;
|
char *p;
|
||||||
struct tm *ts;
|
struct tm *ts;
|
||||||
struct tm data;
|
struct tm data;
|
||||||
|
size_t len = 20;
|
||||||
|
|
||||||
if (s == NULL)
|
if (s == NULL)
|
||||||
s=M_ASN1_GENERALIZEDTIME_new();
|
s=M_ASN1_GENERALIZEDTIME_new();
|
||||||
@@ -219,17 +221,22 @@ ASN1_GENERALIZEDTIME *ASN1_GENERALIZEDTIME_set(ASN1_GENERALIZEDTIME *s,
|
|||||||
return(NULL);
|
return(NULL);
|
||||||
|
|
||||||
p=(char *)s->data;
|
p=(char *)s->data;
|
||||||
if ((p == NULL) || (s->length < 16))
|
if ((p == NULL) || ((size_t)s->length < len))
|
||||||
{
|
{
|
||||||
p=OPENSSL_malloc(20);
|
p=OPENSSL_malloc(len);
|
||||||
if (p == NULL) return(NULL);
|
if (p == NULL)
|
||||||
|
{
|
||||||
|
ASN1err(ASN1_F_ASN1_GENERALIZEDTIME_SET,
|
||||||
|
ERR_R_MALLOC_FAILURE);
|
||||||
|
return(NULL);
|
||||||
|
}
|
||||||
if (s->data != NULL)
|
if (s->data != NULL)
|
||||||
OPENSSL_free(s->data);
|
OPENSSL_free(s->data);
|
||||||
s->data=(unsigned char *)p;
|
s->data=(unsigned char *)p;
|
||||||
}
|
}
|
||||||
|
|
||||||
sprintf(p,"%04d%02d%02d%02d%02d%02dZ",ts->tm_year + 1900,
|
BIO_snprintf(p,len,"%04d%02d%02d%02d%02d%02dZ",ts->tm_year + 1900,
|
||||||
ts->tm_mon+1,ts->tm_mday,ts->tm_hour,ts->tm_min,ts->tm_sec);
|
ts->tm_mon+1,ts->tm_mday,ts->tm_hour,ts->tm_min,ts->tm_sec);
|
||||||
s->length=strlen(p);
|
s->length=strlen(p);
|
||||||
s->type=V_ASN1_GENERALIZEDTIME;
|
s->type=V_ASN1_GENERALIZEDTIME;
|
||||||
#ifdef CHARSET_EBCDIC_not
|
#ifdef CHARSET_EBCDIC_not
|
||||||
|
|||||||
@@ -64,7 +64,26 @@ ASN1_INTEGER *ASN1_INTEGER_dup(ASN1_INTEGER *x)
|
|||||||
{ return M_ASN1_INTEGER_dup(x);}
|
{ return M_ASN1_INTEGER_dup(x);}
|
||||||
|
|
||||||
int ASN1_INTEGER_cmp(ASN1_INTEGER *x, ASN1_INTEGER *y)
|
int ASN1_INTEGER_cmp(ASN1_INTEGER *x, ASN1_INTEGER *y)
|
||||||
{ return M_ASN1_INTEGER_cmp(x,y);}
|
{
|
||||||
|
int neg, ret;
|
||||||
|
/* Compare signs */
|
||||||
|
neg = x->type & V_ASN1_NEG;
|
||||||
|
if (neg != (y->type & V_ASN1_NEG))
|
||||||
|
{
|
||||||
|
if (neg)
|
||||||
|
return -1;
|
||||||
|
else
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
ret = ASN1_STRING_cmp(x, y);
|
||||||
|
|
||||||
|
if (neg)
|
||||||
|
return -ret;
|
||||||
|
else
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This converts an ASN1 INTEGER into its content encoding.
|
* This converts an ASN1 INTEGER into its content encoding.
|
||||||
|
|||||||
@@ -145,14 +145,14 @@ int ASN1_mbstring_ncopy(ASN1_STRING **out, const unsigned char *in, int len,
|
|||||||
|
|
||||||
if((minsize > 0) && (nchar < minsize)) {
|
if((minsize > 0) && (nchar < minsize)) {
|
||||||
ASN1err(ASN1_F_ASN1_MBSTRING_COPY, ASN1_R_STRING_TOO_SHORT);
|
ASN1err(ASN1_F_ASN1_MBSTRING_COPY, ASN1_R_STRING_TOO_SHORT);
|
||||||
sprintf(strbuf, "%ld", minsize);
|
BIO_snprintf(strbuf, sizeof strbuf, "%ld", minsize);
|
||||||
ERR_add_error_data(2, "minsize=", strbuf);
|
ERR_add_error_data(2, "minsize=", strbuf);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if((maxsize > 0) && (nchar > maxsize)) {
|
if((maxsize > 0) && (nchar > maxsize)) {
|
||||||
ASN1err(ASN1_F_ASN1_MBSTRING_COPY, ASN1_R_STRING_TOO_LONG);
|
ASN1err(ASN1_F_ASN1_MBSTRING_COPY, ASN1_R_STRING_TOO_LONG);
|
||||||
sprintf(strbuf, "%ld", maxsize);
|
BIO_snprintf(strbuf, sizeof strbuf, "%ld", maxsize);
|
||||||
ERR_add_error_data(2, "maxsize=", strbuf);
|
ERR_add_error_data(2, "maxsize=", strbuf);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
@@ -296,7 +296,7 @@ static int in_utf8(unsigned long value, void *arg)
|
|||||||
|
|
||||||
static int out_utf8(unsigned long value, void *arg)
|
static int out_utf8(unsigned long value, void *arg)
|
||||||
{
|
{
|
||||||
long *outlen;
|
int *outlen;
|
||||||
outlen = arg;
|
outlen = arg;
|
||||||
*outlen += UTF8_putc(NULL, -1, value);
|
*outlen += UTF8_putc(NULL, -1, value);
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
@@ -60,7 +60,7 @@
|
|||||||
#include "cryptlib.h"
|
#include "cryptlib.h"
|
||||||
#include <openssl/asn1.h>
|
#include <openssl/asn1.h>
|
||||||
|
|
||||||
int ASN1_PRINTABLE_type(unsigned char *s, int len)
|
int ASN1_PRINTABLE_type(const unsigned char *s, int len)
|
||||||
{
|
{
|
||||||
int c;
|
int c;
|
||||||
int ia5=0;
|
int ia5=0;
|
||||||
|
|||||||
@@ -118,8 +118,13 @@ int i2d_ASN1_SET(STACK *a, unsigned char **pp, int (*func)(), int ex_tag,
|
|||||||
}
|
}
|
||||||
|
|
||||||
pStart = p; /* Catch the beg of Setblobs*/
|
pStart = p; /* Catch the beg of Setblobs*/
|
||||||
if (!(rgSetBlob = (MYBLOB *)OPENSSL_malloc( sk_num(a) * sizeof(MYBLOB)))) return 0; /* In this array
|
/* In this array we will store the SET blobs */
|
||||||
we will store the SET blobs */
|
rgSetBlob = (MYBLOB *)OPENSSL_malloc(sk_num(a) * sizeof(MYBLOB));
|
||||||
|
if (rgSetBlob == NULL)
|
||||||
|
{
|
||||||
|
ASN1err(ASN1_F_I2D_ASN1_SET,ERR_R_MALLOC_FAILURE);
|
||||||
|
return(0);
|
||||||
|
}
|
||||||
|
|
||||||
for (i=0; i<sk_num(a); i++)
|
for (i=0; i<sk_num(a); i++)
|
||||||
{
|
{
|
||||||
@@ -135,7 +140,11 @@ SetBlob
|
|||||||
/* Now we have to sort the blobs. I am using a simple algo.
|
/* Now we have to sort the blobs. I am using a simple algo.
|
||||||
*Sort ptrs *Copy to temp-mem *Copy from temp-mem to user-mem*/
|
*Sort ptrs *Copy to temp-mem *Copy from temp-mem to user-mem*/
|
||||||
qsort( rgSetBlob, sk_num(a), sizeof(MYBLOB), SetBlobCmp);
|
qsort( rgSetBlob, sk_num(a), sizeof(MYBLOB), SetBlobCmp);
|
||||||
if (!(pTempMem = OPENSSL_malloc(totSize))) return 0;
|
if (!(pTempMem = OPENSSL_malloc(totSize)))
|
||||||
|
{
|
||||||
|
ASN1err(ASN1_F_I2D_ASN1_SET,ERR_R_MALLOC_FAILURE);
|
||||||
|
return(0);
|
||||||
|
}
|
||||||
|
|
||||||
/* Copy to temp mem */
|
/* Copy to temp mem */
|
||||||
p = pTempMem;
|
p = pTempMem;
|
||||||
@@ -160,7 +169,13 @@ STACK *d2i_ASN1_SET(STACK **a, unsigned char **pp, long length,
|
|||||||
STACK *ret=NULL;
|
STACK *ret=NULL;
|
||||||
|
|
||||||
if ((a == NULL) || ((*a) == NULL))
|
if ((a == NULL) || ((*a) == NULL))
|
||||||
{ if ((ret=sk_new_null()) == NULL) goto err; }
|
{
|
||||||
|
if ((ret=sk_new_null()) == NULL)
|
||||||
|
{
|
||||||
|
ASN1err(ASN1_F_D2I_ASN1_SET,ERR_R_MALLOC_FAILURE);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
ret=(*a);
|
ret=(*a);
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
* project 2000.
|
* project 2000.
|
||||||
*/
|
*/
|
||||||
/* ====================================================================
|
/* ====================================================================
|
||||||
* Copyright (c) 2000 The OpenSSL Project. All rights reserved.
|
* Copyright (c) 2000-2004 The OpenSSL Project. All rights reserved.
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
* modification, are permitted provided that the following conditions
|
* modification, are permitted provided that the following conditions
|
||||||
@@ -279,13 +279,13 @@ static int do_dump(unsigned long lflags, char_io *io_ch, void *arg, ASN1_STRING
|
|||||||
* otherwise it is the number of bytes per character
|
* otherwise it is the number of bytes per character
|
||||||
*/
|
*/
|
||||||
|
|
||||||
const static char tag2nbyte[] = {
|
const static signed char tag2nbyte[] = {
|
||||||
-1, -1, -1, -1, -1, /* 0-4 */
|
-1, -1, -1, -1, -1, /* 0-4 */
|
||||||
-1, -1, -1, -1, -1, /* 5-9 */
|
-1, -1, -1, -1, -1, /* 5-9 */
|
||||||
-1, -1, 0, -1, /* 10-13 */
|
-1, -1, 0, -1, /* 10-13 */
|
||||||
-1, -1, -1, -1, /* 15-17 */
|
-1, -1, -1, -1, /* 15-17 */
|
||||||
-1, 1, 1, /* 18-20 */
|
-1, 1, 1, /* 18-20 */
|
||||||
-1, 1, -1,-1, /* 21-24 */
|
-1, 1, 1, 1, /* 21-24 */
|
||||||
-1, 1, -1, /* 25-27 */
|
-1, 1, -1, /* 25-27 */
|
||||||
4, -1, 2 /* 28-30 */
|
4, -1, 2 /* 28-30 */
|
||||||
};
|
};
|
||||||
@@ -553,7 +553,12 @@ int ASN1_STRING_to_UTF8(unsigned char **out, ASN1_STRING *in)
|
|||||||
if((type < 0) || (type > 30)) return -1;
|
if((type < 0) || (type > 30)) return -1;
|
||||||
mbflag = tag2nbyte[type];
|
mbflag = tag2nbyte[type];
|
||||||
if(mbflag == -1) return -1;
|
if(mbflag == -1) return -1;
|
||||||
mbflag |= MBSTRING_FLAG;
|
if (mbflag == 0)
|
||||||
|
mbflag = MBSTRING_UTF8;
|
||||||
|
else if (mbflag == 4)
|
||||||
|
mbflag = MBSTRING_UNIV;
|
||||||
|
else
|
||||||
|
mbflag |= MBSTRING_FLAG;
|
||||||
stmp.data = NULL;
|
stmp.data = NULL;
|
||||||
ret = ASN1_mbstring_copy(&str, in->data, in->length, mbflag, B_ASN1_UTF8STRING);
|
ret = ASN1_mbstring_copy(&str, in->data, in->length, mbflag, B_ASN1_UTF8STRING);
|
||||||
if(ret < 0) return ret;
|
if(ret < 0) return ret;
|
||||||
|
|||||||
@@ -143,7 +143,7 @@ ASN1_STRING *ASN1_STRING_set_by_NID(ASN1_STRING **out, const unsigned char *in,
|
|||||||
/* Now the tables and helper functions for the string table:
|
/* Now the tables and helper functions for the string table:
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* size limits: this stuff is taken straight from RFC2459 */
|
/* size limits: this stuff is taken straight from RFC3280 */
|
||||||
|
|
||||||
#define ub_name 32768
|
#define ub_name 32768
|
||||||
#define ub_common_name 64
|
#define ub_common_name 64
|
||||||
@@ -153,6 +153,8 @@ ASN1_STRING *ASN1_STRING_set_by_NID(ASN1_STRING **out, const unsigned char *in,
|
|||||||
#define ub_organization_unit_name 64
|
#define ub_organization_unit_name 64
|
||||||
#define ub_title 64
|
#define ub_title 64
|
||||||
#define ub_email_address 128
|
#define ub_email_address 128
|
||||||
|
#define ub_serial_number 64
|
||||||
|
|
||||||
|
|
||||||
/* This table must be kept in NID order */
|
/* This table must be kept in NID order */
|
||||||
|
|
||||||
@@ -170,9 +172,11 @@ static ASN1_STRING_TABLE tbl_standard[] = {
|
|||||||
{NID_givenName, 1, ub_name, DIRSTRING_TYPE, 0},
|
{NID_givenName, 1, ub_name, DIRSTRING_TYPE, 0},
|
||||||
{NID_surname, 1, ub_name, DIRSTRING_TYPE, 0},
|
{NID_surname, 1, ub_name, DIRSTRING_TYPE, 0},
|
||||||
{NID_initials, 1, ub_name, DIRSTRING_TYPE, 0},
|
{NID_initials, 1, ub_name, DIRSTRING_TYPE, 0},
|
||||||
|
{NID_serialNumber, 1, ub_serial_number, B_ASN1_PRINTABLESTRING, STABLE_NO_MASK},
|
||||||
{NID_friendlyName, -1, -1, B_ASN1_BMPSTRING, STABLE_NO_MASK},
|
{NID_friendlyName, -1, -1, B_ASN1_BMPSTRING, STABLE_NO_MASK},
|
||||||
{NID_name, 1, ub_name, DIRSTRING_TYPE, 0},
|
{NID_name, 1, ub_name, DIRSTRING_TYPE, 0},
|
||||||
{NID_dnQualifier, -1, -1, B_ASN1_PRINTABLESTRING, STABLE_NO_MASK},
|
{NID_dnQualifier, -1, -1, B_ASN1_PRINTABLESTRING, STABLE_NO_MASK},
|
||||||
|
{NID_domainComponent, 1, -1, B_ASN1_IA5STRING, STABLE_NO_MASK},
|
||||||
{NID_ms_csp_name, -1, -1, B_ASN1_BMPSTRING, STABLE_NO_MASK}
|
{NID_ms_csp_name, -1, -1, B_ASN1_BMPSTRING, STABLE_NO_MASK}
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -249,4 +253,38 @@ static void st_free(ASN1_STRING_TABLE *tbl)
|
|||||||
if(tbl->flags & STABLE_FLAGS_MALLOC) OPENSSL_free(tbl);
|
if(tbl->flags & STABLE_FLAGS_MALLOC) OPENSSL_free(tbl);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
IMPLEMENT_STACK_OF(ASN1_STRING_TABLE)
|
IMPLEMENT_STACK_OF(ASN1_STRING_TABLE)
|
||||||
|
|
||||||
|
#ifdef STRING_TABLE_TEST
|
||||||
|
|
||||||
|
main()
|
||||||
|
{
|
||||||
|
ASN1_STRING_TABLE *tmp;
|
||||||
|
int i, last_nid = -1;
|
||||||
|
|
||||||
|
for (tmp = tbl_standard, i = 0;
|
||||||
|
i < sizeof(tbl_standard)/sizeof(ASN1_STRING_TABLE); i++, tmp++)
|
||||||
|
{
|
||||||
|
if (tmp->nid < last_nid)
|
||||||
|
{
|
||||||
|
last_nid = 0;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
last_nid = tmp->nid;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (last_nid != 0)
|
||||||
|
{
|
||||||
|
printf("Table order OK\n");
|
||||||
|
exit(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
for (tmp = tbl_standard, i = 0;
|
||||||
|
i < sizeof(tbl_standard)/sizeof(ASN1_STRING_TABLE); i++, tmp++)
|
||||||
|
printf("Index %d, NID %d, Name=%s\n", i, tmp->nid,
|
||||||
|
OBJ_nid2ln(tmp->nid));
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|||||||
@@ -128,6 +128,7 @@ ASN1_GENERALIZEDTIME *ASN1_TIME_to_generalizedtime(ASN1_TIME *t, ASN1_GENERALIZE
|
|||||||
{
|
{
|
||||||
ASN1_GENERALIZEDTIME *ret;
|
ASN1_GENERALIZEDTIME *ret;
|
||||||
char *str;
|
char *str;
|
||||||
|
int newlen;
|
||||||
|
|
||||||
if (!ASN1_TIME_check(t)) return NULL;
|
if (!ASN1_TIME_check(t)) return NULL;
|
||||||
|
|
||||||
@@ -150,12 +151,14 @@ ASN1_GENERALIZEDTIME *ASN1_TIME_to_generalizedtime(ASN1_TIME *t, ASN1_GENERALIZE
|
|||||||
/* grow the string */
|
/* grow the string */
|
||||||
if (!ASN1_STRING_set(ret, NULL, t->length + 2))
|
if (!ASN1_STRING_set(ret, NULL, t->length + 2))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
/* ASN1_STRING_set() allocated 'len + 1' bytes. */
|
||||||
|
newlen = t->length + 2 + 1;
|
||||||
str = (char *)ret->data;
|
str = (char *)ret->data;
|
||||||
/* Work out the century and prepend */
|
/* Work out the century and prepend */
|
||||||
if (t->data[0] >= '5') strcpy(str, "19");
|
if (t->data[0] >= '5') BUF_strlcpy(str, "19", newlen);
|
||||||
else strcpy(str, "20");
|
else BUF_strlcpy(str, "20", newlen);
|
||||||
|
|
||||||
BUF_strlcat(str, (char *)t->data, t->length+3); /* Include space for a '\0' */
|
BUF_strlcat(str, (char *)t->data, newlen);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user