Compare commits
1508 Commits
OpenSSL-fi
...
OpenSSL_1_
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0d8776344c | ||
|
|
197e0ea817 | ||
|
|
c776a3f398 | ||
|
|
25c9fa6026 | ||
|
|
d2dc33d57c | ||
|
|
f3dcc8411e | ||
|
|
1c2c5e402a | ||
|
|
34628967f1 | ||
|
|
a6c62f0c25 | ||
|
|
ca989269a2 | ||
|
|
2ec4181ba9 | ||
|
|
0294b2be5f | ||
|
|
f1068a1ab7 | ||
|
|
cadde467a8 | ||
|
|
c2bdcba347 | ||
|
|
60df657b3a | ||
|
|
17a2d0801f | ||
|
|
accb3007ac | ||
|
|
b13dff6141 | ||
|
|
4ade6a8ca4 | ||
|
|
00fadef414 | ||
|
|
7ed244a0b3 | ||
|
|
e94a23876c | ||
|
|
041f681943 | ||
|
|
afec9f57da | ||
|
|
0ec1a77891 | ||
|
|
62c2b6d944 | ||
|
|
5b98979712 | ||
|
|
9abbf5cce7 | ||
|
|
ddfe486e4c | ||
|
|
834d30bc63 | ||
|
|
e26faa9e0c | ||
|
|
025f7dbdd1 | ||
|
|
44f4934bde | ||
|
|
453ca706cc | ||
|
|
5e1ff664f9 | ||
|
|
833a896681 | ||
|
|
34e43b909f | ||
|
|
62036c6fc3 | ||
|
|
68dd8512b7 | ||
|
|
bbf9f3c654 | ||
|
|
2583270191 | ||
|
|
3da721dac9 | ||
|
|
eb22b7ec75 | ||
|
|
b93916149d | ||
|
|
82f42a1d2e | ||
|
|
a4870de5aa | ||
|
|
39aabe59c8 | ||
|
|
f4c93b46ed | ||
|
|
4af793036f | ||
|
|
13bca90ac5 | ||
|
|
c9a6ddafc5 | ||
|
|
f4a51970d2 | ||
|
|
937f125efc | ||
|
|
4b61f6d2a6 | ||
|
|
d5bff72615 | ||
|
|
3b4be0018b | ||
|
|
125c2ed8a3 | ||
|
|
09da95542a | ||
|
|
cc53b38574 | ||
|
|
0aeeae0c9c | ||
|
|
00c991f028 | ||
|
|
55856a7b74 | ||
|
|
83a3af9f4e | ||
|
|
76bf0cf27c | ||
|
|
7cf0529b52 | ||
|
|
6c03af135b | ||
|
|
5cd1aa4f15 | ||
|
|
04b80f4003 | ||
|
|
591c55a981 | ||
|
|
cd2693862b | ||
|
|
25370e93c6 | ||
|
|
cdb6c48445 | ||
|
|
04b727b4dd | ||
|
|
cbd93a0636 | ||
|
|
b9e84f007f | ||
|
|
29a546720b | ||
|
|
0e9dd387ea | ||
|
|
79dabcc137 | ||
|
|
944bc29f90 | ||
|
|
03e1b3a153 | ||
|
|
9c95ff968a | ||
|
|
96b680f210 | ||
|
|
9ab3ce1246 | ||
|
|
3972dbe462 | ||
|
|
85615e33e5 | ||
|
|
f4cfc3444a | ||
|
|
24f599af21 | ||
|
|
bca0d7fdb5 | ||
|
|
bc4ae2cb0b | ||
|
|
ef4b9f001a | ||
|
|
08f8933fa3 | ||
|
|
41958376b5 | ||
|
|
9fe4603b82 | ||
|
|
147dbb2fe3 | ||
|
|
cbf9b4aed3 | ||
|
|
625a55324f | ||
|
|
3151e328e0 | ||
|
|
46ebd9e3bb | ||
|
|
f66db68e1f | ||
|
|
0c4b72e9c0 | ||
|
|
f88dbb8385 | ||
|
|
1113fc31ba | ||
|
|
0898147090 | ||
|
|
4d8da30fc1 | ||
|
|
579f3a631e | ||
|
|
47061af106 | ||
|
|
13e225300f | ||
|
|
26bc56d014 | ||
|
|
496681cd51 | ||
|
|
746c6f3a53 | ||
|
|
8545f73b89 | ||
|
|
32cc2479b4 | ||
|
|
f306b87d76 | ||
|
|
41cf07f0ec | ||
|
|
62f4033381 | ||
|
|
f9f6a8f96c | ||
|
|
df0d93564e | ||
|
|
0d589ac150 | ||
|
|
35d732fc2e | ||
|
|
896ddb9851 | ||
|
|
e630b3c218 | ||
|
|
f1ca56a69f | ||
|
|
529d27ea47 | ||
|
|
b2226c6c83 | ||
|
|
024de2174b | ||
|
|
125093b59f | ||
|
|
f3e99ea072 | ||
|
|
8bfd4c659f | ||
|
|
ec07246a08 | ||
|
|
04e45b52ee | ||
|
|
d5371324d9 | ||
|
|
36260233e7 | ||
|
|
cab13fc847 | ||
|
|
34ab3c8c71 | ||
|
|
25c93fd240 | ||
|
|
428c1064c3 | ||
|
|
81ce0e14e7 | ||
|
|
b908e88ec1 | ||
|
|
62e4506a7d | ||
|
|
014265eb02 | ||
|
|
9f27de170d | ||
|
|
6cb19b7681 | ||
|
|
e130841bcc | ||
|
|
2ee798880a | ||
|
|
ffcf4c6164 | ||
|
|
b286a96811 | ||
|
|
2a2df2e9f2 | ||
|
|
15481c5e42 | ||
|
|
366b60b9da | ||
|
|
4782444a35 | ||
|
|
8a17e161d1 | ||
|
|
72f27cd2df | ||
|
|
3b3674ae58 | ||
|
|
9d75e765bc | ||
|
|
bf07bd4d61 | ||
|
|
296cc7f4b8 | ||
|
|
3d92984689 | ||
|
|
51447d5db5 | ||
|
|
1dcf520fe2 | ||
|
|
fca84dabe6 | ||
|
|
3ea1e13569 | ||
|
|
dd6639bd3a | ||
|
|
bee0550397 | ||
|
|
fc57c58c81 | ||
|
|
5bb6d96558 | ||
|
|
28e1bd35bd | ||
|
|
dd83cc298d | ||
|
|
ea00598596 | ||
|
|
a650314f72 | ||
|
|
54fdc39a08 | ||
|
|
7dc98a62b2 | ||
|
|
f20ba1c9bb | ||
|
|
7c3562947a | ||
|
|
eb3a3911fc | ||
|
|
540f7c75ef | ||
|
|
d6342aab08 | ||
|
|
e7b85bc402 | ||
|
|
07eaaab2f6 | ||
|
|
96f7fafa24 | ||
|
|
487a0df700 | ||
|
|
09ef5f6258 | ||
|
|
bcc0e4ca7c | ||
|
|
caac8fefdc | ||
|
|
353e845120 | ||
|
|
d1451f18d9 | ||
|
|
c3a5b7b82a | ||
|
|
70d91d60bc | ||
|
|
bc78883017 | ||
|
|
f929f201fb | ||
|
|
554cf97f03 | ||
|
|
48ccbeefda | ||
|
|
7a217076d9 | ||
|
|
0720bf7df1 | ||
|
|
9d6727781d | ||
|
|
12c1621523 | ||
|
|
f9b48d60f2 | ||
|
|
5c29127666 | ||
|
|
78d767f5ec | ||
|
|
c8b979e929 | ||
|
|
2beaa91ca7 | ||
|
|
efa288ceac | ||
|
|
ad3bbd4a16 | ||
|
|
73913443a5 | ||
|
|
e133ff7190 | ||
|
|
25da47c3c8 | ||
|
|
4dc40f5eec | ||
|
|
a1a37575f0 | ||
|
|
c64c0e03d3 | ||
|
|
e1e882a368 | ||
|
|
36b0719793 | ||
|
|
7655044dd3 | ||
|
|
58fdd30664 | ||
|
|
7175dbaeba | ||
|
|
af454b5bb0 | ||
|
|
5b2bbf37fa | ||
|
|
6321ac9e15 | ||
|
|
eeca72f71e | ||
|
|
6e164e5c3d | ||
|
|
1b452133ae | ||
|
|
d9c34505e5 | ||
|
|
f9885acc8c | ||
|
|
fa9df48401 | ||
|
|
d414a5a0f0 | ||
|
|
9eb4460e68 | ||
|
|
6984d16671 | ||
|
|
5b9d0995a1 | ||
|
|
7ad8e1fc4e | ||
|
|
c9b31189a9 | ||
|
|
c76b7a1a82 | ||
|
|
c940e07014 | ||
|
|
88be4ebfbc | ||
|
|
effa47b80a | ||
|
|
067400b16e | ||
|
|
748628ced0 | ||
|
|
6791060eae | ||
|
|
502dfeb8de | ||
|
|
5bbed29518 | ||
|
|
2f2d33f470 | ||
|
|
be60a3feaa | ||
|
|
e504a829a0 | ||
|
|
0d829f6681 | ||
|
|
d9540579c5 | ||
|
|
ecf963b80d | ||
|
|
7fc6d35be0 | ||
|
|
e7d2a37158 | ||
|
|
531c6fc8f3 | ||
|
|
e011d0a3c4 | ||
|
|
8d5505d099 | ||
|
|
d36e0ee460 | ||
|
|
143619ccf6 | ||
|
|
9f339d75b5 | ||
|
|
28583660fb | ||
|
|
dedfe959dd | ||
|
|
4d936ace08 | ||
|
|
89bd25eb26 | ||
|
|
4a1cf50187 | ||
|
|
32e12316e5 | ||
|
|
ad7b24f145 | ||
|
|
c2770c0e0e | ||
|
|
371056f2b9 | ||
|
|
2d613908e8 | ||
|
|
18fb1fae08 | ||
|
|
39ef161c72 | ||
|
|
a7612c5066 | ||
|
|
6cbae10b5e | ||
|
|
ebe81134c0 | ||
|
|
a1d573e282 | ||
|
|
e959e24b47 | ||
|
|
3f98d7c0b5 | ||
|
|
d2f950c984 | ||
|
|
63e8f16737 | ||
|
|
9bf5fd894f | ||
|
|
6296729fae | ||
|
|
67d216801b | ||
|
|
0a5575f3f6 | ||
|
|
418044cbab | ||
|
|
8c67b13407 | ||
|
|
2a477ccf0b | ||
|
|
c34137bef9 | ||
|
|
914d91c5b3 | ||
|
|
e733dea3ce | ||
|
|
78c5d2a9bb | ||
|
|
3bf4e14cc3 | ||
|
|
d68d160cb7 | ||
|
|
202cb42fbb | ||
|
|
49f6cb968f | ||
|
|
07e120b7da | ||
|
|
f3dcae15ac | ||
|
|
25ec498dc7 | ||
|
|
9cc42cb091 | ||
|
|
bcf9cf89e7 | ||
|
|
f0729fc3e0 | ||
|
|
8186c00ef3 | ||
|
|
c0b31ccb87 | ||
|
|
267c950c5f | ||
|
|
ce1605b508 | ||
|
|
66fdb1c0d4 | ||
|
|
25bfdca16a | ||
|
|
9c284f9651 | ||
|
|
6d78c381f6 | ||
|
|
784e2080df | ||
|
|
70505bc334 | ||
|
|
8e8b247341 | ||
|
|
a8595879ec | ||
|
|
33a688e806 | ||
|
|
5c2bfad9b4 | ||
|
|
250f979237 | ||
|
|
b527b6e8ff | ||
|
|
a54ce007e6 | ||
|
|
4ed1f3490e | ||
|
|
0a082e9b37 | ||
|
|
236a99a409 | ||
|
|
04b4363ec8 | ||
|
|
37ebc20093 | ||
|
|
cef781cc87 | ||
|
|
08e4c7a967 | ||
|
|
697e4edcad | ||
|
|
b26297ca51 | ||
|
|
6ca7dba0cf | ||
|
|
f1fa05b407 | ||
|
|
02e22c35fe | ||
|
|
b935714237 | ||
|
|
a8314df902 | ||
|
|
0cd7a0325f | ||
|
|
16b7c81d55 | ||
|
|
424ba8b588 | ||
|
|
bf493e8d62 | ||
|
|
c714e43c8d | ||
|
|
cdf9d6f6ed | ||
|
|
cc4b48c27c | ||
|
|
cac9c92cc0 | ||
|
|
d40abf1689 | ||
|
|
69e9c69e70 | ||
|
|
c489ea7d01 | ||
|
|
26c6857a59 | ||
|
|
508bd3d1aa | ||
|
|
8705846710 | ||
|
|
c944a9696e | ||
|
|
943cc09d8a | ||
|
|
fc6800d19f | ||
|
|
d06f047b04 | ||
|
|
ddc899bada | ||
|
|
bd479e25c7 | ||
|
|
eaf5bd168e | ||
|
|
d7ecc206ba | ||
|
|
11ea212e8c | ||
|
|
cb29d8c11f | ||
|
|
adcea5a043 | ||
|
|
f02f7c2c4a | ||
|
|
a1e44cc14f | ||
|
|
d2d09bf68c | ||
|
|
e2dfb655f7 | ||
|
|
463e76b63c | ||
|
|
2dc4b0dbe8 | ||
|
|
7b23c126e6 | ||
|
|
25e3d2225a | ||
|
|
c8e0b5d7b6 | ||
|
|
4fb7e2b445 | ||
|
|
9138e3c061 | ||
|
|
9b2a29660b | ||
|
|
b7b4a9fa57 | ||
|
|
1fb07a7de8 | ||
|
|
b9cbcaad58 | ||
|
|
c6706a6f6c | ||
|
|
958e6a75a1 | ||
|
|
397977726c | ||
|
|
285d9189c7 | ||
|
|
767d3e0054 | ||
|
|
409d2a1b71 | ||
|
|
e0b9678d7f | ||
|
|
166dea6ac8 | ||
|
|
52bef4d677 | ||
|
|
801e5ef840 | ||
|
|
0044739ae5 | ||
|
|
4e44bd3650 | ||
|
|
0cffb0cd3e | ||
|
|
aaa3850ccd | ||
|
|
a17b5d5a4f | ||
|
|
2f97765bc3 | ||
|
|
3205ca8deb | ||
|
|
1cb4d65b87 | ||
|
|
7b2dd292bc | ||
|
|
ab585551c0 | ||
|
|
6cf0d7b999 | ||
|
|
9d972207f0 | ||
|
|
d9834ff24b | ||
|
|
d9c3ba05e7 | ||
|
|
03467ce6bd | ||
|
|
6e750fcb1e | ||
|
|
bd6941cfaa | ||
|
|
578519edd0 | ||
|
|
5c05f69450 | ||
|
|
f529dca488 | ||
|
|
296aca9dcf | ||
|
|
b170703128 | ||
|
|
b300fb7734 | ||
|
|
f89af47438 | ||
|
|
7bb4f8ff12 | ||
|
|
7dd6407a4c | ||
|
|
53de315b78 | ||
|
|
e065e6cda2 | ||
|
|
60553cc209 | ||
|
|
2d4c9ab518 | ||
|
|
50771f7ce3 | ||
|
|
242f8d644c | ||
|
|
f5575cd167 | ||
|
|
dd0ddc3e78 | ||
|
|
62308f3f4a | ||
|
|
cecafcce94 | ||
|
|
ca0efb7594 | ||
|
|
1d05ff2779 | ||
|
|
941811ccb9 | ||
|
|
700384be8e | ||
|
|
b8a22c40e0 | ||
|
|
3918de9ad1 | ||
|
|
96fe35e7d4 | ||
|
|
e87afb1518 | ||
|
|
7b467c6b81 | ||
|
|
eb8ebafe87 | ||
|
|
e559febaf1 | ||
|
|
6bcc6d38c7 | ||
|
|
8173960305 | ||
|
|
f2e590942e | ||
|
|
6a4b87eb9d | ||
|
|
edcba19c23 | ||
|
|
b140ae9137 | ||
|
|
8ee0591f28 | ||
|
|
97d0c596a1 | ||
|
|
7454cba4fa | ||
|
|
5713411893 | ||
|
|
a0cf79e841 | ||
|
|
825e1a7c56 | ||
|
|
9f2b453338 | ||
|
|
a0dce9be76 | ||
|
|
cf2b938529 | ||
|
|
62f685a9cd | ||
|
|
2c7d978c2d | ||
|
|
8cd897a42c | ||
|
|
1dc44d3130 | ||
|
|
2a6e3ef37e | ||
|
|
115d528c23 | ||
|
|
a310428527 | ||
|
|
7e0fd45ce3 | ||
|
|
b138ea54ee | ||
|
|
d7125d8d85 | ||
|
|
9c115a4acc | ||
|
|
43716567f5 | ||
|
|
0a8f00af34 | ||
|
|
b1d7429186 | ||
|
|
060a38a2c0 | ||
|
|
58402976b4 | ||
|
|
cd7b854bbb | ||
|
|
aecc0756e8 | ||
|
|
e6ccc6ed70 | ||
|
|
e959a01fac | ||
|
|
17674bfdf7 | ||
|
|
d807d4c21f | ||
|
|
b4690d2eab | ||
|
|
886657a641 | ||
|
|
db896db5a7 | ||
|
|
2357ae17e7 | ||
|
|
9f1c5491d2 | ||
|
|
70b52222f5 | ||
|
|
88cb59727c | ||
|
|
781bfdc314 | ||
|
|
b66723b23e | ||
|
|
cf96d71c22 | ||
|
|
1a111921da | ||
|
|
5d9bb428bb | ||
|
|
9833757b5d | ||
|
|
4195343c0d | ||
|
|
042bee4e5c | ||
|
|
4afba1f3d9 | ||
|
|
5999d45a5d | ||
|
|
f69e5d6a19 | ||
|
|
3517637702 | ||
|
|
e2809bfb42 | ||
|
|
68b33cc5c7 | ||
|
|
4c02cf8ecc | ||
|
|
271daaf768 | ||
|
|
efbb7ee432 | ||
|
|
6471ec71aa | ||
|
|
cb45708061 | ||
|
|
02597f2885 | ||
|
|
8c6a514edf | ||
|
|
7f3fdab793 | ||
|
|
5372f5f989 | ||
|
|
6d24c09a69 | ||
|
|
a8d72c79db | ||
|
|
1f713e0106 | ||
|
|
03f84c8260 | ||
|
|
6d5eb464c9 | ||
|
|
67f8de9ab8 | ||
|
|
2d95ceedc5 | ||
|
|
6526d765fc | ||
|
|
3d520f7c2d | ||
|
|
9c37519b55 | ||
|
|
7e9cfcd0dc | ||
|
|
a99ce1f5b1 | ||
|
|
42660b3cf1 | ||
|
|
f30258c439 | ||
|
|
93ff4c69f7 | ||
|
|
79571bb1ca | ||
|
|
f72c1a58cb | ||
|
|
2461396f69 | ||
|
|
81a071df2f | ||
|
|
6841abe842 | ||
|
|
cb70355d87 | ||
|
|
b17442bb04 | ||
|
|
4874e235fb | ||
|
|
06afa6eb94 | ||
|
|
58e4205d6c | ||
|
|
733394d6dd | ||
|
|
2de9558dea | ||
|
|
6bd173fced | ||
|
|
6b00cd746a | ||
|
|
9309ea6617 | ||
|
|
05c9e3aea5 | ||
|
|
88bac3e664 | ||
|
|
5473b6bc2f | ||
|
|
38e408076e | ||
|
|
dc100d87b5 | ||
|
|
6f6b31dadc | ||
|
|
b08b158b44 | ||
|
|
177f27d71e | ||
|
|
928bd9a149 | ||
|
|
e53113b8ac | ||
|
|
1fe83b4afe | ||
|
|
e8f31f80d1 | ||
|
|
56f5ab43c2 | ||
|
|
370385571c | ||
|
|
e34a303ce1 | ||
|
|
36f120cd20 | ||
|
|
0ae7c43fa5 | ||
|
|
c0d2943952 | ||
|
|
7d453a3b49 | ||
|
|
cd447875e6 | ||
|
|
692a94293c | ||
|
|
efebb10829 | ||
|
|
3c3f025923 | ||
|
|
5ff6e2dfbb | ||
|
|
61ac68f9f6 | ||
|
|
7f1022a8b1 | ||
|
|
edf6b025b1 | ||
|
|
d799df36b3 | ||
|
|
9e96812934 | ||
|
|
91e97cbe4c | ||
|
|
63ee3b32fe | ||
|
|
4ff1a2da10 | ||
|
|
4c3c975066 | ||
|
|
ec5d74f868 | ||
|
|
be0853358c | ||
|
|
fea15b553d | ||
|
|
88ef78745e | ||
|
|
be79342515 | ||
|
|
064a6176ac | ||
|
|
84e7485bfb | ||
|
|
f56f72f219 | ||
|
|
2bfb23f102 | ||
|
|
cf199fec52 | ||
|
|
165c20c2c4 | ||
|
|
625c6ba4c7 | ||
|
|
a32bede701 | ||
|
|
8ff5c8874f | ||
|
|
c5d38fc262 | ||
|
|
6b71970520 | ||
|
|
0209e111f6 | ||
|
|
dc01af7723 | ||
|
|
5435d0412f | ||
|
|
922ac25f64 | ||
|
|
aed53d6c5a | ||
|
|
61cdb9f36a | ||
|
|
1acd042c85 | ||
|
|
572712d82a | ||
|
|
d1697a7556 | ||
|
|
c8c6e9ecd9 | ||
|
|
90f3e4cf05 | ||
|
|
7bd8bf58bb | ||
|
|
1190d3f442 | ||
|
|
0e4f5cfbab | ||
|
|
f1c8db9f8c | ||
|
|
2c9abbd554 | ||
|
|
2305ae5d8c | ||
|
|
dec54bd0ba | ||
|
|
aade369737 | ||
|
|
2a5e042c70 | ||
|
|
1dc4c8c727 | ||
|
|
7ca035db88 | ||
|
|
a460c42f94 | ||
|
|
d16743e728 | ||
|
|
4a29fa8caf | ||
|
|
250bb54dba | ||
|
|
847d05d0b4 | ||
|
|
8315aa03fc | ||
|
|
b7a4c480d6 | ||
|
|
9a35faaa29 | ||
|
|
fbe2e28911 | ||
|
|
84968e25f3 | ||
|
|
10fd0b7b55 | ||
|
|
4a46dc6e5c | ||
|
|
0ec55604c0 | ||
|
|
500007c9ed | ||
|
|
f75abba013 | ||
|
|
dea113b428 | ||
|
|
6abc406a69 | ||
|
|
dcbe723bc5 | ||
|
|
33c98a28ac | ||
|
|
b2ddddfb20 | ||
|
|
c24367ebb9 | ||
|
|
7397b35379 | ||
|
|
baee44c3de | ||
|
|
1f2e4ecc30 | ||
|
|
955e28006d | ||
|
|
bf0736eb1f | ||
|
|
3a5b97b7f1 | ||
|
|
45bf825066 | ||
|
|
4a18d5c89b | ||
|
|
174b26c497 | ||
|
|
5cacc82f61 | ||
|
|
29a90816ff | ||
|
|
4bea454021 | ||
|
|
8bfd0ae4c4 | ||
|
|
378943ce67 | ||
|
|
c65d409afd | ||
|
|
ed1bbe2cad | ||
|
|
b0b3d09063 | ||
|
|
0ede2af7a0 | ||
|
|
e8d23f7811 | ||
|
|
907cd7217e | ||
|
|
7c402e5af3 | ||
|
|
b8d78a5520 | ||
|
|
dfa5862960 | ||
|
|
4276908f51 | ||
|
|
be23b71e87 | ||
|
|
f851acbfff | ||
|
|
78ef9b0205 | ||
|
|
ed9b0e5cba | ||
|
|
752c1a0ce9 | ||
|
|
cc30415d0c | ||
|
|
03e16611a3 | ||
|
|
8e2f3c1c83 | ||
|
|
b6d63b2516 | ||
|
|
e6b88d02bd | ||
|
|
125060ca63 | ||
|
|
b4baca9261 | ||
|
|
6342b6e332 | ||
|
|
a6dc77822b | ||
|
|
59bc67052b | ||
|
|
c090562828 | ||
|
|
69e2ec63c5 | ||
|
|
f610a516a0 | ||
|
|
2e51a4caa3 | ||
|
|
c6fa97a6d6 | ||
|
|
24d7159abd | ||
|
|
7978dc989d | ||
|
|
d99e6b5014 | ||
|
|
2cf40fc2b8 | ||
|
|
260d08b814 | ||
|
|
53dd05d8f6 | ||
|
|
fbe7055370 | ||
|
|
a5b386205f | ||
|
|
916bcab28e | ||
|
|
c7373c3dee | ||
|
|
9f2c8eb2a1 | ||
|
|
65300dcfb0 | ||
|
|
9ddc574f9a | ||
|
|
2dd9e67874 | ||
|
|
f93b03a5e6 | ||
|
|
55a47cd30f | ||
|
|
5792219d1d | ||
|
|
293c58c1e7 | ||
|
|
9f375a752e | ||
|
|
04dc5a9ca6 | ||
|
|
ae6cb5483e | ||
|
|
a168ec1d27 | ||
|
|
2a35144327 | ||
|
|
7207eca1ee | ||
|
|
9c34782478 | ||
|
|
20e6d22709 | ||
|
|
24dd0c61ef | ||
|
|
565c15363c | ||
|
|
ed67f7b7a7 | ||
|
|
6ea8d138d3 | ||
|
|
4159ac43aa | ||
|
|
419b09b053 | ||
|
|
88530f6b76 | ||
|
|
a8cb8177f6 | ||
|
|
277f8a34f4 | ||
|
|
4dde470865 | ||
|
|
ab08405984 | ||
|
|
b81fde02aa | ||
|
|
57dd2ea808 | ||
|
|
7043fa702f | ||
|
|
f98d2e5cc1 | ||
|
|
1a5538251f | ||
|
|
f4ddbb5ad1 | ||
|
|
74bf705ea8 | ||
|
|
676cd3a283 | ||
|
|
c6ead3cdd3 | ||
|
|
2d53648ce7 | ||
|
|
64ca6ac26b | ||
|
|
4fe4c00eca | ||
|
|
376838a606 | ||
|
|
d768a816aa | ||
|
|
766e0cb7d1 | ||
|
|
6a6b0c8b51 | ||
|
|
e24b01cc6f | ||
|
|
7f9ef5621a | ||
|
|
d7fc9ffc51 | ||
|
|
39348038df | ||
|
|
9472baae0d | ||
|
|
ae17b9ecd5 | ||
|
|
74096890ba | ||
|
|
889c2282a5 | ||
|
|
dca30c44f5 | ||
|
|
f2c358c6ce | ||
|
|
2ab42de1ec | ||
|
|
ac2024ccbf | ||
|
|
93164a7d64 | ||
|
|
ecff2e5ce1 | ||
|
|
c9d630dab6 | ||
|
|
d135906dbc | ||
|
|
9f427a52cb | ||
|
|
5a39d3a838 | ||
|
|
013f3d999f | ||
|
|
64d30d7adc | ||
|
|
7062cb56a9 | ||
|
|
9d57828d66 | ||
|
|
9ed8dee71b | ||
|
|
4692b3345d | ||
|
|
e59fb00735 | ||
|
|
9275853084 | ||
|
|
0c81aa29f9 | ||
|
|
01d2e27a2b | ||
|
|
dd7aadf7b2 | ||
|
|
b2fdf501c5 | ||
|
|
345e515735 | ||
|
|
945982b0b2 | ||
|
|
18ad9cbd10 | ||
|
|
f433a75569 | ||
|
|
b05389c825 | ||
|
|
68875fdf32 | ||
|
|
3393e0c02c | ||
|
|
a149b2466e | ||
|
|
13e230d505 | ||
|
|
80b3d7a3c9 | ||
|
|
4bd48de60c | ||
|
|
2eab92f8e3 | ||
|
|
2bbd82cf24 | ||
|
|
1bfd3d7f58 | ||
|
|
cd77b3e88b | ||
|
|
8c93c4dd42 | ||
|
|
45d63a5408 | ||
|
|
decef971f4 | ||
|
|
a288aaefc4 | ||
|
|
eed56c77b4 | ||
|
|
346601bc32 | ||
|
|
5080fbbef0 | ||
|
|
b5b724348d | ||
|
|
c3ee90d8ca | ||
|
|
e1435034ae | ||
|
|
bf35c5dc7f | ||
|
|
c42d223ac2 | ||
|
|
d5654d2b20 | ||
|
|
a7508fec1a | ||
|
|
c31945e682 | ||
|
|
d3203b931e | ||
|
|
947f4e90c3 | ||
|
|
d184c7b271 | ||
|
|
913488c066 | ||
|
|
7fa27d9ac6 | ||
|
|
c341b9cce5 | ||
|
|
bbbf0d45ba | ||
|
|
114c402d9e | ||
|
|
d51519eba4 | ||
|
|
e650f9988b | ||
|
|
8ed8454115 | ||
|
|
6e101bebb1 | ||
|
|
4577b38d22 | ||
|
|
a8515e2d28 | ||
|
|
964e91052e | ||
|
|
4e55e69bff | ||
|
|
e501dbb658 | ||
|
|
20e505e4b7 | ||
|
|
291a26e6e3 | ||
|
|
0383911887 | ||
|
|
a5c5eb77b5 | ||
|
|
90d02be7c5 | ||
|
|
04221983ac | ||
|
|
dfda027ae8 | ||
|
|
21b5a79121 | ||
|
|
411a388c62 | ||
|
|
61c10d42f6 | ||
|
|
68ecfb69a5 | ||
|
|
e62fee8eb3 | ||
|
|
5566d49103 | ||
|
|
48337a4a35 | ||
|
|
2c5c4fca14 | ||
|
|
4fab95ed20 | ||
|
|
6c36ca4628 | ||
|
|
9c61c57896 | ||
|
|
a618011ca1 | ||
|
|
95eef4df79 | ||
|
|
ec1e714ac1 | ||
|
|
736d658080 | ||
|
|
aa2920584e | ||
|
|
9d13bfc258 | ||
|
|
e43633011c | ||
|
|
97027f7fb3 | ||
|
|
bf5adc9be4 | ||
|
|
7665b436f0 | ||
|
|
ffca7b85c2 | ||
|
|
eef2fa00d9 | ||
|
|
c55551ad7c | ||
|
|
c91b521111 | ||
|
|
deb35e3e2c | ||
|
|
5e2d3c9ec1 | ||
|
|
dda454434b | ||
|
|
b97d371ce0 | ||
|
|
a25c98ac73 | ||
|
|
fd47013111 | ||
|
|
b3aa469c21 | ||
|
|
981c0de27a | ||
|
|
1bfe9acbbf | ||
|
|
2d1e9ce753 | ||
|
|
19043426b9 | ||
|
|
6e21ce592e | ||
|
|
975c6efbe4 | ||
|
|
972491aece | ||
|
|
1a8ecda3ee | ||
|
|
d36c7b618d | ||
|
|
251431ff4f | ||
|
|
1a3052793e | ||
|
|
84fbc56fd0 | ||
|
|
4444ff7632 | ||
|
|
7770da4b41 | ||
|
|
7202a4d42b | ||
|
|
3fa29765fd | ||
|
|
b9e468c163 | ||
|
|
0172ad2902 | ||
|
|
d9aa352ff0 | ||
|
|
945ba0300d | ||
|
|
9e15cc606e | ||
|
|
e011160f3c | ||
|
|
9447da5065 | ||
|
|
387ed39f6d | ||
|
|
e50e5f9336 | ||
|
|
6f0d9950f3 | ||
|
|
4705ff7d6d | ||
|
|
36778eb231 | ||
|
|
c6dd154b3e | ||
|
|
74b5feea7b | ||
|
|
35cae95032 | ||
|
|
11a36aa96f | ||
|
|
9b0e97ae10 | ||
|
|
02ba02604c | ||
|
|
42ecf418f5 | ||
|
|
48ce525d16 | ||
|
|
3081e2ca73 | ||
|
|
48ae85b6ff | ||
|
|
82281ce47d | ||
|
|
4ecd2bafbb | ||
|
|
308b9ad8f0 | ||
|
|
73b408c242 | ||
|
|
51c9eb321a | ||
|
|
1657fca2f4 | ||
|
|
0d25aad90d | ||
|
|
b8c1cb1c2c | ||
|
|
6e1d44fd56 | ||
|
|
528ff4b451 | ||
|
|
f6c29ba3dc | ||
|
|
160f9b5bf6 | ||
|
|
53e7985c8d | ||
|
|
9102342795 | ||
|
|
c4488936b2 | ||
|
|
4e2b990734 | ||
|
|
6ca1418587 | ||
|
|
30dd06812e | ||
|
|
b29b89ef21 | ||
|
|
81ae27d56a | ||
|
|
f90bf72280 | ||
|
|
abcf7aa591 | ||
|
|
40b6d49387 | ||
|
|
497b4f92d2 | ||
|
|
28566b4966 | ||
|
|
b4b15f68c0 | ||
|
|
1eb1cf452b | ||
|
|
c549810def | ||
|
|
0d0ed9187a | ||
|
|
dfa81d9efb | ||
|
|
1dba06e7b0 | ||
|
|
daac87be95 | ||
|
|
e97359435e | ||
|
|
afce9bcca1 | ||
|
|
9c7baca820 | ||
|
|
618265e645 | ||
|
|
9728978b75 | ||
|
|
938c0bbae1 | ||
|
|
a0cd818831 | ||
|
|
31c4ab5401 | ||
|
|
1f65529824 | ||
|
|
5b3a6eedd1 | ||
|
|
6938440d68 | ||
|
|
57ec6c9bad | ||
|
|
7a09bc4068 | ||
|
|
deb15645a8 | ||
|
|
f0b358e8b9 | ||
|
|
dce2b5a8fc | ||
|
|
59d100d959 | ||
|
|
d497b5362b | ||
|
|
369b0abdc2 | ||
|
|
72240ab31a | ||
|
|
dc4e1ddc9f | ||
|
|
ff656346fa | ||
|
|
ca91057d50 | ||
|
|
8c1e7de6cb | ||
|
|
207886cd3a | ||
|
|
336d1ee733 | ||
|
|
bed2b769f5 | ||
|
|
26029d9c4c | ||
|
|
c64c888929 | ||
|
|
8d9db41880 | ||
|
|
4fae54a8e0 | ||
|
|
9f35928719 | ||
|
|
c5af032df5 | ||
|
|
8a898a6fcc | ||
|
|
9f827ded1c | ||
|
|
5daa9411a0 | ||
|
|
094d4019b8 | ||
|
|
1507f3abba | ||
|
|
30e8defe52 | ||
|
|
9f4dd3e3e3 | ||
|
|
8c00014d7e | ||
|
|
1cf12a6350 | ||
|
|
dc9461e23f | ||
|
|
72d57050df | ||
|
|
49d1f665a4 | ||
|
|
2c25edc4c1 | ||
|
|
d2f098b33d | ||
|
|
6f4f7f35f3 | ||
|
|
0a4fe6c8db | ||
|
|
7bba401d5d | ||
|
|
c73cff12f1 | ||
|
|
b32d93840e | ||
|
|
cb457849fd | ||
|
|
cb3c30059a | ||
|
|
20dc93e49e | ||
|
|
b620447dcc | ||
|
|
4ffd2ad1d3 | ||
|
|
acc9938ba5 | ||
|
|
f6d13ac8cf | ||
|
|
24cb653c6b | ||
|
|
6dfd3cf68e | ||
|
|
073775cbbb | ||
|
|
e995d5044e | ||
|
|
5b0a79a27a | ||
|
|
6747de655e | ||
|
|
91bad2b09e | ||
|
|
1244d5b713 | ||
|
|
c0ed5cd47b | ||
|
|
c8281fd38e | ||
|
|
fe8e6bff9b | ||
|
|
9caf25d144 | ||
|
|
348620c7ac | ||
|
|
30fc2ab92b | ||
|
|
5b5464d525 | ||
|
|
cd15a0528f | ||
|
|
7b52778eff | ||
|
|
162de2f2b5 | ||
|
|
f6e4af6fd7 | ||
|
|
32b76dcdac | ||
|
|
bcfd252052 | ||
|
|
32c452779e | ||
|
|
118b90c59e | ||
|
|
f6a61b140e | ||
|
|
75ece4b5cf | ||
|
|
724cca4178 | ||
|
|
5b3fdb0181 | ||
|
|
fcc3d0265d | ||
|
|
5356ea7cde | ||
|
|
06226df1a9 | ||
|
|
bf638ef026 | ||
|
|
07973d5db8 | ||
|
|
3b3f71121b | ||
|
|
47333a34d5 | ||
|
|
d92138f703 | ||
|
|
b2bf335327 | ||
|
|
33bec62a20 | ||
|
|
2e630b1847 | ||
|
|
002d3fe863 | ||
|
|
fb24311e7c | ||
|
|
90278430d9 | ||
|
|
bcd9d12a8d | ||
|
|
79363339b7 | ||
|
|
fbe2c6b33e | ||
|
|
fc11f47229 | ||
|
|
2b23d89d14 | ||
|
|
9cfa3cff54 | ||
|
|
6507653e72 | ||
|
|
7fe747d1eb | ||
|
|
32567c9f3b | ||
|
|
4f3d52fedc | ||
|
|
8321bab39c | ||
|
|
989238802a | ||
|
|
9051fc538f | ||
|
|
03fd7f27db | ||
|
|
45d6a15ae9 | ||
|
|
6c6ca18664 | ||
|
|
97fe2b40c1 | ||
|
|
f689ab5017 | ||
|
|
edb7cac271 | ||
|
|
81d87a2a28 | ||
|
|
7366f0b304 | ||
|
|
1d8fa09c80 | ||
|
|
e085e6c84c | ||
|
|
008fa4584d | ||
|
|
c8c49133d9 | ||
|
|
961f1dea06 | ||
|
|
1700426256 | ||
|
|
aa7f5baad2 | ||
|
|
45acdd6f6d | ||
|
|
8b354e776b | ||
|
|
868f5e44ca | ||
|
|
4e5fdd11ea | ||
|
|
d552a3391a | ||
|
|
d023b4e2dd | ||
|
|
fa79cc9c23 | ||
|
|
06daa75fb9 | ||
|
|
ffa304c838 | ||
|
|
df21765a3e | ||
|
|
5a6ae115f8 | ||
|
|
5e5df40b9b | ||
|
|
6d4943e81f | ||
|
|
57cffe901f | ||
|
|
a758f61793 | ||
|
|
b3b35df2a2 | ||
|
|
5ad50246fc | ||
|
|
d89b895cfd | ||
|
|
d793c292cb | ||
|
|
57749b1b9f | ||
|
|
1cdb7854a5 | ||
|
|
704d33b347 | ||
|
|
b2a7515ee8 | ||
|
|
f4f2b52995 | ||
|
|
c7d5edbf5e | ||
|
|
d8f07f1674 | ||
|
|
78bfb45b07 | ||
|
|
6ad4d60555 | ||
|
|
2fad8aa209 | ||
|
|
74397d45b2 | ||
|
|
c8ca769d3b | ||
|
|
25d42c17e3 | ||
|
|
a377811f15 | ||
|
|
ef1b6b2cf2 | ||
|
|
1699389a46 | ||
|
|
ad8ee3d7d1 | ||
|
|
39f0a4d8e9 | ||
|
|
15a9821cc2 | ||
|
|
53e97e7433 | ||
|
|
bc0ecd202a | ||
|
|
b307daa23f | ||
|
|
4c95b1bfda | ||
|
|
9359fc5ff2 | ||
|
|
a238d7d1eb | ||
|
|
0e92313331 | ||
|
|
3e719c99f5 | ||
|
|
2a4d0dcb89 | ||
|
|
2e155fde39 | ||
|
|
9a8c8cb22e | ||
|
|
04aa7441ab | ||
|
|
28dc54f6d9 | ||
|
|
a1e1165200 | ||
|
|
ddba003d5e | ||
|
|
e59d9a34c9 | ||
|
|
9e198c4bd0 | ||
|
|
7eceffbfef | ||
|
|
8043f01b13 | ||
|
|
41c0f68630 | ||
|
|
2c627637c5 | ||
|
|
58f4b3511e | ||
|
|
93fac08ec3 | ||
|
|
23c3bee970 | ||
|
|
73ff97ad76 | ||
|
|
0d8ffc2007 | ||
|
|
a32f7fb832 | ||
|
|
496cf69e40 | ||
|
|
eb17330837 | ||
|
|
2708603bb4 | ||
|
|
e4f1cda7de | ||
|
|
4359b88bbe | ||
|
|
c079fde3f7 | ||
|
|
6e94156199 | ||
|
|
1f67a3a985 | ||
|
|
4cba294d79 | ||
|
|
e642fd7a1c | ||
|
|
5448e6739c | ||
|
|
f0389d8d37 | ||
|
|
a5313cf360 | ||
|
|
b26c45b033 | ||
|
|
986093affa | ||
|
|
f88e0acb0e | ||
|
|
aed461b431 | ||
|
|
8bbd0e826c | ||
|
|
40c45f86d4 | ||
|
|
a0b7277724 | ||
|
|
54bc369ad7 | ||
|
|
2d3855fc6e | ||
|
|
1cd47f5f6e | ||
|
|
675564835c | ||
|
|
2456cd58c4 | ||
|
|
43a107026d | ||
|
|
ef0498a00b | ||
|
|
f1784f2fd2 | ||
|
|
730f5752ff | ||
|
|
a88c73b43a | ||
|
|
a6d204e241 | ||
|
|
941baf6641 | ||
|
|
b41a614686 | ||
|
|
aac751832a | ||
|
|
52a08e90d1 | ||
|
|
6b5f0458fe | ||
|
|
b52a2738d4 | ||
|
|
10f99d7b77 | ||
|
|
593222afe1 | ||
|
|
7b1856e5a1 | ||
|
|
3d5d81bf39 | ||
|
|
50f06b46f4 | ||
|
|
be6076c0ad | ||
|
|
6125e07d79 | ||
|
|
d5b8c46499 | ||
|
|
7805e23588 | ||
|
|
9117b9d17a | ||
|
|
e274c8fb72 | ||
|
|
e8dbd66e2b | ||
|
|
8b9b23603f | ||
|
|
aefb9dc5e5 | ||
|
|
a8c1b19a31 | ||
|
|
29c8d2a54a | ||
|
|
87827be0c2 | ||
|
|
e4572e5210 | ||
|
|
3e8e12a6b6 | ||
|
|
5ddbb8f41a | ||
|
|
3c44e92bcb | ||
|
|
5e8d95f590 | ||
|
|
2156704924 | ||
|
|
4e49aa0ca3 | ||
|
|
d5d1c53735 | ||
|
|
1aac5c0ee8 | ||
|
|
4434328b0a | ||
|
|
9b2cfb890c | ||
|
|
b2f364ec62 | ||
|
|
b7aeb4c9b5 | ||
|
|
370f48da2a | ||
|
|
32def77ace | ||
|
|
531c81ece8 | ||
|
|
73582b8117 | ||
|
|
5c33091cfa | ||
|
|
56327ebe6a | ||
|
|
e0031b1c78 | ||
|
|
b2ac5cb2d0 | ||
|
|
6757ef89b3 | ||
|
|
bf6eea6536 | ||
|
|
ec4346f6f9 | ||
|
|
e42ff486a8 | ||
|
|
bc9058d041 | ||
|
|
4a276f3039 | ||
|
|
acf47d8f24 | ||
|
|
f62d1ea3d5 | ||
|
|
f923bba73c | ||
|
|
e3738c49b8 | ||
|
|
41746da8c2 | ||
|
|
23b97c6bb5 | ||
|
|
4a7f7171f5 | ||
|
|
961092281f | ||
|
|
036b3f331b | ||
|
|
9ac5c355a2 | ||
|
|
3d0b604c14 | ||
|
|
257b2bfb6c | ||
|
|
90528846e8 | ||
|
|
32509c9731 | ||
|
|
d3f940833d | ||
|
|
b335e351d4 | ||
|
|
67bcde9ba8 | ||
|
|
169bfde4d4 | ||
|
|
0a7f291268 | ||
|
|
0c2c2e71a6 | ||
|
|
d1d746afb4 | ||
|
|
db6e41f0ed | ||
|
|
5b2b60ae98 | ||
|
|
c90a1ae0c9 | ||
|
|
c679fb298e | ||
|
|
17c7cad545 | ||
|
|
164c263b5c | ||
|
|
a9bb9d0eb4 | ||
|
|
cc6688d796 | ||
|
|
9b1f24df3d | ||
|
|
595e804ae3 | ||
|
|
b381e9b952 | ||
|
|
28418076b2 | ||
|
|
abdfdb029e | ||
|
|
8465b81d50 | ||
|
|
ed65b6e512 | ||
|
|
d793544518 | ||
|
|
53480a673b | ||
|
|
ad187f8905 | ||
|
|
2280f82fc6 | ||
|
|
e6714faffb | ||
|
|
af8f2bb174 | ||
|
|
d7501c16bf | ||
|
|
804196a418 | ||
|
|
50d70c01d6 | ||
|
|
9fc601cfbb | ||
|
|
fed5333248 | ||
|
|
3d1dab4404 | ||
|
|
29c2fd46d2 | ||
|
|
a3d5cdb07c | ||
|
|
d99c0f6b4a | ||
|
|
43f21e62aa | ||
|
|
50425bc137 | ||
|
|
0c690586e0 | ||
|
|
bc8c5fe58d | ||
|
|
0cc0db32e3 | ||
|
|
d68f7641a3 | ||
|
|
4fcbaa3dd9 | ||
|
|
5e56584285 | ||
|
|
ca26ccb083 | ||
|
|
3e8b713b06 | ||
|
|
13eca7d782 | ||
|
|
af3d4e1b02 | ||
|
|
80afb40ae3 | ||
|
|
3333428b44 | ||
|
|
a131de9bb2 | ||
|
|
0ddd002f60 | ||
|
|
e7209103e6 | ||
|
|
53f062d050 | ||
|
|
b5b65403a4 | ||
|
|
1a3914fe0c | ||
|
|
b7e3cb31a5 | ||
|
|
9769137a43 | ||
|
|
c0688f1aef | ||
|
|
6c29853bf2 | ||
|
|
2e9802b7a7 | ||
|
|
7483896e15 | ||
|
|
4b4f249e0d | ||
|
|
196dcf93bc | ||
|
|
2c11ec308b | ||
|
|
e5eb96c83a | ||
|
|
54ed003ace | ||
|
|
f18e10253d | ||
|
|
c9add317a9 | ||
|
|
6d1741030b | ||
|
|
b8dc932c05 | ||
|
|
17f8d8db61 | ||
|
|
38437fa135 | ||
|
|
82f35daaaf | ||
|
|
b529bba4bf | ||
|
|
dde33ea9c3 | ||
|
|
cb0d89705b | ||
|
|
f49353b42f | ||
|
|
573c61dcde | ||
|
|
51f38e6c2d | ||
|
|
2de213732a | ||
|
|
3798c36686 | ||
|
|
209abea1db | ||
|
|
250705e7b5 | ||
|
|
5a96822f2c | ||
|
|
23b34259e0 | ||
|
|
11b6cb8aae | ||
|
|
a4bade7aac | ||
|
|
e322b5d167 | ||
|
|
01af4edcfe | ||
|
|
ff0945cbdc | ||
|
|
d5ec7d66a8 | ||
|
|
dc0aebabe6 | ||
|
|
52828ca214 | ||
|
|
757e9886a0 | ||
|
|
f45e8c7bdd | ||
|
|
ea904b4074 | ||
|
|
ec6158d029 | ||
|
|
4386445c18 | ||
|
|
a585aa6750 | ||
|
|
2475a52061 | ||
|
|
001dfac061 | ||
|
|
1b37c55e26 | ||
|
|
3442781798 | ||
|
|
c9d3f123a6 | ||
|
|
d069a4d15d | ||
|
|
f1ad8fb627 | ||
|
|
d7406b1528 | ||
|
|
02ce897e80 | ||
|
|
0bd9d3a60e | ||
|
|
b4c81fb6db | ||
|
|
0f566bda2b | ||
|
|
f97a8149cd | ||
|
|
f4b6a3e9c0 | ||
|
|
7dfae89768 | ||
|
|
d41ca3f0e2 | ||
|
|
65fc4c55be | ||
|
|
5135d6b985 | ||
|
|
2202edeff0 | ||
|
|
c8f759ec74 | ||
|
|
5fda10c6f1 | ||
|
|
11ba084e1b | ||
|
|
cddd00166c | ||
|
|
0190aa7353 | ||
|
|
1546de87f0 | ||
|
|
affffaed3d | ||
|
|
0c644f1462 | ||
|
|
a2da5c7daa | ||
|
|
c155d83f5b | ||
|
|
5a03e3ac3f | ||
|
|
08b2097967 | ||
|
|
15401859b5 | ||
|
|
6f24165170 | ||
|
|
a8afd9382c | ||
|
|
caddf00d78 | ||
|
|
e105098b3f | ||
|
|
9852e7e4d7 | ||
|
|
b855560192 | ||
|
|
f2f50efea3 | ||
|
|
2b3cd246e5 | ||
|
|
7171ade2c2 | ||
|
|
76ec9151d1 | ||
|
|
6c24dd9005 | ||
|
|
e323afb0ce | ||
|
|
1fd43fd86e | ||
|
|
3e70c81ed9 | ||
|
|
6e07229564 | ||
|
|
859d5eb2d7 | ||
|
|
29b0c4a01c | ||
|
|
b824f0f458 | ||
|
|
43ea53a04a | ||
|
|
fa07f00aaf | ||
|
|
dbb834ffeb | ||
|
|
8549a8a5dc | ||
|
|
887c250852 | ||
|
|
710c1c34d1 | ||
|
|
e16818108f | ||
|
|
0cb76e79df | ||
|
|
6cb419673e | ||
|
|
72d668c332 | ||
|
|
5ce4799a38 | ||
|
|
6178da0142 | ||
|
|
27713e3fc2 | ||
|
|
3492c47b18 | ||
|
|
43dc001b62 | ||
|
|
8280b43a62 | ||
|
|
85d9b02d16 | ||
|
|
bfd502f027 | ||
|
|
f1ed5fa827 | ||
|
|
5bb9e1b4d4 | ||
|
|
7de819237d | ||
|
|
6cfab29b71 | ||
|
|
55708796af | ||
|
|
7074f1df07 | ||
|
|
67d8ab07e6 | ||
|
|
4e63da0669 | ||
|
|
15b0a5651c | ||
|
|
4e66723517 | ||
|
|
3e53c86001 | ||
|
|
524e5b844b | ||
|
|
e1f09dfd84 | ||
|
|
f16411ccfd | ||
|
|
2bbcd45b05 | ||
|
|
fdc6c6ef08 | ||
|
|
6e87cc8da6 | ||
|
|
2d0b6c72b8 | ||
|
|
3e84046f90 | ||
|
|
cc1cb996f1 | ||
|
|
32fbeacdfb | ||
|
|
431aad3c15 | ||
|
|
0454f2c490 | ||
|
|
5f911774bf | ||
|
|
66b7e42790 | ||
|
|
6a419388fc | ||
|
|
abda7c1147 | ||
|
|
88b48dc680 | ||
|
|
661d35dfb2 | ||
|
|
f99c9daa39 | ||
|
|
019b3f3e5a | ||
|
|
d6584eba8c | ||
|
|
a379c433a3 | ||
|
|
006c7c6bb1 | ||
|
|
bd4a902a15 | ||
|
|
17ae5e9f13 | ||
|
|
baa5f52422 | ||
|
|
b3620451b2 | ||
|
|
d2f17d9615 | ||
|
|
561cbe5678 | ||
|
|
756d2074b8 | ||
|
|
c65db618bb | ||
|
|
8355647403 | ||
|
|
b839d73411 | ||
|
|
4563c1e043 | ||
|
|
11f35a036d | ||
|
|
d8646dab14 | ||
|
|
47b3cd98f2 | ||
|
|
27c7e53882 | ||
|
|
b2b28803fb | ||
|
|
8e92b1b9ce | ||
|
|
0f41ccf370 | ||
|
|
c44544a1d7 | ||
|
|
4e50f02638 | ||
|
|
174ea15647 | ||
|
|
18f8258a87 | ||
|
|
376bbb5887 | ||
|
|
2c8275409e | ||
|
|
892582b541 | ||
|
|
57b53c1b0a | ||
|
|
004c3ca521 | ||
|
|
f0f00f9272 | ||
|
|
a243c68736 | ||
|
|
467d9f2a34 | ||
|
|
226a94963a | ||
|
|
d7f0d147b1 | ||
|
|
26902b9aad | ||
|
|
3c69d6bec4 | ||
|
|
4f44677a41 | ||
|
|
88d9f669c5 | ||
|
|
22e1421672 | ||
|
|
5409414eff | ||
|
|
7134507de0 | ||
|
|
fe41d9853c | ||
|
|
d07692cd96 | ||
|
|
82ae57136b | ||
|
|
30baeaaeab | ||
|
|
87a0f4b92e | ||
|
|
1b08bcbfe3 | ||
|
|
346b1001eb | ||
|
|
b61a84c8e6 | ||
|
|
a543ea44bc | ||
|
|
b0dd3d1b94 | ||
|
|
461be68b75 | ||
|
|
21fb688d26 | ||
|
|
d8faad27b7 | ||
|
|
dab7075946 | ||
|
|
dfc8e96daa | ||
|
|
71d3eaf358 | ||
|
|
ef6b25be63 | ||
|
|
b452f43322 | ||
|
|
52891f832f | ||
|
|
9990cb75c1 | ||
|
|
a5cc69c7ae | ||
|
|
0b4b8ba64e | ||
|
|
268e78c305 | ||
|
|
c900a78c99 | ||
|
|
46ffb2dc97 | ||
|
|
10acacb3bf | ||
|
|
aab790a656 | ||
|
|
1319aad994 | ||
|
|
3c0ce01cea | ||
|
|
9fcbefebdb | ||
|
|
017d2a887f | ||
|
|
0416482605 | ||
|
|
0f17424918 | ||
|
|
55ed10db21 | ||
|
|
3877b6bfe9 | ||
|
|
a0f32454b6 | ||
|
|
6fda4d7e5d | ||
|
|
36a252ea46 | ||
|
|
a31a195246 | ||
|
|
5f590d2218 | ||
|
|
791b7bc715 | ||
|
|
19ae090787 | ||
|
|
db3076621b | ||
|
|
9ae5743515 | ||
|
|
c184b140df | ||
|
|
9d80aa7e3f | ||
|
|
15671a90a9 | ||
|
|
0048464449 | ||
|
|
b422166ce0 | ||
|
|
81be661ae2 | ||
|
|
8681c66eec | ||
|
|
69a0034e50 | ||
|
|
c9a1778134 | ||
|
|
326794e9c6 | ||
|
|
2dd5ca1fbc | ||
|
|
3042945ac8 | ||
|
|
da29b0d335 | ||
|
|
6abbc68188 | ||
|
|
25f6c7fd8b | ||
|
|
1cf3571ea4 | ||
|
|
d769e7a58c | ||
|
|
fa3619f233 | ||
|
|
a414cbcad3 | ||
|
|
c6196da587 | ||
|
|
5d48762647 | ||
|
|
77e749405d | ||
|
|
9ccd4e224f | ||
|
|
1dad4f3672 | ||
|
|
59745556b4 | ||
|
|
fab4447179 | ||
|
|
417b8d4705 | ||
|
|
e614ec4769 | ||
|
|
a6b03f4138 | ||
|
|
809fa4cc59 | ||
|
|
463f448595 | ||
|
|
5cd0cf8cce | ||
|
|
49cb959494 | ||
|
|
783a73c47f | ||
|
|
99bf516908 | ||
|
|
a26c372cfc | ||
|
|
ed5ac22e5b | ||
|
|
3d11b8f896 | ||
|
|
2840dcd2a6 | ||
|
|
a9c5de8654 | ||
|
|
837685c522 |
77
.gitignore
vendored
Normal file
77
.gitignore
vendored
Normal file
@@ -0,0 +1,77 @@
|
|||||||
|
# Object files
|
||||||
|
*.o
|
||||||
|
|
||||||
|
# editor artefacts
|
||||||
|
*.swp
|
||||||
|
.#*
|
||||||
|
#*#
|
||||||
|
*~
|
||||||
|
|
||||||
|
# Top level excludes
|
||||||
|
/Makefile.bak
|
||||||
|
/Makefile
|
||||||
|
/*.a
|
||||||
|
/include
|
||||||
|
/*.pc
|
||||||
|
/rehash.time
|
||||||
|
|
||||||
|
# Most *.c files under test/ are symlinks
|
||||||
|
/test/*.c
|
||||||
|
# Apart from these
|
||||||
|
!/test/asn1test.c
|
||||||
|
!/test/methtest.c
|
||||||
|
!/test/dummytest.c
|
||||||
|
!/test/igetest.c
|
||||||
|
!/test/r160test.c
|
||||||
|
!/test/fips_algvs.c
|
||||||
|
|
||||||
|
/test/*.ss
|
||||||
|
/test/*.srl
|
||||||
|
/test/.rnd
|
||||||
|
/test/test*.pem
|
||||||
|
/test/newkey.pem
|
||||||
|
|
||||||
|
# Certificate symbolic links
|
||||||
|
*.0
|
||||||
|
|
||||||
|
# Links under apps
|
||||||
|
/apps/CA.pl
|
||||||
|
/apps/md4.c
|
||||||
|
|
||||||
|
|
||||||
|
# Auto generated headers
|
||||||
|
/crypto/buildinf.h
|
||||||
|
/crypto/opensslconf.h
|
||||||
|
|
||||||
|
# Auto generated assembly language source files
|
||||||
|
*.s
|
||||||
|
!/crypto/bn/asm/pa-risc2.s
|
||||||
|
!/crypto/bn/asm/pa-risc2W.s
|
||||||
|
|
||||||
|
# Executables
|
||||||
|
/apps/openssl
|
||||||
|
/test/sha256t
|
||||||
|
/test/sha512t
|
||||||
|
/test/*test
|
||||||
|
/test/fips_aesavs
|
||||||
|
/test/fips_desmovs
|
||||||
|
/test/fips_dhvs
|
||||||
|
/test/fips_drbgvs
|
||||||
|
/test/fips_dssvs
|
||||||
|
/test/fips_ecdhvs
|
||||||
|
/test/fips_ecdsavs
|
||||||
|
/test/fips_rngvs
|
||||||
|
/test/fips_test_suite
|
||||||
|
*.so*
|
||||||
|
*.dylib*
|
||||||
|
*.dll*
|
||||||
|
# Exceptions
|
||||||
|
!/test/bctest
|
||||||
|
!/crypto/des/times/486-50.sol
|
||||||
|
|
||||||
|
# Misc auto generated files
|
||||||
|
/tools/c_rehash
|
||||||
|
/test/evptests.txt
|
||||||
|
lib
|
||||||
|
Makefile.save
|
||||||
|
*.bak
|
||||||
25
ACKNOWLEDGMENTS
Normal file
25
ACKNOWLEDGMENTS
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
The OpenSSL project depends on volunteer efforts and financial support from
|
||||||
|
the end user community. That support comes in the form of donations and paid
|
||||||
|
sponsorships, software support contracts, paid consulting services
|
||||||
|
and commissioned software development.
|
||||||
|
|
||||||
|
Since all these activities support the continued development and improvement
|
||||||
|
of OpenSSL we consider all these clients and customers as sponsors of the
|
||||||
|
OpenSSL project.
|
||||||
|
|
||||||
|
We would like to identify and thank the following such sponsors for their past
|
||||||
|
or current significant support of the OpenSSL project:
|
||||||
|
|
||||||
|
Very significant support:
|
||||||
|
|
||||||
|
OpenGear: www.opengear.com
|
||||||
|
|
||||||
|
Significant support:
|
||||||
|
|
||||||
|
PSW Group: www.psw.net
|
||||||
|
|
||||||
|
Please note that we ask permission to identify sponsors and that some sponsors
|
||||||
|
we consider eligible for inclusion here have requested to remain anonymous.
|
||||||
|
|
||||||
|
Additional sponsorship or financial support is always welcome: for more
|
||||||
|
information please contact the OpenSSL Software Foundation.
|
||||||
@@ -148,7 +148,7 @@ eric (about to go bushwalking for the 4 day easter break :-)
|
|||||||
This would tend to cause memory overwrites since SSLv3 has
|
This would tend to cause memory overwrites since SSLv3 has
|
||||||
a maximum packet size of 16k. If your program uses
|
a maximum packet size of 16k. If your program uses
|
||||||
buffers <= 16k, you would probably never see this problem.
|
buffers <= 16k, you would probably never see this problem.
|
||||||
- Fixed a new errors that were cause by malloc() not returning
|
- Fixed a few errors that were cause by malloc() not returning
|
||||||
0 initialised memory..
|
0 initialised memory..
|
||||||
- SSL_OP_NETSCAPE_CA_DN_BUG was being switched on when using
|
- SSL_OP_NETSCAPE_CA_DN_BUG was being switched on when using
|
||||||
SSL_CTX_set_options(ssl_ctx,SSL_OP_ALL); which was a bad thing
|
SSL_CTX_set_options(ssl_ctx,SSL_OP_ALL); which was a bad thing
|
||||||
|
|||||||
368
Configure
368
Configure
@@ -10,7 +10,7 @@ use strict;
|
|||||||
|
|
||||||
# see INSTALL for instructions.
|
# see INSTALL for instructions.
|
||||||
|
|
||||||
my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimental-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [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> ...] [enable-<cipher> ...] [experimental-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [no-hw-xxx|no-hw] [[no-]threads] [[no-]shared] [[no-]zlib|zlib-dynamic] [no-asm] [no-dso] [no-krb5] [sctp] [386] [--prefix=DIR] [--openssldir=OPENSSLDIR] [--with-xxx[=vvv]] [--test-sanity] os/compiler[:flags]\n";
|
||||||
|
|
||||||
# Options:
|
# Options:
|
||||||
#
|
#
|
||||||
@@ -56,6 +56,7 @@ my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimenta
|
|||||||
# [no-]zlib [don't] compile support for zlib compression.
|
# [no-]zlib [don't] compile support for zlib compression.
|
||||||
# zlib-dynamic Like "zlib", but the zlib library is expected to be a shared
|
# zlib-dynamic Like "zlib", but the zlib library is expected to be a shared
|
||||||
# library and will be loaded in run-time by the OpenSSL library.
|
# library and will be loaded in run-time by the OpenSSL library.
|
||||||
|
# sctp include SCTP support
|
||||||
# 386 generate 80386 code
|
# 386 generate 80386 code
|
||||||
# no-sse2 disables IA-32 SSE2 code, above option implies no-sse2
|
# no-sse2 disables IA-32 SSE2 code, above option implies no-sse2
|
||||||
# no-<cipher> build without specified algorithm (rsa, idea, rc5, ...)
|
# no-<cipher> build without specified algorithm (rsa, idea, rc5, ...)
|
||||||
@@ -104,6 +105,8 @@ my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimenta
|
|||||||
|
|
||||||
my $gcc_devteam_warn = "-Wall -pedantic -DPEDANTIC -Wno-long-long -Wsign-compare -Wmissing-prototypes -Wshadow -Wformat -Werror -DCRYPTO_MDEBUG_ALL -DCRYPTO_MDEBUG_ABORT -DREF_CHECK -DOPENSSL_NO_DEPRECATED";
|
my $gcc_devteam_warn = "-Wall -pedantic -DPEDANTIC -Wno-long-long -Wsign-compare -Wmissing-prototypes -Wshadow -Wformat -Werror -DCRYPTO_MDEBUG_ALL -DCRYPTO_MDEBUG_ABORT -DREF_CHECK -DOPENSSL_NO_DEPRECATED";
|
||||||
|
|
||||||
|
my $strict_warnings = 0;
|
||||||
|
|
||||||
my $x86_gcc_des="DES_PTR DES_RISC1 DES_UNROLL";
|
my $x86_gcc_des="DES_PTR DES_RISC1 DES_UNROLL";
|
||||||
|
|
||||||
# MD2_CHAR slags pentium pros
|
# MD2_CHAR slags pentium pros
|
||||||
@@ -121,21 +124,24 @@ my $tlib="-lnsl -lsocket";
|
|||||||
my $bits1="THIRTY_TWO_BIT ";
|
my $bits1="THIRTY_TWO_BIT ";
|
||||||
my $bits2="SIXTY_FOUR_BIT ";
|
my $bits2="SIXTY_FOUR_BIT ";
|
||||||
|
|
||||||
my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o:des-586.o crypt586.o:aes-586.o:bf-586.o:md5-586.o:sha1-586.o sha256-586.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cmll-x86.o";
|
my $x86_asm="x86cpuid.o:bn-586.o co-586.o x86-mont.o x86-gf2m.o:des-586.o crypt586.o:aes-586.o vpaes-x86.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o:cmll-x86.o:ghash-x86.o:";
|
||||||
|
|
||||||
my $x86_elf_asm="$x86_asm:elf";
|
my $x86_elf_asm="$x86_asm:elf";
|
||||||
|
|
||||||
my $x86_64_asm="x86_64cpuid.o:x86_64-gcc.o x86_64-mont.o::aes-x86_64.o::md5-x86_64.o:sha1-x86_64.o sha256-x86_64.o sha512-x86_64.o::rc4-x86_64.o:::wp-x86_64.o:cmll-x86_64.o cmll_misc.o";
|
my $x86_64_asm="x86_64cpuid.o:x86_64-gcc.o x86_64-mont.o x86_64-mont5.o x86_64-gf2m.o modexp512-x86_64.o::aes-x86_64.o vpaes-x86_64.o bsaes-x86_64.o aesni-x86_64.o aesni-sha1-x86_64.o::md5-x86_64.o:sha1-x86_64.o sha256-x86_64.o sha512-x86_64.o::rc4-x86_64.o rc4-md5-x86_64.o:::wp-x86_64.o:cmll-x86_64.o cmll_misc.o:ghash-x86_64.o:";
|
||||||
my $ia64_asm="ia64cpuid.o:bn-ia64.o::aes_core.o aes_cbc.o aes-ia64.o::md5-ia64.o:sha1-ia64.o sha256-ia64.o sha512-ia64.o::rc4-ia64.o rc4_skey.o:::::void";
|
my $ia64_asm="ia64cpuid.o:bn-ia64.o ia64-mont.o::aes_core.o aes_cbc.o aes-ia64.o::md5-ia64.o:sha1-ia64.o sha256-ia64.o sha512-ia64.o::rc4-ia64.o rc4_skey.o:::::ghash-ia64.o::void";
|
||||||
my $sparcv9_asm="sparcv9cap.o sparccpuid.o:bn-sparcv9.o sparcv9-mont.o sparcv9a-mont.o:des_enc-sparc.o fcrypt_b.o:aes_core.o aes_cbc.o aes-sparcv9.o:::sha1-sparcv9.o sha256-sparcv9.o sha512-sparcv9.o:::::::void";
|
my $sparcv9_asm="sparcv9cap.o sparccpuid.o:bn-sparcv9.o sparcv9-mont.o sparcv9a-mont.o:des_enc-sparc.o fcrypt_b.o:aes_core.o aes_cbc.o aes-sparcv9.o:::sha1-sparcv9.o sha256-sparcv9.o sha512-sparcv9.o:::::::ghash-sparcv9.o::void";
|
||||||
my $sparcv8_asm=":sparcv8.o:des_enc-sparc.o fcrypt_b.o:::::::::::void";
|
my $sparcv8_asm=":sparcv8.o:des_enc-sparc.o fcrypt_b.o:::::::::::::void";
|
||||||
my $alpha_asm="alphacpuid.o:bn_asm.o alpha-mont.o::::::::::::void";
|
my $alpha_asm="alphacpuid.o:bn_asm.o alpha-mont.o:::::sha1-alpha.o:::::::ghash-alpha.o::void";
|
||||||
my $mips3_asm=":bn-mips3.o::::::::::::void";
|
my $mips32_asm=":bn-mips.o::aes_cbc.o aes-mips.o:::sha1-mips.o sha256-mips.o::::::::";
|
||||||
my $s390x_asm="s390xcpuid.o:bn-s390x.o s390x-mont.o::aes-s390x.o:::sha1-s390x.o sha256-s390x.o sha512-s390x.o::rc4-s390x.o:::::void";
|
my $mips64_asm=":bn-mips.o mips-mont.o::aes_cbc.o aes-mips.o:::sha1-mips.o sha256-mips.o sha512-mips.o::::::::";
|
||||||
my $armv4_asm=":bn_asm.o armv4-mont.o::aes_cbc.o aes-armv4.o:::sha1-armv4-large.o sha256-armv4.o sha512-armv4.o:::::::void";
|
my $s390x_asm="s390xcap.o s390xcpuid.o:bn-s390x.o s390x-mont.o s390x-gf2m.o::aes-s390x.o aes-ctr.o aes-xts.o:::sha1-s390x.o sha256-s390x.o sha512-s390x.o::rc4-s390x.o:::::ghash-s390x.o:";
|
||||||
my $ppc32_asm="ppccpuid.o:bn-ppc.o::aes_core.o aes_cbc.o aes-ppc.o:::sha1-ppc.o sha256-ppc.o::::::";
|
my $armv4_asm="armcap.o armv4cpuid.o:bn_asm.o armv4-mont.o armv4-gf2m.o::aes_cbc.o aes-armv4.o:::sha1-armv4-large.o sha256-armv4.o sha512-armv4.o:::::::ghash-armv4.o::void";
|
||||||
my $ppc64_asm="ppccpuid.o:bn-ppc.o ppc-mont.o::aes_core.o aes_cbc.o aes-ppc.o:::sha1-ppc.o sha256-ppc.o sha512-ppc.o::::::";
|
my $parisc11_asm="pariscid.o:bn_asm.o parisc-mont.o::aes_core.o aes_cbc.o aes-parisc.o:::sha1-parisc.o sha256-parisc.o sha512-parisc.o::rc4-parisc.o:::::ghash-parisc.o::32";
|
||||||
my $no_asm=":::::::::::::void";
|
my $parisc20_asm="pariscid.o:pa-risc2W.o parisc-mont.o::aes_core.o aes_cbc.o aes-parisc.o:::sha1-parisc.o sha256-parisc.o sha512-parisc.o::rc4-parisc.o:::::ghash-parisc.o::64";
|
||||||
|
my $ppc32_asm="ppccpuid.o ppccap.o:bn-ppc.o ppc-mont.o ppc64-mont.o::aes_core.o aes_cbc.o aes-ppc.o:::sha1-ppc.o sha256-ppc.o::::::::";
|
||||||
|
my $ppc64_asm="ppccpuid.o ppccap.o:bn-ppc.o ppc-mont.o ppc64-mont.o::aes_core.o aes_cbc.o aes-ppc.o:::sha1-ppc.o sha256-ppc.o sha512-ppc.o::::::::";
|
||||||
|
my $no_asm=":::::::::::::::void";
|
||||||
|
|
||||||
# As for $BSDthreads. Idea is to maintain "collective" set of flags,
|
# As for $BSDthreads. Idea is to maintain "collective" set of flags,
|
||||||
# which would cover all BSD flavors. -pthread applies to them all,
|
# which would cover all BSD flavors. -pthread applies to them all,
|
||||||
@@ -146,7 +152,7 @@ my $no_asm=":::::::::::::void";
|
|||||||
# seems to be sufficient?
|
# seems to be sufficient?
|
||||||
my $BSDthreads="-pthread -D_THREAD_SAFE -D_REENTRANT";
|
my $BSDthreads="-pthread -D_THREAD_SAFE -D_REENTRANT";
|
||||||
|
|
||||||
#config-string $cc : $cflags : $unistd : $thread_cflag : $sys_id : $lflags : $bn_ops : $cpuid_obj : $bn_obj : $des_obj : $aes_obj : $bf_obj : $md5_obj : $sha1_obj : $cast_obj : $rc4_obj : $rmd160_obj : $rc5_obj : $wp_obj : $cmll_obj : $dso_scheme : $shared_target : $shared_cflag : $shared_ldflag : $shared_extension : $ranlib : $arflags : $multilib
|
#config-string $cc : $cflags : $unistd : $thread_cflag : $sys_id : $lflags : $bn_ops : $cpuid_obj : $bn_obj : $des_obj : $aes_obj : $bf_obj : $md5_obj : $sha1_obj : $cast_obj : $rc4_obj : $rmd160_obj : $rc5_obj : $wp_obj : $cmll_obj : $modes_obj : $engines_obj : $dso_scheme : $shared_target : $shared_cflag : $shared_ldflag : $shared_extension : $ranlib : $arflags : $multilib
|
||||||
|
|
||||||
my %table=(
|
my %table=(
|
||||||
# File 'TABLE' (created by 'make TABLE') contains the data from this list,
|
# File 'TABLE' (created by 'make TABLE') contains the data from this list,
|
||||||
@@ -161,29 +167,36 @@ 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):::::bn86-elf.o co86-elf.o",
|
"debug-ben", "gcc:$gcc_devteam_warn -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DDEBUG_SAFESTACK -O2 -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","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:$gcc_devteam_warn -DBN_DEBUG -DCONF_DEBUG -DBN_CTX_DEBUG -DDEBUG_SAFESTACK -g3 -O2 -pipe::(unknown)::::::",
|
"debug-ben-debug", "gcc44:$gcc_devteam_warn -DBN_DEBUG -DCONF_DEBUG -DDEBUG_SAFESTACK -DDEBUG_UNUSED -g3 -O2 -pipe::(unknown)::::::",
|
||||||
|
"debug-ben-debug-64", "gcc:$gcc_devteam_warn -Wno-error=overlength-strings -DBN_DEBUG -DCONF_DEBUG -DDEBUG_SAFESTACK -DDEBUG_UNUSED -g3 -O3 -pipe::${BSDthreads}:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"debug-ben-macos", "cc:$gcc_devteam_warn -arch i386 -DBN_DEBUG -DCONF_DEBUG -DDEBUG_SAFESTACK -DDEBUG_UNUSED -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -O3 -DL_ENDIAN -g3 -pipe::(unknown)::-Wl,-search_paths_first::::",
|
||||||
|
"debug-ben-macos-gcc46", "gcc-mp-4.6:$gcc_devteam_warn -Wconversion -DBN_DEBUG -DCONF_DEBUG -DDEBUG_SAFESTACK -DDEBUG_UNUSED -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -O3 -DL_ENDIAN -g3 -pipe::(unknown)::::::",
|
||||||
|
"debug-ben-darwin64","cc:$gcc_devteam_warn -Wno-language-extension-token -Wno-extended-offsetof -arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"debug-ben-no-opt", "gcc: -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -DDEBUG_SAFESTACK -DCRYPTO_MDEBUG -Werror -DL_ENDIAN -DTERMIOS -Wall -g3::(unknown)::::::",
|
"debug-ben-no-opt", "gcc: -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -DDEBUG_SAFESTACK -DCRYPTO_MDEBUG -Werror -DL_ENDIAN -DTERMIOS -Wall -g3::(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-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 -DBIO_PAIR_DEBUG -DPEDANTIC -g -march=i486 -pedantic -Wshadow -Wall -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wundef -Wconversion::-D_REENTRANT:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}",
|
"debug-bodo", "gcc:$gcc_devteam_warn -Wno-error=overlength-strings -DBN_DEBUG -DBN_DEBUG_RAND -DCONF_DEBUG -DBIO_PAIR_DEBUG -m64 -DL_ENDIAN -DTERMIO -g -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
||||||
"debug-ulf", "gcc:-DTERMIOS -DL_ENDIAN -march=i486 -Wall -DBN_DEBUG -DBN_DEBUG_RAND -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -g -Wformat -Wshadow -Wmissing-prototypes -Wmissing-declarations:::CYGWIN32:::${no_asm}:win32:cygwin-shared:::.dll",
|
"debug-ulf", "gcc:-DTERMIOS -DL_ENDIAN -march=i486 -Wall -DBN_DEBUG -DBN_DEBUG_RAND -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -g -Wformat -Wshadow -Wmissing-prototypes -Wmissing-declarations:::CYGWIN32:::${no_asm}:win32:cygwin-shared:::.dll",
|
||||||
"debug-steve64", "gcc:$gcc_devteam_warn -m64 -DL_ENDIAN -DTERMIO -DCONF_DEBUG -DDEBUG_SAFESTACK -g -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK BF_PTR2 DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-steve64", "gcc:$gcc_devteam_warn -m64 -DL_ENDIAN -DTERMIO -DCONF_DEBUG -DDEBUG_SAFESTACK -Wno-overlength-strings -g::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-steve32", "gcc:$gcc_devteam_warn -m32 -DL_ENDIAN -DCONF_DEBUG -DDEBUG_SAFESTACK -g -pipe::-D_REENTRANT::-rdynamic -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC:-m32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-steve32", "gcc:$gcc_devteam_warn -m32 -DL_ENDIAN -DCONF_DEBUG -DDEBUG_SAFESTACK -g -pipe::-D_REENTRANT::-rdynamic -ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC:-m32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-steve-opt", "gcc:$gcc_devteam_warn -m64 -O3 -DL_ENDIAN -DTERMIO -DCONF_DEBUG -DDEBUG_SAFESTACK -g -DMD32_REG_T=int::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK BF_PTR2 DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-steve-opt", "gcc:$gcc_devteam_warn -m64 -O3 -DL_ENDIAN -DTERMIO -DCONF_DEBUG -DDEBUG_SAFESTACK -g::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-levitte-linux-elf","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_DEBUG -DBN_DEBUG_RAND -DCRYPTO_MDEBUG -DENGINE_CONF_DEBUG -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wundef -Wconversion -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 -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -ggdb -g3 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-levitte-linux-noasm","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_DEBUG -DBN_DEBUG_RAND -DCRYPTO_MDEBUG -DENGINE_CONF_DEBUG -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 -Wundef -Wconversion -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-levitte-linux-noasm","gcc:-DLEVITTE_DEBUG -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DOPENSSL_NO_ASM -DL_ENDIAN -ggdb -g3 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-levitte-linux-elf-extreme","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_DEBUG -DBN_DEBUG_RAND -DCRYPTO_MDEBUG -DENGINE_CONF_DEBUG -DL_ENDIAN -DTERMIO -D_POSIX_SOURCE -DPEDANTIC -ggdb -g3 -mcpu=i486 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wundef -Wconversion -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_DEBUG -DBN_DEBUG_RAND -DCRYPTO_MDEBUG -DENGINE_CONF_DEBUG -DL_ENDIAN -DTERMIO -DPEDANTIC -ggdb -g3 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wundef -Wconversion -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_DEBUG -DBN_DEBUG_RAND -DCRYPTO_MDEBUG -DENGINE_CONF_DEBUG -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 -Wno-long-long -Wundef -Wconversion -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-levitte-linux-noasm-extreme","gcc:-DLEVITTE_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_DEBUG -DBN_DEBUG_RAND -DCRYPTO_MDEBUG -DENGINE_CONF_DEBUG -DOPENSSL_NO_ASM -DL_ENDIAN -DTERMIO -DPEDANTIC -ggdb -g3 -pedantic -ansi -Wall -W -Wundef -Wshadow -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wundef -Wconversion -pipe::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-geoff32","gcc:-DBN_DEBUG -DBN_DEBUG_RAND -DBN_STRICT -DPURIFY -DOPENSSL_NO_DEPRECATED -DOPENSSL_NO_ASM -DOPENSSL_NO_INLINE_ASM -DL_ENDIAN -DTERMIO -DPEDANTIC -DMD32_REG_T=int -O1 -ggdb2 -Wall -Werror -Wundef -pedantic -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wsign-compare -Wmissing-prototypes -Wmissing-declarations -Wno-long-long::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-geoff32","gcc:-DBN_DEBUG -DBN_DEBUG_RAND -DBN_STRICT -DPURIFY -DOPENSSL_NO_DEPRECATED -DOPENSSL_NO_ASM -DOPENSSL_NO_INLINE_ASM -DL_ENDIAN -DTERMIO -DPEDANTIC -O1 -ggdb2 -Wall -Werror -Wundef -pedantic -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wsign-compare -Wmissing-prototypes -Wmissing-declarations -Wno-long-long::-D_REENTRANT::-ldl:BN_LLONG:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-geoff64","gcc:-DBN_DEBUG -DBN_DEBUG_RAND -DBN_STRICT -DPURIFY -DOPENSSL_NO_DEPRECATED -DOPENSSL_NO_ASM -DOPENSSL_NO_INLINE_ASM -DL_ENDIAN -DTERMIO -DPEDANTIC -DMD32_REG_T=int -O1 -ggdb2 -Wall -Werror -Wundef -pedantic -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wsign-compare -Wmissing-prototypes -Wmissing-declarations -Wno-long-long::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-geoff64","gcc:-DBN_DEBUG -DBN_DEBUG_RAND -DBN_STRICT -DPURIFY -DOPENSSL_NO_DEPRECATED -DOPENSSL_NO_ASM -DOPENSSL_NO_INLINE_ASM -DL_ENDIAN -DTERMIO -DPEDANTIC -O1 -ggdb2 -Wall -Werror -Wundef -pedantic -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wsign-compare -Wmissing-prototypes -Wmissing-declarations -Wno-long-long::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"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 -march=i486 -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 -march=i486 -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 -march=i486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-linux-elf-noefence","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DBN_CTX_DEBUG -DCRYPTO_MDEBUG -DL_ENDIAN -DTERMIO -g -march=i486 -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"debug-linux-ia32-aes", "gcc:-DAES_EXPERIMENTAL -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:x86cpuid.o:bn-586.o co-586.o x86-mont.o:des-586.o crypt586.o:aes_x86core.o aes_cbc.o:bf-586.o:md5-586.o:sha1-586.o sha256-586.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o::elf:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"debug-linux-ia32-aes", "gcc:-DAES_EXPERIMENTAL -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:x86cpuid.o:bn-586.o co-586.o x86-mont.o:des-586.o crypt586.o:aes_x86core.o aes_cbc.o aesni-x86.o:bf-586.o:md5-586.o:sha1-586.o sha256-586.o sha512-586.o:cast-586.o:rc4-586.o:rmd-586.o:rc5-586.o:wp_block.o wp-mmx.o::ghash-x86.o::elf:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"debug-linux-generic32","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DTERMIO -g -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"debug-linux-generic64","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DTERMIO -g -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"debug-linux-x86_64","gcc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -m64 -DL_ENDIAN -DTERMIO -g -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
||||||
"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
|
||||||
@@ -191,8 +204,8 @@ my %table=(
|
|||||||
"cc", "cc:-O::(unknown)::::::",
|
"cc", "cc:-O::(unknown)::::::",
|
||||||
|
|
||||||
####VOS Configurations
|
####VOS Configurations
|
||||||
"vos-gcc","gcc:-O3 -Wall -D_POSIX_C_SOURCE=200112L -D_BSD -DB_ENDIAN::(unknown):VOS:-Wl,-map:BN_LLONG:${no_asm}:::::.so:",
|
"vos-gcc","gcc:-O3 -Wall -DOPENSSL_SYSNAME_VOS -D_POSIX_C_SOURCE=200112L -D_BSD -D_VOS_EXTENDED_NAMES -DB_ENDIAN::(unknown):VOS:-Wl,-map:BN_LLONG:${no_asm}:::::.so:",
|
||||||
"debug-vos-gcc","gcc:-O0 -g -Wall -D_POSIX_C_SOURCE=200112L -D_BSD -DB_ENDIAN -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG::(unknown):VOS:-Wl,-map:BN_LLONG:${no_asm}:::::.so:",
|
"debug-vos-gcc","gcc:-O0 -g -Wall -DOPENSSL_SYSNAME_VOS -D_POSIX_C_SOURCE=200112L -D_BSD -D_VOS_EXTENDED_NAMES -DB_ENDIAN -DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG::(unknown):VOS:-Wl,-map:BN_LLONG:${no_asm}:::::.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
|
||||||
@@ -209,11 +222,11 @@ my %table=(
|
|||||||
# actually recommend to consider using gcc shared build even with vendor
|
# actually recommend to consider using gcc shared build even with vendor
|
||||||
# compiler:-)
|
# compiler:-)
|
||||||
# <appro@fy.chalmers.se>
|
# <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 BF_PTR2 DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:solaris-shared:-fPIC:-m64 -shared -static-libgcc:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/64",
|
"solaris64-x86_64-gcc","gcc:-m64 -O3 -Wall -DL_ENDIAN::-D_REENTRANT::-lsocket -lnsl -ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:solaris-shared:-fPIC:-m64 -shared -static-libgcc:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/64",
|
||||||
|
|
||||||
#### 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:${no_asm}:dlfcn:solaris-shared:-KPIC:-G -dy -z text:.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:${no_asm}: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 BF_PTR2 DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:solaris-shared:-KPIC:-xarch=amd64 -G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/64",
|
"solaris64-x86_64-cc","cc:-fast -xarch=amd64 -xstrconst -Xa -DL_ENDIAN::-D_REENTRANT::-lsocket -lnsl -ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:solaris-shared:-KPIC:-xarch=amd64 -G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/64",
|
||||||
|
|
||||||
#### 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:${no_asm}: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:${no_asm}:dlfcn:solaris-shared:-fPIC:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
@@ -232,7 +245,7 @@ my %table=(
|
|||||||
"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:${no_asm}:dlfcn:solaris-shared:-KPIC:-G -dy -z text:.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:${no_asm}: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:${sparcv8_asm}: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:${sparcv8_asm}:dlfcn:solaris-shared:-KPIC:-G -dy -z text:.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:${sparcv9_asm}:dlfcn:solaris-shared:-KPIC:-G -dy -z text:.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:${sparcv9_asm}: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:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:solaris-shared:-KPIC:-xarch=v9 -G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):/usr/ccs/bin/ar rs::/64",
|
"solaris64-sparcv9-cc","cc:-xtarget=ultra -xarch=v9 -xO5 -xstrconst -xdepend -Xa -DB_ENDIAN::-D_REENTRANT:ULTRASPARC:-lsocket -lnsl -ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL BF_PTR:${sparcv9_asm}:dlfcn:solaris-shared:-KPIC:-xarch=v9 -G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/64",
|
||||||
####
|
####
|
||||||
"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:${sparcv8_asm}:dlfcn:solaris-shared:-KPIC:-G -dy -z text:.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:${sparcv8_asm}: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:${sparcv9_asm}: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:${sparcv9_asm}:dlfcn:solaris-shared:-KPIC:-G -dy -z text:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
@@ -243,16 +256,16 @@ my %table=(
|
|||||||
|
|
||||||
#### IRIX 5.x configs
|
#### IRIX 5.x configs
|
||||||
# -mips2 flag is added by ./config when appropriate.
|
# -mips2 flag is added by ./config when appropriate.
|
||||||
"irix-gcc","gcc:-O3 -DTERMIOS -DB_ENDIAN::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR RC4_CHUNK DES_UNROLL DES_RISC2 DES_PTR BF_PTR:${no_asm}:dlfcn:irix-shared:::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"irix-gcc","gcc:-O3 -DTERMIOS -DB_ENDIAN::(unknown):::BN_LLONG MD2_CHAR RC4_INDEX RC4_CHAR RC4_CHUNK DES_UNROLL DES_RISC2 DES_PTR BF_PTR:${mips32_asm}:o32: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:${no_asm}: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:${mips32_asm}:o32: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-cc -o32' manually.
|
# './Configure irix-cc -o32' manually.
|
||||||
"irix-mips3-gcc","gcc:-mabi=n32 -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_asm}:dlfcn:irix-shared::-mabi=n32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::32",
|
"irix-mips3-gcc","gcc:-mabi=n32 -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:${mips64_asm}:n32:dlfcn:irix-shared::-mabi=n32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::32",
|
||||||
"irix-mips3-cc", "cc:-n32 -mips3 -O2 -use_readonly_const -G0 -rdata_shared -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_asm}:dlfcn:irix-shared::-n32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::32",
|
"irix-mips3-cc", "cc:-n32 -mips3 -O2 -use_readonly_const -G0 -rdata_shared -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:${mips64_asm}:n32:dlfcn:irix-shared::-n32:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::32",
|
||||||
# N64 ABI builds.
|
# N64 ABI builds.
|
||||||
"irix64-mips4-gcc","gcc:-mabi=64 -mips4 -O3 -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE:::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:${mips3_asm}:dlfcn:irix-shared::-mabi=64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
"irix64-mips4-gcc","gcc:-mabi=64 -mips4 -O3 -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE:::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:${mips64_asm}:64:dlfcn:irix-shared::-mabi=64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
||||||
"irix64-mips4-cc", "cc:-64 -mips4 -O2 -use_readonly_const -G0 -rdata_shared -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE:::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:${mips3_asm}:dlfcn:irix-shared::-64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
"irix64-mips4-cc", "cc:-64 -mips4 -O2 -use_readonly_const -G0 -rdata_shared -DTERMIOS -DB_ENDIAN -DBN_DIV3W::-D_SGI_MP_SOURCE:::RC4_CHAR RC4_CHUNK DES_RISC2 DES_UNROLL SIXTY_FOUR_BIT_LONG:${mips64_asm}:64:dlfcn:irix-shared::-64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
||||||
|
|
||||||
#### Unified HP-UX ANSI C configs.
|
#### Unified HP-UX ANSI C configs.
|
||||||
# Special notes:
|
# Special notes:
|
||||||
@@ -285,17 +298,18 @@ my %table=(
|
|||||||
# 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::-D_REENTRANT::-ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1:${no_asm}:dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc-cc-o4","cc:-Ae +O4 +ESlit -z -DB_ENDIAN -DBN_DIV2W -DMD32_XARRAY::-D_REENTRANT::-ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1:${no_asm}:dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"hpux-parisc-gcc","gcc:-O3 -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1:${no_asm}:dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc-gcc","gcc:-O3 -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1:${no_asm}:dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"hpux-parisc2-gcc","gcc:-march=2.0 -O3 -DB_ENDIAN -D_REENTRANT::::-Wl,+s -ldld:SIXTY_FOUR_BIT RC4_CHAR RC4_CHUNK DES_PTR DES_UNROLL DES_RISC1::pa-risc2.o::::::::::::void:dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc1_1-gcc","gcc:-O3 -DB_ENDIAN -DBN_DIV2W::-D_REENTRANT::-Wl,+s -ldld:BN_LLONG DES_PTR DES_UNROLL DES_RISC1:${parisc11_asm}:dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa1.1",
|
||||||
"hpux64-parisc2-gcc","gcc:-O3 -DB_ENDIAN -D_REENTRANT::::-ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::pa-risc2W.o::::::::::::void:dlfcn:hpux-shared:-fpic:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa20_64",
|
"hpux-parisc2-gcc","gcc:-march=2.0 -O3 -DB_ENDIAN -D_REENTRANT::::-Wl,+s -ldld:SIXTY_FOUR_BIT RC4_CHAR RC4_CHUNK DES_PTR DES_UNROLL DES_RISC1:".eval{my $asm=$parisc20_asm;$asm=~s/2W\./2\./;$asm=~s/:64/:32/;$asm}.":dl:hpux-shared:-fPIC:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa20_32",
|
||||||
|
"hpux64-parisc2-gcc","gcc:-O3 -DB_ENDIAN -D_REENTRANT::::-ldl:SIXTY_FOUR_BIT_LONG MD2_CHAR RC4_INDEX RC4_CHAR DES_UNROLL DES_RISC1 DES_INT::pa-risc2W.o::::::::::::::void:dlfcn:hpux-shared:-fpic:-shared:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa20_64",
|
||||||
|
|
||||||
# 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:${no_asm}:dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"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:${no_asm}:dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"hpux-parisc1_0-cc","cc:+DAportable +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:${no_asm}:dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"hpux-parisc1_1-cc","cc:+DA1.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:${parisc11_asm}:dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa1.1",
|
||||||
"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::pa-risc2.o::::::::::::void: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:".eval{my $asm=$parisc20_asm;$asm=~s/2W\./2\./;$asm=~s/:64/:32/;$asm}.":dl:hpux-shared:+Z:-b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa20_32",
|
||||||
"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::pa-risc2W.o::::::::::::void:dlfcn:hpux-shared:+Z:+DD64 -b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa20_64",
|
"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:${parisc20_asm}:dlfcn:hpux-shared:+Z:+DD64 -b:.sl.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/pa20_64",
|
||||||
|
|
||||||
# HP/UX IA-64 targets
|
# HP/UX IA-64 targets
|
||||||
"hpux-ia64-cc","cc:-Ae +DD32 +O2 +Olit=all -z -DB_ENDIAN -D_REENTRANT::::-ldl:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX DES_UNROLL DES_RISC1 DES_INT:${ia64_asm}:dlfcn:hpux-shared:+Z:+DD32 -b:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/hpux32",
|
"hpux-ia64-cc","cc:-Ae +DD32 +O2 +Olit=all -z -DB_ENDIAN -D_REENTRANT::::-ldl:SIXTY_FOUR_BIT MD2_CHAR RC4_INDEX DES_UNROLL DES_RISC1 DES_INT:${ia64_asm}:dlfcn:hpux-shared:+Z:+DD32 -b:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/hpux32",
|
||||||
@@ -346,8 +360,22 @@ my %table=(
|
|||||||
"linux-ia64", "gcc:-DL_ENDIAN -DTERMIO -O3 -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-ia64", "gcc:-DL_ENDIAN -DTERMIO -O3 -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.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 DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.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 DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"linux-ia64-icc","icc:-DL_ENDIAN -DTERMIO -O2 -Wall -no_cpprt::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_INT:${ia64_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"linux-ia64-icc","icc:-DL_ENDIAN -DTERMIO -O2 -Wall -no_cpprt::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_RISC1 DES_INT:${ia64_asm}: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 BF_PTR2 DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
"linux-x86_64", "gcc:-m64 -DL_ENDIAN -DTERMIO -O3 -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
||||||
"linux-s390x", "gcc:-m64 -DB_ENDIAN -DTERMIO -O3 -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:${s390x_asm}:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
"linux64-s390x", "gcc:-m64 -DB_ENDIAN -DTERMIO -O3 -Wall::-D_REENTRANT::-ldl:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:${s390x_asm}:64:dlfcn:linux-shared:-fPIC:-m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::64",
|
||||||
|
#### So called "highgprs" target for z/Architecture CPUs
|
||||||
|
# "Highgprs" is kernel feature first implemented in Linux 2.6.32, see
|
||||||
|
# /proc/cpuinfo. The idea is to preserve most significant bits of
|
||||||
|
# general purpose registers not only upon 32-bit process context
|
||||||
|
# switch, but even on asynchronous signal delivery to such process.
|
||||||
|
# This makes it possible to deploy 64-bit instructions even in legacy
|
||||||
|
# application context and achieve better [or should we say adequate]
|
||||||
|
# performance. The build is binary compatible with linux-generic32,
|
||||||
|
# and the idea is to be able to install the resulting libcrypto.so
|
||||||
|
# alongside generic one, e.g. as /lib/highgprs/libcrypto.so.x.y, for
|
||||||
|
# ldconfig and run-time linker to autodiscover. Unfortunately it
|
||||||
|
# doesn't work just yet, because of couple of bugs in glibc
|
||||||
|
# sysdeps/s390/dl-procinfo.c affecting ldconfig and ld.so.1...
|
||||||
|
"linux32-s390x", "gcc:-m31 -Wa,-mzarch -DB_ENDIAN -DTERMIO -O3 -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$s390x_asm;$asm=~s/bn\-s390x\.o/bn_asm.o/;$asm}.":31:dlfcn:linux-shared:-fPIC:-m31:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):::/highgprs",
|
||||||
#### SPARC Linux setups
|
#### SPARC Linux setups
|
||||||
# Ray Miller <ray.miller@computing-services.oxford.ac.uk> has patiently
|
# Ray Miller <ray.miller@computing-services.oxford.ac.uk> has patiently
|
||||||
# assisted with debugging of following two configs.
|
# assisted with debugging of following two configs.
|
||||||
@@ -375,6 +403,11 @@ my %table=(
|
|||||||
"linux-alpha-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:${alpha_asm}",
|
"linux-alpha-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:${alpha_asm}",
|
||||||
"linux-alpha+bwx-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT:::SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:${alpha_asm}",
|
"linux-alpha+bwx-ccc","ccc:-fast -readonly_strings -DL_ENDIAN -DTERMIO::-D_REENTRANT:::SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC1 DES_UNROLL:${alpha_asm}",
|
||||||
|
|
||||||
|
# Android: linux-* but without -DTERMIO and pointers to headers and libs.
|
||||||
|
"android","gcc:-mandroid -I\$(ANDROID_DEV)/include -B\$(ANDROID_DEV)/lib -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${no_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"android-x86","gcc:-mandroid -I\$(ANDROID_DEV)/include -B\$(ANDROID_DEV)/lib -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:".eval{my $asm=${x86_elf_asm};$asm=~s/:elf/:android/;$asm}.":dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"android-armv7","gcc:-march=armv7-a -mandroid -I\$(ANDROID_DEV)/include -B\$(ANDROID_DEV)/lib -O3 -fomit-frame-pointer -Wall::-D_REENTRANT::-ldl:BN_LLONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL BF_PTR:${armv4_asm}:dlfcn:linux-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
#### *BSD [do see comment about ${BSDthreads} above!]
|
#### *BSD [do see comment about ${BSDthreads} above!]
|
||||||
"BSD-generic32","gcc:-DTERMIOS -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"BSD-generic32","gcc:-DTERMIOS -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG RC2_CHAR RC4_INDEX DES_INT DES_UNROLL:${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"BSD-x86", "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_asm}:a.out:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"BSD-x86", "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -Wall::${BSDthreads}:::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_asm}:a.out:dlfcn:bsd-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
@@ -388,7 +421,7 @@ my %table=(
|
|||||||
# triggered by RIPEMD160 code.
|
# triggered by RIPEMD160 code.
|
||||||
"BSD-sparc64", "gcc:-DB_ENDIAN -DTERMIOS -O3 -DMD32_REG_T=int -Wall::${BSDthreads}:::BN_LLONG RC2_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC2 BF_PTR:${sparcv9_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"BSD-sparc64", "gcc:-DB_ENDIAN -DTERMIOS -O3 -DMD32_REG_T=int -Wall::${BSDthreads}:::BN_LLONG RC2_CHAR RC4_CHUNK DES_INT DES_PTR DES_RISC2 BF_PTR:${sparcv9_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"BSD-ia64", "gcc:-DL_ENDIAN -DTERMIOS -O3 -Wall::${BSDthreads}:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_INT:${ia64_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"BSD-ia64", "gcc:-DL_ENDIAN -DTERMIOS -O3 -Wall::${BSDthreads}:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_UNROLL DES_INT:${ia64_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
"BSD-x86_64", "gcc:-DL_ENDIAN -DTERMIOS -O3 -DMD32_REG_T=int -Wall::${BSDthreads}:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"BSD-x86_64", "gcc:-DL_ENDIAN -DTERMIOS -O3 -Wall::${BSDthreads}:::SIXTY_FOUR_BIT_LONG RC4_CHUNK DES_INT DES_UNROLL:${x86_64_asm}:elf:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
"bsdi-elf-gcc", "gcc:-DPERL5 -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall::(unknown)::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
"bsdi-elf-gcc", "gcc:-DPERL5 -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall::(unknown)::-ldl:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
@@ -400,7 +433,8 @@ my %table=(
|
|||||||
|
|
||||||
# QNX
|
# QNX
|
||||||
"qnx4", "cc:-DL_ENDIAN -DTERMIO::(unknown):::${x86_gcc_des} ${x86_gcc_opts}:",
|
"qnx4", "cc:-DL_ENDIAN -DTERMIO::(unknown):::${x86_gcc_des} ${x86_gcc_opts}:",
|
||||||
"qnx6", "cc:-DL_ENDIAN -DTERMIOS::(unknown)::-lsocket:${x86_gcc_des} ${x86_gcc_opts}:",
|
"QNX6", "gcc:-DTERMIOS::::-lsocket::${no_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
"QNX6-i386", "gcc:-DL_ENDIAN -DTERMIOS -O2 -Wall::::-lsocket:${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:dlfcn:bsd-gcc-shared:-fPIC::.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
|
||||||
|
|
||||||
# BeOS
|
# BeOS
|
||||||
"beos-x86-r5", "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -mcpu=pentium -Wall::-D_REENTRANT:BEOS:-lbe -lnet:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:beos:beos-shared:-fPIC -DPIC:-shared:.so",
|
"beos-x86-r5", "gcc:-DL_ENDIAN -DTERMIOS -O3 -fomit-frame-pointer -mcpu=pentium -Wall::-D_REENTRANT:BEOS:-lbe -lnet:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${x86_elf_asm}:beos:beos-shared:-fPIC -DPIC:-shared:.so",
|
||||||
@@ -432,8 +466,8 @@ my %table=(
|
|||||||
"aix64-gcc","gcc:-maix64 -O -DB_ENDIAN::-pthread:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-maix64 -shared -Wl,-G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X64",
|
"aix64-gcc","gcc:-maix64 -O -DB_ENDIAN::-pthread:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-maix64 -shared -Wl,-G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X64",
|
||||||
# Below targets assume AIX 5. Idea is to effectively disregard $OBJECT_MODE
|
# Below targets assume AIX 5. Idea is to effectively disregard $OBJECT_MODE
|
||||||
# at build time. $OBJECT_MODE is respected at ./config stage!
|
# at build time. $OBJECT_MODE is respected at ./config stage!
|
||||||
"aix-cc", "cc:-q32 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded:AIX::BN_LLONG RC4_CHAR:${ppc32_asm}:aix32:dlfcn:aix-shared::-q32 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 32",
|
"aix-cc", "cc:-q32 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded -D_THREAD_SAFE:AIX::BN_LLONG RC4_CHAR:${ppc32_asm}:aix32:dlfcn:aix-shared::-q32 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 32",
|
||||||
"aix64-cc", "cc:-q64 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-q64 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 64",
|
"aix64-cc", "cc:-q64 -O -DB_ENDIAN -qmaxmem=16384 -qro -qroconst::-qthreaded -D_THREAD_SAFE:AIX::SIXTY_FOUR_BIT_LONG RC4_CHAR:${ppc64_asm}:aix64:dlfcn:aix-shared::-q64 -G:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)::-X 64",
|
||||||
|
|
||||||
#
|
#
|
||||||
# Cray T90 and similar (SDSC)
|
# Cray T90 and similar (SDSC)
|
||||||
@@ -484,19 +518,22 @@ my %table=(
|
|||||||
# Visual C targets
|
# Visual C targets
|
||||||
#
|
#
|
||||||
# Win64 targets, WIN64I denotes IA-64 and WIN64A - AMD64
|
# Win64 targets, WIN64I denotes IA-64 and WIN64A - AMD64
|
||||||
"VC-WIN64I","cl:-W3 -Gs0 -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_DEPRECATE:::WIN64I::SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:ia64cpuid.o:ia64.o::aes_core.o aes_cbc.o aes-ia64.o::md5-ia64.o:sha1-ia64.o sha256-ia64.o sha512-ia64.o:::::::ias:win32",
|
"VC-WIN64I","cl:-W3 -Gs0 -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_DEPRECATE:::WIN64I::SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:ia64cpuid.o:ia64.o ia64-mont.o::aes_core.o aes_cbc.o aes-ia64.o::md5-ia64.o:sha1-ia64.o sha256-ia64.o sha512-ia64.o:::::::ghash-ia64.o::ias:win32",
|
||||||
"VC-WIN64A","cl:-W3 -Gs0 -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_DEPRECATE:::WIN64A::SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:x86_64cpuid.o:bn_asm.o x86_64-mont.o::aes-x86_64.o::md5-x86_64.o:sha1-x86_64.o sha256-x86_64.o sha512-x86_64.o::rc4-x86_64.o:::wp-x86_64.o::ml64:win32",
|
"VC-WIN64A","cl:-W3 -Gs0 -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_DEPRECATE:::WIN64A::SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:".eval{my $asm=$x86_64_asm;$asm=~s/x86_64-gcc\.o/bn_asm.o/;$asm}.":auto:win32",
|
||||||
|
"debug-VC-WIN64I","cl:-W3 -Gs0 -Gy -Zi -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_DEPRECATE:::WIN64I::SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:ia64cpuid.o:ia64.o::aes_core.o aes_cbc.o aes-ia64.o::md5-ia64.o:sha1-ia64.o sha256-ia64.o sha512-ia64.o:::::::ghash-ia64.o::ias:win32",
|
||||||
|
"debug-VC-WIN64A","cl:-W3 -Gs0 -Gy -Zi -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -DUNICODE -D_UNICODE -D_CRT_SECURE_NO_DEPRECATE:::WIN64A::SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:".eval{my $asm=$x86_64_asm;$asm=~s/x86_64-gcc\.o/bn_asm.o/;$asm}.":auto:win32",
|
||||||
# x86 Win32 target defaults to ANSI API, if you want UNICODE, complement
|
# x86 Win32 target defaults to ANSI API, if you want UNICODE, complement
|
||||||
# 'perl Configure VC-WIN32' with '-DUNICODE -D_UNICODE'
|
# 'perl Configure VC-WIN32' with '-DUNICODE -D_UNICODE'
|
||||||
"VC-WIN32","cl:-W3 -WX -Gs0 -GF -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -D_CRT_SECURE_NO_DEPRECATE:::WIN32::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}:${x86_asm}:win32n:win32",
|
"VC-WIN32","cl:-W3 -Gs0 -GF -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -D_CRT_SECURE_NO_DEPRECATE:::WIN32::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}:${x86_asm}:win32n:win32",
|
||||||
# Unified CE target
|
# Unified CE target
|
||||||
|
"debug-VC-WIN32","cl:-W3 -WX -Gs0 -GF -Gy -Zi -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -D_CRT_SECURE_NO_DEPRECATE:::WIN32::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}:${x86_asm}:win32n:win32",
|
||||||
"VC-CE","cl::::WINCE::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}:${no_asm}:win32",
|
"VC-CE","cl::::WINCE::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}:${no_asm}:win32",
|
||||||
|
|
||||||
# Borland C++ 4.5
|
# Borland C++ 4.5
|
||||||
"BC-32","bcc32::::WIN32::BN_LLONG DES_PTR RC4_INDEX EXPORT_VAR_AS_FN:${no_asm}:win32",
|
"BC-32","bcc32::::WIN32::BN_LLONG DES_PTR RC4_INDEX EXPORT_VAR_AS_FN:${no_asm}:win32",
|
||||||
|
|
||||||
# MinGW
|
# MinGW
|
||||||
"mingw", "gcc:-mno-cygwin -DL_ENDIAN -fomit-frame-pointer -O3 -march=i486 -Wall:::MINGW32:-lws2_32 -lgdi32:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts} EXPORT_VAR_AS_FN:${x86_asm}:coff:win32:cygwin-shared:-D_WINDLL -DOPENSSL_USE_APPLINK:-mno-cygwin:.dll.a",
|
"mingw", "gcc:-mno-cygwin -DL_ENDIAN -DWIN32_LEAN_AND_MEAN -fomit-frame-pointer -O3 -march=i486 -Wall::-D_MT:MINGW32:-lws2_32 -lgdi32 -lcrypt32:BN_LLONG ${x86_gcc_des} ${x86_gcc_opts} EXPORT_VAR_AS_FN:${x86_asm}:coff:win32:cygwin-shared:-D_WINDLL -DOPENSSL_USE_APPLINK:-mno-cygwin:.dll.a",
|
||||||
# As for OPENSSL_USE_APPLINK. Applink makes it possible to use .dll
|
# As for OPENSSL_USE_APPLINK. Applink makes it possible to use .dll
|
||||||
# compiled with one compiler with application compiled with another
|
# compiled with one compiler with application compiled with another
|
||||||
# compiler. It's possible to engage Applink support in mingw64 build,
|
# compiler. It's possible to engage Applink support in mingw64 build,
|
||||||
@@ -504,7 +541,7 @@ my %table=(
|
|||||||
# handling, one can't seriously consider its binaries for using with
|
# handling, one can't seriously consider its binaries for using with
|
||||||
# non-mingw64 run-time environment. And as mingw64 is always consistent
|
# non-mingw64 run-time environment. And as mingw64 is always consistent
|
||||||
# with itself, Applink is never engaged and can as well be omitted.
|
# with itself, Applink is never engaged and can as well be omitted.
|
||||||
"mingw64", "gcc:-mno-cygwin -DL_ENDIAN -O3 -Wall -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE:::MINGW64:-lws2_32 -lgdi32:SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:${x86_64_asm}:mingw64:win32:cygwin-shared:-D_WINDLL:-mno-cygwin:.dll.a",
|
"mingw64", "gcc:-mno-cygwin -DL_ENDIAN -O3 -Wall -DWIN32_LEAN_AND_MEAN -DUNICODE -D_UNICODE::-D_MT:MINGW64:-lws2_32 -lgdi32 -lcrypt32:SIXTY_FOUR_BIT RC4_CHUNK_LL DES_INT EXPORT_VAR_AS_FN:${x86_64_asm}:mingw64:win32:cygwin-shared:-D_WINDLL:-mno-cygwin:.dll.a",
|
||||||
|
|
||||||
# UWIN
|
# UWIN
|
||||||
"UWIN", "cc:-DTERMIOS -DL_ENDIAN -O -Wall:::UWIN::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:win32",
|
"UWIN", "cc:-DTERMIOS -DL_ENDIAN -O -Wall:::UWIN::BN_LLONG ${x86_gcc_des} ${x86_gcc_opts}:${no_asm}:win32",
|
||||||
@@ -540,12 +577,14 @@ 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:${no_asm}::",
|
"rhapsody-ppc-cc","cc:-O3 -DB_ENDIAN::(unknown):MACOSX_RHAPSODY::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${no_asm}::",
|
||||||
"darwin-ppc-cc","cc:-arch ppc -O3 -DB_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"darwin-ppc-cc","cc:-arch ppc -O3 -DB_ENDIAN -Wa,-force_cpusubtype_ALL::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"darwin64-ppc-cc","cc:-arch ppc64 -O3 -DB_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc64_asm}:osx64:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"darwin64-ppc-cc","cc:-arch ppc64 -O3 -DB_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc64_asm}:osx64:dlfcn:darwin-shared:-fPIC -fno-common:-arch ppc64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"darwin-i386-cc","cc:-arch i386 -O3 -fomit-frame-pointer -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:${x86_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"darwin-i386-cc","cc:-arch i386 -O3 -fomit-frame-pointer -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:".eval{my $asm=$x86_asm;$asm=~s/cast\-586\.o//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"debug-darwin-i386-cc","cc:-arch i386 -g3 -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:${x86_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"debug-darwin-i386-cc","cc:-arch i386 -g3 -DL_ENDIAN::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:BN_LLONG RC4_INT RC4_CHUNK DES_UNROLL BF_PTR:${x86_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch i386 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -DMD32_REG_T=int -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK BF_PTR2 DES_INT DES_UNROLL:${x86_64_asm}:macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"darwin64-x86_64-cc","cc:-arch x86_64 -O3 -DL_ENDIAN -Wall::-D_REENTRANT:MACOSX:-Wl,-search_paths_first%:SIXTY_FOUR_BIT_LONG RC4_CHAR RC4_CHUNK DES_INT DES_UNROLL:".eval{my $asm=$x86_64_asm;$asm=~s/rc4\-[^:]+//;$asm}.":macosx:dlfcn:darwin-shared:-fPIC -fno-common:-arch x86_64 -dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
"debug-darwin-ppc-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DB_ENDIAN -g -Wall -O::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
"debug-darwin-ppc-cc","cc:-DBN_DEBUG -DREF_CHECK -DCONF_DEBUG -DCRYPTO_MDEBUG -DB_ENDIAN -g -Wall -O::-D_REENTRANT:MACOSX::BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${ppc32_asm}:osx32:dlfcn:darwin-shared:-fPIC:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
|
# iPhoneOS/iOS
|
||||||
|
"iphoneos-cross","llvm-gcc:-O3 -isysroot \$(CROSS_TOP)/SDKs/\$(CROSS_SDK) -fomit-frame-pointer -fno-common::-D_REENTRANT:iOS:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${no_asm}:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
|
||||||
|
|
||||||
##### A/UX
|
##### A/UX
|
||||||
"aux3-gcc","gcc:-O2 -DTERMIO::(unknown):AUX:-lbsd:RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::",
|
"aux3-gcc","gcc:-O2 -DTERMIO::(unknown):AUX:-lbsd:RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:::",
|
||||||
@@ -560,20 +599,28 @@ my %table=(
|
|||||||
"OS2-EMX", "gcc::::::::",
|
"OS2-EMX", "gcc::::::::",
|
||||||
|
|
||||||
##### VxWorks for various targets
|
##### VxWorks for various targets
|
||||||
|
"vxworks-ppc60x","ccppc:-D_REENTRANT -mrtp -mhard-float -mstrict-align -fno-implicit-fp -DPPC32_fp60x -O2 -fstrength-reduce -fno-builtin -fno-strict-aliasing -Wall -DCPU=PPC32 -DTOOL_FAMILY=gnu -DTOOL=gnu -I\$(WIND_BASE)/target/usr/h -I\$(WIND_BASE)/target/usr/h/wrn/coreip:::VXWORKS:-Wl,--defsym,__wrs_rtp_base=0xe0000000 -L \$(WIND_BASE)/target/usr/lib/ppc/PPC32/common:::::",
|
||||||
|
"vxworks-ppcgen","ccppc:-D_REENTRANT -mrtp -msoft-float -mstrict-align -O1 -fno-builtin -fno-strict-aliasing -Wall -DCPU=PPC32 -DTOOL_FAMILY=gnu -DTOOL=gnu -I\$(WIND_BASE)/target/usr/h -I\$(WIND_BASE)/target/usr/h/wrn/coreip:::VXWORKS:-Wl,--defsym,__wrs_rtp_base=0xe0000000 -L \$(WIND_BASE)/target/usr/lib/ppc/PPC32/sfcommon:::::",
|
||||||
"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-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::${no_asm}::::::ranlibmips:",
|
"vxworks-simlinux","ccpentium:-B\$(WIND_BASE)/host/\$(WIND_HOST_TYPE)/lib/gcc-lib/ -D_VSB_CONFIG_FILE=\"\$(WIND_BASE)/target/lib/h/config/vsbConfig.h\" -DL_ENDIAN -DCPU=SIMLINUX -DTOOL_FAMILY=gnu -DTOOL=gnu -fno-builtin -fno-defer-pop -DNO_STRINGS_H -I\$(WIND_BASE)/target/h -I\$(WIND_BASE)/target/h/wrn/coreip -DOPENSSL_NO_HW_PADLOCK:::VXWORKS:-r::${no_asm}::::::ranlibpentium:",
|
||||||
|
"vxworks-mips","ccmips:-mrtp -mips2 -O -G 0 -B\$(WIND_BASE)/host/\$(WIND_HOST_TYPE)/lib/gcc-lib/ -D_VSB_CONFIG_FILE=\"\$(WIND_BASE)/target/lib/h/config/vsbConfig.h\" -DCPU=MIPS32 -msoft-float -mno-branch-likely -DTOOL_FAMILY=gnu -DTOOL=gnu -fno-builtin -fno-defer-pop -DNO_STRINGS_H -I\$(WIND_BASE)/target/usr/h -I\$(WIND_BASE)/target/h/wrn/coreip::-D_REENTRANT:VXWORKS:-Wl,--defsym,__wrs_rtp_base=0xe0000000 -L \$(WIND_BASE)/target/usr/lib/mips/MIPSI32/sfcommon::${mips32_asm}:o32::::::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:::",
|
||||||
|
|
||||||
|
# uClinux
|
||||||
|
"uClinux-dist","$ENV{'CC'}:\$(CFLAGS)::-D_REENTRANT::\$(LDFLAGS) \$(LDLIBS):BN_LLONG:${no_asm}:$ENV{'LIBSSL_dlfcn'}:linux-shared:-fPIC:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):$ENV{'RANLIB'}::",
|
||||||
|
"uClinux-dist64","$ENV{'CC'}:\$(CFLAGS)::-D_REENTRANT::\$(LDFLAGS) \$(LDLIBS):SIXTY_FOUR_BIT_LONG:${no_asm}:$ENV{'LIBSSL_dlfcn'}:linux-shared:-fPIC:-shared:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR):$ENV{'RANLIB'}::",
|
||||||
|
|
||||||
);
|
);
|
||||||
|
|
||||||
my @MK1MF_Builds=qw(VC-WIN64I VC-WIN64A
|
my @MK1MF_Builds=qw(VC-WIN64I VC-WIN64A
|
||||||
VC-NT VC-CE VC-WIN32
|
debug-VC-WIN64I debug-VC-WIN64A
|
||||||
BC-32 OS2-EMX
|
VC-NT VC-CE VC-WIN32 debug-VC-WIN32
|
||||||
|
BC-32
|
||||||
netware-clib netware-clib-bsdsock
|
netware-clib netware-clib-bsdsock
|
||||||
netware-libc netware-libc-bsdsock);
|
netware-libc netware-libc-bsdsock);
|
||||||
|
|
||||||
@@ -598,6 +645,8 @@ my $idx_rmd160_obj = $idx++;
|
|||||||
my $idx_rc5_obj = $idx++;
|
my $idx_rc5_obj = $idx++;
|
||||||
my $idx_wp_obj = $idx++;
|
my $idx_wp_obj = $idx++;
|
||||||
my $idx_cmll_obj = $idx++;
|
my $idx_cmll_obj = $idx++;
|
||||||
|
my $idx_modes_obj = $idx++;
|
||||||
|
my $idx_engines_obj = $idx++;
|
||||||
my $idx_perlasm_scheme = $idx++;
|
my $idx_perlasm_scheme = $idx++;
|
||||||
my $idx_dso_scheme = $idx++;
|
my $idx_dso_scheme = $idx++;
|
||||||
my $idx_shared_target = $idx++;
|
my $idx_shared_target = $idx++;
|
||||||
@@ -609,10 +658,14 @@ my $idx_arflags = $idx++;
|
|||||||
my $idx_multilib = $idx++;
|
my $idx_multilib = $idx++;
|
||||||
|
|
||||||
my $prefix="";
|
my $prefix="";
|
||||||
|
my $libdir="";
|
||||||
my $openssldir="";
|
my $openssldir="";
|
||||||
my $exe_ext="";
|
my $exe_ext="";
|
||||||
my $install_prefix="";
|
my $install_prefix= "$ENV{'INSTALL_PREFIX'}";
|
||||||
my $cross_compile_prefix="";
|
my $cross_compile_prefix="";
|
||||||
|
my $fipsdir="/usr/local/ssl/fips-2.0";
|
||||||
|
my $fipslibdir="";
|
||||||
|
my $baseaddr="0xFB00000";
|
||||||
my $no_threads=0;
|
my $no_threads=0;
|
||||||
my $threads=0;
|
my $threads=0;
|
||||||
my $no_shared=0; # but "no-shared" is default
|
my $no_shared=0; # but "no-shared" is default
|
||||||
@@ -647,27 +700,34 @@ my $cmll_enc="camellia.o cmll_misc.o cmll_cbc.o";
|
|||||||
my $processor="";
|
my $processor="";
|
||||||
my $default_ranlib;
|
my $default_ranlib;
|
||||||
my $perl;
|
my $perl;
|
||||||
|
my $fips=0;
|
||||||
|
|
||||||
|
if (exists $ENV{FIPSDIR})
|
||||||
|
{
|
||||||
|
$fipsdir = $ENV{FIPSDIR};
|
||||||
|
$fipsdir =~ s/\/$//;
|
||||||
|
}
|
||||||
|
|
||||||
# All of the following is disabled by default (RC5 was enabled before 0.9.8):
|
# All of the following is disabled by default (RC5 was enabled before 0.9.8):
|
||||||
|
|
||||||
my %disabled = ( # "what" => "comment" [or special keyword "experimental"]
|
my %disabled = ( # "what" => "comment" [or special keyword "experimental"]
|
||||||
|
"ec_nistp_64_gcc_128" => "default",
|
||||||
"gmp" => "default",
|
"gmp" => "default",
|
||||||
"jpake" => "experimental",
|
"jpake" => "experimental",
|
||||||
"mdc2" => "default",
|
"md2" => "default",
|
||||||
"rc5" => "default",
|
"rc5" => "default",
|
||||||
"rfc3779" => "default",
|
"rfc3779" => "default",
|
||||||
"shared" => "default",
|
"sctp" => "default",
|
||||||
|
"shared" => "default",
|
||||||
"store" => "experimental",
|
"store" => "experimental",
|
||||||
"zlib" => "default",
|
"zlib" => "default",
|
||||||
"zlib-dynamic" => "default"
|
"zlib-dynamic" => "default"
|
||||||
);
|
);
|
||||||
my @experimental = ();
|
my @experimental = ();
|
||||||
|
|
||||||
# This is what $depflags will look like with the above defaults
|
# This is what $depflags will look like with the above defaults
|
||||||
# (we need this to see if we should advise the user to run "make depend"):
|
# (we need this to see if we should advise the user to run "make depend"):
|
||||||
my $default_depflags = " -DOPENSSL_NO_GMP -DOPENSSL_NO_JPAKE -DOPENSSL_NO_MDC2 -DOPENSSL_NO_RC5 -DOPENSSL_NO_RFC3779 -DOPENSSL_NO_STORE";
|
my $default_depflags = " -DOPENSSL_NO_EC_NISTP_64_GCC_128 -DOPENSSL_NO_GMP -DOPENSSL_NO_JPAKE -DOPENSSL_NO_MD2 -DOPENSSL_NO_RC5 -DOPENSSL_NO_RFC3779 -DOPENSSL_NO_SCTP -DOPENSSL_NO_STORE";
|
||||||
|
|
||||||
|
|
||||||
# Explicit "no-..." options will be collected in %disabled along with the defaults.
|
# Explicit "no-..." options will be collected in %disabled along with the defaults.
|
||||||
# To remove something from %disabled, use "enable-foo" (unless it's experimental).
|
# To remove something from %disabled, use "enable-foo" (unless it's experimental).
|
||||||
@@ -725,6 +785,7 @@ PROCESS_ARGS:
|
|||||||
|
|
||||||
# rewrite some options in "enable-..." form
|
# rewrite some options in "enable-..." form
|
||||||
s /^-?-?shared$/enable-shared/;
|
s /^-?-?shared$/enable-shared/;
|
||||||
|
s /^sctp$/enable-sctp/;
|
||||||
s /^threads$/enable-threads/;
|
s /^threads$/enable-threads/;
|
||||||
s /^zlib$/enable-zlib/;
|
s /^zlib$/enable-zlib/;
|
||||||
s /^zlib-dynamic$/enable-zlib-dynamic/;
|
s /^zlib-dynamic$/enable-zlib-dynamic/;
|
||||||
@@ -765,6 +826,10 @@ PROCESS_ARGS:
|
|||||||
{
|
{
|
||||||
exit(&test_sanity());
|
exit(&test_sanity());
|
||||||
}
|
}
|
||||||
|
elsif (/^--strict-warnings/)
|
||||||
|
{
|
||||||
|
$strict_warnings = 1;
|
||||||
|
}
|
||||||
elsif (/^reconfigure/ || /^reconf/)
|
elsif (/^reconfigure/ || /^reconf/)
|
||||||
{
|
{
|
||||||
if (open(IN,"<$Makefile"))
|
if (open(IN,"<$Makefile"))
|
||||||
@@ -790,6 +855,10 @@ PROCESS_ARGS:
|
|||||||
}
|
}
|
||||||
elsif (/^386$/)
|
elsif (/^386$/)
|
||||||
{ $processor=386; }
|
{ $processor=386; }
|
||||||
|
elsif (/^fips$/)
|
||||||
|
{
|
||||||
|
$fips=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.
|
||||||
@@ -804,12 +873,17 @@ PROCESS_ARGS:
|
|||||||
}
|
}
|
||||||
elsif (/^-[^-]/ or /^\+/)
|
elsif (/^-[^-]/ or /^\+/)
|
||||||
{
|
{
|
||||||
|
$_ =~ s/%([0-9a-f]{1,2})/chr(hex($1))/gei;
|
||||||
$flags.=$_." ";
|
$flags.=$_." ";
|
||||||
}
|
}
|
||||||
elsif (/^--prefix=(.*)$/)
|
elsif (/^--prefix=(.*)$/)
|
||||||
{
|
{
|
||||||
$prefix=$1;
|
$prefix=$1;
|
||||||
}
|
}
|
||||||
|
elsif (/^--libdir=(.*)$/)
|
||||||
|
{
|
||||||
|
$libdir=$1;
|
||||||
|
}
|
||||||
elsif (/^--openssldir=(.*)$/)
|
elsif (/^--openssldir=(.*)$/)
|
||||||
{
|
{
|
||||||
$openssldir=$1;
|
$openssldir=$1;
|
||||||
@@ -830,6 +904,18 @@ PROCESS_ARGS:
|
|||||||
{
|
{
|
||||||
$withargs{"zlib-include"}="-I$1";
|
$withargs{"zlib-include"}="-I$1";
|
||||||
}
|
}
|
||||||
|
elsif (/^--with-fipsdir=(.*)$/)
|
||||||
|
{
|
||||||
|
$fipsdir="$1";
|
||||||
|
}
|
||||||
|
elsif (/^--with-fipslibdir=(.*)$/)
|
||||||
|
{
|
||||||
|
$fipslibdir="$1";
|
||||||
|
}
|
||||||
|
elsif (/^--with-baseaddr=(.*)$/)
|
||||||
|
{
|
||||||
|
$baseaddr="$1";
|
||||||
|
}
|
||||||
elsif (/^--cross-compile-prefix=(.*)$/)
|
elsif (/^--cross-compile-prefix=(.*)$/)
|
||||||
{
|
{
|
||||||
$cross_compile_prefix=$1;
|
$cross_compile_prefix=$1;
|
||||||
@@ -904,6 +990,17 @@ if (defined($disabled{"md5"}) || defined($disabled{"rsa"}))
|
|||||||
$disabled{"ssl2"} = "forced";
|
$disabled{"ssl2"} = "forced";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($fips && $fipslibdir eq "")
|
||||||
|
{
|
||||||
|
$fipslibdir = $fipsdir . "/lib/";
|
||||||
|
}
|
||||||
|
|
||||||
|
# RSAX ENGINE sets default non-FIPS RSA method.
|
||||||
|
if ($fips)
|
||||||
|
{
|
||||||
|
$disabled{"rsax"} = "forced";
|
||||||
|
}
|
||||||
|
|
||||||
# SSL 3.0 and TLS requires MD5 and SHA and either RSA or DSA+DH
|
# SSL 3.0 and TLS requires MD5 and SHA and either RSA or DSA+DH
|
||||||
if (defined($disabled{"md5"}) || defined($disabled{"sha"})
|
if (defined($disabled{"md5"}) || defined($disabled{"sha"})
|
||||||
|| (defined($disabled{"rsa"})
|
|| (defined($disabled{"rsa"})
|
||||||
@@ -918,6 +1015,19 @@ if (defined($disabled{"tls1"}))
|
|||||||
$disabled{"tlsext"} = "forced";
|
$disabled{"tlsext"} = "forced";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (defined($disabled{"ec"}) || defined($disabled{"dsa"})
|
||||||
|
|| defined($disabled{"dh"}))
|
||||||
|
{
|
||||||
|
$disabled{"gost"} = "forced";
|
||||||
|
}
|
||||||
|
|
||||||
|
# SRP and HEARTBEATS require TLSEXT
|
||||||
|
if (defined($disabled{"tlsext"}))
|
||||||
|
{
|
||||||
|
$disabled{"srp"} = "forced";
|
||||||
|
$disabled{"heartbeats"} = "forced";
|
||||||
|
}
|
||||||
|
|
||||||
if ($target eq "TABLE") {
|
if ($target eq "TABLE") {
|
||||||
foreach $target (sort keys %table) {
|
foreach $target (sort keys %table) {
|
||||||
print_table_entry($target);
|
print_table_entry($target);
|
||||||
@@ -967,7 +1077,7 @@ foreach (sort (keys %disabled))
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
my ($ALGO, $algo);
|
my ($ALGO, $algo);
|
||||||
($ALGO = $algo = $_) =~ tr/[a-z]/[A-Z]/;
|
($ALGO = $algo = $_) =~ tr/[\-a-z]/[_A-Z]/;
|
||||||
|
|
||||||
if (/^asm$/ || /^err$/ || /^hw$/ || /^hw-/)
|
if (/^asm$/ || /^err$/ || /^hw$/ || /^hw-/)
|
||||||
{
|
{
|
||||||
@@ -987,6 +1097,8 @@ foreach (sort (keys %disabled))
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
push @skip, $algo;
|
push @skip, $algo;
|
||||||
|
# fix-up crypto/directory name(s)
|
||||||
|
@skip[$#skip]="whrlpool" if $algo eq "whirlpool";
|
||||||
print " (skip dir)";
|
print " (skip dir)";
|
||||||
|
|
||||||
$depflags .= " -DOPENSSL_NO_$ALGO";
|
$depflags .= " -DOPENSSL_NO_$ALGO";
|
||||||
@@ -1019,6 +1131,9 @@ $prefix=$openssldir if $prefix eq "";
|
|||||||
$default_ranlib= &which("ranlib") or $default_ranlib="true";
|
$default_ranlib= &which("ranlib") or $default_ranlib="true";
|
||||||
$perl=$ENV{'PERL'} or $perl=&which("perl5") or $perl=&which("perl")
|
$perl=$ENV{'PERL'} or $perl=&which("perl5") or $perl=&which("perl")
|
||||||
or $perl="perl";
|
or $perl="perl";
|
||||||
|
my $make = $ENV{'MAKE'} || "make";
|
||||||
|
|
||||||
|
$cross_compile_prefix=$ENV{'CROSS_COMPILE'} if $cross_compile_prefix eq "";
|
||||||
|
|
||||||
chop $openssldir if $openssldir =~ /\/$/;
|
chop $openssldir if $openssldir =~ /\/$/;
|
||||||
chop $prefix if $prefix =~ /.\/$/;
|
chop $prefix if $prefix =~ /.\/$/;
|
||||||
@@ -1054,16 +1169,27 @@ my $rmd160_obj = $fields[$idx_rmd160_obj];
|
|||||||
my $rc5_obj = $fields[$idx_rc5_obj];
|
my $rc5_obj = $fields[$idx_rc5_obj];
|
||||||
my $wp_obj = $fields[$idx_wp_obj];
|
my $wp_obj = $fields[$idx_wp_obj];
|
||||||
my $cmll_obj = $fields[$idx_cmll_obj];
|
my $cmll_obj = $fields[$idx_cmll_obj];
|
||||||
|
my $modes_obj = $fields[$idx_modes_obj];
|
||||||
|
my $engines_obj = $fields[$idx_engines_obj];
|
||||||
my $perlasm_scheme = $fields[$idx_perlasm_scheme];
|
my $perlasm_scheme = $fields[$idx_perlasm_scheme];
|
||||||
my $dso_scheme = $fields[$idx_dso_scheme];
|
my $dso_scheme = $fields[$idx_dso_scheme];
|
||||||
my $shared_target = $fields[$idx_shared_target];
|
my $shared_target = $fields[$idx_shared_target];
|
||||||
my $shared_cflag = $fields[$idx_shared_cflag];
|
my $shared_cflag = $fields[$idx_shared_cflag];
|
||||||
my $shared_ldflag = $fields[$idx_shared_ldflag];
|
my $shared_ldflag = $fields[$idx_shared_ldflag];
|
||||||
my $shared_extension = $fields[$idx_shared_extension];
|
my $shared_extension = $fields[$idx_shared_extension];
|
||||||
my $ranlib = $fields[$idx_ranlib];
|
my $ranlib = $ENV{'RANLIB'} || $fields[$idx_ranlib];
|
||||||
|
my $ar = $ENV{'AR'} || "ar";
|
||||||
my $arflags = $fields[$idx_arflags];
|
my $arflags = $fields[$idx_arflags];
|
||||||
my $multilib = $fields[$idx_multilib];
|
my $multilib = $fields[$idx_multilib];
|
||||||
|
|
||||||
|
# if $prefix/lib$multilib is not an existing directory, then
|
||||||
|
# assume that it's not searched by linker automatically, in
|
||||||
|
# which case adding $multilib suffix causes more grief than
|
||||||
|
# we're ready to tolerate, so don't...
|
||||||
|
$multilib="" if !-d "$prefix/lib$multilib";
|
||||||
|
|
||||||
|
$libdir="lib$multilib" if $libdir eq "";
|
||||||
|
|
||||||
$cflags = "$cflags$exp_cflags";
|
$cflags = "$cflags$exp_cflags";
|
||||||
|
|
||||||
# '%' in $lflags is used to split flags to "pre-" and post-flags
|
# '%' in $lflags is used to split flags to "pre-" and post-flags
|
||||||
@@ -1071,6 +1197,12 @@ my ($prelflags,$postlflags)=split('%',$lflags);
|
|||||||
if (defined($postlflags)) { $lflags=$postlflags; }
|
if (defined($postlflags)) { $lflags=$postlflags; }
|
||||||
else { $lflags=$prelflags; undef $prelflags; }
|
else { $lflags=$prelflags; undef $prelflags; }
|
||||||
|
|
||||||
|
if ($target =~ /^mingw/ && `$cc --target-help 2>&1` !~ m/\-mno\-cygwin/m)
|
||||||
|
{
|
||||||
|
$cflags =~ s/\-mno\-cygwin\s*//;
|
||||||
|
$shared_ldflag =~ s/\-mno\-cygwin\s*//;
|
||||||
|
}
|
||||||
|
|
||||||
my $no_shared_warn=0;
|
my $no_shared_warn=0;
|
||||||
my $no_user_cflags=0;
|
my $no_user_cflags=0;
|
||||||
|
|
||||||
@@ -1199,7 +1331,7 @@ if ($no_asm)
|
|||||||
{
|
{
|
||||||
$cpuid_obj=$bn_obj=
|
$cpuid_obj=$bn_obj=
|
||||||
$des_obj=$aes_obj=$bf_obj=$cast_obj=$rc4_obj=$rc5_obj=$cmll_obj=
|
$des_obj=$aes_obj=$bf_obj=$cast_obj=$rc4_obj=$rc5_obj=$cmll_obj=
|
||||||
$sha1_obj=$md5_obj=$rmd160_obj=$wp_obj="";
|
$modes_obj=$sha1_obj=$md5_obj=$rmd160_obj=$wp_obj=$engines_obj="";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$no_shared)
|
if (!$no_shared)
|
||||||
@@ -1218,7 +1350,14 @@ if ($zlib)
|
|||||||
$cflags = "-DZLIB $cflags";
|
$cflags = "-DZLIB $cflags";
|
||||||
if (defined($disabled{"zlib-dynamic"}))
|
if (defined($disabled{"zlib-dynamic"}))
|
||||||
{
|
{
|
||||||
$lflags = "$lflags -lz";
|
if (defined($withargs{"zlib-lib"}))
|
||||||
|
{
|
||||||
|
$lflags = "$lflags -L" . $withargs{"zlib-lib"} . " -lz";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$lflags = "$lflags -lz";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -1256,7 +1395,7 @@ if (!$IsMK1MF)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$cpuid_obj.=" uplink.o uplink-cof.o" if ($cflags =~ /\-DOPENSSL_USE_APPLINK/);
|
$cpuid_obj.=" uplink.o uplink-x86.o" if ($cflags =~ /\-DOPENSSL_USE_APPLINK/);
|
||||||
|
|
||||||
#
|
#
|
||||||
# Platform fix-ups
|
# Platform fix-ups
|
||||||
@@ -1324,6 +1463,14 @@ $cflags.=" -DOPENSSL_BN_ASM_PART_WORDS" if ($bn_obj =~ /bn-586/);
|
|||||||
$cflags.=" -DOPENSSL_IA32_SSE2" if (!$no_sse2 && $bn_obj =~ /86/);
|
$cflags.=" -DOPENSSL_IA32_SSE2" if (!$no_sse2 && $bn_obj =~ /86/);
|
||||||
|
|
||||||
$cflags.=" -DOPENSSL_BN_ASM_MONT" if ($bn_obj =~ /-mont/);
|
$cflags.=" -DOPENSSL_BN_ASM_MONT" if ($bn_obj =~ /-mont/);
|
||||||
|
$cflags.=" -DOPENSSL_BN_ASM_MONT5" if ($bn_obj =~ /-mont5/);
|
||||||
|
$cflags.=" -DOPENSSL_BN_ASM_GF2m" if ($bn_obj =~ /-gf2m/);
|
||||||
|
|
||||||
|
if ($fips)
|
||||||
|
{
|
||||||
|
$openssl_other_defines.="#define OPENSSL_FIPS\n";
|
||||||
|
$cflags .= " -I\$(FIPSDIR)/include";
|
||||||
|
}
|
||||||
|
|
||||||
$cpuid_obj="mem_clr.o" unless ($cpuid_obj =~ /\.o$/);
|
$cpuid_obj="mem_clr.o" unless ($cpuid_obj =~ /\.o$/);
|
||||||
$des_obj=$des_enc unless ($des_obj =~ /\.o$/);
|
$des_obj=$des_enc unless ($des_obj =~ /\.o$/);
|
||||||
@@ -1357,12 +1504,20 @@ if ($rmd160_obj =~ /\.o$/)
|
|||||||
if ($aes_obj =~ /\.o$/)
|
if ($aes_obj =~ /\.o$/)
|
||||||
{
|
{
|
||||||
$cflags.=" -DAES_ASM";
|
$cflags.=" -DAES_ASM";
|
||||||
|
# aes-ctr.o is not a real file, only indication that assembler
|
||||||
|
# module implements AES_ctr32_encrypt...
|
||||||
|
$cflags.=" -DAES_CTR_ASM" if ($aes_obj =~ s/\s*aes\-ctr\.o//);
|
||||||
|
# aes-xts.o indicates presense of AES_xts_[en|de]crypt...
|
||||||
|
$cflags.=" -DAES_XTS_ASM" if ($aes_obj =~ s/\s*aes\-xts\.o//);
|
||||||
|
$aes_obj =~ s/\s*(vpaes|aesni)\-x86\.o//g if ($no_sse2);
|
||||||
|
$cflags.=" -DVPAES_ASM" if ($aes_obj =~ m/vpaes/);
|
||||||
|
$cflags.=" -DBSAES_ASM" if ($aes_obj =~ m/bsaes/);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$aes_obj=$aes_enc;
|
$aes_obj=$aes_enc;
|
||||||
}
|
}
|
||||||
$wp_obj="" if ($wp_obj =~ /mmx/ && $processor eq "386");
|
$wp_obj="" if ($wp_obj =~ /mmx/ && $processor eq "386");
|
||||||
if ($wp_obj =~ /\.o$/)
|
if ($wp_obj =~ /\.o$/ && !$disabled{"whirlpool"})
|
||||||
{
|
{
|
||||||
$cflags.=" -DWHIRLPOOL_ASM";
|
$cflags.=" -DWHIRLPOOL_ASM";
|
||||||
}
|
}
|
||||||
@@ -1370,6 +1525,10 @@ else {
|
|||||||
$wp_obj="wp_block.o";
|
$wp_obj="wp_block.o";
|
||||||
}
|
}
|
||||||
$cmll_obj=$cmll_enc unless ($cmll_obj =~ /.o$/);
|
$cmll_obj=$cmll_enc unless ($cmll_obj =~ /.o$/);
|
||||||
|
if ($modes_obj =~ /ghash/)
|
||||||
|
{
|
||||||
|
$cflags.=" -DGHASH_ASM";
|
||||||
|
}
|
||||||
|
|
||||||
# "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.
|
||||||
@@ -1407,6 +1566,16 @@ if ($shlib_version_number =~ /(^[0-9]*)\.([0-9\.]*)/)
|
|||||||
$shlib_minor=$2;
|
$shlib_minor=$2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($strict_warnings)
|
||||||
|
{
|
||||||
|
my $wopt;
|
||||||
|
die "ERROR --strict-warnings requires gcc" unless ($cc =~ /gcc$/);
|
||||||
|
foreach $wopt (split /\s+/, $gcc_devteam_warn)
|
||||||
|
{
|
||||||
|
$cflags .= " $wopt" unless ($cflags =~ /$wopt/)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
open(IN,'<Makefile.org') || die "unable to read Makefile.org:$!\n";
|
open(IN,'<Makefile.org') || die "unable to read Makefile.org:$!\n";
|
||||||
unlink("$Makefile.new") || die "unable to remove old $Makefile.new:$!\n" if -e "$Makefile.new";
|
unlink("$Makefile.new") || die "unable to remove old $Makefile.new:$!\n" if -e "$Makefile.new";
|
||||||
open(OUT,">$Makefile.new") || die "unable to create $Makefile.new:$!\n";
|
open(OUT,">$Makefile.new") || die "unable to create $Makefile.new:$!\n";
|
||||||
@@ -1425,6 +1594,7 @@ while (<IN>)
|
|||||||
}
|
}
|
||||||
$sdirs = 0 unless /\\$/;
|
$sdirs = 0 unless /\\$/;
|
||||||
s/engines // if (/^DIRS=/ && $disabled{"engine"});
|
s/engines // if (/^DIRS=/ && $disabled{"engine"});
|
||||||
|
s/ccgost// if (/^ENGDIRS=/ && $disabled{"gost"});
|
||||||
s/^VERSION=.*/VERSION=$version/;
|
s/^VERSION=.*/VERSION=$version/;
|
||||||
s/^MAJOR=.*/MAJOR=$major/;
|
s/^MAJOR=.*/MAJOR=$major/;
|
||||||
s/^MINOR=.*/MINOR=$minor/;
|
s/^MINOR=.*/MINOR=$minor/;
|
||||||
@@ -1436,20 +1606,22 @@ while (<IN>)
|
|||||||
s/^INSTALLTOP=.*$/INSTALLTOP=$prefix/;
|
s/^INSTALLTOP=.*$/INSTALLTOP=$prefix/;
|
||||||
s/^MULTILIB=.*$/MULTILIB=$multilib/;
|
s/^MULTILIB=.*$/MULTILIB=$multilib/;
|
||||||
s/^OPENSSLDIR=.*$/OPENSSLDIR=$openssldir/;
|
s/^OPENSSLDIR=.*$/OPENSSLDIR=$openssldir/;
|
||||||
|
s/^LIBDIR=.*$/LIBDIR=$libdir/;
|
||||||
s/^INSTALL_PREFIX=.*$/INSTALL_PREFIX=$install_prefix/;
|
s/^INSTALL_PREFIX=.*$/INSTALL_PREFIX=$install_prefix/;
|
||||||
s/^PLATFORM=.*$/PLATFORM=$target/;
|
s/^PLATFORM=.*$/PLATFORM=$target/;
|
||||||
s/^OPTIONS=.*$/OPTIONS=$options/;
|
s/^OPTIONS=.*$/OPTIONS=$options/;
|
||||||
s/^CONFIGURE_ARGS=.*$/CONFIGURE_ARGS=$argvstring/;
|
s/^CONFIGURE_ARGS=.*$/CONFIGURE_ARGS=$argvstring/;
|
||||||
if ($cross_compile_prefix)
|
if ($cross_compile_prefix)
|
||||||
{
|
{
|
||||||
s/^CC=.*$/CROSS_COMPILE_PREFIX= $cross_compile_prefix\nCC= \$\(CROSS_COMPILE_PREFIX\)$cc/;
|
s/^CC=.*$/CROSS_COMPILE= $cross_compile_prefix\nCC= \$\(CROSS_COMPILE\)$cc/;
|
||||||
s/^AR=\s*/AR= \$\(CROSS_COMPILE_PREFIX\)/;
|
s/^AR=\s*/AR= \$\(CROSS_COMPILE\)/;
|
||||||
s/^NM=\s*/NM= \$\(CROSS_COMPILE_PREFIX\)/;
|
s/^NM=\s*/NM= \$\(CROSS_COMPILE\)/;
|
||||||
s/^RANLIB=\s*/RANLIB= \$\(CROSS_COMPILE_PREFIX\)/;
|
s/^RANLIB=\s*/RANLIB= \$\(CROSS_COMPILE\)/;
|
||||||
s/^MAKEDEPPROG=.*$/MAKEDEPPROG= \$\(CROSS_COMPILE_PREFIX\)$cc/ if $cc eq "gcc";
|
s/^MAKEDEPPROG=.*$/MAKEDEPPROG= \$\(CROSS_COMPILE\)$cc/ if $cc eq "gcc";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
s/^CC=.*$/CC= $cc/;
|
s/^CC=.*$/CC= $cc/;
|
||||||
|
s/^AR=\s*ar/AR= $ar/;
|
||||||
s/^RANLIB=.*/RANLIB= $ranlib/;
|
s/^RANLIB=.*/RANLIB= $ranlib/;
|
||||||
s/^MAKEDEPPROG=.*$/MAKEDEPPROG= $cc/ if $cc eq "gcc";
|
s/^MAKEDEPPROG=.*$/MAKEDEPPROG= $cc/ if $cc eq "gcc";
|
||||||
}
|
}
|
||||||
@@ -1471,6 +1643,8 @@ while (<IN>)
|
|||||||
s/^RMD160_ASM_OBJ=.*$/RMD160_ASM_OBJ= $rmd160_obj/;
|
s/^RMD160_ASM_OBJ=.*$/RMD160_ASM_OBJ= $rmd160_obj/;
|
||||||
s/^WP_ASM_OBJ=.*$/WP_ASM_OBJ= $wp_obj/;
|
s/^WP_ASM_OBJ=.*$/WP_ASM_OBJ= $wp_obj/;
|
||||||
s/^CMLL_ENC=.*$/CMLL_ENC= $cmll_obj/;
|
s/^CMLL_ENC=.*$/CMLL_ENC= $cmll_obj/;
|
||||||
|
s/^MODES_ASM_OBJ.=*$/MODES_ASM_OBJ= $modes_obj/;
|
||||||
|
s/^ENGINES_ASM_OBJ.=*$/ENGINES_ASM_OBJ= $engines_obj/;
|
||||||
s/^PERLASM_SCHEME=.*$/PERLASM_SCHEME= $perlasm_scheme/;
|
s/^PERLASM_SCHEME=.*$/PERLASM_SCHEME= $perlasm_scheme/;
|
||||||
s/^PROCESSOR=.*/PROCESSOR= $processor/;
|
s/^PROCESSOR=.*/PROCESSOR= $processor/;
|
||||||
s/^ARFLAGS=.*/ARFLAGS= $arflags/;
|
s/^ARFLAGS=.*/ARFLAGS= $arflags/;
|
||||||
@@ -1479,6 +1653,12 @@ while (<IN>)
|
|||||||
s/^LIBKRB5=.*/LIBKRB5=$withargs{"krb5-lib"}/;
|
s/^LIBKRB5=.*/LIBKRB5=$withargs{"krb5-lib"}/;
|
||||||
s/^LIBZLIB=.*/LIBZLIB=$withargs{"zlib-lib"}/;
|
s/^LIBZLIB=.*/LIBZLIB=$withargs{"zlib-lib"}/;
|
||||||
s/^ZLIB_INCLUDE=.*/ZLIB_INCLUDE=$withargs{"zlib-include"}/;
|
s/^ZLIB_INCLUDE=.*/ZLIB_INCLUDE=$withargs{"zlib-include"}/;
|
||||||
|
|
||||||
|
s/^FIPSDIR=.*/FIPSDIR=$fipsdir/;
|
||||||
|
s/^FIPSLIBDIR=.*/FIPSLIBDIR=$fipslibdir/;
|
||||||
|
s/^FIPSCANLIB=.*/FIPSCANLIB=libcrypto/ if $fips;
|
||||||
|
s/^BASEADDR=.*/BASEADDR=$baseaddr/;
|
||||||
|
|
||||||
s/^SHLIB_TARGET=.*/SHLIB_TARGET=$shared_target/;
|
s/^SHLIB_TARGET=.*/SHLIB_TARGET=$shared_target/;
|
||||||
s/^SHLIB_MARK=.*/SHLIB_MARK=$shared_mark/;
|
s/^SHLIB_MARK=.*/SHLIB_MARK=$shared_mark/;
|
||||||
s/^SHARED_LIBS=.*/SHARED_LIBS=\$(SHARED_CRYPTO) \$(SHARED_SSL)/ if (!$no_shared);
|
s/^SHARED_LIBS=.*/SHARED_LIBS=\$(SHARED_CRYPTO) \$(SHARED_SSL)/ if (!$no_shared);
|
||||||
@@ -1522,7 +1702,9 @@ print "RC5_ENC =$rc5_obj\n";
|
|||||||
print "MD5_OBJ_ASM =$md5_obj\n";
|
print "MD5_OBJ_ASM =$md5_obj\n";
|
||||||
print "SHA1_OBJ_ASM =$sha1_obj\n";
|
print "SHA1_OBJ_ASM =$sha1_obj\n";
|
||||||
print "RMD160_OBJ_ASM=$rmd160_obj\n";
|
print "RMD160_OBJ_ASM=$rmd160_obj\n";
|
||||||
print "CMLL_ENC= =$cmll_obj\n";
|
print "CMLL_ENC =$cmll_obj\n";
|
||||||
|
print "MODES_OBJ =$modes_obj\n";
|
||||||
|
print "ENGINES_OBJ =$engines_obj\n";
|
||||||
print "PROCESSOR =$processor\n";
|
print "PROCESSOR =$processor\n";
|
||||||
print "RANLIB =$ranlib\n";
|
print "RANLIB =$ranlib\n";
|
||||||
print "ARFLAGS =$arflags\n";
|
print "ARFLAGS =$arflags\n";
|
||||||
@@ -1622,10 +1804,7 @@ while (<IN>)
|
|||||||
}
|
}
|
||||||
elsif (/^#define\s+ENGINESDIR/)
|
elsif (/^#define\s+ENGINESDIR/)
|
||||||
{
|
{
|
||||||
# $foo is to become "$prefix/lib$multilib/engines";
|
my $foo = "$prefix/$libdir/engines";
|
||||||
# as Makefile.org and engines/Makefile are adapted for
|
|
||||||
# $multilib suffix.
|
|
||||||
my $foo = "$prefix/lib/engines";
|
|
||||||
$foo =~ s/\\/\\\\/g;
|
$foo =~ s/\\/\\\\/g;
|
||||||
print OUT "#define ENGINESDIR \"$foo\"\n";
|
print OUT "#define ENGINESDIR \"$foo\"\n";
|
||||||
}
|
}
|
||||||
@@ -1733,7 +1912,7 @@ if($IsMK1MF) {
|
|||||||
EOF
|
EOF
|
||||||
close(OUT);
|
close(OUT);
|
||||||
} else {
|
} else {
|
||||||
my $make_command = "make 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 $default_depflags && $make_depend;
|
$make_targets .= " depend" if $depflags ne $default_depflags && $make_depend;
|
||||||
@@ -1741,11 +1920,11 @@ EOF
|
|||||||
(system $make_command.$make_targets) == 0 or exit $?
|
(system $make_command.$make_targets) == 0 or exit $?
|
||||||
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 . '";', '^my \$prefix;$', 'my $prefix = "' . $prefix . '";');
|
||||||
&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 . '";', '^my \$prefix;$', 'my $prefix = "' . $prefix . '";');
|
||||||
&dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s');
|
&dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s');
|
||||||
}
|
}
|
||||||
if ($depflags ne $default_depflags && !$make_depend) {
|
if ($depflags ne $default_depflags && !$make_depend) {
|
||||||
@@ -1918,7 +2097,8 @@ sub print_table_entry
|
|||||||
(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 $cpuid_obj,my $bn_obj,my $des_obj,my $aes_obj, my $bf_obj,
|
my $bn_ops,my $cpuid_obj,my $bn_obj,my $des_obj,my $aes_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 $wp_obj,my $cmll_obj,my $perlasm_scheme,my $dso_scheme,my $shared_target,my $shared_cflag,
|
my $rc5_obj,my $wp_obj,my $cmll_obj,my $modes_obj, my $engines_obj,
|
||||||
|
my $perlasm_scheme,my $dso_scheme,my $shared_target,my $shared_cflag,
|
||||||
my $shared_ldflag,my $shared_extension,my $ranlib,my $arflags,my $multilib)=
|
my $shared_ldflag,my $shared_extension,my $ranlib,my $arflags,my $multilib)=
|
||||||
split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||||
|
|
||||||
@@ -1945,6 +2125,8 @@ sub print_table_entry
|
|||||||
\$rc5_obj = $rc5_obj
|
\$rc5_obj = $rc5_obj
|
||||||
\$wp_obj = $wp_obj
|
\$wp_obj = $wp_obj
|
||||||
\$cmll_obj = $cmll_obj
|
\$cmll_obj = $cmll_obj
|
||||||
|
\$modes_obj = $modes_obj
|
||||||
|
\$engines_obj = $engines_obj
|
||||||
\$perlasm_scheme = $perlasm_scheme
|
\$perlasm_scheme = $perlasm_scheme
|
||||||
\$dso_scheme = $dso_scheme
|
\$dso_scheme = $dso_scheme
|
||||||
\$shared_target= $shared_target
|
\$shared_target= $shared_target
|
||||||
@@ -1970,23 +2152,23 @@ sub test_sanity
|
|||||||
{
|
{
|
||||||
@fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
@fields = split(/\s*:\s*/,$table{$target} . ":" x 30 , -1);
|
||||||
|
|
||||||
if ($fields[$idx_dso_scheme-1] =~ /^(dl|dlfcn|win32|vms)$/)
|
if ($fields[$idx_dso_scheme-1] =~ /^(beos|dl|dlfcn|win32|vms)$/)
|
||||||
{
|
{
|
||||||
$errorcnt++;
|
$errorcnt++;
|
||||||
print STDERR "SANITY ERROR: '$target' has the dso_scheme [$idx_dso_scheme] values\n";
|
print STDERR "SANITY ERROR: '$target' has the dso_scheme [$idx_dso_scheme] values\n";
|
||||||
print STDERR " in the previous field\n";
|
print STDERR " in the previous field\n";
|
||||||
}
|
}
|
||||||
elsif ($fields[$idx_dso_scheme+1] =~ /^(dl|dlfcn|win32|vms)$/)
|
elsif ($fields[$idx_dso_scheme+1] =~ /^(beos|dl|dlfcn|win32|vms)$/)
|
||||||
{
|
{
|
||||||
$errorcnt++;
|
$errorcnt++;
|
||||||
print STDERR "SANITY ERROR: '$target' has the dso_scheme [$idx_dso_scheme] values\n";
|
print STDERR "SANITY ERROR: '$target' has the dso_scheme [$idx_dso_scheme] values\n";
|
||||||
print STDERR " in the following field\n";
|
print STDERR " in the following field\n";
|
||||||
}
|
}
|
||||||
elsif ($fields[$idx_dso_scheme] !~ /^(dl|dlfcn|win32|vms|)$/)
|
elsif ($fields[$idx_dso_scheme] !~ /^(beos|dl|dlfcn|win32|vms|)$/)
|
||||||
{
|
{
|
||||||
$errorcnt++;
|
$errorcnt++;
|
||||||
print STDERR "SANITY ERROR: '$target' has the dso_scheme [$idx_dso_scheme] field = ",$fields[$idx_dso_scheme],"\n";
|
print STDERR "SANITY ERROR: '$target' has the dso_scheme [$idx_dso_scheme] field = ",$fields[$idx_dso_scheme],"\n";
|
||||||
print STDERR " valid values are 'dl', 'dlfcn', 'win32' and 'vms'\n";
|
print STDERR " valid values are 'beos', 'dl', 'dlfcn', 'win32' and 'vms'\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
print STDERR "No sanity errors detected!\n" if $errorcnt == 0;
|
print STDERR "No sanity errors detected!\n" if $errorcnt == 0;
|
||||||
|
|||||||
96
FAQ
96
FAQ
@@ -10,6 +10,7 @@ OpenSSL - Frequently Asked Questions
|
|||||||
* Why aren't tools like 'autoconf' and 'libtool' used?
|
* Why aren't tools like 'autoconf' and 'libtool' used?
|
||||||
* What is an 'engine' version?
|
* What is an 'engine' version?
|
||||||
* How do I check the authenticity of the OpenSSL distribution?
|
* How do I check the authenticity of the OpenSSL distribution?
|
||||||
|
* How does the versioning scheme work?
|
||||||
|
|
||||||
[LEGAL] Legal questions
|
[LEGAL] Legal questions
|
||||||
|
|
||||||
@@ -52,6 +53,9 @@ OpenSSL - Frequently Asked Questions
|
|||||||
* Why does the OpenSSL test suite fail in sha512t on x86 CPU?
|
* Why does the OpenSSL test suite fail in sha512t on x86 CPU?
|
||||||
* Why does compiler fail to compile sha512.c?
|
* Why does compiler fail to compile sha512.c?
|
||||||
* Test suite still fails, what to do?
|
* Test suite still fails, what to do?
|
||||||
|
* I think I've found a bug, what should I do?
|
||||||
|
* I'm SURE I've found a bug, how do I report it?
|
||||||
|
* I've found a security issue, how do I report it?
|
||||||
|
|
||||||
[PROG] Questions about programming with OpenSSL
|
[PROG] Questions about programming with OpenSSL
|
||||||
|
|
||||||
@@ -70,6 +74,7 @@ OpenSSL - Frequently Asked Questions
|
|||||||
* I think I've detected a memory leak, is this a bug?
|
* I think I've detected a memory leak, is this a bug?
|
||||||
* Why does Valgrind complain about the use of uninitialized data?
|
* Why does Valgrind complain about the use of uninitialized data?
|
||||||
* Why doesn't a memory BIO work when a file does?
|
* Why doesn't a memory BIO work when a file does?
|
||||||
|
* Where are the declarations and implementations of d2i_X509() etc?
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
|
|
||||||
@@ -78,11 +83,11 @@ 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.8k was released on Mar 25th, 2009.
|
OpenSSL 1.0.1e was released on Feb 11th, 2013.
|
||||||
|
|
||||||
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:
|
||||||
ftp://ftp.openssl.org/snapshot/>, or get it by anonymous CVS access.
|
ftp://ftp.openssl.org/snapshot/>, or get it by anonymous Git access.
|
||||||
|
|
||||||
|
|
||||||
* Where is the documentation?
|
* Where is the documentation?
|
||||||
@@ -94,14 +99,19 @@ explains how to install this library.
|
|||||||
|
|
||||||
OpenSSL includes a command line utility that can be used to perform a
|
OpenSSL includes a command line utility that can be used to perform a
|
||||||
variety of cryptographic functions. It is described in the openssl(1)
|
variety of cryptographic functions. It is described in the openssl(1)
|
||||||
manpage. Documentation for developers is currently being written. A
|
manpage. Documentation for developers is currently being written. Many
|
||||||
few manual pages already are available; overviews over libcrypto and
|
manual pages are available; overviews over libcrypto and
|
||||||
libssl are given in the crypto(3) and ssl(3) manpages.
|
libssl are given in the crypto(3) and ssl(3) manpages.
|
||||||
|
|
||||||
The OpenSSL manpages are installed in /usr/local/ssl/man/ (or a
|
The OpenSSL manpages are installed in /usr/local/ssl/man/ (or a
|
||||||
different directory if you specified one as described in INSTALL).
|
different directory if you specified one as described in INSTALL).
|
||||||
In addition, you can read the most current versions at
|
In addition, you can read the most current versions at
|
||||||
<URL: http://www.openssl.org/docs/>.
|
<URL: http://www.openssl.org/docs/>. Note that the online documents refer
|
||||||
|
to the very latest development versions of OpenSSL and may include features
|
||||||
|
not present in released versions. If in doubt refer to the documentation
|
||||||
|
that came with the version of OpenSSL you are using. The pod format
|
||||||
|
documentation is included in each OpenSSL distribution under the docs
|
||||||
|
directory.
|
||||||
|
|
||||||
For information on parts of libcrypto that are not yet documented, you
|
For information on parts of libcrypto that are not yet documented, you
|
||||||
might want to read Ariel Glenn's documentation on SSLeay 0.9, OpenSSL's
|
might want to read Ariel Glenn's documentation on SSLeay 0.9, OpenSSL's
|
||||||
@@ -127,7 +137,7 @@ 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
|
You can finder pointers to binary distributions in
|
||||||
http://www.openssl.org/related/binaries.html .
|
<URL: 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
|
||||||
@@ -166,6 +176,19 @@ just do:
|
|||||||
|
|
||||||
pgp TARBALL.asc
|
pgp TARBALL.asc
|
||||||
|
|
||||||
|
* How does the versioning scheme work?
|
||||||
|
|
||||||
|
After the release of OpenSSL 1.0.0 the versioning scheme changed. Letter
|
||||||
|
releases (e.g. 1.0.1a) can only contain bug and security fixes and no
|
||||||
|
new features. Minor releases change the last number (e.g. 1.0.2) and
|
||||||
|
can contain new features that retain binary compatibility. Changes to
|
||||||
|
the middle number are considered major releases and neither source nor
|
||||||
|
binary compatibility is guaranteed.
|
||||||
|
|
||||||
|
Therefore the answer to the common question "when will feature X be
|
||||||
|
backported to OpenSSL 1.0.0/0.9.8?" is "never" but it could appear
|
||||||
|
in the next minor release.
|
||||||
|
|
||||||
[LEGAL] =======================================================================
|
[LEGAL] =======================================================================
|
||||||
|
|
||||||
* Do I need patent licenses to use OpenSSL?
|
* Do I need patent licenses to use OpenSSL?
|
||||||
@@ -277,7 +300,7 @@ current directory in this case, but this has changed with 0.9.6a.)
|
|||||||
Check out the CA.pl(1) manual page. This provides a simple wrapper round
|
Check out the CA.pl(1) manual page. This provides a simple wrapper round
|
||||||
the 'req', 'verify', 'ca' and 'pkcs12' utilities. For finer control check
|
the 'req', 'verify', 'ca' and 'pkcs12' utilities. For finer control check
|
||||||
out the manual pages for the individual utilities and the certificate
|
out the manual pages for the individual utilities and the certificate
|
||||||
extensions documentation (currently in doc/openssl.txt).
|
extensions documentation (in ca(1), req(1), x509v3_config(5) )
|
||||||
|
|
||||||
|
|
||||||
* Why can't I create certificate requests?
|
* Why can't I create certificate requests?
|
||||||
@@ -459,7 +482,7 @@ administrators.
|
|||||||
Other projects do have other policies so you can for example extract the CA
|
Other projects do have other policies so you can for example extract the CA
|
||||||
bundle used by Mozilla and/or modssl as described in this article:
|
bundle used by Mozilla and/or modssl as described in this article:
|
||||||
|
|
||||||
http://www.mail-archive.com/modssl-users@modssl.org/msg16980.html
|
<URL: http://www.mail-archive.com/modssl-users@modssl.org/msg16980.html>
|
||||||
|
|
||||||
|
|
||||||
[BUILD] =======================================================================
|
[BUILD] =======================================================================
|
||||||
@@ -501,7 +524,7 @@ when you run the test suite (using "make test"). The message returned is
|
|||||||
"bc: 1 not implemented".
|
"bc: 1 not implemented".
|
||||||
|
|
||||||
The best way to deal with this is to find another implementation of bc
|
The best way to deal with this is to find another implementation of bc
|
||||||
and compile/install it. GNU bc (see http://www.gnu.org/software/software.html
|
and compile/install it. GNU bc (see <URL: http://www.gnu.org/software/software.html>
|
||||||
for download instructions) can be safely used, for example.
|
for download instructions) can be safely used, for example.
|
||||||
|
|
||||||
|
|
||||||
@@ -512,7 +535,7 @@ that the OpenSSL bntest throws at it. This gets triggered when you run the
|
|||||||
test suite (using "make test"). The message returned is "bc: stack empty".
|
test suite (using "make test"). The message returned is "bc: stack empty".
|
||||||
|
|
||||||
The best way to deal with this is to find another implementation of bc
|
The best way to deal with this is to find another implementation of bc
|
||||||
and compile/install it. GNU bc (see http://www.gnu.org/software/software.html
|
and compile/install it. GNU bc (see <URL: http://www.gnu.org/software/software.html>
|
||||||
for download instructions) can be safely used, for example.
|
for download instructions) can be safely used, for example.
|
||||||
|
|
||||||
|
|
||||||
@@ -705,6 +728,46 @@ never make sense, and tend to emerge when you least expect them. In order
|
|||||||
to identify one, drop optimization level, e.g. by editing CFLAG line in
|
to identify one, drop optimization level, e.g. by editing CFLAG line in
|
||||||
top-level Makefile, recompile and re-run the test.
|
top-level Makefile, recompile and re-run the test.
|
||||||
|
|
||||||
|
* I think I've found a bug, what should I do?
|
||||||
|
|
||||||
|
If you are a new user then it is quite likely you haven't found a bug and
|
||||||
|
something is happening you aren't familiar with. Check this FAQ, the associated
|
||||||
|
documentation and the mailing lists for similar queries. If you are still
|
||||||
|
unsure whether it is a bug or not submit a query to the openssl-users mailing
|
||||||
|
list.
|
||||||
|
|
||||||
|
|
||||||
|
* I'm SURE I've found a bug, how do I report it?
|
||||||
|
|
||||||
|
Bug reports with no security implications should be sent to the request
|
||||||
|
tracker. This can be done by mailing the report to <rt@openssl.org> (or its
|
||||||
|
alias <openssl-bugs@openssl.org>), please note that messages sent to the
|
||||||
|
request tracker also appear in the public openssl-dev mailing list.
|
||||||
|
|
||||||
|
The report should be in plain text. Any patches should be sent as
|
||||||
|
plain text attachments because some mailers corrupt patches sent inline.
|
||||||
|
If your issue affects multiple versions of OpenSSL check any patches apply
|
||||||
|
cleanly and, if possible include patches to each affected version.
|
||||||
|
|
||||||
|
The report should be given a meaningful subject line briefly summarising the
|
||||||
|
issue. Just "bug in OpenSSL" or "bug in OpenSSL 0.9.8n" is not very helpful.
|
||||||
|
|
||||||
|
By sending reports to the request tracker the bug can then be given a priority
|
||||||
|
and assigned to the appropriate maintainer. The history of discussions can be
|
||||||
|
accessed and if the issue has been addressed or a reason why not. If patches
|
||||||
|
are only sent to openssl-dev they can be mislaid if a team member has to
|
||||||
|
wade through months of old messages to review the discussion.
|
||||||
|
|
||||||
|
See also <URL: http://www.openssl.org/support/rt.html>
|
||||||
|
|
||||||
|
|
||||||
|
* I've found a security issue, how do I report it?
|
||||||
|
|
||||||
|
If you think your bug has security implications then please send it to
|
||||||
|
openssl-security@openssl.org if you don't get a prompt reply at least
|
||||||
|
acknowledging receipt then resend or mail it directly to one of the
|
||||||
|
more active team members (e.g. Steve).
|
||||||
|
|
||||||
[PROG] ========================================================================
|
[PROG] ========================================================================
|
||||||
|
|
||||||
* Is OpenSSL thread-safe?
|
* Is OpenSSL thread-safe?
|
||||||
@@ -718,7 +781,7 @@ file.
|
|||||||
Multi-threaded applications must provide two callback functions to
|
Multi-threaded applications must provide two callback functions to
|
||||||
OpenSSL by calling CRYPTO_set_locking_callback() and
|
OpenSSL by calling CRYPTO_set_locking_callback() and
|
||||||
CRYPTO_set_id_callback(), for all versions of OpenSSL up to and
|
CRYPTO_set_id_callback(), for all versions of OpenSSL up to and
|
||||||
including 0.9.8[abc...]. As of version 0.9.9, CRYPTO_set_id_callback()
|
including 0.9.8[abc...]. As of version 1.0.0, CRYPTO_set_id_callback()
|
||||||
and associated APIs are deprecated by CRYPTO_THREADID_set_callback()
|
and associated APIs are deprecated by CRYPTO_THREADID_set_callback()
|
||||||
and friends. This is described in the threads(3) manpage.
|
and friends. This is described in the threads(3) manpage.
|
||||||
|
|
||||||
@@ -964,4 +1027,15 @@ is needed. This must be done by calling:
|
|||||||
See the manual pages for more details.
|
See the manual pages for more details.
|
||||||
|
|
||||||
|
|
||||||
|
* Where are the declarations and implementations of d2i_X509() etc?
|
||||||
|
|
||||||
|
These are defined and implemented by macros of the form:
|
||||||
|
|
||||||
|
|
||||||
|
DECLARE_ASN1_FUNCTIONS(X509) and IMPLEMENT_ASN1_FUNCTIONS(X509)
|
||||||
|
|
||||||
|
The implementation passes an ASN1 "template" defining the structure into an
|
||||||
|
ASN1 interpreter using generalised functions such as ASN1_item_d2i().
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
|
|||||||
6
INSTALL
6
INSTALL
@@ -103,6 +103,12 @@
|
|||||||
define preprocessor symbols, specify additional libraries,
|
define preprocessor symbols, specify additional libraries,
|
||||||
library directories or other compiler options.
|
library directories or other compiler options.
|
||||||
|
|
||||||
|
-DHAVE_CRYPTODEV Enable the BSD cryptodev engine even if we are not using
|
||||||
|
BSD. Useful if you are running ocf-linux or something
|
||||||
|
similar. Once enabled you can also enable the use of
|
||||||
|
cryptodev digests, which is usually slower unless you have
|
||||||
|
large amounts data. Use -DUSE_CRYPTODEV_DIGESTS to force
|
||||||
|
it.
|
||||||
|
|
||||||
Installation in Detail
|
Installation in Detail
|
||||||
----------------------
|
----------------------
|
||||||
|
|||||||
52
INSTALL.VMS
52
INSTALL.VMS
@@ -71,7 +71,7 @@ the top to understand how to use them. However, if you want to
|
|||||||
compile all you can get, the simplest is to use MAKEVMS.COM in the top
|
compile all you can get, the simplest is to use MAKEVMS.COM in the top
|
||||||
directory. The syntax is the following:
|
directory. The syntax is the following:
|
||||||
|
|
||||||
@MAKEVMS <option> <rsaref-p> <debug-p> [<compiler>]
|
@MAKEVMS <option> <bits> <debug-p> [<compiler>]
|
||||||
|
|
||||||
<option> must be one of the following:
|
<option> must be one of the following:
|
||||||
|
|
||||||
@@ -87,24 +87,11 @@ directory. The syntax is the following:
|
|||||||
TEST Just build the "[.xxx.EXE.TEST]" test programs for OpenSSL.
|
TEST Just build the "[.xxx.EXE.TEST]" test programs for OpenSSL.
|
||||||
APPS Just build the "[.xxx.EXE.APPS]" application programs for OpenSSL.
|
APPS Just build the "[.xxx.EXE.APPS]" application programs for OpenSSL.
|
||||||
|
|
||||||
<rsaref-p> must be one of the following:
|
<bits> must be one of the following:
|
||||||
|
|
||||||
RSAREF compile using the RSAREF Library
|
"" compile using default pointer size
|
||||||
NORSAREF compile without using RSAREF
|
32 compile using 32 bit pointer size
|
||||||
|
64 compile using 64 bit pointer size
|
||||||
Note 0: The RSAREF library IS NO LONGER NEEDED. The RSA patent
|
|
||||||
expires September 20, 2000, and RSA Security chose to make
|
|
||||||
the algorithm public domain two weeks before that.
|
|
||||||
|
|
||||||
Note 1: If you still want to use RSAREF, the library is NOT INCLUDED
|
|
||||||
and you have to download it. RSA Security doesn't carry it
|
|
||||||
any more, but there are a number of places where you can find
|
|
||||||
it. You have to get the ".tar-Z" file as the ".zip" file
|
|
||||||
doesn't have the directory structure stored. You have to
|
|
||||||
extract the file into the [.RSAREF] directory as that is where
|
|
||||||
the scripts will look for the files.
|
|
||||||
|
|
||||||
Note 2: I have never done this, so I've no idea if it works or not.
|
|
||||||
|
|
||||||
<debug-p> must be one of the following:
|
<debug-p> must be one of the following:
|
||||||
|
|
||||||
@@ -117,12 +104,13 @@ Note 2: I have never done this, so I've no idea if it works or not.
|
|||||||
GNUC For GNU C.
|
GNUC For GNU C.
|
||||||
|
|
||||||
|
|
||||||
You will find the crypto library in [.xxx.EXE.CRYPTO], called LIBCRYPTO.OLB,
|
You will find the crypto library in [.xxx.EXE.CRYPTO] (where xxx is VAX,
|
||||||
where xxx is VAX or AXP. You will find the SSL library in [.xxx.EXE.SSL],
|
ALPHA or IA64), called SSL_LIBCRYPTO32.OLB or SSL_LIBCRYPTO.OLB depending
|
||||||
named LIBSSL.OLB, and you will find a bunch of useful programs in
|
on how it was built. You will find the SSL library in [.xxx.EXE.SSL],
|
||||||
[.xxx.EXE.APPS]. However, these shouldn't be used right off unless it's
|
named SSL_LIBSSL32.OLB or SSL_LIBSSL.OLB, and you will find a bunch of
|
||||||
just to test them. For production use, make sure you install first, see
|
useful programs in [.xxx.EXE.APPS]. However, these shouldn't be used
|
||||||
Installation below.
|
right off unless it's just to test them. For production use, make sure
|
||||||
|
you install first, see Installation below.
|
||||||
|
|
||||||
Note 1: Some programs in this package require a TCP/IP library.
|
Note 1: Some programs in this package require a TCP/IP library.
|
||||||
|
|
||||||
@@ -170,12 +158,14 @@ Installation:
|
|||||||
|
|
||||||
Installation is easy, just do the following:
|
Installation is easy, just do the following:
|
||||||
|
|
||||||
@INSTALL <root>
|
@INSTALL <root> <bits>
|
||||||
|
|
||||||
<root> is the directory in which everything will be installed,
|
<root> is the directory in which everything will be installed,
|
||||||
subdirectories, libraries, header files, programs and startup command
|
subdirectories, libraries, header files, programs and startup command
|
||||||
procedures.
|
procedures.
|
||||||
|
|
||||||
|
<bits> works the same way as for MAKEVMS.COM
|
||||||
|
|
||||||
N.B.: INSTALL.COM builds a new directory structure, different from
|
N.B.: INSTALL.COM builds a new directory structure, different from
|
||||||
the directory tree where you have now build OpenSSL.
|
the directory tree where you have now build OpenSSL.
|
||||||
|
|
||||||
@@ -196,6 +186,10 @@ following command procedures:
|
|||||||
sets up the symbols to the applications. Should be called
|
sets up the symbols to the applications. Should be called
|
||||||
from for example SYS$MANAGER:SYLOGIN.COM
|
from for example SYS$MANAGER:SYLOGIN.COM
|
||||||
|
|
||||||
|
OPENSSL_UNDO.COM
|
||||||
|
|
||||||
|
deassigns the logical names created with OPENSSL_STARTUP.COM.
|
||||||
|
|
||||||
The logical names that are set up are the following:
|
The logical names that are set up are the following:
|
||||||
|
|
||||||
SSLROOT a dotted concealed logical name pointing at the
|
SSLROOT a dotted concealed logical name pointing at the
|
||||||
@@ -203,7 +197,6 @@ The logical names that are set up are the following:
|
|||||||
|
|
||||||
SSLCERTS Initially an empty directory, this is the default
|
SSLCERTS Initially an empty directory, this is the default
|
||||||
location for certificate files.
|
location for certificate files.
|
||||||
SSLMISC Various scripts.
|
|
||||||
SSLPRIVATE Initially an empty directory, this is the default
|
SSLPRIVATE Initially an empty directory, this is the default
|
||||||
location for private key files.
|
location for private key files.
|
||||||
|
|
||||||
@@ -211,8 +204,9 @@ The logical names that are set up are the following:
|
|||||||
programs.
|
programs.
|
||||||
SSLINCLUDE Contains the header files needed if you want to
|
SSLINCLUDE Contains the header files needed if you want to
|
||||||
compile programs with libcrypto or libssl.
|
compile programs with libcrypto or libssl.
|
||||||
SSLLIB Contains the OpenSSL library files (LIBCRYPTO.OLB
|
SSLLIB Contains the OpenSSL library files themselves:
|
||||||
and LIBSSL.OLB) themselves.
|
- SSL_LIBCRYPTO32.OLB and SSL_LIBSSL32.OLB or
|
||||||
|
- SSL_LIBCRYPTO.OLB and SSL_LIBSSL.OLB
|
||||||
|
|
||||||
OPENSSL Same as SSLINCLUDE. This is because the standard
|
OPENSSL Same as SSLINCLUDE. This is because the standard
|
||||||
way to include OpenSSL header files from version
|
way to include OpenSSL header files from version
|
||||||
@@ -296,4 +290,4 @@ have any ideas.
|
|||||||
|
|
||||||
--
|
--
|
||||||
Richard Levitte <richard@levitte.org>
|
Richard Levitte <richard@levitte.org>
|
||||||
2000-02-27
|
2000-02-27, 2011-03-18
|
||||||
|
|||||||
47
INSTALL.W32
47
INSTALL.W32
@@ -27,9 +27,9 @@
|
|||||||
|
|
||||||
- Netwide Assembler, a.k.a. NASM, available from http://nasm.sourceforge.net/
|
- Netwide Assembler, a.k.a. NASM, available from http://nasm.sourceforge.net/
|
||||||
is required if you intend to utilize assembler modules. Note that NASM
|
is required if you intend to utilize assembler modules. Note that NASM
|
||||||
is the only supported assembler.
|
is now the only supported assembler.
|
||||||
|
|
||||||
If you are compiling from a tarball or a CVS snapshot then the Win32 files
|
If you are compiling from a tarball or a Git snapshot then the Win32 files
|
||||||
may well be not up to date. This may mean that some "tweaking" is required to
|
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?)
|
get it all to work. See the trouble shooting section later on for if (when?)
|
||||||
it goes wrong.
|
it goes wrong.
|
||||||
@@ -41,9 +41,9 @@
|
|||||||
C++, then you will need already mentioned Netwide Assembler binary,
|
C++, then you will need already mentioned Netwide Assembler binary,
|
||||||
nasmw.exe or nasm.exe, to be available on your %PATH%.
|
nasmw.exe or nasm.exe, to be available on your %PATH%.
|
||||||
|
|
||||||
Firstly you should run Configure:
|
Firstly you should run Configure with platform VC-WIN32:
|
||||||
|
|
||||||
> perl Configure VC-WIN32 --prefix=c:/some/openssl/dir
|
> perl Configure VC-WIN32 --prefix=c:\some\openssl\dir
|
||||||
|
|
||||||
Where the prefix argument specifies where OpenSSL will be installed to.
|
Where the prefix argument specifies where OpenSSL will be installed to.
|
||||||
|
|
||||||
@@ -56,6 +56,7 @@
|
|||||||
|
|
||||||
- If you don't want to use the assembly language files at all then run:
|
- If you don't want to use the assembly language files at all then run:
|
||||||
|
|
||||||
|
> perl Configure VC-WIN32 no-asm --prefix=c:/some/openssl/dir
|
||||||
> ms\do_ms
|
> ms\do_ms
|
||||||
|
|
||||||
If you get errors about things not having numbers assigned then check the
|
If you get errors about things not having numbers assigned then check the
|
||||||
@@ -80,16 +81,13 @@
|
|||||||
|
|
||||||
There are various changes you can make to the Win32 compile
|
There are various changes you can make to the Win32 compile
|
||||||
environment. By default the library is not compiled with debugging
|
environment. By default the library is not compiled with debugging
|
||||||
symbols. If you add 'debug' to the mk1mf.pl lines in the do_* batch
|
symbols. If you use the platform debug-VC-WIN32 instead of VC-WIN32
|
||||||
file then debugging symbols will be compiled in. Note that mk1mf.pl
|
then debugging symbols will be compiled in.
|
||||||
expects the platform to be the last argument on the command line, so
|
|
||||||
'debug' must appear before that, as all other options.
|
|
||||||
|
|
||||||
|
By default in 1.0.0 OpenSSL will compile builtin ENGINES into the
|
||||||
By default in 0.9.8 OpenSSL will compile builtin ENGINES into the
|
separate shared librariesy. If you specify the "enable-static-engine"
|
||||||
libeay32.dll shared library. If you specify the "no-static-engine"
|
|
||||||
option on the command line to Configure the shared library build
|
option on the command line to Configure the shared library build
|
||||||
(ms\ntdll.mak) will compile the engines as separate DLLs.
|
(ms\ntdll.mak) will compile the engines into libeay32.dll instead.
|
||||||
|
|
||||||
The default Win32 environment is to leave out any Windows NT specific
|
The default Win32 environment is to leave out any Windows NT specific
|
||||||
features.
|
features.
|
||||||
@@ -102,7 +100,6 @@
|
|||||||
ms\nt.mak
|
ms\nt.mak
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Borland C++ builder 5
|
Borland C++ builder 5
|
||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
@@ -188,6 +185,15 @@
|
|||||||
required. Run the installers and do whatever magic they say it takes
|
required. Run the installers and do whatever magic they say it takes
|
||||||
to start MSYS bash shell with GNU tools on its PATH.
|
to start MSYS bash shell with GNU tools on its PATH.
|
||||||
|
|
||||||
|
N.B. Since source tar-ball can contain symbolic links, it's essential
|
||||||
|
that you use accompanying MSYS tar to unpack the source. It will
|
||||||
|
either handle them in one way or another or fail to extract them,
|
||||||
|
which does the trick too. Latter means that you may safely ignore all
|
||||||
|
"cannot create symlink" messages, as they will be "re-created" at
|
||||||
|
configure stage by copying corresponding files. Alternative programs
|
||||||
|
were observed to create empty files instead, which results in build
|
||||||
|
failure.
|
||||||
|
|
||||||
* Compile OpenSSL:
|
* Compile OpenSSL:
|
||||||
|
|
||||||
$ ./config
|
$ ./config
|
||||||
@@ -251,7 +257,7 @@
|
|||||||
|
|
||||||
then ms\do_XXX should not give a warning any more. However the numbers that
|
then ms\do_XXX should not give a warning any more. However the numbers that
|
||||||
get assigned by this technique may not match those that eventually get
|
get assigned by this technique may not match those that eventually get
|
||||||
assigned in the CVS tree: so anything linked against this version of the
|
assigned in the Git tree: so anything linked against this version of the
|
||||||
library may need to be recompiled.
|
library may need to be recompiled.
|
||||||
|
|
||||||
If you get errors about unresolved symbols there are several possible
|
If you get errors about unresolved symbols there are several possible
|
||||||
@@ -300,7 +306,18 @@
|
|||||||
desktop, which is not available to service processes. The toolkit is
|
desktop, which is not available to service processes. The toolkit is
|
||||||
designed to detect in which context it's currently executed, GUI,
|
designed to detect in which context it's currently executed, GUI,
|
||||||
console app or service, and act accordingly, namely whether or not to
|
console app or service, and act accordingly, namely whether or not to
|
||||||
actually make GUI calls.
|
actually make GUI calls. Additionally those who wish to
|
||||||
|
/DELAYLOAD:GDI32.DLL and /DELAYLOAD:USER32.DLL and actually keep them
|
||||||
|
off service process should consider implementing and exporting from
|
||||||
|
.exe image in question own _OPENSSL_isservice not relying on USER32.DLL.
|
||||||
|
E.g., on Windows Vista and later you could:
|
||||||
|
|
||||||
|
__declspec(dllexport) __cdecl BOOL _OPENSSL_isservice(void)
|
||||||
|
{ DWORD sess;
|
||||||
|
if (ProcessIdToSessionId(GetCurrentProcessId(),&sess))
|
||||||
|
return sess==0;
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
If you link with OpenSSL .DLLs, then you're expected to include into
|
If you link with OpenSSL .DLLs, then you're expected to include into
|
||||||
your application code small "shim" snippet, which provides glue between
|
your application code small "shim" snippet, which provides glue between
|
||||||
|
|||||||
2
LICENSE
2
LICENSE
@@ -12,7 +12,7 @@
|
|||||||
---------------
|
---------------
|
||||||
|
|
||||||
/* ====================================================================
|
/* ====================================================================
|
||||||
* Copyright (c) 1998-2008 The OpenSSL Project. All rights reserved.
|
* Copyright (c) 1998-2011 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
|
||||||
|
|||||||
142
Makefile.org
142
Makefile.org
@@ -69,8 +69,9 @@ RANLIB= ranlib
|
|||||||
NM= nm
|
NM= nm
|
||||||
PERL= perl
|
PERL= perl
|
||||||
TAR= tar
|
TAR= tar
|
||||||
TARFLAGS= --no-recursion
|
TARFLAGS= --no-recursion --record-size=10240
|
||||||
MAKEDEPPROG=makedepend
|
MAKEDEPPROG=makedepend
|
||||||
|
LIBDIR=lib
|
||||||
|
|
||||||
# We let the C compiler driver to take care of .s files. This is done in
|
# We let the C compiler driver to take care of .s files. This is done in
|
||||||
# order to be excused from maintaining a separate set of architecture
|
# order to be excused from maintaining a separate set of architecture
|
||||||
@@ -98,6 +99,8 @@ SHA1_ASM_OBJ=
|
|||||||
RMD160_ASM_OBJ=
|
RMD160_ASM_OBJ=
|
||||||
WP_ASM_OBJ=
|
WP_ASM_OBJ=
|
||||||
CMLL_ENC=
|
CMLL_ENC=
|
||||||
|
MODES_ASM_OBJ=
|
||||||
|
ENGINES_ASM_OBJ=
|
||||||
PERLASM_SCHEME=
|
PERLASM_SCHEME=
|
||||||
|
|
||||||
# KRB5 stuff
|
# KRB5 stuff
|
||||||
@@ -108,7 +111,32 @@ LIBKRB5=
|
|||||||
ZLIB_INCLUDE=
|
ZLIB_INCLUDE=
|
||||||
LIBZLIB=
|
LIBZLIB=
|
||||||
|
|
||||||
|
# TOP level FIPS install directory.
|
||||||
|
FIPSDIR=
|
||||||
|
|
||||||
|
# This is the location of fipscanister.o and friends.
|
||||||
|
# The FIPS module build will place it $(INSTALLTOP)/lib
|
||||||
|
# but since $(INSTALLTOP) can only take the default value
|
||||||
|
# when the module is built it will be in /usr/local/ssl/lib
|
||||||
|
# $(INSTALLTOP) for this build may be different so hard
|
||||||
|
# code the path.
|
||||||
|
|
||||||
|
FIPSLIBDIR=
|
||||||
|
|
||||||
|
# The location of the library which contains fipscanister.o
|
||||||
|
# normally it will be libcrypto unless fipsdso is set in which
|
||||||
|
# case it will be libfips. If not compiling in FIPS mode at all
|
||||||
|
# this is empty making it a useful test for a FIPS compile.
|
||||||
|
|
||||||
|
FIPSCANLIB=
|
||||||
|
|
||||||
|
# Shared library base address. Currently only used on Windows.
|
||||||
|
#
|
||||||
|
|
||||||
|
BASEADDR=
|
||||||
|
|
||||||
DIRS= crypto ssl engines apps test tools
|
DIRS= crypto ssl engines apps test tools
|
||||||
|
ENGDIRS= ccgost
|
||||||
SHLIBDIRS= crypto ssl
|
SHLIBDIRS= crypto ssl
|
||||||
|
|
||||||
# dirs in crypto to build
|
# dirs in crypto to build
|
||||||
@@ -119,7 +147,7 @@ SDIRS= \
|
|||||||
bn ec rsa dsa ecdsa dh ecdh dso engine \
|
bn ec rsa dsa ecdsa dh ecdh dso engine \
|
||||||
buffer bio stack lhash rand err \
|
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 \
|
||||||
cms pqueue ts jpake store
|
cms pqueue ts jpake srp store cmac
|
||||||
# keep in mind that the above list is adjusted by ./Configure
|
# keep in mind that the above list is adjusted by ./Configure
|
||||||
# according to no-xxx arguments...
|
# according to no-xxx arguments...
|
||||||
|
|
||||||
@@ -170,7 +198,7 @@ CLEARENV= TOP= && unset TOP $${LIB+LIB} $${LIBS+LIBS} \
|
|||||||
$${EXHEADER+EXHEADER} $${HEADER+HEADER} \
|
$${EXHEADER+EXHEADER} $${HEADER+HEADER} \
|
||||||
$${GENERAL+GENERAL} $${CFLAGS+CFLAGS} \
|
$${GENERAL+GENERAL} $${CFLAGS+CFLAGS} \
|
||||||
$${ASFLAGS+ASFLAGS} $${AFLAGS+AFLAGS} \
|
$${ASFLAGS+ASFLAGS} $${AFLAGS+AFLAGS} \
|
||||||
$${LDCMD+LDCMD} $${LDFLAGS+LDFLAGS} \
|
$${LDCMD+LDCMD} $${LDFLAGS+LDFLAGS} $${SCRIPTS+SCRIPTS} \
|
||||||
$${SHAREDCMD+SHAREDCMD} $${SHAREDFLAGS+SHAREDFLAGS} \
|
$${SHAREDCMD+SHAREDCMD} $${SHAREDFLAGS+SHAREDFLAGS} \
|
||||||
$${SHARED_LIB+SHARED_LIB} $${LIBEXTRAS+LIBEXTRAS}
|
$${SHARED_LIB+SHARED_LIB} $${LIBEXTRAS+LIBEXTRAS}
|
||||||
|
|
||||||
@@ -178,16 +206,18 @@ BUILDENV= PLATFORM='$(PLATFORM)' PROCESSOR='$(PROCESSOR)' \
|
|||||||
CC='$(CC)' CFLAG='$(CFLAG)' \
|
CC='$(CC)' CFLAG='$(CFLAG)' \
|
||||||
AS='$(CC)' ASFLAG='$(CFLAG) -c' \
|
AS='$(CC)' ASFLAG='$(CFLAG) -c' \
|
||||||
AR='$(AR)' NM='$(NM)' RANLIB='$(RANLIB)' \
|
AR='$(AR)' NM='$(NM)' RANLIB='$(RANLIB)' \
|
||||||
CROSS_COMPILE_PREFIX='$(CROSS_COMPILE_PREFIX)' \
|
CROSS_COMPILE='$(CROSS_COMPILE)' \
|
||||||
PERL='$(PERL)' \
|
PERL='$(PERL)' ENGDIRS='$(ENGDIRS)' \
|
||||||
SDIRS='$(SDIRS)' LIBRPATH='$(INSTALLTOP)/lib' \
|
SDIRS='$(SDIRS)' LIBRPATH='$(INSTALLTOP)/$(LIBDIR)' \
|
||||||
INSTALL_PREFIX='$(INSTALL_PREFIX)' \
|
INSTALL_PREFIX='$(INSTALL_PREFIX)' \
|
||||||
INSTALLTOP='$(INSTALLTOP)' OPENSSLDIR='$(OPENSSLDIR)' \
|
INSTALLTOP='$(INSTALLTOP)' OPENSSLDIR='$(OPENSSLDIR)' \
|
||||||
|
LIBDIR='$(LIBDIR)' \
|
||||||
MAKEDEPEND='$$$${TOP}/util/domd $$$${TOP} -MD $(MAKEDEPPROG)' \
|
MAKEDEPEND='$$$${TOP}/util/domd $$$${TOP} -MD $(MAKEDEPPROG)' \
|
||||||
DEPFLAG='-DOPENSSL_NO_DEPRECATED $(DEPFLAG)' \
|
DEPFLAG='-DOPENSSL_NO_DEPRECATED $(DEPFLAG)' \
|
||||||
MAKEDEPPROG='$(MAKEDEPPROG)' \
|
MAKEDEPPROG='$(MAKEDEPPROG)' \
|
||||||
SHARED_LDFLAGS='$(SHARED_LDFLAGS)' \
|
SHARED_LDFLAGS='$(SHARED_LDFLAGS)' \
|
||||||
KRB5_INCLUDES='$(KRB5_INCLUDES)' LIBKRB5='$(LIBKRB5)' \
|
KRB5_INCLUDES='$(KRB5_INCLUDES)' LIBKRB5='$(LIBKRB5)' \
|
||||||
|
ZLIB_INCLUDE='$(ZLIB_INCLUDE)' LIBZLIB='$(LIBZLIB)' \
|
||||||
EXE_EXT='$(EXE_EXT)' SHARED_LIBS='$(SHARED_LIBS)' \
|
EXE_EXT='$(EXE_EXT)' SHARED_LIBS='$(SHARED_LIBS)' \
|
||||||
SHLIB_EXT='$(SHLIB_EXT)' SHLIB_TARGET='$(SHLIB_TARGET)' \
|
SHLIB_EXT='$(SHLIB_EXT)' SHLIB_TARGET='$(SHLIB_TARGET)' \
|
||||||
PEX_LIBS='$(PEX_LIBS)' EX_LIBS='$(EX_LIBS)' \
|
PEX_LIBS='$(PEX_LIBS)' EX_LIBS='$(EX_LIBS)' \
|
||||||
@@ -200,7 +230,12 @@ BUILDENV= PLATFORM='$(PLATFORM)' PROCESSOR='$(PROCESSOR)' \
|
|||||||
MD5_ASM_OBJ='$(MD5_ASM_OBJ)' \
|
MD5_ASM_OBJ='$(MD5_ASM_OBJ)' \
|
||||||
RMD160_ASM_OBJ='$(RMD160_ASM_OBJ)' \
|
RMD160_ASM_OBJ='$(RMD160_ASM_OBJ)' \
|
||||||
WP_ASM_OBJ='$(WP_ASM_OBJ)' \
|
WP_ASM_OBJ='$(WP_ASM_OBJ)' \
|
||||||
|
MODES_ASM_OBJ='$(MODES_ASM_OBJ)' \
|
||||||
|
ENGINES_ASM_OBJ='$(ENGINES_ASM_OBJ)' \
|
||||||
PERLASM_SCHEME='$(PERLASM_SCHEME)' \
|
PERLASM_SCHEME='$(PERLASM_SCHEME)' \
|
||||||
|
FIPSLIBDIR='${FIPSLIBDIR}' \
|
||||||
|
FIPSDIR='${FIPSDIR}' \
|
||||||
|
FIPSCANLIB="$${FIPSCANLIB:-$(FIPSCANLIB)}" \
|
||||||
THIS=$${THIS:-$@} MAKEFILE=Makefile MAKEOVERRIDES=
|
THIS=$${THIS:-$@} MAKEFILE=Makefile MAKEOVERRIDES=
|
||||||
# MAKEOVERRIDES= effectively "equalizes" GNU-ish and SysV-ish make flavors,
|
# MAKEOVERRIDES= effectively "equalizes" GNU-ish and SysV-ish make flavors,
|
||||||
# which in turn eliminates ambiguities in variable treatment with -e.
|
# which in turn eliminates ambiguities in variable treatment with -e.
|
||||||
@@ -254,9 +289,21 @@ all_testapps: build_libs build_testapps
|
|||||||
build_testapps:
|
build_testapps:
|
||||||
@dir=crypto; target=testapps; $(BUILD_ONE_CMD)
|
@dir=crypto; target=testapps; $(BUILD_ONE_CMD)
|
||||||
|
|
||||||
libcrypto$(SHLIB_EXT): libcrypto.a
|
fips_premain_dso$(EXE_EXT): libcrypto.a
|
||||||
|
[ -z "$(FIPSCANLIB)" ] || $(CC) $(CFLAG) -Iinclude \
|
||||||
|
-DFINGERPRINT_PREMAIN_DSO_LOAD -o $@ \
|
||||||
|
$(FIPSLIBDIR)fips_premain.c $(FIPSLIBDIR)fipscanister.o \
|
||||||
|
libcrypto.a $(EX_LIBS)
|
||||||
|
|
||||||
|
libcrypto$(SHLIB_EXT): libcrypto.a fips_premain_dso$(EXE_EXT)
|
||||||
@if [ "$(SHLIB_TARGET)" != "" ]; then \
|
@if [ "$(SHLIB_TARGET)" != "" ]; then \
|
||||||
$(MAKE) SHLIBDIRS=crypto build-shared; \
|
if [ "$(FIPSCANLIB)" = "libcrypto" ]; then \
|
||||||
|
FIPSLD_LIBCRYPTO=libcrypto.a ; \
|
||||||
|
FIPSLD_CC="$(CC)"; CC=$(FIPSDIR)/bin/fipsld; \
|
||||||
|
export CC FIPSLD_CC FIPSLD_LIBCRYPTO; \
|
||||||
|
fi; \
|
||||||
|
$(MAKE) -e SHLIBDIRS=crypto CC=$${CC:-$(CC)} build-shared; \
|
||||||
|
touch -c fips_premain_dso$(EXE_EXT); \
|
||||||
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; \
|
||||||
exit 1; \
|
exit 1; \
|
||||||
@@ -297,7 +344,7 @@ build-shared: do_$(SHLIB_TARGET) link-shared
|
|||||||
|
|
||||||
do_$(SHLIB_TARGET):
|
do_$(SHLIB_TARGET):
|
||||||
@ set -e; libs='-L. $(SHLIBDEPS)'; for i in $(SHLIBDIRS); do \
|
@ set -e; libs='-L. $(SHLIBDEPS)'; for i in $(SHLIBDIRS); do \
|
||||||
if [ "$(SHLIBDIRS)" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
if [ "$$i" = "ssl" -a -n "$(LIBKRB5)" ]; then \
|
||||||
libs="$(LIBKRB5) $$libs"; \
|
libs="$(LIBKRB5) $$libs"; \
|
||||||
fi; \
|
fi; \
|
||||||
$(CLEARENV) && $(MAKE) -f Makefile.shared -e $(BUILDENV) \
|
$(CLEARENV) && $(MAKE) -f Makefile.shared -e $(BUILDENV) \
|
||||||
@@ -311,40 +358,43 @@ do_$(SHLIB_TARGET):
|
|||||||
libcrypto.pc: Makefile
|
libcrypto.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}/$(LIBDIR)'; \
|
||||||
echo 'includedir=$${prefix}/include'; \
|
echo 'includedir=$${prefix}/include'; \
|
||||||
echo ''; \
|
echo ''; \
|
||||||
echo 'Name: OpenSSL-libcrypto'; \
|
echo 'Name: OpenSSL-libcrypto'; \
|
||||||
echo 'Description: OpenSSL cryptography library'; \
|
echo 'Description: OpenSSL cryptography library'; \
|
||||||
echo 'Version: '$(VERSION); \
|
echo 'Version: '$(VERSION); \
|
||||||
echo 'Requires: '; \
|
echo 'Requires: '; \
|
||||||
echo 'Libs: -L$${libdir} -lcrypto $(EX_LIBS)'; \
|
echo 'Libs: -L$${libdir} -lcrypto'; \
|
||||||
|
echo 'Libs.private: $(EX_LIBS)'; \
|
||||||
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libcrypto.pc
|
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libcrypto.pc
|
||||||
|
|
||||||
libssl.pc: Makefile
|
libssl.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}/$(LIBDIR)'; \
|
||||||
echo 'includedir=$${prefix}/include'; \
|
echo 'includedir=$${prefix}/include'; \
|
||||||
echo ''; \
|
echo ''; \
|
||||||
echo 'Name: OpenSSL'; \
|
echo 'Name: OpenSSL'; \
|
||||||
echo 'Description: Secure Sockets Layer and cryptography libraries'; \
|
echo 'Description: Secure Sockets Layer and cryptography libraries'; \
|
||||||
echo 'Version: '$(VERSION); \
|
echo 'Version: '$(VERSION); \
|
||||||
echo 'Requires: '; \
|
echo 'Requires: '; \
|
||||||
echo 'Libs: -L$${libdir} -lssl -lcrypto $(EX_LIBS)'; \
|
echo 'Libs: -L$${libdir} -lssl -lcrypto'; \
|
||||||
|
echo 'Libs.private: $(EX_LIBS)'; \
|
||||||
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libssl.pc
|
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libssl.pc
|
||||||
|
|
||||||
openssl.pc: Makefile
|
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}/$(LIBDIR)'; \
|
||||||
echo 'includedir=$${prefix}/include'; \
|
echo 'includedir=$${prefix}/include'; \
|
||||||
echo ''; \
|
echo ''; \
|
||||||
echo 'Name: OpenSSL'; \
|
echo 'Name: OpenSSL'; \
|
||||||
echo 'Description: Secure Sockets Layer and cryptography libraries and tools'; \
|
echo 'Description: Secure Sockets Layer and cryptography libraries and tools'; \
|
||||||
echo 'Version: '$(VERSION); \
|
echo 'Version: '$(VERSION); \
|
||||||
echo 'Requires: '; \
|
echo 'Requires: '; \
|
||||||
echo 'Libs: -L$${libdir} -lssl -lcrypto $(EX_LIBS)'; \
|
echo 'Libs: -L$${libdir} -lssl -lcrypto'; \
|
||||||
|
echo 'Libs.private: $(EX_LIBS)'; \
|
||||||
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > openssl.pc
|
echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > openssl.pc
|
||||||
|
|
||||||
Makefile: Makefile.org Configure config
|
Makefile: Makefile.org Configure config
|
||||||
@@ -353,7 +403,7 @@ Makefile: Makefile.org Configure config
|
|||||||
@false
|
@false
|
||||||
|
|
||||||
libclean:
|
libclean:
|
||||||
rm -f *.map *.so *.so.* *.dll engines/*.so engines/*.dll *.a engines/*.a */lib */*/lib
|
rm -f *.map *.so *.so.* *.dylib *.dll engines/*.so engines/*.dll engines/*.dylib *.a engines/*.a */lib */*/lib
|
||||||
|
|
||||||
clean: libclean
|
clean: libclean
|
||||||
rm -f shlib/*.o *.o core a.out fluff 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
|
||||||
@@ -390,12 +440,12 @@ dclean:
|
|||||||
|
|
||||||
rehash: rehash.time
|
rehash: rehash.time
|
||||||
rehash.time: certs apps
|
rehash.time: certs apps
|
||||||
@if [ -z "$(CROSS_COMPILE_PREFIX)" ]; then \
|
@if [ -z "$(CROSS_COMPILE)" ]; then \
|
||||||
(OPENSSL="`pwd`/util/opensslwrap.sh"; \
|
(OPENSSL="`pwd`/util/opensslwrap.sh"; \
|
||||||
[ -x "apps/openssl.exe" ] && OPENSSL="apps/openssl.exe" || :; \
|
[ -x "apps/openssl.exe" ] && OPENSSL="apps/openssl.exe" || :; \
|
||||||
OPENSSL_DEBUG_MEMORY=on; \
|
OPENSSL_DEBUG_MEMORY=on; \
|
||||||
export OPENSSL OPENSSL_DEBUG_MEMORY; \
|
export OPENSSL OPENSSL_DEBUG_MEMORY; \
|
||||||
$(PERL) tools/c_rehash certs) && \
|
$(PERL) tools/c_rehash certs/demo) && \
|
||||||
touch rehash.time; \
|
touch rehash.time; \
|
||||||
else :; fi
|
else :; fi
|
||||||
|
|
||||||
@@ -403,8 +453,8 @@ test: tests
|
|||||||
|
|
||||||
tests: rehash
|
tests: rehash
|
||||||
@(cd test && echo "testing..." && \
|
@(cd test && echo "testing..." && \
|
||||||
$(CLEARENV) && $(MAKE) -e $(BUILDENV) TOP=.. TESTS='$(TESTS)' OPENSSL_DEBUG_MEMORY=on tests );
|
$(CLEARENV) && $(MAKE) -e $(BUILDENV) TOP=.. TESTS='$(TESTS)' OPENSSL_DEBUG_MEMORY=on OPENSSL_CONF=../apps/openssl.cnf tests );
|
||||||
util/opensslwrap.sh version -a
|
OPENSSL_CONF=apps/openssl.cnf util/opensslwrap.sh version -a
|
||||||
|
|
||||||
report:
|
report:
|
||||||
@$(PERL) util/selftest.pl
|
@$(PERL) util/selftest.pl
|
||||||
@@ -420,9 +470,9 @@ tags:
|
|||||||
find . -name '[^.]*.[ch]' | xargs etags -a
|
find . -name '[^.]*.[ch]' | xargs etags -a
|
||||||
|
|
||||||
errors:
|
errors:
|
||||||
|
$(PERL) util/ck_errf.pl -strict */*.c */*/*.c
|
||||||
$(PERL) util/mkerr.pl -recurse -write
|
$(PERL) util/mkerr.pl -recurse -write
|
||||||
(cd engines; $(MAKE) PERL=$(PERL) errors)
|
(cd engines; $(MAKE) PERL=$(PERL) errors)
|
||||||
$(PERL) util/ck_errf.pl */*.c */*/*.c
|
|
||||||
|
|
||||||
stacks:
|
stacks:
|
||||||
$(PERL) util/mkstack.pl -write
|
$(PERL) util/mkstack.pl -write
|
||||||
@@ -492,9 +542,9 @@ install: all install_docs install_sw
|
|||||||
|
|
||||||
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)/$(LIBDIR) \
|
||||||
$(INSTALL_PREFIX)$(INSTALLTOP)/lib/engines \
|
$(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/engines \
|
||||||
$(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig \
|
$(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/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 \
|
||||||
@@ -505,14 +555,14 @@ install_sw:
|
|||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \
|
||||||
done;
|
done;
|
||||||
@set -e; target=install; $(RECURSIVE_BUILD_CMD)
|
@set -e; target=install; $(RECURSIVE_BUILD_CMD)
|
||||||
@set -e; for i in $(LIBS) ;\
|
@set -e; liblist="$(LIBS)"; for i in $$liblist ;\
|
||||||
do \
|
do \
|
||||||
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)/$(LIBDIR)/$$i.new; \
|
||||||
$(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
$(RANLIB) $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
|
||||||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i ); \
|
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i ); \
|
||||||
fi; \
|
fi; \
|
||||||
done;
|
done;
|
||||||
@set -e; if [ -n "$(SHARED_LIBS)" ]; then \
|
@set -e; if [ -n "$(SHARED_LIBS)" ]; then \
|
||||||
@@ -522,17 +572,17 @@ install_sw:
|
|||||||
if [ -f "$$i" -o -f "$$i.a" ]; then \
|
if [ -f "$$i" -o -f "$$i.a" ]; then \
|
||||||
( echo installing $$i; \
|
( echo installing $$i; \
|
||||||
if [ "$(PLATFORM)" != "Cygwin" ]; then \
|
if [ "$(PLATFORM)" != "Cygwin" ]; then \
|
||||||
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
|
||||||
chmod 555 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
chmod 555 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
|
||||||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i; \
|
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i; \
|
||||||
else \
|
else \
|
||||||
c=`echo $$i | sed 's/^lib\(.*\)\.dll\.a/cyg\1-$(SHLIB_VERSION_NUMBER).dll/'`; \
|
c=`echo $$i | sed 's/^lib\(.*\)\.dll\.a/cyg\1-$(SHLIB_VERSION_NUMBER).dll/'`; \
|
||||||
cp $$c $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new; \
|
cp $$c $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new; \
|
||||||
chmod 755 $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new; \
|
chmod 755 $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new; \
|
||||||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c; \
|
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c.new $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$c; \
|
||||||
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new; \
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new; \
|
||||||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/lib/$$i; \
|
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/$$i; \
|
||||||
fi ); \
|
fi ); \
|
||||||
if expr $(PLATFORM) : 'mingw' > /dev/null; then \
|
if expr $(PLATFORM) : 'mingw' > /dev/null; then \
|
||||||
( case $$i in \
|
( case $$i in \
|
||||||
@@ -547,7 +597,7 @@ install_sw:
|
|||||||
fi; \
|
fi; \
|
||||||
done; \
|
done; \
|
||||||
( here="`pwd`"; \
|
( here="`pwd`"; \
|
||||||
cd $(INSTALL_PREFIX)$(INSTALLTOP)/lib; \
|
cd $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR); \
|
||||||
$(MAKE) -f $$here/Makefile HERE="$$here" link-shared ); \
|
$(MAKE) -f $$here/Makefile HERE="$$here" link-shared ); \
|
||||||
if [ "$(INSTALLTOP)" != "/usr" ]; then \
|
if [ "$(INSTALLTOP)" != "/usr" ]; then \
|
||||||
echo 'OpenSSL shared libraries have been installed in:'; \
|
echo 'OpenSSL shared libraries have been installed in:'; \
|
||||||
@@ -556,12 +606,12 @@ install_sw:
|
|||||||
sed -e '1,/^$$/d' doc/openssl-shared.txt; \
|
sed -e '1,/^$$/d' doc/openssl-shared.txt; \
|
||||||
fi; \
|
fi; \
|
||||||
fi
|
fi
|
||||||
cp libcrypto.pc $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig
|
cp libcrypto.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig/libcrypto.pc
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig/libcrypto.pc
|
||||||
cp libssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig
|
cp libssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig/libssl.pc
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig/libssl.pc
|
||||||
cp openssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig
|
cp openssl.pc $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig
|
||||||
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/lib/pkgconfig/openssl.pc
|
chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/$(LIBDIR)/pkgconfig/openssl.pc
|
||||||
|
|
||||||
install_html_docs:
|
install_html_docs:
|
||||||
here="`pwd`"; \
|
here="`pwd`"; \
|
||||||
@@ -579,7 +629,7 @@ install_html_docs:
|
|||||||
grep -v $$filecase "^$$fn\$$" | \
|
grep -v $$filecase "^$$fn\$$" | \
|
||||||
(cd $(INSTALL_PREFIX)$(HTMLDIR)/$$subdir; \
|
(cd $(INSTALL_PREFIX)$(HTMLDIR)/$$subdir; \
|
||||||
while read n; do \
|
while read n; do \
|
||||||
$$here/util/point.sh $$fn.$(HTMLSUFFIX) "$$n".$(HTMLSUFFIX); \
|
PLATFORM=$(PLATFORM) $$here/util/point.sh $$fn.$(HTMLSUFFIX) "$$n".$(HTMLSUFFIX); \
|
||||||
done); \
|
done); \
|
||||||
done; \
|
done; \
|
||||||
done
|
done
|
||||||
@@ -590,7 +640,7 @@ install_docs:
|
|||||||
$(INSTALL_PREFIX)$(MANDIR)/man3 \
|
$(INSTALL_PREFIX)$(MANDIR)/man3 \
|
||||||
$(INSTALL_PREFIX)$(MANDIR)/man5 \
|
$(INSTALL_PREFIX)$(MANDIR)/man5 \
|
||||||
$(INSTALL_PREFIX)$(MANDIR)/man7
|
$(INSTALL_PREFIX)$(MANDIR)/man7
|
||||||
@pod2man="`cd util; ./pod2mantest $(PERL)`"; \
|
@pod2man="`cd ./util; ./pod2mantest $(PERL)`"; \
|
||||||
here="`pwd`"; \
|
here="`pwd`"; \
|
||||||
filecase=; \
|
filecase=; \
|
||||||
if [ "$(PLATFORM)" = "DJGPP" -o "$(PLATFORM)" = "Cygwin" -o "$(PLATFORM)" = "mingw" ]; then \
|
if [ "$(PLATFORM)" = "DJGPP" -o "$(PLATFORM)" = "Cygwin" -o "$(PLATFORM)" = "mingw" ]; then \
|
||||||
@@ -610,7 +660,7 @@ install_docs:
|
|||||||
(grep -v "[ ]"; true) | \
|
(grep -v "[ ]"; true) | \
|
||||||
(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}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
|
PLATFORM=$(PLATFORM) $$here/util/point.sh $$fn.$${sec}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
|
||||||
done); \
|
done); \
|
||||||
done; \
|
done; \
|
||||||
set -e; for i in doc/crypto/*.pod doc/ssl/*.pod; do \
|
set -e; for i in doc/crypto/*.pod doc/ssl/*.pod; do \
|
||||||
@@ -627,7 +677,7 @@ install_docs:
|
|||||||
(grep -v "[ ]"; true) | \
|
(grep -v "[ ]"; true) | \
|
||||||
(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}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
|
PLATFORM=$(PLATFORM) $$here/util/point.sh $$fn.$${sec}$(MANSUFFIX) "$$n".$${sec}$(MANSUFFIX); \
|
||||||
done); \
|
done); \
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ LINK_SO_A_VIA_O= \
|
|||||||
ALL=$$ALLSYMSFLAGS; ALLSYMSFLAGS=; NOALLSYMSFLAGS=; \
|
ALL=$$ALLSYMSFLAGS; ALLSYMSFLAGS=; NOALLSYMSFLAGS=; \
|
||||||
( $(SET_X); \
|
( $(SET_X); \
|
||||||
ld $(LDFLAGS) -r -o lib$(LIBNAME).o $$ALL lib$(LIBNAME).a $(LIBEXTRAS) ); \
|
ld $(LDFLAGS) -r -o lib$(LIBNAME).o $$ALL lib$(LIBNAME).a $(LIBEXTRAS) ); \
|
||||||
$(LINK_SO) && rm -f $(LIBNAME).o
|
$(LINK_SO) && rm -f lib$(LIBNAME).o
|
||||||
|
|
||||||
LINK_SO_A_UNPACKED= \
|
LINK_SO_A_UNPACKED= \
|
||||||
UNPACKDIR=link_tmp.$$$$; rm -rf $$UNPACKDIR; mkdir $$UNPACKDIR; \
|
UNPACKDIR=link_tmp.$$$$; rm -rf $$UNPACKDIR; mkdir $$UNPACKDIR; \
|
||||||
@@ -207,17 +207,29 @@ link_app.bsd:
|
|||||||
fi; $(LINK_APP)
|
fi; $(LINK_APP)
|
||||||
|
|
||||||
# For Darwin AKA Mac OS/X (dyld)
|
# For Darwin AKA Mac OS/X (dyld)
|
||||||
# link_o.darwin produces .so, because we let it use dso_dlfcn module,
|
# Originally link_o.darwin produced .so, because it was hard-coded
|
||||||
# which has .so extension hard-coded. One can argue that one should
|
# in dso_dlfcn module. At later point dso_dlfcn switched to .dylib
|
||||||
# develop special dso module for MacOS X. At least manual encourages
|
# extension in order to allow for run-time linking with vendor-
|
||||||
# to use native NSModule(3) API and refers to dlfcn as termporary hack.
|
# supplied shared libraries such as libz, so that link_o.darwin had
|
||||||
|
# to be harmonized with it. This caused minor controversy, because
|
||||||
|
# it was believed that dlopen can't be used to dynamically load
|
||||||
|
# .dylib-s, only so called bundle modules (ones linked with -bundle
|
||||||
|
# flag). The belief seems to be originating from pre-10.4 release,
|
||||||
|
# where dlfcn functionality was emulated by dlcompat add-on. In
|
||||||
|
# 10.4 dlopen was rewritten as native part of dyld and is documented
|
||||||
|
# to be capable of loading both dynamic libraries and bundles. In
|
||||||
|
# order to provide compatibility with pre-10.4 dlopen, modules are
|
||||||
|
# linked with -bundle flag, which makes .dylib extension misleading.
|
||||||
|
# It works, because dlopen is [and always was] extension-agnostic.
|
||||||
|
# Alternative to this heuristic approach is to develop specific
|
||||||
|
# MacOS X dso module relying on whichever "native" dyld interface.
|
||||||
link_o.darwin:
|
link_o.darwin:
|
||||||
@ $(CALC_VERSIONS); \
|
@ $(CALC_VERSIONS); \
|
||||||
SHLIB=lib$(LIBNAME); \
|
SHLIB=lib$(LIBNAME); \
|
||||||
SHLIB_SUFFIX=.so; \
|
SHLIB_SUFFIX=.dylib; \
|
||||||
ALLSYMSFLAGS='-all_load'; \
|
ALLSYMSFLAGS='-all_load'; \
|
||||||
NOALLSYMSFLAGS=''; \
|
NOALLSYMSFLAGS=''; \
|
||||||
SHAREDFLAGS="$(CFLAGS) $(SHARED_LDFLAGS)"; \
|
SHAREDFLAGS="$(CFLAGS) `echo $(SHARED_LDFLAGS) | sed s/dynamiclib/bundle/`"; \
|
||||||
if [ -n "$(LIBVERSION)" ]; then \
|
if [ -n "$(LIBVERSION)" ]; then \
|
||||||
SHAREDFLAGS="$$SHAREDFLAGS -current_version $(LIBVERSION)"; \
|
SHAREDFLAGS="$$SHAREDFLAGS -current_version $(LIBVERSION)"; \
|
||||||
fi; \
|
fi; \
|
||||||
@@ -238,7 +250,7 @@ link_a.darwin:
|
|||||||
if [ -n "$$SHLIB_SOVER_NODOT" ]; then \
|
if [ -n "$$SHLIB_SOVER_NODOT" ]; then \
|
||||||
SHAREDFLAGS="$$SHAREDFLAGS -compatibility_version $$SHLIB_SOVER_NODOT"; \
|
SHAREDFLAGS="$$SHAREDFLAGS -compatibility_version $$SHLIB_SOVER_NODOT"; \
|
||||||
fi; \
|
fi; \
|
||||||
SHAREDFLAGS="$$SHAREDFLAGS -install_name $(INSTALLTOP)/lib/$$SHLIB$(SHLIB_EXT)"; \
|
SHAREDFLAGS="$$SHAREDFLAGS -install_name $(INSTALLTOP)/$(LIBDIR)/$$SHLIB$(SHLIB_EXT)"; \
|
||||||
$(LINK_SO_A)
|
$(LINK_SO_A)
|
||||||
link_app.darwin: # is there run-path on darwin?
|
link_app.darwin: # is there run-path on darwin?
|
||||||
$(LINK_APP)
|
$(LINK_APP)
|
||||||
@@ -281,7 +293,7 @@ link_a.cygwin:
|
|||||||
fi; \
|
fi; \
|
||||||
dll_name=$$SHLIB$$SHLIB_SOVER$$SHLIB_SUFFIX; \
|
dll_name=$$SHLIB$$SHLIB_SOVER$$SHLIB_SUFFIX; \
|
||||||
$(PERL) util/mkrc.pl $$dll_name | \
|
$(PERL) util/mkrc.pl $$dll_name | \
|
||||||
$(CROSS_COMPILE_PREFIX)windres -o rc.o; \
|
$(CROSS_COMPILE)windres -o rc.o; \
|
||||||
extras="$$extras rc.o"; \
|
extras="$$extras rc.o"; \
|
||||||
ALLSYMSFLAGS='-Wl,--whole-archive'; \
|
ALLSYMSFLAGS='-Wl,--whole-archive'; \
|
||||||
NOALLSYMSFLAGS='-Wl,--no-whole-archive'; \
|
NOALLSYMSFLAGS='-Wl,--no-whole-archive'; \
|
||||||
|
|||||||
277
NEWS
277
NEWS
@@ -5,13 +5,122 @@
|
|||||||
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.8k and OpenSSL 1.0:
|
Major changes between OpenSSL 1.0.1e and OpenSSL 1.0.1f [6 Jan 2014]
|
||||||
|
|
||||||
|
o Fix for TLS record tampering bug CVE-2013-4353
|
||||||
|
o Fix for TLS version checking bug CVE-2013-6449
|
||||||
|
o Fix for DTLS retransmission bug CVE-2013-6450
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.1d and OpenSSL 1.0.1e [11 Feb 2013]:
|
||||||
|
|
||||||
|
o Corrected fix for CVE-2013-0169
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.1c and OpenSSL 1.0.1d [4 Feb 2013]:
|
||||||
|
|
||||||
|
o Fix renegotiation in TLS 1.1, 1.2 by using the correct TLS version.
|
||||||
|
o Include the fips configuration module.
|
||||||
|
o Fix OCSP bad key DoS attack CVE-2013-0166
|
||||||
|
o Fix for SSL/TLS/DTLS CBC plaintext recovery attack CVE-2013-0169
|
||||||
|
o Fix for TLS AESNI record handling flaw CVE-2012-2686
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.1b and OpenSSL 1.0.1c [10 May 2012]:
|
||||||
|
|
||||||
|
o Fix TLS/DTLS record length checking bug CVE-2012-2333
|
||||||
|
o Don't attempt to use non-FIPS composite ciphers in FIPS mode.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.1a and OpenSSL 1.0.1b [26 Apr 2012]:
|
||||||
|
|
||||||
|
o Fix compilation error on non-x86 platforms.
|
||||||
|
o Make FIPS capable OpenSSL ciphers work in non-FIPS mode.
|
||||||
|
o Fix SSL_OP_NO_TLSv1_1 clash with SSL_OP_ALL in OpenSSL 1.0.0
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.1 and OpenSSL 1.0.1a [19 Apr 2012]:
|
||||||
|
|
||||||
|
o Fix for ASN1 overflow bug CVE-2012-2110
|
||||||
|
o Workarounds for some servers that hang on long client hellos.
|
||||||
|
o Fix SEGV in AES code.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0h and OpenSSL 1.0.1 [14 Mar 2012]:
|
||||||
|
|
||||||
|
o TLS/DTLS heartbeat support.
|
||||||
|
o SCTP support.
|
||||||
|
o RFC 5705 TLS key material exporter.
|
||||||
|
o RFC 5764 DTLS-SRTP negotiation.
|
||||||
|
o Next Protocol Negotiation.
|
||||||
|
o PSS signatures in certificates, requests and CRLs.
|
||||||
|
o Support for password based recipient info for CMS.
|
||||||
|
o Support TLS v1.2 and TLS v1.1.
|
||||||
|
o Preliminary FIPS capability for unvalidated 2.0 FIPS module.
|
||||||
|
o SRP support.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0j and OpenSSL 1.0.0k [5 Feb 2013]:
|
||||||
|
|
||||||
|
o Fix for SSL/TLS/DTLS CBC plaintext recovery attack CVE-2013-0169
|
||||||
|
o Fix OCSP bad key DoS attack CVE-2013-0166
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0i and OpenSSL 1.0.0j [10 May 2012]:
|
||||||
|
|
||||||
|
o Fix DTLS record length checking bug CVE-2012-2333
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0h and OpenSSL 1.0.0i [19 Apr 2012]:
|
||||||
|
|
||||||
|
o Fix for ASN1 overflow bug CVE-2012-2110
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0g and OpenSSL 1.0.0h [12 Mar 2012]:
|
||||||
|
|
||||||
|
o Fix for CMS/PKCS#7 MMA CVE-2012-0884
|
||||||
|
o Corrected fix for CVE-2011-4619
|
||||||
|
o Various DTLS fixes.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0f and OpenSSL 1.0.0g [18 Jan 2012]:
|
||||||
|
|
||||||
|
o Fix for DTLS DoS issue CVE-2012-0050
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0e and OpenSSL 1.0.0f [4 Jan 2012]:
|
||||||
|
|
||||||
|
o Fix for DTLS plaintext recovery attack CVE-2011-4108
|
||||||
|
o Clear block padding bytes of SSL 3.0 records CVE-2011-4576
|
||||||
|
o Only allow one SGC handshake restart for SSL/TLS CVE-2011-4619
|
||||||
|
o Check parameters are not NULL in GOST ENGINE CVE-2012-0027
|
||||||
|
o Check for malformed RFC3779 data CVE-2011-4577
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0d and OpenSSL 1.0.0e [6 Sep 2011]:
|
||||||
|
|
||||||
|
o Fix for CRL vulnerability issue CVE-2011-3207
|
||||||
|
o Fix for ECDH crashes CVE-2011-3210
|
||||||
|
o Protection against EC timing attacks.
|
||||||
|
o Support ECDH ciphersuites for certificates using SHA2 algorithms.
|
||||||
|
o Various DTLS fixes.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0c and OpenSSL 1.0.0d [8 Feb 2011]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2011-0014
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0b and OpenSSL 1.0.0c [2 Dec 2010]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2010-4180
|
||||||
|
o Fix for CVE-2010-4252
|
||||||
|
o Fix mishandling of absent EC point format extension.
|
||||||
|
o Fix various platform compilation issues.
|
||||||
|
o Corrected fix for security issue CVE-2010-3864.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0a and OpenSSL 1.0.0b [16 Nov 2010]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2010-3864.
|
||||||
|
o Fix for CVE-2010-2939
|
||||||
|
o Fix WIN32 build system for GOST ENGINE.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 1.0.0 and OpenSSL 1.0.0a [1 Jun 2010]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2010-1633.
|
||||||
|
o GOST MAC and CFB fixes.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8n and OpenSSL 1.0.0 [29 Mar 2010]:
|
||||||
|
|
||||||
o RFC3280 path validation: sufficient to process PKITS tests.
|
o RFC3280 path validation: sufficient to process PKITS tests.
|
||||||
o Integrated support for PVK files and keyblobs.
|
o Integrated support for PVK files and keyblobs.
|
||||||
o Change default private key format to PKCS#8.
|
o Change default private key format to PKCS#8.
|
||||||
o CMS support: able to process all examples in RFCXXXX
|
o CMS support: able to process all examples in RFC4134
|
||||||
o Streaming ASN1 encode support for PKCS#7 and CMS.
|
o Streaming ASN1 encode support for PKCS#7 and CMS.
|
||||||
o Multiple signer and signer add support for PKCS#7 and CMS.
|
o Multiple signer and signer add support for PKCS#7 and CMS.
|
||||||
o ASN1 printing support.
|
o ASN1 printing support.
|
||||||
@@ -27,30 +136,108 @@
|
|||||||
o ecdsa-with-SHA224/256/384/512 signature types.
|
o ecdsa-with-SHA224/256/384/512 signature types.
|
||||||
o dsa-with-SHA224 and dsa-with-SHA256 signature types.
|
o dsa-with-SHA224 and dsa-with-SHA256 signature types.
|
||||||
o Opaque PRF Input TLS extension support.
|
o Opaque PRF Input TLS extension support.
|
||||||
|
o Updated time routines to avoid OS limitations.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8j and OpenSSL 0.9.8k:
|
Major changes between OpenSSL 0.9.8x and OpenSSL 0.9.8y [5 Feb 2013]:
|
||||||
|
|
||||||
|
o Fix for SSL/TLS/DTLS CBC plaintext recovery attack CVE-2013-0169
|
||||||
|
o Fix OCSP bad key DoS attack CVE-2013-0166
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8w and OpenSSL 0.9.8x [10 May 2012]:
|
||||||
|
|
||||||
|
o Fix DTLS record length checking bug CVE-2012-2333
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8v and OpenSSL 0.9.8w [23 Apr 2012]:
|
||||||
|
|
||||||
|
o Fix for CVE-2012-2131 (corrected fix for 0.9.8 and CVE-2012-2110)
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8u and OpenSSL 0.9.8v [19 Apr 2012]:
|
||||||
|
|
||||||
|
o Fix for ASN1 overflow bug CVE-2012-2110
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8t and OpenSSL 0.9.8u [12 Mar 2012]:
|
||||||
|
|
||||||
|
o Fix for CMS/PKCS#7 MMA CVE-2012-0884
|
||||||
|
o Corrected fix for CVE-2011-4619
|
||||||
|
o Various DTLS fixes.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8s and OpenSSL 0.9.8t [18 Jan 2012]:
|
||||||
|
|
||||||
|
o Fix for DTLS DoS issue CVE-2012-0050
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8r and OpenSSL 0.9.8s [4 Jan 2012]:
|
||||||
|
|
||||||
|
o Fix for DTLS plaintext recovery attack CVE-2011-4108
|
||||||
|
o Fix policy check double free error CVE-2011-4109
|
||||||
|
o Clear block padding bytes of SSL 3.0 records CVE-2011-4576
|
||||||
|
o Only allow one SGC handshake restart for SSL/TLS CVE-2011-4619
|
||||||
|
o Check for malformed RFC3779 data CVE-2011-4577
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8q and OpenSSL 0.9.8r [8 Feb 2011]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2011-0014
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8p and OpenSSL 0.9.8q [2 Dec 2010]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2010-4180
|
||||||
|
o Fix for CVE-2010-4252
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8o and OpenSSL 0.9.8p [16 Nov 2010]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2010-3864.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8n and OpenSSL 0.9.8o [1 Jun 2010]:
|
||||||
|
|
||||||
|
o Fix for security issue CVE-2010-0742.
|
||||||
|
o Various DTLS fixes.
|
||||||
|
o Recognise SHA2 certificates if only SSL algorithms added.
|
||||||
|
o Fix for no-rc4 compilation.
|
||||||
|
o Chil ENGINE unload workaround.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8m and OpenSSL 0.9.8n [24 Mar 2010]:
|
||||||
|
|
||||||
|
o CFB cipher definition fixes.
|
||||||
|
o Fix security issues CVE-2010-0740 and CVE-2010-0433.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8l and OpenSSL 0.9.8m [25 Feb 2010]:
|
||||||
|
|
||||||
|
o Cipher definition fixes.
|
||||||
|
o Workaround for slow RAND_poll() on some WIN32 versions.
|
||||||
|
o Remove MD2 from algorithm tables.
|
||||||
|
o SPKAC handling fixes.
|
||||||
|
o Support for RFC5746 TLS renegotiation extension.
|
||||||
|
o Compression memory leak fixed.
|
||||||
|
o Compression session resumption fixed.
|
||||||
|
o Ticket and SNI coexistence fixes.
|
||||||
|
o Many fixes to DTLS handling.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8k and OpenSSL 0.9.8l [5 Nov 2009]:
|
||||||
|
|
||||||
|
o Temporary work around for CVE-2009-3555: disable renegotiation.
|
||||||
|
|
||||||
|
Major changes between OpenSSL 0.9.8j and OpenSSL 0.9.8k [25 Mar 2009]:
|
||||||
|
|
||||||
o Fix various build issues.
|
o Fix various build issues.
|
||||||
o Fix security issues (CVE-2009-0590, CVE-2009-0591, CVE-2009-0789)
|
o Fix security issues (CVE-2009-0590, CVE-2009-0591, CVE-2009-0789)
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8i and OpenSSL 0.9.8j:
|
Major changes between OpenSSL 0.9.8i and OpenSSL 0.9.8j [7 Jan 2009]:
|
||||||
|
|
||||||
o Fix security issue (CVE-2008-5077)
|
o Fix security issue (CVE-2008-5077)
|
||||||
o Merge FIPS 140-2 branch code.
|
o Merge FIPS 140-2 branch code.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8g and OpenSSL 0.9.8h:
|
Major changes between OpenSSL 0.9.8g and OpenSSL 0.9.8h [28 May 2008]:
|
||||||
|
|
||||||
o CryptoAPI ENGINE support.
|
o CryptoAPI ENGINE support.
|
||||||
o Various precautionary measures.
|
o Various precautionary measures.
|
||||||
o Fix for bugs affecting certificate request creation.
|
o Fix for bugs affecting certificate request creation.
|
||||||
o Support for local machine keyset attribute in PKCS#12 files.
|
o Support for local machine keyset attribute in PKCS#12 files.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8f and OpenSSL 0.9.8g:
|
Major changes between OpenSSL 0.9.8f and OpenSSL 0.9.8g [19 Oct 2007]:
|
||||||
|
|
||||||
o Backport of CMS functionality to 0.9.8.
|
o Backport of CMS functionality to 0.9.8.
|
||||||
o Fixes for bugs introduced with 0.9.8f.
|
o Fixes for bugs introduced with 0.9.8f.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8e and OpenSSL 0.9.8f:
|
Major changes between OpenSSL 0.9.8e and OpenSSL 0.9.8f [11 Oct 2007]:
|
||||||
|
|
||||||
o Add gcc 4.2 support.
|
o Add gcc 4.2 support.
|
||||||
o Add support for AES and SSE2 assembly lanugauge optimization
|
o Add support for AES and SSE2 assembly lanugauge optimization
|
||||||
@@ -61,23 +248,23 @@
|
|||||||
o RFC4507bis support.
|
o RFC4507bis support.
|
||||||
o TLS Extensions support.
|
o TLS Extensions support.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8d and OpenSSL 0.9.8e:
|
Major changes between OpenSSL 0.9.8d and OpenSSL 0.9.8e [23 Feb 2007]:
|
||||||
|
|
||||||
o Various ciphersuite selection fixes.
|
o Various ciphersuite selection fixes.
|
||||||
o RFC3779 support.
|
o RFC3779 support.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8c and OpenSSL 0.9.8d:
|
Major changes between OpenSSL 0.9.8c and OpenSSL 0.9.8d [28 Sep 2006]:
|
||||||
|
|
||||||
o Introduce limits to prevent malicious key DoS (CVE-2006-2940)
|
o Introduce limits to prevent malicious key DoS (CVE-2006-2940)
|
||||||
o Fix security issues (CVE-2006-2937, CVE-2006-3737, CVE-2006-4343)
|
o Fix security issues (CVE-2006-2937, CVE-2006-3737, CVE-2006-4343)
|
||||||
o Changes to ciphersuite selection algorithm
|
o Changes to ciphersuite selection algorithm
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8b and OpenSSL 0.9.8c:
|
Major changes between OpenSSL 0.9.8b and OpenSSL 0.9.8c [5 Sep 2006]:
|
||||||
|
|
||||||
o Fix Daniel Bleichenbacher forged signature attack, CVE-2006-4339
|
o Fix Daniel Bleichenbacher forged signature attack, CVE-2006-4339
|
||||||
o New cipher Camellia
|
o New cipher Camellia
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8a and OpenSSL 0.9.8b:
|
Major changes between OpenSSL 0.9.8a and OpenSSL 0.9.8b [4 May 2006]:
|
||||||
|
|
||||||
o Cipher string fixes.
|
o Cipher string fixes.
|
||||||
o Fixes for VC++ 2005.
|
o Fixes for VC++ 2005.
|
||||||
@@ -87,12 +274,12 @@
|
|||||||
o Built in dynamic engine compilation support on Win32.
|
o Built in dynamic engine compilation support on Win32.
|
||||||
o Fixes auto dynamic engine loading in Win32.
|
o Fixes auto dynamic engine loading in Win32.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.8 and OpenSSL 0.9.8a:
|
Major changes between OpenSSL 0.9.8 and OpenSSL 0.9.8a [11 Oct 2005]:
|
||||||
|
|
||||||
o Fix potential SSL 2.0 rollback, CVE-2005-2969
|
o Fix potential SSL 2.0 rollback, CVE-2005-2969
|
||||||
o Extended Windows CE support
|
o Extended Windows CE support
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7g and OpenSSL 0.9.8:
|
Major changes between OpenSSL 0.9.7g and OpenSSL 0.9.8 [5 Jul 2005]:
|
||||||
|
|
||||||
o Major work on the BIGNUM library for higher efficiency and to
|
o Major work on the BIGNUM library for higher efficiency and to
|
||||||
make operations more streamlined and less contradictory. This
|
make operations more streamlined and less contradictory. This
|
||||||
@@ -166,36 +353,36 @@
|
|||||||
o Added initial support for Win64.
|
o Added initial support for Win64.
|
||||||
o Added alternate pkg-config files.
|
o Added alternate pkg-config files.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7l and OpenSSL 0.9.7m:
|
Major changes between OpenSSL 0.9.7l and OpenSSL 0.9.7m [23 Feb 2007]:
|
||||||
|
|
||||||
o FIPS 1.1.1 module linking.
|
o FIPS 1.1.1 module linking.
|
||||||
o Various ciphersuite selection fixes.
|
o Various ciphersuite selection fixes.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7k and OpenSSL 0.9.7l:
|
Major changes between OpenSSL 0.9.7k and OpenSSL 0.9.7l [28 Sep 2006]:
|
||||||
|
|
||||||
o Introduce limits to prevent malicious key DoS (CVE-2006-2940)
|
o Introduce limits to prevent malicious key DoS (CVE-2006-2940)
|
||||||
o Fix security issues (CVE-2006-2937, CVE-2006-3737, CVE-2006-4343)
|
o Fix security issues (CVE-2006-2937, CVE-2006-3737, CVE-2006-4343)
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7j and OpenSSL 0.9.7k:
|
Major changes between OpenSSL 0.9.7j and OpenSSL 0.9.7k [5 Sep 2006]:
|
||||||
|
|
||||||
o Fix Daniel Bleichenbacher forged signature attack, CVE-2006-4339
|
o Fix Daniel Bleichenbacher forged signature attack, CVE-2006-4339
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7i and OpenSSL 0.9.7j:
|
Major changes between OpenSSL 0.9.7i and OpenSSL 0.9.7j [4 May 2006]:
|
||||||
|
|
||||||
o Visual C++ 2005 fixes.
|
o Visual C++ 2005 fixes.
|
||||||
o Update Windows build system for FIPS.
|
o Update Windows build system for FIPS.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7h and OpenSSL 0.9.7i:
|
Major changes between OpenSSL 0.9.7h and OpenSSL 0.9.7i [14 Oct 2005]:
|
||||||
|
|
||||||
o Give EVP_MAX_MD_SIZE it's old value, except for a FIPS build.
|
o Give EVP_MAX_MD_SIZE it's old value, except for a FIPS build.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7g and OpenSSL 0.9.7h:
|
Major changes between OpenSSL 0.9.7g and OpenSSL 0.9.7h [11 Oct 2005]:
|
||||||
|
|
||||||
o Fix SSL 2.0 Rollback, CVE-2005-2969
|
o Fix SSL 2.0 Rollback, CVE-2005-2969
|
||||||
o Allow use of fixed-length exponent on DSA signing
|
o Allow use of fixed-length exponent on DSA signing
|
||||||
o Default fixed-window RSA, DSA, DH private-key operations
|
o Default fixed-window RSA, DSA, DH private-key operations
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7f and OpenSSL 0.9.7g:
|
Major changes between OpenSSL 0.9.7f and OpenSSL 0.9.7g [11 Apr 2005]:
|
||||||
|
|
||||||
o More compilation issues fixed.
|
o More compilation issues fixed.
|
||||||
o Adaptation to more modern Kerberos API.
|
o Adaptation to more modern Kerberos API.
|
||||||
@@ -204,7 +391,7 @@
|
|||||||
o More constification.
|
o More constification.
|
||||||
o Added processing of proxy certificates (RFC 3820).
|
o Added processing of proxy certificates (RFC 3820).
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7e and OpenSSL 0.9.7f:
|
Major changes between OpenSSL 0.9.7e and OpenSSL 0.9.7f [22 Mar 2005]:
|
||||||
|
|
||||||
o Several compilation issues fixed.
|
o Several compilation issues fixed.
|
||||||
o Many memory allocation failure checks added.
|
o Many memory allocation failure checks added.
|
||||||
@@ -212,12 +399,12 @@
|
|||||||
o Mandatory basic checks on certificates.
|
o Mandatory basic checks on certificates.
|
||||||
o Performance improvements.
|
o Performance improvements.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7d and OpenSSL 0.9.7e:
|
Major changes between OpenSSL 0.9.7d and OpenSSL 0.9.7e [25 Oct 2004]:
|
||||||
|
|
||||||
o Fix race condition in CRL checking code.
|
o Fix race condition in CRL checking code.
|
||||||
o Fixes to PKCS#7 (S/MIME) code.
|
o Fixes to PKCS#7 (S/MIME) code.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7c and OpenSSL 0.9.7d:
|
Major changes between OpenSSL 0.9.7c and OpenSSL 0.9.7d [17 Mar 2004]:
|
||||||
|
|
||||||
o Security: Fix Kerberos ciphersuite SSL/TLS handshaking bug
|
o Security: Fix Kerberos ciphersuite SSL/TLS handshaking bug
|
||||||
o Security: Fix null-pointer assignment in do_change_cipher_spec()
|
o Security: Fix null-pointer assignment in do_change_cipher_spec()
|
||||||
@@ -225,14 +412,14 @@
|
|||||||
o Multiple X509 verification fixes
|
o Multiple X509 verification fixes
|
||||||
o Speed up HMAC and other operations
|
o Speed up HMAC and other operations
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7b and OpenSSL 0.9.7c:
|
Major changes between OpenSSL 0.9.7b and OpenSSL 0.9.7c [30 Sep 2003]:
|
||||||
|
|
||||||
o Security: fix various ASN1 parsing bugs.
|
o Security: fix various ASN1 parsing bugs.
|
||||||
o New -ignore_err option to OCSP utility.
|
o New -ignore_err option to OCSP utility.
|
||||||
o Various interop and bug fixes in S/MIME code.
|
o Various interop and bug fixes in S/MIME code.
|
||||||
o SSL/TLS protocol fix for unrequested client certificates.
|
o SSL/TLS protocol fix for unrequested client certificates.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.7a and OpenSSL 0.9.7b:
|
Major changes between OpenSSL 0.9.7a and OpenSSL 0.9.7b [10 Apr 2003]:
|
||||||
|
|
||||||
o Security: counter the Klima-Pokorny-Rosa extension of
|
o Security: counter the Klima-Pokorny-Rosa extension of
|
||||||
Bleichbacher's attack
|
Bleichbacher's attack
|
||||||
@@ -243,7 +430,7 @@
|
|||||||
o ASN.1: treat domainComponent correctly.
|
o ASN.1: treat domainComponent correctly.
|
||||||
o Documentation: fixes and additions.
|
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 [19 Feb 2003]:
|
||||||
|
|
||||||
o Security: Important security related bugfixes.
|
o Security: Important security related bugfixes.
|
||||||
o Enhanced compatibility with MIT Kerberos.
|
o Enhanced compatibility with MIT Kerberos.
|
||||||
@@ -254,7 +441,7 @@
|
|||||||
o SSL/TLS: now handles manual certificate chain building.
|
o SSL/TLS: now handles manual certificate chain building.
|
||||||
o SSL/TLS: certain session ID malfunctions corrected.
|
o SSL/TLS: certain session ID malfunctions corrected.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6 and OpenSSL 0.9.7:
|
Major changes between OpenSSL 0.9.6 and OpenSSL 0.9.7 [30 Dec 2002]:
|
||||||
|
|
||||||
o New library section OCSP.
|
o New library section OCSP.
|
||||||
o Complete rewrite of ASN1 code.
|
o Complete rewrite of ASN1 code.
|
||||||
@@ -300,23 +487,23 @@
|
|||||||
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:
|
Major changes between OpenSSL 0.9.6j and OpenSSL 0.9.6k [30 Sep 2003]:
|
||||||
|
|
||||||
o Security: fix various ASN1 parsing bugs.
|
o Security: fix various ASN1 parsing bugs.
|
||||||
o SSL/TLS protocol fix for unrequested client certificates.
|
o SSL/TLS protocol fix for unrequested client certificates.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6i and OpenSSL 0.9.6j:
|
Major changes between OpenSSL 0.9.6i and OpenSSL 0.9.6j [10 Apr 2003]:
|
||||||
|
|
||||||
o Security: counter the Klima-Pokorny-Rosa extension of
|
o Security: counter the Klima-Pokorny-Rosa extension of
|
||||||
Bleichbacher's attack
|
Bleichbacher's attack
|
||||||
o Security: make RSA blinding default.
|
o Security: make RSA blinding default.
|
||||||
o Build: shared library support fixes.
|
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 [19 Feb 2003]:
|
||||||
|
|
||||||
o Important security related bugfixes.
|
o Important security related bugfixes.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6g and OpenSSL 0.9.6h:
|
Major changes between OpenSSL 0.9.6g and OpenSSL 0.9.6h [5 Dec 2002]:
|
||||||
|
|
||||||
o New configuration targets for Tandem OSS and A/UX.
|
o New configuration targets for Tandem OSS and A/UX.
|
||||||
o New OIDs for Microsoft attributes.
|
o New OIDs for Microsoft attributes.
|
||||||
@@ -330,25 +517,25 @@
|
|||||||
o Fixes for smaller building problems.
|
o Fixes for smaller building problems.
|
||||||
o Updates of manuals, FAQ and other instructive documents.
|
o Updates of manuals, FAQ and other instructive documents.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6f and OpenSSL 0.9.6g:
|
Major changes between OpenSSL 0.9.6f and OpenSSL 0.9.6g [9 Aug 2002]:
|
||||||
|
|
||||||
o Important building fixes on Unix.
|
o Important building fixes on Unix.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6e and OpenSSL 0.9.6f:
|
Major changes between OpenSSL 0.9.6e and OpenSSL 0.9.6f [8 Aug 2002]:
|
||||||
|
|
||||||
o Various important bugfixes.
|
o Various important bugfixes.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6d and OpenSSL 0.9.6e:
|
Major changes between OpenSSL 0.9.6d and OpenSSL 0.9.6e [30 Jul 2002]:
|
||||||
|
|
||||||
o Important security related bugfixes.
|
o Important security related bugfixes.
|
||||||
o Various SSL/TLS library bugfixes.
|
o Various SSL/TLS library bugfixes.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6c and OpenSSL 0.9.6d:
|
Major changes between OpenSSL 0.9.6c and OpenSSL 0.9.6d [9 May 2002]:
|
||||||
|
|
||||||
o Various SSL/TLS library bugfixes.
|
o Various SSL/TLS library bugfixes.
|
||||||
o Fix DH parameter generation for 'non-standard' generators.
|
o Fix DH parameter generation for 'non-standard' generators.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6b and OpenSSL 0.9.6c:
|
Major changes between OpenSSL 0.9.6b and OpenSSL 0.9.6c [21 Dec 2001]:
|
||||||
|
|
||||||
o Various SSL/TLS library bugfixes.
|
o Various SSL/TLS library bugfixes.
|
||||||
o BIGNUM library fixes.
|
o BIGNUM library fixes.
|
||||||
@@ -361,7 +548,7 @@
|
|||||||
Broadcom and Cryptographic Appliance's keyserver
|
Broadcom and Cryptographic Appliance's keyserver
|
||||||
[in 0.9.6c-engine release].
|
[in 0.9.6c-engine release].
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6a and OpenSSL 0.9.6b:
|
Major changes between OpenSSL 0.9.6a and OpenSSL 0.9.6b [9 Jul 2001]:
|
||||||
|
|
||||||
o Security fix: PRNG improvements.
|
o Security fix: PRNG improvements.
|
||||||
o Security fix: RSA OAEP check.
|
o Security fix: RSA OAEP check.
|
||||||
@@ -378,7 +565,7 @@
|
|||||||
o Increase default size for BIO buffering filter.
|
o Increase default size for BIO buffering filter.
|
||||||
o Compatibility fixes in some scripts.
|
o Compatibility fixes in some scripts.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.6 and OpenSSL 0.9.6a:
|
Major changes between OpenSSL 0.9.6 and OpenSSL 0.9.6a [5 Apr 2001]:
|
||||||
|
|
||||||
o Security fix: change behavior of OpenSSL to avoid using
|
o Security fix: change behavior of OpenSSL to avoid using
|
||||||
environment variables when running as root.
|
environment variables when running as root.
|
||||||
@@ -403,7 +590,7 @@
|
|||||||
o New function BN_rand_range().
|
o New function BN_rand_range().
|
||||||
o Add "-rand" option to openssl s_client and s_server.
|
o Add "-rand" option to openssl s_client and s_server.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.5a and OpenSSL 0.9.6:
|
Major changes between OpenSSL 0.9.5a and OpenSSL 0.9.6 [10 Oct 2000]:
|
||||||
|
|
||||||
o Some documentation for BIO and SSL libraries.
|
o Some documentation for BIO and SSL libraries.
|
||||||
o Enhanced chain verification using key identifiers.
|
o Enhanced chain verification using key identifiers.
|
||||||
@@ -418,7 +605,7 @@
|
|||||||
[1] The support for external crypto devices is currently a separate
|
[1] The support for external crypto devices is currently a separate
|
||||||
distribution. See the file README.ENGINE.
|
distribution. See the file README.ENGINE.
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.5 and OpenSSL 0.9.5a:
|
Major changes between OpenSSL 0.9.5 and OpenSSL 0.9.5a [1 Apr 2000]:
|
||||||
|
|
||||||
o Bug fixes for Win32, SuSE Linux, NeXTSTEP and FreeBSD 2.2.8
|
o Bug fixes for Win32, SuSE Linux, NeXTSTEP and FreeBSD 2.2.8
|
||||||
o Shared library support for HPUX and Solaris-gcc
|
o Shared library support for HPUX and Solaris-gcc
|
||||||
@@ -427,7 +614,7 @@
|
|||||||
o New 'rand' application
|
o New 'rand' application
|
||||||
o New way to check for existence of algorithms from scripts
|
o New way to check for existence of algorithms from scripts
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.4 and OpenSSL 0.9.5:
|
Major changes between OpenSSL 0.9.4 and OpenSSL 0.9.5 [25 May 2000]:
|
||||||
|
|
||||||
o S/MIME support in new 'smime' command
|
o S/MIME support in new 'smime' command
|
||||||
o Documentation for the OpenSSL command line application
|
o Documentation for the OpenSSL command line application
|
||||||
@@ -463,7 +650,7 @@
|
|||||||
o Enhanced support for Alpha Linux
|
o Enhanced support for Alpha Linux
|
||||||
o Experimental MacOS support
|
o Experimental MacOS support
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.3 and OpenSSL 0.9.4:
|
Major changes between OpenSSL 0.9.3 and OpenSSL 0.9.4 [9 Aug 1999]:
|
||||||
|
|
||||||
o Transparent support for PKCS#8 format private keys: these are used
|
o Transparent support for PKCS#8 format private keys: these are used
|
||||||
by several software packages and are more secure than the standard
|
by several software packages and are more secure than the standard
|
||||||
@@ -474,7 +661,7 @@
|
|||||||
o New pipe-like BIO that allows using the SSL library when actual I/O
|
o New pipe-like BIO that allows using the SSL library when actual I/O
|
||||||
must be handled by the application (BIO pair)
|
must be handled by the application (BIO pair)
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.2b and OpenSSL 0.9.3:
|
Major changes between OpenSSL 0.9.2b and OpenSSL 0.9.3 [24 May 1999]:
|
||||||
o Lots of enhancements and cleanups to the Configuration mechanism
|
o Lots of enhancements and cleanups to the Configuration mechanism
|
||||||
o RSA OEAP related fixes
|
o RSA OEAP related fixes
|
||||||
o Added `openssl ca -revoke' option for revoking a certificate
|
o Added `openssl ca -revoke' option for revoking a certificate
|
||||||
@@ -488,7 +675,7 @@
|
|||||||
o Sparc assembler bignum implementation, optimized hash functions
|
o Sparc assembler bignum implementation, optimized hash functions
|
||||||
o Option to disable selected ciphers
|
o Option to disable selected ciphers
|
||||||
|
|
||||||
Major changes between OpenSSL 0.9.1c and OpenSSL 0.9.2b:
|
Major changes between OpenSSL 0.9.1c and OpenSSL 0.9.2b [22 Mar 1999]:
|
||||||
o Fixed a security hole related to session resumption
|
o Fixed a security hole related to session resumption
|
||||||
o Fixed RSA encryption routines for the p < q case
|
o Fixed RSA encryption routines for the p < q case
|
||||||
o "ALL" in cipher lists now means "everything except NULL ciphers"
|
o "ALL" in cipher lists now means "everything except NULL ciphers"
|
||||||
@@ -510,7 +697,7 @@
|
|||||||
o Lots of memory leak fixes.
|
o Lots of memory leak fixes.
|
||||||
o Lots of bug fixes.
|
o Lots of bug fixes.
|
||||||
|
|
||||||
Major changes between SSLeay 0.9.0b and OpenSSL 0.9.1c:
|
Major changes between SSLeay 0.9.0b and OpenSSL 0.9.1c [23 Dec 1998]:
|
||||||
o Integration of the popular NO_RSA/NO_DSA patches
|
o Integration of the popular NO_RSA/NO_DSA patches
|
||||||
o Initial support for compression inside the SSL record layer
|
o Initial support for compression inside the SSL record layer
|
||||||
o Added BIO proxy and filtering functionality
|
o Added BIO proxy and filtering functionality
|
||||||
|
|||||||
18
PROBLEMS
18
PROBLEMS
@@ -36,7 +36,9 @@ may differ on your machine.
|
|||||||
|
|
||||||
|
|
||||||
As long as Apple doesn't fix the problem with ld, this problem building
|
As long as Apple doesn't fix the problem with ld, this problem building
|
||||||
OpenSSL will remain as is.
|
OpenSSL will remain as is. Well, the problem was addressed in 0.9.8f by
|
||||||
|
passing -Wl,-search_paths_first, but it's unknown if the flag was
|
||||||
|
supported from the initial MacOS X release.
|
||||||
|
|
||||||
|
|
||||||
* Parallell make leads to errors
|
* Parallell make leads to errors
|
||||||
@@ -195,3 +197,17 @@ reconfigure with additional no-sse2 [or 386] option passed to ./config.
|
|||||||
We don't have framework to associate -ldl with no-dso, therefore the only
|
We don't have framework to associate -ldl with no-dso, therefore the only
|
||||||
way is to edit Makefile right after ./config no-dso and remove -ldl from
|
way is to edit Makefile right after ./config no-dso and remove -ldl from
|
||||||
EX_LIBS line.
|
EX_LIBS line.
|
||||||
|
|
||||||
|
* hpux-parisc2-cc no-asm build fails with SEGV in ECDSA/DH.
|
||||||
|
|
||||||
|
Compiler bug, presumably at particular patch level. Remaining
|
||||||
|
hpux*-parisc*-cc configurations can be affected too. Drop optimization
|
||||||
|
level to +O2 when compiling bn_nist.o.
|
||||||
|
|
||||||
|
* solaris64-sparcv9-cc link failure
|
||||||
|
|
||||||
|
Solaris 8 ar can fail to maintain symbol table in .a, which results in
|
||||||
|
link failures. Apply 109147-09 or later or modify Makefile generated
|
||||||
|
by ./Configure solaris64-sparcv9-cc and replace RANLIB assignment with
|
||||||
|
|
||||||
|
RANLIB= /usr/ccs/bin/ar rs
|
||||||
|
|||||||
27
README
27
README
@@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
OpenSSL 1.0.0-dev XX xxx XXXX
|
OpenSSL 1.0.1f 6 Jan 2014
|
||||||
|
|
||||||
Copyright (c) 1998-2008 The OpenSSL Project
|
Copyright (c) 1998-2011 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.
|
||||||
|
|
||||||
@@ -112,8 +112,6 @@
|
|||||||
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.
|
|
||||||
|
|
||||||
NTT and Mitsubishi have patents and pending patents on the Camellia
|
NTT and Mitsubishi have patents and pending patents on the Camellia
|
||||||
algorithm, but allow use at no charge without requiring an explicit
|
algorithm, but allow use at no charge without requiring an explicit
|
||||||
licensing agreement: http://info.isl.ntt.co.jp/crypt/eng/info/chiteki.html
|
licensing agreement: http://info.isl.ntt.co.jp/crypt/eng/info/chiteki.html
|
||||||
@@ -139,6 +137,9 @@
|
|||||||
SUPPORT
|
SUPPORT
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
See the OpenSSL website www.openssl.org for details of how to obtain
|
||||||
|
commercial technical support.
|
||||||
|
|
||||||
If you have any problems with OpenSSL then please take the following steps
|
If you have any problems with OpenSSL then please take the following steps
|
||||||
first:
|
first:
|
||||||
|
|
||||||
@@ -165,6 +166,10 @@
|
|||||||
|
|
||||||
openssl-bugs@openssl.org
|
openssl-bugs@openssl.org
|
||||||
|
|
||||||
|
Note that the request tracker should NOT be used for general assistance
|
||||||
|
or support queries. Just because something doesn't work the way you expect
|
||||||
|
does not mean it is necessarily a bug in OpenSSL.
|
||||||
|
|
||||||
Note that mail to openssl-bugs@openssl.org is recorded in the publicly
|
Note that mail to openssl-bugs@openssl.org is recorded in the publicly
|
||||||
readable request tracker database and is forwarded to a public
|
readable request tracker database and is forwarded to a public
|
||||||
mailing list. Confidential mail may be sent to openssl-security@openssl.org
|
mailing list. Confidential mail may be sent to openssl-security@openssl.org
|
||||||
@@ -175,10 +180,22 @@
|
|||||||
|
|
||||||
Development is coordinated on the openssl-dev mailing list (see
|
Development is coordinated on the openssl-dev mailing list (see
|
||||||
http://www.openssl.org for information on subscribing). If you
|
http://www.openssl.org for information on subscribing). If you
|
||||||
would like to submit a patch, send it to openssl-dev@openssl.org with
|
would like to submit a patch, send it to openssl-bugs@openssl.org with
|
||||||
the string "[PATCH]" in the subject. Please be sure to include a
|
the string "[PATCH]" in the subject. Please be sure to include a
|
||||||
textual explanation of what your patch does.
|
textual explanation of what your patch does.
|
||||||
|
|
||||||
|
If you are unsure as to whether a feature will be useful for the general
|
||||||
|
OpenSSL community please discuss it on the openssl-dev mailing list first.
|
||||||
|
Someone may be already working on the same thing or there may be a good
|
||||||
|
reason as to why that feature isn't implemented.
|
||||||
|
|
||||||
|
Patches should be as up to date as possible, preferably relative to the
|
||||||
|
current Git or the last snapshot. They should follow the coding style of
|
||||||
|
OpenSSL and compile without warnings. Some of the core team developer targets
|
||||||
|
can be used for testing purposes, (debug-steve64, debug-geoff etc). OpenSSL
|
||||||
|
compiles on many varied platforms: try to ensure you only use portable
|
||||||
|
features.
|
||||||
|
|
||||||
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 TSU notification and a copy of the patch are sent to crypt@bis.doc.gov
|
if a TSU notification and a copy of the patch are sent to crypt@bis.doc.gov
|
||||||
(formerly BXA) with a copy to the ENC Encryption Request Coordinator;
|
(formerly BXA) with a copy to the ENC Encryption Request Coordinator;
|
||||||
|
|||||||
132
STATUS
132
STATUS
@@ -1,132 +0,0 @@
|
|||||||
|
|
||||||
OpenSSL STATUS Last modified at
|
|
||||||
______________ $Date: 2009/03/30 11:33:03 $
|
|
||||||
|
|
||||||
DEVELOPMENT STATE
|
|
||||||
|
|
||||||
o OpenSSL 1.0: Under development...
|
|
||||||
o OpenSSL 0.9.8h: Released on May 28th, 2008
|
|
||||||
o OpenSSL 0.9.8g: Released on October 19th, 2007
|
|
||||||
o OpenSSL 0.9.8f: Released on October 11th, 2007
|
|
||||||
o OpenSSL 0.9.8e: Released on February 23rd, 2007
|
|
||||||
o OpenSSL 0.9.8d: Released on September 28th, 2006
|
|
||||||
o OpenSSL 0.9.8c: Released on September 5th, 2006
|
|
||||||
o OpenSSL 0.9.8b: Released on May 4th, 2006
|
|
||||||
o OpenSSL 0.9.8a: Released on October 11th, 2005
|
|
||||||
o OpenSSL 0.9.8: Released on July 5th, 2005
|
|
||||||
o OpenSSL 0.9.7m: Released on February 23rd, 2007
|
|
||||||
o OpenSSL 0.9.7l: Released on September 28th, 2006
|
|
||||||
o OpenSSL 0.9.7k: Released on September 5th, 2006
|
|
||||||
o OpenSSL 0.9.7j: Released on May 4th, 2006
|
|
||||||
o OpenSSL 0.9.7i: Released on October 14th, 2005
|
|
||||||
o OpenSSL 0.9.7h: Released on October 11th, 2005
|
|
||||||
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.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.6h: Released on December 5th, 2002
|
|
||||||
o OpenSSL 0.9.6g: Released on August 9th, 2002
|
|
||||||
o OpenSSL 0.9.6f: Released on August 8th, 2002
|
|
||||||
o OpenSSL 0.9.6e: Released on July 30th, 2002
|
|
||||||
o OpenSSL 0.9.6d: Released on May 9th, 2002
|
|
||||||
o OpenSSL 0.9.6c: Released on December 21st, 2001
|
|
||||||
o OpenSSL 0.9.6b: Released on July 9th, 2001
|
|
||||||
o OpenSSL 0.9.6a: Released on April 5th, 2001
|
|
||||||
o OpenSSL 0.9.6: Released on September 24th, 2000
|
|
||||||
o OpenSSL 0.9.5a: Released on April 1st, 2000
|
|
||||||
o OpenSSL 0.9.5: Released on February 28th, 2000
|
|
||||||
o OpenSSL 0.9.4: Released on August 09th, 1999
|
|
||||||
o OpenSSL 0.9.3a: Released on May 29th, 1999
|
|
||||||
o OpenSSL 0.9.3: Released on May 25th, 1999
|
|
||||||
o OpenSSL 0.9.2b: Released on March 22th, 1999
|
|
||||||
o OpenSSL 0.9.1c: Released on December 23th, 1998
|
|
||||||
|
|
||||||
[See also http://www.openssl.org/support/rt.html]
|
|
||||||
|
|
||||||
RELEASE SHOWSTOPPERS
|
|
||||||
|
|
||||||
o The Makefiles fail with some SysV makes.
|
|
||||||
o
|
|
||||||
|
|
||||||
AVAILABLE PATCHES
|
|
||||||
|
|
||||||
o
|
|
||||||
|
|
||||||
IN PROGRESS
|
|
||||||
|
|
||||||
o Steve is currently working on (in no particular order):
|
|
||||||
ASN1 code redesign, butchery, replacement.
|
|
||||||
OCSP
|
|
||||||
EVP cipher enhancement.
|
|
||||||
Enhanced certificate chain verification.
|
|
||||||
Private key, certificate and CRL API and implementation.
|
|
||||||
Developing and bugfixing PKCS#7 (S/MIME code).
|
|
||||||
Various X509 issues: character sets, certificate request extensions.
|
|
||||||
o Richard is currently working on:
|
|
||||||
Constification
|
|
||||||
Attribute Certificate support
|
|
||||||
Certificate Pair support
|
|
||||||
Storage Engines (primarly an LDAP storage engine)
|
|
||||||
Certificate chain validation with full RFC 3280 compatibility
|
|
||||||
|
|
||||||
NEEDS PATCH
|
|
||||||
|
|
||||||
o 0.9.8-dev: COMPLEMENTOFALL and COMPLEMENTOFDEFAULT do not
|
|
||||||
handle ECCdraft cipher suites correctly.
|
|
||||||
|
|
||||||
o apps/ca.c: "Sign the certificate?" - "n" creates empty certificate file
|
|
||||||
|
|
||||||
o "OpenSSL STATUS" is never up-to-date.
|
|
||||||
|
|
||||||
OPEN ISSUES
|
|
||||||
|
|
||||||
o The Makefile hierarchy and build mechanism is still not a round thing:
|
|
||||||
|
|
||||||
1. The config vs. Configure scripts
|
|
||||||
It's the same nasty situation as for Apache with APACI vs.
|
|
||||||
src/Configure. It confuses.
|
|
||||||
Suggestion: Merge Configure and config into a single configure
|
|
||||||
script with a Autoconf style interface ;-) and remove
|
|
||||||
Configure and config. Or even let us use GNU Autoconf
|
|
||||||
itself. Then we can avoid a lot of those platform checks
|
|
||||||
which are currently in Configure.
|
|
||||||
|
|
||||||
o Support for Shared Libraries has to be added at least
|
|
||||||
for the major Unix platforms. The details we can rip from the stuff
|
|
||||||
Ralf has done for the Apache src/Configure script. Ben wants the
|
|
||||||
solution to be really simple.
|
|
||||||
|
|
||||||
Status: Ralf will look how we can easily incorporate the
|
|
||||||
compiler PIC and linker DSO flags from Apache
|
|
||||||
into the OpenSSL Configure script.
|
|
||||||
|
|
||||||
Ulf: +1 for using GNU autoconf and libtool (but not automake,
|
|
||||||
which apparently is not flexible enough to generate
|
|
||||||
libcrypto)
|
|
||||||
|
|
||||||
WISHES
|
|
||||||
|
|
||||||
o Add variants of DH_generate_parameters() and BN_generate_prime() [etc?]
|
|
||||||
where the callback function can request that the function be aborted.
|
|
||||||
[Gregory Stark <ghstark@pobox.com>, <rayyang2000@yahoo.com>]
|
|
||||||
|
|
||||||
o SRP in TLS.
|
|
||||||
[wished by:
|
|
||||||
Dj <derek@yo.net>, Tom Wu <tom@arcot.com>,
|
|
||||||
Tom Holroyd <tomh@po.crl.go.jp>]
|
|
||||||
|
|
||||||
See http://search.ietf.org/internet-drafts/draft-ietf-tls-srp-00.txt
|
|
||||||
as well as http://www-cs-students.stanford.edu/~tjw/srp/.
|
|
||||||
|
|
||||||
Tom Holroyd tells us there is a SRP patch for OpenSSH at
|
|
||||||
http://members.tripod.com/professor_tom/archives/, that could
|
|
||||||
be useful.
|
|
||||||
67
VMS/install-vms.com
Executable file
67
VMS/install-vms.com
Executable file
@@ -0,0 +1,67 @@
|
|||||||
|
$! install-vms.com -- Installs the files in a given directory tree
|
||||||
|
$!
|
||||||
|
$! Author: Richard Levitte <richard@levitte.org>
|
||||||
|
$! Time of creation: 23-MAY-1998 19:22
|
||||||
|
$!
|
||||||
|
$! P1 root of the directory tree
|
||||||
|
$!
|
||||||
|
$!
|
||||||
|
$! Announce/identify.
|
||||||
|
$!
|
||||||
|
$ proc = f$environment( "procedure")
|
||||||
|
$ write sys$output "@@@ "+ -
|
||||||
|
f$parse( proc, , , "name")+ f$parse( proc, , , "type")
|
||||||
|
$!
|
||||||
|
$ on error then goto tidy
|
||||||
|
$ on control_c then goto tidy
|
||||||
|
$!
|
||||||
|
$ if p1 .eqs. ""
|
||||||
|
$ then
|
||||||
|
$ write sys$output "First argument missing."
|
||||||
|
$ write sys$output -
|
||||||
|
"Should be the directory where you want things installed."
|
||||||
|
$ exit
|
||||||
|
$ endif
|
||||||
|
$
|
||||||
|
$ if (f$getsyi( "cpu") .lt. 128)
|
||||||
|
$ then
|
||||||
|
$ arch = "VAX"
|
||||||
|
$ else
|
||||||
|
$ arch = f$edit( f$getsyi( "arch_name"), "upcase")
|
||||||
|
$ if (arch .eqs. "") then arch = "UNK"
|
||||||
|
$ endif
|
||||||
|
$
|
||||||
|
$ root = f$parse( P1, "[]A.;0", , , "SYNTAX_ONLY, NO_CONCEAL")- "A.;0"
|
||||||
|
$ root_dev = f$parse( root, , , "device", "syntax_only")
|
||||||
|
$ root_dir = f$parse( root, , , "directory", "syntax_only") - -
|
||||||
|
"[000000." - "][" - "[" - "]"
|
||||||
|
$ root = root_dev + "[" + root_dir
|
||||||
|
$
|
||||||
|
$ define /nolog wrk_sslroot 'root'.] /translation_attributes = concealed
|
||||||
|
$ define /nolog wrk_sslinclude wrk_sslroot:[include]
|
||||||
|
$
|
||||||
|
$ if f$parse( "wrk_sslroot:[000000]") .eqs. "" then -
|
||||||
|
create /directory /log wrk_sslroot:[000000]
|
||||||
|
$ if f$parse( "wrk_sslinclude:") .eqs. "" then -
|
||||||
|
create /directory /log wrk_sslinclude:
|
||||||
|
$ if f$parse( "wrk_sslroot:[vms]") .eqs. "" then -
|
||||||
|
create /directory /log wrk_sslroot:[vms]
|
||||||
|
$!
|
||||||
|
$ copy /log /protection = world:re openssl_startup.com wrk_sslroot:[vms]
|
||||||
|
$ copy /log /protection = world:re openssl_undo.com wrk_sslroot:[vms]
|
||||||
|
$ copy /log /protection = world:re openssl_utils.com wrk_sslroot:[vms]
|
||||||
|
$!
|
||||||
|
$ tidy:
|
||||||
|
$!
|
||||||
|
$ call deass wrk_sslroot
|
||||||
|
$ call deass wrk_sslinclude
|
||||||
|
$!
|
||||||
|
$ exit
|
||||||
|
$!
|
||||||
|
$ deass: subroutine
|
||||||
|
$ if (f$trnlnm( p1, "LNM$PROCESS") .nes. "")
|
||||||
|
$ then
|
||||||
|
$ deassign /process 'p1'
|
||||||
|
$ endif
|
||||||
|
$ endsubroutine
|
||||||
|
$!
|
||||||
@@ -1,72 +0,0 @@
|
|||||||
$! INSTALL.COM -- Installs the files in a given directory tree
|
|
||||||
$!
|
|
||||||
$! Author: Richard Levitte <richard@levitte.org>
|
|
||||||
$! Time of creation: 23-MAY-1998 19:22
|
|
||||||
$!
|
|
||||||
$! P1 root of the directory tree
|
|
||||||
$!
|
|
||||||
$ IF P1 .EQS. ""
|
|
||||||
$ THEN
|
|
||||||
$ WRITE SYS$OUTPUT "First argument missing."
|
|
||||||
$ WRITE SYS$OUTPUT "Should be the directory where you want things installed."
|
|
||||||
$ EXIT
|
|
||||||
$ ENDIF
|
|
||||||
$
|
|
||||||
$ ROOT = F$PARSE(P1,"[]A.;0",,,"SYNTAX_ONLY,NO_CONCEAL") - "A.;0"
|
|
||||||
$ ROOT_DEV = F$PARSE(ROOT,,,"DEVICE","SYNTAX_ONLY")
|
|
||||||
$ ROOT_DIR = F$PARSE(ROOT,,,"DIRECTORY","SYNTAX_ONLY") -
|
|
||||||
- "[000000." - "][" - "[" - "]"
|
|
||||||
$ ROOT = ROOT_DEV + "[" + ROOT_DIR
|
|
||||||
$
|
|
||||||
$ DEFINE/NOLOG WRK_SSLROOT 'ROOT'.] /TRANS=CONC
|
|
||||||
$ DEFINE/NOLOG WRK_SSLVLIB WRK_SSLROOT:[VAX_LIB]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLALIB WRK_SSLROOT:[ALPHA_LIB]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLINCLUDE WRK_SSLROOT:[INCLUDE]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLVEXE WRK_SSLROOT:[VAX_EXE]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLAEXE WRK_SSLROOT:[ALPHA_EXE]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLCERTS WRK_SSLROOT:[CERTS]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLPRIVATE WRK_SSLROOT:[PRIVATE]
|
|
||||||
$
|
|
||||||
$ IF F$PARSE("WRK_SSLROOT:[000000]") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLROOT:[000000]
|
|
||||||
$ IF F$PARSE("WRK_SSLINCLUDE:") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLINCLUDE:
|
|
||||||
$ IF F$PARSE("WRK_SSLROOT:[VMS]") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLROOT:[VMS]
|
|
||||||
$
|
|
||||||
$ IF F$SEARCH("WRK_SSLINCLUDE:vms_idhacks.h") .NES. "" THEN -
|
|
||||||
DELETE WRK_SSLINCLUDE:vms_idhacks.h;*
|
|
||||||
$
|
|
||||||
$ OPEN/WRITE SF WRK_SSLROOT:[VMS]OPENSSL_STARTUP.COM
|
|
||||||
$ WRITE SYS$OUTPUT "%OPEN-I-CREATED, ",F$SEARCH("WRK_SSLROOT:[VMS]OPENSSL_STARTUP.COM")," created."
|
|
||||||
$ WRITE SF "$! Startup file for Openssl 0.9.2-RL 15-Mar-1999"
|
|
||||||
$ WRITE SF "$!"
|
|
||||||
$ WRITE SF "$! Do not edit this file, as it will be regenerated during next installation."
|
|
||||||
$ WRITE SF "$! Instead, add or change SSLROOT:[VMS]OPENSSL_SYSTARTUP.COM"
|
|
||||||
$ WRITE SF "$!"
|
|
||||||
$ WRITE SF "$! P1 a qualifier to DEFINE. For example ""/SYSTEM"" to get the logical names"
|
|
||||||
$ WRITE SF "$! defined in the system logical name table."
|
|
||||||
$ WRITE SF "$!"
|
|
||||||
$ WRITE SF "$ ARCH = ""VAX"""
|
|
||||||
$ WRITE SF "$ IF F$GETSYI(""CPU"") .GE. 128 THEN ARCH = ""ALPHA"""
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 SSLROOT ",ROOT,".] /TRANS=CONC"
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 SSLLIB SSLROOT:['ARCH'_LIB]"
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 SSLINCLUDE SSLROOT:[INCLUDE]"
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 SSLEXE SSLROOT:['ARCH'_EXE]"
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 SSLCERTS SSLROOT:[CERTS]"
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 SSLPRIVATE SSLROOT:[PRIVATE]"
|
|
||||||
$ WRITE SF "$"
|
|
||||||
$ WRITE SF "$! This is program can include <openssl/{foo}.h>"
|
|
||||||
$ WRITE SF "$ DEFINE/NOLOG'P1 OPENSSL SSLINCLUDE:"
|
|
||||||
$ WRITE SF "$"
|
|
||||||
$ WRITE SF "$ IF F$SEARCH(""SSLROOT:[VMS]OPENSSL_SYSTARTUP.COM"") .NES."""" THEN -"
|
|
||||||
$ WRITE SF " @SSLROOT:[VMS]OPENSSL_SYSTARTUP.COM"
|
|
||||||
$ WRITE SF "$"
|
|
||||||
$ WRITE SF "$ EXIT"
|
|
||||||
$ CLOSE SF
|
|
||||||
$ SET FILE/PROT=WORLD:RE WRK_SSLROOT:[VMS]OPENSSL_STARTUP.COM
|
|
||||||
$
|
|
||||||
$ COPY OPENSSL_UTILS.COM WRK_SSLROOT:[VMS]/LOG
|
|
||||||
$ SET FILE/PROT=WORLD:RE WRK_SSLROOT:[VMS]OPENSSL_UTILS.COM
|
|
||||||
$
|
|
||||||
$ EXIT
|
|
||||||
276
VMS/mkshared.com
276
VMS/mkshared.com
@@ -1,77 +1,168 @@
|
|||||||
$! MKSHARED.COM -- script to created shareable images on VMS
|
$! MKSHARED.COM -- Create shareable images.
|
||||||
$!
|
$!
|
||||||
$! No command line parameters. This should be run at the start of the source
|
$! P1: "64" for 64-bit pointers.
|
||||||
$! tree (the same directory where one finds INSTALL.VMS).
|
|
||||||
$!
|
$!
|
||||||
$! Input: [.UTIL]LIBEAY.NUM,[.AXP.EXE.CRYPTO]LIBCRYPTO.OLB
|
$! P2: Zlib object library path (optional).
|
||||||
$! [.UTIL]SSLEAY.NUM,[.AXP.EXE.SSL]LIBSSL.OLB
|
$!
|
||||||
$! Output: [.AXP.EXE.CRYPTO]LIBCRYPTO.OPT,.MAP,.EXE
|
$! Input: [.UTIL]LIBEAY.NUM,[.xxx.EXE.CRYPTO]SSL_LIBCRYPTO[32].OLB
|
||||||
$! [.AXP.EXE.SSL]LIBSSL.OPT,.MAP,.EXE
|
$! [.UTIL]SSLEAY.NUM,[.xxx.EXE.SSL]SSL_LIBSSL[32].OLB
|
||||||
|
$! [.CRYPTO.xxx]OPENSSLCONF.H
|
||||||
|
$! Output: [.xxx.EXE.CRYPTO]SSL_LIBCRYPTO_SHR[32].OPT,.MAP,.EXE
|
||||||
|
$! [.xxx.EXE.SSL]SSL_LIBSSL_SRH[32].OPT,.MAP,.EXE
|
||||||
$!
|
$!
|
||||||
$! So far, tests have only been made on VMS for Alpha. VAX will come in time.
|
$! So far, tests have only been made on VMS for Alpha. VAX will come in time.
|
||||||
$! ===========================================================================
|
$! ===========================================================================
|
||||||
$
|
$!
|
||||||
|
$! Announce/identify.
|
||||||
|
$!
|
||||||
|
$ proc = f$environment( "procedure")
|
||||||
|
$ write sys$output "@@@ "+ -
|
||||||
|
f$parse( proc, , , "name")+ f$parse( proc, , , "type")
|
||||||
|
$!
|
||||||
|
$! Save the original default device:[directory].
|
||||||
|
$!
|
||||||
|
$ def_orig = f$environment( "default")
|
||||||
|
$ on error then goto tidy
|
||||||
|
$ on control_c then goto tidy
|
||||||
|
$!
|
||||||
|
$! SET DEFAULT to the main kit directory.
|
||||||
|
$!
|
||||||
|
$ proc = f$environment("procedure")
|
||||||
|
$ proc = f$parse( "A.;", proc)- "A.;"
|
||||||
|
$ set default 'proc'
|
||||||
|
$ set default [-]
|
||||||
|
$!
|
||||||
$! ----- Prepare info for processing: version number and file info
|
$! ----- Prepare info for processing: version number and file info
|
||||||
$ gosub read_version_info
|
$ gosub read_version_info
|
||||||
$ if libver .eqs. ""
|
$ if libver .eqs. ""
|
||||||
$ then
|
$ then
|
||||||
$ write sys$error "ERROR: Couldn't find any library version info..."
|
$ write sys$error "ERROR: Couldn't find any library version info..."
|
||||||
$ exit
|
$ go to tidy:
|
||||||
$ endif
|
$ endif
|
||||||
$
|
$
|
||||||
$ if f$getsyi("CPU") .ge. 128
|
$ if (f$getsyi("cpu") .lt. 128)
|
||||||
$ then
|
$ then
|
||||||
$ libid = "Crypto"
|
$ arch_vax = 1
|
||||||
$ libnum = "[.UTIL]LIBEAY.NUM"
|
$ arch = "VAX"
|
||||||
$ libdir = "[.AXP.EXE.CRYPTO]"
|
|
||||||
$ libolb = "''libdir'LIBCRYPTO.OLB"
|
|
||||||
$ libopt = "''libdir'LIBCRYPTO.OPT"
|
|
||||||
$ libmap = "''libdir'LIBCRYPTO.MAP"
|
|
||||||
$ libgoal= "''libdir'LIBCRYPTO.EXE"
|
|
||||||
$ libref = ""
|
|
||||||
$ gosub create_axp_shr
|
|
||||||
$ libid = "SSL"
|
|
||||||
$ libnum = "[.UTIL]SSLEAY.NUM"
|
|
||||||
$ libdir = "[.AXP.EXE.SSL]"
|
|
||||||
$ libolb = "''libdir'LIBSSL.OLB"
|
|
||||||
$ libopt = "''libdir'LIBSSL.OPT"
|
|
||||||
$ libmap = "''libdir'LIBSSL.MAP"
|
|
||||||
$ libgoal= "''libdir'LIBSSL.EXE"
|
|
||||||
$ libref = "[.AXP.EXE.CRYPTO]LIBCRYPTO.EXE"
|
|
||||||
$ gosub create_axp_shr
|
|
||||||
$ else
|
$ else
|
||||||
|
$ arch_vax = 0
|
||||||
|
$ arch = f$edit( f$getsyi( "ARCH_NAME"), "UPCASE")
|
||||||
|
$ if (arch .eqs. "") then arch = "UNK"
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ archd = arch
|
||||||
|
$ lib32 = "32"
|
||||||
|
$ shr = "SHR32"
|
||||||
|
$!
|
||||||
|
$ if (p1 .nes. "")
|
||||||
|
$ then
|
||||||
|
$ if (p1 .eqs. "64")
|
||||||
|
$ then
|
||||||
|
$ archd = arch+ "_64"
|
||||||
|
$ lib32 = ""
|
||||||
|
$ shr = "SHR"
|
||||||
|
$ else
|
||||||
|
$ if (p1 .nes. "32")
|
||||||
|
$ then
|
||||||
|
$ write sys$output "Second argument invalid."
|
||||||
|
$ write sys$output "It should be "32", "64", or nothing."
|
||||||
|
$ exit
|
||||||
|
$ endif
|
||||||
|
$ endif
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$! ----- Prepare info for processing: disabled algorithms info
|
||||||
|
$ gosub read_disabled_algorithms_info
|
||||||
|
$!
|
||||||
|
$ ZLIB = p2
|
||||||
|
$ zlib_lib = ""
|
||||||
|
$ if (ZLIB .nes. "")
|
||||||
|
$ then
|
||||||
|
$ file2 = f$parse( ZLIB, "libz.olb", , , "syntax_only")
|
||||||
|
$ if (f$search( file2) .eqs. "")
|
||||||
|
$ then
|
||||||
|
$ write sys$output ""
|
||||||
|
$ write sys$output "The Option ", ZLIB, " Is Invalid."
|
||||||
|
$ write sys$output " Can't find library: ''file2'"
|
||||||
|
$ write sys$output ""
|
||||||
|
$ goto tidy
|
||||||
|
$ endif
|
||||||
|
$ zlib_lib = ", ''file2' /library"
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ if (arch_vax)
|
||||||
|
$ then
|
||||||
$ libtit = "CRYPTO_TRANSFER_VECTOR"
|
$ libtit = "CRYPTO_TRANSFER_VECTOR"
|
||||||
$ libid = "Crypto"
|
$ libid = "Crypto"
|
||||||
$ libnum = "[.UTIL]LIBEAY.NUM"
|
$ libnum = "[.UTIL]LIBEAY.NUM"
|
||||||
$ libdir = "[.VAX.EXE.CRYPTO]"
|
$ libdir = "[.''ARCHD'.EXE.CRYPTO]"
|
||||||
$ libmar = "''libdir'LIBCRYPTO.MAR"
|
$ libmar = "''libdir'SSL_LIBCRYPTO_''shr'.MAR"
|
||||||
$ libolb = "''libdir'LIBCRYPTO.OLB"
|
$ libolb = "''libdir'SSL_LIBCRYPTO''lib32'.OLB"
|
||||||
$ libopt = "''libdir'LIBCRYPTO.OPT"
|
$ libopt = "''libdir'SSL_LIBCRYPTO_''shr'.OPT"
|
||||||
$ libobj = "''libdir'LIBCRYPTO.OBJ"
|
$ libobj = "''libdir'SSL_LIBCRYPTO_''shr'.OBJ"
|
||||||
$ libmap = "''libdir'LIBCRYPTO.MAP"
|
$ libmap = "''libdir'SSL_LIBCRYPTO_''shr'.MAP"
|
||||||
$ libgoal= "''libdir'LIBCRYPTO.EXE"
|
$ libgoal= "''libdir'SSL_LIBCRYPTO_''shr'.EXE"
|
||||||
$ libref = ""
|
$ libref = ""
|
||||||
$ libvec = "LIBCRYPTO"
|
$ libvec = "LIBCRYPTO"
|
||||||
$ gosub create_vax_shr
|
$ if f$search( libolb) .nes. "" then gosub create_vax_shr
|
||||||
$ libtit = "SSL_TRANSFER_VECTOR"
|
$ libtit = "SSL_TRANSFER_VECTOR"
|
||||||
$ libid = "SSL"
|
$ libid = "SSL"
|
||||||
$ libnum = "[.UTIL]SSLEAY.NUM"
|
$ libnum = "[.UTIL]SSLEAY.NUM"
|
||||||
$ libdir = "[.VAX.EXE.SSL]"
|
$ libdir = "[.''ARCHD'.EXE.SSL]"
|
||||||
$ libmar = "''libdir'LIBSSL.MAR"
|
$ libmar = "''libdir'SSL_LIBSSL_''shr'.MAR"
|
||||||
$ libolb = "''libdir'LIBSSL.OLB"
|
$ libolb = "''libdir'SSL_LIBSSL''lib32'.OLB"
|
||||||
$ libopt = "''libdir'LIBSSL.OPT"
|
$ libopt = "''libdir'SSL_LIBSSL_''shr'.OPT"
|
||||||
$ libobj = "''libdir'LIBSSL.OBJ"
|
$ libobj = "''libdir'SSL_LIBSSL_''shr'.OBJ"
|
||||||
$ libmap = "''libdir'LIBSSL.MAP"
|
$ libmap = "''libdir'SSL_LIBSSL_''shr'.MAP"
|
||||||
$ libgoal= "''libdir'LIBSSL.EXE"
|
$ libgoal= "''libdir'SSL_LIBSSL_''shr'.EXE"
|
||||||
$ libref = "[.VAX.EXE.CRYPTO]LIBCRYPTO.EXE"
|
$ libref = "[.''ARCHD'.EXE.CRYPTO]SSL_LIBCRYPTO_''shr'.EXE"
|
||||||
$ libvec = "LIBSSL"
|
$ libvec = "LIBSSL"
|
||||||
$ gosub create_vax_shr
|
$ if f$search( libolb) .nes. "" then gosub create_vax_shr
|
||||||
|
$ else
|
||||||
|
$ libid = "Crypto"
|
||||||
|
$ libnum = "[.UTIL]LIBEAY.NUM"
|
||||||
|
$ libdir = "[.''ARCHD'.EXE.CRYPTO]"
|
||||||
|
$ libolb = "''libdir'SSL_LIBCRYPTO''lib32'.OLB"
|
||||||
|
$ libopt = "''libdir'SSL_LIBCRYPTO_''shr'.OPT"
|
||||||
|
$ libmap = "''libdir'SSL_LIBCRYPTO_''shr'.MAP"
|
||||||
|
$ libgoal= "''libdir'SSL_LIBCRYPTO_''shr'.EXE"
|
||||||
|
$ libref = ""
|
||||||
|
$ if f$search( libolb) .nes. "" then gosub create_nonvax_shr
|
||||||
|
$ libid = "SSL"
|
||||||
|
$ libnum = "[.UTIL]SSLEAY.NUM"
|
||||||
|
$ libdir = "[.''ARCHD'.EXE.SSL]"
|
||||||
|
$ libolb = "''libdir'SSL_LIBSSL''lib32'.OLB"
|
||||||
|
$ libopt = "''libdir'SSL_LIBSSL_''shr'.OPT"
|
||||||
|
$ libmap = "''libdir'SSL_LIBSSL_''shr'.MAP"
|
||||||
|
$ libgoal= "''libdir'SSL_LIBSSL_''shr'.EXE"
|
||||||
|
$ libref = "[.''ARCHD'.EXE.CRYPTO]SSL_LIBCRYPTO_''shr'.EXE"
|
||||||
|
$ if f$search( libolb) .nes. "" then gosub create_nonvax_shr
|
||||||
$ endif
|
$ endif
|
||||||
|
$!
|
||||||
|
$ tidy:
|
||||||
|
$!
|
||||||
|
$! Close any open files.
|
||||||
|
$!
|
||||||
|
$ if (f$trnlnm( "libnum", "LNM$PROCESS", 0, "SUPERVISOR") .nes. "") then -
|
||||||
|
close libnum
|
||||||
|
$!
|
||||||
|
$ if (f$trnlnm( "mar", "LNM$PROCESS", 0, "SUPERVISOR") .nes. "") then -
|
||||||
|
close mar
|
||||||
|
$!
|
||||||
|
$ if (f$trnlnm( "opt", "LNM$PROCESS", 0, "SUPERVISOR") .nes. "") then -
|
||||||
|
close opt
|
||||||
|
$!
|
||||||
|
$ if (f$trnlnm( "vf", "LNM$PROCESS", 0, "SUPERVISOR") .nes. "") then -
|
||||||
|
close vf
|
||||||
|
$!
|
||||||
|
$! Restore the original default device:[directory].
|
||||||
|
$!
|
||||||
|
$ set default 'def_orig'
|
||||||
$ exit
|
$ exit
|
||||||
$
|
$
|
||||||
$! ----- Soubroutines to actually build the shareable libraries
|
$! ----- Subroutines to build the shareable libraries
|
||||||
$! The way things work, there's a main shareable library creator for each
|
$! For each supported architecture, there's a main shareable library
|
||||||
$! supported architecture, which is called from the main code above.
|
$! creator, which is called from the main code above.
|
||||||
$! The creator will define a number of variables to tell the next levels of
|
$! The creator will define a number of variables to tell the next levels of
|
||||||
$! subroutines what routines to use to write to the option files, call the
|
$! subroutines what routines to use to write to the option files, call the
|
||||||
$! main processor, read_func_num, and when that is done, it will write version
|
$! main processor, read_func_num, and when that is done, it will write version
|
||||||
@@ -97,28 +188,29 @@ $! read_func_num depends on the following variables from the creator:
|
|||||||
$! libwriter The name of the writer routine to call for each .num file line
|
$! libwriter The name of the writer routine to call for each .num file line
|
||||||
$! -----
|
$! -----
|
||||||
$
|
$
|
||||||
$! ----- Subroutines for AXP
|
$! ----- Subroutines for non-VAX
|
||||||
$! -----
|
$! -----
|
||||||
$! The creator routine
|
$! The creator routine
|
||||||
$ create_axp_shr:
|
$ create_nonvax_shr:
|
||||||
$ open/write opt 'libopt'
|
$ open /write opt 'libopt'
|
||||||
$ write opt "identification=""",libid," ",libverstr,""""
|
$ write opt "identification=""",libid," ",libverstr,""""
|
||||||
$ write opt libolb,"/lib"
|
$ write opt libolb, " /library"
|
||||||
$ if libref .nes. "" then write opt libref,"/SHARE"
|
$ if libref .nes. "" then write opt libref,"/SHARE"
|
||||||
$ write opt "SYMBOL_VECTOR=(-"
|
$ write opt "SYMBOL_VECTOR=(-"
|
||||||
$ libfirstentry := true
|
$ libfirstentry := true
|
||||||
$ libwrch := opt
|
$ libwrch := opt
|
||||||
$ libwriter := write_axp_transfer_entry
|
$ libwriter := write_nonvax_transfer_entry
|
||||||
$ textcount = 0
|
$ textcount = 0
|
||||||
$ gosub read_func_num
|
$ gosub read_func_num
|
||||||
$ write opt ")"
|
$ write opt ")"
|
||||||
$ write opt "GSMATCH=",libvmatch,",",libver
|
$ write opt "GSMATCH=",libvmatch,",",libver
|
||||||
$ close opt
|
$ close opt
|
||||||
$ link/map='libmap'/full/share='libgoal' 'libopt'/option
|
$ link /map = 'libmap' /full /share = 'libgoal' 'libopt' /options -
|
||||||
|
'zlib_lib'
|
||||||
$ return
|
$ return
|
||||||
$
|
$
|
||||||
$! The record writer routine
|
$! The record writer routine
|
||||||
$ write_axp_transfer_entry:
|
$ write_nonvax_transfer_entry:
|
||||||
$ if libentry .eqs. ".dummy" then return
|
$ if libentry .eqs. ".dummy" then return
|
||||||
$ if info_kind .eqs. "VARIABLE"
|
$ if info_kind .eqs. "VARIABLE"
|
||||||
$ then
|
$ then
|
||||||
@@ -144,11 +236,11 @@ $ libfirstentry := false
|
|||||||
$ textcount = textcount + textcount_this
|
$ textcount = textcount + textcount_this
|
||||||
$ return
|
$ return
|
||||||
$
|
$
|
||||||
$! ----- Subroutines for AXP
|
$! ----- Subroutines for VAX
|
||||||
$! -----
|
$! -----
|
||||||
$! The creator routine
|
$! The creator routine
|
||||||
$ create_vax_shr:
|
$ create_vax_shr:
|
||||||
$ open/write mar 'libmar'
|
$ open /write mar 'libmar'
|
||||||
$ type sys$input:/out=mar:
|
$ type sys$input:/out=mar:
|
||||||
;
|
;
|
||||||
; Transfer vector for VAX shareable image
|
; Transfer vector for VAX shareable image
|
||||||
@@ -183,10 +275,10 @@ $! libwriter := write_vax_vtransfer_entry
|
|||||||
$! gosub read_func_num
|
$! gosub read_func_num
|
||||||
$ write mar " .END"
|
$ write mar " .END"
|
||||||
$ close mar
|
$ close mar
|
||||||
$ open/write opt 'libopt'
|
$ open /write opt 'libopt'
|
||||||
$ write opt "identification=""",libid," ",libverstr,""""
|
$ write opt "identification=""",libid," ",libverstr,""""
|
||||||
$ write opt libobj
|
$ write opt libobj
|
||||||
$ write opt libolb,"/lib"
|
$ write opt libolb, " /library"
|
||||||
$ if libref .nes. "" then write opt libref,"/SHARE"
|
$ if libref .nes. "" then write opt libref,"/SHARE"
|
||||||
$ type sys$input:/out=opt:
|
$ type sys$input:/out=opt:
|
||||||
!
|
!
|
||||||
@@ -205,7 +297,8 @@ $ libwriter := write_vax_psect_attr
|
|||||||
$ gosub read_func_num
|
$ gosub read_func_num
|
||||||
$ close opt
|
$ close opt
|
||||||
$ macro/obj='libobj' 'libmar'
|
$ macro/obj='libobj' 'libmar'
|
||||||
$ link/map='libmap'/full/share='libgoal' 'libopt'/option
|
$ link /map = 'libmap' /full /share = 'libgoal' 'libopt' /options -
|
||||||
|
'zlib_lib'
|
||||||
$ return
|
$ return
|
||||||
$
|
$
|
||||||
$! The record writer routine for VAX functions
|
$! The record writer routine for VAX functions
|
||||||
@@ -227,9 +320,9 @@ $ return
|
|||||||
$
|
$
|
||||||
$! ----- Common subroutines
|
$! ----- Common subroutines
|
||||||
$! -----
|
$! -----
|
||||||
$! The .num file reader. This one has great responsability.
|
$! The .num file reader. This one has great responsibility.
|
||||||
$ read_func_num:
|
$ read_func_num:
|
||||||
$ open libnum 'libnum'
|
$ open /read libnum 'libnum'
|
||||||
$ goto read_nums
|
$ goto read_nums
|
||||||
$
|
$
|
||||||
$ read_nums:
|
$ read_nums:
|
||||||
@@ -237,35 +330,46 @@ $ libentrynum=0
|
|||||||
$ liblastentry:=false
|
$ liblastentry:=false
|
||||||
$ entrycount=0
|
$ entrycount=0
|
||||||
$ loop:
|
$ loop:
|
||||||
$ read/end=loop_end/err=loop_end libnum line
|
$ read /end=loop_end /err=loop_end libnum line
|
||||||
$ entrynum=f$int(f$element(1," ",f$edit(line,"COMPRESS,TRIM")))
|
$ lin = f$edit( line, "COMPRESS,TRIM")
|
||||||
$ entryinfo=f$element(2," ",f$edit(line,"COMPRESS,TRIM"))
|
$! Skip a "#" comment line.
|
||||||
$ curentry=f$element(0," ",f$edit(line,"COMPRESS,TRIM"))
|
$ if (f$extract( 0, 1, lin) .eqs. "#") then goto loop
|
||||||
$ info_exist=f$element(0,":",entryinfo)
|
$ entrynum = f$int(f$element( 1, " ", lin))
|
||||||
$ info_platforms=","+f$element(1,":",entryinfo)+","
|
$ entryinfo = f$element( 2, " ", lin)
|
||||||
$ info_kind=f$element(2,":",entryinfo)
|
$ curentry = f$element( 0, " ", lin)
|
||||||
$ info_algorithms=","+f$element(3,":",entryinfo)+","
|
$ info_exist = f$element( 0, ":", entryinfo)
|
||||||
|
$ info_platforms = ","+ f$element(1, ":", entryinfo)+ ","
|
||||||
|
$ info_kind = f$element( 2, ":", entryinfo)
|
||||||
|
$ info_algorithms = ","+ f$element( 3, ":", entryinfo)+ ","
|
||||||
$ if info_exist .eqs. "NOEXIST" then goto loop
|
$ if info_exist .eqs. "NOEXIST" then goto loop
|
||||||
$ truesum = 0
|
$ truesum = 0
|
||||||
$ falsesum = 0
|
$ falsesum = 0
|
||||||
$ negatives = 1
|
$ negatives = 1
|
||||||
$ plat_i = 0
|
$ plat_i = 0
|
||||||
$ loop1:
|
$ loop1:
|
||||||
$ plat_entry = f$element(plat_i,",",info_platforms)
|
$ plat_entry = f$element( plat_i, ",", info_platforms)
|
||||||
$ plat_i = plat_i + 1
|
$ plat_i = plat_i + 1
|
||||||
$ if plat_entry .eqs. "" then goto loop1
|
$ if plat_entry .eqs. "" then goto loop1
|
||||||
$ if plat_entry .nes. ","
|
$ if plat_entry .nes. ","
|
||||||
$ then
|
$ then
|
||||||
$ if f$extract(0,1,plat_entry) .nes. "!" then negatives = 0
|
$ if f$extract(0,1,plat_entry) .nes. "!" then negatives = 0
|
||||||
$ if f$getsyi("CPU") .lt. 128
|
$ if (arch_vax)
|
||||||
$ then
|
$ then
|
||||||
$ if plat_entry .eqs. "EXPORT_VAR_AS_FUNCTION" then -
|
$ if plat_entry .eqs. "EXPORT_VAR_AS_FUNCTION" then -
|
||||||
$ truesum = truesum + 1
|
$ truesum = truesum + 1
|
||||||
$ if plat_entry .eqs. "!EXPORT_VAR_AS_FUNCTION" then -
|
$ if plat_entry .eqs. "!EXPORT_VAR_AS_FUNCTION" then -
|
||||||
$ falsesum = falsesum + 1
|
$ falsesum = falsesum + 1
|
||||||
$ endif
|
$ endif
|
||||||
$ if plat_entry .eqs. "VMS" then truesum = truesum + 1
|
$!
|
||||||
$ if plat_entry .eqs. "!VMS" then falsesum = falsesum + 1
|
$ if ((plat_entry .eqs. "VMS") .or. -
|
||||||
|
((plat_entry .eqs. "ZLIB") .and. (ZLIB .nes. "")) .or. -
|
||||||
|
(arch_vax .and. (plat_entry .eqs. "VMSVAX"))) then -
|
||||||
|
truesum = truesum + 1
|
||||||
|
$!
|
||||||
|
$ if ((plat_entry .eqs. "!VMS") .or. -
|
||||||
|
(arch_vax .and. (plat_entry .eqs. "!VMSVAX"))) then -
|
||||||
|
falsesum = falsesum + 1
|
||||||
|
$!
|
||||||
$ goto loop1
|
$ goto loop1
|
||||||
$ endif
|
$ endif
|
||||||
$ endloop1:
|
$ endloop1:
|
||||||
@@ -284,8 +388,7 @@ $ alg_i = alg_i + 1
|
|||||||
$ if alg_entry .eqs. "" then goto loop2
|
$ if alg_entry .eqs. "" then goto loop2
|
||||||
$ if alg_entry .nes. ","
|
$ if alg_entry .nes. ","
|
||||||
$ then
|
$ then
|
||||||
$ if alg_entry .eqs. "KRB5" then goto loop ! Special for now
|
$ if disabled_algorithms - ("," + alg_entry + ",") .nes disabled_algorithms then goto loop
|
||||||
$ if alg_entry .eqs. "STATIC_ENGINE" then goto loop ! Special for now
|
|
||||||
$ if f$trnlnm("OPENSSL_NO_"+alg_entry) .nes. "" then goto loop
|
$ if f$trnlnm("OPENSSL_NO_"+alg_entry) .nes. "" then goto loop
|
||||||
$ goto loop2
|
$ goto loop2
|
||||||
$ endif
|
$ endif
|
||||||
@@ -328,7 +431,7 @@ $
|
|||||||
$! The version number reader
|
$! The version number reader
|
||||||
$ read_version_info:
|
$ read_version_info:
|
||||||
$ libver = ""
|
$ libver = ""
|
||||||
$ open/read vf [.CRYPTO]OPENSSLV.H
|
$ open /read vf [.CRYPTO]OPENSSLV.H
|
||||||
$ loop_rvi:
|
$ loop_rvi:
|
||||||
$ read/err=endloop_rvi/end=endloop_rvi vf rvi_line
|
$ read/err=endloop_rvi/end=endloop_rvi vf rvi_line
|
||||||
$ if rvi_line - "SHLIB_VERSION_NUMBER """ .eqs. rvi_line then -
|
$ if rvi_line - "SHLIB_VERSION_NUMBER """ .eqs. rvi_line then -
|
||||||
@@ -352,3 +455,22 @@ $ endif
|
|||||||
$ endloop_rvi:
|
$ endloop_rvi:
|
||||||
$ close vf
|
$ close vf
|
||||||
$ return
|
$ return
|
||||||
|
$
|
||||||
|
$! The disabled algorithms reader
|
||||||
|
$ read_disabled_algorithms_info:
|
||||||
|
$ disabled_algorithms = ","
|
||||||
|
$ open /read cf [.CRYPTO.'ARCH']OPENSSLCONF.H
|
||||||
|
$ loop_rci:
|
||||||
|
$ read/err=endloop_rci/end=endloop_rci cf rci_line
|
||||||
|
$ rci_line = f$edit(rci_line,"TRIM,COMPRESS")
|
||||||
|
$ rci_ei = 0
|
||||||
|
$ if f$extract(0,9,rci_line) .eqs. "# define " then rci_ei = 2
|
||||||
|
$ if f$extract(0,8,rci_line) .eqs. "#define " then rci_ei = 1
|
||||||
|
$ if rci_ei .eq. 0 then goto loop_rci
|
||||||
|
$ rci_e = f$element(rci_ei," ",rci_line)
|
||||||
|
$ if f$extract(0,11,rci_e) .nes. "OPENSSL_NO_" then goto loop_rci
|
||||||
|
$ disabled_algorithms = disabled_algorithms + f$extract(11,999,rci_e) + ","
|
||||||
|
$ goto loop_rci
|
||||||
|
$ endloop_rci:
|
||||||
|
$ close cf
|
||||||
|
$ return
|
||||||
|
|||||||
108
VMS/openssl_startup.com
Executable file
108
VMS/openssl_startup.com
Executable file
@@ -0,0 +1,108 @@
|
|||||||
|
$!
|
||||||
|
$! Startup file for OpenSSL 1.x.
|
||||||
|
$!
|
||||||
|
$! 2011-03-05 SMS.
|
||||||
|
$!
|
||||||
|
$! This procedure must reside in the OpenSSL installation directory.
|
||||||
|
$! It will fail if it is copied to a different location.
|
||||||
|
$!
|
||||||
|
$! P1 qualifier(s) for DEFINE. For example, "/SYSTEM" to get the
|
||||||
|
$! logical names defined in the system logical name table.
|
||||||
|
$!
|
||||||
|
$! P2 "64", to use executables which were built with 64-bit pointers.
|
||||||
|
$!
|
||||||
|
$! Good (default) and bad status values.
|
||||||
|
$!
|
||||||
|
$ status = %x00010001 ! RMS$_NORMAL, normal successful completion.
|
||||||
|
$ rms_e_fnf = %x00018292 ! RMS$_FNF, file not found.
|
||||||
|
$!
|
||||||
|
$! Prepare for problems.
|
||||||
|
$!
|
||||||
|
$ orig_dev_dir = f$environment( "DEFAULT")
|
||||||
|
$ on control_y then goto clean_up
|
||||||
|
$ on error then goto clean_up
|
||||||
|
$!
|
||||||
|
$! Determine hardware architecture.
|
||||||
|
$!
|
||||||
|
$ if (f$getsyi( "cpu") .lt. 128)
|
||||||
|
$ then
|
||||||
|
$ arch_name = "VAX"
|
||||||
|
$ else
|
||||||
|
$ arch_name = f$edit( f$getsyi( "arch_name"), "upcase")
|
||||||
|
$ if (arch_name .eqs. "") then arch_name = "UNK"
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ if (p2 .eqs. "64")
|
||||||
|
$ then
|
||||||
|
$ arch_name_exe = arch_name+ "_64"
|
||||||
|
$ else
|
||||||
|
$ arch_name_exe = arch_name
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$! Derive the OpenSSL installation device:[directory] from the location
|
||||||
|
$! of this command procedure.
|
||||||
|
$!
|
||||||
|
$ proc = f$environment( "procedure")
|
||||||
|
$ proc_dev_dir = f$parse( "A.;", proc, , , "no_conceal") - "A.;"
|
||||||
|
$ proc_dev = f$parse( proc_dev_dir, , , "device", "syntax_only")
|
||||||
|
$ proc_dir = f$parse( proc_dev_dir, , , "directory", "syntax_only") - -
|
||||||
|
".][000000"- "[000000."- "]["- "["- "]"
|
||||||
|
$ proc_dev_dir = proc_dev+ "["+ proc_dir+ "]"
|
||||||
|
$ set default 'proc_dev_dir'
|
||||||
|
$ set default [-]
|
||||||
|
$ ossl_dev_dir = f$environment( "default")
|
||||||
|
$!
|
||||||
|
$! Check existence of expected directories (to see if this procedure has
|
||||||
|
$! been moved away from its proper place).
|
||||||
|
$!
|
||||||
|
$ if ((f$search( "certs.dir;1") .eqs. "") .or. -
|
||||||
|
(f$search( "include.dir;1") .eqs. "") .or. -
|
||||||
|
(f$search( "private.dir;1") .eqs. "") .or. -
|
||||||
|
(f$search( "vms.dir;1") .eqs. ""))
|
||||||
|
$ then
|
||||||
|
$ write sys$output -
|
||||||
|
" Can't find expected common OpenSSL directories in:"
|
||||||
|
$ write sys$output " ''ossl_dev_dir'"
|
||||||
|
$ status = rms_e_fnf
|
||||||
|
$ goto clean_up
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ if ((f$search( "''arch_name_exe'_exe.dir;1") .eqs. "") .or. -
|
||||||
|
(f$search( "''arch_name'_lib.dir;1") .eqs. ""))
|
||||||
|
$ then
|
||||||
|
$ write sys$output -
|
||||||
|
" Can't find expected architecture-specific OpenSSL directories in:"
|
||||||
|
$ write sys$output " ''ossl_dev_dir'"
|
||||||
|
$ status = rms_e_fnf
|
||||||
|
$ goto clean_up
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$! All seems well (enough). Define the OpenSSL logical names.
|
||||||
|
$!
|
||||||
|
$ ossl_root = ossl_dev_dir- "]"+ ".]"
|
||||||
|
$ define /translation_attributes = concealed /nolog'p1 SSLROOT 'ossl_root'
|
||||||
|
$ define /nolog 'p1' SSLCERTS sslroot:[certs]
|
||||||
|
$ define /nolog 'p1' SSLINCLUDE sslroot:[include]
|
||||||
|
$ define /nolog 'p1' SSLPRIVATE sslroot:[private]
|
||||||
|
$ define /nolog 'p1' SSLEXE sslroot:['arch_name_exe'_exe]
|
||||||
|
$ define /nolog 'p1' SSLLIB sslroot:['arch_name'_lib]
|
||||||
|
$!
|
||||||
|
$! Defining OPENSSL lets a C program use "#include <openssl/{foo}.h>":
|
||||||
|
$ define /nolog 'p1' OPENSSL SSLINCLUDE:
|
||||||
|
$!
|
||||||
|
$! Run a site-specific procedure, if it exists.
|
||||||
|
$!
|
||||||
|
$ if f$search( "sslroot:[vms]openssl_systartup.com") .nes."" then -
|
||||||
|
@ sslroot:[vms]openssl_systartup.com
|
||||||
|
$!
|
||||||
|
$! Restore the original default dev:[dir] (if known).
|
||||||
|
$!
|
||||||
|
$ clean_up:
|
||||||
|
$!
|
||||||
|
$ if (f$type( orig_dev_dir) .nes. "")
|
||||||
|
$ then
|
||||||
|
$ set default 'orig_dev_dir'
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ EXIT 'status'
|
||||||
|
$!
|
||||||
20
VMS/openssl_undo.com
Executable file
20
VMS/openssl_undo.com
Executable file
@@ -0,0 +1,20 @@
|
|||||||
|
$!
|
||||||
|
$! Deassign OpenSSL logical names.
|
||||||
|
$!
|
||||||
|
$ call deass "OPENSSL" "''p1'"
|
||||||
|
$ call deass "SSLCERTS" "''p1'"
|
||||||
|
$ call deass "SSLEXE" "''p1'"
|
||||||
|
$ call deass "SSLINCLUDE" "''p1'"
|
||||||
|
$ call deass "SSLLIB" "''p1'"
|
||||||
|
$ call deass "SSLPRIVATE" "''p1'"
|
||||||
|
$ call deass "SSLROOT" "''p1'"
|
||||||
|
$!
|
||||||
|
$ exit
|
||||||
|
$!
|
||||||
|
$deass: subroutine
|
||||||
|
$ if (f$trnlnm( p1) .nes. "")
|
||||||
|
$ then
|
||||||
|
$ deassign 'p2' 'p1'
|
||||||
|
$ endif
|
||||||
|
$ endsubroutine
|
||||||
|
$!
|
||||||
@@ -8,31 +8,39 @@ $!
|
|||||||
$!
|
$!
|
||||||
$! Slightly modified by Richard Levitte <richard@levitte.org>
|
$! Slightly modified by Richard Levitte <richard@levitte.org>
|
||||||
$!
|
$!
|
||||||
|
$!
|
||||||
|
$! Always define OPENSSL. Others are optional (non-null P1).
|
||||||
|
$!
|
||||||
$ OPENSSL :== $SSLEXE:OPENSSL
|
$ OPENSSL :== $SSLEXE:OPENSSL
|
||||||
$ VERIFY :== $SSLEXE:OPENSSL VERIFY
|
$
|
||||||
$ ASN1PARSE:== $SSLEXE:OPENSSL ASN1PARS
|
$ IF (P1 .NES. "")
|
||||||
$ REQ :== $SSLEXE:OPENSSL REQ
|
$ THEN
|
||||||
$ DGST :== $SSLEXE:OPENSSL DGST
|
$ VERIFY :== $SSLEXE:OPENSSL VERIFY
|
||||||
$ DH :== $SSLEXE:OPENSSL DH
|
$ ASN1PARSE:== $SSLEXE:OPENSSL ASN1PARS
|
||||||
$ ENC :== $SSLEXE:OPENSSL ENC
|
$! REQ could conflict with REQUEST.
|
||||||
$ GENDH :== $SSLEXE:OPENSSL GENDH
|
$ OREQ :== $SSLEXE:OPENSSL REQ
|
||||||
$ ERRSTR :== $SSLEXE:OPENSSL ERRSTR
|
$ DGST :== $SSLEXE:OPENSSL DGST
|
||||||
$ CA :== $SSLEXE:OPENSSL CA
|
$ DH :== $SSLEXE:OPENSSL DH
|
||||||
$ CRL :== $SSLEXE:OPENSSL CRL
|
$ ENC :== $SSLEXE:OPENSSL ENC
|
||||||
$ RSA :== $SSLEXE:OPENSSL RSA
|
$ GENDH :== $SSLEXE:OPENSSL GENDH
|
||||||
$ DSA :== $SSLEXE:OPENSSL DSA
|
$ ERRSTR :== $SSLEXE:OPENSSL ERRSTR
|
||||||
$ DSAPARAM :== $SSLEXE:OPENSSL DSAPARAM
|
$ CA :== $SSLEXE:OPENSSL CA
|
||||||
$ X509 :== $SSLEXE:OPENSSL X509
|
$ CRL :== $SSLEXE:OPENSSL CRL
|
||||||
$ GENRSA :== $SSLEXE:OPENSSL GENRSA
|
$ RSA :== $SSLEXE:OPENSSL RSA
|
||||||
$ GENDSA :== $SSLEXE:OPENSSL GENDSA
|
$ DSA :== $SSLEXE:OPENSSL DSA
|
||||||
$ S_SERVER :== $SSLEXE:OPENSSL S_SERVER
|
$ DSAPARAM :== $SSLEXE:OPENSSL DSAPARAM
|
||||||
$ S_CLIENT :== $SSLEXE:OPENSSL S_CLIENT
|
$ X509 :== $SSLEXE:OPENSSL X509
|
||||||
$ SPEED :== $SSLEXE:OPENSSL SPEED
|
$ GENRSA :== $SSLEXE:OPENSSL GENRSA
|
||||||
$ S_TIME :== $SSLEXE:OPENSSL S_TIME
|
$ GENDSA :== $SSLEXE:OPENSSL GENDSA
|
||||||
$ VERSION :== $SSLEXE:OPENSSL VERSION
|
$ S_SERVER :== $SSLEXE:OPENSSL S_SERVER
|
||||||
$ PKCS7 :== $SSLEXE:OPENSSL PKCS7
|
$ S_CLIENT :== $SSLEXE:OPENSSL S_CLIENT
|
||||||
$ CRL2PKCS7:== $SSLEXE:OPENSSL CRL2P7
|
$ SPEED :== $SSLEXE:OPENSSL SPEED
|
||||||
$ SESS_ID :== $SSLEXE:OPENSSL SESS_ID
|
$ S_TIME :== $SSLEXE:OPENSSL S_TIME
|
||||||
$ CIPHERS :== $SSLEXE:OPENSSL CIPHERS
|
$ VERSION :== $SSLEXE:OPENSSL VERSION
|
||||||
$ NSEQ :== $SSLEXE:OPENSSL NSEQ
|
$ PKCS7 :== $SSLEXE:OPENSSL PKCS7
|
||||||
$ PKCS12 :== $SSLEXE:OPENSSL PKCS12
|
$ CRL2PKCS7:== $SSLEXE:OPENSSL CRL2P7
|
||||||
|
$ SESS_ID :== $SSLEXE:OPENSSL SESS_ID
|
||||||
|
$ CIPHERS :== $SSLEXE:OPENSSL CIPHERS
|
||||||
|
$ NSEQ :== $SSLEXE:OPENSSL NSEQ
|
||||||
|
$ PKCS12 :== $SSLEXE:OPENSSL PKCS12
|
||||||
|
$ ENDIF
|
||||||
|
|||||||
100
apps/CA.com
100
apps/CA.com
@@ -37,14 +37,25 @@ $ VERIFY = openssl + " verify"
|
|||||||
$ X509 = openssl + " x509"
|
$ X509 = openssl + " x509"
|
||||||
$ PKCS12 = openssl + " pkcs12"
|
$ PKCS12 = openssl + " pkcs12"
|
||||||
$ echo = "write sys$Output"
|
$ echo = "write sys$Output"
|
||||||
|
$ RET = 1
|
||||||
$!
|
$!
|
||||||
$ s = F$PARSE(F$ENVIRONMENT("DEFAULT"),"[]") - "].;"
|
$! 2010-12-20 SMS.
|
||||||
$ CATOP := 's'.demoCA
|
$! Use a concealed logical name to reduce command line lengths, to
|
||||||
$ CAKEY := ]cakey.pem
|
$! avoid DCL errors on VAX:
|
||||||
$ CACERT := ]cacert.pem
|
$! %DCL-W-TKNOVF, command element is too long - shorten
|
||||||
|
$! (Path segments like "openssl-1_0_1-stable-SNAP-20101217" accumulate
|
||||||
|
$! quickly.)
|
||||||
|
$!
|
||||||
|
$ CATOP = F$PARSE( F$ENVIRONMENT( "DEFAULT"), "[]")- "].;"+ ".demoCA.]"
|
||||||
|
$ define /translation_attributes = concealed CATOP 'CATOP'
|
||||||
|
$!
|
||||||
|
$ on error then goto clean_up
|
||||||
|
$ on control_y then goto clean_up
|
||||||
|
$!
|
||||||
|
$ CAKEY = "CATOP:[private]cakey.pem"
|
||||||
|
$ CACERT = "CATOP:[000000]cacert.pem"
|
||||||
$
|
$
|
||||||
$ __INPUT := SYS$COMMAND
|
$ __INPUT := SYS$COMMAND
|
||||||
$ RET = 1
|
|
||||||
$!
|
$!
|
||||||
$ i = 1
|
$ i = 1
|
||||||
$opt_loop:
|
$opt_loop:
|
||||||
@@ -55,7 +66,7 @@ $
|
|||||||
$ IF (prog_opt .EQS. "?" .OR. prog_opt .EQS. "-h" .OR. prog_opt .EQS. "-help")
|
$ IF (prog_opt .EQS. "?" .OR. prog_opt .EQS. "-h" .OR. prog_opt .EQS. "-help")
|
||||||
$ THEN
|
$ THEN
|
||||||
$ echo "usage: CA -newcert|-newreq|-newca|-sign|-verify"
|
$ echo "usage: CA -newcert|-newreq|-newca|-sign|-verify"
|
||||||
$ exit
|
$ goto clean_up
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
$ IF (prog_opt .EQS. "-input")
|
$ IF (prog_opt .EQS. "-input")
|
||||||
@@ -69,7 +80,7 @@ $!
|
|||||||
$ IF (prog_opt .EQS. "-newcert")
|
$ IF (prog_opt .EQS. "-newcert")
|
||||||
$ THEN
|
$ THEN
|
||||||
$ ! Create a certificate.
|
$ ! Create a certificate.
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ REQ -new -x509 -keyout newreq.pem -out newreq.pem 'DAYS'
|
$ REQ -new -x509 -keyout newreq.pem -out newreq.pem 'DAYS'
|
||||||
$ RET=$STATUS
|
$ RET=$STATUS
|
||||||
$ echo "Certificate (and private key) is in newreq.pem"
|
$ echo "Certificate (and private key) is in newreq.pem"
|
||||||
@@ -79,7 +90,7 @@ $!
|
|||||||
$ IF (prog_opt .EQS. "-newreq")
|
$ IF (prog_opt .EQS. "-newreq")
|
||||||
$ THEN
|
$ THEN
|
||||||
$ ! Create a certificate request
|
$ ! Create a certificate request
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ REQ -new -keyout newreq.pem -out newreq.pem 'DAYS'
|
$ REQ -new -keyout newreq.pem -out newreq.pem 'DAYS'
|
||||||
$ RET=$STATUS
|
$ RET=$STATUS
|
||||||
$ echo "Request (and private key) is in newreq.pem"
|
$ echo "Request (and private key) is in newreq.pem"
|
||||||
@@ -90,41 +101,40 @@ $ IF (prog_opt .EQS. "-newca")
|
|||||||
$ THEN
|
$ THEN
|
||||||
$ ! If explicitly asked for or it doesn't exist then setup the directory
|
$ ! If explicitly asked for or it doesn't exist then setup the directory
|
||||||
$ ! structure that Eric likes to manage things.
|
$ ! structure that Eric likes to manage things.
|
||||||
$ IF F$SEARCH(CATOP+"]serial.") .EQS. ""
|
$ IF F$SEARCH( "CATOP:[000000]serial.") .EQS. ""
|
||||||
$ THEN
|
$ THEN
|
||||||
$ CREATE /DIR /PROTECTION=OWNER:RWED 'CATOP']
|
$ CREATE /DIRECTORY /PROTECTION=OWNER:RWED CATOP:[000000]
|
||||||
$ CREATE /DIR /PROTECTION=OWNER:RWED 'CATOP'.certs]
|
$ CREATE /DIRECTORY /PROTECTION=OWNER:RWED CATOP:[certs]
|
||||||
$ CREATE /DIR /PROTECTION=OWNER:RWED 'CATOP'.crl]
|
$ CREATE /DIRECTORY /PROTECTION=OWNER:RWED CATOP:[crl]
|
||||||
$ CREATE /DIR /PROTECTION=OWNER:RWED 'CATOP'.newcerts]
|
$ CREATE /DIRECTORY /PROTECTION=OWNER:RWED CATOP:[newcerts]
|
||||||
$ CREATE /DIR /PROTECTION=OWNER:RWED 'CATOP'.private]
|
$ CREATE /DIRECTORY /PROTECTION=OWNER:RWED CATOP:[private]
|
||||||
$
|
$
|
||||||
$ OPEN /WRITE ser_file 'CATOP']serial.
|
$ OPEN /WRITE ser_file CATOP:[000000]serial.
|
||||||
$ WRITE ser_file "01"
|
$ WRITE ser_file "01"
|
||||||
$ CLOSE ser_file
|
$ CLOSE ser_file
|
||||||
$ APPEND/NEW NL: 'CATOP']index.txt
|
$ APPEND /NEW_VERSION NL: CATOP:[000000]index.txt
|
||||||
$
|
$
|
||||||
$ ! The following is to make sure access() doesn't get confused. It
|
$ ! The following is to make sure access() doesn't get confused. It
|
||||||
$ ! really needs one file in the directory to give correct answers...
|
$ ! really needs one file in the directory to give correct answers...
|
||||||
$ COPY NLA0: 'CATOP'.certs].;
|
$ COPY NLA0: CATOP:[certs].;
|
||||||
$ COPY NLA0: 'CATOP'.crl].;
|
$ COPY NLA0: CATOP:[crl].;
|
||||||
$ COPY NLA0: 'CATOP'.newcerts].;
|
$ COPY NLA0: CATOP:[newcerts].;
|
||||||
$ COPY NLA0: 'CATOP'.private].;
|
$ COPY NLA0: CATOP:[private].;
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
$ IF F$SEARCH(CATOP+".private"+CAKEY) .EQS. ""
|
$ IF F$SEARCH( CAKEY) .EQS. ""
|
||||||
$ THEN
|
$ THEN
|
||||||
$ READ '__INPUT' FILE -
|
$ READ '__INPUT' FILE -
|
||||||
/PROMT="CA certificate filename (or enter to create)"
|
/PROMPT="CA certificate filename (or enter to create): "
|
||||||
$ IF F$SEARCH(FILE) .NES. ""
|
$ IF (FILE .NES. "") .AND. (F$SEARCH(FILE) .NES. "")
|
||||||
$ THEN
|
$ THEN
|
||||||
$ COPY 'FILE' 'CATOP'.private'CAKEY'
|
$ COPY 'FILE' 'CAKEY'
|
||||||
$ RET=$STATUS
|
$ RET=$STATUS
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$ echo "Making CA certificate ..."
|
$ echo "Making CA certificate ..."
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ REQ -new -x509 -keyout 'CATOP'.private'CAKEY' -
|
$ REQ -new -x509 -keyout 'CAKEY' -out 'CACERT' 'DAYS'
|
||||||
-out 'CATOP''CACERT' 'DAYS'
|
$ RET=$STATUS
|
||||||
$ RET=$STATUS
|
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$ GOTO opt_loop_continue
|
$ GOTO opt_loop_continue
|
||||||
@@ -135,16 +145,16 @@ $ THEN
|
|||||||
$ i = i + 1
|
$ i = i + 1
|
||||||
$ cname = P'i'
|
$ cname = P'i'
|
||||||
$ IF cname .EQS. "" THEN cname = "My certificate"
|
$ IF cname .EQS. "" THEN cname = "My certificate"
|
||||||
$ PKCS12 -in newcert.pem -inkey newreq.pem -certfile 'CATOP''CACERT -
|
$ PKCS12 -in newcert.pem -inkey newreq.pem -certfile 'CACERT' -
|
||||||
-out newcert.p12 -export -name "''cname'"
|
-out newcert.p12 -export -name "''cname'"
|
||||||
$ RET=$STATUS
|
$ RET=$STATUS
|
||||||
$ exit RET
|
$ goto clean_up
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
$ IF (prog_opt .EQS. "-xsign")
|
$ IF (prog_opt .EQS. "-xsign")
|
||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ CA -policy policy_anything -infiles newreq.pem
|
$ CA -policy policy_anything -infiles newreq.pem
|
||||||
$ RET=$STATUS
|
$ RET=$STATUS
|
||||||
$ GOTO opt_loop_continue
|
$ GOTO opt_loop_continue
|
||||||
@@ -153,7 +163,7 @@ $!
|
|||||||
$ IF ((prog_opt .EQS. "-sign") .OR. (prog_opt .EQS. "-signreq"))
|
$ IF ((prog_opt .EQS. "-sign") .OR. (prog_opt .EQS. "-signreq"))
|
||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ CA -policy policy_anything -out newcert.pem -infiles newreq.pem
|
$ CA -policy policy_anything -out newcert.pem -infiles newreq.pem
|
||||||
$ RET=$STATUS
|
$ RET=$STATUS
|
||||||
$ type newcert.pem
|
$ type newcert.pem
|
||||||
@@ -165,9 +175,9 @@ $ IF (prog_opt .EQS. "-signcert")
|
|||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$ echo "Cert passphrase will be requested twice - bug?"
|
$ echo "Cert passphrase will be requested twice - bug?"
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ X509 -x509toreq -in newreq.pem -signkey newreq.pem -out tmp.pem
|
$ X509 -x509toreq -in newreq.pem -signkey newreq.pem -out tmp.pem
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ CA -policy policy_anything -out newcert.pem -infiles tmp.pem
|
$ CA -policy policy_anything -out newcert.pem -infiles tmp.pem
|
||||||
y
|
y
|
||||||
y
|
y
|
||||||
@@ -182,17 +192,17 @@ $!
|
|||||||
$ i = i + 1
|
$ i = i + 1
|
||||||
$ IF (p'i' .EQS. "")
|
$ IF (p'i' .EQS. "")
|
||||||
$ THEN
|
$ THEN
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ VERIFY "-CAfile" 'CATOP''CACERT' newcert.pem
|
$ VERIFY "-CAfile" 'CACERT' newcert.pem
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$ j = i
|
$ j = i
|
||||||
$ verify_opt_loop:
|
$ verify_opt_loop:
|
||||||
$ IF j .GT. 8 THEN GOTO verify_opt_loop_end
|
$ IF j .GT. 8 THEN GOTO verify_opt_loop_end
|
||||||
$ IF p'j' .NES. ""
|
$ IF p'j' .NES. ""
|
||||||
$ THEN
|
$ THEN
|
||||||
$ DEFINE/USER SYS$INPUT '__INPUT'
|
$ DEFINE /USER_MODE SYS$INPUT '__INPUT'
|
||||||
$ __tmp = p'j'
|
$ __tmp = p'j'
|
||||||
$ VERIFY "-CAfile" 'CATOP''CACERT' '__tmp'
|
$ VERIFY "-CAfile" 'CACERT' '__tmp'
|
||||||
$ tmp=$STATUS
|
$ tmp=$STATUS
|
||||||
$ IF tmp .NE. 0 THEN RET=tmp
|
$ IF tmp .NE. 0 THEN RET=tmp
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
@@ -208,8 +218,8 @@ $ IF (prog_opt .NES. "")
|
|||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$ echo "Unknown argument ''prog_opt'"
|
$ echo "Unknown argument ''prog_opt'"
|
||||||
$
|
$ RET = 3
|
||||||
$ EXIT 3
|
$ goto clean_up
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$
|
$
|
||||||
$opt_loop_continue:
|
$opt_loop_continue:
|
||||||
@@ -217,4 +227,10 @@ $ i = i + 1
|
|||||||
$ GOTO opt_loop
|
$ GOTO opt_loop
|
||||||
$
|
$
|
||||||
$opt_loop_end:
|
$opt_loop_end:
|
||||||
|
$!
|
||||||
|
$clean_up:
|
||||||
|
$!
|
||||||
|
$ if f$trnlnm( "CATOP", "LNM$PROCESS") .nes. "" then -
|
||||||
|
deassign /process CATOP
|
||||||
|
$!
|
||||||
$ EXIT 'RET'
|
$ EXIT 'RET'
|
||||||
|
|||||||
97
apps/CA.sh
97
apps/CA.sh
@@ -16,8 +16,8 @@
|
|||||||
# 12-Jan-96 tjh Added more things ... including CA -signcert which
|
# 12-Jan-96 tjh Added more things ... including CA -signcert which
|
||||||
# converts a certificate to a request and then signs it.
|
# converts a certificate to a request and then signs it.
|
||||||
# 10-Jan-96 eay Fixed a few more bugs and added the SSLEAY_CONFIG
|
# 10-Jan-96 eay Fixed a few more bugs and added the SSLEAY_CONFIG
|
||||||
# environment variable so this can be driven from
|
# environment variable so this can be driven from
|
||||||
# a script.
|
# a script.
|
||||||
# 25-Jul-96 eay Cleaned up filenames some more.
|
# 25-Jul-96 eay Cleaned up filenames some more.
|
||||||
# 11-Jun-96 eay Fixed a few filename missmatches.
|
# 11-Jun-96 eay Fixed a few filename missmatches.
|
||||||
# 03-May-96 eay Modified to use 'ssleay cmd' instead of 'cmd'.
|
# 03-May-96 eay Modified to use 'ssleay cmd' instead of 'cmd'.
|
||||||
@@ -29,26 +29,56 @@
|
|||||||
|
|
||||||
# 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
|
||||||
|
cp_pem() {
|
||||||
|
infile=$1
|
||||||
|
outfile=$2
|
||||||
|
bound=$3
|
||||||
|
flag=0
|
||||||
|
exec <$infile;
|
||||||
|
while read line; do
|
||||||
|
if [ $flag -eq 1 ]; then
|
||||||
|
echo $line|grep "^-----END.*$bound" 2>/dev/null 1>/dev/null
|
||||||
|
if [ $? -eq 0 ] ; then
|
||||||
|
echo $line >>$outfile
|
||||||
|
break
|
||||||
|
else
|
||||||
|
echo $line >>$outfile
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo $line|grep "^-----BEGIN.*$bound" 2>/dev/null 1>/dev/null
|
||||||
|
if [ $? -eq 0 ]; then
|
||||||
|
echo $line >$outfile
|
||||||
|
flag=1
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
usage() {
|
||||||
|
echo "usage: $0 -newcert|-newreq|-newreq-nodes|-newca|-sign|-verify" >&2
|
||||||
|
}
|
||||||
|
|
||||||
if [ -z "$OPENSSL" ]; then OPENSSL=openssl; fi
|
if [ -z "$OPENSSL" ]; then OPENSSL=openssl; fi
|
||||||
|
|
||||||
DAYS="-days 365" # 1 year
|
if [ -z "$DAYS" ] ; then DAYS="-days 365" ; fi # 1 year
|
||||||
CADAYS="-days 1095" # 3 years
|
CADAYS="-days 1095" # 3 years
|
||||||
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"
|
||||||
|
|
||||||
CATOP=./demoCA
|
if [ -z "$CATOP" ] ; then CATOP=./demoCA ; fi
|
||||||
CAKEY=./cakey.pem
|
CAKEY=./cakey.pem
|
||||||
CAREQ=./careq.pem
|
CAREQ=./careq.pem
|
||||||
CACERT=./cacert.pem
|
CACERT=./cacert.pem
|
||||||
|
|
||||||
for i
|
RET=0
|
||||||
do
|
|
||||||
case $i in
|
while [ "$1" != "" ] ; do
|
||||||
|
case $1 in
|
||||||
-\?|-h|-help)
|
-\?|-h|-help)
|
||||||
echo "usage: CA -newcert|-newreq|-newca|-sign|-verify" >&2
|
usage
|
||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
-newcert)
|
-newcert)
|
||||||
@@ -63,18 +93,23 @@ case $i in
|
|||||||
RET=$?
|
RET=$?
|
||||||
echo "Request is in newreq.pem, private key is in newkey.pem"
|
echo "Request is in newreq.pem, private key is in newkey.pem"
|
||||||
;;
|
;;
|
||||||
|
-newreq-nodes)
|
||||||
|
# create a certificate request
|
||||||
|
$REQ -new -nodes -keyout newreq.pem -out newreq.pem $DAYS
|
||||||
|
RET=$?
|
||||||
|
echo "Request (and private key) is in newreq.pem"
|
||||||
|
;;
|
||||||
-newca)
|
-newca)
|
||||||
# if explicitly asked for or it doesn't exist then setup the directory
|
# if explicitly asked for or it doesn't exist then setup the directory
|
||||||
# structure that Eric likes to manage things
|
# structure that Eric likes to manage things
|
||||||
NEW="1"
|
NEW="1"
|
||||||
if [ "$NEW" -o ! -f ${CATOP}/serial ]; then
|
if [ "$NEW" -o ! -f ${CATOP}/serial ]; then
|
||||||
# create the directory hierarchy
|
# create the directory hierarchy
|
||||||
mkdir ${CATOP}
|
mkdir -p ${CATOP}
|
||||||
mkdir ${CATOP}/certs
|
mkdir -p ${CATOP}/certs
|
||||||
mkdir ${CATOP}/crl
|
mkdir -p ${CATOP}/crl
|
||||||
mkdir ${CATOP}/newcerts
|
mkdir -p ${CATOP}/newcerts
|
||||||
mkdir ${CATOP}/private
|
mkdir -p ${CATOP}/private
|
||||||
echo "00" > ${CATOP}/serial
|
|
||||||
touch ${CATOP}/index.txt
|
touch ${CATOP}/index.txt
|
||||||
fi
|
fi
|
||||||
if [ ! -f ${CATOP}/private/$CAKEY ]; then
|
if [ ! -f ${CATOP}/private/$CAKEY ]; then
|
||||||
@@ -83,14 +118,20 @@ case $i in
|
|||||||
|
|
||||||
# ask user for existing CA certificate
|
# ask user for existing CA certificate
|
||||||
if [ "$FILE" ]; then
|
if [ "$FILE" ]; then
|
||||||
cp $FILE ${CATOP}/private/$CAKEY
|
cp_pem $FILE ${CATOP}/private/$CAKEY PRIVATE
|
||||||
|
cp_pem $FILE ${CATOP}/$CACERT CERTIFICATE
|
||||||
RET=$?
|
RET=$?
|
||||||
|
if [ ! -f "${CATOP}/serial" ]; then
|
||||||
|
$X509 -in ${CATOP}/$CACERT -noout -next_serial \
|
||||||
|
-out ${CATOP}/serial
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
echo "Making CA certificate ..."
|
echo "Making CA certificate ..."
|
||||||
$REQ -new -keyout ${CATOP}/private/$CAKEY \
|
$REQ -new -keyout ${CATOP}/private/$CAKEY \
|
||||||
-out ${CATOP}/$CAREQ
|
-out ${CATOP}/$CAREQ
|
||||||
$CA -out ${CATOP}/$CACERT $CADAYS -batch \
|
$CA -create_serial -out ${CATOP}/$CACERT $CADAYS -batch \
|
||||||
-keyfile ${CATOP}/private/$CAKEY -selfsign \
|
-keyfile ${CATOP}/private/$CAKEY -selfsign \
|
||||||
|
-extensions v3_ca \
|
||||||
-infiles ${CATOP}/$CAREQ
|
-infiles ${CATOP}/$CAREQ
|
||||||
RET=$?
|
RET=$?
|
||||||
fi
|
fi
|
||||||
@@ -100,16 +141,33 @@ case $i in
|
|||||||
$CA -policy policy_anything -infiles newreq.pem
|
$CA -policy policy_anything -infiles newreq.pem
|
||||||
RET=$?
|
RET=$?
|
||||||
;;
|
;;
|
||||||
|
-pkcs12)
|
||||||
|
if [ -z "$2" ] ; then
|
||||||
|
CNAME="My Certificate"
|
||||||
|
else
|
||||||
|
CNAME="$2"
|
||||||
|
fi
|
||||||
|
$PKCS12 -in newcert.pem -inkey newreq.pem -certfile ${CATOP}/$CACERT \
|
||||||
|
-out newcert.p12 -export -name "$CNAME"
|
||||||
|
RET=$?
|
||||||
|
exit $RET
|
||||||
|
;;
|
||||||
-sign|-signreq)
|
-sign|-signreq)
|
||||||
$CA -policy policy_anything -out newcert.pem -infiles newreq.pem
|
$CA -policy policy_anything -out newcert.pem -infiles newreq.pem
|
||||||
RET=$?
|
RET=$?
|
||||||
cat newcert.pem
|
cat newcert.pem
|
||||||
echo "Signed certificate is in newcert.pem"
|
echo "Signed certificate is in newcert.pem"
|
||||||
;;
|
;;
|
||||||
|
-signCA)
|
||||||
|
$CA -policy policy_anything -out newcert.pem -extensions v3_ca -infiles newreq.pem
|
||||||
|
RET=$?
|
||||||
|
echo "Signed CA certificate is in newcert.pem"
|
||||||
|
;;
|
||||||
-signcert)
|
-signcert)
|
||||||
echo "Cert passphrase will be requested twice - bug?"
|
echo "Cert passphrase will be requested twice - bug?"
|
||||||
$X509 -x509toreq -in newreq.pem -signkey newreq.pem -out tmp.pem
|
$X509 -x509toreq -in newreq.pem -signkey newreq.pem -out tmp.pem
|
||||||
$CA -policy policy_anything -out newcert.pem -infiles tmp.pem
|
$CA -policy policy_anything -out newcert.pem -infiles tmp.pem
|
||||||
|
RET=$?
|
||||||
cat newcert.pem
|
cat newcert.pem
|
||||||
echo "Signed certificate is in newcert.pem"
|
echo "Signed certificate is in newcert.pem"
|
||||||
;;
|
;;
|
||||||
@@ -127,13 +185,14 @@ case $i in
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
exit 0
|
exit $RET
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Unknown arg $i";
|
echo "Unknown arg $i" >&2
|
||||||
|
usage
|
||||||
exit 1
|
exit 1
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
shift
|
||||||
done
|
done
|
||||||
exit $RET
|
exit $RET
|
||||||
|
|
||||||
|
|||||||
199
apps/Makefile
199
apps/Makefile
@@ -39,7 +39,7 @@ E_EXE= verify asn1pars req dgst dh dhparam enc passwd gendh errstr \
|
|||||||
ca crl rsa rsautl dsa dsaparam ec ecparam \
|
ca crl rsa rsautl dsa dsaparam ec ecparam \
|
||||||
x509 genrsa gendsa genpkey s_server s_client speed \
|
x509 genrsa gendsa genpkey s_server s_client speed \
|
||||||
s_time version pkcs7 cms crl2pkcs7 sess_id ciphers nseq pkcs12 \
|
s_time version pkcs7 cms crl2pkcs7 sess_id ciphers nseq pkcs12 \
|
||||||
pkcs8 pkey pkeyparam pkeyutl spkac smime rand engine ocsp prime ts
|
pkcs8 pkey pkeyparam pkeyutl spkac smime rand engine ocsp prime ts srp
|
||||||
|
|
||||||
PROGS= $(PROGRAM).c
|
PROGS= $(PROGRAM).c
|
||||||
|
|
||||||
@@ -56,7 +56,7 @@ E_OBJ= verify.o asn1pars.o req.o dgst.o dh.o dhparam.o enc.o passwd.o gendh.o er
|
|||||||
x509.o genrsa.o gendsa.o genpkey.o s_server.o s_client.o speed.o \
|
x509.o genrsa.o gendsa.o genpkey.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 pkey.o pkeyparam.o pkeyutl.o \
|
ciphers.o nseq.o pkcs12.o pkcs8.o pkey.o pkeyparam.o pkeyutl.o \
|
||||||
spkac.o smime.o cms.o rand.o engine.o ocsp.o prime.o ts.o
|
spkac.o smime.o cms.o rand.o engine.o ocsp.o prime.o ts.o srp.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 \
|
||||||
@@ -64,7 +64,7 @@ E_SRC= verify.c asn1pars.c req.c dgst.c dh.c enc.c passwd.c gendh.c errstr.c ca.
|
|||||||
x509.c genrsa.c gendsa.c genpkey.c s_server.c s_client.c speed.c \
|
x509.c genrsa.c gendsa.c genpkey.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 pkey.c pkeyparam.c pkeyutl.c \
|
ciphers.c nseq.c pkcs12.c pkcs8.c pkey.c pkeyparam.c pkeyutl.c \
|
||||||
spkac.c smime.c cms.c rand.c engine.c ocsp.c prime.c ts.c
|
spkac.c smime.c cms.c rand.c engine.c ocsp.c prime.c ts.c srp.c
|
||||||
|
|
||||||
SRC=$(E_SRC)
|
SRC=$(E_SRC)
|
||||||
|
|
||||||
@@ -153,6 +153,8 @@ $(EXE): progs.h $(E_OBJ) $(PROGRAM).o $(DLIBCRYPTO) $(DLIBSSL)
|
|||||||
$(RM) $(EXE)
|
$(RM) $(EXE)
|
||||||
shlib_target=; if [ -n "$(SHARED_LIBS)" ]; then \
|
shlib_target=; if [ -n "$(SHARED_LIBS)" ]; then \
|
||||||
shlib_target="$(SHLIB_TARGET)"; \
|
shlib_target="$(SHLIB_TARGET)"; \
|
||||||
|
elif [ -n "$(FIPSCANLIB)" ]; then \
|
||||||
|
FIPSLD_CC="$(CC)"; CC=$(FIPSDIR)/bin/fipsld; export CC FIPSLD_CC; \
|
||||||
fi; \
|
fi; \
|
||||||
LIBRARIES="$(LIBSSL) $(LIBKRB5) $(LIBCRYPTO)" ; \
|
LIBRARIES="$(LIBSSL) $(LIBKRB5) $(LIBCRYPTO)" ; \
|
||||||
$(MAKE) -f $(TOP)/Makefile.shared -e \
|
$(MAKE) -f $(TOP)/Makefile.shared -e \
|
||||||
@@ -245,13 +247,13 @@ ciphers.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
|||||||
ciphers.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
ciphers.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
ciphers.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
ciphers.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
ciphers.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
ciphers.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
||||||
ciphers.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
ciphers.o: ../include/openssl/sha.h ../include/openssl/srtp.h
|
||||||
ciphers.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
ciphers.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
ciphers.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
ciphers.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
ciphers.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
ciphers.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
ciphers.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
ciphers.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
||||||
ciphers.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
ciphers.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
ciphers.o: ciphers.c
|
ciphers.o: ../include/openssl/x509v3.h apps.h ciphers.c
|
||||||
cms.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
cms.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
cms.o: ../include/openssl/buffer.h ../include/openssl/cms.h
|
cms.o: ../include/openssl/buffer.h ../include/openssl/cms.h
|
||||||
cms.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
cms.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
@@ -427,13 +429,13 @@ engine.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
|||||||
engine.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
engine.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
engine.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
engine.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
engine.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
engine.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
||||||
engine.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
engine.o: ../include/openssl/sha.h ../include/openssl/srtp.h
|
||||||
engine.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
engine.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
engine.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
engine.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
engine.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
engine.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
engine.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
engine.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
||||||
engine.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
engine.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
engine.o: engine.c
|
engine.o: ../include/openssl/x509v3.h apps.h engine.c
|
||||||
errstr.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
errstr.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
errstr.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
errstr.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
||||||
errstr.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
errstr.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
@@ -448,13 +450,13 @@ errstr.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
|||||||
errstr.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
errstr.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
errstr.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
errstr.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
errstr.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
errstr.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
||||||
errstr.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
errstr.o: ../include/openssl/sha.h ../include/openssl/srtp.h
|
||||||
errstr.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
errstr.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
errstr.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
errstr.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
errstr.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
errstr.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
errstr.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
errstr.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
||||||
errstr.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
errstr.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
errstr.o: errstr.c
|
errstr.o: ../include/openssl/x509v3.h apps.h errstr.c
|
||||||
gendh.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
gendh.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
gendh.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
gendh.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
gendh.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
gendh.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
@@ -556,12 +558,12 @@ ocsp.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
|||||||
ocsp.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
ocsp.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
||||||
ocsp.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
ocsp.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
||||||
ocsp.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
ocsp.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
||||||
ocsp.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
ocsp.o: ../include/openssl/srtp.h ../include/openssl/ssl.h
|
||||||
ocsp.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
ocsp.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
||||||
ocsp.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
ocsp.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
||||||
ocsp.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
ocsp.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
||||||
ocsp.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
ocsp.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
||||||
ocsp.o: ../include/openssl/x509v3.h apps.h ocsp.c
|
ocsp.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h ocsp.c
|
||||||
openssl.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
openssl.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
openssl.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
openssl.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
||||||
openssl.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
openssl.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
@@ -575,8 +577,9 @@ openssl.o: ../include/openssl/objects.h ../include/openssl/ocsp.h
|
|||||||
openssl.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
openssl.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
openssl.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
openssl.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
openssl.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
openssl.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
openssl.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
openssl.o: ../include/openssl/pqueue.h ../include/openssl/rand.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/srtp.h ../include/openssl/ssl.h
|
||||||
openssl.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
openssl.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
||||||
openssl.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
openssl.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
||||||
openssl.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
openssl.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
||||||
@@ -789,8 +792,9 @@ s_cb.o: ../include/openssl/objects.h ../include/openssl/ocsp.h
|
|||||||
s_cb.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
s_cb.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
s_cb.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
s_cb.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
s_cb.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
s_cb.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
s_cb.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
s_cb.o: ../include/openssl/pqueue.h ../include/openssl/rand.h
|
||||||
s_cb.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
s_cb.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
||||||
|
s_cb.o: ../include/openssl/srtp.h ../include/openssl/ssl.h
|
||||||
s_cb.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
s_cb.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
||||||
s_cb.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
s_cb.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
||||||
s_cb.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
s_cb.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
||||||
@@ -812,7 +816,8 @@ s_client.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
|||||||
s_client.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
s_client.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
||||||
s_client.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
s_client.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
||||||
s_client.o: ../include/openssl/rand.h ../include/openssl/safestack.h
|
s_client.o: ../include/openssl/rand.h ../include/openssl/safestack.h
|
||||||
s_client.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
s_client.o: ../include/openssl/sha.h ../include/openssl/srp.h
|
||||||
|
s_client.o: ../include/openssl/srtp.h ../include/openssl/ssl.h
|
||||||
s_client.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
s_client.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
||||||
s_client.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
s_client.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
||||||
s_client.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
s_client.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
||||||
@@ -836,6 +841,7 @@ s_server.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
|||||||
s_server.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
s_server.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
||||||
s_server.o: ../include/openssl/rand.h ../include/openssl/rsa.h
|
s_server.o: ../include/openssl/rand.h ../include/openssl/rsa.h
|
||||||
s_server.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
s_server.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
||||||
|
s_server.o: ../include/openssl/srp.h ../include/openssl/srtp.h
|
||||||
s_server.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
s_server.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
s_server.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
s_server.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
s_server.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
s_server.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
@@ -843,20 +849,21 @@ s_server.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
|||||||
s_server.o: ../include/openssl/ui.h ../include/openssl/x509.h
|
s_server.o: ../include/openssl/ui.h ../include/openssl/x509.h
|
||||||
s_server.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
s_server.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
||||||
s_server.o: s_apps.h s_server.c timeouts.h
|
s_server.o: s_apps.h s_server.c timeouts.h
|
||||||
s_socket.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
s_socket.o: ../e_os.h ../e_os2.h ../include/openssl/asn1.h
|
||||||
s_socket.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
s_socket.o: ../include/openssl/bio.h ../include/openssl/buffer.h
|
||||||
s_socket.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
s_socket.o: ../include/openssl/comp.h ../include/openssl/conf.h
|
||||||
s_socket.o: ../include/openssl/dtls1.h ../include/openssl/e_os2.h
|
s_socket.o: ../include/openssl/crypto.h ../include/openssl/dtls1.h
|
||||||
s_socket.o: ../include/openssl/ec.h ../include/openssl/ecdh.h
|
s_socket.o: ../include/openssl/e_os2.h ../include/openssl/ec.h
|
||||||
s_socket.o: ../include/openssl/ecdsa.h ../include/openssl/engine.h
|
s_socket.o: ../include/openssl/ecdh.h ../include/openssl/ecdsa.h
|
||||||
s_socket.o: ../include/openssl/evp.h ../include/openssl/hmac.h
|
s_socket.o: ../include/openssl/engine.h ../include/openssl/evp.h
|
||||||
s_socket.o: ../include/openssl/kssl.h ../include/openssl/lhash.h
|
s_socket.o: ../include/openssl/hmac.h ../include/openssl/kssl.h
|
||||||
s_socket.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
s_socket.o: ../include/openssl/lhash.h ../include/openssl/obj_mac.h
|
||||||
s_socket.o: ../include/openssl/ocsp.h ../include/openssl/opensslconf.h
|
s_socket.o: ../include/openssl/objects.h ../include/openssl/ocsp.h
|
||||||
s_socket.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
s_socket.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
s_socket.o: ../include/openssl/pem.h ../include/openssl/pem2.h
|
s_socket.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
s_socket.o: ../include/openssl/pkcs7.h ../include/openssl/pqueue.h
|
s_socket.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
s_socket.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
s_socket.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
||||||
|
s_socket.o: ../include/openssl/sha.h ../include/openssl/srtp.h
|
||||||
s_socket.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
s_socket.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
s_socket.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
s_socket.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
s_socket.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
s_socket.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
@@ -877,13 +884,13 @@ s_time.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
|||||||
s_time.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
s_time.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
s_time.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
s_time.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
s_time.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
s_time.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
||||||
s_time.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
s_time.o: ../include/openssl/sha.h ../include/openssl/srtp.h
|
||||||
s_time.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
s_time.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
s_time.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
s_time.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
s_time.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
s_time.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
s_time.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
s_time.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
||||||
s_time.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
s_time.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
s_time.o: s_apps.h s_time.c
|
s_time.o: ../include/openssl/x509v3.h apps.h s_apps.h s_time.c
|
||||||
sess_id.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
sess_id.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
sess_id.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
sess_id.o: ../include/openssl/buffer.h ../include/openssl/comp.h
|
||||||
sess_id.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
sess_id.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
@@ -898,13 +905,13 @@ sess_id.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
|||||||
sess_id.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
sess_id.o: ../include/openssl/ossl_typ.h ../include/openssl/pem.h
|
||||||
sess_id.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
sess_id.o: ../include/openssl/pem2.h ../include/openssl/pkcs7.h
|
||||||
sess_id.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
sess_id.o: ../include/openssl/pqueue.h ../include/openssl/safestack.h
|
||||||
sess_id.o: ../include/openssl/sha.h ../include/openssl/ssl.h
|
sess_id.o: ../include/openssl/sha.h ../include/openssl/srtp.h
|
||||||
sess_id.o: ../include/openssl/ssl2.h ../include/openssl/ssl23.h
|
sess_id.o: ../include/openssl/ssl.h ../include/openssl/ssl2.h
|
||||||
sess_id.o: ../include/openssl/ssl3.h ../include/openssl/stack.h
|
sess_id.o: ../include/openssl/ssl23.h ../include/openssl/ssl3.h
|
||||||
sess_id.o: ../include/openssl/symhacks.h ../include/openssl/tls1.h
|
sess_id.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
sess_id.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
sess_id.o: ../include/openssl/tls1.h ../include/openssl/txt_db.h
|
||||||
sess_id.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
sess_id.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
sess_id.o: sess_id.c
|
sess_id.o: ../include/openssl/x509v3.h apps.h sess_id.c
|
||||||
smime.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
smime.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
smime.o: ../include/openssl/buffer.h ../include/openssl/conf.h
|
smime.o: ../include/openssl/buffer.h ../include/openssl/conf.h
|
||||||
smime.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
smime.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
||||||
@@ -932,21 +939,21 @@ speed.o: ../include/openssl/ec.h ../include/openssl/ecdh.h
|
|||||||
speed.o: ../include/openssl/ecdsa.h ../include/openssl/engine.h
|
speed.o: ../include/openssl/ecdsa.h ../include/openssl/engine.h
|
||||||
speed.o: ../include/openssl/err.h ../include/openssl/evp.h
|
speed.o: ../include/openssl/err.h ../include/openssl/evp.h
|
||||||
speed.o: ../include/openssl/hmac.h ../include/openssl/idea.h
|
speed.o: ../include/openssl/hmac.h ../include/openssl/idea.h
|
||||||
speed.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
speed.o: ../include/openssl/lhash.h ../include/openssl/md4.h
|
||||||
speed.o: ../include/openssl/md4.h ../include/openssl/md5.h
|
speed.o: ../include/openssl/md5.h ../include/openssl/mdc2.h
|
||||||
speed.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
speed.o: ../include/openssl/modes.h ../include/openssl/obj_mac.h
|
||||||
speed.o: ../include/openssl/ocsp.h ../include/openssl/opensslconf.h
|
speed.o: ../include/openssl/objects.h ../include/openssl/ocsp.h
|
||||||
speed.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
speed.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
speed.o: ../include/openssl/pkcs7.h ../include/openssl/rand.h
|
speed.o: ../include/openssl/ossl_typ.h ../include/openssl/pkcs7.h
|
||||||
speed.o: ../include/openssl/rc2.h ../include/openssl/rc4.h
|
speed.o: ../include/openssl/rand.h ../include/openssl/rc2.h
|
||||||
speed.o: ../include/openssl/ripemd.h ../include/openssl/rsa.h
|
speed.o: ../include/openssl/rc4.h ../include/openssl/ripemd.h
|
||||||
speed.o: ../include/openssl/safestack.h ../include/openssl/seed.h
|
speed.o: ../include/openssl/rsa.h ../include/openssl/safestack.h
|
||||||
speed.o: ../include/openssl/sha.h ../include/openssl/stack.h
|
speed.o: ../include/openssl/seed.h ../include/openssl/sha.h
|
||||||
speed.o: ../include/openssl/symhacks.h ../include/openssl/txt_db.h
|
speed.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
speed.o: ../include/openssl/ui.h ../include/openssl/ui_compat.h
|
speed.o: ../include/openssl/txt_db.h ../include/openssl/ui.h
|
||||||
speed.o: ../include/openssl/whrlpool.h ../include/openssl/x509.h
|
speed.o: ../include/openssl/ui_compat.h ../include/openssl/whrlpool.h
|
||||||
speed.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
speed.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
speed.o: speed.c testdsa.h testrsa.h
|
speed.o: ../include/openssl/x509v3.h apps.h speed.c testdsa.h testrsa.h
|
||||||
spkac.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
spkac.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
spkac.o: ../include/openssl/buffer.h ../include/openssl/conf.h
|
spkac.o: ../include/openssl/buffer.h ../include/openssl/conf.h
|
||||||
spkac.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
spkac.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
||||||
@@ -963,6 +970,21 @@ spkac.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
|||||||
spkac.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
spkac.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
||||||
spkac.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
spkac.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
||||||
spkac.o: spkac.c
|
spkac.o: spkac.c
|
||||||
|
srp.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
|
srp.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
|
srp.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
|
srp.o: ../include/openssl/e_os2.h ../include/openssl/ec.h
|
||||||
|
srp.o: ../include/openssl/ecdh.h ../include/openssl/ecdsa.h
|
||||||
|
srp.o: ../include/openssl/engine.h ../include/openssl/err.h
|
||||||
|
srp.o: ../include/openssl/evp.h ../include/openssl/lhash.h
|
||||||
|
srp.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
||||||
|
srp.o: ../include/openssl/ocsp.h ../include/openssl/opensslconf.h
|
||||||
|
srp.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
||||||
|
srp.o: ../include/openssl/pkcs7.h ../include/openssl/safestack.h
|
||||||
|
srp.o: ../include/openssl/sha.h ../include/openssl/srp.h
|
||||||
|
srp.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
||||||
|
srp.o: ../include/openssl/txt_db.h ../include/openssl/x509.h
|
||||||
|
srp.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h srp.c
|
||||||
ts.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
ts.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
ts.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
ts.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
ts.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
ts.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
@@ -1005,17 +1027,16 @@ version.o: ../include/openssl/des_old.h ../include/openssl/e_os2.h
|
|||||||
version.o: ../include/openssl/ec.h ../include/openssl/ecdh.h
|
version.o: ../include/openssl/ec.h ../include/openssl/ecdh.h
|
||||||
version.o: ../include/openssl/ecdsa.h ../include/openssl/engine.h
|
version.o: ../include/openssl/ecdsa.h ../include/openssl/engine.h
|
||||||
version.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
version.o: ../include/openssl/evp.h ../include/openssl/idea.h
|
||||||
version.o: ../include/openssl/lhash.h ../include/openssl/md2.h
|
version.o: ../include/openssl/lhash.h ../include/openssl/obj_mac.h
|
||||||
version.o: ../include/openssl/obj_mac.h ../include/openssl/objects.h
|
version.o: ../include/openssl/objects.h ../include/openssl/ocsp.h
|
||||||
version.o: ../include/openssl/ocsp.h ../include/openssl/opensslconf.h
|
version.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
version.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
version.o: ../include/openssl/ossl_typ.h ../include/openssl/pkcs7.h
|
||||||
version.o: ../include/openssl/pkcs7.h ../include/openssl/rc4.h
|
version.o: ../include/openssl/rc4.h ../include/openssl/safestack.h
|
||||||
version.o: ../include/openssl/safestack.h ../include/openssl/sha.h
|
version.o: ../include/openssl/sha.h ../include/openssl/stack.h
|
||||||
version.o: ../include/openssl/stack.h ../include/openssl/symhacks.h
|
version.o: ../include/openssl/symhacks.h ../include/openssl/txt_db.h
|
||||||
version.o: ../include/openssl/txt_db.h ../include/openssl/ui.h
|
version.o: ../include/openssl/ui.h ../include/openssl/ui_compat.h
|
||||||
version.o: ../include/openssl/ui_compat.h ../include/openssl/x509.h
|
version.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h
|
||||||
version.o: ../include/openssl/x509_vfy.h ../include/openssl/x509v3.h apps.h
|
version.o: ../include/openssl/x509v3.h apps.h version.c
|
||||||
version.o: version.c
|
|
||||||
x509.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
x509.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h
|
||||||
x509.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
x509.o: ../include/openssl/bn.h ../include/openssl/buffer.h
|
||||||
x509.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
x509.o: ../include/openssl/conf.h ../include/openssl/crypto.h
|
||||||
|
|||||||
292
apps/apps.c
292
apps/apps.c
@@ -109,14 +109,16 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#if !defined(_POSIX_C_SOURCE) && defined(OPENSSL_SYS_VMS)
|
||||||
#define _POSIX_C_SOURCE 2 /* On VMS, you need to define this to get
|
#define _POSIX_C_SOURCE 2 /* On VMS, you need to define this to get
|
||||||
the declaration of fileno(). The value
|
the declaration of fileno(). The value
|
||||||
2 is to make sure no function defined
|
2 is to make sure no function defined
|
||||||
in POSIX-2 is left undefined. */
|
in POSIX-2 is left undefined. */
|
||||||
|
#endif
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#ifndef OPENSSL_SYSNAME_WIN32
|
#if !defined(OPENSSL_SYSNAME_WIN32) && !defined(NETWARE_CLIB)
|
||||||
#include <strings.h>
|
#include <strings.h>
|
||||||
#endif
|
#endif
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
@@ -255,17 +257,12 @@ int args_from_file(char *file, int *argc, char **argv[])
|
|||||||
|
|
||||||
int str2fmt(char *s)
|
int str2fmt(char *s)
|
||||||
{
|
{
|
||||||
|
if (s == NULL)
|
||||||
|
return FORMAT_UNDEF;
|
||||||
if ((*s == 'D') || (*s == 'd'))
|
if ((*s == 'D') || (*s == 'd'))
|
||||||
return(FORMAT_ASN1);
|
return(FORMAT_ASN1);
|
||||||
else if ((*s == 'T') || (*s == 't'))
|
else if ((*s == 'T') || (*s == 't'))
|
||||||
return(FORMAT_TEXT);
|
return(FORMAT_TEXT);
|
||||||
else if ((*s == 'P') || (*s == 'p'))
|
|
||||||
{
|
|
||||||
if (s[1] == 'V' || s[1] == 'v')
|
|
||||||
return FORMAT_PVK;
|
|
||||||
else
|
|
||||||
return(FORMAT_PEM);
|
|
||||||
}
|
|
||||||
else if ((*s == 'N') || (*s == 'n'))
|
else if ((*s == 'N') || (*s == 'n'))
|
||||||
return(FORMAT_NETSCAPE);
|
return(FORMAT_NETSCAPE);
|
||||||
else if ((*s == 'S') || (*s == 's'))
|
else if ((*s == 'S') || (*s == 's'))
|
||||||
@@ -278,6 +275,13 @@ int str2fmt(char *s)
|
|||||||
return(FORMAT_PKCS12);
|
return(FORMAT_PKCS12);
|
||||||
else if ((*s == 'E') || (*s == 'e'))
|
else if ((*s == 'E') || (*s == 'e'))
|
||||||
return(FORMAT_ENGINE);
|
return(FORMAT_ENGINE);
|
||||||
|
else if ((*s == 'P') || (*s == 'p'))
|
||||||
|
{
|
||||||
|
if (s[1] == 'V' || s[1] == 'v')
|
||||||
|
return FORMAT_PVK;
|
||||||
|
else
|
||||||
|
return(FORMAT_PEM);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
return(FORMAT_UNDEF);
|
return(FORMAT_UNDEF);
|
||||||
}
|
}
|
||||||
@@ -375,13 +379,12 @@ void program_name(char *in, char *out, int size)
|
|||||||
|
|
||||||
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,i;
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
*argc=0;
|
*argc=0;
|
||||||
*argv=NULL;
|
*argv=NULL;
|
||||||
|
|
||||||
len=strlen(buf);
|
|
||||||
i=0;
|
i=0;
|
||||||
if (arg->count == 0)
|
if (arg->count == 0)
|
||||||
{
|
{
|
||||||
@@ -795,7 +798,9 @@ X509 *load_cert(BIO *err, const char *file, int format,
|
|||||||
if (file == NULL)
|
if (file == NULL)
|
||||||
{
|
{
|
||||||
#ifdef _IONBF
|
#ifdef _IONBF
|
||||||
|
# ifndef OPENSSL_NO_SETVBUF_IONBF
|
||||||
setvbuf(stdin, NULL, _IONBF, 0);
|
setvbuf(stdin, NULL, _IONBF, 0);
|
||||||
|
# endif /* ndef OPENSSL_NO_SETVBUF_IONBF */
|
||||||
#endif
|
#endif
|
||||||
BIO_set_fp(cert,stdin,BIO_NOCLOSE);
|
BIO_set_fp(cert,stdin,BIO_NOCLOSE);
|
||||||
}
|
}
|
||||||
@@ -873,10 +878,17 @@ EVP_PKEY *load_key(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
if (format == FORMAT_ENGINE)
|
if (format == FORMAT_ENGINE)
|
||||||
{
|
{
|
||||||
if (!e)
|
if (!e)
|
||||||
BIO_printf(bio_err,"no engine specified\n");
|
BIO_printf(err,"no engine specified\n");
|
||||||
else
|
else
|
||||||
|
{
|
||||||
pkey = ENGINE_load_private_key(e, file,
|
pkey = ENGINE_load_private_key(e, file,
|
||||||
ui_method, &cb_data);
|
ui_method, &cb_data);
|
||||||
|
if (!pkey)
|
||||||
|
{
|
||||||
|
BIO_printf(err,"cannot load %s from engine\n",key_descrip);
|
||||||
|
ERR_print_errors(err);
|
||||||
|
}
|
||||||
|
}
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -889,7 +901,9 @@ EVP_PKEY *load_key(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
if (file == NULL && maybe_stdin)
|
if (file == NULL && maybe_stdin)
|
||||||
{
|
{
|
||||||
#ifdef _IONBF
|
#ifdef _IONBF
|
||||||
|
# ifndef OPENSSL_NO_SETVBUF_IONBF
|
||||||
setvbuf(stdin, NULL, _IONBF, 0);
|
setvbuf(stdin, NULL, _IONBF, 0);
|
||||||
|
# endif /* ndef OPENSSL_NO_SETVBUF_IONBF */
|
||||||
#endif
|
#endif
|
||||||
BIO_set_fp(key,stdin,BIO_NOCLOSE);
|
BIO_set_fp(key,stdin,BIO_NOCLOSE);
|
||||||
}
|
}
|
||||||
@@ -921,11 +935,13 @@ EVP_PKEY *load_key(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
&pkey, NULL, NULL))
|
&pkey, NULL, NULL))
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
#if !defined(OPENSSL_NO_RSA) && !defined(OPENSSL_NO_DSA) && !defined (OPENSSL_NO_RC4)
|
||||||
else if (format == FORMAT_MSBLOB)
|
else if (format == FORMAT_MSBLOB)
|
||||||
pkey = b2i_PrivateKey_bio(key);
|
pkey = b2i_PrivateKey_bio(key);
|
||||||
else if (format == FORMAT_PVK)
|
else if (format == FORMAT_PVK)
|
||||||
pkey = b2i_PVK_bio(key, (pem_password_cb *)password_callback,
|
pkey = b2i_PVK_bio(key, (pem_password_cb *)password_callback,
|
||||||
&cb_data);
|
&cb_data);
|
||||||
|
#endif
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
BIO_printf(err,"bad input format specified for key file\n");
|
BIO_printf(err,"bad input format specified for key file\n");
|
||||||
@@ -934,7 +950,10 @@ EVP_PKEY *load_key(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
end:
|
end:
|
||||||
if (key != NULL) BIO_free(key);
|
if (key != NULL) BIO_free(key);
|
||||||
if (pkey == NULL)
|
if (pkey == NULL)
|
||||||
|
{
|
||||||
BIO_printf(err,"unable to load %s\n", key_descrip);
|
BIO_printf(err,"unable to load %s\n", key_descrip);
|
||||||
|
ERR_print_errors(err);
|
||||||
|
}
|
||||||
return(pkey);
|
return(pkey);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -973,7 +992,9 @@ EVP_PKEY *load_pubkey(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
if (file == NULL && maybe_stdin)
|
if (file == NULL && maybe_stdin)
|
||||||
{
|
{
|
||||||
#ifdef _IONBF
|
#ifdef _IONBF
|
||||||
|
# ifndef OPENSSL_NO_SETVBUF_IONBF
|
||||||
setvbuf(stdin, NULL, _IONBF, 0);
|
setvbuf(stdin, NULL, _IONBF, 0);
|
||||||
|
# endif /* ndef OPENSSL_NO_SETVBUF_IONBF */
|
||||||
#endif
|
#endif
|
||||||
BIO_set_fp(key,stdin,BIO_NOCLOSE);
|
BIO_set_fp(key,stdin,BIO_NOCLOSE);
|
||||||
}
|
}
|
||||||
@@ -989,6 +1010,7 @@ EVP_PKEY *load_pubkey(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
{
|
{
|
||||||
pkey=d2i_PUBKEY_bio(key, NULL);
|
pkey=d2i_PUBKEY_bio(key, NULL);
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_RSA
|
||||||
else if (format == FORMAT_ASN1RSA)
|
else if (format == FORMAT_ASN1RSA)
|
||||||
{
|
{
|
||||||
RSA *rsa;
|
RSA *rsa;
|
||||||
@@ -1018,7 +1040,7 @@ EVP_PKEY *load_pubkey(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
else
|
else
|
||||||
pkey = NULL;
|
pkey = NULL;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
else if (format == FORMAT_PEM)
|
else if (format == FORMAT_PEM)
|
||||||
{
|
{
|
||||||
pkey=PEM_read_bio_PUBKEY(key,NULL,
|
pkey=PEM_read_bio_PUBKEY(key,NULL,
|
||||||
@@ -1028,8 +1050,10 @@ EVP_PKEY *load_pubkey(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
else if (format == FORMAT_NETSCAPE || format == FORMAT_IISSGC)
|
else if (format == FORMAT_NETSCAPE || format == FORMAT_IISSGC)
|
||||||
pkey = load_netscape_key(err, key, file, key_descrip, format);
|
pkey = load_netscape_key(err, key, file, key_descrip, format);
|
||||||
#endif
|
#endif
|
||||||
|
#if !defined(OPENSSL_NO_RSA) && !defined(OPENSSL_NO_DSA)
|
||||||
else if (format == FORMAT_MSBLOB)
|
else if (format == FORMAT_MSBLOB)
|
||||||
pkey = b2i_PublicKey_bio(key);
|
pkey = b2i_PublicKey_bio(key);
|
||||||
|
#endif
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
BIO_printf(err,"bad input format specified for key file\n");
|
BIO_printf(err,"bad input format specified for key file\n");
|
||||||
@@ -1088,76 +1112,122 @@ error:
|
|||||||
}
|
}
|
||||||
#endif /* ndef OPENSSL_NO_RC4 */
|
#endif /* ndef OPENSSL_NO_RC4 */
|
||||||
|
|
||||||
STACK_OF(X509) *load_certs(BIO *err, const char *file, int format,
|
static int load_certs_crls(BIO *err, const char *file, int format,
|
||||||
const char *pass, ENGINE *e, const char *cert_descrip)
|
const char *pass, ENGINE *e, const char *desc,
|
||||||
|
STACK_OF(X509) **pcerts, STACK_OF(X509_CRL) **pcrls)
|
||||||
{
|
{
|
||||||
BIO *certs;
|
|
||||||
int i;
|
int i;
|
||||||
STACK_OF(X509) *othercerts = NULL;
|
BIO *bio;
|
||||||
STACK_OF(X509_INFO) *allcerts = NULL;
|
STACK_OF(X509_INFO) *xis = NULL;
|
||||||
X509_INFO *xi;
|
X509_INFO *xi;
|
||||||
PW_CB_DATA cb_data;
|
PW_CB_DATA cb_data;
|
||||||
|
int rv = 0;
|
||||||
|
|
||||||
cb_data.password = pass;
|
cb_data.password = pass;
|
||||||
cb_data.prompt_info = file;
|
cb_data.prompt_info = file;
|
||||||
|
|
||||||
if((certs = BIO_new(BIO_s_file())) == NULL)
|
if (format != FORMAT_PEM)
|
||||||
{
|
{
|
||||||
ERR_print_errors(err);
|
BIO_printf(err,"bad input format specified for %s\n", desc);
|
||||||
goto end;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (file == NULL)
|
if (file == NULL)
|
||||||
BIO_set_fp(certs,stdin,BIO_NOCLOSE);
|
bio = BIO_new_fp(stdin,BIO_NOCLOSE);
|
||||||
else
|
else
|
||||||
|
bio = BIO_new_file(file, "r");
|
||||||
|
|
||||||
|
if (bio == NULL)
|
||||||
{
|
{
|
||||||
if (BIO_read_filename(certs,file) <= 0)
|
BIO_printf(err, "Error opening %s %s\n",
|
||||||
{
|
desc, file ? file : "stdin");
|
||||||
BIO_printf(err, "Error opening %s %s\n",
|
ERR_print_errors(err);
|
||||||
cert_descrip, file);
|
return 0;
|
||||||
ERR_print_errors(err);
|
}
|
||||||
|
|
||||||
|
xis = PEM_X509_INFO_read_bio(bio, NULL,
|
||||||
|
(pem_password_cb *)password_callback, &cb_data);
|
||||||
|
|
||||||
|
BIO_free(bio);
|
||||||
|
|
||||||
|
if (pcerts)
|
||||||
|
{
|
||||||
|
*pcerts = sk_X509_new_null();
|
||||||
|
if (!*pcerts)
|
||||||
goto end;
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (pcrls)
|
||||||
|
{
|
||||||
|
*pcrls = sk_X509_CRL_new_null();
|
||||||
|
if (!*pcrls)
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
for(i = 0; i < sk_X509_INFO_num(xis); i++)
|
||||||
|
{
|
||||||
|
xi = sk_X509_INFO_value (xis, i);
|
||||||
|
if (xi->x509 && pcerts)
|
||||||
|
{
|
||||||
|
if (!sk_X509_push(*pcerts, xi->x509))
|
||||||
|
goto end;
|
||||||
|
xi->x509 = NULL;
|
||||||
|
}
|
||||||
|
if (xi->crl && pcrls)
|
||||||
|
{
|
||||||
|
if (!sk_X509_CRL_push(*pcrls, xi->crl))
|
||||||
|
goto end;
|
||||||
|
xi->crl = NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (format == FORMAT_PEM)
|
if (pcerts && sk_X509_num(*pcerts) > 0)
|
||||||
|
rv = 1;
|
||||||
|
|
||||||
|
if (pcrls && sk_X509_CRL_num(*pcrls) > 0)
|
||||||
|
rv = 1;
|
||||||
|
|
||||||
|
end:
|
||||||
|
|
||||||
|
if (xis)
|
||||||
|
sk_X509_INFO_pop_free(xis, X509_INFO_free);
|
||||||
|
|
||||||
|
if (rv == 0)
|
||||||
{
|
{
|
||||||
othercerts = sk_X509_new_null();
|
if (pcerts)
|
||||||
if(!othercerts)
|
|
||||||
{
|
{
|
||||||
sk_X509_free(othercerts);
|
sk_X509_pop_free(*pcerts, X509_free);
|
||||||
othercerts = NULL;
|
*pcerts = NULL;
|
||||||
goto end;
|
|
||||||
}
|
}
|
||||||
allcerts = PEM_X509_INFO_read_bio(certs, NULL,
|
if (pcrls)
|
||||||
(pem_password_cb *)password_callback, &cb_data);
|
|
||||||
for(i = 0; i < sk_X509_INFO_num(allcerts); i++)
|
|
||||||
{
|
{
|
||||||
xi = sk_X509_INFO_value (allcerts, i);
|
sk_X509_CRL_pop_free(*pcrls, X509_CRL_free);
|
||||||
if (xi->x509)
|
*pcrls = NULL;
|
||||||
{
|
|
||||||
sk_X509_push(othercerts, xi->x509);
|
|
||||||
xi->x509 = NULL;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
goto end;
|
BIO_printf(err,"unable to load %s\n",
|
||||||
}
|
pcerts ? "certificates" : "CRLs");
|
||||||
else {
|
|
||||||
BIO_printf(err,"bad input format specified for %s\n",
|
|
||||||
cert_descrip);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
end:
|
|
||||||
if (othercerts == NULL)
|
|
||||||
{
|
|
||||||
BIO_printf(err,"unable to load certificates\n");
|
|
||||||
ERR_print_errors(err);
|
ERR_print_errors(err);
|
||||||
}
|
}
|
||||||
if (allcerts) sk_X509_INFO_pop_free(allcerts, X509_INFO_free);
|
return rv;
|
||||||
if (certs != NULL) BIO_free(certs);
|
|
||||||
return(othercerts);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
STACK_OF(X509) *load_certs(BIO *err, const char *file, int format,
|
||||||
|
const char *pass, ENGINE *e, const char *desc)
|
||||||
|
{
|
||||||
|
STACK_OF(X509) *certs;
|
||||||
|
if (!load_certs_crls(err, file, format, pass, e, desc, &certs, NULL))
|
||||||
|
return NULL;
|
||||||
|
return certs;
|
||||||
|
}
|
||||||
|
|
||||||
|
STACK_OF(X509_CRL) *load_crls(BIO *err, const char *file, int format,
|
||||||
|
const char *pass, ENGINE *e, const char *desc)
|
||||||
|
{
|
||||||
|
STACK_OF(X509_CRL) *crls;
|
||||||
|
if (!load_certs_crls(err, file, format, pass, e, desc, NULL, &crls))
|
||||||
|
return NULL;
|
||||||
|
return crls;
|
||||||
|
}
|
||||||
|
|
||||||
#define X509V3_EXT_UNKNOWN_MASK (0xfL << 16)
|
#define X509V3_EXT_UNKNOWN_MASK (0xfL << 16)
|
||||||
/* Return error for unknown extensions */
|
/* Return error for unknown extensions */
|
||||||
@@ -1481,7 +1551,7 @@ char *make_config_name()
|
|||||||
return p;
|
return p;
|
||||||
}
|
}
|
||||||
|
|
||||||
static unsigned long index_serial_hash(const CSTRING *a)
|
static unsigned long index_serial_hash(const OPENSSL_CSTRING *a)
|
||||||
{
|
{
|
||||||
const char *n;
|
const char *n;
|
||||||
|
|
||||||
@@ -1490,7 +1560,7 @@ static unsigned long index_serial_hash(const CSTRING *a)
|
|||||||
return(lh_strhash(n));
|
return(lh_strhash(n));
|
||||||
}
|
}
|
||||||
|
|
||||||
static int index_serial_cmp(const CSTRING *a, const CSTRING *b)
|
static int index_serial_cmp(const OPENSSL_CSTRING *a, const OPENSSL_CSTRING *b)
|
||||||
{
|
{
|
||||||
const char *aa,*bb;
|
const char *aa,*bb;
|
||||||
|
|
||||||
@@ -1502,16 +1572,16 @@ static int index_serial_cmp(const CSTRING *a, const CSTRING *b)
|
|||||||
static int index_name_qual(char **a)
|
static int index_name_qual(char **a)
|
||||||
{ return(a[0][0] == 'V'); }
|
{ return(a[0][0] == 'V'); }
|
||||||
|
|
||||||
static unsigned long index_name_hash(const CSTRING *a)
|
static unsigned long index_name_hash(const OPENSSL_CSTRING *a)
|
||||||
{ return(lh_strhash(a[DB_name])); }
|
{ return(lh_strhash(a[DB_name])); }
|
||||||
|
|
||||||
int index_name_cmp(const CSTRING *a, const CSTRING *b)
|
int index_name_cmp(const OPENSSL_CSTRING *a, const OPENSSL_CSTRING *b)
|
||||||
{ return(strcmp(a[DB_name], b[DB_name])); }
|
{ return(strcmp(a[DB_name], b[DB_name])); }
|
||||||
|
|
||||||
static IMPLEMENT_LHASH_HASH_FN(index_serial, CSTRING)
|
static IMPLEMENT_LHASH_HASH_FN(index_serial, OPENSSL_CSTRING)
|
||||||
static IMPLEMENT_LHASH_COMP_FN(index_serial, CSTRING)
|
static IMPLEMENT_LHASH_COMP_FN(index_serial, OPENSSL_CSTRING)
|
||||||
static IMPLEMENT_LHASH_HASH_FN(index_name, CSTRING)
|
static IMPLEMENT_LHASH_HASH_FN(index_name, OPENSSL_CSTRING)
|
||||||
static IMPLEMENT_LHASH_COMP_FN(index_name, CSTRING)
|
static IMPLEMENT_LHASH_COMP_FN(index_name, OPENSSL_CSTRING)
|
||||||
|
|
||||||
#undef BSIZE
|
#undef BSIZE
|
||||||
#define BSIZE 256
|
#define BSIZE 256
|
||||||
@@ -2062,7 +2132,7 @@ X509_NAME *parse_name(char *subject, long chtype, int multirdn)
|
|||||||
X509_NAME *n = NULL;
|
X509_NAME *n = NULL;
|
||||||
int nid;
|
int nid;
|
||||||
|
|
||||||
if (!buf || !ne_types || !ne_values)
|
if (!buf || !ne_types || !ne_values || !mval)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "malloc error\n");
|
BIO_printf(bio_err, "malloc error\n");
|
||||||
goto error;
|
goto error;
|
||||||
@@ -2166,6 +2236,7 @@ X509_NAME *parse_name(char *subject, long chtype, int multirdn)
|
|||||||
OPENSSL_free(ne_values);
|
OPENSSL_free(ne_values);
|
||||||
OPENSSL_free(ne_types);
|
OPENSSL_free(ne_types);
|
||||||
OPENSSL_free(buf);
|
OPENSSL_free(buf);
|
||||||
|
OPENSSL_free(mval);
|
||||||
return n;
|
return n;
|
||||||
|
|
||||||
error:
|
error:
|
||||||
@@ -2174,6 +2245,8 @@ error:
|
|||||||
OPENSSL_free(ne_values);
|
OPENSSL_free(ne_values);
|
||||||
if (ne_types)
|
if (ne_types)
|
||||||
OPENSSL_free(ne_types);
|
OPENSSL_free(ne_types);
|
||||||
|
if (mval)
|
||||||
|
OPENSSL_free(mval);
|
||||||
if (buf)
|
if (buf)
|
||||||
OPENSSL_free(buf);
|
OPENSSL_free(buf);
|
||||||
return NULL;
|
return NULL;
|
||||||
@@ -2185,9 +2258,10 @@ int args_verify(char ***pargs, int *pargc,
|
|||||||
ASN1_OBJECT *otmp = NULL;
|
ASN1_OBJECT *otmp = NULL;
|
||||||
unsigned long flags = 0;
|
unsigned long flags = 0;
|
||||||
int i;
|
int i;
|
||||||
int purpose = 0;
|
int purpose = 0, depth = -1;
|
||||||
char **oldargs = *pargs;
|
char **oldargs = *pargs;
|
||||||
char *arg = **pargs, *argn = (*pargs)[1];
|
char *arg = **pargs, *argn = (*pargs)[1];
|
||||||
|
time_t at_time = 0;
|
||||||
if (!strcmp(arg, "-policy"))
|
if (!strcmp(arg, "-policy"))
|
||||||
{
|
{
|
||||||
if (!argn)
|
if (!argn)
|
||||||
@@ -2225,6 +2299,42 @@ int args_verify(char ***pargs, int *pargc,
|
|||||||
}
|
}
|
||||||
(*pargs)++;
|
(*pargs)++;
|
||||||
}
|
}
|
||||||
|
else if (strcmp(arg,"-verify_depth") == 0)
|
||||||
|
{
|
||||||
|
if (!argn)
|
||||||
|
*badarg = 1;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
depth = atoi(argn);
|
||||||
|
if(depth < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(err, "invalid depth\n");
|
||||||
|
*badarg = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
(*pargs)++;
|
||||||
|
}
|
||||||
|
else if (strcmp(arg,"-attime") == 0)
|
||||||
|
{
|
||||||
|
if (!argn)
|
||||||
|
*badarg = 1;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
long timestamp;
|
||||||
|
/* interpret the -attime argument as seconds since
|
||||||
|
* Epoch */
|
||||||
|
if (sscanf(argn, "%li", ×tamp) != 1)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"Error parsing timestamp %s\n",
|
||||||
|
argn);
|
||||||
|
*badarg = 1;
|
||||||
|
}
|
||||||
|
/* on some platforms time_t may be a float */
|
||||||
|
at_time = (time_t) timestamp;
|
||||||
|
}
|
||||||
|
(*pargs)++;
|
||||||
|
}
|
||||||
else if (!strcmp(arg, "-ignore_critical"))
|
else if (!strcmp(arg, "-ignore_critical"))
|
||||||
flags |= X509_V_FLAG_IGNORE_CRITICAL;
|
flags |= X509_V_FLAG_IGNORE_CRITICAL;
|
||||||
else if (!strcmp(arg, "-issuer_checks"))
|
else if (!strcmp(arg, "-issuer_checks"))
|
||||||
@@ -2249,6 +2359,8 @@ int args_verify(char ***pargs, int *pargc,
|
|||||||
flags |= X509_V_FLAG_USE_DELTAS;
|
flags |= X509_V_FLAG_USE_DELTAS;
|
||||||
else if (!strcmp(arg, "-policy_print"))
|
else if (!strcmp(arg, "-policy_print"))
|
||||||
flags |= X509_V_FLAG_NOTIFY_POLICY;
|
flags |= X509_V_FLAG_NOTIFY_POLICY;
|
||||||
|
else if (!strcmp(arg, "-check_ss_sig"))
|
||||||
|
flags |= X509_V_FLAG_CHECK_SS_SIGNATURE;
|
||||||
else
|
else
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
@@ -2274,6 +2386,12 @@ int args_verify(char ***pargs, int *pargc,
|
|||||||
if (purpose)
|
if (purpose)
|
||||||
X509_VERIFY_PARAM_set_purpose(*pm, purpose);
|
X509_VERIFY_PARAM_set_purpose(*pm, purpose);
|
||||||
|
|
||||||
|
if (depth >= 0)
|
||||||
|
X509_VERIFY_PARAM_set_depth(*pm, depth);
|
||||||
|
|
||||||
|
if (at_time)
|
||||||
|
X509_VERIFY_PARAM_set_time(*pm, at_time);
|
||||||
|
|
||||||
end:
|
end:
|
||||||
|
|
||||||
(*pargs)++;
|
(*pargs)++;
|
||||||
@@ -2605,6 +2723,50 @@ void jpake_server_auth(BIO *out, BIO *conn, const char *secret)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
/* next_protos_parse parses a comma separated list of strings into a string
|
||||||
|
* in a format suitable for passing to SSL_CTX_set_next_protos_advertised.
|
||||||
|
* outlen: (output) set to the length of the resulting buffer on success.
|
||||||
|
* err: (maybe NULL) on failure, an error message line is written to this BIO.
|
||||||
|
* in: a NUL termianted string like "abc,def,ghi"
|
||||||
|
*
|
||||||
|
* returns: a malloced buffer or NULL on failure.
|
||||||
|
*/
|
||||||
|
unsigned char *next_protos_parse(unsigned short *outlen, const char *in)
|
||||||
|
{
|
||||||
|
size_t len;
|
||||||
|
unsigned char *out;
|
||||||
|
size_t i, start = 0;
|
||||||
|
|
||||||
|
len = strlen(in);
|
||||||
|
if (len >= 65535)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
out = OPENSSL_malloc(strlen(in) + 1);
|
||||||
|
if (!out)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
for (i = 0; i <= len; ++i)
|
||||||
|
{
|
||||||
|
if (i == len || in[i] == ',')
|
||||||
|
{
|
||||||
|
if (i - start > 255)
|
||||||
|
{
|
||||||
|
OPENSSL_free(out);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
out[start] = i - start;
|
||||||
|
start = i + 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
out[i+1] = in[i];
|
||||||
|
}
|
||||||
|
|
||||||
|
*outlen = len + 1;
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
#endif /* !OPENSSL_NO_TLSEXT && !OPENSSL_NO_NEXTPROTONEG */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Platform-specific sections
|
* Platform-specific sections
|
||||||
*/
|
*/
|
||||||
|
|||||||
34
apps/apps.h
34
apps/apps.h
@@ -168,6 +168,12 @@ extern BIO *bio_err;
|
|||||||
#define do_pipe_sig()
|
#define do_pipe_sig()
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef OPENSSL_NO_COMP
|
||||||
|
#define zlib_cleanup()
|
||||||
|
#else
|
||||||
|
#define zlib_cleanup() COMP_zlib_cleanup()
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(MONOLITH) && !defined(OPENSSL_C)
|
#if defined(MONOLITH) && !defined(OPENSSL_C)
|
||||||
# define apps_startup() \
|
# define apps_startup() \
|
||||||
do_pipe_sig()
|
do_pipe_sig()
|
||||||
@@ -182,7 +188,8 @@ extern BIO *bio_err;
|
|||||||
do { CONF_modules_unload(1); destroy_ui_method(); \
|
do { CONF_modules_unload(1); destroy_ui_method(); \
|
||||||
OBJ_cleanup(); EVP_cleanup(); ENGINE_cleanup(); \
|
OBJ_cleanup(); EVP_cleanup(); ENGINE_cleanup(); \
|
||||||
CRYPTO_cleanup_all_ex_data(); ERR_remove_thread_state(NULL); \
|
CRYPTO_cleanup_all_ex_data(); ERR_remove_thread_state(NULL); \
|
||||||
ERR_free_strings(); COMP_zlib_cleanup();} while(0)
|
RAND_cleanup(); \
|
||||||
|
ERR_free_strings(); zlib_cleanup();} while(0)
|
||||||
# else
|
# else
|
||||||
# define apps_startup() \
|
# define apps_startup() \
|
||||||
do { do_pipe_sig(); CRYPTO_malloc_init(); \
|
do { do_pipe_sig(); CRYPTO_malloc_init(); \
|
||||||
@@ -192,7 +199,8 @@ extern BIO *bio_err;
|
|||||||
do { CONF_modules_unload(1); destroy_ui_method(); \
|
do { CONF_modules_unload(1); destroy_ui_method(); \
|
||||||
OBJ_cleanup(); EVP_cleanup(); \
|
OBJ_cleanup(); EVP_cleanup(); \
|
||||||
CRYPTO_cleanup_all_ex_data(); ERR_remove_thread_state(NULL); \
|
CRYPTO_cleanup_all_ex_data(); ERR_remove_thread_state(NULL); \
|
||||||
ERR_free_strings(); } while(0)
|
RAND_cleanup(); \
|
||||||
|
ERR_free_strings(); zlib_cleanup(); } while(0)
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -245,6 +253,8 @@ EVP_PKEY *load_pubkey(BIO *err, const char *file, int format, int maybe_stdin,
|
|||||||
const char *pass, ENGINE *e, const char *key_descrip);
|
const char *pass, ENGINE *e, const char *key_descrip);
|
||||||
STACK_OF(X509) *load_certs(BIO *err, const char *file, int format,
|
STACK_OF(X509) *load_certs(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);
|
||||||
|
STACK_OF(X509_CRL) *load_crls(BIO *err, const char *file, int format,
|
||||||
|
const char *pass, ENGINE *e, const char *cert_descrip);
|
||||||
X509_STORE *setup_verify(BIO *bp, char *CAfile, char *CApath);
|
X509_STORE *setup_verify(BIO *bp, char *CAfile, char *CApath);
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
ENGINE *setup_engine(BIO *err, const char *engine, int debug);
|
ENGINE *setup_engine(BIO *err, const char *engine, int debug);
|
||||||
@@ -253,6 +263,7 @@ ENGINE *setup_engine(BIO *err, const char *engine, int debug);
|
|||||||
#ifndef OPENSSL_NO_OCSP
|
#ifndef OPENSSL_NO_OCSP
|
||||||
OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req,
|
OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req,
|
||||||
char *host, char *path, char *port, int use_ssl,
|
char *host, char *path, char *port, int use_ssl,
|
||||||
|
STACK_OF(CONF_VALUE) *headers,
|
||||||
int req_timeout);
|
int req_timeout);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -295,9 +306,9 @@ int save_index(const char *dbfile, const char *suffix, CA_DB *db);
|
|||||||
int rotate_index(const char *dbfile, const char *new_suffix, const char *old_suffix);
|
int rotate_index(const char *dbfile, const char *new_suffix, const char *old_suffix);
|
||||||
void free_index(CA_DB *db);
|
void free_index(CA_DB *db);
|
||||||
#define index_name_cmp_noconst(a, b) \
|
#define index_name_cmp_noconst(a, b) \
|
||||||
index_name_cmp((const CSTRING *)CHECKED_PTR_OF(STRING, a), \
|
index_name_cmp((const OPENSSL_CSTRING *)CHECKED_PTR_OF(OPENSSL_STRING, a), \
|
||||||
(const CSTRING *)CHECKED_PTR_OF(STRING, b))
|
(const OPENSSL_CSTRING *)CHECKED_PTR_OF(OPENSSL_STRING, b))
|
||||||
int index_name_cmp(const CSTRING *a, const CSTRING *b);
|
int index_name_cmp(const OPENSSL_CSTRING *a, const OPENSSL_CSTRING *b);
|
||||||
int parse_yesno(const char *str, int def);
|
int parse_yesno(const char *str, int def);
|
||||||
|
|
||||||
X509_NAME *parse_name(char *str, long chtype, int multirdn);
|
X509_NAME *parse_name(char *str, long chtype, int multirdn);
|
||||||
@@ -308,6 +319,12 @@ int bio_to_mem(unsigned char **out, int maxlen, BIO *in);
|
|||||||
int pkey_ctrl_string(EVP_PKEY_CTX *ctx, char *value);
|
int pkey_ctrl_string(EVP_PKEY_CTX *ctx, char *value);
|
||||||
int init_gen_str(BIO *err, EVP_PKEY_CTX **pctx,
|
int init_gen_str(BIO *err, EVP_PKEY_CTX **pctx,
|
||||||
const char *algname, ENGINE *e, int do_param);
|
const char *algname, ENGINE *e, int do_param);
|
||||||
|
int do_X509_sign(BIO *err, X509 *x, EVP_PKEY *pkey, const EVP_MD *md,
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts);
|
||||||
|
int do_X509_REQ_sign(BIO *err, X509_REQ *x, EVP_PKEY *pkey, const EVP_MD *md,
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts);
|
||||||
|
int do_X509_CRL_sign(BIO *err, X509_CRL *x, EVP_PKEY *pkey, const EVP_MD *md,
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts);
|
||||||
#ifndef OPENSSL_NO_PSK
|
#ifndef OPENSSL_NO_PSK
|
||||||
extern char *psk_key;
|
extern char *psk_key;
|
||||||
#endif
|
#endif
|
||||||
@@ -316,6 +333,10 @@ void jpake_client_auth(BIO *out, BIO *conn, const char *secret);
|
|||||||
void jpake_server_auth(BIO *out, BIO *conn, const char *secret);
|
void jpake_server_auth(BIO *out, BIO *conn, const char *secret);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
unsigned char *next_protos_parse(unsigned short *outlen, const char *in);
|
||||||
|
#endif /* !OPENSSL_NO_TLSEXT && !OPENSSL_NO_NEXTPROTONEG */
|
||||||
|
|
||||||
#define FORMAT_UNDEF 0
|
#define FORMAT_UNDEF 0
|
||||||
#define FORMAT_ASN1 1
|
#define FORMAT_ASN1 1
|
||||||
#define FORMAT_TEXT 2
|
#define FORMAT_TEXT 2
|
||||||
@@ -348,4 +369,7 @@ int raw_write_stdout(const void *,int);
|
|||||||
#define TM_START 0
|
#define TM_START 0
|
||||||
#define TM_STOP 1
|
#define TM_STOP 1
|
||||||
double app_tminterval (int stop,int usertime);
|
double app_tminterval (int stop,int usertime);
|
||||||
|
|
||||||
|
#define OPENSSL_NO_SSL_INTERN
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ int MAIN(int argc, char **argv)
|
|||||||
unsigned char *tmpbuf;
|
unsigned char *tmpbuf;
|
||||||
const unsigned char *ctmpbuf;
|
const unsigned char *ctmpbuf;
|
||||||
BUF_MEM *buf=NULL;
|
BUF_MEM *buf=NULL;
|
||||||
STACK_OF(STRING) *osk=NULL;
|
STACK_OF(OPENSSL_STRING) *osk=NULL;
|
||||||
ASN1_TYPE *at=NULL;
|
ASN1_TYPE *at=NULL;
|
||||||
|
|
||||||
informat=FORMAT_PEM;
|
informat=FORMAT_PEM;
|
||||||
@@ -113,7 +113,7 @@ int MAIN(int argc, char **argv)
|
|||||||
prog=argv[0];
|
prog=argv[0];
|
||||||
argc--;
|
argc--;
|
||||||
argv++;
|
argv++;
|
||||||
if ((osk=sk_STRING_new_null()) == NULL)
|
if ((osk=sk_OPENSSL_STRING_new_null()) == NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Memory allocation failure\n");
|
BIO_printf(bio_err,"Memory allocation failure\n");
|
||||||
goto end;
|
goto end;
|
||||||
@@ -169,7 +169,7 @@ int MAIN(int argc, char **argv)
|
|||||||
else if (strcmp(*argv,"-strparse") == 0)
|
else if (strcmp(*argv,"-strparse") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
sk_STRING_push(osk,*(++argv));
|
sk_OPENSSL_STRING_push(osk,*(++argv));
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-genstr") == 0)
|
else if (strcmp(*argv,"-genstr") == 0)
|
||||||
{
|
{
|
||||||
@@ -302,18 +302,18 @@ bad:
|
|||||||
|
|
||||||
/* If any structs to parse go through in sequence */
|
/* If any structs to parse go through in sequence */
|
||||||
|
|
||||||
if (sk_STRING_num(osk))
|
if (sk_OPENSSL_STRING_num(osk))
|
||||||
{
|
{
|
||||||
tmpbuf=(unsigned char *)str;
|
tmpbuf=(unsigned char *)str;
|
||||||
tmplen=num;
|
tmplen=num;
|
||||||
for (i=0; i<sk_STRING_num(osk); i++)
|
for (i=0; i<sk_OPENSSL_STRING_num(osk); i++)
|
||||||
{
|
{
|
||||||
ASN1_TYPE *atmp;
|
ASN1_TYPE *atmp;
|
||||||
int typ;
|
int typ;
|
||||||
j=atoi(sk_STRING_value(osk,i));
|
j=atoi(sk_OPENSSL_STRING_value(osk,i));
|
||||||
if (j == 0)
|
if (j == 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"'%s' is an invalid number\n",sk_STRING_value(osk,i));
|
BIO_printf(bio_err,"'%s' is an invalid number\n",sk_OPENSSL_STRING_value(osk,i));
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
tmpbuf+=j;
|
tmpbuf+=j;
|
||||||
@@ -378,7 +378,7 @@ end:
|
|||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
if (buf != NULL) BUF_MEM_free(buf);
|
if (buf != NULL) BUF_MEM_free(buf);
|
||||||
if (at != NULL) ASN1_TYPE_free(at);
|
if (at != NULL) ASN1_TYPE_free(at);
|
||||||
if (osk != NULL) sk_STRING_free(osk);
|
if (osk != NULL) sk_OPENSSL_STRING_free(osk);
|
||||||
OBJ_cleanup();
|
OBJ_cleanup();
|
||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
@@ -408,6 +408,7 @@ static int do_generate(BIO *bio, char *genstr, char *genconf, BUF_MEM *buf)
|
|||||||
|
|
||||||
atyp = ASN1_generate_nconf(genstr, cnf);
|
atyp = ASN1_generate_nconf(genstr, cnf);
|
||||||
NCONF_free(cnf);
|
NCONF_free(cnf);
|
||||||
|
cnf = NULL;
|
||||||
|
|
||||||
if (!atyp)
|
if (!atyp)
|
||||||
return -1;
|
return -1;
|
||||||
|
|||||||
146
apps/ca.c
146
apps/ca.c
@@ -197,27 +197,30 @@ extern int EF_ALIGNMENT;
|
|||||||
|
|
||||||
static void lookup_fail(const char *name, const char *tag);
|
static void lookup_fail(const char *name, const char *tag);
|
||||||
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,CA_DB *db,
|
const EVP_MD *dgst,STACK_OF(OPENSSL_STRING) *sigopts,
|
||||||
|
STACK_OF(CONF_VALUE) *policy,CA_DB *db,
|
||||||
BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, int email_dn, char *startdate,
|
BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, 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 selfsign);
|
int default_op, int ext_copy, int selfsign);
|
||||||
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(OPENSSL_STRING) *sigopts,
|
||||||
|
STACK_OF(CONF_VALUE) *policy,
|
||||||
CA_DB *db, BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, int email_dn,
|
CA_DB *db, BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, 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(OPENSSL_STRING) *sigopts,
|
||||||
|
STACK_OF(CONF_VALUE) *policy,
|
||||||
CA_DB *db, BIGNUM *serial,char *subj,unsigned long chtype, int multirdn, int email_dn,
|
CA_DB *db, BIGNUM *serial,char *subj,unsigned long chtype, int multirdn, 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 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(OPENSSL_STRING) *sigopts,
|
||||||
STACK_OF(CONF_VALUE) *policy, CA_DB *db, BIGNUM *serial,char *subj,unsigned long chtype, int multirdn,
|
STACK_OF(CONF_VALUE) *policy, CA_DB *db, BIGNUM *serial,char *subj,unsigned long chtype, int multirdn,
|
||||||
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,
|
||||||
@@ -312,6 +315,7 @@ int MAIN(int argc, char **argv)
|
|||||||
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;
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts = NULL;
|
||||||
#undef BSIZE
|
#undef BSIZE
|
||||||
#define BSIZE 256
|
#define BSIZE 256
|
||||||
MS_STATIC char buf[3][BSIZE];
|
MS_STATIC char buf[3][BSIZE];
|
||||||
@@ -436,6 +440,15 @@ EF_ALIGNMENT=0;
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
outdir= *(++argv);
|
outdir= *(++argv);
|
||||||
}
|
}
|
||||||
|
else if (strcmp(*argv,"-sigopt") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1)
|
||||||
|
goto bad;
|
||||||
|
if (!sigopts)
|
||||||
|
sigopts = sk_OPENSSL_STRING_new_null();
|
||||||
|
if (!sigopts || !sk_OPENSSL_STRING_push(sigopts, *(++argv)))
|
||||||
|
goto bad;
|
||||||
|
}
|
||||||
else if (strcmp(*argv,"-notext") == 0)
|
else if (strcmp(*argv,"-notext") == 0)
|
||||||
notext=1;
|
notext=1;
|
||||||
else if (strcmp(*argv,"-batch") == 0)
|
else if (strcmp(*argv,"-batch") == 0)
|
||||||
@@ -883,9 +896,9 @@ bad:
|
|||||||
if (db == NULL) goto err;
|
if (db == NULL) goto err;
|
||||||
|
|
||||||
/* Lets check some fields */
|
/* Lets check some fields */
|
||||||
for (i=0; i<sk_PSTRING_num(db->db->data); i++)
|
for (i=0; i<sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
{
|
{
|
||||||
pp=sk_PSTRING_value(db->db->data,i);
|
pp=sk_OPENSSL_PSTRING_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'))
|
||||||
{
|
{
|
||||||
@@ -938,7 +951,7 @@ bad:
|
|||||||
#endif
|
#endif
|
||||||
TXT_DB_write(out,db->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",
|
||||||
sk_PSTRING_num(db->db->data));
|
sk_OPENSSL_PSTRING_num(db->db->data));
|
||||||
BIO_printf(bio_err,"generating index\n");
|
BIO_printf(bio_err,"generating index\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1171,8 +1184,9 @@ bad:
|
|||||||
if (spkac_file != NULL)
|
if (spkac_file != NULL)
|
||||||
{
|
{
|
||||||
total++;
|
total++;
|
||||||
j=certify_spkac(&x,spkac_file,pkey,x509,dgst,attribs,db,
|
j=certify_spkac(&x,spkac_file,pkey,x509,dgst,sigopts,
|
||||||
serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,extensions,
|
attribs,db, serial,subj,chtype,multirdn,
|
||||||
|
email_dn,startdate,enddate,days,extensions,
|
||||||
conf,verbose,certopt,nameopt,default_op,ext_copy);
|
conf,verbose,certopt,nameopt,default_op,ext_copy);
|
||||||
if (j < 0) goto err;
|
if (j < 0) goto err;
|
||||||
if (j > 0)
|
if (j > 0)
|
||||||
@@ -1195,7 +1209,8 @@ bad:
|
|||||||
if (ss_cert_file != NULL)
|
if (ss_cert_file != NULL)
|
||||||
{
|
{
|
||||||
total++;
|
total++;
|
||||||
j=certify_cert(&x,ss_cert_file,pkey,x509,dgst,attribs,
|
j=certify_cert(&x,ss_cert_file,pkey,x509,dgst,sigopts,
|
||||||
|
attribs,
|
||||||
db,serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,batch,
|
db,serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,batch,
|
||||||
extensions,conf,verbose, certopt, nameopt,
|
extensions,conf,verbose, certopt, nameopt,
|
||||||
default_op, ext_copy, e);
|
default_op, ext_copy, e);
|
||||||
@@ -1215,7 +1230,7 @@ bad:
|
|||||||
if (infile != NULL)
|
if (infile != NULL)
|
||||||
{
|
{
|
||||||
total++;
|
total++;
|
||||||
j=certify(&x,infile,pkey,x509p,dgst,attribs,db,
|
j=certify(&x,infile,pkey,x509p,dgst,sigopts, attribs,db,
|
||||||
serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,batch,
|
serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,batch,
|
||||||
extensions,conf,verbose, certopt, nameopt,
|
extensions,conf,verbose, certopt, nameopt,
|
||||||
default_op, ext_copy, selfsign);
|
default_op, ext_copy, selfsign);
|
||||||
@@ -1235,7 +1250,7 @@ bad:
|
|||||||
for (i=0; i<argc; i++)
|
for (i=0; i<argc; i++)
|
||||||
{
|
{
|
||||||
total++;
|
total++;
|
||||||
j=certify(&x,argv[i],pkey,x509p,dgst,attribs,db,
|
j=certify(&x,argv[i],pkey,x509p,dgst,sigopts,attribs,db,
|
||||||
serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,batch,
|
serial,subj,chtype,multirdn,email_dn,startdate,enddate,days,batch,
|
||||||
extensions,conf,verbose, certopt, nameopt,
|
extensions,conf,verbose, certopt, nameopt,
|
||||||
default_op, ext_copy, selfsign);
|
default_op, ext_copy, selfsign);
|
||||||
@@ -1263,7 +1278,12 @@ bad:
|
|||||||
BIO_printf(bio_err,"\n%d out of %d certificate requests certified, commit? [y/n]",total_done,total);
|
BIO_printf(bio_err,"\n%d out of %d certificate requests certified, commit? [y/n]",total_done,total);
|
||||||
(void)BIO_flush(bio_err);
|
(void)BIO_flush(bio_err);
|
||||||
buf[0][0]='\0';
|
buf[0][0]='\0';
|
||||||
fgets(buf[0],10,stdin);
|
if (!fgets(buf[0],10,stdin))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"CERTIFICATION CANCELED: I/O error\n");
|
||||||
|
ret=0;
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
if ((buf[0][0] != 'y') && (buf[0][0] != 'Y'))
|
if ((buf[0][0] != 'y') && (buf[0][0] != 'Y'))
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"CERTIFICATION CANCELED\n");
|
BIO_printf(bio_err,"CERTIFICATION CANCELED\n");
|
||||||
@@ -1388,6 +1408,7 @@ bad:
|
|||||||
if (!NCONF_get_number(conf,section,
|
if (!NCONF_get_number(conf,section,
|
||||||
ENV_DEFAULT_CRL_HOURS, &crlhours))
|
ENV_DEFAULT_CRL_HOURS, &crlhours))
|
||||||
crlhours = 0;
|
crlhours = 0;
|
||||||
|
ERR_clear_error();
|
||||||
}
|
}
|
||||||
if ((crldays == 0) && (crlhours == 0) && (crlsec == 0))
|
if ((crldays == 0) && (crlhours == 0) && (crlsec == 0))
|
||||||
{
|
{
|
||||||
@@ -1403,14 +1424,19 @@ bad:
|
|||||||
if (!tmptm) goto err;
|
if (!tmptm) goto err;
|
||||||
X509_gmtime_adj(tmptm,0);
|
X509_gmtime_adj(tmptm,0);
|
||||||
X509_CRL_set_lastUpdate(crl, tmptm);
|
X509_CRL_set_lastUpdate(crl, tmptm);
|
||||||
X509_time_adj_ex(tmptm, crldays, crlhours*60*60 + crlsec, NULL);
|
if (!X509_time_adj_ex(tmptm, crldays, crlhours*60*60 + crlsec,
|
||||||
|
NULL))
|
||||||
|
{
|
||||||
|
BIO_puts(bio_err, "error setting CRL nextUpdate\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
X509_CRL_set_nextUpdate(crl, tmptm);
|
X509_CRL_set_nextUpdate(crl, tmptm);
|
||||||
|
|
||||||
ASN1_TIME_free(tmptm);
|
ASN1_TIME_free(tmptm);
|
||||||
|
|
||||||
for (i=0; i<sk_PSTRING_num(db->db->data); i++)
|
for (i=0; i<sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
{
|
{
|
||||||
pp=sk_PSTRING_value(db->db->data,i);
|
pp=sk_OPENSSL_PSTRING_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;
|
||||||
@@ -1474,7 +1500,7 @@ bad:
|
|||||||
crlnumber = NULL;
|
crlnumber = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!X509_CRL_sign(crl,pkey,dgst)) goto err;
|
if (!do_X509_CRL_sign(bio_err,crl,pkey,dgst,sigopts)) goto err;
|
||||||
|
|
||||||
PEM_write_bio_X509_CRL(Sout,crl);
|
PEM_write_bio_X509_CRL(Sout,crl);
|
||||||
|
|
||||||
@@ -1528,6 +1554,8 @@ err:
|
|||||||
BN_free(serial);
|
BN_free(serial);
|
||||||
BN_free(crlnumber);
|
BN_free(crlnumber);
|
||||||
free_index(db);
|
free_index(db);
|
||||||
|
if (sigopts)
|
||||||
|
sk_OPENSSL_STRING_free(sigopts);
|
||||||
EVP_PKEY_free(pkey);
|
EVP_PKEY_free(pkey);
|
||||||
if (x509) X509_free(x509);
|
if (x509) X509_free(x509);
|
||||||
X509_CRL_free(crl);
|
X509_CRL_free(crl);
|
||||||
@@ -1544,8 +1572,10 @@ static void lookup_fail(const char *name, const char *tag)
|
|||||||
}
|
}
|
||||||
|
|
||||||
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, CA_DB *db,
|
const EVP_MD *dgst, STACK_OF(OPENSSL_STRING) *sigopts,
|
||||||
BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, int email_dn, char *startdate, char *enddate,
|
STACK_OF(CONF_VALUE) *policy, CA_DB *db,
|
||||||
|
BIGNUM *serial, char *subj,unsigned long chtype, int multirdn,
|
||||||
|
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,
|
||||||
int ext_copy, int selfsign)
|
int ext_copy, int selfsign)
|
||||||
@@ -1601,7 +1631,8 @@ static int certify(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
|||||||
else
|
else
|
||||||
BIO_printf(bio_err,"Signature ok\n");
|
BIO_printf(bio_err,"Signature ok\n");
|
||||||
|
|
||||||
ok=do_body(xret,pkey,x509,dgst,policy,db,serial,subj,chtype,multirdn, email_dn,
|
ok=do_body(xret,pkey,x509,dgst,sigopts, policy,db,serial,subj,chtype,
|
||||||
|
multirdn, email_dn,
|
||||||
startdate,enddate,days,batch,verbose,req,ext_sect,lconf,
|
startdate,enddate,days,batch,verbose,req,ext_sect,lconf,
|
||||||
certopt, nameopt, default_op, ext_copy, selfsign);
|
certopt, nameopt, default_op, ext_copy, selfsign);
|
||||||
|
|
||||||
@@ -1612,7 +1643,8 @@ 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, CA_DB *db,
|
const EVP_MD *dgst, STACK_OF(OPENSSL_STRING) *sigopts,
|
||||||
|
STACK_OF(CONF_VALUE) *policy, CA_DB *db,
|
||||||
BIGNUM *serial, char *subj, unsigned long chtype, int multirdn, int email_dn, char *startdate, char *enddate,
|
BIGNUM *serial, char *subj, unsigned long chtype, int multirdn, 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,
|
||||||
@@ -1655,7 +1687,7 @@ static int certify_cert(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
|||||||
if ((rreq=X509_to_X509_REQ(req,NULL,EVP_md5())) == NULL)
|
if ((rreq=X509_to_X509_REQ(req,NULL,EVP_md5())) == NULL)
|
||||||
goto err;
|
goto err;
|
||||||
|
|
||||||
ok=do_body(xret,pkey,x509,dgst,policy,db,serial,subj,chtype,multirdn,email_dn,startdate,enddate,
|
ok=do_body(xret,pkey,x509,dgst,sigopts,policy,db,serial,subj,chtype,multirdn,email_dn,startdate,enddate,
|
||||||
days,batch,verbose,rreq,ext_sect,lconf, certopt, nameopt, default_op,
|
days,batch,verbose,rreq,ext_sect,lconf, certopt, nameopt, default_op,
|
||||||
ext_copy, 0);
|
ext_copy, 0);
|
||||||
|
|
||||||
@@ -1666,7 +1698,8 @@ 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, CA_DB *db, BIGNUM *serial, char *subj,
|
STACK_OF(OPENSSL_STRING) *sigopts, STACK_OF(CONF_VALUE) *policy,
|
||||||
|
CA_DB *db, BIGNUM *serial, char *subj,
|
||||||
unsigned long chtype, int multirdn,
|
unsigned long chtype, int multirdn,
|
||||||
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,
|
||||||
@@ -1685,9 +1718,9 @@ 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;
|
||||||
const char *p;
|
const char *p;
|
||||||
CONF_VALUE *cv;
|
CONF_VALUE *cv;
|
||||||
STRING row[DB_NUMBER];
|
OPENSSL_STRING row[DB_NUMBER];
|
||||||
STRING *irow=NULL;
|
OPENSSL_STRING *irow=NULL;
|
||||||
STRING *rrow=NULL;
|
OPENSSL_STRING *rrow=NULL;
|
||||||
char buf[25];
|
char buf[25];
|
||||||
|
|
||||||
tmptm=ASN1_UTCTIME_new();
|
tmptm=ASN1_UTCTIME_new();
|
||||||
@@ -1929,7 +1962,7 @@ again2:
|
|||||||
|
|
||||||
if (db->attributes.unique_subject)
|
if (db->attributes.unique_subject)
|
||||||
{
|
{
|
||||||
STRING *crow=row;
|
OPENSSL_STRING *crow=row;
|
||||||
|
|
||||||
rrow=TXT_DB_get_by_index(db->db,DB_name,crow);
|
rrow=TXT_DB_get_by_index(db->db,DB_name,crow);
|
||||||
if (rrow != NULL)
|
if (rrow != NULL)
|
||||||
@@ -2117,7 +2150,12 @@ again2:
|
|||||||
BIO_printf(bio_err,"Sign the certificate? [y/n]:");
|
BIO_printf(bio_err,"Sign the certificate? [y/n]:");
|
||||||
(void)BIO_flush(bio_err);
|
(void)BIO_flush(bio_err);
|
||||||
buf[0]='\0';
|
buf[0]='\0';
|
||||||
fgets(buf,sizeof(buf)-1,stdin);
|
if (!fgets(buf,sizeof(buf)-1,stdin))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"CERTIFICATE WILL NOT BE CERTIFIED: I/O error\n");
|
||||||
|
ok=0;
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
if (!((buf[0] == 'y') || (buf[0] == 'Y')))
|
if (!((buf[0] == 'y') || (buf[0] == 'Y')))
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"CERTIFICATE WILL NOT BE CERTIFIED\n");
|
BIO_printf(bio_err,"CERTIFICATE WILL NOT BE CERTIFIED\n");
|
||||||
@@ -2132,7 +2170,7 @@ again2:
|
|||||||
EVP_PKEY_copy_parameters(pktmp,pkey);
|
EVP_PKEY_copy_parameters(pktmp,pkey);
|
||||||
EVP_PKEY_free(pktmp);
|
EVP_PKEY_free(pktmp);
|
||||||
|
|
||||||
if (!X509_sign(ret,pkey,dgst))
|
if (!do_X509_sign(bio_err, ret,pkey,dgst, sigopts))
|
||||||
goto err;
|
goto err;
|
||||||
|
|
||||||
/* We now just add it to the database */
|
/* We now just add it to the database */
|
||||||
@@ -2226,7 +2264,8 @@ 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, CA_DB *db,
|
const EVP_MD *dgst, STACK_OF(OPENSSL_STRING) *sigopts,
|
||||||
|
STACK_OF(CONF_VALUE) *policy, CA_DB *db,
|
||||||
BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, int email_dn, char *startdate, char *enddate,
|
BIGNUM *serial, char *subj,unsigned long chtype, int multirdn, 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)
|
||||||
@@ -2319,25 +2358,9 @@ static int certify_spkac(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
if (!X509_NAME_add_entry_by_NID(n, nid, chtype,
|
||||||
if ((nid == NID_pkcs9_emailAddress) && (email_dn == 0))
|
(unsigned char *)buf, -1, -1, 0))
|
||||||
continue;
|
|
||||||
*/
|
|
||||||
|
|
||||||
j=ASN1_PRINTABLE_type((unsigned char *)buf,-1);
|
|
||||||
if (fix_data(nid, &j) == 0)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err,
|
|
||||||
"invalid characters in string %s\n",buf);
|
|
||||||
goto err;
|
goto err;
|
||||||
}
|
|
||||||
|
|
||||||
if ((ne=X509_NAME_ENTRY_create_by_NID(&ne,nid,j,
|
|
||||||
(unsigned char *)buf,
|
|
||||||
strlen(buf))) == NULL)
|
|
||||||
goto err;
|
|
||||||
|
|
||||||
if (!X509_NAME_add_entry(n,ne,-1, 0)) goto err;
|
|
||||||
}
|
}
|
||||||
if (spki == NULL)
|
if (spki == NULL)
|
||||||
{
|
{
|
||||||
@@ -2368,9 +2391,9 @@ static int certify_spkac(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509,
|
|||||||
|
|
||||||
X509_REQ_set_pubkey(req,pktmp);
|
X509_REQ_set_pubkey(req,pktmp);
|
||||||
EVP_PKEY_free(pktmp);
|
EVP_PKEY_free(pktmp);
|
||||||
ok=do_body(xret,pkey,x509,dgst,policy,db,serial,subj,chtype,multirdn,email_dn,startdate,enddate,
|
ok=do_body(xret,pkey,x509,dgst,sigopts,policy,db,serial,subj,chtype,
|
||||||
days,1,verbose,req,ext_sect,lconf, certopt, nameopt, default_op,
|
multirdn,email_dn,startdate,enddate, days,1,verbose,req,
|
||||||
ext_copy, 0);
|
ext_sect,lconf, certopt, nameopt, default_op, ext_copy, 0);
|
||||||
err:
|
err:
|
||||||
if (req != NULL) X509_REQ_free(req);
|
if (req != NULL) X509_REQ_free(req);
|
||||||
if (parms != NULL) CONF_free(parms);
|
if (parms != NULL) CONF_free(parms);
|
||||||
@@ -2380,21 +2403,6 @@ err:
|
|||||||
return(ok);
|
return(ok);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int fix_data(int nid, int *type)
|
|
||||||
{
|
|
||||||
if (nid == NID_pkcs9_emailAddress)
|
|
||||||
*type=V_ASN1_IA5STRING;
|
|
||||||
if ((nid == NID_commonName) && (*type == V_ASN1_IA5STRING))
|
|
||||||
*type=V_ASN1_T61STRING;
|
|
||||||
if ((nid == NID_pkcs9_challengePassword) && (*type == V_ASN1_IA5STRING))
|
|
||||||
*type=V_ASN1_T61STRING;
|
|
||||||
if ((nid == NID_pkcs9_unstructuredName) && (*type == V_ASN1_T61STRING))
|
|
||||||
return(0);
|
|
||||||
if (nid == NID_pkcs9_unstructuredName)
|
|
||||||
*type=V_ASN1_IA5STRING;
|
|
||||||
return(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int check_time_format(const char *str)
|
static int check_time_format(const char *str)
|
||||||
{
|
{
|
||||||
return ASN1_TIME_set_string(NULL, str);
|
return ASN1_TIME_set_string(NULL, str);
|
||||||
@@ -2553,7 +2561,7 @@ static int get_certificate_status(const char *serial, CA_DB *db)
|
|||||||
|
|
||||||
/* Make it Upper Case */
|
/* Make it Upper Case */
|
||||||
for (i=0; row[DB_serial][i] != '\0'; i++)
|
for (i=0; row[DB_serial][i] != '\0'; i++)
|
||||||
row[DB_serial][i] = toupper(row[DB_serial][i]);
|
row[DB_serial][i] = toupper((unsigned char)row[DB_serial][i]);
|
||||||
|
|
||||||
|
|
||||||
ok=1;
|
ok=1;
|
||||||
@@ -2632,9 +2640,9 @@ static int do_updatedb (CA_DB *db)
|
|||||||
else
|
else
|
||||||
a_y2k = 0;
|
a_y2k = 0;
|
||||||
|
|
||||||
for (i = 0; i < sk_PSTRING_num(db->db->data); i++)
|
for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
{
|
{
|
||||||
rrow = sk_PSTRING_value(db->db->data, i);
|
rrow = sk_OPENSSL_PSTRING_value(db->db->data, i);
|
||||||
|
|
||||||
if (rrow[DB_type][0] == 'V')
|
if (rrow[DB_type][0] == 'V')
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -196,7 +196,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
if (Verbose)
|
if (Verbose)
|
||||||
{
|
{
|
||||||
unsigned long id = c->id;
|
unsigned long id = SSL_CIPHER_get_id(c);
|
||||||
int id0 = (int)(id >> 24);
|
int id0 = (int)(id >> 24);
|
||||||
int id1 = (int)((id >> 16) & 0xffL);
|
int id1 = (int)((id >> 16) & 0xffL);
|
||||||
int id2 = (int)((id >> 8) & 0xffL);
|
int id2 = (int)((id >> 8) & 0xffL);
|
||||||
|
|||||||
@@ -1,24 +1,52 @@
|
|||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit)
|
subject= C = UK, O = OpenSSL Group, OU = FOR TESTING PURPOSES ONLY, CN = Test Client Cert
|
||||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Client test cert (512 bit)
|
issuer= C = UK, O = OpenSSL Group, OU = FOR TESTING PURPOSES ONLY, CN = OpenSSL Test Intermediate CA
|
||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
MIIB6TCCAVICAQIwDQYJKoZIhvcNAQEEBQAwWzELMAkGA1UEBhMCQVUxEzARBgNV
|
MIID5zCCAs+gAwIBAgIJALnu1NlVpZ6yMA0GCSqGSIb3DQEBBQUAMHAxCzAJBgNV
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRswGQYD
|
BAYTAlVLMRYwFAYDVQQKDA1PcGVuU1NMIEdyb3VwMSIwIAYDVQQLDBlGT1IgVEVT
|
||||||
VQQDExJUZXN0IENBICgxMDI0IGJpdCkwHhcNOTcwNjA5MTM1NzU2WhcNOTgwNjA5
|
VElORyBQVVJQT1NFUyBPTkxZMSUwIwYDVQQDDBxPcGVuU1NMIFRlc3QgSW50ZXJt
|
||||||
MTM1NzU2WjBjMQswCQYDVQQGEwJBVTETMBEGA1UECBMKUXVlZW5zbGFuZDEaMBgG
|
ZWRpYXRlIENBMB4XDTExMTIwODE0MDE0OFoXDTIxMTAxNjE0MDE0OFowZDELMAkG
|
||||||
A1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxIzAhBgNVBAMTGkNsaWVudCB0ZXN0IGNl
|
A1UEBhMCVUsxFjAUBgNVBAoMDU9wZW5TU0wgR3JvdXAxIjAgBgNVBAsMGUZPUiBU
|
||||||
cnQgKDUxMiBiaXQpMFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBALtv55QyzG6i2Plw
|
RVNUSU5HIFBVUlBPU0VTIE9OTFkxGTAXBgNVBAMMEFRlc3QgQ2xpZW50IENlcnQw
|
||||||
Z1pah7++Gv8L5j6Hnyr/uTZE1NLG0ABDDexmq/R4KedLjFEIYjocDui+IXs62NNt
|
ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC0ranbHRLcLVqN+0BzcZpY
|
||||||
XrT8odkCAwEAATANBgkqhkiG9w0BAQQFAAOBgQBwtMmI7oGUG8nKmftQssATViH5
|
+yOLqxzDWT1LD9eW1stC4NzXX9/DCtSIVyN7YIHdGLrIPr64IDdXXaMRzgZ2rOKs
|
||||||
NRRtoEw07DxJp/LfatHdrhqQB73eGdL5WILZJXk46Xz2e9WMSUjVCSYhdKxtflU3
|
lmHCAiFpO/ja99gGCJRxH0xwQatqAULfJVHeUhs7OEGOZc2nWifjqKvGfNTilP7D
|
||||||
UR2Ajv1Oo0sTNdfz0wDqJNirLNtzyhhsaq8qMTrLwXrCP31VxBiigFSQSUFnZyTE
|
nwi69ipQFq9oS19FmhwVHk2wg7KZGHI1qDyG04UrfCZMRitvS9+UVhPpIPjuiBi2
|
||||||
9TKwhS4GlwbtCfxSKQ==
|
x3/FZIpL5gXJvvFK6xHY63oq2asyzBATntBgnP4qJFWWcvRx24wF1PnZabxuVoL2
|
||||||
|
bPnQ/KvONDrw3IdqkKhYNTul7jEcu3OlcZIMw+7DiaKJLAzKb/bBF5gm/pwW6As9
|
||||||
|
AgMBAAGjgY8wgYwwDAYDVR0TAQH/BAIwADAOBgNVHQ8BAf8EBAMCBeAwLAYJYIZI
|
||||||
|
AYb4QgENBB8WHU9wZW5TU0wgR2VuZXJhdGVkIENlcnRpZmljYXRlMB0GA1UdDgQW
|
||||||
|
BBSZHKyLoTh7Mb409Zn/mK1ceSDAjDAfBgNVHSMEGDAWgBQ2w2yI55X+sL3szj49
|
||||||
|
hqshgYfa2jANBgkqhkiG9w0BAQUFAAOCAQEAD0mL7PtPYgCEuDyOQSbLpeND5hVS
|
||||||
|
curxQdGnrJ6Acrhodb7E9ccATokeb0PLx6HBLQUicxhTZIQ9FbO43YkQcOU6C3BB
|
||||||
|
IlwskqmtN6+VmrQzNolHCDzvxNZs9lYL2VbGPGqVRyjZeHpoAlf9cQr8PgDb4d4b
|
||||||
|
vUx2KAhHQvV2nkmYvKyXcgnRuHggumF87mkxidriGAEFwH4qfOqetUg64WyxP7P2
|
||||||
|
QLipm04SyQa7ONtIApfVXgHcE42Py4/f4arzCzMjKe3VyhGkS7nsT55X/fWgTaRm
|
||||||
|
CQPkO+H94P958WTvQDt77bQ+D3IvYaVvfil8n6HJMOJfFT0LJuSUbpSXJg==
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
-----BEGIN RSA PRIVATE KEY-----
|
||||||
MIIBOwIBAAJBALtv55QyzG6i2PlwZ1pah7++Gv8L5j6Hnyr/uTZE1NLG0ABDDexm
|
MIIEpQIBAAKCAQEAtK2p2x0S3C1ajftAc3GaWPsji6scw1k9Sw/XltbLQuDc11/f
|
||||||
q/R4KedLjFEIYjocDui+IXs62NNtXrT8odkCAwEAAQJAbwXq0vJ/+uyEvsNgxLko
|
wwrUiFcje2CB3Ri6yD6+uCA3V12jEc4GdqzirJZhwgIhaTv42vfYBgiUcR9McEGr
|
||||||
/V86mGXQ/KrSkeKlL0r4ENxjcyeMAGoKu6J9yMY7+X9+Zm4nxShNfTsf/+Freoe1
|
agFC3yVR3lIbOzhBjmXNp1on46irxnzU4pT+w58IuvYqUBavaEtfRZocFR5NsIOy
|
||||||
HQIhAPOSm5Q1YI+KIsII2GeVJx1U69+wnd71OasIPakS1L1XAiEAxQAW+J3/JWE0
|
mRhyNag8htOFK3wmTEYrb0vflFYT6SD47ogYtsd/xWSKS+YFyb7xSusR2Ot6Ktmr
|
||||||
ftEYakbhUOKL8tD1OaFZS71/5GdG7E8CIQCefUMmySSvwd6kC0VlATSWbW+d+jp/
|
MswQE57QYJz+KiRVlnL0cduMBdT52Wm8blaC9mz50PyrzjQ68NyHapCoWDU7pe4x
|
||||||
nWmM1KvqnAo5uQIhALqEADu5U1Wvt8UN8UDGBRPQulHWNycuNV45d3nnskWPAiAw
|
HLtzpXGSDMPuw4miiSwMym/2wReYJv6cFugLPQIDAQABAoIBAAZOyc9MhIwLSU4L
|
||||||
ueTyr6WsZ5+SD8g/Hy3xuvF3nPmJRH+rwvVihlcFOg==
|
p4RgQvM4UVVe8/Id+3XTZ8NsXExJbWxXfIhiqGjaIfL8u4vsgRjcl+v1s/jo2/iT
|
||||||
|
KMab4o4D8gXD7UavQVDjtjb/ta79WL3SjRl2Uc9YjjMkyq6WmDNQeo2NKDdafCTB
|
||||||
|
1uzSJtLNipB8Z53ELPuHJhxX9QMHrMnuha49riQgXZ7buP9iQrHJFhImBjSzbxJx
|
||||||
|
L+TI6rkyLSf9Wi0Pd3L27Ob3QWNfNRYNSeTE+08eSRChkur5W0RuXAcuAICdQlCl
|
||||||
|
LBvWO/LmmvbzCqiDcgy/TliSb6CGGwgiNG7LJZmlkYNj8laGwalNlYZs3UrVv6NO
|
||||||
|
Br2loAECgYEA2kvCvPGj0Dg/6g7WhXDvAkEbcaL1tSeCxBbNH+6HS2UWMWvyTtCn
|
||||||
|
/bbD519QIdkvayy1QjEf32GV/UjUVmlULMLBcDy0DGjtL3+XpIhLKWDNxN1v1/ai
|
||||||
|
1oz23ZJCOgnk6K4qtFtlRS1XtynjA+rBetvYvLP9SKeFrnpzCgaA2r0CgYEA0+KX
|
||||||
|
1ACXDTNH5ySX3kMjSS9xdINf+OOw4CvPHFwbtc9aqk2HePlEsBTz5I/W3rKwXva3
|
||||||
|
NqZ/bRqVVeZB/hHKFywgdUQk2Uc5z/S7Lw70/w1HubNTXGU06Ngb6zOFAo/o/TwZ
|
||||||
|
zTP1BMIKSOB6PAZPS3l+aLO4FRIRotfFhgRHOoECgYEAmiZbqt8cJaJDB/5YYDzC
|
||||||
|
mp3tSk6gIb936Q6M5VqkMYp9pIKsxhk0N8aDCnTU+kIK6SzWBpr3/d9Ecmqmfyq7
|
||||||
|
5SvWO3KyVf0WWK9KH0abhOm2BKm2HBQvI0DB5u8sUx2/hsvOnjPYDISbZ11t0MtK
|
||||||
|
u35Zy89yMYcSsIYJjG/ROCUCgYEAgI2P9G5PNxEP5OtMwOsW84Y3Xat/hPAQFlI+
|
||||||
|
HES+AzbFGWJkeT8zL2nm95tVkFP1sggZ7Kxjz3w7cpx7GX0NkbWSE9O+T51pNASV
|
||||||
|
tN1sQ3p5M+/a+cnlqgfEGJVvc7iAcXQPa3LEi5h2yPR49QYXAgG6cifn3dDSpmwn
|
||||||
|
SUI7PQECgYEApGCIIpSRPLAEHTGmP87RBL1smurhwmy2s/pghkvUkWehtxg0sGHh
|
||||||
|
kuaqDWcskogv+QC0sVdytiLSz8G0DwcEcsHK1Fkyb8A+ayiw6jWJDo2m9+IF4Fww
|
||||||
|
1Te6jFPYDESnbhq7+TLGgHGhtwcu5cnb4vSuYXGXKupZGzoLOBbv1Zw=
|
||||||
-----END RSA PRIVATE KEY-----
|
-----END RSA PRIVATE KEY-----
|
||||||
|
|||||||
109
apps/cms.c
109
apps/cms.c
@@ -71,9 +71,9 @@
|
|||||||
static int save_certs(char *signerfile, STACK_OF(X509) *signers);
|
static int save_certs(char *signerfile, STACK_OF(X509) *signers);
|
||||||
static int cms_cb(int ok, X509_STORE_CTX *ctx);
|
static int cms_cb(int ok, X509_STORE_CTX *ctx);
|
||||||
static void receipt_request_print(BIO *out, CMS_ContentInfo *cms);
|
static void receipt_request_print(BIO *out, CMS_ContentInfo *cms);
|
||||||
static CMS_ReceiptRequest *make_receipt_request(STACK_OF(STRING) *rr_to,
|
static CMS_ReceiptRequest *make_receipt_request(STACK_OF(OPENSSL_STRING) *rr_to,
|
||||||
int rr_allorfirst,
|
int rr_allorfirst,
|
||||||
STACK_OF(STRING) *rr_from);
|
STACK_OF(OPENSSL_STRING) *rr_from);
|
||||||
|
|
||||||
#define SMIME_OP 0x10
|
#define SMIME_OP 0x10
|
||||||
#define SMIME_IP 0x20
|
#define SMIME_IP 0x20
|
||||||
@@ -108,7 +108,7 @@ int MAIN(int argc, char **argv)
|
|||||||
const char *inmode = "r", *outmode = "w";
|
const char *inmode = "r", *outmode = "w";
|
||||||
char *infile = NULL, *outfile = NULL, *rctfile = NULL;
|
char *infile = NULL, *outfile = NULL, *rctfile = NULL;
|
||||||
char *signerfile = NULL, *recipfile = NULL;
|
char *signerfile = NULL, *recipfile = NULL;
|
||||||
STACK_OF(STRING) *sksigners = NULL, *skkeys = NULL;
|
STACK_OF(OPENSSL_STRING) *sksigners = NULL, *skkeys = NULL;
|
||||||
char *certfile = NULL, *keyfile = NULL, *contfile=NULL;
|
char *certfile = NULL, *keyfile = NULL, *contfile=NULL;
|
||||||
char *certsoutfile = NULL;
|
char *certsoutfile = NULL;
|
||||||
const EVP_CIPHER *cipher = NULL;
|
const EVP_CIPHER *cipher = NULL;
|
||||||
@@ -122,7 +122,7 @@ int MAIN(int argc, char **argv)
|
|||||||
int flags = CMS_DETACHED, noout = 0, print = 0;
|
int flags = CMS_DETACHED, noout = 0, print = 0;
|
||||||
int verify_retcode = 0;
|
int verify_retcode = 0;
|
||||||
int rr_print = 0, rr_allorfirst = -1;
|
int rr_print = 0, rr_allorfirst = -1;
|
||||||
STACK_OF(STRING) *rr_to = NULL, *rr_from = NULL;
|
STACK_OF(OPENSSL_STRING) *rr_to = NULL, *rr_from = NULL;
|
||||||
CMS_ReceiptRequest *rr = NULL;
|
CMS_ReceiptRequest *rr = NULL;
|
||||||
char *to = NULL, *from = NULL, *subject = NULL;
|
char *to = NULL, *from = NULL, *subject = NULL;
|
||||||
char *CAfile = NULL, *CApath = NULL;
|
char *CAfile = NULL, *CApath = NULL;
|
||||||
@@ -136,6 +136,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *engine=NULL;
|
char *engine=NULL;
|
||||||
#endif
|
#endif
|
||||||
unsigned char *secret_key = NULL, *secret_keyid = NULL;
|
unsigned char *secret_key = NULL, *secret_keyid = NULL;
|
||||||
|
unsigned char *pwri_pass = NULL, *pwri_tmp = NULL;
|
||||||
size_t secret_keylen = 0, secret_keyidlen = 0;
|
size_t secret_keylen = 0, secret_keyidlen = 0;
|
||||||
|
|
||||||
ASN1_OBJECT *econtent_type = NULL;
|
ASN1_OBJECT *econtent_type = NULL;
|
||||||
@@ -232,6 +233,8 @@ int MAIN(int argc, char **argv)
|
|||||||
else if (!strcmp(*args,"-camellia256"))
|
else if (!strcmp(*args,"-camellia256"))
|
||||||
cipher = EVP_camellia_256_cbc();
|
cipher = EVP_camellia_256_cbc();
|
||||||
#endif
|
#endif
|
||||||
|
else if (!strcmp (*args, "-debug_decrypt"))
|
||||||
|
flags |= CMS_DEBUG_DECRYPT;
|
||||||
else if (!strcmp (*args, "-text"))
|
else if (!strcmp (*args, "-text"))
|
||||||
flags |= CMS_TEXT;
|
flags |= CMS_TEXT;
|
||||||
else if (!strcmp (*args, "-nointern"))
|
else if (!strcmp (*args, "-nointern"))
|
||||||
@@ -281,8 +284,8 @@ int MAIN(int argc, char **argv)
|
|||||||
goto argerr;
|
goto argerr;
|
||||||
args++;
|
args++;
|
||||||
if (!rr_from)
|
if (!rr_from)
|
||||||
rr_from = sk_STRING_new_null();
|
rr_from = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(rr_from, *args);
|
sk_OPENSSL_STRING_push(rr_from, *args);
|
||||||
}
|
}
|
||||||
else if (!strcmp(*args,"-receipt_request_to"))
|
else if (!strcmp(*args,"-receipt_request_to"))
|
||||||
{
|
{
|
||||||
@@ -290,8 +293,8 @@ int MAIN(int argc, char **argv)
|
|||||||
goto argerr;
|
goto argerr;
|
||||||
args++;
|
args++;
|
||||||
if (!rr_to)
|
if (!rr_to)
|
||||||
rr_to = sk_STRING_new_null();
|
rr_to = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(rr_to, *args);
|
sk_OPENSSL_STRING_push(rr_to, *args);
|
||||||
}
|
}
|
||||||
else if (!strcmp (*args, "-print"))
|
else if (!strcmp (*args, "-print"))
|
||||||
{
|
{
|
||||||
@@ -326,6 +329,13 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
secret_keyidlen = (size_t)ltmp;
|
secret_keyidlen = (size_t)ltmp;
|
||||||
}
|
}
|
||||||
|
else if (!strcmp(*args,"-pwri_password"))
|
||||||
|
{
|
||||||
|
if (!args[1])
|
||||||
|
goto argerr;
|
||||||
|
args++;
|
||||||
|
pwri_pass = (unsigned char *)*args;
|
||||||
|
}
|
||||||
else if (!strcmp(*args,"-econtent_type"))
|
else if (!strcmp(*args,"-econtent_type"))
|
||||||
{
|
{
|
||||||
if (!args[1])
|
if (!args[1])
|
||||||
@@ -387,13 +397,13 @@ int MAIN(int argc, char **argv)
|
|||||||
if (signerfile)
|
if (signerfile)
|
||||||
{
|
{
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
sksigners = sk_STRING_new_null();
|
sksigners = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(sksigners, signerfile);
|
sk_OPENSSL_STRING_push(sksigners, signerfile);
|
||||||
if (!keyfile)
|
if (!keyfile)
|
||||||
keyfile = signerfile;
|
keyfile = signerfile;
|
||||||
if (!skkeys)
|
if (!skkeys)
|
||||||
skkeys = sk_STRING_new_null();
|
skkeys = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(skkeys, keyfile);
|
sk_OPENSSL_STRING_push(skkeys, keyfile);
|
||||||
keyfile = NULL;
|
keyfile = NULL;
|
||||||
}
|
}
|
||||||
signerfile = *++args;
|
signerfile = *++args;
|
||||||
@@ -435,12 +445,12 @@ int MAIN(int argc, char **argv)
|
|||||||
goto argerr;
|
goto argerr;
|
||||||
}
|
}
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
sksigners = sk_STRING_new_null();
|
sksigners = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(sksigners, signerfile);
|
sk_OPENSSL_STRING_push(sksigners, signerfile);
|
||||||
signerfile = NULL;
|
signerfile = NULL;
|
||||||
if (!skkeys)
|
if (!skkeys)
|
||||||
skkeys = sk_STRING_new_null();
|
skkeys = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(skkeys, keyfile);
|
sk_OPENSSL_STRING_push(skkeys, keyfile);
|
||||||
}
|
}
|
||||||
keyfile = *++args;
|
keyfile = *++args;
|
||||||
}
|
}
|
||||||
@@ -539,13 +549,13 @@ int MAIN(int argc, char **argv)
|
|||||||
if (signerfile)
|
if (signerfile)
|
||||||
{
|
{
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
sksigners = sk_STRING_new_null();
|
sksigners = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(sksigners, signerfile);
|
sk_OPENSSL_STRING_push(sksigners, signerfile);
|
||||||
if (!skkeys)
|
if (!skkeys)
|
||||||
skkeys = sk_STRING_new_null();
|
skkeys = sk_OPENSSL_STRING_new_null();
|
||||||
if (!keyfile)
|
if (!keyfile)
|
||||||
keyfile = signerfile;
|
keyfile = signerfile;
|
||||||
sk_STRING_push(skkeys, keyfile);
|
sk_OPENSSL_STRING_push(skkeys, keyfile);
|
||||||
}
|
}
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
{
|
{
|
||||||
@@ -559,7 +569,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
else if (operation == SMIME_DECRYPT)
|
else if (operation == SMIME_DECRYPT)
|
||||||
{
|
{
|
||||||
if (!recipfile && !keyfile && !secret_key)
|
if (!recipfile && !keyfile && !secret_key && !pwri_pass)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "No recipient certificate or key specified\n");
|
BIO_printf(bio_err, "No recipient certificate or key specified\n");
|
||||||
badarg = 1;
|
badarg = 1;
|
||||||
@@ -567,7 +577,7 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
else if (operation == SMIME_ENCRYPT)
|
else if (operation == SMIME_ENCRYPT)
|
||||||
{
|
{
|
||||||
if (!*args && !secret_key)
|
if (!*args && !secret_key && !pwri_pass)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "No recipient(s) certificate(s) specified\n");
|
BIO_printf(bio_err, "No recipient(s) certificate(s) specified\n");
|
||||||
badarg = 1;
|
badarg = 1;
|
||||||
@@ -618,7 +628,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf (bio_err, "-certsout file certificate output file\n");
|
BIO_printf (bio_err, "-certsout file certificate output file\n");
|
||||||
BIO_printf (bio_err, "-signer file signer certificate file\n");
|
BIO_printf (bio_err, "-signer file signer certificate file\n");
|
||||||
BIO_printf (bio_err, "-recip file recipient certificate file for decryption\n");
|
BIO_printf (bio_err, "-recip file recipient certificate file for decryption\n");
|
||||||
BIO_printf (bio_err, "-skeyid use subject key identifier\n");
|
BIO_printf (bio_err, "-keyid use subject key identifier\n");
|
||||||
BIO_printf (bio_err, "-in file input file\n");
|
BIO_printf (bio_err, "-in file input file\n");
|
||||||
BIO_printf (bio_err, "-inform arg input format SMIME (default), PEM or DER\n");
|
BIO_printf (bio_err, "-inform arg input format SMIME (default), PEM or DER\n");
|
||||||
BIO_printf (bio_err, "-inkey file input private key (if not signer or recipient)\n");
|
BIO_printf (bio_err, "-inkey file input private key (if not signer or recipient)\n");
|
||||||
@@ -704,7 +714,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
if (secret_key && !secret_keyid)
|
if (secret_key && !secret_keyid)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "No sectre key id\n");
|
BIO_printf(bio_err, "No secret key id\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -880,7 +890,7 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
if (!(store = setup_verify(bio_err, CAfile, CApath)))
|
if (!(store = setup_verify(bio_err, CAfile, CApath)))
|
||||||
goto end;
|
goto end;
|
||||||
X509_STORE_set_verify_cb_func(store, cms_cb);
|
X509_STORE_set_verify_cb(store, cms_cb);
|
||||||
if (vpm)
|
if (vpm)
|
||||||
X509_STORE_set1_param(store, vpm);
|
X509_STORE_set1_param(store, vpm);
|
||||||
}
|
}
|
||||||
@@ -917,6 +927,17 @@ int MAIN(int argc, char **argv)
|
|||||||
secret_key = NULL;
|
secret_key = NULL;
|
||||||
secret_keyid = NULL;
|
secret_keyid = NULL;
|
||||||
}
|
}
|
||||||
|
if (pwri_pass)
|
||||||
|
{
|
||||||
|
pwri_tmp = (unsigned char *)BUF_strdup((char *)pwri_pass);
|
||||||
|
if (!pwri_tmp)
|
||||||
|
goto end;
|
||||||
|
if (!CMS_add0_recipient_password(cms,
|
||||||
|
-1, NID_undef, NID_undef,
|
||||||
|
pwri_tmp, -1, NULL))
|
||||||
|
goto end;
|
||||||
|
pwri_tmp = NULL;
|
||||||
|
}
|
||||||
if (!(flags & CMS_STREAM))
|
if (!(flags & CMS_STREAM))
|
||||||
{
|
{
|
||||||
if (!CMS_final(cms, in, NULL, flags))
|
if (!CMS_final(cms, in, NULL, flags))
|
||||||
@@ -980,11 +1001,11 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
flags |= CMS_REUSE_DIGEST;
|
flags |= CMS_REUSE_DIGEST;
|
||||||
for (i = 0; i < sk_STRING_num(sksigners); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(sksigners); i++)
|
||||||
{
|
{
|
||||||
CMS_SignerInfo *si;
|
CMS_SignerInfo *si;
|
||||||
signerfile = sk_STRING_value(sksigners, i);
|
signerfile = sk_OPENSSL_STRING_value(sksigners, i);
|
||||||
keyfile = sk_STRING_value(skkeys, i);
|
keyfile = sk_OPENSSL_STRING_value(skkeys, i);
|
||||||
signer = load_cert(bio_err, signerfile,FORMAT_PEM, NULL,
|
signer = load_cert(bio_err, signerfile,FORMAT_PEM, NULL,
|
||||||
e, "signer certificate");
|
e, "signer certificate");
|
||||||
if (!signer)
|
if (!signer)
|
||||||
@@ -1020,6 +1041,8 @@ int MAIN(int argc, char **argv)
|
|||||||
ret = 4;
|
ret = 4;
|
||||||
if (operation == SMIME_DECRYPT)
|
if (operation == SMIME_DECRYPT)
|
||||||
{
|
{
|
||||||
|
if (flags & CMS_DEBUG_DECRYPT)
|
||||||
|
CMS_decrypt(cms, NULL, NULL, NULL, NULL, flags);
|
||||||
|
|
||||||
if (secret_key)
|
if (secret_key)
|
||||||
{
|
{
|
||||||
@@ -1043,6 +1066,16 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (pwri_pass)
|
||||||
|
{
|
||||||
|
if (!CMS_decrypt_set1_password(cms, pwri_pass, -1))
|
||||||
|
{
|
||||||
|
BIO_puts(bio_err,
|
||||||
|
"Error decrypting CMS using password\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!CMS_decrypt(cms, NULL, NULL, indata, out, flags))
|
if (!CMS_decrypt(cms, NULL, NULL, indata, out, flags))
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "Error decrypting CMS structure\n");
|
BIO_printf(bio_err, "Error decrypting CMS structure\n");
|
||||||
@@ -1160,21 +1193,23 @@ end:
|
|||||||
if (vpm)
|
if (vpm)
|
||||||
X509_VERIFY_PARAM_free(vpm);
|
X509_VERIFY_PARAM_free(vpm);
|
||||||
if (sksigners)
|
if (sksigners)
|
||||||
sk_STRING_free(sksigners);
|
sk_OPENSSL_STRING_free(sksigners);
|
||||||
if (skkeys)
|
if (skkeys)
|
||||||
sk_STRING_free(skkeys);
|
sk_OPENSSL_STRING_free(skkeys);
|
||||||
if (secret_key)
|
if (secret_key)
|
||||||
OPENSSL_free(secret_key);
|
OPENSSL_free(secret_key);
|
||||||
if (secret_keyid)
|
if (secret_keyid)
|
||||||
OPENSSL_free(secret_keyid);
|
OPENSSL_free(secret_keyid);
|
||||||
|
if (pwri_tmp)
|
||||||
|
OPENSSL_free(pwri_tmp);
|
||||||
if (econtent_type)
|
if (econtent_type)
|
||||||
ASN1_OBJECT_free(econtent_type);
|
ASN1_OBJECT_free(econtent_type);
|
||||||
if (rr)
|
if (rr)
|
||||||
CMS_ReceiptRequest_free(rr);
|
CMS_ReceiptRequest_free(rr);
|
||||||
if (rr_to)
|
if (rr_to)
|
||||||
sk_STRING_free(rr_to);
|
sk_OPENSSL_STRING_free(rr_to);
|
||||||
if (rr_from)
|
if (rr_from)
|
||||||
sk_STRING_free(rr_from);
|
sk_OPENSSL_STRING_free(rr_from);
|
||||||
X509_STORE_free(store);
|
X509_STORE_free(store);
|
||||||
X509_free(cert);
|
X509_free(cert);
|
||||||
X509_free(recip);
|
X509_free(recip);
|
||||||
@@ -1296,7 +1331,7 @@ static void receipt_request_print(BIO *out, CMS_ContentInfo *cms)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static STACK_OF(GENERAL_NAMES) *make_names_stack(STACK_OF(STRING) *ns)
|
static STACK_OF(GENERAL_NAMES) *make_names_stack(STACK_OF(OPENSSL_STRING) *ns)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
STACK_OF(GENERAL_NAMES) *ret;
|
STACK_OF(GENERAL_NAMES) *ret;
|
||||||
@@ -1305,9 +1340,9 @@ static STACK_OF(GENERAL_NAMES) *make_names_stack(STACK_OF(STRING) *ns)
|
|||||||
ret = sk_GENERAL_NAMES_new_null();
|
ret = sk_GENERAL_NAMES_new_null();
|
||||||
if (!ret)
|
if (!ret)
|
||||||
goto err;
|
goto err;
|
||||||
for (i = 0; i < sk_STRING_num(ns); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(ns); i++)
|
||||||
{
|
{
|
||||||
char *str = sk_STRING_value(ns, i);
|
char *str = sk_OPENSSL_STRING_value(ns, i);
|
||||||
gen = a2i_GENERAL_NAME(NULL, NULL, NULL, GEN_EMAIL, str, 0);
|
gen = a2i_GENERAL_NAME(NULL, NULL, NULL, GEN_EMAIL, str, 0);
|
||||||
if (!gen)
|
if (!gen)
|
||||||
goto err;
|
goto err;
|
||||||
@@ -1335,9 +1370,9 @@ static STACK_OF(GENERAL_NAMES) *make_names_stack(STACK_OF(STRING) *ns)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static CMS_ReceiptRequest *make_receipt_request(STACK_OF(STRING) *rr_to,
|
static CMS_ReceiptRequest *make_receipt_request(STACK_OF(OPENSSL_STRING) *rr_to,
|
||||||
int rr_allorfirst,
|
int rr_allorfirst,
|
||||||
STACK_OF(STRING) *rr_from)
|
STACK_OF(OPENSSL_STRING) *rr_from)
|
||||||
{
|
{
|
||||||
STACK_OF(GENERAL_NAMES) *rct_to, *rct_from;
|
STACK_OF(GENERAL_NAMES) *rct_to, *rct_from;
|
||||||
CMS_ReceiptRequest *rr;
|
CMS_ReceiptRequest *rr;
|
||||||
|
|||||||
@@ -92,7 +92,7 @@ int MAIN(int argc, char **argv)
|
|||||||
PKCS7 *p7 = NULL;
|
PKCS7 *p7 = NULL;
|
||||||
PKCS7_SIGNED *p7s = NULL;
|
PKCS7_SIGNED *p7s = NULL;
|
||||||
X509_CRL *crl=NULL;
|
X509_CRL *crl=NULL;
|
||||||
STACK_OF(STRING) *certflst=NULL;
|
STACK_OF(OPENSSL_STRING) *certflst=NULL;
|
||||||
STACK_OF(X509_CRL) *crl_stack=NULL;
|
STACK_OF(X509_CRL) *crl_stack=NULL;
|
||||||
STACK_OF(X509) *cert_stack=NULL;
|
STACK_OF(X509) *cert_stack=NULL;
|
||||||
int ret=1,nocrl=0;
|
int ret=1,nocrl=0;
|
||||||
@@ -140,8 +140,8 @@ int MAIN(int argc, char **argv)
|
|||||||
else if (strcmp(*argv,"-certfile") == 0)
|
else if (strcmp(*argv,"-certfile") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
if(!certflst) certflst = sk_STRING_new_null();
|
if(!certflst) certflst = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(certflst,*(++argv));
|
sk_OPENSSL_STRING_push(certflst,*(++argv));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -226,8 +226,8 @@ bad:
|
|||||||
if ((cert_stack=sk_X509_new_null()) == NULL) goto end;
|
if ((cert_stack=sk_X509_new_null()) == NULL) goto end;
|
||||||
p7s->cert=cert_stack;
|
p7s->cert=cert_stack;
|
||||||
|
|
||||||
if(certflst) for(i = 0; i < sk_STRING_num(certflst); i++) {
|
if(certflst) for(i = 0; i < sk_OPENSSL_STRING_num(certflst); i++) {
|
||||||
certfile = sk_STRING_value(certflst, i);
|
certfile = sk_OPENSSL_STRING_value(certflst, i);
|
||||||
if (add_certs_from_file(cert_stack,certfile) < 0)
|
if (add_certs_from_file(cert_stack,certfile) < 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "error loading certificates\n");
|
BIO_printf(bio_err, "error loading certificates\n");
|
||||||
@@ -236,7 +236,7 @@ bad:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sk_STRING_free(certflst);
|
sk_OPENSSL_STRING_free(certflst);
|
||||||
|
|
||||||
if (outfile == NULL)
|
if (outfile == NULL)
|
||||||
{
|
{
|
||||||
|
|||||||
6
apps/demoSRP/srp_verifier.txt
Normal file
6
apps/demoSRP/srp_verifier.txt
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# This is a file that will be filled by the openssl srp routine.
|
||||||
|
# You can initialize the file with additional groups, these are
|
||||||
|
# records starting with a I followed by the g and N values and the id.
|
||||||
|
# The exact values ... you have to dig this out from the source of srp.c
|
||||||
|
# or srp_vfy.c
|
||||||
|
# The last value of an I is used as the default group for new users.
|
||||||
1
apps/demoSRP/srp_verifier.txt.attr
Normal file
1
apps/demoSRP/srp_verifier.txt.attr
Normal file
@@ -0,0 +1 @@
|
|||||||
|
unique_subject = yes
|
||||||
99
apps/dgst.c
99
apps/dgst.c
@@ -79,6 +79,26 @@ int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
|||||||
const char *sig_name, const char *md_name,
|
const char *sig_name, const char *md_name,
|
||||||
const char *file,BIO *bmd);
|
const char *file,BIO *bmd);
|
||||||
|
|
||||||
|
static void list_md_fn(const EVP_MD *m,
|
||||||
|
const char *from, const char *to, void *arg)
|
||||||
|
{
|
||||||
|
const char *mname;
|
||||||
|
/* Skip aliases */
|
||||||
|
if (!m)
|
||||||
|
return;
|
||||||
|
mname = OBJ_nid2ln(EVP_MD_type(m));
|
||||||
|
/* Skip shortnames */
|
||||||
|
if (strcmp(from, mname))
|
||||||
|
return;
|
||||||
|
/* Skip clones */
|
||||||
|
if (EVP_MD_flags(m) & EVP_MD_FLAG_PKEY_DIGEST)
|
||||||
|
return;
|
||||||
|
if (strchr(mname, ' '))
|
||||||
|
mname= EVP_MD_name(m);
|
||||||
|
BIO_printf(arg, "-%-14s to use the %s message digest algorithm\n",
|
||||||
|
mname, mname);
|
||||||
|
}
|
||||||
|
|
||||||
int MAIN(int, char **);
|
int MAIN(int, char **);
|
||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
@@ -107,7 +127,8 @@ int MAIN(int argc, char **argv)
|
|||||||
#endif
|
#endif
|
||||||
char *hmac_key=NULL;
|
char *hmac_key=NULL;
|
||||||
char *mac_name=NULL;
|
char *mac_name=NULL;
|
||||||
STACK_OF(STRING) *sigopts = NULL, *macopts = NULL;
|
int non_fips_allow = 0;
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts = NULL, *macopts = NULL;
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
|
|
||||||
@@ -135,6 +156,8 @@ int MAIN(int argc, char **argv)
|
|||||||
if ((*argv)[0] != '-') break;
|
if ((*argv)[0] != '-') break;
|
||||||
if (strcmp(*argv,"-c") == 0)
|
if (strcmp(*argv,"-c") == 0)
|
||||||
separator=1;
|
separator=1;
|
||||||
|
else if (strcmp(*argv,"-r") == 0)
|
||||||
|
separator=2;
|
||||||
else if (strcmp(*argv,"-rand") == 0)
|
else if (strcmp(*argv,"-rand") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) break;
|
if (--argc < 1) break;
|
||||||
@@ -193,6 +216,10 @@ 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,"-fips-fingerprint"))
|
||||||
|
hmac_key = "etaonrishdlcupfm";
|
||||||
|
else if (strcmp(*argv,"-non-fips-allow") == 0)
|
||||||
|
non_fips_allow=1;
|
||||||
else if (!strcmp(*argv,"-hmac"))
|
else if (!strcmp(*argv,"-hmac"))
|
||||||
{
|
{
|
||||||
if (--argc < 1)
|
if (--argc < 1)
|
||||||
@@ -210,8 +237,8 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1)
|
if (--argc < 1)
|
||||||
break;
|
break;
|
||||||
if (!sigopts)
|
if (!sigopts)
|
||||||
sigopts = sk_STRING_new_null();
|
sigopts = sk_OPENSSL_STRING_new_null();
|
||||||
if (!sigopts || !sk_STRING_push(sigopts, *(++argv)))
|
if (!sigopts || !sk_OPENSSL_STRING_push(sigopts, *(++argv)))
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-macopt") == 0)
|
else if (strcmp(*argv,"-macopt") == 0)
|
||||||
@@ -219,8 +246,8 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1)
|
if (--argc < 1)
|
||||||
break;
|
break;
|
||||||
if (!macopts)
|
if (!macopts)
|
||||||
macopts = sk_STRING_new_null();
|
macopts = sk_OPENSSL_STRING_new_null();
|
||||||
if (!macopts || !sk_STRING_push(macopts, *(++argv)))
|
if (!macopts || !sk_OPENSSL_STRING_push(macopts, *(++argv)))
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else if ((m=EVP_get_digestbyname(&((*argv)[1]))) != NULL)
|
else if ((m=EVP_get_digestbyname(&((*argv)[1]))) != NULL)
|
||||||
@@ -242,6 +269,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf(bio_err,"unknown option '%s'\n",*argv);
|
BIO_printf(bio_err,"unknown option '%s'\n",*argv);
|
||||||
BIO_printf(bio_err,"options are\n");
|
BIO_printf(bio_err,"options are\n");
|
||||||
BIO_printf(bio_err,"-c to output the digest with separating colons\n");
|
BIO_printf(bio_err,"-c to output the digest with separating colons\n");
|
||||||
|
BIO_printf(bio_err,"-r to output the digest in coreutils format\n");
|
||||||
BIO_printf(bio_err,"-d to output debug info\n");
|
BIO_printf(bio_err,"-d to output debug info\n");
|
||||||
BIO_printf(bio_err,"-hex output as hex dump\n");
|
BIO_printf(bio_err,"-hex output as hex dump\n");
|
||||||
BIO_printf(bio_err,"-binary output in binary form\n");
|
BIO_printf(bio_err,"-binary output in binary form\n");
|
||||||
@@ -249,43 +277,17 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf(bio_err,"-verify file verify a signature using public key in file\n");
|
BIO_printf(bio_err,"-verify file verify a signature using public key in file\n");
|
||||||
BIO_printf(bio_err,"-prverify file verify a signature using private key in file\n");
|
BIO_printf(bio_err,"-prverify file verify a signature using private key in file\n");
|
||||||
BIO_printf(bio_err,"-keyform arg key file format (PEM or ENGINE)\n");
|
BIO_printf(bio_err,"-keyform arg key file format (PEM or ENGINE)\n");
|
||||||
|
BIO_printf(bio_err,"-out filename output to filename rather than stdout\n");
|
||||||
BIO_printf(bio_err,"-signature file signature to verify\n");
|
BIO_printf(bio_err,"-signature file signature to verify\n");
|
||||||
BIO_printf(bio_err,"-sigopt nm:v signature parameter\n");
|
BIO_printf(bio_err,"-sigopt nm:v signature parameter\n");
|
||||||
BIO_printf(bio_err,"-hmac key create hashed MAC with key\n");
|
BIO_printf(bio_err,"-hmac key create hashed MAC with key\n");
|
||||||
|
BIO_printf(bio_err,"-mac algorithm create MAC (not neccessarily HMAC)\n");
|
||||||
|
BIO_printf(bio_err,"-macopt nm:v MAC algorithm parameters or key\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");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm (default)\n",
|
EVP_MD_do_all_sorted(list_md_fn, bio_err);
|
||||||
LN_md5,LN_md5);
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_md4,LN_md4);
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_md2,LN_md2);
|
|
||||||
#ifndef OPENSSL_NO_SHA
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_sha1,LN_sha1);
|
|
||||||
#ifndef OPENSSL_NO_SHA256
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_sha224,LN_sha224);
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_sha256,LN_sha256);
|
|
||||||
#endif
|
|
||||||
#ifndef OPENSSL_NO_SHA512
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_sha384,LN_sha384);
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_sha512,LN_sha512);
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_mdc2,LN_mdc2);
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
LN_ripemd160,LN_ripemd160);
|
|
||||||
#ifndef OPENSSL_NO_WHIRLPOOL
|
|
||||||
BIO_printf(bio_err,"-%-14s to use the %s message digest algorithm\n",
|
|
||||||
SN_whirlpool,SN_whirlpool);
|
|
||||||
#endif
|
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -371,9 +373,9 @@ int MAIN(int argc, char **argv)
|
|||||||
if (macopts)
|
if (macopts)
|
||||||
{
|
{
|
||||||
char *macopt;
|
char *macopt;
|
||||||
for (i = 0; i < sk_STRING_num(macopts); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(macopts); i++)
|
||||||
{
|
{
|
||||||
macopt = sk_STRING_value(macopts, i);
|
macopt = sk_OPENSSL_STRING_value(macopts, i);
|
||||||
if (pkey_ctrl_string(mac_ctx, macopt) <= 0)
|
if (pkey_ctrl_string(mac_ctx, macopt) <= 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
@@ -398,6 +400,13 @@ int MAIN(int argc, char **argv)
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
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);
|
||||||
|
}
|
||||||
|
|
||||||
if (hmac_key)
|
if (hmac_key)
|
||||||
{
|
{
|
||||||
sigkey = EVP_PKEY_new_mac_key(EVP_PKEY_HMAC, e,
|
sigkey = EVP_PKEY_new_mac_key(EVP_PKEY_HMAC, e,
|
||||||
@@ -430,9 +439,9 @@ int MAIN(int argc, char **argv)
|
|||||||
if (sigopts)
|
if (sigopts)
|
||||||
{
|
{
|
||||||
char *sigopt;
|
char *sigopt;
|
||||||
for (i = 0; i < sk_STRING_num(sigopts); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(sigopts); i++)
|
||||||
{
|
{
|
||||||
sigopt = sk_STRING_value(sigopts, i);
|
sigopt = sk_OPENSSL_STRING_value(sigopts, i);
|
||||||
if (pkey_ctrl_string(pctx, sigopt) <= 0)
|
if (pkey_ctrl_string(pctx, sigopt) <= 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
@@ -537,9 +546,9 @@ end:
|
|||||||
BIO_free_all(out);
|
BIO_free_all(out);
|
||||||
EVP_PKEY_free(sigkey);
|
EVP_PKEY_free(sigkey);
|
||||||
if (sigopts)
|
if (sigopts)
|
||||||
sk_STRING_free(sigopts);
|
sk_OPENSSL_STRING_free(sigopts);
|
||||||
if (macopts)
|
if (macopts)
|
||||||
sk_STRING_free(macopts);
|
sk_OPENSSL_STRING_free(macopts);
|
||||||
if(sigbuf) OPENSSL_free(sigbuf);
|
if(sigbuf) OPENSSL_free(sigbuf);
|
||||||
if (bmd != NULL) BIO_free(bmd);
|
if (bmd != NULL) BIO_free(bmd);
|
||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
@@ -600,7 +609,7 @@ int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
len=BIO_gets(bp,(char *)buf,BUFSIZE);
|
len=BIO_gets(bp,(char *)buf,BUFSIZE);
|
||||||
if (len <0)
|
if ((int)len <0)
|
||||||
{
|
{
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
return 1;
|
return 1;
|
||||||
@@ -608,6 +617,12 @@ int do_fp(BIO *out, unsigned char *buf, BIO *bp, int sep, int binout,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(binout) BIO_write(out, buf, len);
|
if(binout) BIO_write(out, buf, len);
|
||||||
|
else if (sep == 2)
|
||||||
|
{
|
||||||
|
for (i=0; i<(int)len; i++)
|
||||||
|
BIO_printf(out, "%02x",buf[i]);
|
||||||
|
BIO_printf(out, " *%s\n", file);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (sig_name)
|
if (sig_name)
|
||||||
|
|||||||
11
apps/dh.c
11
apps/dh.c
@@ -88,9 +88,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
DH *dh=NULL;
|
DH *dh=NULL;
|
||||||
int i,badops=0,text=0;
|
int i,badops=0,text=0;
|
||||||
BIO *in=NULL,*out=NULL;
|
BIO *in=NULL,*out=NULL;
|
||||||
@@ -189,7 +186,7 @@ bad:
|
|||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
in=BIO_new(BIO_s_file());
|
in=BIO_new(BIO_s_file());
|
||||||
@@ -349,4 +346,10 @@ end:
|
|||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_DH */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -149,9 +149,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
DH *dh=NULL;
|
DH *dh=NULL;
|
||||||
int i,badops=0,text=0;
|
int i,badops=0,text=0;
|
||||||
#ifndef OPENSSL_NO_DSA
|
#ifndef OPENSSL_NO_DSA
|
||||||
@@ -270,7 +267,7 @@ bad:
|
|||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (g && !num)
|
if (g && !num)
|
||||||
@@ -335,7 +332,6 @@ bad:
|
|||||||
BIO_printf(bio_err,"This is going to take a long time\n");
|
BIO_printf(bio_err,"This is going to take a long time\n");
|
||||||
if(!dh || !DH_generate_parameters_ex(dh, num, g, &cb))
|
if(!dh || !DH_generate_parameters_ex(dh, num, g, &cb))
|
||||||
{
|
{
|
||||||
if(dh) DH_free(dh);
|
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
@@ -554,4 +550,10 @@ static int MS_CALLBACK dh_cb(int p, int n, BN_GENCB *cb)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#else /* !OPENSSL_NO_DH */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
10
apps/dsa.c
10
apps/dsa.c
@@ -334,6 +334,7 @@ bad:
|
|||||||
i=PEM_write_bio_DSA_PUBKEY(out,dsa);
|
i=PEM_write_bio_DSA_PUBKEY(out,dsa);
|
||||||
else i=PEM_write_bio_DSAPrivateKey(out,dsa,enc,
|
else i=PEM_write_bio_DSAPrivateKey(out,dsa,enc,
|
||||||
NULL,0,NULL, passout);
|
NULL,0,NULL, passout);
|
||||||
|
#if !defined(OPENSSL_NO_RSA) && !defined(OPENSSL_NO_RC4)
|
||||||
} else if (outformat == FORMAT_MSBLOB || outformat == FORMAT_PVK) {
|
} else if (outformat == FORMAT_MSBLOB || outformat == FORMAT_PVK) {
|
||||||
EVP_PKEY *pk;
|
EVP_PKEY *pk;
|
||||||
pk = EVP_PKEY_new();
|
pk = EVP_PKEY_new();
|
||||||
@@ -345,11 +346,12 @@ bad:
|
|||||||
else
|
else
|
||||||
i = i2b_PrivateKey_bio(out, pk);
|
i = i2b_PrivateKey_bio(out, pk);
|
||||||
EVP_PKEY_free(pk);
|
EVP_PKEY_free(pk);
|
||||||
|
#endif
|
||||||
} else {
|
} else {
|
||||||
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
if (!i)
|
if (i <= 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"unable to write private key\n");
|
BIO_printf(bio_err,"unable to write private key\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
@@ -365,4 +367,10 @@ end:
|
|||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_DSA */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -111,9 +111,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
DSA *dsa=NULL;
|
DSA *dsa=NULL;
|
||||||
int i,badops=0,text=0;
|
int i,badops=0,text=0;
|
||||||
BIO *in=NULL,*out=NULL;
|
BIO *in=NULL,*out=NULL;
|
||||||
@@ -278,7 +275,7 @@ bad:
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (need_rand)
|
if (need_rand)
|
||||||
@@ -329,6 +326,7 @@ bad:
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
BIO_printf(bio_err,"Error, DSA key generation failed\n");
|
BIO_printf(bio_err,"Error, DSA key generation failed\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
@@ -357,12 +355,10 @@ bad:
|
|||||||
if (C)
|
if (C)
|
||||||
{
|
{
|
||||||
unsigned char *data;
|
unsigned char *data;
|
||||||
int l,len,bits_p,bits_q,bits_g;
|
int l,len,bits_p;
|
||||||
|
|
||||||
len=BN_num_bytes(dsa->p);
|
len=BN_num_bytes(dsa->p);
|
||||||
bits_p=BN_num_bits(dsa->p);
|
bits_p=BN_num_bits(dsa->p);
|
||||||
bits_q=BN_num_bits(dsa->q);
|
|
||||||
bits_g=BN_num_bits(dsa->g);
|
|
||||||
data=(unsigned char *)OPENSSL_malloc(len+20);
|
data=(unsigned char *)OPENSSL_malloc(len+20);
|
||||||
if (data == NULL)
|
if (data == NULL)
|
||||||
{
|
{
|
||||||
@@ -434,13 +430,19 @@ bad:
|
|||||||
|
|
||||||
assert(need_rand);
|
assert(need_rand);
|
||||||
if ((dsakey=DSAparams_dup(dsa)) == NULL) goto end;
|
if ((dsakey=DSAparams_dup(dsa)) == NULL) goto end;
|
||||||
if (!DSA_generate_key(dsakey)) goto end;
|
if (!DSA_generate_key(dsakey))
|
||||||
|
{
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
DSA_free(dsakey);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
if (outformat == FORMAT_ASN1)
|
if (outformat == FORMAT_ASN1)
|
||||||
i=i2d_DSAPrivateKey_bio(out,dsakey);
|
i=i2d_DSAPrivateKey_bio(out,dsakey);
|
||||||
else if (outformat == FORMAT_PEM)
|
else if (outformat == FORMAT_PEM)
|
||||||
i=PEM_write_bio_DSAPrivateKey(out,dsakey,NULL,NULL,0,NULL,NULL);
|
i=PEM_write_bio_DSAPrivateKey(out,dsakey,NULL,NULL,0,NULL,NULL);
|
||||||
else {
|
else {
|
||||||
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
||||||
|
DSA_free(dsakey);
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
DSA_free(dsakey);
|
DSA_free(dsakey);
|
||||||
@@ -475,4 +477,10 @@ static int MS_CALLBACK dsa_cb(int p, int n, BN_GENCB *cb)
|
|||||||
#endif
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_DSA */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
11
apps/ec.c
11
apps/ec.c
@@ -85,9 +85,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
int ret = 1;
|
int ret = 1;
|
||||||
EC_KEY *eckey = NULL;
|
EC_KEY *eckey = NULL;
|
||||||
const EC_GROUP *group;
|
const EC_GROUP *group;
|
||||||
@@ -254,7 +251,7 @@ bad:
|
|||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
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))
|
||||||
@@ -400,4 +397,10 @@ end:
|
|||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_EC */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -129,9 +129,6 @@ int MAIN(int argc, char **argv)
|
|||||||
char *infile = NULL, *outfile = NULL, *prog;
|
char *infile = NULL, *outfile = NULL, *prog;
|
||||||
BIO *in = NULL, *out = NULL;
|
BIO *in = NULL, *out = NULL;
|
||||||
int informat, outformat, noout = 0, C = 0, ret = 1;
|
int informat, outformat, noout = 0, C = 0, ret = 1;
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
char *engine = NULL;
|
char *engine = NULL;
|
||||||
|
|
||||||
BIGNUM *ec_p = NULL, *ec_a = NULL, *ec_b = NULL,
|
BIGNUM *ec_p = NULL, *ec_a = NULL, *ec_b = NULL,
|
||||||
@@ -340,7 +337,7 @@ bad:
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (list_curves)
|
if (list_curves)
|
||||||
@@ -725,4 +722,10 @@ static int ecparam_print_var(BIO *out, BIGNUM *in, const char *var,
|
|||||||
BIO_printf(out, "\n\t};\n\n");
|
BIO_printf(out, "\n\t};\n\n");
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_EC */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
24
apps/enc.c
24
apps/enc.c
@@ -101,9 +101,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
static const char magic[]="Salted__";
|
static const char magic[]="Salted__";
|
||||||
char mbuf[sizeof magic-1];
|
char mbuf[sizeof magic-1];
|
||||||
char *strbuf=NULL;
|
char *strbuf=NULL;
|
||||||
@@ -132,6 +129,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *engine = NULL;
|
char *engine = NULL;
|
||||||
#endif
|
#endif
|
||||||
const EVP_MD *dgst=NULL;
|
const EVP_MD *dgst=NULL;
|
||||||
|
int non_fips_allow = 0;
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
|
|
||||||
@@ -243,7 +241,12 @@ int MAIN(int argc, char **argv)
|
|||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
buf[0]='\0';
|
buf[0]='\0';
|
||||||
fgets(buf,sizeof buf,infile);
|
if (!fgets(buf,sizeof buf,infile))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"unable to read key from '%s'\n",
|
||||||
|
file);
|
||||||
|
goto bad;
|
||||||
|
}
|
||||||
fclose(infile);
|
fclose(infile);
|
||||||
i=strlen(buf);
|
i=strlen(buf);
|
||||||
if ((i > 0) &&
|
if ((i > 0) &&
|
||||||
@@ -279,6 +282,8 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
md= *(++argv);
|
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))
|
||||||
{
|
{
|
||||||
@@ -323,7 +328,7 @@ bad:
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (md && (dgst=EVP_get_digestbyname(md)) == NULL)
|
if (md && (dgst=EVP_get_digestbyname(md)) == NULL)
|
||||||
@@ -391,8 +396,10 @@ bad:
|
|||||||
|
|
||||||
if (inf == NULL)
|
if (inf == NULL)
|
||||||
{
|
{
|
||||||
|
#ifndef OPENSSL_NO_SETVBUF_IONBF
|
||||||
if (bufsize != NULL)
|
if (bufsize != NULL)
|
||||||
setvbuf(stdin, (char *)NULL, _IONBF, 0);
|
setvbuf(stdin, (char *)NULL, _IONBF, 0);
|
||||||
|
#endif /* ndef OPENSSL_NO_SETVBUF_IONBF */
|
||||||
BIO_set_fp(in,stdin,BIO_NOCLOSE);
|
BIO_set_fp(in,stdin,BIO_NOCLOSE);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -445,8 +452,10 @@ bad:
|
|||||||
if (outf == NULL)
|
if (outf == NULL)
|
||||||
{
|
{
|
||||||
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
BIO_set_fp(out,stdout,BIO_NOCLOSE);
|
||||||
|
#ifndef OPENSSL_NO_SETVBUF_IONBF
|
||||||
if (bufsize != NULL)
|
if (bufsize != NULL)
|
||||||
setvbuf(stdout, (char *)NULL, _IONBF, 0);
|
setvbuf(stdout, (char *)NULL, _IONBF, 0);
|
||||||
|
#endif /* ndef OPENSSL_NO_SETVBUF_IONBF */
|
||||||
#ifdef OPENSSL_SYS_VMS
|
#ifdef OPENSSL_SYS_VMS
|
||||||
{
|
{
|
||||||
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
BIO *tmpbio = BIO_new(BIO_f_linebuffer());
|
||||||
@@ -583,6 +592,11 @@ bad:
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
BIO_get_cipher_ctx(benc, &ctx);
|
BIO_get_cipher_ctx(benc, &ctx);
|
||||||
|
|
||||||
|
if (non_fips_allow)
|
||||||
|
EVP_CIPHER_CTX_set_flags(ctx,
|
||||||
|
EVP_CIPH_FLAG_NON_FIPS_ALLOW);
|
||||||
|
|
||||||
if (!EVP_CipherInit_ex(ctx, cipher, NULL, NULL, NULL, enc))
|
if (!EVP_CipherInit_ex(ctx, cipher, NULL, NULL, NULL, enc))
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "Error setting cipher %s\n",
|
BIO_printf(bio_err, "Error setting cipher %s\n",
|
||||||
|
|||||||
@@ -200,7 +200,7 @@ static int util_verbose(ENGINE *e, int verbose, BIO *bio_out, const char *indent
|
|||||||
char *desc = NULL;
|
char *desc = NULL;
|
||||||
int flags;
|
int flags;
|
||||||
int xpos = 0;
|
int xpos = 0;
|
||||||
STACK_OF(STRING) *cmds = NULL;
|
STACK_OF(OPENSSL_STRING) *cmds = NULL;
|
||||||
if(!ENGINE_ctrl(e, ENGINE_CTRL_HAS_CTRL_FUNCTION, 0, NULL, NULL) ||
|
if(!ENGINE_ctrl(e, ENGINE_CTRL_HAS_CTRL_FUNCTION, 0, NULL, NULL) ||
|
||||||
((num = ENGINE_ctrl(e, ENGINE_CTRL_GET_FIRST_CMD_TYPE,
|
((num = ENGINE_ctrl(e, ENGINE_CTRL_GET_FIRST_CMD_TYPE,
|
||||||
0, NULL, NULL)) <= 0))
|
0, NULL, NULL)) <= 0))
|
||||||
@@ -211,7 +211,7 @@ static int util_verbose(ENGINE *e, int verbose, BIO *bio_out, const char *indent
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
cmds = sk_STRING_new_null();
|
cmds = sk_OPENSSL_STRING_new_null();
|
||||||
|
|
||||||
if(!cmds)
|
if(!cmds)
|
||||||
goto err;
|
goto err;
|
||||||
@@ -284,16 +284,16 @@ static int util_verbose(ENGINE *e, int verbose, BIO *bio_out, const char *indent
|
|||||||
BIO_printf(bio_out, "\n");
|
BIO_printf(bio_out, "\n");
|
||||||
ret = 1;
|
ret = 1;
|
||||||
err:
|
err:
|
||||||
if(cmds) sk_STRING_pop_free(cmds, identity);
|
if(cmds) sk_OPENSSL_STRING_pop_free(cmds, identity);
|
||||||
if(name) OPENSSL_free(name);
|
if(name) OPENSSL_free(name);
|
||||||
if(desc) OPENSSL_free(desc);
|
if(desc) OPENSSL_free(desc);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void util_do_cmds(ENGINE *e, STACK_OF(STRING) *cmds, BIO *bio_out,
|
static void util_do_cmds(ENGINE *e, STACK_OF(OPENSSL_STRING) *cmds,
|
||||||
const char *indent)
|
BIO *bio_out, const char *indent)
|
||||||
{
|
{
|
||||||
int loop, res, num = sk_STRING_num(cmds);
|
int loop, res, num = sk_OPENSSL_STRING_num(cmds);
|
||||||
|
|
||||||
if(num < 0)
|
if(num < 0)
|
||||||
{
|
{
|
||||||
@@ -304,7 +304,7 @@ static void util_do_cmds(ENGINE *e, STACK_OF(STRING) *cmds, BIO *bio_out,
|
|||||||
{
|
{
|
||||||
char buf[256];
|
char buf[256];
|
||||||
const char *cmd, *arg;
|
const char *cmd, *arg;
|
||||||
cmd = sk_STRING_value(cmds, loop);
|
cmd = sk_OPENSSL_STRING_value(cmds, loop);
|
||||||
res = 1; /* assume success */
|
res = 1; /* assume success */
|
||||||
/* Check if this command has no ":arg" */
|
/* Check if this command has no ":arg" */
|
||||||
if((arg = strstr(cmd, ":")) == NULL)
|
if((arg = strstr(cmd, ":")) == NULL)
|
||||||
@@ -344,9 +344,9 @@ int MAIN(int argc, char **argv)
|
|||||||
const char **pp;
|
const char **pp;
|
||||||
int verbose=0, list_cap=0, test_avail=0, test_avail_noise = 0;
|
int verbose=0, list_cap=0, test_avail=0, test_avail_noise = 0;
|
||||||
ENGINE *e;
|
ENGINE *e;
|
||||||
STACK_OF(STRING) *engines = sk_STRING_new_null();
|
STACK_OF(OPENSSL_STRING) *engines = sk_OPENSSL_STRING_new_null();
|
||||||
STACK_OF(STRING) *pre_cmds = sk_STRING_new_null();
|
STACK_OF(OPENSSL_STRING) *pre_cmds = sk_OPENSSL_STRING_new_null();
|
||||||
STACK_OF(STRING) *post_cmds = sk_STRING_new_null();
|
STACK_OF(OPENSSL_STRING) *post_cmds = sk_OPENSSL_STRING_new_null();
|
||||||
int badops=1;
|
int badops=1;
|
||||||
BIO *bio_out=NULL;
|
BIO *bio_out=NULL;
|
||||||
const char *indent = " ";
|
const char *indent = " ";
|
||||||
@@ -393,20 +393,20 @@ int MAIN(int argc, char **argv)
|
|||||||
argc--; argv++;
|
argc--; argv++;
|
||||||
if (argc == 0)
|
if (argc == 0)
|
||||||
goto skip_arg_loop;
|
goto skip_arg_loop;
|
||||||
sk_STRING_push(pre_cmds,*argv);
|
sk_OPENSSL_STRING_push(pre_cmds,*argv);
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-post") == 0)
|
else if (strcmp(*argv,"-post") == 0)
|
||||||
{
|
{
|
||||||
argc--; argv++;
|
argc--; argv++;
|
||||||
if (argc == 0)
|
if (argc == 0)
|
||||||
goto skip_arg_loop;
|
goto skip_arg_loop;
|
||||||
sk_STRING_push(post_cmds,*argv);
|
sk_OPENSSL_STRING_push(post_cmds,*argv);
|
||||||
}
|
}
|
||||||
else if ((strncmp(*argv,"-h",2) == 0) ||
|
else if ((strncmp(*argv,"-h",2) == 0) ||
|
||||||
(strcmp(*argv,"-?") == 0))
|
(strcmp(*argv,"-?") == 0))
|
||||||
goto skip_arg_loop;
|
goto skip_arg_loop;
|
||||||
else
|
else
|
||||||
sk_STRING_push(engines,*argv);
|
sk_OPENSSL_STRING_push(engines,*argv);
|
||||||
argc--;
|
argc--;
|
||||||
argv++;
|
argv++;
|
||||||
}
|
}
|
||||||
@@ -421,17 +421,17 @@ skip_arg_loop:
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sk_STRING_num(engines) == 0)
|
if (sk_OPENSSL_STRING_num(engines) == 0)
|
||||||
{
|
{
|
||||||
for(e = ENGINE_get_first(); e != NULL; e = ENGINE_get_next(e))
|
for(e = ENGINE_get_first(); e != NULL; e = ENGINE_get_next(e))
|
||||||
{
|
{
|
||||||
sk_STRING_push(engines,(char *)ENGINE_get_id(e));
|
sk_OPENSSL_STRING_push(engines,(char *)ENGINE_get_id(e));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (i=0; i<sk_STRING_num(engines); i++)
|
for (i=0; i<sk_OPENSSL_STRING_num(engines); i++)
|
||||||
{
|
{
|
||||||
const char *id = sk_STRING_value(engines,i);
|
const char *id = sk_OPENSSL_STRING_value(engines,i);
|
||||||
if ((e = ENGINE_by_id(id)) != NULL)
|
if ((e = ENGINE_by_id(id)) != NULL)
|
||||||
{
|
{
|
||||||
const char *name = ENGINE_get_name(e);
|
const char *name = ENGINE_get_name(e);
|
||||||
@@ -533,9 +533,9 @@ skip_pmeths:
|
|||||||
end:
|
end:
|
||||||
|
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
sk_STRING_pop_free(engines, identity);
|
sk_OPENSSL_STRING_pop_free(engines, identity);
|
||||||
sk_STRING_pop_free(pre_cmds, identity);
|
sk_OPENSSL_STRING_pop_free(pre_cmds, identity);
|
||||||
sk_STRING_pop_free(post_cmds, identity);
|
sk_OPENSSL_STRING_pop_free(post_cmds, identity);
|
||||||
if (bio_out != NULL) BIO_free_all(bio_out);
|
if (bio_out != NULL) BIO_free_all(bio_out);
|
||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
|
|||||||
11
apps/gendh.c
11
apps/gendh.c
@@ -89,9 +89,6 @@ int MAIN(int, char **);
|
|||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
BN_GENCB cb;
|
BN_GENCB cb;
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
DH *dh=NULL;
|
DH *dh=NULL;
|
||||||
int ret=1,num=DEFBITS;
|
int ret=1,num=DEFBITS;
|
||||||
int g=2;
|
int g=2;
|
||||||
@@ -163,7 +160,7 @@ bad:
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
out=BIO_new(BIO_s_file());
|
out=BIO_new(BIO_s_file());
|
||||||
@@ -235,4 +232,10 @@ static int MS_CALLBACK dh_cb(int p, int n, BN_GENCB *cb)
|
|||||||
#endif
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_DH */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -78,9 +78,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
DSA *dsa=NULL;
|
DSA *dsa=NULL;
|
||||||
int ret=1;
|
int ret=1;
|
||||||
char *outfile=NULL;
|
char *outfile=NULL;
|
||||||
@@ -206,7 +203,7 @@ bad:
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if(!app_passwd(bio_err, NULL, passargout, NULL, &passout)) {
|
if(!app_passwd(bio_err, NULL, passargout, NULL, &passout)) {
|
||||||
@@ -279,4 +276,10 @@ end:
|
|||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
#else /* !OPENSSL_NO_DSA */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -78,7 +78,7 @@
|
|||||||
#include <openssl/pem.h>
|
#include <openssl/pem.h>
|
||||||
#include <openssl/rand.h>
|
#include <openssl/rand.h>
|
||||||
|
|
||||||
#define DEFBITS 512
|
#define DEFBITS 1024
|
||||||
#undef PROG
|
#undef PROG
|
||||||
#define PROG genrsa_main
|
#define PROG genrsa_main
|
||||||
|
|
||||||
@@ -105,9 +105,9 @@ int MAIN(int argc, char **argv)
|
|||||||
char *inrand=NULL;
|
char *inrand=NULL;
|
||||||
BIO *out=NULL;
|
BIO *out=NULL;
|
||||||
BIGNUM *bn = BN_new();
|
BIGNUM *bn = BN_new();
|
||||||
RSA *rsa = RSA_new();
|
RSA *rsa = NULL;
|
||||||
|
|
||||||
if(!bn || !rsa) goto err;
|
if(!bn) goto err;
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
BN_GENCB_set(&cb, genrsa_cb, bio_err);
|
BN_GENCB_set(&cb, genrsa_cb, bio_err);
|
||||||
@@ -265,6 +265,13 @@ 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);
|
||||||
|
#ifdef OPENSSL_NO_ENGINE
|
||||||
|
rsa = RSA_new();
|
||||||
|
#else
|
||||||
|
rsa = RSA_new_method(e);
|
||||||
|
#endif
|
||||||
|
if (!rsa)
|
||||||
|
goto err;
|
||||||
|
|
||||||
if(!BN_set_word(bn, f4) || !RSA_generate_key_ex(rsa, num, bn, &cb))
|
if(!BN_set_word(bn, f4) || !RSA_generate_key_ex(rsa, num, bn, &cb))
|
||||||
goto err;
|
goto err;
|
||||||
|
|||||||
107
apps/install-apps.com
Executable file
107
apps/install-apps.com
Executable file
@@ -0,0 +1,107 @@
|
|||||||
|
$! INSTALL.COM -- Installs the files in a given directory tree
|
||||||
|
$!
|
||||||
|
$! Author: Richard Levitte <richard@levitte.org>
|
||||||
|
$! Time of creation: 22-MAY-1998 10:13
|
||||||
|
$!
|
||||||
|
$! P1 root of the directory tree
|
||||||
|
$! P2 "64" for 64-bit pointers.
|
||||||
|
$!
|
||||||
|
$!
|
||||||
|
$! Announce/identify.
|
||||||
|
$!
|
||||||
|
$ proc = f$environment( "procedure")
|
||||||
|
$ write sys$output "@@@ "+ -
|
||||||
|
f$parse( proc, , , "name")+ f$parse( proc, , , "type")
|
||||||
|
$!
|
||||||
|
$ on error then goto tidy
|
||||||
|
$ on control_c then goto tidy
|
||||||
|
$!
|
||||||
|
$ if (p1 .eqs. "")
|
||||||
|
$ then
|
||||||
|
$ write sys$output "First argument missing."
|
||||||
|
$ write sys$output -
|
||||||
|
"It should be the directory where you want things installed."
|
||||||
|
$ exit
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ if (f$getsyi("cpu") .lt. 128)
|
||||||
|
$ then
|
||||||
|
$ arch = "VAX"
|
||||||
|
$ else
|
||||||
|
$ arch = f$edit( f$getsyi( "arch_name"), "upcase")
|
||||||
|
$ if (arch .eqs. "") then arch = "UNK"
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ archd = arch
|
||||||
|
$!
|
||||||
|
$ if (p2 .nes. "")
|
||||||
|
$ then
|
||||||
|
$ if (p2 .eqs. "64")
|
||||||
|
$ then
|
||||||
|
$ archd = arch+ "_64"
|
||||||
|
$ else
|
||||||
|
$ if (p2 .nes. "32")
|
||||||
|
$ then
|
||||||
|
$ write sys$output "Second argument invalid."
|
||||||
|
$ write sys$output "It should be "32", "64", or nothing."
|
||||||
|
$ exit
|
||||||
|
$ endif
|
||||||
|
$ endif
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ root = f$parse( p1, "[]A.;0", , , "syntax_only, no_conceal") - "A.;0"
|
||||||
|
$ root_dev = f$parse(root,,,"device","syntax_only")
|
||||||
|
$ root_dir = f$parse(root,,,"directory","syntax_only") - -
|
||||||
|
"[000000." - "][" - "[" - "]"
|
||||||
|
$ root = root_dev + "[" + root_dir
|
||||||
|
$!
|
||||||
|
$ define /nolog wrk_sslroot 'root'.] /trans=conc
|
||||||
|
$ define /nolog wrk_sslxexe wrk_sslroot:['archd'_exe]
|
||||||
|
$!
|
||||||
|
$ if f$parse("wrk_sslroot:[000000]") .eqs. "" then -
|
||||||
|
create /directory /log wrk_sslroot:[000000]
|
||||||
|
$ if f$parse("wrk_sslxexe:") .eqs. "" then -
|
||||||
|
create /directory /log wrk_sslxexe:
|
||||||
|
$!
|
||||||
|
$ exe := openssl
|
||||||
|
$!
|
||||||
|
$ exe_dir := [-.'archd'.exe.apps]
|
||||||
|
$!
|
||||||
|
$! Executables.
|
||||||
|
$!
|
||||||
|
$ i = 0
|
||||||
|
$ loop_exe:
|
||||||
|
$ e = f$edit(f$element( i, ",", exe), "trim")
|
||||||
|
$ i = i + 1
|
||||||
|
$ if e .eqs. "," then goto loop_exe_end
|
||||||
|
$ set noon
|
||||||
|
$ file = exe_dir+ e+ ".exe"
|
||||||
|
$ if f$search( file) .nes. ""
|
||||||
|
$ then
|
||||||
|
$ copy /protection = w:re 'file' wrk_sslxexe: /log
|
||||||
|
$ endif
|
||||||
|
$ set on
|
||||||
|
$ goto loop_exe
|
||||||
|
$ loop_exe_end:
|
||||||
|
$!
|
||||||
|
$! Miscellaneous.
|
||||||
|
$!
|
||||||
|
$ set noon
|
||||||
|
$ copy /protection = w:re ca.com wrk_sslxexe:ca.com /log
|
||||||
|
$ copy /protection = w:re openssl-vms.cnf wrk_sslroot:[000000]openssl.cnf /log
|
||||||
|
$ set on
|
||||||
|
$!
|
||||||
|
$ tidy:
|
||||||
|
$!
|
||||||
|
$ call deass wrk_sslroot
|
||||||
|
$ call deass wrk_sslxexe
|
||||||
|
$!
|
||||||
|
$ exit
|
||||||
|
$!
|
||||||
|
$ deass: subroutine
|
||||||
|
$ if (f$trnlnm( p1, "LNM$PROCESS") .nes. "")
|
||||||
|
$ then
|
||||||
|
$ deassign /process 'p1'
|
||||||
|
$ endif
|
||||||
|
$ endsubroutine
|
||||||
|
$!
|
||||||
@@ -1,69 +0,0 @@
|
|||||||
$! INSTALL.COM -- Installs the files in a given directory tree
|
|
||||||
$!
|
|
||||||
$! Author: Richard Levitte <richard@levitte.org>
|
|
||||||
$! Time of creation: 22-MAY-1998 10:13
|
|
||||||
$!
|
|
||||||
$! P1 root of the directory tree
|
|
||||||
$!
|
|
||||||
$ IF P1 .EQS. ""
|
|
||||||
$ THEN
|
|
||||||
$ WRITE SYS$OUTPUT "First argument missing."
|
|
||||||
$ WRITE SYS$OUTPUT "Should be the directory where you want things installed."
|
|
||||||
$ EXIT
|
|
||||||
$ ENDIF
|
|
||||||
$
|
|
||||||
$ ROOT = F$PARSE(P1,"[]A.;0",,,"SYNTAX_ONLY,NO_CONCEAL") - "A.;0"
|
|
||||||
$ ROOT_DEV = F$PARSE(ROOT,,,"DEVICE","SYNTAX_ONLY")
|
|
||||||
$ ROOT_DIR = F$PARSE(ROOT,,,"DIRECTORY","SYNTAX_ONLY") -
|
|
||||||
- "[000000." - "][" - "[" - "]"
|
|
||||||
$ ROOT = ROOT_DEV + "[" + ROOT_DIR
|
|
||||||
$
|
|
||||||
$ DEFINE/NOLOG WRK_SSLROOT 'ROOT'.] /TRANS=CONC
|
|
||||||
$ DEFINE/NOLOG WRK_SSLVEXE WRK_SSLROOT:[VAX_EXE]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLAEXE WRK_SSLROOT:[ALPHA_EXE]
|
|
||||||
$ DEFINE/NOLOG WRK_SSLLIB WRK_SSLROOT:[LIB]
|
|
||||||
$
|
|
||||||
$ IF F$PARSE("WRK_SSLROOT:[000000]") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLROOT:[000000]
|
|
||||||
$ IF F$PARSE("WRK_SSLVEXE:") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLVEXE:
|
|
||||||
$ IF F$PARSE("WRK_SSLAEXE:") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLAEXE:
|
|
||||||
$ IF F$PARSE("WRK_SSLLIB:") .EQS. "" THEN -
|
|
||||||
CREATE/DIR/LOG WRK_SSLLIB:
|
|
||||||
$
|
|
||||||
$ EXE := openssl
|
|
||||||
$
|
|
||||||
$ VEXE_DIR := [-.VAX.EXE.APPS]
|
|
||||||
$ AEXE_DIR := [-.AXP.EXE.APPS]
|
|
||||||
$
|
|
||||||
$ I = 0
|
|
||||||
$ LOOP_EXE:
|
|
||||||
$ E = F$EDIT(F$ELEMENT(I, ",", EXE),"TRIM")
|
|
||||||
$ I = I + 1
|
|
||||||
$ IF E .EQS. "," THEN GOTO LOOP_EXE_END
|
|
||||||
$ SET NOON
|
|
||||||
$ IF F$SEARCH(VEXE_DIR+E+".EXE") .NES. ""
|
|
||||||
$ THEN
|
|
||||||
$ COPY 'VEXE_DIR''E'.EXE WRK_SSLVEXE:'E'.EXE/log
|
|
||||||
$ SET FILE/PROT=W:RE WRK_SSLVEXE:'E'.EXE
|
|
||||||
$ ENDIF
|
|
||||||
$ IF F$SEARCH(AEXE_DIR+E+".EXE") .NES. ""
|
|
||||||
$ THEN
|
|
||||||
$ COPY 'AEXE_DIR''E'.EXE WRK_SSLAEXE:'E'.EXE/log
|
|
||||||
$ SET FILE/PROT=W:RE WRK_SSLAEXE:'E'.EXE
|
|
||||||
$ ENDIF
|
|
||||||
$ SET ON
|
|
||||||
$ GOTO LOOP_EXE
|
|
||||||
$ LOOP_EXE_END:
|
|
||||||
$
|
|
||||||
$ SET NOON
|
|
||||||
$ COPY CA.COM WRK_SSLAEXE:CA.COM/LOG
|
|
||||||
$ SET FILE/PROT=W:RE WRK_SSLAEXE:CA.COM
|
|
||||||
$ COPY CA.COM WRK_SSLVEXE:CA.COM/LOG
|
|
||||||
$ SET FILE/PROT=W:RE WRK_SSLVEXE:CA.COM
|
|
||||||
$ COPY OPENSSL-VMS.CNF WRK_SSLROOT:[000000]OPENSSL.CNF/LOG
|
|
||||||
$ SET FILE/PROT=W:R WRK_SSLROOT:[000000]OPENSSL.CNF
|
|
||||||
$ SET ON
|
|
||||||
$
|
|
||||||
$ EXIT
|
|
||||||
@@ -6,11 +6,12 @@ $! A-Com Computing, Inc.
|
|||||||
$! byer@mail.all-net.net
|
$! byer@mail.all-net.net
|
||||||
$!
|
$!
|
||||||
$! Changes by Richard Levitte <richard@levitte.org>
|
$! Changes by Richard Levitte <richard@levitte.org>
|
||||||
|
$! Zoltan Arpadffy <zoli@polarhome.com>
|
||||||
$!
|
$!
|
||||||
$! This command files compiles and creates all the various different
|
$! This command files compiles and creates all the various different
|
||||||
$! "application" programs for the different types of encryption for OpenSSL.
|
$! "application" programs for the different types of encryption for OpenSSL.
|
||||||
$! The EXE's are placed in the directory [.xxx.EXE.APPS] where "xxx" denotes
|
$! The EXE's are placed in the directory [.xxx.EXE.APPS] where "xxx" denotes
|
||||||
$! either AXP or VAX depending on your machine architecture.
|
$! ALPHA, IA64 or VAX, depending on your machine architecture.
|
||||||
$!
|
$!
|
||||||
$! It was written so it would try to determine what "C" compiler to
|
$! It was written so it would try to determine what "C" compiler to
|
||||||
$! use or you can specify which "C" compiler to use.
|
$! use or you can specify which "C" compiler to use.
|
||||||
@@ -24,7 +25,7 @@ $! VAXC For VAX C.
|
|||||||
$! DECC For DEC C.
|
$! DECC For DEC C.
|
||||||
$! GNUC For GNU C.
|
$! GNUC For GNU C.
|
||||||
$!
|
$!
|
||||||
$! If you don't speficy a compiler, it will try to determine which
|
$! If you don't specify a compiler, it will try to determine which
|
||||||
$! "C" compiler to use.
|
$! "C" compiler to use.
|
||||||
$!
|
$!
|
||||||
$! P3, if defined, sets a TCP/IP library to use, through one of the following
|
$! P3, if defined, sets a TCP/IP library to use, through one of the following
|
||||||
@@ -38,33 +39,63 @@ $! P4, if defined, sets a compiler thread NOT needed on OpenVMS 7.1 (and up)
|
|||||||
$!
|
$!
|
||||||
$! P5, if defined, sets a choice of programs to compile.
|
$! P5, if defined, sets a choice of programs to compile.
|
||||||
$!
|
$!
|
||||||
|
$! P6, if defined, specifies the C pointer size. Ignored on VAX.
|
||||||
|
$! ("64=ARGV" gives more efficient code with HP C V7.3 or newer.)
|
||||||
|
$! Supported values are:
|
||||||
|
$!
|
||||||
|
$! "" Compile with default (/NOPOINTER_SIZE)
|
||||||
|
$! 32 Compile with /POINTER_SIZE=32 (SHORT)
|
||||||
|
$! 64 Compile with /POINTER_SIZE=64[=ARGV] (LONG[=ARGV])
|
||||||
|
$! (Automatically select ARGV if compiler supports it.)
|
||||||
|
$! 64= Compile with /POINTER_SIZE=64 (LONG).
|
||||||
|
$! 64=ARGV Compile with /POINTER_SIZE=64=ARGV (LONG=ARGV).
|
||||||
|
$!
|
||||||
|
$! P7, if defined, specifies a directory where ZLIB files (zlib.h,
|
||||||
|
$! libz.olb) may be found. Optionally, a non-default object library
|
||||||
|
$! name may be included ("dev:[dir]libz_64.olb", for example).
|
||||||
|
$!
|
||||||
|
$!
|
||||||
|
$! Announce/identify.
|
||||||
|
$!
|
||||||
|
$ proc = f$environment( "procedure")
|
||||||
|
$ write sys$output "@@@ "+ -
|
||||||
|
f$parse( proc, , , "name")+ f$parse( proc, , , "type")
|
||||||
|
$!
|
||||||
|
$ on control_c then goto exit
|
||||||
$!
|
$!
|
||||||
$! Define A TCP/IP Library That We Will Need To Link To.
|
$! Define A TCP/IP Library That We Will Need To Link To.
|
||||||
$! (That Is, If We Need To Link To One.)
|
$! (That Is, If We Need To Link To One.)
|
||||||
$!
|
$!
|
||||||
$ TCPIP_LIB = ""
|
$ TCPIP_LIB = ""
|
||||||
|
$ ZLIB_LIB = ""
|
||||||
$!
|
$!
|
||||||
$! Check What Architecture We Are Using.
|
$! Check What Architecture We Are Using.
|
||||||
$!
|
$!
|
||||||
$ IF (F$GETSYI("CPU").GE.128)
|
$ IF (F$GETSYI("CPU").LT.128)
|
||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$! The Architecture Is AXP.
|
$! The Architecture Is VAX.
|
||||||
$!
|
$!
|
||||||
$ ARCH := AXP
|
$ ARCH = "VAX"
|
||||||
$!
|
$!
|
||||||
$! Else...
|
$! Else...
|
||||||
$!
|
$!
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$!
|
$!
|
||||||
$! The Architecture Is VAX.
|
$! The Architecture Is Alpha, IA64 or whatever comes in the future.
|
||||||
$!
|
$!
|
||||||
$ ARCH := VAX
|
$ ARCH = F$EDIT( F$GETSYI( "ARCH_NAME"), "UPCASE")
|
||||||
|
$ IF (ARCH .EQS. "") THEN ARCH = "UNK"
|
||||||
$!
|
$!
|
||||||
$! End The Architecture Check.
|
$! End The Architecture Check.
|
||||||
$!
|
$!
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
|
$ ARCHD = ARCH
|
||||||
|
$ LIB32 = "32"
|
||||||
|
$ OPT_FILE = ""
|
||||||
|
$ POINTER_SIZE = ""
|
||||||
|
$!
|
||||||
$! Define what programs should be compiled
|
$! Define what programs should be compiled
|
||||||
$!
|
$!
|
||||||
$ PROGRAMS := OPENSSL
|
$ PROGRAMS := OPENSSL
|
||||||
@@ -73,25 +104,40 @@ $! Check To Make Sure We Have Valid Command Line Parameters.
|
|||||||
$!
|
$!
|
||||||
$ GOSUB CHECK_OPTIONS
|
$ GOSUB CHECK_OPTIONS
|
||||||
$!
|
$!
|
||||||
|
$! Define The CRYPTO Library.
|
||||||
|
$!
|
||||||
|
$ CRYPTO_LIB := SYS$DISK:[-.'ARCHD'.EXE.CRYPTO]SSL_LIBCRYPTO'LIB32'.OLB
|
||||||
|
$!
|
||||||
|
$! Define The SSL Library.
|
||||||
|
$!
|
||||||
|
$ SSL_LIB := SYS$DISK:[-.'ARCHD'.EXE.SSL]SSL_LIBSSL'LIB32'.OLB
|
||||||
|
$!
|
||||||
|
$! Define The OBJ and EXE Directories.
|
||||||
|
$!
|
||||||
|
$ OBJ_DIR := SYS$DISK:[-.'ARCHD'.OBJ.APPS]
|
||||||
|
$ EXE_DIR := SYS$DISK:[-.'ARCHD'.EXE.APPS]
|
||||||
|
$!
|
||||||
|
$! Specify the destination directory in any /MAP option.
|
||||||
|
$!
|
||||||
|
$ if (LINKMAP .eqs. "MAP")
|
||||||
|
$ then
|
||||||
|
$ LINKMAP = LINKMAP+ "=''EXE_DIR'"
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$! Add the location prefix to the linker options file name.
|
||||||
|
$!
|
||||||
|
$ if (OPT_FILE .nes. "")
|
||||||
|
$ then
|
||||||
|
$ OPT_FILE = EXE_DIR+ OPT_FILE
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
$! Initialise logical names and such
|
$! Initialise logical names and such
|
||||||
$!
|
$!
|
||||||
$ GOSUB INITIALISE
|
$ GOSUB INITIALISE
|
||||||
$!
|
$!
|
||||||
$! Tell The User What Kind of Machine We Run On.
|
$! Tell The User What Kind of Machine We Run On.
|
||||||
$!
|
$!
|
||||||
$ WRITE SYS$OUTPUT "Compiling On A ",ARCH," Machine."
|
$ WRITE SYS$OUTPUT "Host system architecture: ''ARCHD'"
|
||||||
$!
|
|
||||||
$! Define The CRYPTO Library.
|
|
||||||
$!
|
|
||||||
$ CRYPTO_LIB := SYS$DISK:[-.'ARCH'.EXE.CRYPTO]LIBCRYPTO.OLB
|
|
||||||
$!
|
|
||||||
$! Define The SSL Library.
|
|
||||||
$!
|
|
||||||
$ SSL_LIB := SYS$DISK:[-.'ARCH'.EXE.SSL]LIBSSL.OLB
|
|
||||||
$!
|
|
||||||
$! Define The OBJ Directory.
|
|
||||||
$!
|
|
||||||
$ OBJ_DIR := SYS$DISK:[-.'ARCH'.OBJ.APPS]
|
|
||||||
$!
|
$!
|
||||||
$! Check To See If The OBJ Directory Exists.
|
$! Check To See If The OBJ Directory Exists.
|
||||||
$!
|
$!
|
||||||
@@ -106,10 +152,6 @@ $! End The OBJ Directory Check.
|
|||||||
$!
|
$!
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
$! Define The EXE Directory.
|
|
||||||
$!
|
|
||||||
$ EXE_DIR := SYS$DISK:[-.'ARCH'.EXE.APPS]
|
|
||||||
$!
|
|
||||||
$! Check To See If The EXE Directory Exists.
|
$! Check To See If The EXE Directory Exists.
|
||||||
$!
|
$!
|
||||||
$ IF (F$PARSE(EXE_DIR).EQS."")
|
$ IF (F$PARSE(EXE_DIR).EQS."")
|
||||||
@@ -132,6 +174,9 @@ $!
|
|||||||
$ GOSUB CHECK_OPT_FILE
|
$ GOSUB CHECK_OPT_FILE
|
||||||
$!
|
$!
|
||||||
$! Define The Application Files.
|
$! Define The Application Files.
|
||||||
|
$! NOTE: Some might think this list ugly. However, it's made this way to
|
||||||
|
$! reflect the E_OBJ variable in Makefile as closely as possible, thereby
|
||||||
|
$! making it fairly easy to verify that the lists are the same.
|
||||||
$!
|
$!
|
||||||
$ LIB_OPENSSL = "VERIFY,ASN1PARS,REQ,DGST,DH,DHPARAM,ENC,PASSWD,GENDH,ERRSTR,"+-
|
$ LIB_OPENSSL = "VERIFY,ASN1PARS,REQ,DGST,DH,DHPARAM,ENC,PASSWD,GENDH,ERRSTR,"+-
|
||||||
"CA,PKCS7,CRL2P7,CRL,"+-
|
"CA,PKCS7,CRL2P7,CRL,"+-
|
||||||
@@ -139,14 +184,17 @@ $ LIB_OPENSSL = "VERIFY,ASN1PARS,REQ,DGST,DH,DHPARAM,ENC,PASSWD,GENDH,ERRSTR,"+-
|
|||||||
"X509,GENRSA,GENDSA,GENPKEY,S_SERVER,S_CLIENT,SPEED,"+-
|
"X509,GENRSA,GENDSA,GENPKEY,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,PKEY,PKEYPARAM,PKEYUTL,"+ -
|
"CIPHERS,NSEQ,PKCS12,PKCS8,PKEY,PKEYPARAM,PKEYUTL,"+ -
|
||||||
"SPKAC,SMIME,CMS,RAND,ENGINE,OCSP,PRIME,TS"
|
"SPKAC,SMIME,CMS,RAND,ENGINE,OCSP,PRIME,TS,SRP"
|
||||||
|
$!
|
||||||
|
$ LIB_OPENSSL = LIB_OPENSSL+ ",VMS_DECC_INIT"
|
||||||
|
$!
|
||||||
$ TCPIP_PROGRAMS = ",,"
|
$ TCPIP_PROGRAMS = ",,"
|
||||||
$ IF COMPILER .EQS. "VAXC" THEN -
|
$ IF COMPILER .EQS. "VAXC" THEN -
|
||||||
TCPIP_PROGRAMS = ",OPENSSL,"
|
TCPIP_PROGRAMS = ",OPENSSL,"
|
||||||
$!
|
$!
|
||||||
$! Setup exceptional compilations
|
$! Setup exceptional compilations
|
||||||
$!
|
$!
|
||||||
$ COMPILEWITH_CC2 = ",S_SERVER,S_CLIENT,"
|
$ COMPILEWITH_CC2 = ",S_SOCKET,S_SERVER,S_CLIENT,"
|
||||||
$!
|
$!
|
||||||
$ PHASE := LIB
|
$ PHASE := LIB
|
||||||
$!
|
$!
|
||||||
@@ -164,6 +212,10 @@ $! Make The Application File Name
|
|||||||
$!
|
$!
|
||||||
$ CURRENT_APP = F$EDIT(F$ELEMENT(APP_COUNTER,",",PROGRAMS),"TRIM")
|
$ CURRENT_APP = F$EDIT(F$ELEMENT(APP_COUNTER,",",PROGRAMS),"TRIM")
|
||||||
$!
|
$!
|
||||||
|
$! Create The Executable File Name.
|
||||||
|
$!
|
||||||
|
$ EXE_FILE = EXE_DIR + CURRENT_APP + ".EXE"
|
||||||
|
$!
|
||||||
$! Check To See If We Are At The End Of The File List.
|
$! Check To See If We Are At The End Of The File List.
|
||||||
$!
|
$!
|
||||||
$ IF (CURRENT_APP.EQS.",")
|
$ IF (CURRENT_APP.EQS.",")
|
||||||
@@ -193,7 +245,7 @@ $ LIB_COUNTER = -1
|
|||||||
$!
|
$!
|
||||||
$! Create a .OPT file for the object files
|
$! Create a .OPT file for the object files
|
||||||
$!
|
$!
|
||||||
$ OPEN/WRITE OBJECTS 'EXE_DIR''CURRENT_APP'.OPT
|
$ OPEN /WRITE OBJECTS 'EXE_DIR''CURRENT_APP'.OPT
|
||||||
$!
|
$!
|
||||||
$! Top Of The File Loop.
|
$! Top Of The File Loop.
|
||||||
$!
|
$!
|
||||||
@@ -227,10 +279,6 @@ $!
|
|||||||
$! Create The Object File Name.
|
$! Create The Object File Name.
|
||||||
$!
|
$!
|
||||||
$ OBJECT_FILE = OBJ_DIR + FILE_NAME + ".OBJ"
|
$ OBJECT_FILE = OBJ_DIR + FILE_NAME + ".OBJ"
|
||||||
$!
|
|
||||||
$! Create The Executable File Name.
|
|
||||||
$!
|
|
||||||
$ EXE_FILE = EXE_DIR + FILE_NAME + ".EXE"
|
|
||||||
$ ON WARNING THEN GOTO NEXT_LIB
|
$ ON WARNING THEN GOTO NEXT_LIB
|
||||||
$!
|
$!
|
||||||
$! Check To See If The File We Want To Compile Actually Exists.
|
$! Check To See If The File We Want To Compile Actually Exists.
|
||||||
@@ -284,34 +332,18 @@ $ GOTO NEXT_APP
|
|||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
$! Link The Program.
|
$! Link The Program.
|
||||||
$! Check To See If We Are To Link With A Specific TCP/IP Library.
|
|
||||||
$!
|
$!
|
||||||
$ ON WARNING THEN GOTO NEXT_APP
|
$ ON WARNING THEN GOTO NEXT_APP
|
||||||
$!
|
$!
|
||||||
$ IF (TCPIP_LIB.NES."")
|
|
||||||
$ THEN
|
|
||||||
$!
|
|
||||||
$! Don't Link With The RSAREF Routines And TCP/IP Library.
|
$! Don't Link With The RSAREF Routines And TCP/IP Library.
|
||||||
$!
|
$!
|
||||||
$ LINK/'DEBUGGER'/'TRACEBACK' /EXE='EXE_FILE' -
|
$ LINK /'DEBUGGER' /'LINKMAP' /'TRACEBACK' /EXE='EXE_FILE' -
|
||||||
'EXE_DIR''CURRENT_APP'.OPT/OPTION, -
|
'EXE_DIR''CURRENT_APP'.OPT /OPTIONS, -
|
||||||
'SSL_LIB'/LIBRARY,'CRYPTO_LIB'/LIBRARY, -
|
'SSL_LIB' /LIBRARY, -
|
||||||
'TCPIP_LIB','OPT_FILE'/OPTION
|
'CRYPTO_LIB' /LIBRARY -
|
||||||
$!
|
'TCPIP_LIB' -
|
||||||
$! Else...
|
'ZLIB_LIB' -
|
||||||
$!
|
,'OPT_FILE' /OPTIONS
|
||||||
$ ELSE
|
|
||||||
$!
|
|
||||||
$! Don't Link With The RSAREF Routines And Link With A TCP/IP Library.
|
|
||||||
$!
|
|
||||||
$ LINK/'DEBUGGER'/'TRACEBACK' /EXE='EXE_FILE' -
|
|
||||||
'EXE_DIR''CURRENT_APP'.OPT/OPTION, -
|
|
||||||
'SSL_LIB'/LIBRARY,'CRYPTO_LIB'/LIBRARY, -
|
|
||||||
'OPT_FILE'/OPTION
|
|
||||||
$!
|
|
||||||
$! End The TCP/IP Library Check.
|
|
||||||
$!
|
|
||||||
$ ENDIF
|
|
||||||
$!
|
$!
|
||||||
$! Go Back And Do It Again.
|
$! Go Back And Do It Again.
|
||||||
$!
|
$!
|
||||||
@@ -346,7 +378,7 @@ $!
|
|||||||
$ CREATE 'OPT_FILE'
|
$ CREATE 'OPT_FILE'
|
||||||
$DECK
|
$DECK
|
||||||
!
|
!
|
||||||
! Default System Options File To Link Agianst
|
! Default System Options File To Link Against
|
||||||
! The Sharable VAX C Runtime Library.
|
! The Sharable VAX C Runtime Library.
|
||||||
!
|
!
|
||||||
SYS$SHARE:VAXCRTL.EXE/SHARE
|
SYS$SHARE:VAXCRTL.EXE/SHARE
|
||||||
@@ -375,7 +407,7 @@ $!
|
|||||||
$ CREATE 'OPT_FILE'
|
$ CREATE 'OPT_FILE'
|
||||||
$DECK
|
$DECK
|
||||||
!
|
!
|
||||||
! Default System Options File To Link Agianst
|
! Default System Options File To Link Against
|
||||||
! The Sharable C Runtime Library.
|
! The Sharable C Runtime Library.
|
||||||
!
|
!
|
||||||
GNU_CC:[000000]GCCLIB/LIBRARY
|
GNU_CC:[000000]GCCLIB/LIBRARY
|
||||||
@@ -410,7 +442,7 @@ $!
|
|||||||
$ CREATE 'OPT_FILE'
|
$ CREATE 'OPT_FILE'
|
||||||
$DECK
|
$DECK
|
||||||
!
|
!
|
||||||
! Default System Options File To Link Agianst
|
! Default System Options File To Link Against
|
||||||
! The Sharable DEC C Runtime Library.
|
! The Sharable DEC C Runtime Library.
|
||||||
!
|
!
|
||||||
SYS$SHARE:DECC$SHR.EXE/SHARE
|
SYS$SHARE:DECC$SHR.EXE/SHARE
|
||||||
@@ -420,19 +452,19 @@ $! Else...
|
|||||||
$!
|
$!
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$!
|
$!
|
||||||
$! Create The AXP Linker Option File.
|
$! Create The non-VAX Linker Option File.
|
||||||
$!
|
$!
|
||||||
$ CREATE 'OPT_FILE'
|
$ CREATE 'OPT_FILE'
|
||||||
$DECK
|
$DECK
|
||||||
!
|
!
|
||||||
! Default System Options File For AXP To Link Agianst
|
! Default System Options File For non-VAX To Link Against
|
||||||
! The Sharable C Runtime Library.
|
! The Sharable C Runtime Library.
|
||||||
!
|
!
|
||||||
SYS$SHARE:CMA$OPEN_LIB_SHR/SHARE
|
SYS$SHARE:CMA$OPEN_LIB_SHR/SHARE
|
||||||
SYS$SHARE:CMA$OPEN_RTL/SHARE
|
SYS$SHARE:CMA$OPEN_RTL/SHARE
|
||||||
$EOD
|
$EOD
|
||||||
$!
|
$!
|
||||||
$! End The VAX/AXP DEC C Option File Check.
|
$! End The DEC C Option File Check.
|
||||||
$!
|
$!
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
@@ -509,14 +541,15 @@ $!
|
|||||||
$ IF (P1.EQS."NODEBUG")
|
$ IF (P1.EQS."NODEBUG")
|
||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$! P1 Is NODEBUG, So Compile Without Debugger Information.
|
$! P1 Is NODEBUG, So Compile Without Debugger Information.
|
||||||
$!
|
$!
|
||||||
$ DEBUGGER = "NODEBUG"
|
$ DEBUGGER = "NODEBUG"
|
||||||
$ TRACEBACK = "NOTRACEBACK"
|
$ LINKMAP = "NOMAP"
|
||||||
$ GCC_OPTIMIZE = "OPTIMIZE"
|
$ TRACEBACK = "NOTRACEBACK"
|
||||||
$ CC_OPTIMIZE = "OPTIMIZE"
|
$ GCC_OPTIMIZE = "OPTIMIZE"
|
||||||
$ WRITE SYS$OUTPUT "No Debugger Information Will Be Produced During Compile."
|
$ CC_OPTIMIZE = "OPTIMIZE"
|
||||||
$ WRITE SYS$OUTPUT "Compiling With Compiler Optimization."
|
$ WRITE SYS$OUTPUT "No Debugger Information Will Be Produced During Compile."
|
||||||
|
$ WRITE SYS$OUTPUT "Compiling With Compiler Optimization."
|
||||||
$!
|
$!
|
||||||
$! Else...
|
$! Else...
|
||||||
$!
|
$!
|
||||||
@@ -530,6 +563,7 @@ $!
|
|||||||
$! Compile With Debugger Information.
|
$! Compile With Debugger Information.
|
||||||
$!
|
$!
|
||||||
$ DEBUGGER = "DEBUG"
|
$ DEBUGGER = "DEBUG"
|
||||||
|
$ LINKMAP = "MAP"
|
||||||
$ TRACEBACK = "TRACEBACK"
|
$ TRACEBACK = "TRACEBACK"
|
||||||
$ GCC_OPTIMIZE = "NOOPTIMIZE"
|
$ GCC_OPTIMIZE = "NOOPTIMIZE"
|
||||||
$ CC_OPTIMIZE = "NOOPTIMIZE"
|
$ CC_OPTIMIZE = "NOOPTIMIZE"
|
||||||
@@ -537,7 +571,7 @@ $ WRITE SYS$OUTPUT "Debugger Information Will Be Produced During Compile."
|
|||||||
$ WRITE SYS$OUTPUT "Compiling Without Compiler Optimization."
|
$ WRITE SYS$OUTPUT "Compiling Without Compiler Optimization."
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$!
|
$!
|
||||||
$! Tell The User Entered An Invalid Option..
|
$! Tell The User Entered An Invalid Option.
|
||||||
$!
|
$!
|
||||||
$ WRITE SYS$OUTPUT ""
|
$ WRITE SYS$OUTPUT ""
|
||||||
$ WRITE SYS$OUTPUT "The Option ",P1," Is Invalid. The Valid Options Are:"
|
$ WRITE SYS$OUTPUT "The Option ",P1," Is Invalid. The Valid Options Are:"
|
||||||
@@ -550,7 +584,7 @@ $! Time To EXIT.
|
|||||||
$!
|
$!
|
||||||
$ EXIT
|
$ EXIT
|
||||||
$!
|
$!
|
||||||
$! End The Valid Arguement Check.
|
$! End The Valid Argument Check.
|
||||||
$!
|
$!
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
@@ -558,6 +592,87 @@ $! End The P1 Check.
|
|||||||
$!
|
$!
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
|
$! Check P6 (POINTER_SIZE).
|
||||||
|
$!
|
||||||
|
$ IF (P6 .NES. "") .AND. (ARCH .NES. "VAX")
|
||||||
|
$ THEN
|
||||||
|
$!
|
||||||
|
$ IF (P6 .EQS. "32")
|
||||||
|
$ THEN
|
||||||
|
$ POINTER_SIZE = " /POINTER_SIZE=32"
|
||||||
|
$ ELSE
|
||||||
|
$ POINTER_SIZE = F$EDIT( P6, "COLLAPSE, UPCASE")
|
||||||
|
$ IF ((POINTER_SIZE .EQS. "64") .OR. -
|
||||||
|
(POINTER_SIZE .EQS. "64=") .OR. -
|
||||||
|
(POINTER_SIZE .EQS. "64=ARGV"))
|
||||||
|
$ THEN
|
||||||
|
$ ARCHD = ARCH+ "_64"
|
||||||
|
$ LIB32 = ""
|
||||||
|
$ IF (F$EXTRACT( 2, 1, POINTER_SIZE) .EQS. "=")
|
||||||
|
$ THEN
|
||||||
|
$! Explicit user choice: "64" or "64=ARGV".
|
||||||
|
$ IF (POINTER_SIZE .EQS. "64=") THEN POINTER_SIZE = "64"
|
||||||
|
$ ELSE
|
||||||
|
$ SET NOON
|
||||||
|
$ DEFINE /USER_MODE SYS$OUTPUT NL:
|
||||||
|
$ DEFINE /USER_MODE SYS$ERROR NL:
|
||||||
|
$ CC /NOLIST /NOOBJECT /POINTER_SIZE=64=ARGV NL:
|
||||||
|
$ IF ($STATUS .AND. %X0FFF0000) .EQ. %X00030000
|
||||||
|
$ THEN
|
||||||
|
$ ! If we got here, it means DCL complained like this:
|
||||||
|
$ ! %DCL-W-NOVALU, value not allowed - remove value specification
|
||||||
|
$ ! \64=\
|
||||||
|
$ !
|
||||||
|
$ ! If the compiler was run, logicals defined in /USER would
|
||||||
|
$ ! have been deassigned automatically. However, when DCL
|
||||||
|
$ ! complains, they aren't, so we do it here (it might be
|
||||||
|
$ ! unnecessary, but just in case there will be another error
|
||||||
|
$ ! message further on that we don't want to miss)
|
||||||
|
$ DEASSIGN /USER_MODE SYS$ERROR
|
||||||
|
$ DEASSIGN /USER_MODE SYS$OUTPUT
|
||||||
|
$ ELSE
|
||||||
|
$ POINTER_SIZE = POINTER_SIZE + "=ARGV"
|
||||||
|
$ ENDIF
|
||||||
|
$ SET ON
|
||||||
|
$ ENDIF
|
||||||
|
$ POINTER_SIZE = " /POINTER_SIZE=''POINTER_SIZE'"
|
||||||
|
$!
|
||||||
|
$ ELSE
|
||||||
|
$!
|
||||||
|
$! Tell The User Entered An Invalid Option.
|
||||||
|
$!
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$ WRITE SYS$OUTPUT "The Option ", P6, -
|
||||||
|
" Is Invalid. The Valid Options Are:"
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$ WRITE SYS$OUTPUT -
|
||||||
|
" """" : Compile with default (short) pointers."
|
||||||
|
$ WRITE SYS$OUTPUT -
|
||||||
|
" 32 : Compile with 32-bit (short) pointers."
|
||||||
|
$ WRITE SYS$OUTPUT -
|
||||||
|
" 64 : Compile with 64-bit (long) pointers (auto ARGV)."
|
||||||
|
$ WRITE SYS$OUTPUT -
|
||||||
|
" 64= : Compile with 64-bit (long) pointers (no ARGV)."
|
||||||
|
$ WRITE SYS$OUTPUT -
|
||||||
|
" 64=ARGV : Compile with 64-bit (long) pointers (ARGV)."
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$!
|
||||||
|
$! Time To EXIT.
|
||||||
|
$!
|
||||||
|
$ EXIT
|
||||||
|
$!
|
||||||
|
$ ENDIF
|
||||||
|
$!
|
||||||
|
$ ENDIF
|
||||||
|
$!
|
||||||
|
$! End The P6 (POINTER_SIZE) Check.
|
||||||
|
$!
|
||||||
|
$ ENDIF
|
||||||
|
$!
|
||||||
|
$! Set basic C compiler /INCLUDE directories.
|
||||||
|
$!
|
||||||
|
$ CC_INCLUDES = "SYS$DISK:[-],SYS$DISK:[-.CRYPTO]"
|
||||||
|
$!
|
||||||
$! Check To See If P2 Is Blank.
|
$! Check To See If P2 Is Blank.
|
||||||
$!
|
$!
|
||||||
$ IF (P2.EQS."")
|
$ IF (P2.EQS."")
|
||||||
@@ -581,7 +696,7 @@ $ ELSE
|
|||||||
$!
|
$!
|
||||||
$! Check To See If We Have VAXC Or DECC.
|
$! Check To See If We Have VAXC Or DECC.
|
||||||
$!
|
$!
|
||||||
$ IF (ARCH.EQS."AXP").OR.(F$TRNLNM("DECC$CC_DEFAULT").NES."")
|
$ IF (ARCH.NES."VAX").OR.(F$TRNLNM("DECC$CC_DEFAULT").NES."")
|
||||||
$ THEN
|
$ THEN
|
||||||
$!
|
$!
|
||||||
$! Looks Like DECC, Set To Use DECC.
|
$! Looks Like DECC, Set To Use DECC.
|
||||||
@@ -658,11 +773,64 @@ $ 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,FOUNDCR"
|
$ 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
|
||||||
$!
|
$!
|
||||||
$! Check To See If The User Entered A Valid Paramter.
|
$! Check To See If We Have A ZLIB Option.
|
||||||
|
$!
|
||||||
|
$ ZLIB = P7
|
||||||
|
$ IF (ZLIB .NES. "")
|
||||||
|
$ THEN
|
||||||
|
$!
|
||||||
|
$! Check for expected ZLIB files.
|
||||||
|
$!
|
||||||
|
$ err = 0
|
||||||
|
$ file1 = f$parse( "zlib.h", ZLIB, , , "SYNTAX_ONLY")
|
||||||
|
$ if (f$search( file1) .eqs. "")
|
||||||
|
$ then
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$ WRITE SYS$OUTPUT "The Option ", ZLIB, " Is Invalid."
|
||||||
|
$ WRITE SYS$OUTPUT " Can't find header: ''file1'"
|
||||||
|
$ err = 1
|
||||||
|
$ endif
|
||||||
|
$ file1 = f$parse( "A.;", ZLIB)- "A.;"
|
||||||
|
$!
|
||||||
|
$ file2 = f$parse( ZLIB, "libz.olb", , , "SYNTAX_ONLY")
|
||||||
|
$ if (f$search( file2) .eqs. "")
|
||||||
|
$ then
|
||||||
|
$ if (err .eq. 0)
|
||||||
|
$ then
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$ WRITE SYS$OUTPUT "The Option ", ZLIB, " Is Invalid."
|
||||||
|
$ endif
|
||||||
|
$ WRITE SYS$OUTPUT " Can't find library: ''file2'"
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$ err = err+ 2
|
||||||
|
$ endif
|
||||||
|
$ if (err .eq. 1)
|
||||||
|
$ then
|
||||||
|
$ WRITE SYS$OUTPUT ""
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ if (err .ne. 0)
|
||||||
|
$ then
|
||||||
|
$ EXIT
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$ CCDEFS = """ZLIB=1"", "+ CCDEFS
|
||||||
|
$ CC_INCLUDES = CC_INCLUDES+ ", "+ file1
|
||||||
|
$ ZLIB_LIB = ", ''file2' /library"
|
||||||
|
$!
|
||||||
|
$! Print info
|
||||||
|
$!
|
||||||
|
$ WRITE SYS$OUTPUT "ZLIB library spec: ", file2
|
||||||
|
$!
|
||||||
|
$! End The ZLIB Check.
|
||||||
|
$!
|
||||||
|
$ ENDIF
|
||||||
|
$!
|
||||||
|
$! Check To See If The User Entered A Valid Parameter.
|
||||||
$!
|
$!
|
||||||
$ IF (P2.EQS."VAXC").OR.(P2.EQS."DECC").OR.(P2.EQS."GNUC")
|
$ IF (P2.EQS."VAXC").OR.(P2.EQS."DECC").OR.(P2.EQS."GNUC")
|
||||||
$ THEN
|
$ THEN
|
||||||
@@ -685,13 +853,13 @@ $!
|
|||||||
$ CC = "CC"
|
$ CC = "CC"
|
||||||
$ IF ARCH.EQS."VAX" .AND. F$TRNLNM("DECC$CC_DEFAULT").NES."/DECC" -
|
$ 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=RELAXED"+ -
|
||||||
"/NOLIST/PREFIX=ALL" + -
|
"''POINTER_SIZE' /NOLIST /PREFIX=ALL" + -
|
||||||
"/INCLUDE=(SYS$DISK:[-],SYS$DISK:[-.CRYPTO])" + CCEXTRAFLAGS
|
" /INCLUDE=(''CC_INCLUDES') " + CCEXTRAFLAGS
|
||||||
$!
|
$!
|
||||||
$! Define The Linker Options File Name.
|
$! Define The Linker Options File Name.
|
||||||
$!
|
$!
|
||||||
$ OPT_FILE = "SYS$DISK:[]VAX_DECC_OPTIONS.OPT"
|
$ OPT_FILE = "VAX_DECC_OPTIONS.OPT"
|
||||||
$!
|
$!
|
||||||
$! End DECC Check.
|
$! End DECC Check.
|
||||||
$!
|
$!
|
||||||
@@ -712,14 +880,14 @@ $!
|
|||||||
$! Compile Using VAXC.
|
$! Compile Using VAXC.
|
||||||
$!
|
$!
|
||||||
$ CC = "CC"
|
$ CC = "CC"
|
||||||
$ IF ARCH.EQS."AXP"
|
$ IF ARCH.NES."VAX"
|
||||||
$ THEN
|
$ THEN
|
||||||
$ WRITE SYS$OUTPUT "There is no VAX C on Alpha!"
|
$ WRITE SYS$OUTPUT "There is no VAX C on ''ARCH'!"
|
||||||
$ EXIT
|
$ 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:[-],SYS$DISK:[-.CRYPTO])" + CCEXTRAFLAGS
|
"/INCLUDE=(''CC_INCLUDES')" + CCEXTRAFLAGS
|
||||||
$ CCDEFS = CCDEFS + ",""VAXC"""
|
$ CCDEFS = CCDEFS + ",""VAXC"""
|
||||||
$!
|
$!
|
||||||
$! Define <sys> As SYS$COMMON:[SYSLIB]
|
$! Define <sys> As SYS$COMMON:[SYSLIB]
|
||||||
@@ -728,7 +896,7 @@ $ DEFINE/NOLOG SYS SYS$COMMON:[SYSLIB]
|
|||||||
$!
|
$!
|
||||||
$! Define The Linker Options File Name.
|
$! Define The Linker Options File Name.
|
||||||
$!
|
$!
|
||||||
$ OPT_FILE = "SYS$DISK:[]VAX_VAXC_OPTIONS.OPT"
|
$ OPT_FILE = "VAX_VAXC_OPTIONS.OPT"
|
||||||
$!
|
$!
|
||||||
$! End VAXC Check
|
$! End VAXC Check
|
||||||
$!
|
$!
|
||||||
@@ -751,11 +919,11 @@ $! 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:[-],SYS$DISK:[-.CRYPTO])" + CCEXTRAFLAGS
|
"/INCLUDE=(''CC_INCLUDES')" + CCEXTRAFLAGS
|
||||||
$!
|
$!
|
||||||
$! Define The Linker Options File Name.
|
$! Define The Linker Options File Name.
|
||||||
$!
|
$!
|
||||||
$ OPT_FILE = "SYS$DISK:[]VAX_GNUC_OPTIONS.OPT"
|
$ OPT_FILE = "VAX_GNUC_OPTIONS.OPT"
|
||||||
$!
|
$!
|
||||||
$! End The GNU C Check.
|
$! End The GNU C Check.
|
||||||
$!
|
$!
|
||||||
@@ -765,7 +933,7 @@ $! Set up default defines
|
|||||||
$!
|
$!
|
||||||
$ CCDEFS = """FLAT_INC=1""," + CCDEFS
|
$ CCDEFS = """FLAT_INC=1""," + CCDEFS
|
||||||
$!
|
$!
|
||||||
$! Else The User Entered An Invalid Arguement.
|
$! Else The User Entered An Invalid Argument.
|
||||||
$!
|
$!
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$!
|
$!
|
||||||
@@ -797,7 +965,7 @@ $ THEN
|
|||||||
$!
|
$!
|
||||||
$! Set the library to use SOCKETSHR
|
$! Set the library to use SOCKETSHR
|
||||||
$!
|
$!
|
||||||
$ TCPIP_LIB = "SYS$DISK:[-.VMS]SOCKETSHR_SHR.OPT/OPT"
|
$ TCPIP_LIB = ",SYS$DISK:[-.VMS]SOCKETSHR_SHR.OPT /OPTIONS"
|
||||||
$!
|
$!
|
||||||
$! Done with SOCKETSHR
|
$! Done with SOCKETSHR
|
||||||
$!
|
$!
|
||||||
@@ -823,13 +991,13 @@ $ THEN
|
|||||||
$!
|
$!
|
||||||
$! Set the library to use UCX.
|
$! Set the library to use UCX.
|
||||||
$!
|
$!
|
||||||
$ TCPIP_LIB = "SYS$DISK:[-.VMS]UCX_SHR_DECC.OPT/OPT"
|
$ TCPIP_LIB = ",SYS$DISK:[-.VMS]UCX_SHR_DECC.OPT /OPTIONS"
|
||||||
$ IF F$TRNLNM("UCX$IPC_SHR") .NES. ""
|
$ IF F$TRNLNM("UCX$IPC_SHR") .NES. ""
|
||||||
$ THEN
|
$ THEN
|
||||||
$ TCPIP_LIB = "SYS$DISK:[-.VMS]UCX_SHR_DECC_LOG.OPT/OPT"
|
$ TCPIP_LIB = ",SYS$DISK:[-.VMS]UCX_SHR_DECC_LOG.OPT /OPTIONS"
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$ IF COMPILER .NES. "DECC" .AND. ARCH .EQS. "VAX" THEN -
|
$ IF COMPILER .NES. "DECC" .AND. ARCH .EQS. "VAX" THEN -
|
||||||
TCPIP_LIB = "SYS$DISK:[-.VMS]UCX_SHR_VAXC.OPT/OPT"
|
TCPIP_LIB = ",SYS$DISK:[-.VMS]UCX_SHR_VAXC.OPT /OPTIONS"
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$!
|
$!
|
||||||
$! Done with UCX
|
$! Done with UCX
|
||||||
@@ -843,7 +1011,7 @@ $ THEN
|
|||||||
$!
|
$!
|
||||||
$! Set the library to use TCPIP.
|
$! Set the library to use TCPIP.
|
||||||
$!
|
$!
|
||||||
$ TCPIP_LIB = "SYS$DISK:[-.VMS]TCPIP_SHR_DECC.OPT/OPT"
|
$ TCPIP_LIB = ",SYS$DISK:[-.VMS]TCPIP_SHR_DECC.OPT /OPTIONS"
|
||||||
$!
|
$!
|
||||||
$! Done with TCPIP
|
$! Done with TCPIP
|
||||||
$!
|
$!
|
||||||
@@ -868,9 +1036,9 @@ $ CCDEFS = CCDEFS + ",TCPIP_TYPE_''P3'"
|
|||||||
$!
|
$!
|
||||||
$! Print info
|
$! Print info
|
||||||
$!
|
$!
|
||||||
$ WRITE SYS$OUTPUT "TCP/IP library spec: ", TCPIP_LIB
|
$ WRITE SYS$OUTPUT "TCP/IP library spec: ", TCPIP_LIB- ","
|
||||||
$!
|
$!
|
||||||
$! Else The User Entered An Invalid Arguement.
|
$! Else The User Entered An Invalid Argument.
|
||||||
$!
|
$!
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$!
|
$!
|
||||||
@@ -898,13 +1066,13 @@ $ IF COMPILER .EQS. "DECC"
|
|||||||
$ THEN
|
$ THEN
|
||||||
$ IF CCDISABLEWARNINGS .NES. ""
|
$ IF CCDISABLEWARNINGS .NES. ""
|
||||||
$ THEN
|
$ THEN
|
||||||
$ CCDISABLEWARNINGS = "/WARNING=(DISABLE=(" + CCDISABLEWARNINGS + "))"
|
$ CCDISABLEWARNINGS = " /WARNING=(DISABLE=(" + CCDISABLEWARNINGS + "))"
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$ ELSE
|
$ ELSE
|
||||||
$ CCDISABLEWARNINGS = ""
|
$ CCDISABLEWARNINGS = ""
|
||||||
$ ENDIF
|
$ ENDIF
|
||||||
$ CC2 = CC + "/DEFINE=(" + CCDEFS + ",_POSIX_C_SOURCE)" + CCDISABLEWARNINGS
|
$ CC2 = CC + " /DEFINE=(" + CCDEFS + ",_POSIX_C_SOURCE)" + CCDISABLEWARNINGS
|
||||||
$ CC = CC + "/DEFINE=(" + CCDEFS + ")" + CCDISABLEWARNINGS
|
$ CC = CC + " /DEFINE=(" + CCDEFS + ")" + CCDISABLEWARNINGS
|
||||||
$!
|
$!
|
||||||
$! Show user the result
|
$! Show user the result
|
||||||
$!
|
$!
|
||||||
@@ -970,7 +1138,7 @@ $ __INCLUDE = __TOP + "INCLUDE.OPENSSL]"
|
|||||||
$!
|
$!
|
||||||
$! Set up the logical name OPENSSL to point at the include directory
|
$! Set up the logical name OPENSSL to point at the include directory
|
||||||
$!
|
$!
|
||||||
$ DEFINE OPENSSL/NOLOG '__INCLUDE'
|
$ DEFINE OPENSSL /NOLOG '__INCLUDE'
|
||||||
$!
|
$!
|
||||||
$! Done
|
$! Done
|
||||||
$!
|
$!
|
||||||
@@ -978,15 +1146,24 @@ $ RETURN
|
|||||||
$!
|
$!
|
||||||
$ CLEANUP:
|
$ CLEANUP:
|
||||||
$!
|
$!
|
||||||
$! Restore the logical name OPENSSL if it had a value
|
$! Restore the saved logical name OPENSSL, if it had a value.
|
||||||
$!
|
$!
|
||||||
$ IF __SAVE_OPENSSL .EQS. ""
|
$ if (f$type( __SAVE_OPENSSL) .nes. "")
|
||||||
$ THEN
|
$ then
|
||||||
$ DEASSIGN OPENSSL
|
$ IF __SAVE_OPENSSL .EQS. ""
|
||||||
$ ELSE
|
$ THEN
|
||||||
$ DEFINE/NOLOG OPENSSL '__SAVE_OPENSSL'
|
$ DEASSIGN OPENSSL
|
||||||
$ ENDIF
|
$ ELSE
|
||||||
|
$ DEFINE /NOLOG OPENSSL '__SAVE_OPENSSL'
|
||||||
|
$ ENDIF
|
||||||
|
$ endif
|
||||||
|
$!
|
||||||
|
$! Close any open files.
|
||||||
|
$!
|
||||||
|
$ if (f$trnlnm( "objects", "LNM$PROCESS", 0, "SUPERVISOR") .nes. "") then -
|
||||||
|
close objects
|
||||||
$!
|
$!
|
||||||
$! Done
|
$! Done
|
||||||
$!
|
$!
|
||||||
$ RETURN
|
$ RETURN
|
||||||
|
$!
|
||||||
|
|||||||
66
apps/ocsp.c
66
apps/ocsp.c
@@ -62,6 +62,8 @@
|
|||||||
on OpenVMS */
|
on OpenVMS */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define USE_SOCKETS
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
@@ -73,6 +75,7 @@
|
|||||||
#include <openssl/ssl.h>
|
#include <openssl/ssl.h>
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
#include <openssl/bn.h>
|
#include <openssl/bn.h>
|
||||||
|
#include <openssl/x509v3.h>
|
||||||
|
|
||||||
#if defined(NETWARE_CLIB)
|
#if defined(NETWARE_CLIB)
|
||||||
# ifdef NETWARE_BSDSOCK
|
# ifdef NETWARE_BSDSOCK
|
||||||
@@ -97,7 +100,7 @@ static int add_ocsp_cert(OCSP_REQUEST **req, X509 *cert, const EVP_MD *cert_id_m
|
|||||||
static int add_ocsp_serial(OCSP_REQUEST **req, char *serial, const EVP_MD * cert_id_md, X509 *issuer,
|
static int add_ocsp_serial(OCSP_REQUEST **req, char *serial, const EVP_MD * cert_id_md, X509 *issuer,
|
||||||
STACK_OF(OCSP_CERTID) *ids);
|
STACK_OF(OCSP_CERTID) *ids);
|
||||||
static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
||||||
STACK_OF(STRING) *names,
|
STACK_OF(OPENSSL_STRING) *names,
|
||||||
STACK_OF(OCSP_CERTID) *ids, long nsec,
|
STACK_OF(OCSP_CERTID) *ids, long nsec,
|
||||||
long maxage);
|
long maxage);
|
||||||
|
|
||||||
@@ -111,6 +114,7 @@ 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);
|
||||||
static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
||||||
|
STACK_OF(CONF_VALUE) *headers,
|
||||||
OCSP_REQUEST *req, int req_timeout);
|
OCSP_REQUEST *req, int req_timeout);
|
||||||
|
|
||||||
#undef PROG
|
#undef PROG
|
||||||
@@ -129,6 +133,7 @@ int MAIN(int argc, char **argv)
|
|||||||
char *rsignfile = NULL, *rkeyfile = NULL;
|
char *rsignfile = NULL, *rkeyfile = NULL;
|
||||||
char *outfile = NULL;
|
char *outfile = NULL;
|
||||||
int add_nonce = 1, noverify = 0, use_ssl = -1;
|
int add_nonce = 1, noverify = 0, use_ssl = -1;
|
||||||
|
STACK_OF(CONF_VALUE) *headers = NULL;
|
||||||
OCSP_REQUEST *req = NULL;
|
OCSP_REQUEST *req = NULL;
|
||||||
OCSP_RESPONSE *resp = NULL;
|
OCSP_RESPONSE *resp = NULL;
|
||||||
OCSP_BASICRESP *bs = NULL;
|
OCSP_BASICRESP *bs = NULL;
|
||||||
@@ -151,7 +156,7 @@ int MAIN(int argc, char **argv)
|
|||||||
int badarg = 0;
|
int badarg = 0;
|
||||||
int i;
|
int i;
|
||||||
int ignore_err = 0;
|
int ignore_err = 0;
|
||||||
STACK_OF(STRING) *reqnames = NULL;
|
STACK_OF(OPENSSL_STRING) *reqnames = NULL;
|
||||||
STACK_OF(OCSP_CERTID) *ids = NULL;
|
STACK_OF(OCSP_CERTID) *ids = NULL;
|
||||||
|
|
||||||
X509 *rca_cert = NULL;
|
X509 *rca_cert = NULL;
|
||||||
@@ -168,7 +173,7 @@ int MAIN(int argc, char **argv)
|
|||||||
SSL_load_error_strings();
|
SSL_load_error_strings();
|
||||||
OpenSSL_add_ssl_algorithms();
|
OpenSSL_add_ssl_algorithms();
|
||||||
args = argv + 1;
|
args = argv + 1;
|
||||||
reqnames = sk_STRING_new_null();
|
reqnames = sk_OPENSSL_STRING_new_null();
|
||||||
ids = sk_OCSP_CERTID_new_null();
|
ids = sk_OCSP_CERTID_new_null();
|
||||||
while (!badarg && *args && *args[0] == '-')
|
while (!badarg && *args && *args[0] == '-')
|
||||||
{
|
{
|
||||||
@@ -228,6 +233,16 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
else badarg = 1;
|
else badarg = 1;
|
||||||
}
|
}
|
||||||
|
else if (!strcmp(*args, "-header"))
|
||||||
|
{
|
||||||
|
if (args[1] && args[2])
|
||||||
|
{
|
||||||
|
if (!X509V3_add_value(args[1], args[2], &headers))
|
||||||
|
goto end;
|
||||||
|
args += 2;
|
||||||
|
}
|
||||||
|
else badarg = 1;
|
||||||
|
}
|
||||||
else if (!strcmp(*args, "-ignore_err"))
|
else if (!strcmp(*args, "-ignore_err"))
|
||||||
ignore_err = 1;
|
ignore_err = 1;
|
||||||
else if (!strcmp(*args, "-noverify"))
|
else if (!strcmp(*args, "-noverify"))
|
||||||
@@ -430,7 +445,7 @@ int MAIN(int argc, char **argv)
|
|||||||
if (!cert_id_md) cert_id_md = EVP_sha1();
|
if (!cert_id_md) cert_id_md = EVP_sha1();
|
||||||
if(!add_ocsp_cert(&req, cert, cert_id_md, issuer, ids))
|
if(!add_ocsp_cert(&req, cert, cert_id_md, issuer, ids))
|
||||||
goto end;
|
goto end;
|
||||||
if(!sk_STRING_push(reqnames, *args))
|
if(!sk_OPENSSL_STRING_push(reqnames, *args))
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
else badarg = 1;
|
else badarg = 1;
|
||||||
@@ -443,7 +458,7 @@ int MAIN(int argc, char **argv)
|
|||||||
if (!cert_id_md) cert_id_md = EVP_sha1();
|
if (!cert_id_md) cert_id_md = EVP_sha1();
|
||||||
if(!add_ocsp_serial(&req, *args, cert_id_md, issuer, ids))
|
if(!add_ocsp_serial(&req, *args, cert_id_md, issuer, ids))
|
||||||
goto end;
|
goto end;
|
||||||
if(!sk_STRING_push(reqnames, *args))
|
if(!sk_OPENSSL_STRING_push(reqnames, *args))
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
else badarg = 1;
|
else badarg = 1;
|
||||||
@@ -602,7 +617,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf (bio_err, "-ndays n number of days before next update\n");
|
BIO_printf (bio_err, "-ndays n number of days before next update\n");
|
||||||
BIO_printf (bio_err, "-resp_key_id identify reponse by signing certificate key ID\n");
|
BIO_printf (bio_err, "-resp_key_id identify reponse by signing certificate key ID\n");
|
||||||
BIO_printf (bio_err, "-nrequest n number of requests to accept (default unlimited)\n");
|
BIO_printf (bio_err, "-nrequest n number of requests to accept (default unlimited)\n");
|
||||||
BIO_printf (bio_err, "-<dgst alg> use specified digest in the request");
|
BIO_printf (bio_err, "-<dgst alg> use specified digest in the request\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -754,7 +769,7 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_SOCK
|
#ifndef OPENSSL_NO_SOCK
|
||||||
resp = process_responder(bio_err, req, host, path,
|
resp = process_responder(bio_err, req, host, path,
|
||||||
port, use_ssl, req_timeout);
|
port, use_ssl, headers, req_timeout);
|
||||||
if (!resp)
|
if (!resp)
|
||||||
goto end;
|
goto end;
|
||||||
#else
|
#else
|
||||||
@@ -899,10 +914,11 @@ end:
|
|||||||
OCSP_REQUEST_free(req);
|
OCSP_REQUEST_free(req);
|
||||||
OCSP_RESPONSE_free(resp);
|
OCSP_RESPONSE_free(resp);
|
||||||
OCSP_BASICRESP_free(bs);
|
OCSP_BASICRESP_free(bs);
|
||||||
sk_STRING_free(reqnames);
|
sk_OPENSSL_STRING_free(reqnames);
|
||||||
sk_OCSP_CERTID_free(ids);
|
sk_OCSP_CERTID_free(ids);
|
||||||
sk_X509_pop_free(sign_other, X509_free);
|
sk_X509_pop_free(sign_other, X509_free);
|
||||||
sk_X509_pop_free(verify_other, X509_free);
|
sk_X509_pop_free(verify_other, X509_free);
|
||||||
|
sk_CONF_VALUE_pop_free(headers, X509V3_conf_free);
|
||||||
|
|
||||||
if (use_ssl != -1)
|
if (use_ssl != -1)
|
||||||
{
|
{
|
||||||
@@ -969,7 +985,7 @@ static int add_ocsp_serial(OCSP_REQUEST **req, char *serial,const EVP_MD *cert_i
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
||||||
STACK_OF(STRING) *names,
|
STACK_OF(OPENSSL_STRING) *names,
|
||||||
STACK_OF(OCSP_CERTID) *ids, long nsec,
|
STACK_OF(OCSP_CERTID) *ids, long nsec,
|
||||||
long maxage)
|
long maxage)
|
||||||
{
|
{
|
||||||
@@ -981,13 +997,13 @@ static int print_ocsp_summary(BIO *out, OCSP_BASICRESP *bs, OCSP_REQUEST *req,
|
|||||||
|
|
||||||
ASN1_GENERALIZEDTIME *rev, *thisupd, *nextupd;
|
ASN1_GENERALIZEDTIME *rev, *thisupd, *nextupd;
|
||||||
|
|
||||||
if (!bs || !req || !sk_STRING_num(names) || !sk_OCSP_CERTID_num(ids))
|
if (!bs || !req || !sk_OPENSSL_STRING_num(names) || !sk_OCSP_CERTID_num(ids))
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
for (i = 0; i < sk_OCSP_CERTID_num(ids); i++)
|
for (i = 0; i < sk_OCSP_CERTID_num(ids); i++)
|
||||||
{
|
{
|
||||||
id = sk_OCSP_CERTID_value(ids, i);
|
id = sk_OCSP_CERTID_value(ids, i);
|
||||||
name = sk_STRING_value(names, i);
|
name = sk_OPENSSL_STRING_value(names, i);
|
||||||
BIO_printf(out, "%s: ", name);
|
BIO_printf(out, "%s: ", name);
|
||||||
|
|
||||||
if(!OCSP_resp_find_status(bs, id, &status, &reason,
|
if(!OCSP_resp_find_status(bs, id, &status, &reason,
|
||||||
@@ -1258,10 +1274,12 @@ static int send_ocsp_response(BIO *cbio, OCSP_RESPONSE *resp)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
||||||
|
STACK_OF(CONF_VALUE) *headers,
|
||||||
OCSP_REQUEST *req, int req_timeout)
|
OCSP_REQUEST *req, int req_timeout)
|
||||||
{
|
{
|
||||||
int fd;
|
int fd;
|
||||||
int rv;
|
int rv;
|
||||||
|
int i;
|
||||||
OCSP_REQ_CTX *ctx = NULL;
|
OCSP_REQ_CTX *ctx = NULL;
|
||||||
OCSP_RESPONSE *rsp = NULL;
|
OCSP_RESPONSE *rsp = NULL;
|
||||||
fd_set confds;
|
fd_set confds;
|
||||||
@@ -1278,16 +1296,13 @@ static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (req_timeout == -1)
|
|
||||||
return OCSP_sendreq_bio(cbio, path, req);
|
|
||||||
|
|
||||||
if (BIO_get_fd(cbio, &fd) <= 0)
|
if (BIO_get_fd(cbio, &fd) <= 0)
|
||||||
{
|
{
|
||||||
BIO_puts(err, "Can't get connection fd\n");
|
BIO_puts(err, "Can't get connection fd\n");
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rv <= 0)
|
if (req_timeout != -1 && rv <= 0)
|
||||||
{
|
{
|
||||||
FD_ZERO(&confds);
|
FD_ZERO(&confds);
|
||||||
openssl_fdset(fd, &confds);
|
openssl_fdset(fd, &confds);
|
||||||
@@ -1302,15 +1317,27 @@ static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
ctx = OCSP_sendreq_new(cbio, path, req, -1);
|
ctx = OCSP_sendreq_new(cbio, path, NULL, -1);
|
||||||
if (!ctx)
|
if (!ctx)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
for (i = 0; i < sk_CONF_VALUE_num(headers); i++)
|
||||||
|
{
|
||||||
|
CONF_VALUE *hdr = sk_CONF_VALUE_value(headers, i);
|
||||||
|
if (!OCSP_REQ_CTX_add1_header(ctx, hdr->name, hdr->value))
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!OCSP_REQ_CTX_set1_req(ctx, req))
|
||||||
|
goto err;
|
||||||
|
|
||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
rv = OCSP_sendreq_nbio(&rsp, ctx);
|
rv = OCSP_sendreq_nbio(&rsp, ctx);
|
||||||
if (rv != -1)
|
if (rv != -1)
|
||||||
break;
|
break;
|
||||||
|
if (req_timeout == -1)
|
||||||
|
continue;
|
||||||
FD_ZERO(&confds);
|
FD_ZERO(&confds);
|
||||||
openssl_fdset(fd, &confds);
|
openssl_fdset(fd, &confds);
|
||||||
tv.tv_usec = 0;
|
tv.tv_usec = 0;
|
||||||
@@ -1345,6 +1372,7 @@ static OCSP_RESPONSE *query_responder(BIO *err, BIO *cbio, char *path,
|
|||||||
|
|
||||||
OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req,
|
OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req,
|
||||||
char *host, char *path, char *port, int use_ssl,
|
char *host, char *path, char *port, int use_ssl,
|
||||||
|
STACK_OF(CONF_VALUE) *headers,
|
||||||
int req_timeout)
|
int req_timeout)
|
||||||
{
|
{
|
||||||
BIO *cbio = NULL;
|
BIO *cbio = NULL;
|
||||||
@@ -1379,14 +1407,14 @@ OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req,
|
|||||||
sbio = BIO_new_ssl(ctx, 1);
|
sbio = BIO_new_ssl(ctx, 1);
|
||||||
cbio = BIO_push(sbio, cbio);
|
cbio = BIO_push(sbio, cbio);
|
||||||
}
|
}
|
||||||
resp = query_responder(err, cbio, path, req, req_timeout);
|
resp = query_responder(err, cbio, path, headers, req, req_timeout);
|
||||||
if (!resp)
|
if (!resp)
|
||||||
BIO_printf(bio_err, "Error querying OCSP responsder\n");
|
BIO_printf(bio_err, "Error querying OCSP responsder\n");
|
||||||
end:
|
end:
|
||||||
if (ctx)
|
|
||||||
SSL_CTX_free(ctx);
|
|
||||||
if (cbio)
|
if (cbio)
|
||||||
BIO_free_all(cbio);
|
BIO_free_all(cbio);
|
||||||
|
if (ctx)
|
||||||
|
SSL_CTX_free(ctx);
|
||||||
return resp;
|
return resp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -145,7 +145,7 @@ localityName = Locality Name (eg, city)
|
|||||||
organizationalUnitName = Organizational Unit Name (eg, section)
|
organizationalUnitName = Organizational Unit Name (eg, section)
|
||||||
#organizationalUnitName_default =
|
#organizationalUnitName_default =
|
||||||
|
|
||||||
commonName = Common Name (eg, YOUR name)
|
commonName = Common Name (e.g. server FQDN or YOUR name)
|
||||||
commonName_max = 64
|
commonName_max = 64
|
||||||
|
|
||||||
emailAddress = Email Address
|
emailAddress = Email Address
|
||||||
@@ -231,7 +231,7 @@ keyUsage = nonRepudiation, digitalSignature, keyEncipherment
|
|||||||
|
|
||||||
subjectKeyIdentifier=hash
|
subjectKeyIdentifier=hash
|
||||||
|
|
||||||
authorityKeyIdentifier=keyid:always,issuer:always
|
authorityKeyIdentifier=keyid:always,issuer
|
||||||
|
|
||||||
# This is what PKIX recommends but some broken software chokes on critical
|
# This is what PKIX recommends but some broken software chokes on critical
|
||||||
# extensions.
|
# extensions.
|
||||||
@@ -264,7 +264,7 @@ basicConstraints = CA:true
|
|||||||
# Only issuerAltName and authorityKeyIdentifier make any sense in a CRL.
|
# Only issuerAltName and authorityKeyIdentifier make any sense in a CRL.
|
||||||
|
|
||||||
# issuerAltName=issuer:copy
|
# issuerAltName=issuer:copy
|
||||||
authorityKeyIdentifier=keyid:always,issuer:always
|
authorityKeyIdentifier=keyid:always
|
||||||
|
|
||||||
[ proxy_cert_ext ]
|
[ proxy_cert_ext ]
|
||||||
# These extensions should be added when creating a proxy certificate
|
# These extensions should be added when creating a proxy certificate
|
||||||
@@ -297,7 +297,7 @@ nsComment = "OpenSSL Generated Certificate"
|
|||||||
|
|
||||||
# PKIX recommendations harmless if included in all certificates.
|
# PKIX recommendations harmless if included in all certificates.
|
||||||
subjectKeyIdentifier=hash
|
subjectKeyIdentifier=hash
|
||||||
authorityKeyIdentifier=keyid,issuer:always
|
authorityKeyIdentifier=keyid,issuer
|
||||||
|
|
||||||
# This stuff is for subjectAltName and issuerAltname.
|
# This stuff is for subjectAltName and issuerAltname.
|
||||||
# Import the email address.
|
# Import the email address.
|
||||||
|
|||||||
@@ -117,6 +117,7 @@
|
|||||||
#include "apps.h"
|
#include "apps.h"
|
||||||
#include <openssl/bio.h>
|
#include <openssl/bio.h>
|
||||||
#include <openssl/crypto.h>
|
#include <openssl/crypto.h>
|
||||||
|
#include <openssl/rand.h>
|
||||||
#include <openssl/lhash.h>
|
#include <openssl/lhash.h>
|
||||||
#include <openssl/conf.h>
|
#include <openssl/conf.h>
|
||||||
#include <openssl/x509.h>
|
#include <openssl/x509.h>
|
||||||
@@ -129,6 +130,9 @@
|
|||||||
#include "progs.h"
|
#include "progs.h"
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
#include <openssl/fips.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
/* 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
|
||||||
@@ -212,8 +216,13 @@ static void lock_dbg_cb(int mode, int type, const char *file, int line)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined( OPENSSL_SYS_VMS) && (__INITIAL_POINTER_SIZE == 64)
|
||||||
|
# define ARGV _Argv
|
||||||
|
#else
|
||||||
|
# define ARGV Argv
|
||||||
|
#endif
|
||||||
|
|
||||||
int main(int Argc, char *Argv[])
|
int main(int Argc, char *ARGV[])
|
||||||
{
|
{
|
||||||
ARGS arg;
|
ARGS arg;
|
||||||
#define PROG_NAME_SIZE 39
|
#define PROG_NAME_SIZE 39
|
||||||
@@ -228,6 +237,54 @@ int main(int Argc, char *Argv[])
|
|||||||
LHASH_OF(FUNCTION) *prog=NULL;
|
LHASH_OF(FUNCTION) *prog=NULL;
|
||||||
long errline;
|
long errline;
|
||||||
|
|
||||||
|
#if defined( OPENSSL_SYS_VMS) && (__INITIAL_POINTER_SIZE == 64)
|
||||||
|
/* 2011-03-22 SMS.
|
||||||
|
* If we have 32-bit pointers everywhere, then we're safe, and
|
||||||
|
* we bypass this mess, as on non-VMS systems. (See ARGV,
|
||||||
|
* above.)
|
||||||
|
* Problem 1: Compaq/HP C before V7.3 always used 32-bit
|
||||||
|
* pointers for argv[].
|
||||||
|
* Fix 1: For a 32-bit argv[], when we're using 64-bit pointers
|
||||||
|
* everywhere else, we always allocate and use a 64-bit
|
||||||
|
* duplicate of argv[].
|
||||||
|
* Problem 2: Compaq/HP C V7.3 (Alpha, IA64) before ECO1 failed
|
||||||
|
* to NULL-terminate a 64-bit argv[]. (As this was written, the
|
||||||
|
* compiler ECO was available only on IA64.)
|
||||||
|
* Fix 2: Unless advised not to (VMS_TRUST_ARGV), we test a
|
||||||
|
* 64-bit argv[argc] for NULL, and, if necessary, use a
|
||||||
|
* (properly) NULL-terminated (64-bit) duplicate of argv[].
|
||||||
|
* The same code is used in either case to duplicate argv[].
|
||||||
|
* Some of these decisions could be handled in preprocessing,
|
||||||
|
* but the code tends to get even uglier, and the penalty for
|
||||||
|
* deciding at compile- or run-time is tiny.
|
||||||
|
*/
|
||||||
|
char **Argv = NULL;
|
||||||
|
int free_Argv = 0;
|
||||||
|
|
||||||
|
if ((sizeof( _Argv) < 8) /* 32-bit argv[]. */
|
||||||
|
# if !defined( VMS_TRUST_ARGV)
|
||||||
|
|| (_Argv[ Argc] != NULL) /* Untrusted argv[argc] not NULL. */
|
||||||
|
# endif
|
||||||
|
)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
Argv = OPENSSL_malloc( (Argc+ 1)* sizeof( char *));
|
||||||
|
if (Argv == NULL)
|
||||||
|
{ ret = -1; goto end; }
|
||||||
|
for(i = 0; i < Argc; i++)
|
||||||
|
Argv[i] = _Argv[i];
|
||||||
|
Argv[ Argc] = NULL; /* Certain NULL termination. */
|
||||||
|
free_Argv = 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
/* Use the known-good 32-bit argv[] (which needs the
|
||||||
|
* type cast to satisfy the compiler), or the trusted or
|
||||||
|
* tested-good 64-bit argv[] as-is. */
|
||||||
|
Argv = (char **)_Argv;
|
||||||
|
}
|
||||||
|
#endif /* defined( OPENSSL_SYS_VMS) && (__INITIAL_POINTER_SIZE == 64) */
|
||||||
|
|
||||||
arg.data=NULL;
|
arg.data=NULL;
|
||||||
arg.count=0;
|
arg.count=0;
|
||||||
|
|
||||||
@@ -257,6 +314,19 @@ int main(int Argc, char *Argv[])
|
|||||||
CRYPTO_set_locking_callback(lock_dbg_cb);
|
CRYPTO_set_locking_callback(lock_dbg_cb);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(getenv("OPENSSL_FIPS")) {
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
if (!FIPS_mode_set(1)) {
|
||||||
|
ERR_load_crypto_strings();
|
||||||
|
ERR_print_errors(BIO_new_fp(stderr,BIO_NOCLOSE));
|
||||||
|
EXIT(1);
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
fprintf(stderr, "FIPS mode not supported.\n");
|
||||||
|
EXIT(1);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
|
|
||||||
/* Lets load up our environment a little */
|
/* Lets load up our environment a little */
|
||||||
@@ -330,7 +400,8 @@ int main(int Argc, char *Argv[])
|
|||||||
else prompt="OpenSSL> ";
|
else prompt="OpenSSL> ";
|
||||||
fputs(prompt,stdout);
|
fputs(prompt,stdout);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fgets(p,n,stdin);
|
if (!fgets(p,n,stdin))
|
||||||
|
goto end;
|
||||||
if (p[0] == '\0') goto end;
|
if (p[0] == '\0') goto end;
|
||||||
i=strlen(p);
|
i=strlen(p);
|
||||||
if (i <= 1) break;
|
if (i <= 1) break;
|
||||||
@@ -372,6 +443,13 @@ end:
|
|||||||
BIO_free(bio_err);
|
BIO_free(bio_err);
|
||||||
bio_err=NULL;
|
bio_err=NULL;
|
||||||
}
|
}
|
||||||
|
#if defined( OPENSSL_SYS_VMS) && (__INITIAL_POINTER_SIZE == 64)
|
||||||
|
/* Free any duplicate Argv[] storage. */
|
||||||
|
if (free_Argv)
|
||||||
|
{
|
||||||
|
OPENSSL_free(Argv);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -145,7 +145,7 @@ localityName = Locality Name (eg, city)
|
|||||||
organizationalUnitName = Organizational Unit Name (eg, section)
|
organizationalUnitName = Organizational Unit Name (eg, section)
|
||||||
#organizationalUnitName_default =
|
#organizationalUnitName_default =
|
||||||
|
|
||||||
commonName = Common Name (eg, YOUR name)
|
commonName = Common Name (e.g. server FQDN or YOUR name)
|
||||||
commonName_max = 64
|
commonName_max = 64
|
||||||
|
|
||||||
emailAddress = Email Address
|
emailAddress = Email Address
|
||||||
@@ -231,7 +231,7 @@ keyUsage = nonRepudiation, digitalSignature, keyEncipherment
|
|||||||
|
|
||||||
subjectKeyIdentifier=hash
|
subjectKeyIdentifier=hash
|
||||||
|
|
||||||
authorityKeyIdentifier=keyid:always,issuer:always
|
authorityKeyIdentifier=keyid:always,issuer
|
||||||
|
|
||||||
# This is what PKIX recommends but some broken software chokes on critical
|
# This is what PKIX recommends but some broken software chokes on critical
|
||||||
# extensions.
|
# extensions.
|
||||||
@@ -264,7 +264,7 @@ basicConstraints = CA:true
|
|||||||
# Only issuerAltName and authorityKeyIdentifier make any sense in a CRL.
|
# Only issuerAltName and authorityKeyIdentifier make any sense in a CRL.
|
||||||
|
|
||||||
# issuerAltName=issuer:copy
|
# issuerAltName=issuer:copy
|
||||||
authorityKeyIdentifier=keyid:always,issuer:always
|
authorityKeyIdentifier=keyid:always
|
||||||
|
|
||||||
[ proxy_cert_ext ]
|
[ proxy_cert_ext ]
|
||||||
# These extensions should be added when creating a proxy certificate
|
# These extensions should be added when creating a proxy certificate
|
||||||
@@ -297,7 +297,7 @@ nsComment = "OpenSSL Generated Certificate"
|
|||||||
|
|
||||||
# PKIX recommendations harmless if included in all certificates.
|
# PKIX recommendations harmless if included in all certificates.
|
||||||
subjectKeyIdentifier=hash
|
subjectKeyIdentifier=hash
|
||||||
authorityKeyIdentifier=keyid,issuer:always
|
authorityKeyIdentifier=keyid,issuer
|
||||||
|
|
||||||
# This stuff is for subjectAltName and issuerAltname.
|
# This stuff is for subjectAltName and issuerAltname.
|
||||||
# Import the email address.
|
# Import the email address.
|
||||||
|
|||||||
@@ -112,12 +112,12 @@ 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;
|
||||||
int noprompt = 0;
|
int noprompt = 0;
|
||||||
STACK_OF(STRING) *canames = NULL;
|
STACK_OF(OPENSSL_STRING) *canames = NULL;
|
||||||
char *cpass = NULL, *mpass = NULL;
|
char *cpass = NULL, *mpass = NULL;
|
||||||
char *passargin = NULL, *passargout = NULL, *passarg = NULL;
|
char *passargin = NULL, *passargout = NULL, *passarg = NULL;
|
||||||
char *passin = NULL, *passout = NULL;
|
char *passin = NULL, *passout = NULL;
|
||||||
@@ -130,6 +130,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);
|
||||||
|
|
||||||
@@ -222,8 +229,8 @@ int MAIN(int argc, char **argv)
|
|||||||
} else if (!strcmp (*args, "-caname")) {
|
} else if (!strcmp (*args, "-caname")) {
|
||||||
if (args[1]) {
|
if (args[1]) {
|
||||||
args++;
|
args++;
|
||||||
if (!canames) canames = sk_STRING_new_null();
|
if (!canames) canames = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(canames, *args);
|
sk_OPENSSL_STRING_push(canames, *args);
|
||||||
} else badarg = 1;
|
} else badarg = 1;
|
||||||
} else if (!strcmp (*args, "-in")) {
|
} else if (!strcmp (*args, "-in")) {
|
||||||
if (args[1]) {
|
if (args[1]) {
|
||||||
@@ -549,9 +556,9 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
/* Add any CA names */
|
/* Add any CA names */
|
||||||
|
|
||||||
for (i = 0; i < sk_STRING_num(canames); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(canames); i++)
|
||||||
{
|
{
|
||||||
catmp = (unsigned char *)sk_STRING_value(canames, i);
|
catmp = (unsigned char *)sk_OPENSSL_STRING_value(canames, i);
|
||||||
X509_alias_set1(sk_X509_value(certs, i), catmp, -1);
|
X509_alias_set1(sk_X509_value(certs, i), catmp, -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -647,7 +654,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
if (!twopass) BUF_strlcpy(macpass, pass, sizeof macpass);
|
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) && p12->mac) BIO_printf (bio_err, "MAC Iteration %ld\n", p12->mac->iter ? ASN1_INTEGER_get (p12->mac->iter) : 1);
|
||||||
if(macver) {
|
if(macver) {
|
||||||
#ifdef CRYPTO_MDEBUG
|
#ifdef CRYPTO_MDEBUG
|
||||||
CRYPTO_push_info("verify MAC");
|
CRYPTO_push_info("verify MAC");
|
||||||
@@ -687,7 +694,7 @@ int MAIN(int argc, char **argv)
|
|||||||
#endif
|
#endif
|
||||||
BIO_free(in);
|
BIO_free(in);
|
||||||
BIO_free_all(out);
|
BIO_free_all(out);
|
||||||
if (canames) sk_STRING_free(canames);
|
if (canames) sk_OPENSSL_STRING_free(canames);
|
||||||
if(passin) OPENSSL_free(passin);
|
if(passin) OPENSSL_free(passin);
|
||||||
if(passout) OPENSSL_free(passout);
|
if(passout) OPENSSL_free(passout);
|
||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
@@ -923,7 +930,7 @@ int print_attribs (BIO *out, STACK_OF(X509_ATTRIBUTE) *attrlst,const char *name)
|
|||||||
av = sk_ASN1_TYPE_value(attr->value.set, 0);
|
av = sk_ASN1_TYPE_value(attr->value.set, 0);
|
||||||
switch(av->type) {
|
switch(av->type) {
|
||||||
case V_ASN1_BMPSTRING:
|
case V_ASN1_BMPSTRING:
|
||||||
value = uni2asc(av->value.bmpstring->data,
|
value = OPENSSL_uni2asc(av->value.bmpstring->data,
|
||||||
av->value.bmpstring->length);
|
av->value.bmpstring->length);
|
||||||
BIO_printf(out, "%s\n", value);
|
BIO_printf(out, "%s\n", value);
|
||||||
OPENSSL_free(value);
|
OPENSSL_free(value);
|
||||||
|
|||||||
@@ -82,9 +82,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
PKCS7 *p7=NULL;
|
PKCS7 *p7=NULL;
|
||||||
int i,badops=0;
|
int i,badops=0;
|
||||||
BIO *in=NULL,*out=NULL;
|
BIO *in=NULL,*out=NULL;
|
||||||
@@ -182,7 +179,7 @@ bad:
|
|||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
in=BIO_new(BIO_s_file());
|
in=BIO_new(BIO_s_file());
|
||||||
|
|||||||
@@ -275,7 +275,6 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
if (topk8)
|
if (topk8)
|
||||||
{
|
{
|
||||||
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)
|
||||||
@@ -404,6 +403,10 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf(bio_err, "DSA public key include in PrivateKey\n");
|
BIO_printf(bio_err, "DSA public key include in PrivateKey\n");
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case PKCS8_NEG_PRIVKEY:
|
||||||
|
BIO_printf(bio_err, "DSA private key value is negative\n");
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
BIO_printf(bio_err, "Unknown broken type\n");
|
BIO_printf(bio_err, "Unknown broken type\n");
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -74,7 +74,6 @@ int MAIN(int argc, char **argv)
|
|||||||
EVP_PKEY *pkey=NULL;
|
EVP_PKEY *pkey=NULL;
|
||||||
int badarg = 0;
|
int badarg = 0;
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
ENGINE *e = NULL;
|
|
||||||
char *engine=NULL;
|
char *engine=NULL;
|
||||||
#endif
|
#endif
|
||||||
int ret = 1;
|
int ret = 1;
|
||||||
@@ -141,7 +140,7 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (infile)
|
if (infile)
|
||||||
@@ -179,7 +178,7 @@ int MAIN(int argc, char **argv)
|
|||||||
pkey = PEM_read_bio_Parameters(in, NULL);
|
pkey = PEM_read_bio_Parameters(in, NULL);
|
||||||
if (!pkey)
|
if (!pkey)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err, "Error reading paramters\n");
|
BIO_printf(bio_err, "Error reading parameters\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -119,17 +119,17 @@ int MAIN(int argc, char **argv)
|
|||||||
if (!strcmp(*argv,"-in"))
|
if (!strcmp(*argv,"-in"))
|
||||||
{
|
{
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
infile= *(++argv);
|
else infile= *(++argv);
|
||||||
}
|
}
|
||||||
else if (!strcmp(*argv,"-out"))
|
else if (!strcmp(*argv,"-out"))
|
||||||
{
|
{
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
outfile= *(++argv);
|
else outfile= *(++argv);
|
||||||
}
|
}
|
||||||
else if (!strcmp(*argv,"-sigfile"))
|
else if (!strcmp(*argv,"-sigfile"))
|
||||||
{
|
{
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
sigfile= *(++argv);
|
else sigfile= *(++argv);
|
||||||
}
|
}
|
||||||
else if(!strcmp(*argv, "-inkey"))
|
else if(!strcmp(*argv, "-inkey"))
|
||||||
{
|
{
|
||||||
@@ -159,17 +159,17 @@ int MAIN(int argc, char **argv)
|
|||||||
else if (!strcmp(*argv,"-passin"))
|
else if (!strcmp(*argv,"-passin"))
|
||||||
{
|
{
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
passargin= *(++argv);
|
else passargin= *(++argv);
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-peerform") == 0)
|
else if (strcmp(*argv,"-peerform") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) badarg = 1;
|
if (--argc < 1) badarg = 1;
|
||||||
peerform=str2fmt(*(++argv));
|
else peerform=str2fmt(*(++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));
|
else keyform=str2fmt(*(++argv));
|
||||||
}
|
}
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
else if(!strcmp(*argv, "-engine"))
|
else if(!strcmp(*argv, "-engine"))
|
||||||
@@ -390,7 +390,7 @@ static void usage()
|
|||||||
BIO_printf(bio_err, "Usage: pkeyutl [options]\n");
|
BIO_printf(bio_err, "Usage: pkeyutl [options]\n");
|
||||||
BIO_printf(bio_err, "-in file input file\n");
|
BIO_printf(bio_err, "-in file input file\n");
|
||||||
BIO_printf(bio_err, "-out file output file\n");
|
BIO_printf(bio_err, "-out file output file\n");
|
||||||
BIO_printf(bio_err, "-signature file signature file (verify operation only)\n");
|
BIO_printf(bio_err, "-sigfile file signature file (verify operation only)\n");
|
||||||
BIO_printf(bio_err, "-inkey file input key\n");
|
BIO_printf(bio_err, "-inkey file input key\n");
|
||||||
BIO_printf(bio_err, "-keyform arg private key format - default PEM\n");
|
BIO_printf(bio_err, "-keyform arg private key format - default PEM\n");
|
||||||
BIO_printf(bio_err, "-pubin input is a public key\n");
|
BIO_printf(bio_err, "-pubin input is a public key\n");
|
||||||
|
|||||||
@@ -46,6 +46,7 @@ extern int engine_main(int argc,char *argv[]);
|
|||||||
extern int ocsp_main(int argc,char *argv[]);
|
extern int ocsp_main(int argc,char *argv[]);
|
||||||
extern int prime_main(int argc,char *argv[]);
|
extern int prime_main(int argc,char *argv[]);
|
||||||
extern int ts_main(int argc,char *argv[]);
|
extern int ts_main(int argc,char *argv[]);
|
||||||
|
extern int srp_main(int argc,char *argv[]);
|
||||||
|
|
||||||
#define FUNC_TYPE_GENERAL 1
|
#define FUNC_TYPE_GENERAL 1
|
||||||
#define FUNC_TYPE_MD 2
|
#define FUNC_TYPE_MD 2
|
||||||
@@ -142,9 +143,14 @@ FUNCTION functions[] = {
|
|||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
{FUNC_TYPE_GENERAL,"engine",engine_main},
|
{FUNC_TYPE_GENERAL,"engine",engine_main},
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_OCSP
|
||||||
{FUNC_TYPE_GENERAL,"ocsp",ocsp_main},
|
{FUNC_TYPE_GENERAL,"ocsp",ocsp_main},
|
||||||
|
#endif
|
||||||
{FUNC_TYPE_GENERAL,"prime",prime_main},
|
{FUNC_TYPE_GENERAL,"prime",prime_main},
|
||||||
{FUNC_TYPE_GENERAL,"ts",ts_main},
|
{FUNC_TYPE_GENERAL,"ts",ts_main},
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
{FUNC_TYPE_GENERAL,"srp",srp_main},
|
||||||
|
#endif
|
||||||
#ifndef OPENSSL_NO_MD2
|
#ifndef OPENSSL_NO_MD2
|
||||||
{FUNC_TYPE_MD,"md2",dgst_main},
|
{FUNC_TYPE_MD,"md2",dgst_main},
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ typedef struct {
|
|||||||
const char *name;
|
const char *name;
|
||||||
int (*func)(int argc,char *argv[]);
|
int (*func)(int argc,char *argv[]);
|
||||||
} FUNCTION;
|
} FUNCTION;
|
||||||
|
DECLARE_LHASH_OF(FUNCTION);
|
||||||
|
|
||||||
FUNCTION functions[] = {
|
FUNCTION functions[] = {
|
||||||
EOF
|
EOF
|
||||||
@@ -48,6 +49,10 @@ foreach (@ARGV)
|
|||||||
{ print "#if !defined(OPENSSL_NO_DES) && !defined(OPENSSL_NO_SHA1)\n${str}#endif\n"; }
|
{ print "#if !defined(OPENSSL_NO_DES) && !defined(OPENSSL_NO_SHA1)\n${str}#endif\n"; }
|
||||||
elsif ( ($_ =~ /^cms$/))
|
elsif ( ($_ =~ /^cms$/))
|
||||||
{ print "#ifndef OPENSSL_NO_CMS\n${str}#endif\n"; }
|
{ print "#ifndef OPENSSL_NO_CMS\n${str}#endif\n"; }
|
||||||
|
elsif ( ($_ =~ /^ocsp$/))
|
||||||
|
{ print "#ifndef OPENSSL_NO_OCSP\n${str}#endif\n"; }
|
||||||
|
elsif ( ($_ =~ /^srp$/))
|
||||||
|
{ print "#ifndef OPENSSL_NO_SRP\n${str}#endif\n"; }
|
||||||
else
|
else
|
||||||
{ print $str; }
|
{ print $str; }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -77,9 +77,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
int i, r, ret = 1;
|
int i, r, ret = 1;
|
||||||
int badopt;
|
int badopt;
|
||||||
char *outfile = NULL;
|
char *outfile = NULL;
|
||||||
@@ -178,7 +175,7 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine, 0);
|
setup_engine(bio_err, engine, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
app_RAND_load_file(NULL, bio_err, (inrand != NULL));
|
app_RAND_load_file(NULL, bio_err, (inrand != NULL));
|
||||||
|
|||||||
119
apps/req.c
119
apps/req.c
@@ -165,7 +165,7 @@ int MAIN(int argc, char **argv)
|
|||||||
EVP_PKEY_CTX *genctx = NULL;
|
EVP_PKEY_CTX *genctx = NULL;
|
||||||
const char *keyalg = NULL;
|
const char *keyalg = NULL;
|
||||||
char *keyalgstr = NULL;
|
char *keyalgstr = NULL;
|
||||||
STACK_OF(STRING) *pkeyopts = NULL;
|
STACK_OF(OPENSSL_STRING) *pkeyopts = NULL, *sigopts = NULL;
|
||||||
EVP_PKEY *pkey=NULL;
|
EVP_PKEY *pkey=NULL;
|
||||||
int i=0,badops=0,newreq=0,verbose=0,pkey_type=-1;
|
int i=0,badops=0,newreq=0,verbose=0,pkey_type=-1;
|
||||||
long newkey = -1;
|
long newkey = -1;
|
||||||
@@ -306,8 +306,17 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1)
|
if (--argc < 1)
|
||||||
goto bad;
|
goto bad;
|
||||||
if (!pkeyopts)
|
if (!pkeyopts)
|
||||||
pkeyopts = sk_STRING_new_null();
|
pkeyopts = sk_OPENSSL_STRING_new_null();
|
||||||
if (!pkeyopts || !sk_STRING_push(pkeyopts, *(++argv)))
|
if (!pkeyopts || !sk_OPENSSL_STRING_push(pkeyopts, *(++argv)))
|
||||||
|
goto bad;
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-sigopt") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1)
|
||||||
|
goto bad;
|
||||||
|
if (!sigopts)
|
||||||
|
sigopts = sk_OPENSSL_STRING_new_null();
|
||||||
|
if (!sigopts || !sk_OPENSSL_STRING_push(sigopts, *(++argv)))
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-batch") == 0)
|
else if (strcmp(*argv,"-batch") == 0)
|
||||||
@@ -365,11 +374,6 @@ int MAIN(int argc, char **argv)
|
|||||||
serial = s2i_ASN1_INTEGER(NULL, *(++argv));
|
serial = s2i_ASN1_INTEGER(NULL, *(++argv));
|
||||||
if (!serial) goto bad;
|
if (!serial) goto bad;
|
||||||
}
|
}
|
||||||
else if ((md_alg=EVP_get_digestbyname(&((*argv)[1]))) != NULL)
|
|
||||||
{
|
|
||||||
/* ok */
|
|
||||||
digest=md_alg;
|
|
||||||
}
|
|
||||||
else if (strcmp(*argv,"-extensions") == 0)
|
else if (strcmp(*argv,"-extensions") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
@@ -380,6 +384,11 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
req_exts = *(++argv);
|
req_exts = *(++argv);
|
||||||
}
|
}
|
||||||
|
else if ((md_alg=EVP_get_digestbyname(&((*argv)[1]))) != NULL)
|
||||||
|
{
|
||||||
|
/* ok */
|
||||||
|
digest=md_alg;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
||||||
@@ -667,9 +676,9 @@ bad:
|
|||||||
if (pkeyopts)
|
if (pkeyopts)
|
||||||
{
|
{
|
||||||
char *genopt;
|
char *genopt;
|
||||||
for (i = 0; i < sk_STRING_num(pkeyopts); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(pkeyopts); i++)
|
||||||
{
|
{
|
||||||
genopt = sk_STRING_value(pkeyopts, i);
|
genopt = sk_OPENSSL_STRING_value(pkeyopts, i);
|
||||||
if (pkey_ctrl_string(genctx, genopt) <= 0)
|
if (pkey_ctrl_string(genctx, genopt) <= 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,
|
BIO_printf(bio_err,
|
||||||
@@ -859,7 +868,8 @@ loop:
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(i=X509_sign(x509ss,pkey,digest)))
|
i=do_X509_sign(bio_err, x509ss, pkey, digest, sigopts);
|
||||||
|
if (!i)
|
||||||
{
|
{
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
goto end;
|
goto end;
|
||||||
@@ -883,7 +893,8 @@ loop:
|
|||||||
req_exts);
|
req_exts);
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
if (!(i=X509_REQ_sign(req,pkey,digest)))
|
i=do_X509_REQ_sign(bio_err, req, pkey, digest, sigopts);
|
||||||
|
if (!i)
|
||||||
{
|
{
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
goto end;
|
goto end;
|
||||||
@@ -1083,7 +1094,9 @@ end:
|
|||||||
if (genctx)
|
if (genctx)
|
||||||
EVP_PKEY_CTX_free(genctx);
|
EVP_PKEY_CTX_free(genctx);
|
||||||
if (pkeyopts)
|
if (pkeyopts)
|
||||||
sk_STRING_free(pkeyopts);
|
sk_OPENSSL_STRING_free(pkeyopts);
|
||||||
|
if (sigopts)
|
||||||
|
sk_OPENSSL_STRING_free(sigopts);
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
if (gen_eng)
|
if (gen_eng)
|
||||||
ENGINE_free(gen_eng);
|
ENGINE_free(gen_eng);
|
||||||
@@ -1336,11 +1349,17 @@ start2: for (;;)
|
|||||||
|
|
||||||
BIO_snprintf(buf,sizeof 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))
|
||||||
|
{
|
||||||
|
ERR_clear_error();
|
||||||
n_min = -1;
|
n_min = -1;
|
||||||
|
}
|
||||||
|
|
||||||
BIO_snprintf(buf,sizeof 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))
|
||||||
|
{
|
||||||
|
ERR_clear_error();
|
||||||
n_max = -1;
|
n_max = -1;
|
||||||
|
}
|
||||||
|
|
||||||
if (!add_attribute_object(req,
|
if (!add_attribute_object(req,
|
||||||
v->value,def,value,nid,n_min,n_max, chtype))
|
v->value,def,value,nid,n_min,n_max, chtype))
|
||||||
@@ -1441,7 +1460,8 @@ start:
|
|||||||
buf[0]='\0';
|
buf[0]='\0';
|
||||||
if (!batch)
|
if (!batch)
|
||||||
{
|
{
|
||||||
fgets(buf,sizeof buf,stdin);
|
if (!fgets(buf,sizeof buf,stdin))
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -1499,7 +1519,8 @@ start:
|
|||||||
buf[0]='\0';
|
buf[0]='\0';
|
||||||
if (!batch)
|
if (!batch)
|
||||||
{
|
{
|
||||||
fgets(buf,sizeof buf,stdin);
|
if (!fgets(buf,sizeof buf,stdin))
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -1715,7 +1736,7 @@ static EVP_PKEY_CTX *set_keygen_ctx(BIO *err, const char *gstr, int *pkey_type,
|
|||||||
ERR_print_errors(err);
|
ERR_print_errors(err);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_RSA
|
||||||
if ((*pkey_type == EVP_PKEY_RSA) && (keylen != -1))
|
if ((*pkey_type == EVP_PKEY_RSA) && (keylen != -1))
|
||||||
{
|
{
|
||||||
if (EVP_PKEY_CTX_set_rsa_keygen_bits(gctx, keylen) <= 0)
|
if (EVP_PKEY_CTX_set_rsa_keygen_bits(gctx, keylen) <= 0)
|
||||||
@@ -1726,6 +1747,7 @@ static EVP_PKEY_CTX *set_keygen_ctx(BIO *err, const char *gstr, int *pkey_type,
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
return gctx;
|
return gctx;
|
||||||
}
|
}
|
||||||
@@ -1747,3 +1769,68 @@ static int genpkey_cb(EVP_PKEY_CTX *ctx)
|
|||||||
#endif
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int do_sign_init(BIO *err, EVP_MD_CTX *ctx, EVP_PKEY *pkey,
|
||||||
|
const EVP_MD *md, STACK_OF(OPENSSL_STRING) *sigopts)
|
||||||
|
{
|
||||||
|
EVP_PKEY_CTX *pkctx = NULL;
|
||||||
|
int i;
|
||||||
|
EVP_MD_CTX_init(ctx);
|
||||||
|
if (!EVP_DigestSignInit(ctx, &pkctx, md, NULL, pkey))
|
||||||
|
return 0;
|
||||||
|
for (i = 0; i < sk_OPENSSL_STRING_num(sigopts); i++)
|
||||||
|
{
|
||||||
|
char *sigopt = sk_OPENSSL_STRING_value(sigopts, i);
|
||||||
|
if (pkey_ctrl_string(pkctx, sigopt) <= 0)
|
||||||
|
{
|
||||||
|
BIO_printf(err, "parameter error \"%s\"\n", sigopt);
|
||||||
|
ERR_print_errors(bio_err);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int do_X509_sign(BIO *err, X509 *x, EVP_PKEY *pkey, const EVP_MD *md,
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts)
|
||||||
|
{
|
||||||
|
int rv;
|
||||||
|
EVP_MD_CTX mctx;
|
||||||
|
EVP_MD_CTX_init(&mctx);
|
||||||
|
rv = do_sign_init(err, &mctx, pkey, md, sigopts);
|
||||||
|
if (rv > 0)
|
||||||
|
rv = X509_sign_ctx(x, &mctx);
|
||||||
|
EVP_MD_CTX_cleanup(&mctx);
|
||||||
|
return rv > 0 ? 1 : 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int do_X509_REQ_sign(BIO *err, X509_REQ *x, EVP_PKEY *pkey, const EVP_MD *md,
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts)
|
||||||
|
{
|
||||||
|
int rv;
|
||||||
|
EVP_MD_CTX mctx;
|
||||||
|
EVP_MD_CTX_init(&mctx);
|
||||||
|
rv = do_sign_init(err, &mctx, pkey, md, sigopts);
|
||||||
|
if (rv > 0)
|
||||||
|
rv = X509_REQ_sign_ctx(x, &mctx);
|
||||||
|
EVP_MD_CTX_cleanup(&mctx);
|
||||||
|
return rv > 0 ? 1 : 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
int do_X509_CRL_sign(BIO *err, X509_CRL *x, EVP_PKEY *pkey, const EVP_MD *md,
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts)
|
||||||
|
{
|
||||||
|
int rv;
|
||||||
|
EVP_MD_CTX mctx;
|
||||||
|
EVP_MD_CTX_init(&mctx);
|
||||||
|
rv = do_sign_init(err, &mctx, pkey, md, sigopts);
|
||||||
|
if (rv > 0)
|
||||||
|
rv = X509_CRL_sign_ctx(x, &mctx);
|
||||||
|
EVP_MD_CTX_cleanup(&mctx);
|
||||||
|
return rv > 0 ? 1 : 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -409,6 +409,7 @@ bad:
|
|||||||
}
|
}
|
||||||
else i=PEM_write_bio_RSAPrivateKey(out,rsa,
|
else i=PEM_write_bio_RSAPrivateKey(out,rsa,
|
||||||
enc,NULL,0,NULL,passout);
|
enc,NULL,0,NULL,passout);
|
||||||
|
#if !defined(OPENSSL_NO_DSA) && !defined(OPENSSL_NO_RC4)
|
||||||
} else if (outformat == FORMAT_MSBLOB || outformat == FORMAT_PVK) {
|
} else if (outformat == FORMAT_MSBLOB || outformat == FORMAT_PVK) {
|
||||||
EVP_PKEY *pk;
|
EVP_PKEY *pk;
|
||||||
pk = EVP_PKEY_new();
|
pk = EVP_PKEY_new();
|
||||||
@@ -420,11 +421,12 @@ bad:
|
|||||||
else
|
else
|
||||||
i = i2b_PrivateKey_bio(out, pk);
|
i = i2b_PrivateKey_bio(out, pk);
|
||||||
EVP_PKEY_free(pk);
|
EVP_PKEY_free(pk);
|
||||||
|
#endif
|
||||||
} else {
|
} else {
|
||||||
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
if (!i)
|
if (i <= 0)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"unable to write key\n");
|
BIO_printf(bio_err,"unable to write key\n");
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
|
|||||||
@@ -342,4 +342,10 @@ static void usage()
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#else /* !OPENSSL_NO_RSA */
|
||||||
|
|
||||||
|
# if PEDANTIC
|
||||||
|
static void *dummy=&dummy;
|
||||||
|
# endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -171,3 +171,6 @@ void MS_CALLBACK tlsext_cb(SSL *s, int client_server, int type,
|
|||||||
unsigned char *data, int len,
|
unsigned char *data, int len,
|
||||||
void *arg);
|
void *arg);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
int MS_CALLBACK generate_cookie_callback(SSL *ssl, unsigned char *cookie, unsigned int *cookie_len);
|
||||||
|
int MS_CALLBACK verify_cookie_callback(SSL *ssl, unsigned char *cookie, unsigned int cookie_len);
|
||||||
|
|||||||
292
apps/s_cb.c
292
apps/s_cb.c
@@ -117,17 +117,21 @@
|
|||||||
#undef NON_MAIN
|
#undef NON_MAIN
|
||||||
#undef USE_SOCKETS
|
#undef USE_SOCKETS
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
|
#include <openssl/rand.h>
|
||||||
#include <openssl/x509.h>
|
#include <openssl/x509.h>
|
||||||
#include <openssl/ssl.h>
|
#include <openssl/ssl.h>
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
|
|
||||||
|
#define COOKIE_SECRET_LENGTH 16
|
||||||
|
|
||||||
int verify_depth=0;
|
int verify_depth=0;
|
||||||
int verify_error=X509_V_OK;
|
int verify_error=X509_V_OK;
|
||||||
int verify_return_error=0;
|
int verify_return_error=0;
|
||||||
|
unsigned char cookie_secret[COOKIE_SECRET_LENGTH];
|
||||||
|
int cookie_initialized=0;
|
||||||
|
|
||||||
int MS_CALLBACK verify_callback(int ok, X509_STORE_CTX *ctx)
|
int MS_CALLBACK verify_callback(int ok, X509_STORE_CTX *ctx)
|
||||||
{
|
{
|
||||||
char buf[256];
|
|
||||||
X509 *err_cert;
|
X509 *err_cert;
|
||||||
int err,depth;
|
int err,depth;
|
||||||
|
|
||||||
@@ -135,8 +139,15 @@ int MS_CALLBACK verify_callback(int ok, X509_STORE_CTX *ctx)
|
|||||||
err= X509_STORE_CTX_get_error(ctx);
|
err= X509_STORE_CTX_get_error(ctx);
|
||||||
depth= X509_STORE_CTX_get_error_depth(ctx);
|
depth= X509_STORE_CTX_get_error_depth(ctx);
|
||||||
|
|
||||||
X509_NAME_oneline(X509_get_subject_name(err_cert),buf,sizeof buf);
|
BIO_printf(bio_err,"depth=%d ",depth);
|
||||||
BIO_printf(bio_err,"depth=%d %s\n",depth,buf);
|
if (err_cert)
|
||||||
|
{
|
||||||
|
X509_NAME_print_ex(bio_err, X509_get_subject_name(err_cert),
|
||||||
|
0, XN_FLAG_ONELINE);
|
||||||
|
BIO_puts(bio_err, "\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
BIO_puts(bio_err, "<no cert>\n");
|
||||||
if (!ok)
|
if (!ok)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"verify error:num=%d:%s\n",err,
|
BIO_printf(bio_err,"verify error:num=%d:%s\n",err,
|
||||||
@@ -153,25 +164,33 @@ int MS_CALLBACK verify_callback(int ok, X509_STORE_CTX *ctx)
|
|||||||
verify_error=X509_V_ERR_CERT_CHAIN_TOO_LONG;
|
verify_error=X509_V_ERR_CERT_CHAIN_TOO_LONG;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
switch (ctx->error)
|
switch (err)
|
||||||
{
|
{
|
||||||
case X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT:
|
case X509_V_ERR_UNABLE_TO_GET_ISSUER_CERT:
|
||||||
X509_NAME_oneline(X509_get_issuer_name(ctx->current_cert),buf,sizeof buf);
|
BIO_puts(bio_err,"issuer= ");
|
||||||
BIO_printf(bio_err,"issuer= %s\n",buf);
|
X509_NAME_print_ex(bio_err, X509_get_issuer_name(err_cert),
|
||||||
|
0, XN_FLAG_ONELINE);
|
||||||
|
BIO_puts(bio_err, "\n");
|
||||||
break;
|
break;
|
||||||
case X509_V_ERR_CERT_NOT_YET_VALID:
|
case X509_V_ERR_CERT_NOT_YET_VALID:
|
||||||
case X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD:
|
case X509_V_ERR_ERROR_IN_CERT_NOT_BEFORE_FIELD:
|
||||||
BIO_printf(bio_err,"notBefore=");
|
BIO_printf(bio_err,"notBefore=");
|
||||||
ASN1_TIME_print(bio_err,X509_get_notBefore(ctx->current_cert));
|
ASN1_TIME_print(bio_err,X509_get_notBefore(err_cert));
|
||||||
BIO_printf(bio_err,"\n");
|
BIO_printf(bio_err,"\n");
|
||||||
break;
|
break;
|
||||||
case X509_V_ERR_CERT_HAS_EXPIRED:
|
case X509_V_ERR_CERT_HAS_EXPIRED:
|
||||||
case X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD:
|
case X509_V_ERR_ERROR_IN_CERT_NOT_AFTER_FIELD:
|
||||||
BIO_printf(bio_err,"notAfter=");
|
BIO_printf(bio_err,"notAfter=");
|
||||||
ASN1_TIME_print(bio_err,X509_get_notAfter(ctx->current_cert));
|
ASN1_TIME_print(bio_err,X509_get_notAfter(err_cert));
|
||||||
BIO_printf(bio_err,"\n");
|
BIO_printf(bio_err,"\n");
|
||||||
break;
|
break;
|
||||||
|
case X509_V_ERR_NO_EXPLICIT_POLICY:
|
||||||
|
policies_print(bio_err, ctx);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
if (err == X509_V_OK && ok == 2)
|
||||||
|
policies_print(bio_err, ctx);
|
||||||
|
|
||||||
BIO_printf(bio_err,"verify return:%d\n",ok);
|
BIO_printf(bio_err,"verify return:%d\n",ok);
|
||||||
return(ok);
|
return(ok);
|
||||||
}
|
}
|
||||||
@@ -338,6 +357,18 @@ void MS_CALLBACK msg_cb(int write_p, int version, int content_type, const void *
|
|||||||
case TLS1_VERSION:
|
case TLS1_VERSION:
|
||||||
str_version = "TLS 1.0 ";
|
str_version = "TLS 1.0 ";
|
||||||
break;
|
break;
|
||||||
|
case TLS1_1_VERSION:
|
||||||
|
str_version = "TLS 1.1 ";
|
||||||
|
break;
|
||||||
|
case TLS1_2_VERSION:
|
||||||
|
str_version = "TLS 1.2 ";
|
||||||
|
break;
|
||||||
|
case DTLS1_VERSION:
|
||||||
|
str_version = "DTLS 1.0 ";
|
||||||
|
break;
|
||||||
|
case DTLS1_BAD_VER:
|
||||||
|
str_version = "DTLS 1.0 (bad) ";
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
str_version = "???";
|
str_version = "???";
|
||||||
}
|
}
|
||||||
@@ -403,7 +434,12 @@ void MS_CALLBACK msg_cb(int write_p, int version, int content_type, const void *
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (version == SSL3_VERSION || version == TLS1_VERSION)
|
if (version == SSL3_VERSION ||
|
||||||
|
version == TLS1_VERSION ||
|
||||||
|
version == TLS1_1_VERSION ||
|
||||||
|
version == TLS1_2_VERSION ||
|
||||||
|
version == DTLS1_VERSION ||
|
||||||
|
version == DTLS1_BAD_VER)
|
||||||
{
|
{
|
||||||
switch (content_type)
|
switch (content_type)
|
||||||
{
|
{
|
||||||
@@ -521,6 +557,9 @@ void MS_CALLBACK msg_cb(int write_p, int version, int content_type, const void *
|
|||||||
case 114:
|
case 114:
|
||||||
str_details2 = " bad_certificate_hash_value";
|
str_details2 = " bad_certificate_hash_value";
|
||||||
break;
|
break;
|
||||||
|
case 115:
|
||||||
|
str_details2 = " unknown_psk_identity";
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -542,6 +581,9 @@ void MS_CALLBACK msg_cb(int write_p, int version, int content_type, const void *
|
|||||||
case 2:
|
case 2:
|
||||||
str_details1 = ", ServerHello";
|
str_details1 = ", ServerHello";
|
||||||
break;
|
break;
|
||||||
|
case 3:
|
||||||
|
str_details1 = ", HelloVerifyRequest";
|
||||||
|
break;
|
||||||
case 11:
|
case 11:
|
||||||
str_details1 = ", Certificate";
|
str_details1 = ", Certificate";
|
||||||
break;
|
break;
|
||||||
@@ -566,6 +608,26 @@ void MS_CALLBACK msg_cb(int write_p, int version, int content_type, const void *
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_HEARTBEATS
|
||||||
|
if (content_type == 24) /* Heartbeat */
|
||||||
|
{
|
||||||
|
str_details1 = ", Heartbeat";
|
||||||
|
|
||||||
|
if (len > 0)
|
||||||
|
{
|
||||||
|
switch (((const unsigned char*)buf)[0])
|
||||||
|
{
|
||||||
|
case 1:
|
||||||
|
str_details1 = ", HeartbeatRequest";
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
str_details1 = ", HeartbeatResponse";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
BIO_printf(bio, "%s %s%s [length %04lx]%s%s\n", str_write_p, str_version, str_content_type, (unsigned long)len, str_details1, str_details2);
|
BIO_printf(bio, "%s %s%s [length %04lx]%s%s\n", str_write_p, str_version, str_content_type, (unsigned long)len, str_details1, str_details2);
|
||||||
@@ -626,6 +688,22 @@ void MS_CALLBACK tlsext_cb(SSL *s, int client_server, int type,
|
|||||||
extname = "status request";
|
extname = "status request";
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_user_mapping:
|
||||||
|
extname = "user mapping";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_client_authz:
|
||||||
|
extname = "client authz";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_server_authz:
|
||||||
|
extname = "server authz";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_cert_type:
|
||||||
|
extname = "cert type";
|
||||||
|
break;
|
||||||
|
|
||||||
case TLSEXT_TYPE_elliptic_curves:
|
case TLSEXT_TYPE_elliptic_curves:
|
||||||
extname = "elliptic curves";
|
extname = "elliptic curves";
|
||||||
break;
|
break;
|
||||||
@@ -634,8 +712,28 @@ void MS_CALLBACK tlsext_cb(SSL *s, int client_server, int type,
|
|||||||
extname = "EC point formats";
|
extname = "EC point formats";
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_srp:
|
||||||
|
extname = "SRP";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_signature_algorithms:
|
||||||
|
extname = "signature algorithms";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_use_srtp:
|
||||||
|
extname = "use SRTP";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_heartbeat:
|
||||||
|
extname = "heartbeat";
|
||||||
|
break;
|
||||||
|
|
||||||
case TLSEXT_TYPE_session_ticket:
|
case TLSEXT_TYPE_session_ticket:
|
||||||
extname = "server ticket";
|
extname = "session ticket";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case TLSEXT_TYPE_renegotiate:
|
||||||
|
extname = "renegotiation info";
|
||||||
break;
|
break;
|
||||||
|
|
||||||
#ifdef TLSEXT_TYPE_opaque_prf_input
|
#ifdef TLSEXT_TYPE_opaque_prf_input
|
||||||
@@ -643,6 +741,11 @@ void MS_CALLBACK tlsext_cb(SSL *s, int client_server, int type,
|
|||||||
extname = "opaque PRF input";
|
extname = "opaque PRF input";
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef TLSEXT_TYPE_next_proto_neg
|
||||||
|
case TLSEXT_TYPE_next_proto_neg:
|
||||||
|
extname = "next protocol";
|
||||||
|
break;
|
||||||
|
#endif
|
||||||
|
|
||||||
default:
|
default:
|
||||||
extname = "unknown";
|
extname = "unknown";
|
||||||
@@ -656,3 +759,172 @@ void MS_CALLBACK tlsext_cb(SSL *s, int client_server, int type,
|
|||||||
BIO_dump(bio, (char *)data, len);
|
BIO_dump(bio, (char *)data, len);
|
||||||
(void)BIO_flush(bio);
|
(void)BIO_flush(bio);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int MS_CALLBACK generate_cookie_callback(SSL *ssl, unsigned char *cookie, unsigned int *cookie_len)
|
||||||
|
{
|
||||||
|
unsigned char *buffer, result[EVP_MAX_MD_SIZE];
|
||||||
|
unsigned int length, resultlength;
|
||||||
|
union {
|
||||||
|
struct sockaddr sa;
|
||||||
|
struct sockaddr_in s4;
|
||||||
|
#if OPENSSL_USE_IPV6
|
||||||
|
struct sockaddr_in6 s6;
|
||||||
|
#endif
|
||||||
|
} peer;
|
||||||
|
|
||||||
|
/* Initialize a random secret */
|
||||||
|
if (!cookie_initialized)
|
||||||
|
{
|
||||||
|
if (!RAND_bytes(cookie_secret, COOKIE_SECRET_LENGTH))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"error setting random cookie secret\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
cookie_initialized = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Read peer information */
|
||||||
|
(void)BIO_dgram_get_peer(SSL_get_rbio(ssl), &peer);
|
||||||
|
|
||||||
|
/* Create buffer with peer's address and port */
|
||||||
|
length = 0;
|
||||||
|
switch (peer.sa.sa_family)
|
||||||
|
{
|
||||||
|
case AF_INET:
|
||||||
|
length += sizeof(struct in_addr);
|
||||||
|
length += sizeof(peer.s4.sin_port);
|
||||||
|
break;
|
||||||
|
#if OPENSSL_USE_IPV6
|
||||||
|
case AF_INET6:
|
||||||
|
length += sizeof(struct in6_addr);
|
||||||
|
length += sizeof(peer.s6.sin6_port);
|
||||||
|
break;
|
||||||
|
#endif
|
||||||
|
default:
|
||||||
|
OPENSSL_assert(0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
buffer = OPENSSL_malloc(length);
|
||||||
|
|
||||||
|
if (buffer == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"out of memory\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
switch (peer.sa.sa_family)
|
||||||
|
{
|
||||||
|
case AF_INET:
|
||||||
|
memcpy(buffer,
|
||||||
|
&peer.s4.sin_port,
|
||||||
|
sizeof(peer.s4.sin_port));
|
||||||
|
memcpy(buffer + sizeof(peer.s4.sin_port),
|
||||||
|
&peer.s4.sin_addr,
|
||||||
|
sizeof(struct in_addr));
|
||||||
|
break;
|
||||||
|
#if OPENSSL_USE_IPV6
|
||||||
|
case AF_INET6:
|
||||||
|
memcpy(buffer,
|
||||||
|
&peer.s6.sin6_port,
|
||||||
|
sizeof(peer.s6.sin6_port));
|
||||||
|
memcpy(buffer + sizeof(peer.s6.sin6_port),
|
||||||
|
&peer.s6.sin6_addr,
|
||||||
|
sizeof(struct in6_addr));
|
||||||
|
break;
|
||||||
|
#endif
|
||||||
|
default:
|
||||||
|
OPENSSL_assert(0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Calculate HMAC of buffer using the secret */
|
||||||
|
HMAC(EVP_sha1(), cookie_secret, COOKIE_SECRET_LENGTH,
|
||||||
|
buffer, length, result, &resultlength);
|
||||||
|
OPENSSL_free(buffer);
|
||||||
|
|
||||||
|
memcpy(cookie, result, resultlength);
|
||||||
|
*cookie_len = resultlength;
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
int MS_CALLBACK verify_cookie_callback(SSL *ssl, unsigned char *cookie, unsigned int cookie_len)
|
||||||
|
{
|
||||||
|
unsigned char *buffer, result[EVP_MAX_MD_SIZE];
|
||||||
|
unsigned int length, resultlength;
|
||||||
|
union {
|
||||||
|
struct sockaddr sa;
|
||||||
|
struct sockaddr_in s4;
|
||||||
|
#if OPENSSL_USE_IPV6
|
||||||
|
struct sockaddr_in6 s6;
|
||||||
|
#endif
|
||||||
|
} peer;
|
||||||
|
|
||||||
|
/* If secret isn't initialized yet, the cookie can't be valid */
|
||||||
|
if (!cookie_initialized)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
/* Read peer information */
|
||||||
|
(void)BIO_dgram_get_peer(SSL_get_rbio(ssl), &peer);
|
||||||
|
|
||||||
|
/* Create buffer with peer's address and port */
|
||||||
|
length = 0;
|
||||||
|
switch (peer.sa.sa_family)
|
||||||
|
{
|
||||||
|
case AF_INET:
|
||||||
|
length += sizeof(struct in_addr);
|
||||||
|
length += sizeof(peer.s4.sin_port);
|
||||||
|
break;
|
||||||
|
#if OPENSSL_USE_IPV6
|
||||||
|
case AF_INET6:
|
||||||
|
length += sizeof(struct in6_addr);
|
||||||
|
length += sizeof(peer.s6.sin6_port);
|
||||||
|
break;
|
||||||
|
#endif
|
||||||
|
default:
|
||||||
|
OPENSSL_assert(0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
buffer = OPENSSL_malloc(length);
|
||||||
|
|
||||||
|
if (buffer == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"out of memory\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
switch (peer.sa.sa_family)
|
||||||
|
{
|
||||||
|
case AF_INET:
|
||||||
|
memcpy(buffer,
|
||||||
|
&peer.s4.sin_port,
|
||||||
|
sizeof(peer.s4.sin_port));
|
||||||
|
memcpy(buffer + sizeof(peer.s4.sin_port),
|
||||||
|
&peer.s4.sin_addr,
|
||||||
|
sizeof(struct in_addr));
|
||||||
|
break;
|
||||||
|
#if OPENSSL_USE_IPV6
|
||||||
|
case AF_INET6:
|
||||||
|
memcpy(buffer,
|
||||||
|
&peer.s6.sin6_port,
|
||||||
|
sizeof(peer.s6.sin6_port));
|
||||||
|
memcpy(buffer + sizeof(peer.s6.sin6_port),
|
||||||
|
&peer.s6.sin6_addr,
|
||||||
|
sizeof(struct in6_addr));
|
||||||
|
break;
|
||||||
|
#endif
|
||||||
|
default:
|
||||||
|
OPENSSL_assert(0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Calculate HMAC of buffer using the secret */
|
||||||
|
HMAC(EVP_sha1(), cookie_secret, COOKIE_SECRET_LENGTH,
|
||||||
|
buffer, length, result, &resultlength);
|
||||||
|
OPENSSL_free(buffer);
|
||||||
|
|
||||||
|
if (cookie_len == resultlength && memcmp(result, cookie, resultlength) == 0)
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|||||||
475
apps/s_client.c
475
apps/s_client.c
@@ -163,6 +163,9 @@ typedef unsigned int u_int;
|
|||||||
#include <openssl/rand.h>
|
#include <openssl/rand.h>
|
||||||
#include <openssl/ocsp.h>
|
#include <openssl/ocsp.h>
|
||||||
#include <openssl/bn.h>
|
#include <openssl/bn.h>
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
#include <openssl/srp.h>
|
||||||
|
#endif
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
#include "timeouts.h"
|
#include "timeouts.h"
|
||||||
|
|
||||||
@@ -203,6 +206,9 @@ static int c_status_req=0;
|
|||||||
static int c_msg=0;
|
static int c_msg=0;
|
||||||
static int c_showcerts=0;
|
static int c_showcerts=0;
|
||||||
|
|
||||||
|
static char *keymatexportlabel=NULL;
|
||||||
|
static int keymatexportlen=20;
|
||||||
|
|
||||||
static void sc_usage(void);
|
static void sc_usage(void);
|
||||||
static void print_stuff(BIO *berr,SSL *con,int full);
|
static void print_stuff(BIO *berr,SSL *con,int full);
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
@@ -315,13 +321,22 @@ static void sc_usage(void)
|
|||||||
# ifndef OPENSSL_NO_JPAKE
|
# ifndef OPENSSL_NO_JPAKE
|
||||||
BIO_printf(bio_err," -jpake arg - JPAKE secret to use\n");
|
BIO_printf(bio_err," -jpake arg - JPAKE secret to use\n");
|
||||||
# endif
|
# endif
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
BIO_printf(bio_err," -srpuser user - SRP authentification for 'user'\n");
|
||||||
|
BIO_printf(bio_err," -srppass arg - password for 'user'\n");
|
||||||
|
BIO_printf(bio_err," -srp_lateuser - SRP username into second ClientHello message\n");
|
||||||
|
BIO_printf(bio_err," -srp_moregroups - Tolerate other than the known g N values.\n");
|
||||||
|
BIO_printf(bio_err," -srp_strength int - minimal mength in bits for N (default %d).\n",SRP_MINIMAL_N);
|
||||||
#endif
|
#endif
|
||||||
BIO_printf(bio_err," -ssl2 - just use SSLv2\n");
|
BIO_printf(bio_err," -ssl2 - just use SSLv2\n");
|
||||||
BIO_printf(bio_err," -ssl3 - just use SSLv3\n");
|
BIO_printf(bio_err," -ssl3 - just use SSLv3\n");
|
||||||
|
BIO_printf(bio_err," -tls1_2 - just use TLSv1.2\n");
|
||||||
|
BIO_printf(bio_err," -tls1_1 - just use TLSv1.1\n");
|
||||||
BIO_printf(bio_err," -tls1 - just use TLSv1\n");
|
BIO_printf(bio_err," -tls1 - just use TLSv1\n");
|
||||||
BIO_printf(bio_err," -dtls1 - just use DTLSv1\n");
|
BIO_printf(bio_err," -dtls1 - just use DTLSv1\n");
|
||||||
BIO_printf(bio_err," -mtu - set the MTU\n");
|
BIO_printf(bio_err," -mtu - set the link layer MTU\n");
|
||||||
BIO_printf(bio_err," -no_tls1/-no_ssl3/-no_ssl2 - turn off that protocol\n");
|
BIO_printf(bio_err," -no_tls1_2/-no_tls1_1/-no_tls1/-no_ssl3/-no_ssl2 - turn off that protocol\n");
|
||||||
BIO_printf(bio_err," -bugs - Switch on all SSL implementation bug workarounds\n");
|
BIO_printf(bio_err," -bugs - Switch on all SSL implementation bug workarounds\n");
|
||||||
BIO_printf(bio_err," -serverpref - Use server's cipher preferences (only SSLv2)\n");
|
BIO_printf(bio_err," -serverpref - Use server's cipher preferences (only SSLv2)\n");
|
||||||
BIO_printf(bio_err," -cipher - preferred cipher to use, use the 'openssl ciphers'\n");
|
BIO_printf(bio_err," -cipher - preferred cipher to use, use the 'openssl ciphers'\n");
|
||||||
@@ -342,7 +357,16 @@ static void sc_usage(void)
|
|||||||
BIO_printf(bio_err," -tlsextdebug - hex dump of all TLS extensions received\n");
|
BIO_printf(bio_err," -tlsextdebug - hex dump of all TLS extensions received\n");
|
||||||
BIO_printf(bio_err," -status - request certificate status from server\n");
|
BIO_printf(bio_err," -status - request certificate status from server\n");
|
||||||
BIO_printf(bio_err," -no_ticket - disable use of RFC4507bis session tickets\n");
|
BIO_printf(bio_err," -no_ticket - disable use of RFC4507bis session tickets\n");
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
BIO_printf(bio_err," -nextprotoneg arg - enable NPN extension, considering named protocols supported (comma-separated list)\n");
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
BIO_printf(bio_err," -legacy_renegotiation - enable use of legacy renegotiation (dangerous)\n");
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
BIO_printf(bio_err," -use_srtp profiles - Offer SRTP key management with a colon-separated profile list\n");
|
||||||
|
#endif
|
||||||
|
BIO_printf(bio_err," -keymatexport label - Export keying material using label\n");
|
||||||
|
BIO_printf(bio_err," -keymatexportlen len - Export len bytes of keying material (default 20)\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
@@ -365,6 +389,158 @@ static int MS_CALLBACK ssl_servername_cb(SSL *s, int *ad, void *arg)
|
|||||||
|
|
||||||
return SSL_TLSEXT_ERR_OK;
|
return SSL_TLSEXT_ERR_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
|
||||||
|
/* This is a context that we pass to all callbacks */
|
||||||
|
typedef struct srp_arg_st
|
||||||
|
{
|
||||||
|
char *srppassin;
|
||||||
|
char *srplogin;
|
||||||
|
int msg; /* copy from c_msg */
|
||||||
|
int debug; /* copy from c_debug */
|
||||||
|
int amp; /* allow more groups */
|
||||||
|
int strength /* minimal size for N */ ;
|
||||||
|
} SRP_ARG;
|
||||||
|
|
||||||
|
#define SRP_NUMBER_ITERATIONS_FOR_PRIME 64
|
||||||
|
|
||||||
|
static int srp_Verify_N_and_g(BIGNUM *N, BIGNUM *g)
|
||||||
|
{
|
||||||
|
BN_CTX *bn_ctx = BN_CTX_new();
|
||||||
|
BIGNUM *p = BN_new();
|
||||||
|
BIGNUM *r = BN_new();
|
||||||
|
int ret =
|
||||||
|
g != NULL && N != NULL && bn_ctx != NULL && BN_is_odd(N) &&
|
||||||
|
BN_is_prime_ex(N, SRP_NUMBER_ITERATIONS_FOR_PRIME, bn_ctx, NULL) &&
|
||||||
|
p != NULL && BN_rshift1(p, N) &&
|
||||||
|
|
||||||
|
/* p = (N-1)/2 */
|
||||||
|
BN_is_prime_ex(p, SRP_NUMBER_ITERATIONS_FOR_PRIME, bn_ctx, NULL) &&
|
||||||
|
r != NULL &&
|
||||||
|
|
||||||
|
/* verify g^((N-1)/2) == -1 (mod N) */
|
||||||
|
BN_mod_exp(r, g, p, N, bn_ctx) &&
|
||||||
|
BN_add_word(r, 1) &&
|
||||||
|
BN_cmp(r, N) == 0;
|
||||||
|
|
||||||
|
if(r)
|
||||||
|
BN_free(r);
|
||||||
|
if(p)
|
||||||
|
BN_free(p);
|
||||||
|
if(bn_ctx)
|
||||||
|
BN_CTX_free(bn_ctx);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* This callback is used here for two purposes:
|
||||||
|
- extended debugging
|
||||||
|
- making some primality tests for unknown groups
|
||||||
|
The callback is only called for a non default group.
|
||||||
|
|
||||||
|
An application does not need the call back at all if
|
||||||
|
only the stanard groups are used. In real life situations,
|
||||||
|
client and server already share well known groups,
|
||||||
|
thus there is no need to verify them.
|
||||||
|
Furthermore, in case that a server actually proposes a group that
|
||||||
|
is not one of those defined in RFC 5054, it is more appropriate
|
||||||
|
to add the group to a static list and then compare since
|
||||||
|
primality tests are rather cpu consuming.
|
||||||
|
*/
|
||||||
|
|
||||||
|
static int MS_CALLBACK ssl_srp_verify_param_cb(SSL *s, void *arg)
|
||||||
|
{
|
||||||
|
SRP_ARG *srp_arg = (SRP_ARG *)arg;
|
||||||
|
BIGNUM *N = NULL, *g = NULL;
|
||||||
|
if (!(N = SSL_get_srp_N(s)) || !(g = SSL_get_srp_g(s)))
|
||||||
|
return 0;
|
||||||
|
if (srp_arg->debug || srp_arg->msg || srp_arg->amp == 1)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "SRP parameters:\n");
|
||||||
|
BIO_printf(bio_err,"\tN="); BN_print(bio_err,N);
|
||||||
|
BIO_printf(bio_err,"\n\tg="); BN_print(bio_err,g);
|
||||||
|
BIO_printf(bio_err,"\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (SRP_check_known_gN_param(g,N))
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
if (srp_arg->amp == 1)
|
||||||
|
{
|
||||||
|
if (srp_arg->debug)
|
||||||
|
BIO_printf(bio_err, "SRP param N and g are not known params, going to check deeper.\n");
|
||||||
|
|
||||||
|
/* The srp_moregroups is a real debugging feature.
|
||||||
|
Implementors should rather add the value to the known ones.
|
||||||
|
The minimal size has already been tested.
|
||||||
|
*/
|
||||||
|
if (BN_num_bits(g) <= BN_BITS && srp_Verify_N_and_g(N,g))
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
BIO_printf(bio_err, "SRP param N and g rejected.\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
#define PWD_STRLEN 1024
|
||||||
|
|
||||||
|
static char * MS_CALLBACK ssl_give_srp_client_pwd_cb(SSL *s, void *arg)
|
||||||
|
{
|
||||||
|
SRP_ARG *srp_arg = (SRP_ARG *)arg;
|
||||||
|
char *pass = (char *)OPENSSL_malloc(PWD_STRLEN+1);
|
||||||
|
PW_CB_DATA cb_tmp;
|
||||||
|
int l;
|
||||||
|
|
||||||
|
cb_tmp.password = (char *)srp_arg->srppassin;
|
||||||
|
cb_tmp.prompt_info = "SRP user";
|
||||||
|
if ((l = password_callback(pass, PWD_STRLEN, 0, &cb_tmp))<0)
|
||||||
|
{
|
||||||
|
BIO_printf (bio_err, "Can't read Password\n");
|
||||||
|
OPENSSL_free(pass);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
*(pass+l)= '\0';
|
||||||
|
|
||||||
|
return pass;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
char *srtp_profiles = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
/* This the context that we pass to next_proto_cb */
|
||||||
|
typedef struct tlsextnextprotoctx_st {
|
||||||
|
unsigned char *data;
|
||||||
|
unsigned short len;
|
||||||
|
int status;
|
||||||
|
} tlsextnextprotoctx;
|
||||||
|
|
||||||
|
static tlsextnextprotoctx next_proto;
|
||||||
|
|
||||||
|
static int next_proto_cb(SSL *s, unsigned char **out, unsigned char *outlen, const unsigned char *in, unsigned int inlen, void *arg)
|
||||||
|
{
|
||||||
|
tlsextnextprotoctx *ctx = arg;
|
||||||
|
|
||||||
|
if (!c_quiet)
|
||||||
|
{
|
||||||
|
/* We can assume that |in| is syntactically valid. */
|
||||||
|
unsigned i;
|
||||||
|
BIO_printf(bio_c_out, "Protocols advertised by server: ");
|
||||||
|
for (i = 0; i < inlen; )
|
||||||
|
{
|
||||||
|
if (i)
|
||||||
|
BIO_write(bio_c_out, ", ", 2);
|
||||||
|
BIO_write(bio_c_out, &in[i + 1], in[i]);
|
||||||
|
i += in[i] + 1;
|
||||||
|
}
|
||||||
|
BIO_write(bio_c_out, "\n", 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
ctx->status = SSL_select_next_proto(out, outlen, in, inlen, ctx->data, ctx->len);
|
||||||
|
return SSL_TLSEXT_ERR_OK;
|
||||||
|
}
|
||||||
|
# endif /* ndef OPENSSL_NO_NEXTPROTONEG */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
enum
|
enum
|
||||||
@@ -381,9 +557,11 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int off=0;
|
unsigned int off=0, clr=0;
|
||||||
SSL *con=NULL;
|
SSL *con=NULL;
|
||||||
X509_STORE *store = NULL;
|
#ifndef OPENSSL_NO_KRB5
|
||||||
|
KSSL_CTX *kctx;
|
||||||
|
#endif
|
||||||
int s,k,width,state=0;
|
int s,k,width,state=0;
|
||||||
char *cbuf=NULL,*sbuf=NULL,*mbuf=NULL;
|
char *cbuf=NULL,*sbuf=NULL,*mbuf=NULL;
|
||||||
int cbuf_len,cbuf_off;
|
int cbuf_len,cbuf_off;
|
||||||
@@ -404,12 +582,15 @@ int MAIN(int argc, char **argv)
|
|||||||
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 starttls_proto = PROTO_OFF;
|
int starttls_proto = PROTO_OFF;
|
||||||
int prexit = 0, vflags = 0;
|
int prexit = 0;
|
||||||
|
X509_VERIFY_PARAM *vpm = NULL;
|
||||||
|
int badarg = 0;
|
||||||
const SSL_METHOD *meth=NULL;
|
const SSL_METHOD *meth=NULL;
|
||||||
int socket_type=SOCK_STREAM;
|
int socket_type=SOCK_STREAM;
|
||||||
BIO *sbio;
|
BIO *sbio;
|
||||||
char *inrand=NULL;
|
char *inrand=NULL;
|
||||||
int mbuf_len=0;
|
int mbuf_len=0;
|
||||||
|
struct timeval timeout, *timeoutp;
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
char *engine_id=NULL;
|
char *engine_id=NULL;
|
||||||
char *ssl_client_engine_id=NULL;
|
char *ssl_client_engine_id=NULL;
|
||||||
@@ -426,6 +607,9 @@ int MAIN(int argc, char **argv)
|
|||||||
char *servername = NULL;
|
char *servername = NULL;
|
||||||
tlsextctx tlsextcbp =
|
tlsextctx tlsextcbp =
|
||||||
{NULL,0};
|
{NULL,0};
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
const char *next_proto_neg_in = NULL;
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
char *sess_in = NULL;
|
char *sess_in = NULL;
|
||||||
char *sess_out = NULL;
|
char *sess_out = NULL;
|
||||||
@@ -436,15 +620,14 @@ int MAIN(int argc, char **argv)
|
|||||||
#ifndef OPENSSL_NO_JPAKE
|
#ifndef OPENSSL_NO_JPAKE
|
||||||
char *jpake_secret = NULL;
|
char *jpake_secret = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
#if !defined(OPENSSL_NO_SSL2) && !defined(OPENSSL_NO_SSL3)
|
char * srppass = NULL;
|
||||||
meth=SSLv23_client_method();
|
int srp_lateuser = 0;
|
||||||
#elif !defined(OPENSSL_NO_SSL3)
|
SRP_ARG srp_arg = {NULL,NULL,0,0,0,1024};
|
||||||
meth=SSLv3_client_method();
|
|
||||||
#elif !defined(OPENSSL_NO_SSL2)
|
|
||||||
meth=SSLv2_client_method();
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
meth=SSLv23_client_method();
|
||||||
|
|
||||||
apps_startup();
|
apps_startup();
|
||||||
c_Pause=0;
|
c_Pause=0;
|
||||||
c_quiet=0;
|
c_quiet=0;
|
||||||
@@ -521,10 +704,12 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
cert_format = str2fmt(*(++argv));
|
cert_format = str2fmt(*(++argv));
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-crl_check") == 0)
|
else if (args_verify(&argv, &argc, &badarg, bio_err, &vpm))
|
||||||
vflags |= X509_V_FLAG_CRL_CHECK;
|
{
|
||||||
else if (strcmp(*argv,"-crl_check_all") == 0)
|
if (badarg)
|
||||||
vflags |= X509_V_FLAG_CRL_CHECK|X509_V_FLAG_CRL_CHECK_ALL;
|
goto bad;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
else if (strcmp(*argv,"-verify_return_error") == 0)
|
else if (strcmp(*argv,"-verify_return_error") == 0)
|
||||||
verify_return_error = 1;
|
verify_return_error = 1;
|
||||||
else if (strcmp(*argv,"-prexit") == 0)
|
else if (strcmp(*argv,"-prexit") == 0)
|
||||||
@@ -576,13 +761,44 @@ int MAIN(int argc, char **argv)
|
|||||||
psk_key=*(++argv);
|
psk_key=*(++argv);
|
||||||
for (j = 0; j < strlen(psk_key); j++)
|
for (j = 0; j < strlen(psk_key); j++)
|
||||||
{
|
{
|
||||||
if (isxdigit((int)psk_key[j]))
|
if (isxdigit((unsigned char)psk_key[j]))
|
||||||
continue;
|
continue;
|
||||||
BIO_printf(bio_err,"Not a hex number '%s'\n",*argv);
|
BIO_printf(bio_err,"Not a hex number '%s'\n",*argv);
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
else if (strcmp(*argv,"-srpuser") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srp_arg.srplogin= *(++argv);
|
||||||
|
meth=TLSv1_client_method();
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-srppass") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srppass= *(++argv);
|
||||||
|
meth=TLSv1_client_method();
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-srp_strength") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srp_arg.strength=atoi(*(++argv));
|
||||||
|
BIO_printf(bio_err,"SRP minimal length for N is %d\n",srp_arg.strength);
|
||||||
|
meth=TLSv1_client_method();
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-srp_lateuser") == 0)
|
||||||
|
{
|
||||||
|
srp_lateuser= 1;
|
||||||
|
meth=TLSv1_client_method();
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-srp_moregroups") == 0)
|
||||||
|
{
|
||||||
|
srp_arg.amp=1;
|
||||||
|
meth=TLSv1_client_method();
|
||||||
|
}
|
||||||
|
#endif
|
||||||
#ifndef OPENSSL_NO_SSL2
|
#ifndef OPENSSL_NO_SSL2
|
||||||
else if (strcmp(*argv,"-ssl2") == 0)
|
else if (strcmp(*argv,"-ssl2") == 0)
|
||||||
meth=SSLv2_client_method();
|
meth=SSLv2_client_method();
|
||||||
@@ -592,6 +808,10 @@ int MAIN(int argc, char **argv)
|
|||||||
meth=SSLv3_client_method();
|
meth=SSLv3_client_method();
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_TLS1
|
#ifndef OPENSSL_NO_TLS1
|
||||||
|
else if (strcmp(*argv,"-tls1_2") == 0)
|
||||||
|
meth=TLSv1_2_client_method();
|
||||||
|
else if (strcmp(*argv,"-tls1_1") == 0)
|
||||||
|
meth=TLSv1_1_client_method();
|
||||||
else if (strcmp(*argv,"-tls1") == 0)
|
else if (strcmp(*argv,"-tls1") == 0)
|
||||||
meth=TLSv1_client_method();
|
meth=TLSv1_client_method();
|
||||||
#endif
|
#endif
|
||||||
@@ -640,6 +860,10 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
CAfile= *(++argv);
|
CAfile= *(++argv);
|
||||||
}
|
}
|
||||||
|
else if (strcmp(*argv,"-no_tls1_2") == 0)
|
||||||
|
off|=SSL_OP_NO_TLSv1_2;
|
||||||
|
else if (strcmp(*argv,"-no_tls1_1") == 0)
|
||||||
|
off|=SSL_OP_NO_TLSv1_1;
|
||||||
else if (strcmp(*argv,"-no_tls1") == 0)
|
else if (strcmp(*argv,"-no_tls1") == 0)
|
||||||
off|=SSL_OP_NO_TLSv1;
|
off|=SSL_OP_NO_TLSv1;
|
||||||
else if (strcmp(*argv,"-no_ssl3") == 0)
|
else if (strcmp(*argv,"-no_ssl3") == 0)
|
||||||
@@ -651,9 +875,22 @@ int MAIN(int argc, char **argv)
|
|||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
else if (strcmp(*argv,"-no_ticket") == 0)
|
else if (strcmp(*argv,"-no_ticket") == 0)
|
||||||
{ off|=SSL_OP_NO_TICKET; }
|
{ off|=SSL_OP_NO_TICKET; }
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
else if (strcmp(*argv,"-nextprotoneg") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
next_proto_neg_in = *(++argv);
|
||||||
|
}
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
else if (strcmp(*argv,"-serverpref") == 0)
|
else if (strcmp(*argv,"-serverpref") == 0)
|
||||||
off|=SSL_OP_CIPHER_SERVER_PREFERENCE;
|
off|=SSL_OP_CIPHER_SERVER_PREFERENCE;
|
||||||
|
else if (strcmp(*argv,"-legacy_renegotiation") == 0)
|
||||||
|
off|=SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION;
|
||||||
|
else if (strcmp(*argv,"-legacy_server_connect") == 0)
|
||||||
|
{ off|=SSL_OP_LEGACY_SERVER_CONNECT; }
|
||||||
|
else if (strcmp(*argv,"-no_legacy_server_connect") == 0)
|
||||||
|
{ clr|=SSL_OP_LEGACY_SERVER_CONNECT; }
|
||||||
else if (strcmp(*argv,"-cipher") == 0)
|
else if (strcmp(*argv,"-cipher") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
@@ -712,7 +949,25 @@ int MAIN(int argc, char **argv)
|
|||||||
jpake_secret = *++argv;
|
jpake_secret = *++argv;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
else
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
else if (strcmp(*argv,"-use_srtp") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srtp_profiles = *(++argv);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
else if (strcmp(*argv,"-keymatexport") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
keymatexportlabel= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-keymatexportlen") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
keymatexportlen=atoi(*(++argv));
|
||||||
|
if (keymatexportlen == 0) goto bad;
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
||||||
badop=1;
|
badop=1;
|
||||||
@@ -738,19 +993,33 @@ bad:
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
psk_identity = "JPAKE";
|
psk_identity = "JPAKE";
|
||||||
|
if (cipher)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "JPAKE sets cipher to PSK\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
cipher = "PSK";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cipher)
|
|
||||||
{
|
|
||||||
BIO_printf(bio_err, "JPAKE sets cipher to PSK\n");
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
cipher = "PSK";
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
OpenSSL_add_ssl_algorithms();
|
OpenSSL_add_ssl_algorithms();
|
||||||
SSL_load_error_strings();
|
SSL_load_error_strings();
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
next_proto.status = -1;
|
||||||
|
if (next_proto_neg_in)
|
||||||
|
{
|
||||||
|
next_proto.data = next_protos_parse(&next_proto.len, next_proto_neg_in);
|
||||||
|
if (next_proto.data == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error parsing -nextprotoneg argument\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
next_proto.data = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
e = setup_engine(bio_err, engine_id, 1);
|
e = setup_engine(bio_err, engine_id, 1);
|
||||||
if (ssl_client_engine_id)
|
if (ssl_client_engine_id)
|
||||||
@@ -824,6 +1093,14 @@ bad:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
if(!app_passwd(bio_err, srppass, NULL, &srp_arg.srppassin, NULL))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error getting password\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
ctx=SSL_CTX_new(meth);
|
ctx=SSL_CTX_new(meth);
|
||||||
if (ctx == NULL)
|
if (ctx == NULL)
|
||||||
{
|
{
|
||||||
@@ -831,6 +1108,9 @@ bad:
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (vpm)
|
||||||
|
SSL_CTX_set1_param(ctx, vpm);
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
if (ssl_client_engine)
|
if (ssl_client_engine)
|
||||||
{
|
{
|
||||||
@@ -856,16 +1136,28 @@ bad:
|
|||||||
BIO_printf(bio_c_out, "PSK key given or JPAKE in use, setting client callback\n");
|
BIO_printf(bio_c_out, "PSK key given or JPAKE in use, setting client callback\n");
|
||||||
SSL_CTX_set_psk_client_callback(ctx, psk_client_cb);
|
SSL_CTX_set_psk_client_callback(ctx, psk_client_cb);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
if (srtp_profiles != NULL)
|
||||||
|
SSL_CTX_set_tlsext_use_srtp(ctx, srtp_profiles);
|
||||||
#endif
|
#endif
|
||||||
if (bugs)
|
if (bugs)
|
||||||
SSL_CTX_set_options(ctx,SSL_OP_ALL|off);
|
SSL_CTX_set_options(ctx,SSL_OP_ALL|off);
|
||||||
else
|
else
|
||||||
SSL_CTX_set_options(ctx,off);
|
SSL_CTX_set_options(ctx,off);
|
||||||
|
|
||||||
|
if (clr)
|
||||||
|
SSL_CTX_clear_options(ctx, clr);
|
||||||
/* DTLS: partial reads end up discarding unread UDP bytes :-(
|
/* DTLS: partial reads end up discarding unread UDP bytes :-(
|
||||||
* Setting read ahead solves this problem.
|
* Setting read ahead solves this problem.
|
||||||
*/
|
*/
|
||||||
if (socket_type == SOCK_DGRAM) SSL_CTX_set_read_ahead(ctx, 1);
|
if (socket_type == SOCK_DGRAM) SSL_CTX_set_read_ahead(ctx, 1);
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
if (next_proto.data)
|
||||||
|
SSL_CTX_set_next_proto_select_cb(ctx, next_proto_cb, &next_proto);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (state) SSL_CTX_set_info_callback(ctx,apps_ssl_info_callback);
|
if (state) SSL_CTX_set_info_callback(ctx,apps_ssl_info_callback);
|
||||||
if (cipher != NULL)
|
if (cipher != NULL)
|
||||||
if(!SSL_CTX_set_cipher_list(ctx,cipher)) {
|
if(!SSL_CTX_set_cipher_list(ctx,cipher)) {
|
||||||
@@ -890,8 +1182,6 @@ bad:
|
|||||||
/* goto end; */
|
/* goto end; */
|
||||||
}
|
}
|
||||||
|
|
||||||
store = SSL_CTX_get_cert_store(ctx);
|
|
||||||
X509_STORE_set_flags(store, vflags);
|
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
if (servername != NULL)
|
if (servername != NULL)
|
||||||
{
|
{
|
||||||
@@ -899,6 +1189,24 @@ bad:
|
|||||||
SSL_CTX_set_tlsext_servername_callback(ctx, ssl_servername_cb);
|
SSL_CTX_set_tlsext_servername_callback(ctx, ssl_servername_cb);
|
||||||
SSL_CTX_set_tlsext_servername_arg(ctx, &tlsextcbp);
|
SSL_CTX_set_tlsext_servername_arg(ctx, &tlsextcbp);
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
if (srp_arg.srplogin)
|
||||||
|
{
|
||||||
|
if (!srp_lateuser && !SSL_CTX_set_srp_username(ctx, srp_arg.srplogin))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"Unable to set SRP username\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
srp_arg.msg = c_msg;
|
||||||
|
srp_arg.debug = c_debug ;
|
||||||
|
SSL_CTX_set_srp_cb_arg(ctx,&srp_arg);
|
||||||
|
SSL_CTX_set_srp_client_pwd_callback(ctx, ssl_give_srp_client_pwd_cb);
|
||||||
|
SSL_CTX_set_srp_strength(ctx, srp_arg.strength);
|
||||||
|
if (c_msg || c_debug || srp_arg.amp == 0)
|
||||||
|
SSL_CTX_set_srp_verify_param_callback(ctx, ssl_srp_verify_param_cb);
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
con=SSL_new(ctx);
|
con=SSL_new(ctx);
|
||||||
@@ -937,9 +1245,10 @@ bad:
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_KRB5
|
#ifndef OPENSSL_NO_KRB5
|
||||||
if (con && (con->kssl_ctx = kssl_ctx_new()) != NULL)
|
if (con && (kctx = kssl_ctx_new()) != NULL)
|
||||||
{
|
{
|
||||||
kssl_ctx_setstring(con->kssl_ctx, KSSL_SERVER, host);
|
SSL_set0_kssl_ctx(con, kctx);
|
||||||
|
kssl_ctx_setstring(kctx, KSSL_SERVER, host);
|
||||||
}
|
}
|
||||||
#endif /* OPENSSL_NO_KRB5 */
|
#endif /* OPENSSL_NO_KRB5 */
|
||||||
/* SSL_set_cipher_list(con,"RC4-MD5"); */
|
/* SSL_set_cipher_list(con,"RC4-MD5"); */
|
||||||
@@ -971,11 +1280,10 @@ re_start:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
if (c_Pause & 0x01) con->debug=1;
|
if (c_Pause & 0x01) SSL_set_debug(con, 1);
|
||||||
|
|
||||||
if ( SSL_version(con) == DTLS1_VERSION)
|
if ( SSL_version(con) == DTLS1_VERSION)
|
||||||
{
|
{
|
||||||
struct timeval timeout;
|
|
||||||
|
|
||||||
sbio=BIO_new_dgram(s,BIO_NOCLOSE);
|
sbio=BIO_new_dgram(s,BIO_NOCLOSE);
|
||||||
if (getsockname(s, &peer, (void *)&peerlen) < 0)
|
if (getsockname(s, &peer, (void *)&peerlen) < 0)
|
||||||
@@ -999,10 +1307,10 @@ re_start:
|
|||||||
BIO_ctrl(sbio, BIO_CTRL_DGRAM_SET_SEND_TIMEOUT, 0, &timeout);
|
BIO_ctrl(sbio, BIO_CTRL_DGRAM_SET_SEND_TIMEOUT, 0, &timeout);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (socket_mtu > 0)
|
if (socket_mtu > 28)
|
||||||
{
|
{
|
||||||
SSL_set_options(con, SSL_OP_NO_QUERY_MTU);
|
SSL_set_options(con, SSL_OP_NO_QUERY_MTU);
|
||||||
SSL_set_mtu(con, socket_mtu);
|
SSL_set_mtu(con, socket_mtu - 28);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/* want to do MTU discovery */
|
/* want to do MTU discovery */
|
||||||
@@ -1021,7 +1329,7 @@ re_start:
|
|||||||
|
|
||||||
if (c_debug)
|
if (c_debug)
|
||||||
{
|
{
|
||||||
con->debug=1;
|
SSL_set_debug(con, 1);
|
||||||
BIO_set_callback(sbio,bio_dump_callback);
|
BIO_set_callback(sbio,bio_dump_callback);
|
||||||
BIO_set_callback_arg(sbio,(char *)bio_c_out);
|
BIO_set_callback_arg(sbio,(char *)bio_c_out);
|
||||||
}
|
}
|
||||||
@@ -1192,6 +1500,12 @@ SSL_set_tlsext_status_ids(con, ids);
|
|||||||
FD_ZERO(&readfds);
|
FD_ZERO(&readfds);
|
||||||
FD_ZERO(&writefds);
|
FD_ZERO(&writefds);
|
||||||
|
|
||||||
|
if ((SSL_version(con) == DTLS1_VERSION) &&
|
||||||
|
DTLSv1_get_timeout(con, &timeout))
|
||||||
|
timeoutp = &timeout;
|
||||||
|
else
|
||||||
|
timeoutp = NULL;
|
||||||
|
|
||||||
if (SSL_in_init(con) && !SSL_total_renegotiations(con))
|
if (SSL_in_init(con) && !SSL_total_renegotiations(con))
|
||||||
{
|
{
|
||||||
in_init=1;
|
in_init=1;
|
||||||
@@ -1296,7 +1610,7 @@ SSL_set_tlsext_status_ids(con, ids);
|
|||||||
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;
|
||||||
#endif
|
#endif
|
||||||
} else i=select(width,(void *)&readfds,(void *)&writefds,
|
} else i=select(width,(void *)&readfds,(void *)&writefds,
|
||||||
NULL,NULL);
|
NULL,timeoutp);
|
||||||
}
|
}
|
||||||
#elif defined(OPENSSL_SYS_NETWARE)
|
#elif defined(OPENSSL_SYS_NETWARE)
|
||||||
if(!write_tty) {
|
if(!write_tty) {
|
||||||
@@ -1306,7 +1620,7 @@ SSL_set_tlsext_status_ids(con, ids);
|
|||||||
i=select(width,(void *)&readfds,(void *)&writefds,
|
i=select(width,(void *)&readfds,(void *)&writefds,
|
||||||
NULL,&tv);
|
NULL,&tv);
|
||||||
} else i=select(width,(void *)&readfds,(void *)&writefds,
|
} else i=select(width,(void *)&readfds,(void *)&writefds,
|
||||||
NULL,NULL);
|
NULL,timeoutp);
|
||||||
}
|
}
|
||||||
#elif defined(OPENSSL_SYS_BEOS_R5)
|
#elif defined(OPENSSL_SYS_BEOS_R5)
|
||||||
/* Under BeOS-R5 the situation is similar to DOS */
|
/* Under BeOS-R5 the situation is similar to DOS */
|
||||||
@@ -1324,12 +1638,12 @@ SSL_set_tlsext_status_ids(con, ids);
|
|||||||
if (!i && (stdin_set != 1 || !read_tty))
|
if (!i && (stdin_set != 1 || !read_tty))
|
||||||
continue;
|
continue;
|
||||||
} else i=select(width,(void *)&readfds,(void *)&writefds,
|
} else i=select(width,(void *)&readfds,(void *)&writefds,
|
||||||
NULL,NULL);
|
NULL,timeoutp);
|
||||||
}
|
}
|
||||||
(void)fcntl(fileno(stdin), F_SETFL, 0);
|
(void)fcntl(fileno(stdin), F_SETFL, 0);
|
||||||
#else
|
#else
|
||||||
i=select(width,(void *)&readfds,(void *)&writefds,
|
i=select(width,(void *)&readfds,(void *)&writefds,
|
||||||
NULL,NULL);
|
NULL,timeoutp);
|
||||||
#endif
|
#endif
|
||||||
if ( i < 0)
|
if ( i < 0)
|
||||||
{
|
{
|
||||||
@@ -1340,6 +1654,11 @@ SSL_set_tlsext_status_ids(con, ids);
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ((SSL_version(con) == DTLS1_VERSION) && DTLSv1_handle_timeout(con) > 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"TIMEOUT occured\n");
|
||||||
|
}
|
||||||
|
|
||||||
if (!ssl_pending && FD_ISSET(SSL_get_fd(con),&writefds))
|
if (!ssl_pending && FD_ISSET(SSL_get_fd(con),&writefds))
|
||||||
{
|
{
|
||||||
k=SSL_write(con,&(cbuf[cbuf_off]),
|
k=SSL_write(con,&(cbuf[cbuf_off]),
|
||||||
@@ -1544,6 +1863,14 @@ printf("read=%d pending=%d peek=%d\n",k,SSL_pending(con),SSL_peek(con,zbuf,10240
|
|||||||
SSL_renegotiate(con);
|
SSL_renegotiate(con);
|
||||||
cbuf_len=0;
|
cbuf_len=0;
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_HEARTBEATS
|
||||||
|
else if ((!c_ign_eof) && (cbuf[0] == 'B'))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"HEARTBEATING\n");
|
||||||
|
SSL_heartbeat(con);
|
||||||
|
cbuf_len=0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
cbuf_len=i;
|
cbuf_len=i;
|
||||||
@@ -1571,6 +1898,10 @@ end:
|
|||||||
print_stuff(bio_c_out,con,1);
|
print_stuff(bio_c_out,con,1);
|
||||||
SSL_free(con);
|
SSL_free(con);
|
||||||
}
|
}
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
if (next_proto.data)
|
||||||
|
OPENSSL_free(next_proto.data);
|
||||||
|
#endif
|
||||||
if (ctx != NULL) SSL_CTX_free(ctx);
|
if (ctx != NULL) SSL_CTX_free(ctx);
|
||||||
if (cert)
|
if (cert)
|
||||||
X509_free(cert);
|
X509_free(cert);
|
||||||
@@ -1578,6 +1909,8 @@ end:
|
|||||||
EVP_PKEY_free(key);
|
EVP_PKEY_free(key);
|
||||||
if (pass)
|
if (pass)
|
||||||
OPENSSL_free(pass);
|
OPENSSL_free(pass);
|
||||||
|
if (vpm)
|
||||||
|
X509_VERIFY_PARAM_free(vpm);
|
||||||
if (cbuf != NULL) { OPENSSL_cleanse(cbuf,BUFSIZZ); OPENSSL_free(cbuf); }
|
if (cbuf != NULL) { OPENSSL_cleanse(cbuf,BUFSIZZ); OPENSSL_free(cbuf); }
|
||||||
if (sbuf != NULL) { OPENSSL_cleanse(sbuf,BUFSIZZ); OPENSSL_free(sbuf); }
|
if (sbuf != NULL) { OPENSSL_cleanse(sbuf,BUFSIZZ); OPENSSL_free(sbuf); }
|
||||||
if (mbuf != NULL) { OPENSSL_cleanse(mbuf,BUFSIZZ); OPENSSL_free(mbuf); }
|
if (mbuf != NULL) { OPENSSL_cleanse(mbuf,BUFSIZZ); OPENSSL_free(mbuf); }
|
||||||
@@ -1605,6 +1938,7 @@ static void print_stuff(BIO *bio, SSL *s, int full)
|
|||||||
#ifndef OPENSSL_NO_COMP
|
#ifndef OPENSSL_NO_COMP
|
||||||
const COMP_METHOD *comp, *expansion;
|
const COMP_METHOD *comp, *expansion;
|
||||||
#endif
|
#endif
|
||||||
|
unsigned char *exportedkeymat;
|
||||||
|
|
||||||
if (full)
|
if (full)
|
||||||
{
|
{
|
||||||
@@ -1695,7 +2029,7 @@ static void print_stuff(BIO *bio, SSL *s, int full)
|
|||||||
BIO_number_read(SSL_get_rbio(s)),
|
BIO_number_read(SSL_get_rbio(s)),
|
||||||
BIO_number_written(SSL_get_wbio(s)));
|
BIO_number_written(SSL_get_wbio(s)));
|
||||||
}
|
}
|
||||||
BIO_printf(bio,((s->hit)?"---\nReused, ":"---\nNew, "));
|
BIO_printf(bio,(SSL_cache_hit(s)?"---\nReused, ":"---\nNew, "));
|
||||||
c=SSL_get_current_cipher(s);
|
c=SSL_get_current_cipher(s);
|
||||||
BIO_printf(bio,"%s, Cipher is %s\n",
|
BIO_printf(bio,"%s, Cipher is %s\n",
|
||||||
SSL_CIPHER_get_version(c),
|
SSL_CIPHER_get_version(c),
|
||||||
@@ -1707,6 +2041,8 @@ static void print_stuff(BIO *bio, SSL *s, int full)
|
|||||||
EVP_PKEY_bits(pktmp));
|
EVP_PKEY_bits(pktmp));
|
||||||
EVP_PKEY_free(pktmp);
|
EVP_PKEY_free(pktmp);
|
||||||
}
|
}
|
||||||
|
BIO_printf(bio, "Secure Renegotiation IS%s supported\n",
|
||||||
|
SSL_get_secure_renegotiation_support(s) ? "" : " NOT");
|
||||||
#ifndef OPENSSL_NO_COMP
|
#ifndef OPENSSL_NO_COMP
|
||||||
comp=SSL_get_current_compression(s);
|
comp=SSL_get_current_compression(s);
|
||||||
expansion=SSL_get_current_expansion(s);
|
expansion=SSL_get_current_expansion(s);
|
||||||
@@ -1715,7 +2051,68 @@ static void print_stuff(BIO *bio, SSL *s, int full)
|
|||||||
BIO_printf(bio,"Expansion: %s\n",
|
BIO_printf(bio,"Expansion: %s\n",
|
||||||
expansion ? SSL_COMP_get_name(expansion) : "NONE");
|
expansion ? SSL_COMP_get_name(expansion) : "NONE");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef SSL_DEBUG
|
||||||
|
{
|
||||||
|
/* Print out local port of connection: useful for debugging */
|
||||||
|
int sock;
|
||||||
|
struct sockaddr_in ladd;
|
||||||
|
socklen_t ladd_size = sizeof(ladd);
|
||||||
|
sock = SSL_get_fd(s);
|
||||||
|
getsockname(sock, (struct sockaddr *)&ladd, &ladd_size);
|
||||||
|
BIO_printf(bio_c_out, "LOCAL PORT is %u\n", ntohs(ladd.sin_port));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
if (next_proto.status != -1) {
|
||||||
|
const unsigned char *proto;
|
||||||
|
unsigned int proto_len;
|
||||||
|
SSL_get0_next_proto_negotiated(s, &proto, &proto_len);
|
||||||
|
BIO_printf(bio, "Next protocol: (%d) ", next_proto.status);
|
||||||
|
BIO_write(bio, proto, proto_len);
|
||||||
|
BIO_write(bio, "\n", 1);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
{
|
||||||
|
SRTP_PROTECTION_PROFILE *srtp_profile=SSL_get_selected_srtp_profile(s);
|
||||||
|
|
||||||
|
if(srtp_profile)
|
||||||
|
BIO_printf(bio,"SRTP Extension negotiated, profile=%s\n",
|
||||||
|
srtp_profile->name);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
SSL_SESSION_print(bio,SSL_get_session(s));
|
SSL_SESSION_print(bio,SSL_get_session(s));
|
||||||
|
if (keymatexportlabel != NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio, "Keying material exporter:\n");
|
||||||
|
BIO_printf(bio, " Label: '%s'\n", keymatexportlabel);
|
||||||
|
BIO_printf(bio, " Length: %i bytes\n", keymatexportlen);
|
||||||
|
exportedkeymat = OPENSSL_malloc(keymatexportlen);
|
||||||
|
if (exportedkeymat != NULL)
|
||||||
|
{
|
||||||
|
if (!SSL_export_keying_material(s, exportedkeymat,
|
||||||
|
keymatexportlen,
|
||||||
|
keymatexportlabel,
|
||||||
|
strlen(keymatexportlabel),
|
||||||
|
NULL, 0, 0))
|
||||||
|
{
|
||||||
|
BIO_printf(bio, " Error\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
BIO_printf(bio, " Keying material: ");
|
||||||
|
for (i=0; i<keymatexportlen; i++)
|
||||||
|
BIO_printf(bio, "%02X",
|
||||||
|
exportedkeymat[i]);
|
||||||
|
BIO_printf(bio, "\n");
|
||||||
|
}
|
||||||
|
OPENSSL_free(exportedkeymat);
|
||||||
|
}
|
||||||
|
}
|
||||||
BIO_printf(bio,"---\n");
|
BIO_printf(bio,"---\n");
|
||||||
if (peer != NULL)
|
if (peer != NULL)
|
||||||
X509_free(peer);
|
X509_free(peer);
|
||||||
|
|||||||
467
apps/s_server.c
467
apps/s_server.c
@@ -186,6 +186,9 @@ typedef unsigned int u_int;
|
|||||||
#ifndef OPENSSL_NO_RSA
|
#ifndef OPENSSL_NO_RSA
|
||||||
#include <openssl/rsa.h>
|
#include <openssl/rsa.h>
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
#include <openssl/srp.h>
|
||||||
|
#endif
|
||||||
#include "s_apps.h"
|
#include "s_apps.h"
|
||||||
#include "timeouts.h"
|
#include "timeouts.h"
|
||||||
|
|
||||||
@@ -290,6 +293,9 @@ static int cert_status_cb(SSL *s, void *arg);
|
|||||||
static int s_msg=0;
|
static int s_msg=0;
|
||||||
static int s_quiet=0;
|
static int s_quiet=0;
|
||||||
|
|
||||||
|
static char *keymatexportlabel=NULL;
|
||||||
|
static int keymatexportlen=20;
|
||||||
|
|
||||||
static int hack=0;
|
static int hack=0;
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
static char *engine_id=NULL;
|
static char *engine_id=NULL;
|
||||||
@@ -298,7 +304,10 @@ static const char *session_id_prefix=NULL;
|
|||||||
|
|
||||||
static int enable_timeouts = 0;
|
static int enable_timeouts = 0;
|
||||||
static long socket_mtu;
|
static long socket_mtu;
|
||||||
|
#ifndef OPENSSL_NO_DTLS1
|
||||||
static int cert_chain = 0;
|
static int cert_chain = 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_PSK
|
#ifndef OPENSSL_NO_PSK
|
||||||
static char *psk_identity="Client_identity";
|
static char *psk_identity="Client_identity";
|
||||||
@@ -367,6 +376,52 @@ static unsigned int psk_server_cb(SSL *ssl, const char *identity,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
/* This is a context that we pass to callbacks */
|
||||||
|
typedef struct srpsrvparm_st
|
||||||
|
{
|
||||||
|
char *login;
|
||||||
|
SRP_VBASE *vb;
|
||||||
|
SRP_user_pwd *user;
|
||||||
|
} srpsrvparm;
|
||||||
|
|
||||||
|
/* This callback pretends to require some asynchronous logic in order to obtain
|
||||||
|
a verifier. When the callback is called for a new connection we return
|
||||||
|
with a negative value. This will provoke the accept etc to return with
|
||||||
|
an LOOKUP_X509. The main logic of the reinvokes the suspended call
|
||||||
|
(which would normally occur after a worker has finished) and we
|
||||||
|
set the user parameters.
|
||||||
|
*/
|
||||||
|
static int MS_CALLBACK ssl_srp_server_param_cb(SSL *s, int *ad, void *arg)
|
||||||
|
{
|
||||||
|
srpsrvparm *p = (srpsrvparm *)arg;
|
||||||
|
if (p->login == NULL && p->user == NULL )
|
||||||
|
{
|
||||||
|
p->login = SSL_get_srp_username(s);
|
||||||
|
BIO_printf(bio_err, "SRP username = \"%s\"\n", p->login);
|
||||||
|
return (-1) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (p->user == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "User %s doesn't exist\n", p->login);
|
||||||
|
return SSL3_AL_FATAL;
|
||||||
|
}
|
||||||
|
if (SSL_set_srp_server_param(s, p->user->N, p->user->g, p->user->s, p->user->v,
|
||||||
|
p->user->info) < 0)
|
||||||
|
{
|
||||||
|
*ad = SSL_AD_INTERNAL_ERROR;
|
||||||
|
return SSL3_AL_FATAL;
|
||||||
|
}
|
||||||
|
BIO_printf(bio_err, "SRP parameters set: username = \"%s\" info=\"%s\" \n", p->login,p->user->info);
|
||||||
|
/* need to check whether there are memory leaks */
|
||||||
|
p->user = NULL;
|
||||||
|
p->login = NULL;
|
||||||
|
return SSL_ERROR_NONE;
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef MONOLITH
|
#ifdef MONOLITH
|
||||||
static void s_server_init(void)
|
static void s_server_init(void)
|
||||||
{
|
{
|
||||||
@@ -453,17 +508,25 @@ static void sv_usage(void)
|
|||||||
# ifndef OPENSSL_NO_JPAKE
|
# ifndef OPENSSL_NO_JPAKE
|
||||||
BIO_printf(bio_err," -jpake arg - JPAKE secret to use\n");
|
BIO_printf(bio_err," -jpake arg - JPAKE secret to use\n");
|
||||||
# endif
|
# endif
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
BIO_printf(bio_err," -srpvfile file - The verifier file for SRP\n");
|
||||||
|
BIO_printf(bio_err," -srpuserseed string - A seed string for a default user salt.\n");
|
||||||
#endif
|
#endif
|
||||||
BIO_printf(bio_err," -ssl2 - Just talk SSLv2\n");
|
BIO_printf(bio_err," -ssl2 - Just talk SSLv2\n");
|
||||||
BIO_printf(bio_err," -ssl3 - Just talk SSLv3\n");
|
BIO_printf(bio_err," -ssl3 - Just talk SSLv3\n");
|
||||||
|
BIO_printf(bio_err," -tls1_2 - Just talk TLSv1.2\n");
|
||||||
|
BIO_printf(bio_err," -tls1_1 - Just talk TLSv1.1\n");
|
||||||
BIO_printf(bio_err," -tls1 - Just talk TLSv1\n");
|
BIO_printf(bio_err," -tls1 - Just talk TLSv1\n");
|
||||||
BIO_printf(bio_err," -dtls1 - Just talk DTLSv1\n");
|
BIO_printf(bio_err," -dtls1 - Just talk DTLSv1\n");
|
||||||
BIO_printf(bio_err," -timeout - Enable timeouts\n");
|
BIO_printf(bio_err," -timeout - Enable timeouts\n");
|
||||||
BIO_printf(bio_err," -mtu - Set MTU\n");
|
BIO_printf(bio_err," -mtu - Set link layer MTU\n");
|
||||||
BIO_printf(bio_err," -chain - Read a certificate chain\n");
|
BIO_printf(bio_err," -chain - Read a certificate chain\n");
|
||||||
BIO_printf(bio_err," -no_ssl2 - Just disable SSLv2\n");
|
BIO_printf(bio_err," -no_ssl2 - Just disable SSLv2\n");
|
||||||
BIO_printf(bio_err," -no_ssl3 - Just disable SSLv3\n");
|
BIO_printf(bio_err," -no_ssl3 - Just disable SSLv3\n");
|
||||||
BIO_printf(bio_err," -no_tls1 - Just disable TLSv1\n");
|
BIO_printf(bio_err," -no_tls1 - Just disable TLSv1\n");
|
||||||
|
BIO_printf(bio_err," -no_tls1_1 - Just disable TLSv1.1\n");
|
||||||
|
BIO_printf(bio_err," -no_tls1_2 - Just disable TLSv1.2\n");
|
||||||
#ifndef OPENSSL_NO_DH
|
#ifndef OPENSSL_NO_DH
|
||||||
BIO_printf(bio_err," -no_dhe - Disable ephemeral DH\n");
|
BIO_printf(bio_err," -no_dhe - Disable ephemeral DH\n");
|
||||||
#endif
|
#endif
|
||||||
@@ -489,7 +552,16 @@ static void sv_usage(void)
|
|||||||
BIO_printf(bio_err," not specified (default is %s)\n",TEST_CERT2);
|
BIO_printf(bio_err," not specified (default is %s)\n",TEST_CERT2);
|
||||||
BIO_printf(bio_err," -tlsextdebug - hex dump of all TLS extensions received\n");
|
BIO_printf(bio_err," -tlsextdebug - hex dump of all TLS extensions received\n");
|
||||||
BIO_printf(bio_err," -no_ticket - disable use of RFC4507bis session tickets\n");
|
BIO_printf(bio_err," -no_ticket - disable use of RFC4507bis session tickets\n");
|
||||||
|
BIO_printf(bio_err," -legacy_renegotiation - enable use of legacy renegotiation (dangerous)\n");
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
BIO_printf(bio_err," -nextprotoneg arg - set the advertised protocols for the NPN extension (comma-separated list)\n");
|
||||||
|
# endif
|
||||||
|
# ifndef OPENSSL_NO_SRTP
|
||||||
|
BIO_printf(bio_err," -use_srtp profiles - Offer SRTP key management with a colon-separated profile list\n");
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
BIO_printf(bio_err," -keymatexport label - Export keying material using label\n");
|
||||||
|
BIO_printf(bio_err," -keymatexportlen len - Export len bytes of keying material (default 20)\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
static int local_argc=0;
|
static int local_argc=0;
|
||||||
@@ -671,7 +743,7 @@ static int MS_CALLBACK ssl_servername_cb(SSL *s, int *ad, void *arg)
|
|||||||
return p->extension_error;
|
return p->extension_error;
|
||||||
if (ctx2)
|
if (ctx2)
|
||||||
{
|
{
|
||||||
BIO_printf(p->biodebug,"Swiching server context.\n");
|
BIO_printf(p->biodebug,"Switching server context.\n");
|
||||||
SSL_set_SSL_CTX(s,ctx2);
|
SSL_set_SSL_CTX(s,ctx2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -710,7 +782,7 @@ static int cert_status_cb(SSL *s, void *arg)
|
|||||||
int use_ssl;
|
int use_ssl;
|
||||||
unsigned char *rspder = NULL;
|
unsigned char *rspder = NULL;
|
||||||
int rspderlen;
|
int rspderlen;
|
||||||
STACK_OF(STRING) *aia = NULL;
|
STACK_OF(OPENSSL_STRING) *aia = NULL;
|
||||||
X509 *x = NULL;
|
X509 *x = NULL;
|
||||||
X509_STORE_CTX inctx;
|
X509_STORE_CTX inctx;
|
||||||
X509_OBJECT obj;
|
X509_OBJECT obj;
|
||||||
@@ -732,7 +804,7 @@ BIO_printf(err, "cert_status: received %d ids\n", sk_OCSP_RESPID_num(ids));
|
|||||||
aia = X509_get1_ocsp(x);
|
aia = X509_get1_ocsp(x);
|
||||||
if (aia)
|
if (aia)
|
||||||
{
|
{
|
||||||
if (!OCSP_parse_url(sk_STRING_value(aia, 0),
|
if (!OCSP_parse_url(sk_OPENSSL_STRING_value(aia, 0),
|
||||||
&host, &port, &path, &use_ssl))
|
&host, &port, &path, &use_ssl))
|
||||||
{
|
{
|
||||||
BIO_puts(err, "cert_status: can't parse AIA URL\n");
|
BIO_puts(err, "cert_status: can't parse AIA URL\n");
|
||||||
@@ -740,7 +812,7 @@ BIO_printf(err, "cert_status: received %d ids\n", sk_OCSP_RESPID_num(ids));
|
|||||||
}
|
}
|
||||||
if (srctx->verbose)
|
if (srctx->verbose)
|
||||||
BIO_printf(err, "cert_status: AIA URL: %s\n",
|
BIO_printf(err, "cert_status: AIA URL: %s\n",
|
||||||
sk_STRING_value(aia, 0));
|
sk_OPENSSL_STRING_value(aia, 0));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -785,7 +857,7 @@ BIO_printf(err, "cert_status: received %d ids\n", sk_OCSP_RESPID_num(ids));
|
|||||||
if (!OCSP_REQUEST_add_ext(req, ext, -1))
|
if (!OCSP_REQUEST_add_ext(req, ext, -1))
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
resp = process_responder(err, req, host, path, port, use_ssl,
|
resp = process_responder(err, req, host, path, port, use_ssl, NULL,
|
||||||
srctx->timeout);
|
srctx->timeout);
|
||||||
if (!resp)
|
if (!resp)
|
||||||
{
|
{
|
||||||
@@ -823,6 +895,26 @@ BIO_printf(err, "cert_status: received %d ids\n", sk_OCSP_RESPID_num(ids));
|
|||||||
ret = SSL_TLSEXT_ERR_ALERT_FATAL;
|
ret = SSL_TLSEXT_ERR_ALERT_FATAL;
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
/* This is the context that we pass to next_proto_cb */
|
||||||
|
typedef struct tlsextnextprotoctx_st {
|
||||||
|
unsigned char *data;
|
||||||
|
unsigned int len;
|
||||||
|
} tlsextnextprotoctx;
|
||||||
|
|
||||||
|
static int next_proto_cb(SSL *s, const unsigned char **data, unsigned int *len, void *arg)
|
||||||
|
{
|
||||||
|
tlsextnextprotoctx *next_proto = arg;
|
||||||
|
|
||||||
|
*data = next_proto->data;
|
||||||
|
*len = next_proto->len;
|
||||||
|
|
||||||
|
return SSL_TLSEXT_ERR_OK;
|
||||||
|
}
|
||||||
|
# endif /* ndef OPENSSL_NO_NEXTPROTONEG */
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
int MAIN(int, char **);
|
int MAIN(int, char **);
|
||||||
@@ -830,11 +922,17 @@ int MAIN(int, char **);
|
|||||||
#ifndef OPENSSL_NO_JPAKE
|
#ifndef OPENSSL_NO_JPAKE
|
||||||
static char *jpake_secret = NULL;
|
static char *jpake_secret = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
static srpsrvparm srp_callback_parm;
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
static char *srtp_profiles = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
int MAIN(int argc, char *argv[])
|
int MAIN(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
X509_STORE *store = NULL;
|
X509_VERIFY_PARAM *vpm = NULL;
|
||||||
int vflags = 0;
|
int badarg = 0;
|
||||||
short port=PORT;
|
short port=PORT;
|
||||||
char *CApath=NULL,*CAfile=NULL;
|
char *CApath=NULL,*CAfile=NULL;
|
||||||
unsigned char *context = NULL;
|
unsigned char *context = NULL;
|
||||||
@@ -857,24 +955,25 @@ int MAIN(int argc, char *argv[])
|
|||||||
int s_dcert_format = FORMAT_PEM, s_dkey_format = FORMAT_PEM;
|
int s_dcert_format = FORMAT_PEM, s_dkey_format = FORMAT_PEM;
|
||||||
X509 *s_cert = NULL, *s_dcert = NULL;
|
X509 *s_cert = NULL, *s_dcert = NULL;
|
||||||
EVP_PKEY *s_key = NULL, *s_dkey = NULL;
|
EVP_PKEY *s_key = NULL, *s_dkey = NULL;
|
||||||
|
int no_cache = 0;
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
EVP_PKEY *s_key2 = NULL;
|
EVP_PKEY *s_key2 = NULL;
|
||||||
X509 *s_cert2 = NULL;
|
X509 *s_cert2 = NULL;
|
||||||
#endif
|
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
|
||||||
tlsextctx tlsextcbp = {NULL, NULL, SSL_TLSEXT_ERR_ALERT_WARNING};
|
tlsextctx tlsextcbp = {NULL, NULL, SSL_TLSEXT_ERR_ALERT_WARNING};
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
const char *next_proto_neg_in = NULL;
|
||||||
|
tlsextnextprotoctx next_proto;
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_PSK
|
#ifndef OPENSSL_NO_PSK
|
||||||
/* by default do not send a PSK identity hint */
|
/* by default do not send a PSK identity hint */
|
||||||
static char *psk_identity_hint=NULL;
|
static char *psk_identity_hint=NULL;
|
||||||
#endif
|
#endif
|
||||||
#if !defined(OPENSSL_NO_SSL2) && !defined(OPENSSL_NO_SSL3)
|
#ifndef OPENSSL_NO_SRP
|
||||||
meth=SSLv23_server_method();
|
char *srpuserseed = NULL;
|
||||||
#elif !defined(OPENSSL_NO_SSL3)
|
char *srp_verifier_file = NULL;
|
||||||
meth=SSLv3_server_method();
|
|
||||||
#elif !defined(OPENSSL_NO_SSL2)
|
|
||||||
meth=SSLv2_server_method();
|
|
||||||
#endif
|
#endif
|
||||||
|
meth=SSLv23_server_method();
|
||||||
|
|
||||||
local_argc=argc;
|
local_argc=argc;
|
||||||
local_argv=argv;
|
local_argv=argv;
|
||||||
@@ -999,18 +1098,20 @@ int MAIN(int argc, char *argv[])
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
CApath= *(++argv);
|
CApath= *(++argv);
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-crl_check") == 0)
|
else if (strcmp(*argv,"-no_cache") == 0)
|
||||||
|
no_cache = 1;
|
||||||
|
else if (args_verify(&argv, &argc, &badarg, bio_err, &vpm))
|
||||||
{
|
{
|
||||||
vflags |= X509_V_FLAG_CRL_CHECK;
|
if (badarg)
|
||||||
}
|
goto bad;
|
||||||
else if (strcmp(*argv,"-crl_check_all") == 0)
|
continue;
|
||||||
{
|
|
||||||
vflags |= X509_V_FLAG_CRL_CHECK|X509_V_FLAG_CRL_CHECK_ALL;
|
|
||||||
}
|
}
|
||||||
else if (strcmp(*argv,"-verify_return_error") == 0)
|
else if (strcmp(*argv,"-verify_return_error") == 0)
|
||||||
verify_return_error = 1;
|
verify_return_error = 1;
|
||||||
else if (strcmp(*argv,"-serverpref") == 0)
|
else if (strcmp(*argv,"-serverpref") == 0)
|
||||||
{ off|=SSL_OP_CIPHER_SERVER_PREFERENCE; }
|
{ off|=SSL_OP_CIPHER_SERVER_PREFERENCE; }
|
||||||
|
else if (strcmp(*argv,"-legacy_renegotiation") == 0)
|
||||||
|
off|=SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION;
|
||||||
else if (strcmp(*argv,"-cipher") == 0)
|
else if (strcmp(*argv,"-cipher") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
@@ -1097,12 +1198,26 @@ int MAIN(int argc, char *argv[])
|
|||||||
psk_key=*(++argv);
|
psk_key=*(++argv);
|
||||||
for (i=0; i<strlen(psk_key); i++)
|
for (i=0; i<strlen(psk_key); i++)
|
||||||
{
|
{
|
||||||
if (isxdigit((int)psk_key[i]))
|
if (isxdigit((unsigned char)psk_key[i]))
|
||||||
continue;
|
continue;
|
||||||
BIO_printf(bio_err,"Not a hex number '%s'\n",*argv);
|
BIO_printf(bio_err,"Not a hex number '%s'\n",*argv);
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
else if (strcmp(*argv, "-srpvfile") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srp_verifier_file = *(++argv);
|
||||||
|
meth = TLSv1_server_method();
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv, "-srpuserseed") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srpuserseed = *(++argv);
|
||||||
|
meth = TLSv1_server_method();
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
else if (strcmp(*argv,"-www") == 0)
|
else if (strcmp(*argv,"-www") == 0)
|
||||||
{ www=1; }
|
{ www=1; }
|
||||||
@@ -1116,6 +1231,10 @@ int MAIN(int argc, char *argv[])
|
|||||||
{ off|=SSL_OP_NO_SSLv3; }
|
{ off|=SSL_OP_NO_SSLv3; }
|
||||||
else if (strcmp(*argv,"-no_tls1") == 0)
|
else if (strcmp(*argv,"-no_tls1") == 0)
|
||||||
{ off|=SSL_OP_NO_TLSv1; }
|
{ off|=SSL_OP_NO_TLSv1; }
|
||||||
|
else if (strcmp(*argv,"-no_tls1_1") == 0)
|
||||||
|
{ off|=SSL_OP_NO_TLSv1_1; }
|
||||||
|
else if (strcmp(*argv,"-no_tls1_2") == 0)
|
||||||
|
{ off|=SSL_OP_NO_TLSv1_2; }
|
||||||
else if (strcmp(*argv,"-no_comp") == 0)
|
else if (strcmp(*argv,"-no_comp") == 0)
|
||||||
{ off|=SSL_OP_NO_COMPRESSION; }
|
{ off|=SSL_OP_NO_COMPRESSION; }
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
@@ -1133,6 +1252,10 @@ int MAIN(int argc, char *argv[])
|
|||||||
#ifndef OPENSSL_NO_TLS1
|
#ifndef OPENSSL_NO_TLS1
|
||||||
else if (strcmp(*argv,"-tls1") == 0)
|
else if (strcmp(*argv,"-tls1") == 0)
|
||||||
{ meth=TLSv1_server_method(); }
|
{ meth=TLSv1_server_method(); }
|
||||||
|
else if (strcmp(*argv,"-tls1_1") == 0)
|
||||||
|
{ meth=TLSv1_1_server_method(); }
|
||||||
|
else if (strcmp(*argv,"-tls1_2") == 0)
|
||||||
|
{ meth=TLSv1_2_server_method(); }
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_DTLS1
|
#ifndef OPENSSL_NO_DTLS1
|
||||||
else if (strcmp(*argv,"-dtls1") == 0)
|
else if (strcmp(*argv,"-dtls1") == 0)
|
||||||
@@ -1185,7 +1308,13 @@ int MAIN(int argc, char *argv[])
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
s_key_file2= *(++argv);
|
s_key_file2= *(++argv);
|
||||||
}
|
}
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
else if (strcmp(*argv,"-nextprotoneg") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
next_proto_neg_in = *(++argv);
|
||||||
|
}
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
#if !defined(OPENSSL_NO_JPAKE) && !defined(OPENSSL_NO_PSK)
|
#if !defined(OPENSSL_NO_JPAKE) && !defined(OPENSSL_NO_PSK)
|
||||||
else if (strcmp(*argv,"-jpake") == 0)
|
else if (strcmp(*argv,"-jpake") == 0)
|
||||||
@@ -1194,6 +1323,24 @@ int MAIN(int argc, char *argv[])
|
|||||||
jpake_secret = *(++argv);
|
jpake_secret = *(++argv);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
else if (strcmp(*argv,"-use_srtp") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
srtp_profiles = *(++argv);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
else if (strcmp(*argv,"-keymatexport") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
keymatexportlabel= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-keymatexportlen") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
keymatexportlen=atoi(*(++argv));
|
||||||
|
if (keymatexportlen == 0) goto bad;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
||||||
@@ -1293,6 +1440,21 @@ bad:
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
if (next_proto_neg_in)
|
||||||
|
{
|
||||||
|
unsigned short len;
|
||||||
|
next_proto.data = next_protos_parse(&len, next_proto_neg_in);
|
||||||
|
if (next_proto.data == NULL)
|
||||||
|
goto end;
|
||||||
|
next_proto.len = len;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
next_proto.data = NULL;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
if (s_dcert_file)
|
if (s_dcert_file)
|
||||||
{
|
{
|
||||||
@@ -1388,8 +1550,15 @@ bad:
|
|||||||
if (socket_type == SOCK_DGRAM) SSL_CTX_set_read_ahead(ctx, 1);
|
if (socket_type == SOCK_DGRAM) SSL_CTX_set_read_ahead(ctx, 1);
|
||||||
|
|
||||||
if (state) SSL_CTX_set_info_callback(ctx,apps_ssl_info_callback);
|
if (state) SSL_CTX_set_info_callback(ctx,apps_ssl_info_callback);
|
||||||
|
if (no_cache)
|
||||||
|
SSL_CTX_set_session_cache_mode(ctx, SSL_SESS_CACHE_OFF);
|
||||||
|
else
|
||||||
|
SSL_CTX_sess_set_cache_size(ctx,128);
|
||||||
|
|
||||||
SSL_CTX_sess_set_cache_size(ctx,128);
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
if (srtp_profiles != NULL)
|
||||||
|
SSL_CTX_set_tlsext_use_srtp(ctx, srtp_profiles);
|
||||||
|
#endif
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
if (cipher == NULL) cipher=getenv("SSL_CIPHER");
|
if (cipher == NULL) cipher=getenv("SSL_CIPHER");
|
||||||
@@ -1410,8 +1579,8 @@ bad:
|
|||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
/* goto end; */
|
/* goto end; */
|
||||||
}
|
}
|
||||||
store = SSL_CTX_get_cert_store(ctx);
|
if (vpm)
|
||||||
X509_STORE_set_flags(store, vflags);
|
SSL_CTX_set1_param(ctx, vpm);
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
if (s_cert2)
|
if (s_cert2)
|
||||||
@@ -1455,16 +1624,24 @@ bad:
|
|||||||
|
|
||||||
if (state) SSL_CTX_set_info_callback(ctx2,apps_ssl_info_callback);
|
if (state) SSL_CTX_set_info_callback(ctx2,apps_ssl_info_callback);
|
||||||
|
|
||||||
SSL_CTX_sess_set_cache_size(ctx2,128);
|
if (no_cache)
|
||||||
|
SSL_CTX_set_session_cache_mode(ctx2,SSL_SESS_CACHE_OFF);
|
||||||
|
else
|
||||||
|
SSL_CTX_sess_set_cache_size(ctx2,128);
|
||||||
|
|
||||||
if ((!SSL_CTX_load_verify_locations(ctx2,CAfile,CApath)) ||
|
if ((!SSL_CTX_load_verify_locations(ctx2,CAfile,CApath)) ||
|
||||||
(!SSL_CTX_set_default_verify_paths(ctx2)))
|
(!SSL_CTX_set_default_verify_paths(ctx2)))
|
||||||
{
|
{
|
||||||
ERR_print_errors(bio_err);
|
ERR_print_errors(bio_err);
|
||||||
}
|
}
|
||||||
store = SSL_CTX_get_cert_store(ctx2);
|
if (vpm)
|
||||||
X509_STORE_set_flags(store, vflags);
|
SSL_CTX_set1_param(ctx2, vpm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# ifndef OPENSSL_NO_NEXTPROTONEG
|
||||||
|
if (next_proto.data)
|
||||||
|
SSL_CTX_set_next_protos_advertised_cb(ctx, next_proto_cb, &next_proto);
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_DH
|
#ifndef OPENSSL_NO_DH
|
||||||
@@ -1560,7 +1737,7 @@ bad:
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (!set_cert_key_stuff(ctx,s_cert,s_key))
|
if (!set_cert_key_stuff(ctx, s_cert, s_key))
|
||||||
goto end;
|
goto end;
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
if (ctx2 && !set_cert_key_stuff(ctx2,s_cert2,s_key2))
|
if (ctx2 && !set_cert_key_stuff(ctx2,s_cert2,s_key2))
|
||||||
@@ -1568,7 +1745,7 @@ bad:
|
|||||||
#endif
|
#endif
|
||||||
if (s_dcert != NULL)
|
if (s_dcert != NULL)
|
||||||
{
|
{
|
||||||
if (!set_cert_key_stuff(ctx,s_dcert,s_dkey))
|
if (!set_cert_key_stuff(ctx, s_dcert, s_dkey))
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1654,6 +1831,10 @@ bad:
|
|||||||
SSL_CTX_set_session_id_context(ctx,(void*)&s_server_session_id_context,
|
SSL_CTX_set_session_id_context(ctx,(void*)&s_server_session_id_context,
|
||||||
sizeof s_server_session_id_context);
|
sizeof s_server_session_id_context);
|
||||||
|
|
||||||
|
/* Set DTLS cookie generation and verification callbacks */
|
||||||
|
SSL_CTX_set_cookie_generate_cb(ctx, generate_cookie_callback);
|
||||||
|
SSL_CTX_set_cookie_verify_cb(ctx, verify_cookie_callback);
|
||||||
|
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
if (ctx2)
|
if (ctx2)
|
||||||
{
|
{
|
||||||
@@ -1669,6 +1850,25 @@ bad:
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
if (srp_verifier_file != NULL)
|
||||||
|
{
|
||||||
|
srp_callback_parm.vb = SRP_VBASE_new(srpuserseed);
|
||||||
|
srp_callback_parm.user = NULL;
|
||||||
|
srp_callback_parm.login = NULL;
|
||||||
|
if ((ret = SRP_VBASE_init(srp_callback_parm.vb, srp_verifier_file)) != SRP_NO_ERROR)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,
|
||||||
|
"Cannot initialize SRP verifier file \"%s\":ret=%d\n",
|
||||||
|
srp_verifier_file, ret);
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
SSL_CTX_set_verify(ctx, SSL_VERIFY_NONE,verify_callback);
|
||||||
|
SSL_CTX_set_srp_cb_arg(ctx, &srp_callback_parm);
|
||||||
|
SSL_CTX_set_srp_username_callback(ctx, ssl_srp_server_param_cb);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
#endif
|
||||||
if (CAfile != NULL)
|
if (CAfile != NULL)
|
||||||
{
|
{
|
||||||
SSL_CTX_set_client_CA_list(ctx,SSL_load_client_CA_file(CAfile));
|
SSL_CTX_set_client_CA_list(ctx,SSL_load_client_CA_file(CAfile));
|
||||||
@@ -1700,7 +1900,15 @@ end:
|
|||||||
OPENSSL_free(pass);
|
OPENSSL_free(pass);
|
||||||
if (dpass)
|
if (dpass)
|
||||||
OPENSSL_free(dpass);
|
OPENSSL_free(dpass);
|
||||||
|
if (vpm)
|
||||||
|
X509_VERIFY_PARAM_free(vpm);
|
||||||
#ifndef OPENSSL_NO_TLSEXT
|
#ifndef OPENSSL_NO_TLSEXT
|
||||||
|
if (tlscstatp.host)
|
||||||
|
OPENSSL_free(tlscstatp.host);
|
||||||
|
if (tlscstatp.port)
|
||||||
|
OPENSSL_free(tlscstatp.port);
|
||||||
|
if (tlscstatp.path)
|
||||||
|
OPENSSL_free(tlscstatp.path);
|
||||||
if (ctx2 != NULL) SSL_CTX_free(ctx2);
|
if (ctx2 != NULL) SSL_CTX_free(ctx2);
|
||||||
if (s_cert2)
|
if (s_cert2)
|
||||||
X509_free(s_cert2);
|
X509_free(s_cert2);
|
||||||
@@ -1750,8 +1958,14 @@ 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;
|
||||||
|
#ifndef OPENSSL_NO_KRB5
|
||||||
|
KSSL_CTX *kctx;
|
||||||
|
#endif
|
||||||
|
struct timeval timeout;
|
||||||
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS) || defined(OPENSSL_SYS_NETWARE) || defined(OPENSSL_SYS_BEOS_R5)
|
#if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MSDOS) || defined(OPENSSL_SYS_NETWARE) || defined(OPENSSL_SYS_BEOS_R5)
|
||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
|
#else
|
||||||
|
struct timeval *timeoutp;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if ((buf=OPENSSL_malloc(bufsize)) == NULL)
|
if ((buf=OPENSSL_malloc(bufsize)) == NULL)
|
||||||
@@ -1787,12 +2001,11 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_KRB5
|
#ifndef OPENSSL_NO_KRB5
|
||||||
if ((con->kssl_ctx = kssl_ctx_new()) != NULL)
|
if ((kctx = kssl_ctx_new()) != NULL)
|
||||||
{
|
{
|
||||||
kssl_ctx_setstring(con->kssl_ctx, KSSL_SERVICE,
|
SSL_set0_kssl_ctx(con, kctx);
|
||||||
KRB5SVC);
|
kssl_ctx_setstring(kctx, KSSL_SERVICE, KRB5SVC);
|
||||||
kssl_ctx_setstring(con->kssl_ctx, KSSL_KEYTAB,
|
kssl_ctx_setstring(kctx, KSSL_KEYTAB, KRB5KEYTAB);
|
||||||
KRB5KEYTAB);
|
|
||||||
}
|
}
|
||||||
#endif /* OPENSSL_NO_KRB5 */
|
#endif /* OPENSSL_NO_KRB5 */
|
||||||
if(context)
|
if(context)
|
||||||
@@ -1808,7 +2021,6 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
|
|
||||||
if (SSL_version(con) == DTLS1_VERSION)
|
if (SSL_version(con) == DTLS1_VERSION)
|
||||||
{
|
{
|
||||||
struct timeval timeout;
|
|
||||||
|
|
||||||
sbio=BIO_new_dgram(s,BIO_NOCLOSE);
|
sbio=BIO_new_dgram(s,BIO_NOCLOSE);
|
||||||
|
|
||||||
@@ -1823,10 +2035,10 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
BIO_ctrl(sbio, BIO_CTRL_DGRAM_SET_SEND_TIMEOUT, 0, &timeout);
|
BIO_ctrl(sbio, BIO_CTRL_DGRAM_SET_SEND_TIMEOUT, 0, &timeout);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (socket_mtu > 0)
|
if (socket_mtu > 28)
|
||||||
{
|
{
|
||||||
SSL_set_options(con, SSL_OP_NO_QUERY_MTU);
|
SSL_set_options(con, SSL_OP_NO_QUERY_MTU);
|
||||||
SSL_set_mtu(con, socket_mtu);
|
SSL_set_mtu(con, socket_mtu - 28);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
/* want to do MTU discovery */
|
/* want to do MTU discovery */
|
||||||
@@ -1856,7 +2068,7 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
|
|
||||||
if (s_debug)
|
if (s_debug)
|
||||||
{
|
{
|
||||||
con->debug=1;
|
SSL_set_debug(con, 1);
|
||||||
BIO_set_callback(SSL_get_rbio(con),bio_dump_callback);
|
BIO_set_callback(SSL_get_rbio(con),bio_dump_callback);
|
||||||
BIO_set_callback_arg(SSL_get_rbio(con),(char *)bio_s_out);
|
BIO_set_callback_arg(SSL_get_rbio(con),(char *)bio_s_out);
|
||||||
}
|
}
|
||||||
@@ -1919,7 +2131,19 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
read_from_terminal = 1;
|
read_from_terminal = 1;
|
||||||
(void)fcntl(fileno(stdin), F_SETFL, 0);
|
(void)fcntl(fileno(stdin), F_SETFL, 0);
|
||||||
#else
|
#else
|
||||||
i=select(width,(void *)&readfds,NULL,NULL,NULL);
|
if ((SSL_version(con) == DTLS1_VERSION) &&
|
||||||
|
DTLSv1_get_timeout(con, &timeout))
|
||||||
|
timeoutp = &timeout;
|
||||||
|
else
|
||||||
|
timeoutp = NULL;
|
||||||
|
|
||||||
|
i=select(width,(void *)&readfds,NULL,NULL,timeoutp);
|
||||||
|
|
||||||
|
if ((SSL_version(con) == DTLS1_VERSION) && DTLSv1_handle_timeout(con) > 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"TIMEOUT occured\n");
|
||||||
|
}
|
||||||
|
|
||||||
if (i <= 0) continue;
|
if (i <= 0) continue;
|
||||||
if (FD_ISSET(fileno(stdin),&readfds))
|
if (FD_ISSET(fileno(stdin),&readfds))
|
||||||
read_from_terminal = 1;
|
read_from_terminal = 1;
|
||||||
@@ -1973,6 +2197,16 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_HEARTBEATS
|
||||||
|
if ((buf[0] == 'B') &&
|
||||||
|
((buf[1] == '\n') || (buf[1] == '\r')))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"HEARTBEATING\n");
|
||||||
|
SSL_heartbeat(con);
|
||||||
|
i=0;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
if ((buf[0] == 'r') &&
|
if ((buf[0] == 'r') &&
|
||||||
((buf[1] == '\n') || (buf[1] == '\r')))
|
((buf[1] == '\n') || (buf[1] == '\r')))
|
||||||
{
|
{
|
||||||
@@ -2016,6 +2250,18 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
{ static count=0; if (++count == 100) { count=0; SSL_renegotiate(con); } }
|
{ static count=0; if (++count == 100) { count=0; SSL_renegotiate(con); } }
|
||||||
#endif
|
#endif
|
||||||
k=SSL_write(con,&(buf[l]),(unsigned int)i);
|
k=SSL_write(con,&(buf[l]),(unsigned int)i);
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
while (SSL_get_error(con,k) == SSL_ERROR_WANT_X509_LOOKUP)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP renego during write\n");
|
||||||
|
srp_callback_parm.user = SRP_VBASE_get_by_user(srp_callback_parm.vb, srp_callback_parm.login);
|
||||||
|
if (srp_callback_parm.user)
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP done %s\n",srp_callback_parm.user->info);
|
||||||
|
else
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP not successful\n");
|
||||||
|
k=SSL_write(con,&(buf[l]),(unsigned int)i);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
switch (SSL_get_error(con,k))
|
switch (SSL_get_error(con,k))
|
||||||
{
|
{
|
||||||
case SSL_ERROR_NONE:
|
case SSL_ERROR_NONE:
|
||||||
@@ -2063,6 +2309,18 @@ static int sv_body(char *hostname, int s, unsigned char *context)
|
|||||||
{
|
{
|
||||||
again:
|
again:
|
||||||
i=SSL_read(con,(char *)buf,bufsize);
|
i=SSL_read(con,(char *)buf,bufsize);
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
while (SSL_get_error(con,i) == SSL_ERROR_WANT_X509_LOOKUP)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP renego during read\n");
|
||||||
|
srp_callback_parm.user = SRP_VBASE_get_by_user(srp_callback_parm.vb, srp_callback_parm.login);
|
||||||
|
if (srp_callback_parm.user)
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP done %s\n",srp_callback_parm.user->info);
|
||||||
|
else
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP not successful\n");
|
||||||
|
i=SSL_read(con,(char *)buf,bufsize);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
switch (SSL_get_error(con,i))
|
switch (SSL_get_error(con,i))
|
||||||
{
|
{
|
||||||
case SSL_ERROR_NONE:
|
case SSL_ERROR_NONE:
|
||||||
@@ -2075,7 +2333,6 @@ again:
|
|||||||
break;
|
break;
|
||||||
case SSL_ERROR_WANT_WRITE:
|
case SSL_ERROR_WANT_WRITE:
|
||||||
case SSL_ERROR_WANT_READ:
|
case SSL_ERROR_WANT_READ:
|
||||||
case SSL_ERROR_WANT_X509_LOOKUP:
|
|
||||||
BIO_printf(bio_s_out,"Read BLOCK\n");
|
BIO_printf(bio_s_out,"Read BLOCK\n");
|
||||||
break;
|
break;
|
||||||
case SSL_ERROR_SYSCALL:
|
case SSL_ERROR_SYSCALL:
|
||||||
@@ -2130,8 +2387,30 @@ static int init_ssl_connection(SSL *con)
|
|||||||
X509 *peer;
|
X509 *peer;
|
||||||
long verify_error;
|
long verify_error;
|
||||||
MS_STATIC char buf[BUFSIZ];
|
MS_STATIC char buf[BUFSIZ];
|
||||||
|
#ifndef OPENSSL_NO_KRB5
|
||||||
|
char *client_princ;
|
||||||
|
#endif
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
const unsigned char *next_proto_neg;
|
||||||
|
unsigned next_proto_neg_len;
|
||||||
|
#endif
|
||||||
|
unsigned char *exportedkeymat;
|
||||||
|
|
||||||
if ((i=SSL_accept(con)) <= 0)
|
|
||||||
|
i=SSL_accept(con);
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
while (i <= 0 && SSL_get_error(con,i) == SSL_ERROR_WANT_X509_LOOKUP)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP during accept %s\n",srp_callback_parm.login);
|
||||||
|
srp_callback_parm.user = SRP_VBASE_get_by_user(srp_callback_parm.vb, srp_callback_parm.login);
|
||||||
|
if (srp_callback_parm.user)
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP done %s\n",srp_callback_parm.user->info);
|
||||||
|
else
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP not successful\n");
|
||||||
|
i=SSL_accept(con);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
if (i <= 0)
|
||||||
{
|
{
|
||||||
if (BIO_sock_should_retry(i))
|
if (BIO_sock_should_retry(i))
|
||||||
{
|
{
|
||||||
@@ -2169,17 +2448,70 @@ static int init_ssl_connection(SSL *con)
|
|||||||
BIO_printf(bio_s_out,"Shared ciphers:%s\n",buf);
|
BIO_printf(bio_s_out,"Shared ciphers:%s\n",buf);
|
||||||
str=SSL_CIPHER_get_name(SSL_get_current_cipher(con));
|
str=SSL_CIPHER_get_name(SSL_get_current_cipher(con));
|
||||||
BIO_printf(bio_s_out,"CIPHER is %s\n",(str != NULL)?str:"(NONE)");
|
BIO_printf(bio_s_out,"CIPHER is %s\n",(str != NULL)?str:"(NONE)");
|
||||||
if (con->hit) BIO_printf(bio_s_out,"Reused session-id\n");
|
|
||||||
|
#if !defined(OPENSSL_NO_TLSEXT) && !defined(OPENSSL_NO_NEXTPROTONEG)
|
||||||
|
SSL_get0_next_proto_negotiated(con, &next_proto_neg, &next_proto_neg_len);
|
||||||
|
if (next_proto_neg)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out,"NEXTPROTO is ");
|
||||||
|
BIO_write(bio_s_out, next_proto_neg, next_proto_neg_len);
|
||||||
|
BIO_printf(bio_s_out, "\n");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_SRTP
|
||||||
|
{
|
||||||
|
SRTP_PROTECTION_PROFILE *srtp_profile
|
||||||
|
= SSL_get_selected_srtp_profile(con);
|
||||||
|
|
||||||
|
if(srtp_profile)
|
||||||
|
BIO_printf(bio_s_out,"SRTP Extension negotiated, profile=%s\n",
|
||||||
|
srtp_profile->name);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
if (SSL_cache_hit(con)) BIO_printf(bio_s_out,"Reused session-id\n");
|
||||||
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
|
#ifndef OPENSSL_NO_KRB5
|
||||||
if (con->kssl_ctx->client_princ != NULL)
|
client_princ = kssl_ctx_get0_client_princ(SSL_get0_kssl_ctx(con));
|
||||||
|
if (client_princ != NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_s_out,"Kerberos peer principal is %s\n",
|
BIO_printf(bio_s_out,"Kerberos peer principal is %s\n",
|
||||||
con->kssl_ctx->client_princ);
|
client_princ);
|
||||||
}
|
}
|
||||||
#endif /* OPENSSL_NO_KRB5 */
|
#endif /* OPENSSL_NO_KRB5 */
|
||||||
|
BIO_printf(bio_s_out, "Secure Renegotiation IS%s supported\n",
|
||||||
|
SSL_get_secure_renegotiation_support(con) ? "" : " NOT");
|
||||||
|
if (keymatexportlabel != NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out, "Keying material exporter:\n");
|
||||||
|
BIO_printf(bio_s_out, " Label: '%s'\n", keymatexportlabel);
|
||||||
|
BIO_printf(bio_s_out, " Length: %i bytes\n",
|
||||||
|
keymatexportlen);
|
||||||
|
exportedkeymat = OPENSSL_malloc(keymatexportlen);
|
||||||
|
if (exportedkeymat != NULL)
|
||||||
|
{
|
||||||
|
if (!SSL_export_keying_material(con, exportedkeymat,
|
||||||
|
keymatexportlen,
|
||||||
|
keymatexportlabel,
|
||||||
|
strlen(keymatexportlabel),
|
||||||
|
NULL, 0, 0))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out, " Error\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out, " Keying material: ");
|
||||||
|
for (i=0; i<keymatexportlen; i++)
|
||||||
|
BIO_printf(bio_s_out, "%02X",
|
||||||
|
exportedkeymat[i]);
|
||||||
|
BIO_printf(bio_s_out, "\n");
|
||||||
|
}
|
||||||
|
OPENSSL_free(exportedkeymat);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2197,6 +2529,9 @@ err:
|
|||||||
return(ret);
|
return(ret);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_KRB5
|
||||||
|
char *client_princ;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
static int load_CA(SSL_CTX *ctx, char *file)
|
static int load_CA(SSL_CTX *ctx, char *file)
|
||||||
@@ -2223,11 +2558,13 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
{
|
{
|
||||||
char *buf=NULL;
|
char *buf=NULL;
|
||||||
int ret=1;
|
int ret=1;
|
||||||
int i,j,k,blank,dot;
|
int i,j,k,dot;
|
||||||
SSL *con;
|
SSL *con;
|
||||||
const SSL_CIPHER *c;
|
const SSL_CIPHER *c;
|
||||||
BIO *io,*ssl_bio,*sbio;
|
BIO *io,*ssl_bio,*sbio;
|
||||||
long total_bytes;
|
#ifndef OPENSSL_NO_KRB5
|
||||||
|
KSSL_CTX *kctx;
|
||||||
|
#endif
|
||||||
|
|
||||||
buf=OPENSSL_malloc(bufsize);
|
buf=OPENSSL_malloc(bufsize);
|
||||||
if (buf == NULL) return(0);
|
if (buf == NULL) return(0);
|
||||||
@@ -2259,10 +2596,10 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_KRB5
|
#ifndef OPENSSL_NO_KRB5
|
||||||
if ((con->kssl_ctx = kssl_ctx_new()) != NULL)
|
if ((kctx = kssl_ctx_new()) != NULL)
|
||||||
{
|
{
|
||||||
kssl_ctx_setstring(con->kssl_ctx, KSSL_SERVICE, KRB5SVC);
|
kssl_ctx_setstring(kctx, KSSL_SERVICE, KRB5SVC);
|
||||||
kssl_ctx_setstring(con->kssl_ctx, KSSL_KEYTAB, KRB5KEYTAB);
|
kssl_ctx_setstring(kctx, KSSL_KEYTAB, KRB5KEYTAB);
|
||||||
}
|
}
|
||||||
#endif /* OPENSSL_NO_KRB5 */
|
#endif /* OPENSSL_NO_KRB5 */
|
||||||
if(context) SSL_set_session_id_context(con, context,
|
if(context) SSL_set_session_id_context(con, context,
|
||||||
@@ -2288,7 +2625,7 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
|
|
||||||
if (s_debug)
|
if (s_debug)
|
||||||
{
|
{
|
||||||
con->debug=1;
|
SSL_set_debug(con, 1);
|
||||||
BIO_set_callback(SSL_get_rbio(con),bio_dump_callback);
|
BIO_set_callback(SSL_get_rbio(con),bio_dump_callback);
|
||||||
BIO_set_callback_arg(SSL_get_rbio(con),(char *)bio_s_out);
|
BIO_set_callback_arg(SSL_get_rbio(con),(char *)bio_s_out);
|
||||||
}
|
}
|
||||||
@@ -2298,13 +2635,23 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
SSL_set_msg_callback_arg(con, bio_s_out);
|
SSL_set_msg_callback_arg(con, bio_s_out);
|
||||||
}
|
}
|
||||||
|
|
||||||
blank=0;
|
|
||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
if (hack)
|
if (hack)
|
||||||
{
|
{
|
||||||
i=SSL_accept(con);
|
i=SSL_accept(con);
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
while (i <= 0 && SSL_get_error(con,i) == SSL_ERROR_WANT_X509_LOOKUP)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP during accept %s\n",srp_callback_parm.login);
|
||||||
|
srp_callback_parm.user = SRP_VBASE_get_by_user(srp_callback_parm.vb, srp_callback_parm.login);
|
||||||
|
if (srp_callback_parm.user)
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP done %s\n",srp_callback_parm.user->info);
|
||||||
|
else
|
||||||
|
BIO_printf(bio_s_out,"LOOKUP not successful\n");
|
||||||
|
i=SSL_accept(con);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
switch (SSL_get_error(con,i))
|
switch (SSL_get_error(con,i))
|
||||||
{
|
{
|
||||||
case SSL_ERROR_NONE:
|
case SSL_ERROR_NONE:
|
||||||
@@ -2372,6 +2719,11 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
}
|
}
|
||||||
BIO_puts(io,"\n");
|
BIO_puts(io,"\n");
|
||||||
|
|
||||||
|
BIO_printf(io,
|
||||||
|
"Secure Renegotiation IS%s supported\n",
|
||||||
|
SSL_get_secure_renegotiation_support(con) ?
|
||||||
|
"" : " NOT");
|
||||||
|
|
||||||
/* The following is evil and should not really
|
/* The following is evil and should not really
|
||||||
* be done */
|
* be done */
|
||||||
BIO_printf(io,"Ciphers supported in s_server binary\n");
|
BIO_printf(io,"Ciphers supported in s_server binary\n");
|
||||||
@@ -2410,7 +2762,7 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
}
|
}
|
||||||
BIO_puts(io,"\n");
|
BIO_puts(io,"\n");
|
||||||
}
|
}
|
||||||
BIO_printf(io,((con->hit)
|
BIO_printf(io,(SSL_cache_hit(con)
|
||||||
?"---\nReused, "
|
?"---\nReused, "
|
||||||
:"---\nNew, "));
|
:"---\nNew, "));
|
||||||
c=SSL_get_current_cipher(con);
|
c=SSL_get_current_cipher(con);
|
||||||
@@ -2528,7 +2880,6 @@ static int www_body(char *hostname, int s, unsigned char *context)
|
|||||||
BIO_puts(io,"HTTP/1.0 200 ok\r\nContent-type: text/plain\r\n\r\n");
|
BIO_puts(io,"HTTP/1.0 200 ok\r\nContent-type: text/plain\r\n\r\n");
|
||||||
}
|
}
|
||||||
/* send the file */
|
/* send the file */
|
||||||
total_bytes=0;
|
|
||||||
for (;;)
|
for (;;)
|
||||||
{
|
{
|
||||||
i=BIO_read(file,buf,bufsize);
|
i=BIO_read(file,buf,bufsize);
|
||||||
|
|||||||
@@ -62,6 +62,12 @@
|
|||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
|
||||||
|
#ifdef FLAT_INC
|
||||||
|
#include "e_os2.h"
|
||||||
|
#else
|
||||||
|
#include "../e_os2.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
/* With IPv6, it looks like Digital has mixed up the proper order of
|
/* With IPv6, it looks like Digital has mixed up the proper order of
|
||||||
recursive header file inclusion, resulting in the compiler complaining
|
recursive header file inclusion, resulting in the compiler complaining
|
||||||
that u_int isn't defined, but only if _POSIX_C_SOURCE is defined, which
|
that u_int isn't defined, but only if _POSIX_C_SOURCE is defined, which
|
||||||
@@ -232,11 +238,10 @@ int init_client(int *sock, char *host, int port, int type)
|
|||||||
{
|
{
|
||||||
unsigned char ip[4];
|
unsigned char ip[4];
|
||||||
|
|
||||||
|
memset(ip, '\0', sizeof ip);
|
||||||
if (!host_ip(host,&(ip[0])))
|
if (!host_ip(host,&(ip[0])))
|
||||||
{
|
return 0;
|
||||||
return(0);
|
return init_client_ip(sock,ip,port,type);
|
||||||
}
|
|
||||||
return(init_client_ip(sock,ip,port,type));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int init_client_ip(int *sock, unsigned char ip[4], int port, int type)
|
static int init_client_ip(int *sock, unsigned char ip[4], int port, int type)
|
||||||
@@ -321,7 +326,7 @@ static int init_server_long(int *sock, int port, char *ip, int type)
|
|||||||
{
|
{
|
||||||
int ret=0;
|
int ret=0;
|
||||||
struct sockaddr_in server;
|
struct sockaddr_in server;
|
||||||
int s= -1,i;
|
int s= -1;
|
||||||
|
|
||||||
if (!ssl_sock_init()) return(0);
|
if (!ssl_sock_init()) return(0);
|
||||||
|
|
||||||
@@ -360,7 +365,6 @@ static int init_server_long(int *sock, int port, char *ip, int type)
|
|||||||
}
|
}
|
||||||
/* Make it 128 for linux */
|
/* Make it 128 for linux */
|
||||||
if (type==SOCK_STREAM && listen(s,128) == -1) goto err;
|
if (type==SOCK_STREAM && listen(s,128) == -1) goto err;
|
||||||
i=0;
|
|
||||||
*sock=s;
|
*sock=s;
|
||||||
ret=1;
|
ret=1;
|
||||||
err:
|
err:
|
||||||
@@ -378,7 +382,7 @@ static int init_server(int *sock, int port, int type)
|
|||||||
|
|
||||||
static int do_accept(int acc_sock, int *sock, char **host)
|
static int do_accept(int acc_sock, int *sock, char **host)
|
||||||
{
|
{
|
||||||
int ret,i;
|
int ret;
|
||||||
struct hostent *h1,*h2;
|
struct hostent *h1,*h2;
|
||||||
static struct sockaddr_in from;
|
static struct sockaddr_in from;
|
||||||
int len;
|
int len;
|
||||||
@@ -401,6 +405,7 @@ redoit:
|
|||||||
if (ret == INVALID_SOCKET)
|
if (ret == INVALID_SOCKET)
|
||||||
{
|
{
|
||||||
#if defined(OPENSSL_SYS_WINDOWS) || (defined(OPENSSL_SYS_NETWARE) && !defined(NETWARE_BSDSOCK))
|
#if defined(OPENSSL_SYS_WINDOWS) || (defined(OPENSSL_SYS_NETWARE) && !defined(NETWARE_BSDSOCK))
|
||||||
|
int i;
|
||||||
i=WSAGetLastError();
|
i=WSAGetLastError();
|
||||||
BIO_printf(bio_err,"accept error %d\n",i);
|
BIO_printf(bio_err,"accept error %d\n",i);
|
||||||
#else
|
#else
|
||||||
@@ -455,7 +460,6 @@ redoit:
|
|||||||
BIO_printf(bio_err,"gethostbyname failure\n");
|
BIO_printf(bio_err,"gethostbyname failure\n");
|
||||||
return(0);
|
return(0);
|
||||||
}
|
}
|
||||||
i=0;
|
|
||||||
if (h2->h_addrtype != AF_INET)
|
if (h2->h_addrtype != AF_INET)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"gethostbyname addr is not AF_INET\n");
|
BIO_printf(bio_err,"gethostbyname addr is not AF_INET\n");
|
||||||
|
|||||||
413
apps/server.pem
413
apps/server.pem
@@ -1,369 +1,52 @@
|
|||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit)
|
subject= C = UK, O = OpenSSL Group, OU = FOR TESTING PURPOSES ONLY, CN = Test Server Cert
|
||||||
subject= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Server test cert (512 bit)
|
issuer= C = UK, O = OpenSSL Group, OU = FOR TESTING PURPOSES ONLY, CN = OpenSSL Test Intermediate CA
|
||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
MIIB6TCCAVICAQYwDQYJKoZIhvcNAQEEBQAwWzELMAkGA1UEBhMCQVUxEzARBgNV
|
MIID5zCCAs+gAwIBAgIJALnu1NlVpZ6zMA0GCSqGSIb3DQEBBQUAMHAxCzAJBgNV
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRswGQYD
|
BAYTAlVLMRYwFAYDVQQKDA1PcGVuU1NMIEdyb3VwMSIwIAYDVQQLDBlGT1IgVEVT
|
||||||
VQQDExJUZXN0IENBICgxMDI0IGJpdCkwHhcNMDAxMDE2MjIzMTAzWhcNMDMwMTE0
|
VElORyBQVVJQT1NFUyBPTkxZMSUwIwYDVQQDDBxPcGVuU1NMIFRlc3QgSW50ZXJt
|
||||||
MjIzMTAzWjBjMQswCQYDVQQGEwJBVTETMBEGA1UECBMKUXVlZW5zbGFuZDEaMBgG
|
ZWRpYXRlIENBMB4XDTExMTIwODE0MDE0OFoXDTIxMTAxNjE0MDE0OFowZDELMAkG
|
||||||
A1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxIzAhBgNVBAMTGlNlcnZlciB0ZXN0IGNl
|
A1UEBhMCVUsxFjAUBgNVBAoMDU9wZW5TU0wgR3JvdXAxIjAgBgNVBAsMGUZPUiBU
|
||||||
cnQgKDUxMiBiaXQpMFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJ+zw4Qnlf8SMVIP
|
RVNUSU5HIFBVUlBPU0VTIE9OTFkxGTAXBgNVBAMMEFRlc3QgU2VydmVyIENlcnQw
|
||||||
Fe9GEcStgOY2Ww/dgNdhjeD8ckUJNP5VZkVDTGiXav6ooKXfX3j/7tdkuD8Ey2//
|
ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDzhPOSNtyyRspmeuUpxfNJ
|
||||||
Kv7+ue0CAwEAATANBgkqhkiG9w0BAQQFAAOBgQCT0grFQeZaqYb5EYfk20XixZV4
|
KCLTuf7g3uQ4zu4iHOmRO5TQci+HhVlLZrHF9XqFXcIP0y4pWDbMSGuiorUmzmfi
|
||||||
GmyAbXMftG1Eo7qGiMhYzRwGNWxEYojf5PZkYZXvSqZ/ZXHXa4g59jK/rJNnaVGM
|
R7bfSdI/+qIQt8KXRH6HNG1t8ou0VSvWId5TS5Dq/er5ODUr9OaaDva7EquHIcMv
|
||||||
k+xIX8mxQvlV0n5O9PIha5BX5teZnkHKgL8aKKLKW1BK7YTngsfSzzaeame5iKfz
|
vPQGuI+OEAcnleVCy9HVEIySrO4P3CNIicnGkwwiAud05yUAq/gPXBC1hTtmlPD7
|
||||||
itAE+OjGF+PFKbwX8Q==
|
TVcGVSEiJdvzqqlgv02qedGrkki6GY4S7GjZxrrf7Foc2EP+51LJzwLQx3/JfrCU
|
||||||
|
41NEWAsu/Sl0tQabXESN+zJ1pDqoZ3uHMgpQjeGiE0olr+YcsSW/tJmiU9OiAr8R
|
||||||
|
AgMBAAGjgY8wgYwwDAYDVR0TAQH/BAIwADAOBgNVHQ8BAf8EBAMCBeAwLAYJYIZI
|
||||||
|
AYb4QgENBB8WHU9wZW5TU0wgR2VuZXJhdGVkIENlcnRpZmljYXRlMB0GA1UdDgQW
|
||||||
|
BBSCvM8AABPR9zklmifnr9LvIBturDAfBgNVHSMEGDAWgBQ2w2yI55X+sL3szj49
|
||||||
|
hqshgYfa2jANBgkqhkiG9w0BAQUFAAOCAQEAqb1NV0B0/pbpK9Z4/bNjzPQLTRLK
|
||||||
|
WnSNm/Jh5v0GEUOE/Beg7GNjNrmeNmqxAlpqWz9qoeoFZax+QBpIZYjROU3TS3fp
|
||||||
|
yLsrnlr0CDQ5R7kCCDGa8dkXxemmpZZLbUCpW2Uoy8sAA4JjN9OtsZY7dvUXFgJ7
|
||||||
|
vVNTRnI01ghknbtD+2SxSQd3CWF6QhcRMAzZJ1z1cbbwGDDzfvGFPzJ+Sq+zEPds
|
||||||
|
xoVLLSetCiBc+40ZcDS5dV98h9XD7JMTQfxzA7mNGv73JoZJA6nFgj+ADSlJsY/t
|
||||||
|
JBv+z1iQRueoh9Qeee+ZbRifPouCB8FDx+AltvHTANdAq0t/K3o+pplMVA==
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
-----BEGIN RSA PRIVATE KEY-----
|
||||||
MIIBPAIBAAJBAJ+zw4Qnlf8SMVIPFe9GEcStgOY2Ww/dgNdhjeD8ckUJNP5VZkVD
|
MIIEpAIBAAKCAQEA84TzkjbcskbKZnrlKcXzSSgi07n+4N7kOM7uIhzpkTuU0HIv
|
||||||
TGiXav6ooKXfX3j/7tdkuD8Ey2//Kv7+ue0CAwEAAQJAN6W31vDEP2DjdqhzCDDu
|
h4VZS2axxfV6hV3CD9MuKVg2zEhroqK1Js5n4ke230nSP/qiELfCl0R+hzRtbfKL
|
||||||
OA4NACqoiFqyblo7yc2tM4h4xMbC3Yx5UKMN9ZkCtX0gzrz6DyF47bdKcWBzNWCj
|
tFUr1iHeU0uQ6v3q+Tg1K/Tmmg72uxKrhyHDL7z0BriPjhAHJ5XlQsvR1RCMkqzu
|
||||||
gQIhANEoojVt7hq+SQ6MCN6FTAysGgQf56Q3TYoJMoWvdiXVAiEAw3e3rc+VJpOz
|
D9wjSInJxpMMIgLndOclAKv4D1wQtYU7ZpTw+01XBlUhIiXb86qpYL9NqnnRq5JI
|
||||||
rHuDo6bgpjUAAXM+v3fcpsfZSNO6V7kCIQCtbVjanpUwvZkMI9by02oUk9taki3b
|
uhmOEuxo2ca63+xaHNhD/udSyc8C0Md/yX6wlONTRFgLLv0pdLUGm1xEjfsydaQ6
|
||||||
PzPfAfNPYAbCJQIhAJXNQDWyqwn/lGmR11cqY2y9nZ1+5w3yHGatLrcDnQHxAiEA
|
qGd7hzIKUI3hohNKJa/mHLElv7SZolPTogK/EQIDAQABAoIBAADq9FwNtuE5IRQn
|
||||||
vnlEGo8K85u+KwIOimM48ZG8oTk7iFdkqLJR1utT3aU=
|
zGtO4q7Y5uCzZ8GDNYr9RKp+P2cbuWDbvVAecYq2NV9QoIiWJOAYZKklOvekIju3
|
||||||
|
r0UZLA0PRiIrTg6NrESx3JrjWDK8QNlUO7CPTZ39/K+FrmMkV9lem9yxjJjyC34D
|
||||||
|
AQB+YRTx+l14HppjdxNwHjAVQpIx/uO2F5xAMuk32+3K+pq9CZUtrofe1q4Agj9R
|
||||||
|
5s8mSy9pbRo9kW9wl5xdEotz1LivFOEiqPUJTUq5J5PeMKao3vdK726XI4Z455Nm
|
||||||
|
W2/MA0YV0ug2FYinHcZdvKM6dimH8GLfa3X8xKRfzjGjTiMSwsdjgMa4awY3tEHH
|
||||||
|
674jhAECgYEA/zqMrc0zsbNk83sjgaYIug5kzEpN4ic020rSZsmQxSCerJTgNhmg
|
||||||
|
utKSCt0Re09Jt3LqG48msahX8ycqDsHNvlEGPQSbMu9IYeO3Wr3fAm75GEtFWePY
|
||||||
|
BhM73I7gkRt4s8bUiUepMG/wY45c5tRF23xi8foReHFFe9MDzh8fJFECgYEA9EFX
|
||||||
|
4qAik1pOJGNei9BMwmx0I0gfVEIgu0tzeVqT45vcxbxr7RkTEaDoAG6PlbWP6D9a
|
||||||
|
WQNLp4gsgRM90ZXOJ4up5DsAWDluvaF4/omabMA+MJJ5kGZ0gCj5rbZbKqUws7x8
|
||||||
|
bp+6iBfUPJUbcqNqFmi/08Yt7vrDnMnyMw2A/sECgYEAiiuRMxnuzVm34hQcsbhH
|
||||||
|
6ymVqf7j0PW2qK0F4H1ocT9qhzWFd+RB3kHWrCjnqODQoI6GbGr/4JepHUpre1ex
|
||||||
|
4UEN5oSS3G0ru0rC3U4C59dZ5KwDHFm7ffZ1pr52ljfQDUsrjjIMRtuiwNK2OoRa
|
||||||
|
WSsqiaL+SDzSB+nBmpnAizECgYBdt/y6rerWUx4MhDwwtTnel7JwHyo2MDFS6/5g
|
||||||
|
n8qC2Lj6/fMDRE22w+CA2esp7EJNQJGv+b27iFpbJEDh+/Lf5YzIT4MwVskQ5bYB
|
||||||
|
JFcmRxUVmf4e09D7o705U/DjCgMH09iCsbLmqQ38ONIRSHZaJtMDtNTHD1yi+jF+
|
||||||
|
OT43gQKBgQC/2OHZoko6iRlNOAQ/tMVFNq7fL81GivoQ9F1U0Qr+DH3ZfaH8eIkX
|
||||||
|
xT0ToMPJUzWAn8pZv0snA0um6SIgvkCuxO84OkANCVbttzXImIsL7pFzfcwV/ERK
|
||||||
|
UM6j0ZuSMFOCr/lGPAoOQU0fskidGEHi1/kW+suSr28TqsyYZpwBDQ==
|
||||||
-----END RSA PRIVATE KEY-----
|
-----END RSA PRIVATE KEY-----
|
||||||
subject=/C=US/O=AT&T Bell Laboratories/OU=Prototype Research CA
|
|
||||||
issuer= /C=US/O=AT&T Bell Laboratories/OU=Prototype Research CA
|
|
||||||
notBefore=950413210656Z
|
|
||||||
notAfter =970412210656Z
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICCDCCAXECAQAwDQYJKoZIhvcNAQEEBQAwTjELMAkGA1UEBhMCVVMxHzAdBgNV
|
|
||||||
BAoUFkFUJlQgQmVsbCBMYWJvcmF0b3JpZXMxHjAcBgNVBAsUFVByb3RvdHlwZSBS
|
|
||||||
ZXNlYXJjaCBDQTAeFw05NTA0MTMyMTA2NTZaFw05NzA0MTIyMTA2NTZaME4xCzAJ
|
|
||||||
BgNVBAYTAlVTMR8wHQYDVQQKFBZBVCZUIEJlbGwgTGFib3JhdG9yaWVzMR4wHAYD
|
|
||||||
VQQLFBVQcm90b3R5cGUgUmVzZWFyY2ggQ0EwgZwwDQYJKoZIhvcNAQEBBQADgYoA
|
|
||||||
MIGGAoGAebOmgtSCl+wCYZc86UGYeTLY8cjmW2P0FN8ToT/u2pECCoFdrlycX0OR
|
|
||||||
3wt0ZhpFXLVNeDnHwEE9veNUih7pCL2ZBFqoIoQkB1lZmXRiVtjGonz8BLm/qrFM
|
|
||||||
YHb0lme/Ol+s118mwKVxnn6bSAeI/OXKhLaVdYZWk+aEaxEDkVkCAQ8wDQYJKoZI
|
|
||||||
hvcNAQEEBQADgYEAAZMG14lZmZ8bahkaHaTV9dQf4p2FZiQTFwHP9ZyGsXPC+LT5
|
|
||||||
dG5iTaRmyjNIJdPWohZDl97kAci79aBndvuEvRKOjLHs3WRGBIwERnAcnY9Mz8u/
|
|
||||||
zIHK23PjYVxGGaZd669OJwD0CYyqH22HH9nFUGaoJdsv39ChW0NRdLE9+y8=
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test PCA (1024 bit)
|
|
||||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit)
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICJjCCAY8CAQAwDQYJKoZIhvcNAQEEBQAwXDELMAkGA1UEBhMCQVUxEzARBgNV
|
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRwwGgYD
|
|
||||||
VQQDExNUZXN0IFBDQSAoMTAyNCBiaXQpMB4XDTk3MDYwOTEzNTc0M1oXDTAxMDYw
|
|
||||||
OTEzNTc0M1owWzELMAkGA1UEBhMCQVUxEzARBgNVBAgTClF1ZWVuc2xhbmQxGjAY
|
|
||||||
BgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRswGQYDVQQDExJUZXN0IENBICgxMDI0
|
|
||||||
IGJpdCkwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAKO7o8t116VP6cgybTsZ
|
|
||||||
DCZhr95nYlZuya3aCi1IKoztqwWnjbmDFIriOqGFPrZQ+moMETC9D59iRW/dFXSv
|
|
||||||
1F65ka/XY2hLh9exCCo7XuUcDs53Qp3bI3AmMqHjgzE8oO3ajyJAzJkTTOUecQU2
|
|
||||||
mw/gI4tMM0LqWMQS7luTy4+xAgMBAAEwDQYJKoZIhvcNAQEEBQADgYEAM7achv3v
|
|
||||||
hLQJcv/65eGEpBXM40ZDVoFQFFJWaY5p883HTqLB1x4FdzsXHH0QKBTcKpWwqyu4
|
|
||||||
YDm3fb8oDugw72bCzfyZK/zVZPR/hVlqI/fvU109Qoc+7oPvIXWky71HfcK6ZBCA
|
|
||||||
q30KIqGM/uoM60INq97qjDmCJapagcNBGQs=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIICXQIBAAKBgQCju6PLddelT+nIMm07GQwmYa/eZ2JWbsmt2gotSCqM7asFp425
|
|
||||||
gxSK4jqhhT62UPpqDBEwvQ+fYkVv3RV0r9ReuZGv12NoS4fXsQgqO17lHA7Od0Kd
|
|
||||||
2yNwJjKh44MxPKDt2o8iQMyZE0zlHnEFNpsP4COLTDNC6ljEEu5bk8uPsQIDAQAB
|
|
||||||
AoGAVZmpFZsDZfr0l2S9tLLwpjRWNOlKATQkno6q2WesT0eGLQufTciY+c8ypfU6
|
|
||||||
hyio8r5iUl/VhhdjhAtKx1mRpiotftHo/eYf8rtsrnprOnWG0bWjLjtIoMbcxGn2
|
|
||||||
J3bN6LJmbJMjDs0eJ3KnTu646F3nDUw2oGAwmpzKXA1KAP0CQQDRvQhxk2D3Pehs
|
|
||||||
HvG665u2pB5ipYQngEFlZO7RHJZzJOZEWSLuuMqaF/7pTfA5jiBvWqCgJeCRRInL
|
|
||||||
21ru4dlPAkEAx9jj7BgKn5TYnMoBSSe0afjsV9oApVpN1Nacb1YDtCwy+scp3++s
|
|
||||||
nFxlv98wxIlSdpwMUn+AUWfjiWR7Tu/G/wJBAJ/KjwZIrFVxewP0x2ILYsTRYLzz
|
|
||||||
MS4PDsO7FB+I0i7DbBOifXS2oNSpd3I0CNMwrxFnUHzynpbOStVfN3ZL5w0CQQCa
|
|
||||||
pwFahxBRhkJKsxhjoFJBX9yl75JoY4Wvm5Tbo9ih6UJaRx3kqfkN14L2BKYcsZgb
|
|
||||||
KY9vmDOYy6iNfjDeWTfJAkBkfPUb8oTJ/nSP5zN6sqGxSY4krc4xLxpRmxoJ8HL2
|
|
||||||
XfhqXkTzbU13RX9JJ/NZ8vQN9Vm2NhxRGJocQkmcdVtJ
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
MIICYDCCAiACAgEoMAkGBSsOAwINBQAwfDELMAkGA1UEBhMCVVMxNjA0BgNVBAoT
|
|
||||||
LU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEZ
|
|
||||||
MBcGA1UECxMQVGVzdCBFbnZpcm9ubWVudDEaMBgGA1UECxMRRFNTLU5BU0EtUGls
|
|
||||||
b3QtQ0EwHhcNOTYwMjI2MTYzMjQ1WhcNOTcwMjI1MTYzMjQ1WjB8MQswCQYDVQQG
|
|
||||||
EwJVUzE2MDQGA1UEChMtTmF0aW9uYWwgQWVyb25hdXRpY3MgYW5kIFNwYWNlIEFk
|
|
||||||
bWluaXN0cmF0aW9uMRkwFwYDVQQLExBUZXN0IEVudmlyb25tZW50MRowGAYDVQQL
|
|
||||||
ExFEU1MtTkFTQS1QaWxvdC1DQTCB8jAJBgUrDgMCDAUAA4HkADCB4AJBAMA/ssKb
|
|
||||||
hPNUG7ZlASfVwEJU21O5OyF/iyBzgHI1O8eOhJGUYO8cc8wDMjR508Mr9cp6Uhl/
|
|
||||||
ZB7FV5GkLNEnRHYCQQDUEaSg45P2qrDwixTRhFhmWz5Nvc4lRFQ/42XPcchiJBLb
|
|
||||||
bn3QK74T2IxY1yY+kCNq8XrIqf5fJJzIH0J/xUP3AhUAsg2wsQHfDGYk/BOSulX3
|
|
||||||
fVd0geUCQQCzCFUQAh+ZkEmp5804cs6ZWBhrUAfnra8lJItYo9xPcXgdIfLfibcX
|
|
||||||
R71UsyO77MRD7B0+Ag2tq794IleCVcEEMAkGBSsOAwINBQADLwAwLAIUUayDfreR
|
|
||||||
Yh2WeU86/pHNdkUC1IgCFEfxe1f0oMpxJyrJ5XIxTi7vGdoK
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICGTCCAdgCAwCqTDAJBgUrDgMCDQUAMHwxCzAJBgNVBAYTAlVTMTYwNAYDVQQK
|
|
||||||
Ey1OYXRpb25hbCBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x
|
|
||||||
GTAXBgNVBAsTEFRlc3QgRW52aXJvbm1lbnQxGjAYBgNVBAsTEURTUy1OQVNBLVBp
|
|
||||||
bG90LUNBMB4XDTk2MDUxNDE3MDE0MVoXDTk3MDUxNDE3MDE0MVowMzELMAkGA1UE
|
|
||||||
BhMCQVUxDzANBgNVBAoTBk1pbmNvbTETMBEGA1UEAxMKRXJpYyBZb3VuZzCB8jAJ
|
|
||||||
BgUrDgMCDAUAA4HkADCB4AJBAKbfHz6vE6pXXMTpswtGUec2tvnfLJUsoxE9qs4+
|
|
||||||
ObZX7LmLvragNPUeiTJx7UOWZ5DfBj6bXLc8eYne0lP1g3ACQQDUEaSg45P2qrDw
|
|
||||||
ixTRhFhmWz5Nvc4lRFQ/42XPcchiJBLbbn3QK74T2IxY1yY+kCNq8XrIqf5fJJzI
|
|
||||||
H0J/xUP3AhUAsg2wsQHfDGYk/BOSulX3fVd0geUCQQCzCFUQAh+ZkEmp5804cs6Z
|
|
||||||
WBhrUAfnra8lJItYo9xPcXgdIfLfibcXR71UsyO77MRD7B0+Ag2tq794IleCVcEE
|
|
||||||
MAkGBSsOAwINBQADMAAwLQIUWsuuJRE3VT4ueWkWMAJMJaZjj1ECFQCYY0zX4bzM
|
|
||||||
LC7obsrHD8XAHG+ZRG==
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICTTCCAbagAwIBAgIBADANBgkqhkiG9w0BAQQFADBMMQswCQYDVQQGEwJHQjEM
|
|
||||||
MAoGA1UEChMDVUNMMRgwFgYDVQQLEw9JQ0UtVEVMIFByb2plY3QxFTATBgNVBAMT
|
|
||||||
DFRydXN0RmFjdG9yeTAeFw05NzA0MjIxNDM5MTRaFw05ODA0MjIxNDM5MTRaMEwx
|
|
||||||
CzAJBgNVBAYTAkdCMQwwCgYDVQQKEwNVQ0wxGDAWBgNVBAsTD0lDRS1URUwgUHJv
|
|
||||||
amVjdDEVMBMGA1UEAxMMVHJ1c3RGYWN0b3J5MIGcMAoGBFUIAQECAgQAA4GNADCB
|
|
||||||
iQKBgQCEieR8NcXkUW1f0G6aC6u0i8q/98JqS6RxK5YmHIGKCkuTWAUjzLfUa4dt
|
|
||||||
U9igGCjTuxaDqlzEim+t/02pmiBZT9HaX++35MjQPUWmsChcYU5WyzGErXi+rQaw
|
|
||||||
zlwS73zM8qiPj/97lXYycWhgL0VaiDSPxRXEUdWoaGruom4mNQIDAQABo0IwQDAd
|
|
||||||
BgNVHQ4EFgQUHal1LZr7oVg5z6lYzrhTgZRCmcUwDgYDVR0PAQH/BAQDAgH2MA8G
|
|
||||||
A1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQEEBQADgYEAfaggfl6FZoioecjv0dq8
|
|
||||||
/DXo/u11iMZvXn08gjX/zl2b4wtPbShOSY5FhkSm8GeySasz+/Nwb/uzfnIhokWi
|
|
||||||
lfPZHtlCWtXbIy/TN51eJyq04ceDCQDWvLC2enVg9KB+GJ34b5c5VaPRzq8MBxsA
|
|
||||||
S7ELuYGtmYgYm9NZOIr7yU0=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIB6jCCAZQCAgEtMA0GCSqGSIb3DQEBBAUAMIGAMQswCQYDVQQGEwJVUzE2MDQG
|
|
||||||
A1UEChMtTmF0aW9uYWwgQWVyb25hdXRpY3MgYW5kIFNwYWNlIEFkbWluaXN0cmF0
|
|
||||||
aW9uMRkwFwYDVQQLExBUZXN0IEVudmlyb25tZW50MR4wHAYDVQQLExVNRDUtUlNB
|
|
||||||
LU5BU0EtUGlsb3QtQ0EwHhcNOTYwNDMwMjIwNTAwWhcNOTcwNDMwMjIwNTAwWjCB
|
|
||||||
gDELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu
|
|
||||||
ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEZMBcGA1UECxMQVGVzdCBFbnZpcm9ubWVu
|
|
||||||
dDEeMBwGA1UECxMVTUQ1LVJTQS1OQVNBLVBpbG90LUNBMFkwCgYEVQgBAQICAgAD
|
|
||||||
SwAwSAJBALmmX5+GqAvcrWK13rfDrNX9UfeA7f+ijyBgeFQjYUoDpFqapw4nzQBL
|
|
||||||
bAXug8pKkRwa2Zh8YODhXsRWu2F/UckCAwEAATANBgkqhkiG9w0BAQQFAANBAH9a
|
|
||||||
OBA+QCsjxXgnSqHx04gcU8S49DVUb1f2XVoLnHlIb8RnX0k5O6mpHT5eti9bLkiW
|
|
||||||
GJNMJ4L0AJ/ac+SmHZc=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICajCCAdMCBDGA0QUwDQYJKoZIhvcNAQEEBQAwfTELMAkGA1UEBhMCQ2ExDzAN
|
|
||||||
BgNVBAcTBk5lcGVhbjEeMBwGA1UECxMVTm8gTGlhYmlsaXR5IEFjY2VwdGVkMR8w
|
|
||||||
HQYDVQQKExZGb3IgRGVtbyBQdXJwb3NlcyBPbmx5MRwwGgYDVQQDExNFbnRydXN0
|
|
||||||
IERlbW8gV2ViIENBMB4XDTk2MDQyNjEzMzUwMVoXDTA2MDQyNjEzMzUwMVowfTEL
|
|
||||||
MAkGA1UEBhMCQ2ExDzANBgNVBAcTBk5lcGVhbjEeMBwGA1UECxMVTm8gTGlhYmls
|
|
||||||
aXR5IEFjY2VwdGVkMR8wHQYDVQQKExZGb3IgRGVtbyBQdXJwb3NlcyBPbmx5MRww
|
|
||||||
GgYDVQQDExNFbnRydXN0IERlbW8gV2ViIENBMIGdMA0GCSqGSIb3DQEBAQUAA4GL
|
|
||||||
ADCBhwKBgQCaroS7O1DA0hm4IefNYU1cx/nqOmzEnk291d1XqznDeF4wEgakbkCc
|
|
||||||
zTKxK791yNpXG5RmngqH7cygDRTHZJ6mfCRn0wGC+AI00F2vYTGqPGRQL1N3lZT0
|
|
||||||
YDKFC0SQeMMjFIZ1aeQigroFQnHo0VB3zWIMpNkka8PY9lxHZAmWwQIBAzANBgkq
|
|
||||||
hkiG9w0BAQQFAAOBgQBAx0UMVA1s54lMQyXjMX5kj99FJN5itb8bK1Rk+cegPQPF
|
|
||||||
cWO9SEWyEjjBjIkjjzAwBkaEszFsNGxemxtXvwjIm1xEUMTVlPEWTs2qnDvAUA9W
|
|
||||||
YqhWbhH0toGT36236QAsqCZ76rbTRVSSX2BHyJwJMG2tCRv7kRJ//NIgxj3H4w==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test PCA (1024 bit)
|
|
||||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test PCA (1024 bit)
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICJzCCAZACAQAwDQYJKoZIhvcNAQEEBQAwXDELMAkGA1UEBhMCQVUxEzARBgNV
|
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRwwGgYD
|
|
||||||
VQQDExNUZXN0IFBDQSAoMTAyNCBiaXQpMB4XDTk3MDYwOTEzNTczN1oXDTAxMDYw
|
|
||||||
OTEzNTczN1owXDELMAkGA1UEBhMCQVUxEzARBgNVBAgTClF1ZWVuc2xhbmQxGjAY
|
|
||||||
BgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRwwGgYDVQQDExNUZXN0IFBDQSAoMTAy
|
|
||||||
NCBiaXQpMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCdoWk/3+WcMlfjIrkg
|
|
||||||
40ketmnQaEogQe1LLcuOJV6rKfUSAsPgwgsabJ/wn8TxA1yy3eKJbFl3OiUXMRsp
|
|
||||||
22Jp85PmemiDzyUIStwk72qhp1imbANZvlmlCFKiQrjUyuDfu4TABmn+kkt3vR1Y
|
|
||||||
BEOGt+IFye1UBVSATVdRJ2UVhwIDAQABMA0GCSqGSIb3DQEBBAUAA4GBABNA1u/S
|
|
||||||
Cg/LJZWb7GliiKJsvuhxlE4E5JxQF2zMub/CSNbF97//tYSyj96sxeFQxZXbcjm9
|
|
||||||
xt6mr/xNLA4szNQMJ4P+L7b5e/jC5DSqlwS+CUYJgaFs/SP+qJoCSu1bR3IM9XWO
|
|
||||||
cRBpDmcBbYLkSyB92WURvsZ1LtjEcn+cdQVI
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIICXAIBAAKBgQCdoWk/3+WcMlfjIrkg40ketmnQaEogQe1LLcuOJV6rKfUSAsPg
|
|
||||||
wgsabJ/wn8TxA1yy3eKJbFl3OiUXMRsp22Jp85PmemiDzyUIStwk72qhp1imbANZ
|
|
||||||
vlmlCFKiQrjUyuDfu4TABmn+kkt3vR1YBEOGt+IFye1UBVSATVdRJ2UVhwIDAQAB
|
|
||||||
AoGAba4fTtuap5l7/8ZsbE7Z1O32KJY4ZcOZukLOLUUhXxXduT+FTgGWujc0/rgc
|
|
||||||
z9qYCLlNZHOouMYTgtSfYvuMuLZ11VIt0GYH+nRioLShE59Yy+zCRyC+gPigS1kz
|
|
||||||
xvo14AsOIPYV14Tk/SsHyq6E0eTk7VzaIE197giiINUERPECQQDSKmtPTh/lRKw7
|
|
||||||
HSZSM0I1mFWn/1zqrAbontRQY5w98QWIOe5qmzYyFbPXYT3d9BzlsMyhgiRNoBbD
|
|
||||||
yvohSHXJAkEAwAHx6ezAZeWWzD5yXD36nyjpkVCw7Tk7TSmOceLJMWt1QcrCfqlS
|
|
||||||
xA5jjpQ6Z8suU5DdtWAryM2sAir1WisYzwJAd6Zcx56jvAQ3xcPXsE6scBTVFzrj
|
|
||||||
7FqZ6E+cclPzfLQ+QQsyOBE7bpI6e/FJppY26XGZXo3YGzV8IGXrt40oOQJALETG
|
|
||||||
h86EFXo3qGOFbmsDy4pdP5nBERCu8X1xUCSfintiD4c2DInxgS5oGclnJeMcjTvL
|
|
||||||
QjQoJCX3UJCi/OUO1QJBAKgcDHWjMvt+l1pjJBsSEZ0HX9AAIIVx0RQmbFGS+F2Q
|
|
||||||
hhu5l77WnnZOQ9vvhV5u7NPCUF9nhU3jh60qWWO8mkc=
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
subject=/C=US/O=RSA Data Security, Inc./OU=Commercial Certification Authority
|
|
||||||
issuer= /C=US/O=RSA Data Security, Inc./OU=Commercial Certification Authority
|
|
||||||
notBefore=941104185834Z
|
|
||||||
notAfter =991103185834Z
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICIzCCAZACBQJBAAAWMA0GCSqGSIb3DQEBAgUAMFwxCzAJBgNVBAYTAlVTMSAw
|
|
||||||
HgYDVQQKExdSU0EgRGF0YSBTZWN1cml0eSwgSW5jLjErMCkGA1UECxMiQ29tbWVy
|
|
||||||
Y2lhbCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NDExMDQxODU4MzRaFw05
|
|
||||||
OTExMDMxODU4MzRaMFwxCzAJBgNVBAYTAlVTMSAwHgYDVQQKExdSU0EgRGF0YSBT
|
|
||||||
ZWN1cml0eSwgSW5jLjErMCkGA1UECxMiQ29tbWVyY2lhbCBDZXJ0aWZpY2F0aW9u
|
|
||||||
IEF1dGhvcml0eTCBmzANBgkqhkiG9w0BAQEFAAOBiQAwgYUCfgCk+4Fie84QJ93o
|
|
||||||
975sbsZwmdu41QUDaSiCnHJ/lj+O7Kwpkj+KFPhCdr69XQO5kNTQvAayUTNfxMK/
|
|
||||||
touPmbZiImDd298ggrTKoi8tUO2UMt7gVY3UaOLgTNLNBRYulWZcYVI4HlGogqHE
|
|
||||||
7yXpCuaLK44xZtn42f29O2nZ6wIDAQABMA0GCSqGSIb3DQEBAgUAA34AdrW2EP4j
|
|
||||||
9/dZYkuwX5zBaLxJu7NJbyFHXSudVMQAKD+YufKKg5tgf+tQx6sFEC097TgCwaVI
|
|
||||||
0v5loMC86qYjFmZsGySp8+x5NRhPJsjjr1BKx6cxa9B8GJ1Qv6km+iYrRpwUqbtb
|
|
||||||
MJhCKLVLU7tDCZJAuqiqWqTGtotXTcU=
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
subject=/C=US/O=RSA Data Security, Inc./OU=Secure Server Certification Authority
|
|
||||||
issuer= /C=US/O=RSA Data Security, Inc./OU=Secure Server Certification Authority
|
|
||||||
notBefore=941109235417Z
|
|
||||||
notAfter =991231235417Z
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICKTCCAZYCBQJBAAABMA0GCSqGSIb3DQEBAgUAMF8xCzAJBgNVBAYTAlVTMSAw
|
|
||||||
HgYDVQQKExdSU0EgRGF0YSBTZWN1cml0eSwgSW5jLjEuMCwGA1UECxMlU2VjdXJl
|
|
||||||
IFNlcnZlciBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NDExMDkyMzU0MTda
|
|
||||||
Fw05OTEyMzEyMzU0MTdaMF8xCzAJBgNVBAYTAlVTMSAwHgYDVQQKExdSU0EgRGF0
|
|
||||||
YSBTZWN1cml0eSwgSW5jLjEuMCwGA1UECxMlU2VjdXJlIFNlcnZlciBDZXJ0aWZp
|
|
||||||
Y2F0aW9uIEF1dGhvcml0eTCBmzANBgkqhkiG9w0BAQEFAAOBiQAwgYUCfgCSznrB
|
|
||||||
roM+WqqJg1esJQF2DK2ujiw3zus1eGRUA+WEQFHJv48I4oqCCNIWhjdV6bEhAq12
|
|
||||||
aIGaBaJLyUslZiJWbIgHj/eBWW2EB2VwE3F2Ppt3TONQiVaYSLkdpykaEy5KEVmc
|
|
||||||
HhXVSVQsczppgrGXOZxtcGdI5d0t1sgeewIDAQABMA0GCSqGSIb3DQEBAgUAA34A
|
|
||||||
iNHReSHO4ovo+MF9NFM/YYPZtgs4F7boviGNjwC4i1N+RGceIr2XJ+CchcxK9oU7
|
|
||||||
suK+ktPlDemvXA4MRpX/oRxePug2WHpzpgr4IhFrwwk4fia7c+8AvQKk8xQNMD9h
|
|
||||||
cHsg/jKjn7P0Z1LctO6EjJY2IN6BCINxIYoPnqk=
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
subject=/C=ZA/SP=Western Cape/L=Cape Town/O=Thawte Consulting cc
|
|
||||||
/OU=Certification Services Division/CN=Thawte Server CA
|
|
||||||
/Email=server-certs@thawte.com
|
|
||||||
issuer= /C=ZA/SP=Western Cape/L=Cape Town/O=Thawte Consulting cc
|
|
||||||
/OU=Certification Services Division/CN=Thawte Server CA
|
|
||||||
/Email=server-certs@thawte.com
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIC+TCCAmICAQAwDQYJKoZIhvcNAQEEBQAwgcQxCzAJBgNVBAYTAlpBMRUwEwYD
|
|
||||||
VQQIEwxXZXN0ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEdMBsGA1UEChMU
|
|
||||||
VGhhd3RlIENvbnN1bHRpbmcgY2MxKDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2Vy
|
|
||||||
dmljZXMgRGl2aXNpb24xGTAXBgNVBAMTEFRoYXd0ZSBTZXJ2ZXIgQ0ExJjAkBgkq
|
|
||||||
hkiG9w0BCQEWF3NlcnZlci1jZXJ0c0B0aGF3dGUuY29tMB4XDTk2MDcyNzE4MDc1
|
|
||||||
N1oXDTk4MDcyNzE4MDc1N1owgcQxCzAJBgNVBAYTAlpBMRUwEwYDVQQIEwxXZXN0
|
|
||||||
ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEdMBsGA1UEChMUVGhhd3RlIENv
|
|
||||||
bnN1bHRpbmcgY2MxKDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2VydmljZXMgRGl2
|
|
||||||
aXNpb24xGTAXBgNVBAMTEFRoYXd0ZSBTZXJ2ZXIgQ0ExJjAkBgkqhkiG9w0BCQEW
|
|
||||||
F3NlcnZlci1jZXJ0c0B0aGF3dGUuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCB
|
|
||||||
iQKBgQDTpFBuyP9Wa+bPXbbqDGh1R6KqwtqEJfyo9EdR2oW1IHSUhh4PdcnpCGH1
|
|
||||||
Bm0wbhUZAulSwGLbTZme4moMRDjN/r7jZAlwxf6xaym2L0nIO9QnBCUQly/nkG3A
|
|
||||||
KEKZ10xD3sP1IW1Un13DWOHA5NlbsLjctHvfNjrCtWYiEtaHDQIDAQABMA0GCSqG
|
|
||||||
SIb3DQEBBAUAA4GBAIsvn7ifX3RUIrvYXtpI4DOfARkTogwm6o7OwVdl93yFhDcX
|
|
||||||
7h5t0XZ11MUAMziKdde3rmTvzUYIUCYoY5b032IwGMTvdiclK+STN6NP2m5nvFAM
|
|
||||||
qJT5gC5O+j/jBuZRQ4i0AMYQr5F4lT8oBJnhgafw6PL8aDY2vMHGSPl9+7uf
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDDTCCAnYCAQAwDQYJKoZIhvcNAQEEBQAwgc4xCzAJBgNVBAYTAlpBMRUwEwYD
|
|
||||||
VQQIEwxXZXN0ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEdMBsGA1UEChMU
|
|
||||||
VGhhd3RlIENvbnN1bHRpbmcgY2MxKDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2Vy
|
|
||||||
dmljZXMgRGl2aXNpb24xITAfBgNVBAMTGFRoYXd0ZSBQcmVtaXVtIFNlcnZlciBD
|
|
||||||
QTEoMCYGCSqGSIb3DQEJARYZcHJlbWl1bS1zZXJ2ZXJAdGhhd3RlLmNvbTAeFw05
|
|
||||||
NjA3MjcxODA3MTRaFw05ODA3MjcxODA3MTRaMIHOMQswCQYDVQQGEwJaQTEVMBMG
|
|
||||||
A1UECBMMV2VzdGVybiBDYXBlMRIwEAYDVQQHEwlDYXBlIFRvd24xHTAbBgNVBAoT
|
|
||||||
FFRoYXd0ZSBDb25zdWx0aW5nIGNjMSgwJgYDVQQLEx9DZXJ0aWZpY2F0aW9uIFNl
|
|
||||||
cnZpY2VzIERpdmlzaW9uMSEwHwYDVQQDExhUaGF3dGUgUHJlbWl1bSBTZXJ2ZXIg
|
|
||||||
Q0ExKDAmBgkqhkiG9w0BCQEWGXByZW1pdW0tc2VydmVyQHRoYXd0ZS5jb20wgZ8w
|
|
||||||
DQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBANI2NmqL18JbntqBQWKPOO5JBFXW0O8c
|
|
||||||
G5UWR+8YSDU6UvQragaPOy/qVuOvho2eF/eetGV1Ak3vywmiIVHYm9Bn0LoNkgYU
|
|
||||||
c9STy5cqAJxcTgy8+hVS/PJEbtoRSm4Iny8t4/mqOoZztkZTWMiJBb2DEbhzP6oH
|
|
||||||
jfRCTedAnRw3AgMBAAEwDQYJKoZIhvcNAQEEBQADgYEAutFIgTRZVYerIZfL9lvR
|
|
||||||
w9Eifvvo5KTZ3h+Bj+VzNnyw4Qc/IyXkPOu6SIiH9LQ3sCmWBdxpe+qr4l77rLj2
|
|
||||||
GYuMtESFfn1XVALzkYgC7JcPuTOjMfIiMByt+uFf8AV8x0IW/Qkuv+hEQcyM9vxK
|
|
||||||
3VZdLbCVIhNoEsysrxCpxcI=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
Tims test GCI CA
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIB8DCCAZoCAQAwDQYJKoZIhvcNAQEEBQAwgYIxCzAJBgNVBAYTAkFVMRMwEQYD
|
|
||||||
VQQIEwpRdWVlbnNsYW5kMREwDwYDVQQHEwhCcmlzYmFuZTEaMBgGA1UEChMRQ3J5
|
|
||||||
cHRTb2Z0IFB0eSBMdGQxFDASBgNVBAsTC2RldmVsb3BtZW50MRkwFwYDVQQDExBD
|
|
||||||
cnlwdFNvZnQgRGV2IENBMB4XDTk3MDMyMjEzMzQwNFoXDTk4MDMyMjEzMzQwNFow
|
|
||||||
gYIxCzAJBgNVBAYTAkFVMRMwEQYDVQQIEwpRdWVlbnNsYW5kMREwDwYDVQQHEwhC
|
|
||||||
cmlzYmFuZTEaMBgGA1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxFDASBgNVBAsTC2Rl
|
|
||||||
dmVsb3BtZW50MRkwFwYDVQQDExBDcnlwdFNvZnQgRGV2IENBMFwwDQYJKoZIhvcN
|
|
||||||
AQEBBQADSwAwSAJBAOAOAqogG5QwAmLhzyO4CoRnx/wVy4NZP4dxJy83O1EnL0rw
|
|
||||||
OdsamJKvPOLHgSXo3gDu9uVyvCf/QJmZAmC5ml8CAwEAATANBgkqhkiG9w0BAQQF
|
|
||||||
AANBADRRS/GVdd7rAqRW6SdmgLJduOU2yq3avBu99kRqbp9A/dLu6r6jU+eP4oOA
|
|
||||||
TfdbFZtAAD2Hx9jUtY3tfdrJOb8=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICVjCCAgACAQAwDQYJKoZIhvcNAQEEBQAwgbUxCzAJBgNVBAYTAkFVMRMwEQYD
|
|
||||||
VQQIEwpRdWVlbnNsYW5kMREwDwYDVQQHEwhCcmlzYmFuZTEaMBgGA1UEChMRQ3J5
|
|
||||||
cHRTb2Z0IFB0eSBMdGQxLDAqBgNVBAsTI1dPUlRITEVTUyBDRVJUSUZJQ0FUSU9O
|
|
||||||
IEFVVEhPUklUSUVTMTQwMgYDVQQDEytaRVJPIFZBTFVFIENBIC0gREVNT05TVFJB
|
|
||||||
VElPTiBQVVJQT1NFUyBPTkxZMB4XDTk3MDQwMzEzMjI1NFoXDTk4MDQwMzEzMjI1
|
|
||||||
NFowgbUxCzAJBgNVBAYTAkFVMRMwEQYDVQQIEwpRdWVlbnNsYW5kMREwDwYDVQQH
|
|
||||||
EwhCcmlzYmFuZTEaMBgGA1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxLDAqBgNVBAsT
|
|
||||||
I1dPUlRITEVTUyBDRVJUSUZJQ0FUSU9OIEFVVEhPUklUSUVTMTQwMgYDVQQDEyta
|
|
||||||
RVJPIFZBTFVFIENBIC0gREVNT05TVFJBVElPTiBQVVJQT1NFUyBPTkxZMFwwDQYJ
|
|
||||||
KoZIhvcNAQEBBQADSwAwSAJBAOZ7T7yqP/tyspcko3yPY1y0Cm2EmwNvzW4QgVXR
|
|
||||||
Fjs3HmJ4xtSpXdo6mwcGezL3Abt/aQXaxv9PU8xt+Jr0OFUCAwEAATANBgkqhkiG
|
|
||||||
9w0BAQQFAANBAOQpYmGgyCqCy1OljgJhCqQOu627oVlHzK1L+t9vBaMfn40AVUR4
|
|
||||||
WzQVWO31KTgi5vTK1U+3h46fgUWqQ0h+6rU=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIAwgKADAgECAgEAMA0GCSqGSIb3DQEBBAUAMGIxETAPBgNVBAcTCEludGVybmV0
|
|
||||||
MRcwFQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE0MDIGA1UECxMrVmVyaVNpZ24gQ2xh
|
|
||||||
c3MgMSBDQSAtIEluZGl2aWR1YWwgU3Vic2NyaWJlcjAeFw05NjA0MDgxMDIwMjda
|
|
||||||
Fw05NzA0MDgxMDIwMjdaMGIxETAPBgNVBAcTCEludGVybmV0MRcwFQYDVQQKEw5W
|
|
||||||
ZXJpU2lnbiwgSW5jLjE0MDIGA1UECxMrVmVyaVNpZ24gQ2xhc3MgMSBDQSAtIElu
|
|
||||||
ZGl2aWR1YWwgU3Vic2NyaWJlcjCAMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC2
|
|
||||||
FKbPTdAFDdjKI9BvqrQpkmOOLPhvltcunXZLEbE2jVfJw/0cxrr+Hgi6M8qV6r7j
|
|
||||||
W80GqLd5HUQq7XPysVKDaBBwZJHXPmv5912dFEObbpdFmIFH0S3L3bty10w/cari
|
|
||||||
QPJUObwW7s987LrbP2wqsxaxhhKdrpM01bjV0Pc+qQIDAQABAAAAADANBgkqhkiG
|
|
||||||
9w0BAQQFAAOBgQA+1nJryNt8VBRjRr07ArDAV/3jAH7GjDc9jsrxZS68ost9v06C
|
|
||||||
TvTNKGL+LISNmFLXl+JXhgGB0JZ9fvyYzNgHQ46HBUng1H6voalfJgS2KdEo50wW
|
|
||||||
8EFZYMDkT1k4uynwJqkVN2QJK/2q4/A/VCov5h6SlM8Affg2W+1TLqvqkwAA
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
subject=/L=Internet/O=VeriSign, Inc./OU=VeriSign Class 2 CA - Individual Subscriber
|
|
||||||
issuer= /L=Internet/O=VeriSign, Inc./OU=VeriSign Class 2 CA - Individual Subscriber
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIEkzCCA/ygAwIBAgIRANDTUpSRL3nTFeMrMayFSPAwDQYJKoZIhvcNAQECBQAw
|
|
||||||
YjERMA8GA1UEBxMISW50ZXJuZXQxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTQw
|
|
||||||
MgYDVQQLEytWZXJpU2lnbiBDbGFzcyAyIENBIC0gSW5kaXZpZHVhbCBTdWJzY3Jp
|
|
||||||
YmVyMB4XDTk2MDYwNDAwMDAwMFoXDTk4MDYwNDIzNTk1OVowYjERMA8GA1UEBxMI
|
|
||||||
SW50ZXJuZXQxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTQwMgYDVQQLEytWZXJp
|
|
||||||
U2lnbiBDbGFzcyAyIENBIC0gSW5kaXZpZHVhbCBTdWJzY3JpYmVyMIGfMA0GCSqG
|
|
||||||
SIb3DQEBAQUAA4GNADCBiQKBgQC6A+2czKGRcYMfm8gdnk+0de99TDDzsqo0v5nb
|
|
||||||
RsbUmMcdRQ7nsMbRWe0SAb/9QoLTZ/cJ0iOBqdrkz7UpqqKarVoTSdlSMVM92tWp
|
|
||||||
3bJncZHQD1t4xd6lQVdI1/T6R+5J0T1ukOdsI9Jmf+F28S6g3R3L1SFwiHKeZKZv
|
|
||||||
z+793wIDAQABo4ICRzCCAkMwggIpBgNVHQMBAf8EggIdMIICGTCCAhUwggIRBgtg
|
|
||||||
hkgBhvhFAQcBATCCAgAWggGrVGhpcyBjZXJ0aWZpY2F0ZSBpbmNvcnBvcmF0ZXMg
|
|
||||||
YnkgcmVmZXJlbmNlLCBhbmQgaXRzIHVzZSBpcyBzdHJpY3RseSBzdWJqZWN0IHRv
|
|
||||||
LCB0aGUgVmVyaVNpZ24gQ2VydGlmaWNhdGlvbiBQcmFjdGljZSBTdGF0ZW1lbnQg
|
|
||||||
KENQUyksIGF2YWlsYWJsZSBhdDogaHR0cHM6Ly93d3cudmVyaXNpZ24uY29tL0NQ
|
|
||||||
Uy0xLjA7IGJ5IEUtbWFpbCBhdCBDUFMtcmVxdWVzdHNAdmVyaXNpZ24uY29tOyBv
|
|
||||||
ciBieSBtYWlsIGF0IFZlcmlTaWduLCBJbmMuLCAyNTkzIENvYXN0IEF2ZS4sIE1v
|
|
||||||
dW50YWluIFZpZXcsIENBIDk0MDQzIFVTQSBUZWwuICsxICg0MTUpIDk2MS04ODMw
|
|
||||||
IENvcHlyaWdodCAoYykgMTk5NiBWZXJpU2lnbiwgSW5jLiAgQWxsIFJpZ2h0cyBS
|
|
||||||
ZXNlcnZlZC4gQ0VSVEFJTiBXQVJSQU5USUVTIERJU0NMQUlNRUQgYW5kIExJQUJJ
|
|
||||||
TElUWSBMSU1JVEVELqAOBgxghkgBhvhFAQcBAQGhDgYMYIZIAYb4RQEHAQECMC8w
|
|
||||||
LRYraHR0cHM6Ly93d3cudmVyaXNpZ24uY29tL3JlcG9zaXRvcnkvQ1BTLTEuMDAU
|
|
||||||
BglghkgBhvhCAQEBAf8EBAMCAgQwDQYJKoZIhvcNAQECBQADgYEApRJRkNBqLLgs
|
|
||||||
53IR/d18ODdLOWMTZ+QOOxBrq460iBEdUwgF8vmPRX1ku7UiDeNzaLlurE6eFqHq
|
|
||||||
2zPyK5j60zfTLVJMWKcQWwTJLjHtXrW8pxhNtFc6Fdvy5ZkHnC/9NIl7/t4U6WqB
|
|
||||||
p4y+p7SdMIkEwIZfds0VbnQyX5MRUJY=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
subject=/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
|
||||||
issuer= /C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICMTCCAZoCBQKhAAABMA0GCSqGSIb3DQEBAgUAMF8xCzAJBgNVBAYTAlVTMRcw
|
|
||||||
FQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMg
|
|
||||||
UHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NjAxMjkwMDAwMDBa
|
|
||||||
Fw05OTEyMzEyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2ln
|
|
||||||
biwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZp
|
|
||||||
Y2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAyVxZ
|
|
||||||
nvIbigEUtBDfBEDb41evakVAj4QMC9Ez2dkRz+4CWB8l9yqoRAWq7AMfeH+ek7ma
|
|
||||||
AKojfdashaJjRcdyJ8z0TMZ1cdI5709C8HXfCpDGjiBvmA/4rCNfcCk2pMmG57Ga
|
|
||||||
IMtTpYXnPb59mv4kRTPcdhXtD6JxZExlLoFoRacCAwEAATANBgkqhkiG9w0BAQIF
|
|
||||||
AAOBgQB1Zmw+0c2B27X4LzZRtvdCvM1Cr9wO+hVs+GeTVzrrtpLotgHKjLeOQ7RJ
|
|
||||||
Zfk+7r11Ri7J/CVdqMcvi5uPaM+0nJcYwE3vH9mvgrPmZLiEXIqaB1JDYft0nls6
|
|
||||||
NvxMsvwaPxUupVs8G5DsiCnkWRb5zget7Ond2tIxik/W2O8XjQ==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
subject=/C=US/O=VeriSign, Inc./OU=Class 4 Public Primary Certification Authority
|
|
||||||
issuer= /C=US/O=VeriSign, Inc./OU=Class 4 Public Primary Certification Authority
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICMTCCAZoCBQKmAAABMA0GCSqGSIb3DQEBAgUAMF8xCzAJBgNVBAYTAlVTMRcw
|
|
||||||
FQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgNCBQdWJsaWMg
|
|
||||||
UHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NjAxMjkwMDAwMDBa
|
|
||||||
Fw05OTEyMzEyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2ln
|
|
||||||
biwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgNCBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZp
|
|
||||||
Y2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEA0LJ1
|
|
||||||
9njQrlpQ9OlQqZ+M1++RlHDo0iSQdomF1t+s5gEXMoDwnZNHvJplnR+Xrr/phnVj
|
|
||||||
IIm9gFidBAydqMEk6QvlMXi9/C0MN2qeeIDpRnX57aP7E3vIwUzSo+/1PLBij0pd
|
|
||||||
O92VZ48TucE81qcmm+zDO3rZTbxtm+gVAePwR6kCAwEAATANBgkqhkiG9w0BAQIF
|
|
||||||
AAOBgQBT3dPwnCR+QKri/AAa19oM/DJhuBUNlvP6Vxt/M3yv6ZiaYch6s7f/sdyZ
|
|
||||||
g9ysEvxwyR84Qu1E9oAuW2szaayc01znX1oYx7EteQSWQZGZQbE8DbqEOcY7l/Am
|
|
||||||
yY7uvcxClf8exwI/VAx49byqYHwCaejcrOICdmHEPgPq0ook0Q==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|||||||
420
apps/server2.pem
420
apps/server2.pem
@@ -1,376 +1,52 @@
|
|||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit)
|
subject= C = UK, O = OpenSSL Group, OU = FOR TESTING PURPOSES ONLY, CN = Test Server Cert #2
|
||||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Server test cert (1024 bit)
|
issuer= C = UK, O = OpenSSL Group, OU = FOR TESTING PURPOSES ONLY, CN = OpenSSL Test Intermediate CA
|
||||||
-----BEGIN CERTIFICATE-----
|
-----BEGIN CERTIFICATE-----
|
||||||
MIICLjCCAZcCAQEwDQYJKoZIhvcNAQEEBQAwWzELMAkGA1UEBhMCQVUxEzARBgNV
|
MIID6jCCAtKgAwIBAgIJALnu1NlVpZ60MA0GCSqGSIb3DQEBBQUAMHAxCzAJBgNV
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRswGQYD
|
BAYTAlVLMRYwFAYDVQQKDA1PcGVuU1NMIEdyb3VwMSIwIAYDVQQLDBlGT1IgVEVT
|
||||||
VQQDExJUZXN0IENBICgxMDI0IGJpdCkwHhcNOTcwNjA5MTM1NzU0WhcNOTgwNjA5
|
VElORyBQVVJQT1NFUyBPTkxZMSUwIwYDVQQDDBxPcGVuU1NMIFRlc3QgSW50ZXJt
|
||||||
MTM1NzU0WjBkMQswCQYDVQQGEwJBVTETMBEGA1UECBMKUXVlZW5zbGFuZDEaMBgG
|
ZWRpYXRlIENBMB4XDTExMTIwODE0MDE0OFoXDTIxMTAxNjE0MDE0OFowZzELMAkG
|
||||||
A1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxJDAiBgNVBAMTG1NlcnZlciB0ZXN0IGNl
|
A1UEBhMCVUsxFjAUBgNVBAoMDU9wZW5TU0wgR3JvdXAxIjAgBgNVBAsMGUZPUiBU
|
||||||
cnQgKDEwMjQgYml0KTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAsxH1PBPm
|
RVNUSU5HIFBVUlBPU0VTIE9OTFkxHDAaBgNVBAMME1Rlc3QgU2VydmVyIENlcnQg
|
||||||
RkxrR11eV4bzNi4N9n11CI8nV29+ARlT1+qDe/mjVUvXlmsr1v/vf71G9GgqopSa
|
IzIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDrdi7j9yctG+L4EjBy
|
||||||
6RXrICLVdk/FYYYzhPvl1M+OrjaXDFO8BzBAF1Lnz6c7aRZvGRJNrRSr2nZEkqDf
|
gjPmEqZzOJEQba26MoQGzglU7e5Xf59Rb/hgVQuKAoiZe7/R8rK4zJ4W7iXdXw0L
|
||||||
JW9dY7r2VZEpD5QeuaRYUnuECkqeieB65GMCAwEAATANBgkqhkiG9w0BAQQFAAOB
|
qBpyG8B5aGKeI32w+A9TcBApoXXL2CrYQEQjZwUIpLlYBIi2NkJj3nVkq5dgl1gO
|
||||||
gQCWsOta6C0wiVzXz8wPmJKyTrurMlgUss2iSuW9366iwofZddsNg7FXniMzkIf6
|
ALiQ+W8jg3kzg5Ec9rimp9r93N8wsSL3awsafurmYCvOf7leHaMP1WJ/zDRGUNHG
|
||||||
dp7jnmWZwKZ9cXsNUS2o4OL07qOk2HOywC0YsNZQsOBu1CBTYYkIefDiKFL1zQHh
|
/WtDjXc8ZUG1+6EXU9Jc2Fs+2Omf7fcN0l00AK/wPg8OaNS0rKyGq9JdIT9FRGV1
|
||||||
8lwwNd4NP+OE3NzUNkCfh4DnFfg9WHkXUlD5UpxNRJ4gJA==
|
bXe/rx58FaE5CItdwCSYhJvF/O95LWQoxJXye5bCFLmvDTEyVq9FMSCptfsmbXjE
|
||||||
|
ZGsXAgMBAAGjgY8wgYwwDAYDVR0TAQH/BAIwADAOBgNVHQ8BAf8EBAMCBeAwLAYJ
|
||||||
|
YIZIAYb4QgENBB8WHU9wZW5TU0wgR2VuZXJhdGVkIENlcnRpZmljYXRlMB0GA1Ud
|
||||||
|
DgQWBBR52UaWWTKzZGDH/X4mWNcuqeQVazAfBgNVHSMEGDAWgBQ2w2yI55X+sL3s
|
||||||
|
zj49hqshgYfa2jANBgkqhkiG9w0BAQUFAAOCAQEANBW+XYLlHBqVY/31ie+3gRlS
|
||||||
|
LPfy4SIqn0t3RJjagT29MXprblBO2cbMO8VGjkQdKGpmMXjxbht2arOOUXRHX4n/
|
||||||
|
XTyn/QHEf0bcwIITMReO3DZUPAEw8hSjn9xEOM0IRVOCP+mH5fi74QzzQaZVCyYg
|
||||||
|
5VtLKdww/+sc0nCbKl2KWgDluriH0nfVx95qgW3mg9dhXRr0zmf1w2zkBHYpARYL
|
||||||
|
Dew6Z8EE4tS3HJu8/qM6meWzNtrfonQ3eiiMxjZBxzV46jchBwa2z9XYhP6AmpPb
|
||||||
|
oeTSzcQNbWsxaGYzWo46oLDUZmJOwSBawbS31bZNMCoPIY6ukoesCzFSsUKZww==
|
||||||
-----END CERTIFICATE-----
|
-----END CERTIFICATE-----
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
-----BEGIN RSA PRIVATE KEY-----
|
||||||
MIICXgIBAAKBgQCzEfU8E+ZGTGtHXV5XhvM2Lg32fXUIjydXb34BGVPX6oN7+aNV
|
MIIEowIBAAKCAQEA63Yu4/cnLRvi+BIwcoIz5hKmcziREG2tujKEBs4JVO3uV3+f
|
||||||
S9eWayvW/+9/vUb0aCqilJrpFesgItV2T8VhhjOE++XUz46uNpcMU7wHMEAXUufP
|
UW/4YFULigKImXu/0fKyuMyeFu4l3V8NC6gachvAeWhiniN9sPgPU3AQKaF1y9gq
|
||||||
pztpFm8ZEk2tFKvadkSSoN8lb11juvZVkSkPlB65pFhSe4QKSp6J4HrkYwIDAQAB
|
2EBEI2cFCKS5WASItjZCY951ZKuXYJdYDgC4kPlvI4N5M4ORHPa4pqfa/dzfMLEi
|
||||||
AoGBAKy8jvb0Lzby8q11yNLf7+78wCVdYi7ugMHcYA1JVFK8+zb1WfSm44FLQo/0
|
92sLGn7q5mArzn+5Xh2jD9Vif8w0RlDRxv1rQ413PGVBtfuhF1PSXNhbPtjpn+33
|
||||||
dSChAjgz36TTexeLODPYxleJndjVcOMVzsLJjSM8dLpXsTS4FCeMbhw2s2u+xqKY
|
DdJdNACv8D4PDmjUtKyshqvSXSE/RURldW13v68efBWhOQiLXcAkmISbxfzveS1k
|
||||||
bbPWfk+HOTyJjfnkcC5Nbg44eOmruq0gSmBeUXVM5UntlTnxAkEA7TGCA3h7kx5E
|
KMSV8nuWwhS5rw0xMlavRTEgqbX7Jm14xGRrFwIDAQABAoIBAHLsTPihIfLnYIE5
|
||||||
Bl4zl2pc3gPAGt+dyfk5Po9mGJUUXhF5p2zueGmYWW74TmOWB1kzt4QRdYMzFePq
|
x4GsQQ5zXeBw5ITDM37ktwHnQDC+rIzyUl1aLD1AZRBoKinXd4lOTqLZ4/NHKx4A
|
||||||
zfDNXEa1CwJBAMFErdY0xp0UJ13WwBbUTk8rujqQdHtjw0klhpbuKkjxu2hN0wwM
|
DYr58mZtWyUmqLOMmQVuHXTZBlp7XtYuXMMNovQwjQlp9LicBeoBU6gQ5PVMtubD
|
||||||
6p0D9qxF7JHaghqVRI0fAW/EE0OzdHMR9QkCQQDNR26dMFXKsoPu+vItljj/UEGf
|
F4xGF89Sn0cTHW3iMkqTtQ5KcR1j57OcJO0FEb1vPvk2MXI5ZyAatUYE7YacbEzd
|
||||||
QG7gERiQ4yxaFBPHgdpGo0kT31eh9x9hQGDkxTe0GNG/YSgCRvm8+C3TMcKXAkBD
|
rg02uIwx3FqNSkuSI79uz4hMdV5TPtuhxx9nTwj9aLUhXFeZ0mn2PVgVzEnnMoJb
|
||||||
dhGn36wkUFCddMSAM4NSJ1VN8/Z0y5HzCmI8dM3VwGtGMUQlxKxwOl30LEQzdS5M
|
+znlsZDgzDlJqdaD744YGWh8Z3OEssB35KfzFcdOeO6yH8lmv2Zfznk7pNPT7LTb
|
||||||
0SWojNYXiT2gOBfBwtbhAkEAhafl5QEOIgUz+XazS/IlZ8goNKdDVfYgK3mHHjvv
|
Lae9VgkCgYEA92p1qnAB3NtJtNcaW53i0S5WJgS1hxWKvUDx3lTB9s8X9fHpqL1a
|
||||||
nY5G+AuGebdNkXJr4KSWxDcN+C2i47zuj4QXA16MAOandA==
|
E94fDfWzp/hax6FefUKIvBOukPLQ6bYjTMiFoOHzVirghAIuIUoMI5VtLhwD1hKs
|
||||||
|
Lr7l/dptMgKb1nZHyXoKHRBthsy3K4+udsPi8TzMvYElgEqyQIe/Rk0CgYEA86GL
|
||||||
|
8HC6zLszzKERDPBxrboRmoFvVUCTQDhsfj1M8aR3nQ8V5LkdIJc7Wqm/Ggfk9QRf
|
||||||
|
rJ8M2WUMlU5CNnCn/KCrKzCNZIReze3fV+HnKdbcXGLvgbHPrhnz8yYehUFG+RGq
|
||||||
|
bVyDWRU94T38izy2s5qMYrMJWZEYyXncSPbfcPMCgYAtaXfxcZ+V5xYPQFARMtiX
|
||||||
|
5nZfggvDoJuXgx0h3tK/N2HBfcaSdzbaYLG4gTmZggc/jwnl2dl5E++9oSPhUdIG
|
||||||
|
3ONSFUbxsOsGr9PBvnKd8WZZyUCXAVRjPBzAzF+whzQNWCZy/5htnz9LN7YDI9s0
|
||||||
|
5113Q96cheDZPFydZY0hHQKBgQDVbEhNukM5xCiNcu+f2SaMnLp9EjQ4h5g3IvaP
|
||||||
|
5B16daw/Dw8LzcohWboqIxeAsze0GD/D1ZUJAEd0qBjC3g+a9BjefervCjKOzXng
|
||||||
|
38mEUm+6EwVjJSQcjSmycEs+Sr/kwr/8i5WYvU32+jk4tFgMoC+o6tQe/Uesf68k
|
||||||
|
z/dPVwKBgGbF7Vv1/3SmhlOy+zYyvJ0CrWtKxH9QP6tLIEgEpd8x7YTSuCH94yok
|
||||||
|
kToMXYA3sWNPt22GbRDZ+rcp4c7HkDx6I6vpdP9aQEwJTp0EPy0sgWr2XwYmreIQ
|
||||||
|
NFmkk8Itn9EY2R9VBaP7GLv5kvwxDdLAnmwGmzVtbmaVdxCaBwUk
|
||||||
-----END RSA PRIVATE KEY-----
|
-----END RSA PRIVATE KEY-----
|
||||||
subject=/C=US/O=AT&T Bell Laboratories/OU=Prototype Research CA
|
|
||||||
issuer= /C=US/O=AT&T Bell Laboratories/OU=Prototype Research CA
|
|
||||||
notBefore=950413210656Z
|
|
||||||
notAfter =970412210656Z
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICCDCCAXECAQAwDQYJKoZIhvcNAQEEBQAwTjELMAkGA1UEBhMCVVMxHzAdBgNV
|
|
||||||
BAoUFkFUJlQgQmVsbCBMYWJvcmF0b3JpZXMxHjAcBgNVBAsUFVByb3RvdHlwZSBS
|
|
||||||
ZXNlYXJjaCBDQTAeFw05NTA0MTMyMTA2NTZaFw05NzA0MTIyMTA2NTZaME4xCzAJ
|
|
||||||
BgNVBAYTAlVTMR8wHQYDVQQKFBZBVCZUIEJlbGwgTGFib3JhdG9yaWVzMR4wHAYD
|
|
||||||
VQQLFBVQcm90b3R5cGUgUmVzZWFyY2ggQ0EwgZwwDQYJKoZIhvcNAQEBBQADgYoA
|
|
||||||
MIGGAoGAebOmgtSCl+wCYZc86UGYeTLY8cjmW2P0FN8ToT/u2pECCoFdrlycX0OR
|
|
||||||
3wt0ZhpFXLVNeDnHwEE9veNUih7pCL2ZBFqoIoQkB1lZmXRiVtjGonz8BLm/qrFM
|
|
||||||
YHb0lme/Ol+s118mwKVxnn6bSAeI/OXKhLaVdYZWk+aEaxEDkVkCAQ8wDQYJKoZI
|
|
||||||
hvcNAQEEBQADgYEAAZMG14lZmZ8bahkaHaTV9dQf4p2FZiQTFwHP9ZyGsXPC+LT5
|
|
||||||
dG5iTaRmyjNIJdPWohZDl97kAci79aBndvuEvRKOjLHs3WRGBIwERnAcnY9Mz8u/
|
|
||||||
zIHK23PjYVxGGaZd669OJwD0CYyqH22HH9nFUGaoJdsv39ChW0NRdLE9+y8=
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test PCA (1024 bit)
|
|
||||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test CA (1024 bit)
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICJjCCAY8CAQAwDQYJKoZIhvcNAQEEBQAwXDELMAkGA1UEBhMCQVUxEzARBgNV
|
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRwwGgYD
|
|
||||||
VQQDExNUZXN0IFBDQSAoMTAyNCBiaXQpMB4XDTk3MDYwOTEzNTc0M1oXDTAxMDYw
|
|
||||||
OTEzNTc0M1owWzELMAkGA1UEBhMCQVUxEzARBgNVBAgTClF1ZWVuc2xhbmQxGjAY
|
|
||||||
BgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRswGQYDVQQDExJUZXN0IENBICgxMDI0
|
|
||||||
IGJpdCkwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAKO7o8t116VP6cgybTsZ
|
|
||||||
DCZhr95nYlZuya3aCi1IKoztqwWnjbmDFIriOqGFPrZQ+moMETC9D59iRW/dFXSv
|
|
||||||
1F65ka/XY2hLh9exCCo7XuUcDs53Qp3bI3AmMqHjgzE8oO3ajyJAzJkTTOUecQU2
|
|
||||||
mw/gI4tMM0LqWMQS7luTy4+xAgMBAAEwDQYJKoZIhvcNAQEEBQADgYEAM7achv3v
|
|
||||||
hLQJcv/65eGEpBXM40ZDVoFQFFJWaY5p883HTqLB1x4FdzsXHH0QKBTcKpWwqyu4
|
|
||||||
YDm3fb8oDugw72bCzfyZK/zVZPR/hVlqI/fvU109Qoc+7oPvIXWky71HfcK6ZBCA
|
|
||||||
q30KIqGM/uoM60INq97qjDmCJapagcNBGQs=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIICXQIBAAKBgQCju6PLddelT+nIMm07GQwmYa/eZ2JWbsmt2gotSCqM7asFp425
|
|
||||||
gxSK4jqhhT62UPpqDBEwvQ+fYkVv3RV0r9ReuZGv12NoS4fXsQgqO17lHA7Od0Kd
|
|
||||||
2yNwJjKh44MxPKDt2o8iQMyZE0zlHnEFNpsP4COLTDNC6ljEEu5bk8uPsQIDAQAB
|
|
||||||
AoGAVZmpFZsDZfr0l2S9tLLwpjRWNOlKATQkno6q2WesT0eGLQufTciY+c8ypfU6
|
|
||||||
hyio8r5iUl/VhhdjhAtKx1mRpiotftHo/eYf8rtsrnprOnWG0bWjLjtIoMbcxGn2
|
|
||||||
J3bN6LJmbJMjDs0eJ3KnTu646F3nDUw2oGAwmpzKXA1KAP0CQQDRvQhxk2D3Pehs
|
|
||||||
HvG665u2pB5ipYQngEFlZO7RHJZzJOZEWSLuuMqaF/7pTfA5jiBvWqCgJeCRRInL
|
|
||||||
21ru4dlPAkEAx9jj7BgKn5TYnMoBSSe0afjsV9oApVpN1Nacb1YDtCwy+scp3++s
|
|
||||||
nFxlv98wxIlSdpwMUn+AUWfjiWR7Tu/G/wJBAJ/KjwZIrFVxewP0x2ILYsTRYLzz
|
|
||||||
MS4PDsO7FB+I0i7DbBOifXS2oNSpd3I0CNMwrxFnUHzynpbOStVfN3ZL5w0CQQCa
|
|
||||||
pwFahxBRhkJKsxhjoFJBX9yl75JoY4Wvm5Tbo9ih6UJaRx3kqfkN14L2BKYcsZgb
|
|
||||||
KY9vmDOYy6iNfjDeWTfJAkBkfPUb8oTJ/nSP5zN6sqGxSY4krc4xLxpRmxoJ8HL2
|
|
||||||
XfhqXkTzbU13RX9JJ/NZ8vQN9Vm2NhxRGJocQkmcdVtJ
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
MIICYDCCAiACAgEoMAkGBSsOAwINBQAwfDELMAkGA1UEBhMCVVMxNjA0BgNVBAoT
|
|
||||||
LU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEZ
|
|
||||||
MBcGA1UECxMQVGVzdCBFbnZpcm9ubWVudDEaMBgGA1UECxMRRFNTLU5BU0EtUGls
|
|
||||||
b3QtQ0EwHhcNOTYwMjI2MTYzMjQ1WhcNOTcwMjI1MTYzMjQ1WjB8MQswCQYDVQQG
|
|
||||||
EwJVUzE2MDQGA1UEChMtTmF0aW9uYWwgQWVyb25hdXRpY3MgYW5kIFNwYWNlIEFk
|
|
||||||
bWluaXN0cmF0aW9uMRkwFwYDVQQLExBUZXN0IEVudmlyb25tZW50MRowGAYDVQQL
|
|
||||||
ExFEU1MtTkFTQS1QaWxvdC1DQTCB8jAJBgUrDgMCDAUAA4HkADCB4AJBAMA/ssKb
|
|
||||||
hPNUG7ZlASfVwEJU21O5OyF/iyBzgHI1O8eOhJGUYO8cc8wDMjR508Mr9cp6Uhl/
|
|
||||||
ZB7FV5GkLNEnRHYCQQDUEaSg45P2qrDwixTRhFhmWz5Nvc4lRFQ/42XPcchiJBLb
|
|
||||||
bn3QK74T2IxY1yY+kCNq8XrIqf5fJJzIH0J/xUP3AhUAsg2wsQHfDGYk/BOSulX3
|
|
||||||
fVd0geUCQQCzCFUQAh+ZkEmp5804cs6ZWBhrUAfnra8lJItYo9xPcXgdIfLfibcX
|
|
||||||
R71UsyO77MRD7B0+Ag2tq794IleCVcEEMAkGBSsOAwINBQADLwAwLAIUUayDfreR
|
|
||||||
Yh2WeU86/pHNdkUC1IgCFEfxe1f0oMpxJyrJ5XIxTi7vGdoK
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICGTCCAdgCAwCqTDAJBgUrDgMCDQUAMHwxCzAJBgNVBAYTAlVTMTYwNAYDVQQK
|
|
||||||
Ey1OYXRpb25hbCBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x
|
|
||||||
GTAXBgNVBAsTEFRlc3QgRW52aXJvbm1lbnQxGjAYBgNVBAsTEURTUy1OQVNBLVBp
|
|
||||||
bG90LUNBMB4XDTk2MDUxNDE3MDE0MVoXDTk3MDUxNDE3MDE0MVowMzELMAkGA1UE
|
|
||||||
BhMCQVUxDzANBgNVBAoTBk1pbmNvbTETMBEGA1UEAxMKRXJpYyBZb3VuZzCB8jAJ
|
|
||||||
BgUrDgMCDAUAA4HkADCB4AJBAKbfHz6vE6pXXMTpswtGUec2tvnfLJUsoxE9qs4+
|
|
||||||
ObZX7LmLvragNPUeiTJx7UOWZ5DfBj6bXLc8eYne0lP1g3ACQQDUEaSg45P2qrDw
|
|
||||||
ixTRhFhmWz5Nvc4lRFQ/42XPcchiJBLbbn3QK74T2IxY1yY+kCNq8XrIqf5fJJzI
|
|
||||||
H0J/xUP3AhUAsg2wsQHfDGYk/BOSulX3fVd0geUCQQCzCFUQAh+ZkEmp5804cs6Z
|
|
||||||
WBhrUAfnra8lJItYo9xPcXgdIfLfibcXR71UsyO77MRD7B0+Ag2tq794IleCVcEE
|
|
||||||
MAkGBSsOAwINBQADMAAwLQIUWsuuJRE3VT4ueWkWMAJMJaZjj1ECFQCYY0zX4bzM
|
|
||||||
LC7obsrHD8XAHG+ZRG==
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICTTCCAbagAwIBAgIBADANBgkqhkiG9w0BAQQFADBMMQswCQYDVQQGEwJHQjEM
|
|
||||||
MAoGA1UEChMDVUNMMRgwFgYDVQQLEw9JQ0UtVEVMIFByb2plY3QxFTATBgNVBAMT
|
|
||||||
DFRydXN0RmFjdG9yeTAeFw05NzA0MjIxNDM5MTRaFw05ODA0MjIxNDM5MTRaMEwx
|
|
||||||
CzAJBgNVBAYTAkdCMQwwCgYDVQQKEwNVQ0wxGDAWBgNVBAsTD0lDRS1URUwgUHJv
|
|
||||||
amVjdDEVMBMGA1UEAxMMVHJ1c3RGYWN0b3J5MIGcMAoGBFUIAQECAgQAA4GNADCB
|
|
||||||
iQKBgQCEieR8NcXkUW1f0G6aC6u0i8q/98JqS6RxK5YmHIGKCkuTWAUjzLfUa4dt
|
|
||||||
U9igGCjTuxaDqlzEim+t/02pmiBZT9HaX++35MjQPUWmsChcYU5WyzGErXi+rQaw
|
|
||||||
zlwS73zM8qiPj/97lXYycWhgL0VaiDSPxRXEUdWoaGruom4mNQIDAQABo0IwQDAd
|
|
||||||
BgNVHQ4EFgQUHal1LZr7oVg5z6lYzrhTgZRCmcUwDgYDVR0PAQH/BAQDAgH2MA8G
|
|
||||||
A1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQEEBQADgYEAfaggfl6FZoioecjv0dq8
|
|
||||||
/DXo/u11iMZvXn08gjX/zl2b4wtPbShOSY5FhkSm8GeySasz+/Nwb/uzfnIhokWi
|
|
||||||
lfPZHtlCWtXbIy/TN51eJyq04ceDCQDWvLC2enVg9KB+GJ34b5c5VaPRzq8MBxsA
|
|
||||||
S7ELuYGtmYgYm9NZOIr7yU0=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIB6jCCAZQCAgEtMA0GCSqGSIb3DQEBBAUAMIGAMQswCQYDVQQGEwJVUzE2MDQG
|
|
||||||
A1UEChMtTmF0aW9uYWwgQWVyb25hdXRpY3MgYW5kIFNwYWNlIEFkbWluaXN0cmF0
|
|
||||||
aW9uMRkwFwYDVQQLExBUZXN0IEVudmlyb25tZW50MR4wHAYDVQQLExVNRDUtUlNB
|
|
||||||
LU5BU0EtUGlsb3QtQ0EwHhcNOTYwNDMwMjIwNTAwWhcNOTcwNDMwMjIwNTAwWjCB
|
|
||||||
gDELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu
|
|
||||||
ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEZMBcGA1UECxMQVGVzdCBFbnZpcm9ubWVu
|
|
||||||
dDEeMBwGA1UECxMVTUQ1LVJTQS1OQVNBLVBpbG90LUNBMFkwCgYEVQgBAQICAgAD
|
|
||||||
SwAwSAJBALmmX5+GqAvcrWK13rfDrNX9UfeA7f+ijyBgeFQjYUoDpFqapw4nzQBL
|
|
||||||
bAXug8pKkRwa2Zh8YODhXsRWu2F/UckCAwEAATANBgkqhkiG9w0BAQQFAANBAH9a
|
|
||||||
OBA+QCsjxXgnSqHx04gcU8S49DVUb1f2XVoLnHlIb8RnX0k5O6mpHT5eti9bLkiW
|
|
||||||
GJNMJ4L0AJ/ac+SmHZc=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICajCCAdMCBDGA0QUwDQYJKoZIhvcNAQEEBQAwfTELMAkGA1UEBhMCQ2ExDzAN
|
|
||||||
BgNVBAcTBk5lcGVhbjEeMBwGA1UECxMVTm8gTGlhYmlsaXR5IEFjY2VwdGVkMR8w
|
|
||||||
HQYDVQQKExZGb3IgRGVtbyBQdXJwb3NlcyBPbmx5MRwwGgYDVQQDExNFbnRydXN0
|
|
||||||
IERlbW8gV2ViIENBMB4XDTk2MDQyNjEzMzUwMVoXDTA2MDQyNjEzMzUwMVowfTEL
|
|
||||||
MAkGA1UEBhMCQ2ExDzANBgNVBAcTBk5lcGVhbjEeMBwGA1UECxMVTm8gTGlhYmls
|
|
||||||
aXR5IEFjY2VwdGVkMR8wHQYDVQQKExZGb3IgRGVtbyBQdXJwb3NlcyBPbmx5MRww
|
|
||||||
GgYDVQQDExNFbnRydXN0IERlbW8gV2ViIENBMIGdMA0GCSqGSIb3DQEBAQUAA4GL
|
|
||||||
ADCBhwKBgQCaroS7O1DA0hm4IefNYU1cx/nqOmzEnk291d1XqznDeF4wEgakbkCc
|
|
||||||
zTKxK791yNpXG5RmngqH7cygDRTHZJ6mfCRn0wGC+AI00F2vYTGqPGRQL1N3lZT0
|
|
||||||
YDKFC0SQeMMjFIZ1aeQigroFQnHo0VB3zWIMpNkka8PY9lxHZAmWwQIBAzANBgkq
|
|
||||||
hkiG9w0BAQQFAAOBgQBAx0UMVA1s54lMQyXjMX5kj99FJN5itb8bK1Rk+cegPQPF
|
|
||||||
cWO9SEWyEjjBjIkjjzAwBkaEszFsNGxemxtXvwjIm1xEUMTVlPEWTs2qnDvAUA9W
|
|
||||||
YqhWbhH0toGT36236QAsqCZ76rbTRVSSX2BHyJwJMG2tCRv7kRJ//NIgxj3H4w==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
issuer= /C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test PCA (1024 bit)
|
|
||||||
subject=/C=AU/ST=Queensland/O=CryptSoft Pty Ltd/CN=Test PCA (1024 bit)
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICJzCCAZACAQAwDQYJKoZIhvcNAQEEBQAwXDELMAkGA1UEBhMCQVUxEzARBgNV
|
|
||||||
BAgTClF1ZWVuc2xhbmQxGjAYBgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRwwGgYD
|
|
||||||
VQQDExNUZXN0IFBDQSAoMTAyNCBiaXQpMB4XDTk3MDYwOTEzNTczN1oXDTAxMDYw
|
|
||||||
OTEzNTczN1owXDELMAkGA1UEBhMCQVUxEzARBgNVBAgTClF1ZWVuc2xhbmQxGjAY
|
|
||||||
BgNVBAoTEUNyeXB0U29mdCBQdHkgTHRkMRwwGgYDVQQDExNUZXN0IFBDQSAoMTAy
|
|
||||||
NCBiaXQpMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCdoWk/3+WcMlfjIrkg
|
|
||||||
40ketmnQaEogQe1LLcuOJV6rKfUSAsPgwgsabJ/wn8TxA1yy3eKJbFl3OiUXMRsp
|
|
||||||
22Jp85PmemiDzyUIStwk72qhp1imbANZvlmlCFKiQrjUyuDfu4TABmn+kkt3vR1Y
|
|
||||||
BEOGt+IFye1UBVSATVdRJ2UVhwIDAQABMA0GCSqGSIb3DQEBBAUAA4GBABNA1u/S
|
|
||||||
Cg/LJZWb7GliiKJsvuhxlE4E5JxQF2zMub/CSNbF97//tYSyj96sxeFQxZXbcjm9
|
|
||||||
xt6mr/xNLA4szNQMJ4P+L7b5e/jC5DSqlwS+CUYJgaFs/SP+qJoCSu1bR3IM9XWO
|
|
||||||
cRBpDmcBbYLkSyB92WURvsZ1LtjEcn+cdQVI
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIICXAIBAAKBgQCdoWk/3+WcMlfjIrkg40ketmnQaEogQe1LLcuOJV6rKfUSAsPg
|
|
||||||
wgsabJ/wn8TxA1yy3eKJbFl3OiUXMRsp22Jp85PmemiDzyUIStwk72qhp1imbANZ
|
|
||||||
vlmlCFKiQrjUyuDfu4TABmn+kkt3vR1YBEOGt+IFye1UBVSATVdRJ2UVhwIDAQAB
|
|
||||||
AoGAba4fTtuap5l7/8ZsbE7Z1O32KJY4ZcOZukLOLUUhXxXduT+FTgGWujc0/rgc
|
|
||||||
z9qYCLlNZHOouMYTgtSfYvuMuLZ11VIt0GYH+nRioLShE59Yy+zCRyC+gPigS1kz
|
|
||||||
xvo14AsOIPYV14Tk/SsHyq6E0eTk7VzaIE197giiINUERPECQQDSKmtPTh/lRKw7
|
|
||||||
HSZSM0I1mFWn/1zqrAbontRQY5w98QWIOe5qmzYyFbPXYT3d9BzlsMyhgiRNoBbD
|
|
||||||
yvohSHXJAkEAwAHx6ezAZeWWzD5yXD36nyjpkVCw7Tk7TSmOceLJMWt1QcrCfqlS
|
|
||||||
xA5jjpQ6Z8suU5DdtWAryM2sAir1WisYzwJAd6Zcx56jvAQ3xcPXsE6scBTVFzrj
|
|
||||||
7FqZ6E+cclPzfLQ+QQsyOBE7bpI6e/FJppY26XGZXo3YGzV8IGXrt40oOQJALETG
|
|
||||||
h86EFXo3qGOFbmsDy4pdP5nBERCu8X1xUCSfintiD4c2DInxgS5oGclnJeMcjTvL
|
|
||||||
QjQoJCX3UJCi/OUO1QJBAKgcDHWjMvt+l1pjJBsSEZ0HX9AAIIVx0RQmbFGS+F2Q
|
|
||||||
hhu5l77WnnZOQ9vvhV5u7NPCUF9nhU3jh60qWWO8mkc=
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
subject=/C=US/O=RSA Data Security, Inc./OU=Commercial Certification Authority
|
|
||||||
issuer= /C=US/O=RSA Data Security, Inc./OU=Commercial Certification Authority
|
|
||||||
notBefore=941104185834Z
|
|
||||||
notAfter =991103185834Z
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICIzCCAZACBQJBAAAWMA0GCSqGSIb3DQEBAgUAMFwxCzAJBgNVBAYTAlVTMSAw
|
|
||||||
HgYDVQQKExdSU0EgRGF0YSBTZWN1cml0eSwgSW5jLjErMCkGA1UECxMiQ29tbWVy
|
|
||||||
Y2lhbCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NDExMDQxODU4MzRaFw05
|
|
||||||
OTExMDMxODU4MzRaMFwxCzAJBgNVBAYTAlVTMSAwHgYDVQQKExdSU0EgRGF0YSBT
|
|
||||||
ZWN1cml0eSwgSW5jLjErMCkGA1UECxMiQ29tbWVyY2lhbCBDZXJ0aWZpY2F0aW9u
|
|
||||||
IEF1dGhvcml0eTCBmzANBgkqhkiG9w0BAQEFAAOBiQAwgYUCfgCk+4Fie84QJ93o
|
|
||||||
975sbsZwmdu41QUDaSiCnHJ/lj+O7Kwpkj+KFPhCdr69XQO5kNTQvAayUTNfxMK/
|
|
||||||
touPmbZiImDd298ggrTKoi8tUO2UMt7gVY3UaOLgTNLNBRYulWZcYVI4HlGogqHE
|
|
||||||
7yXpCuaLK44xZtn42f29O2nZ6wIDAQABMA0GCSqGSIb3DQEBAgUAA34AdrW2EP4j
|
|
||||||
9/dZYkuwX5zBaLxJu7NJbyFHXSudVMQAKD+YufKKg5tgf+tQx6sFEC097TgCwaVI
|
|
||||||
0v5loMC86qYjFmZsGySp8+x5NRhPJsjjr1BKx6cxa9B8GJ1Qv6km+iYrRpwUqbtb
|
|
||||||
MJhCKLVLU7tDCZJAuqiqWqTGtotXTcU=
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
subject=/C=US/O=RSA Data Security, Inc./OU=Secure Server Certification Authority
|
|
||||||
issuer= /C=US/O=RSA Data Security, Inc./OU=Secure Server Certification Authority
|
|
||||||
notBefore=941109235417Z
|
|
||||||
notAfter =991231235417Z
|
|
||||||
-----BEGIN X509 CERTIFICATE-----
|
|
||||||
|
|
||||||
MIICKTCCAZYCBQJBAAABMA0GCSqGSIb3DQEBAgUAMF8xCzAJBgNVBAYTAlVTMSAw
|
|
||||||
HgYDVQQKExdSU0EgRGF0YSBTZWN1cml0eSwgSW5jLjEuMCwGA1UECxMlU2VjdXJl
|
|
||||||
IFNlcnZlciBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NDExMDkyMzU0MTda
|
|
||||||
Fw05OTEyMzEyMzU0MTdaMF8xCzAJBgNVBAYTAlVTMSAwHgYDVQQKExdSU0EgRGF0
|
|
||||||
YSBTZWN1cml0eSwgSW5jLjEuMCwGA1UECxMlU2VjdXJlIFNlcnZlciBDZXJ0aWZp
|
|
||||||
Y2F0aW9uIEF1dGhvcml0eTCBmzANBgkqhkiG9w0BAQEFAAOBiQAwgYUCfgCSznrB
|
|
||||||
roM+WqqJg1esJQF2DK2ujiw3zus1eGRUA+WEQFHJv48I4oqCCNIWhjdV6bEhAq12
|
|
||||||
aIGaBaJLyUslZiJWbIgHj/eBWW2EB2VwE3F2Ppt3TONQiVaYSLkdpykaEy5KEVmc
|
|
||||||
HhXVSVQsczppgrGXOZxtcGdI5d0t1sgeewIDAQABMA0GCSqGSIb3DQEBAgUAA34A
|
|
||||||
iNHReSHO4ovo+MF9NFM/YYPZtgs4F7boviGNjwC4i1N+RGceIr2XJ+CchcxK9oU7
|
|
||||||
suK+ktPlDemvXA4MRpX/oRxePug2WHpzpgr4IhFrwwk4fia7c+8AvQKk8xQNMD9h
|
|
||||||
cHsg/jKjn7P0Z1LctO6EjJY2IN6BCINxIYoPnqk=
|
|
||||||
-----END X509 CERTIFICATE-----
|
|
||||||
subject=/C=ZA/SP=Western Cape/L=Cape Town/O=Thawte Consulting cc
|
|
||||||
/OU=Certification Services Division/CN=Thawte Server CA
|
|
||||||
/Email=server-certs@thawte.com
|
|
||||||
issuer= /C=ZA/SP=Western Cape/L=Cape Town/O=Thawte Consulting cc
|
|
||||||
/OU=Certification Services Division/CN=Thawte Server CA
|
|
||||||
/Email=server-certs@thawte.com
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIC+TCCAmICAQAwDQYJKoZIhvcNAQEEBQAwgcQxCzAJBgNVBAYTAlpBMRUwEwYD
|
|
||||||
VQQIEwxXZXN0ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEdMBsGA1UEChMU
|
|
||||||
VGhhd3RlIENvbnN1bHRpbmcgY2MxKDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2Vy
|
|
||||||
dmljZXMgRGl2aXNpb24xGTAXBgNVBAMTEFRoYXd0ZSBTZXJ2ZXIgQ0ExJjAkBgkq
|
|
||||||
hkiG9w0BCQEWF3NlcnZlci1jZXJ0c0B0aGF3dGUuY29tMB4XDTk2MDcyNzE4MDc1
|
|
||||||
N1oXDTk4MDcyNzE4MDc1N1owgcQxCzAJBgNVBAYTAlpBMRUwEwYDVQQIEwxXZXN0
|
|
||||||
ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEdMBsGA1UEChMUVGhhd3RlIENv
|
|
||||||
bnN1bHRpbmcgY2MxKDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2VydmljZXMgRGl2
|
|
||||||
aXNpb24xGTAXBgNVBAMTEFRoYXd0ZSBTZXJ2ZXIgQ0ExJjAkBgkqhkiG9w0BCQEW
|
|
||||||
F3NlcnZlci1jZXJ0c0B0aGF3dGUuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCB
|
|
||||||
iQKBgQDTpFBuyP9Wa+bPXbbqDGh1R6KqwtqEJfyo9EdR2oW1IHSUhh4PdcnpCGH1
|
|
||||||
Bm0wbhUZAulSwGLbTZme4moMRDjN/r7jZAlwxf6xaym2L0nIO9QnBCUQly/nkG3A
|
|
||||||
KEKZ10xD3sP1IW1Un13DWOHA5NlbsLjctHvfNjrCtWYiEtaHDQIDAQABMA0GCSqG
|
|
||||||
SIb3DQEBBAUAA4GBAIsvn7ifX3RUIrvYXtpI4DOfARkTogwm6o7OwVdl93yFhDcX
|
|
||||||
7h5t0XZ11MUAMziKdde3rmTvzUYIUCYoY5b032IwGMTvdiclK+STN6NP2m5nvFAM
|
|
||||||
qJT5gC5O+j/jBuZRQ4i0AMYQr5F4lT8oBJnhgafw6PL8aDY2vMHGSPl9+7uf
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDDTCCAnYCAQAwDQYJKoZIhvcNAQEEBQAwgc4xCzAJBgNVBAYTAlpBMRUwEwYD
|
|
||||||
VQQIEwxXZXN0ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEdMBsGA1UEChMU
|
|
||||||
VGhhd3RlIENvbnN1bHRpbmcgY2MxKDAmBgNVBAsTH0NlcnRpZmljYXRpb24gU2Vy
|
|
||||||
dmljZXMgRGl2aXNpb24xITAfBgNVBAMTGFRoYXd0ZSBQcmVtaXVtIFNlcnZlciBD
|
|
||||||
QTEoMCYGCSqGSIb3DQEJARYZcHJlbWl1bS1zZXJ2ZXJAdGhhd3RlLmNvbTAeFw05
|
|
||||||
NjA3MjcxODA3MTRaFw05ODA3MjcxODA3MTRaMIHOMQswCQYDVQQGEwJaQTEVMBMG
|
|
||||||
A1UECBMMV2VzdGVybiBDYXBlMRIwEAYDVQQHEwlDYXBlIFRvd24xHTAbBgNVBAoT
|
|
||||||
FFRoYXd0ZSBDb25zdWx0aW5nIGNjMSgwJgYDVQQLEx9DZXJ0aWZpY2F0aW9uIFNl
|
|
||||||
cnZpY2VzIERpdmlzaW9uMSEwHwYDVQQDExhUaGF3dGUgUHJlbWl1bSBTZXJ2ZXIg
|
|
||||||
Q0ExKDAmBgkqhkiG9w0BCQEWGXByZW1pdW0tc2VydmVyQHRoYXd0ZS5jb20wgZ8w
|
|
||||||
DQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBANI2NmqL18JbntqBQWKPOO5JBFXW0O8c
|
|
||||||
G5UWR+8YSDU6UvQragaPOy/qVuOvho2eF/eetGV1Ak3vywmiIVHYm9Bn0LoNkgYU
|
|
||||||
c9STy5cqAJxcTgy8+hVS/PJEbtoRSm4Iny8t4/mqOoZztkZTWMiJBb2DEbhzP6oH
|
|
||||||
jfRCTedAnRw3AgMBAAEwDQYJKoZIhvcNAQEEBQADgYEAutFIgTRZVYerIZfL9lvR
|
|
||||||
w9Eifvvo5KTZ3h+Bj+VzNnyw4Qc/IyXkPOu6SIiH9LQ3sCmWBdxpe+qr4l77rLj2
|
|
||||||
GYuMtESFfn1XVALzkYgC7JcPuTOjMfIiMByt+uFf8AV8x0IW/Qkuv+hEQcyM9vxK
|
|
||||||
3VZdLbCVIhNoEsysrxCpxcI=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
Tims test GCI CA
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIB8DCCAZoCAQAwDQYJKoZIhvcNAQEEBQAwgYIxCzAJBgNVBAYTAkFVMRMwEQYD
|
|
||||||
VQQIEwpRdWVlbnNsYW5kMREwDwYDVQQHEwhCcmlzYmFuZTEaMBgGA1UEChMRQ3J5
|
|
||||||
cHRTb2Z0IFB0eSBMdGQxFDASBgNVBAsTC2RldmVsb3BtZW50MRkwFwYDVQQDExBD
|
|
||||||
cnlwdFNvZnQgRGV2IENBMB4XDTk3MDMyMjEzMzQwNFoXDTk4MDMyMjEzMzQwNFow
|
|
||||||
gYIxCzAJBgNVBAYTAkFVMRMwEQYDVQQIEwpRdWVlbnNsYW5kMREwDwYDVQQHEwhC
|
|
||||||
cmlzYmFuZTEaMBgGA1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxFDASBgNVBAsTC2Rl
|
|
||||||
dmVsb3BtZW50MRkwFwYDVQQDExBDcnlwdFNvZnQgRGV2IENBMFwwDQYJKoZIhvcN
|
|
||||||
AQEBBQADSwAwSAJBAOAOAqogG5QwAmLhzyO4CoRnx/wVy4NZP4dxJy83O1EnL0rw
|
|
||||||
OdsamJKvPOLHgSXo3gDu9uVyvCf/QJmZAmC5ml8CAwEAATANBgkqhkiG9w0BAQQF
|
|
||||||
AANBADRRS/GVdd7rAqRW6SdmgLJduOU2yq3avBu99kRqbp9A/dLu6r6jU+eP4oOA
|
|
||||||
TfdbFZtAAD2Hx9jUtY3tfdrJOb8=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICVjCCAgACAQAwDQYJKoZIhvcNAQEEBQAwgbUxCzAJBgNVBAYTAkFVMRMwEQYD
|
|
||||||
VQQIEwpRdWVlbnNsYW5kMREwDwYDVQQHEwhCcmlzYmFuZTEaMBgGA1UEChMRQ3J5
|
|
||||||
cHRTb2Z0IFB0eSBMdGQxLDAqBgNVBAsTI1dPUlRITEVTUyBDRVJUSUZJQ0FUSU9O
|
|
||||||
IEFVVEhPUklUSUVTMTQwMgYDVQQDEytaRVJPIFZBTFVFIENBIC0gREVNT05TVFJB
|
|
||||||
VElPTiBQVVJQT1NFUyBPTkxZMB4XDTk3MDQwMzEzMjI1NFoXDTk4MDQwMzEzMjI1
|
|
||||||
NFowgbUxCzAJBgNVBAYTAkFVMRMwEQYDVQQIEwpRdWVlbnNsYW5kMREwDwYDVQQH
|
|
||||||
EwhCcmlzYmFuZTEaMBgGA1UEChMRQ3J5cHRTb2Z0IFB0eSBMdGQxLDAqBgNVBAsT
|
|
||||||
I1dPUlRITEVTUyBDRVJUSUZJQ0FUSU9OIEFVVEhPUklUSUVTMTQwMgYDVQQDEyta
|
|
||||||
RVJPIFZBTFVFIENBIC0gREVNT05TVFJBVElPTiBQVVJQT1NFUyBPTkxZMFwwDQYJ
|
|
||||||
KoZIhvcNAQEBBQADSwAwSAJBAOZ7T7yqP/tyspcko3yPY1y0Cm2EmwNvzW4QgVXR
|
|
||||||
Fjs3HmJ4xtSpXdo6mwcGezL3Abt/aQXaxv9PU8xt+Jr0OFUCAwEAATANBgkqhkiG
|
|
||||||
9w0BAQQFAANBAOQpYmGgyCqCy1OljgJhCqQOu627oVlHzK1L+t9vBaMfn40AVUR4
|
|
||||||
WzQVWO31KTgi5vTK1U+3h46fgUWqQ0h+6rU=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIAwgKADAgECAgEAMA0GCSqGSIb3DQEBBAUAMGIxETAPBgNVBAcTCEludGVybmV0
|
|
||||||
MRcwFQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE0MDIGA1UECxMrVmVyaVNpZ24gQ2xh
|
|
||||||
c3MgMSBDQSAtIEluZGl2aWR1YWwgU3Vic2NyaWJlcjAeFw05NjA0MDgxMDIwMjda
|
|
||||||
Fw05NzA0MDgxMDIwMjdaMGIxETAPBgNVBAcTCEludGVybmV0MRcwFQYDVQQKEw5W
|
|
||||||
ZXJpU2lnbiwgSW5jLjE0MDIGA1UECxMrVmVyaVNpZ24gQ2xhc3MgMSBDQSAtIElu
|
|
||||||
ZGl2aWR1YWwgU3Vic2NyaWJlcjCAMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC2
|
|
||||||
FKbPTdAFDdjKI9BvqrQpkmOOLPhvltcunXZLEbE2jVfJw/0cxrr+Hgi6M8qV6r7j
|
|
||||||
W80GqLd5HUQq7XPysVKDaBBwZJHXPmv5912dFEObbpdFmIFH0S3L3bty10w/cari
|
|
||||||
QPJUObwW7s987LrbP2wqsxaxhhKdrpM01bjV0Pc+qQIDAQABAAAAADANBgkqhkiG
|
|
||||||
9w0BAQQFAAOBgQA+1nJryNt8VBRjRr07ArDAV/3jAH7GjDc9jsrxZS68ost9v06C
|
|
||||||
TvTNKGL+LISNmFLXl+JXhgGB0JZ9fvyYzNgHQ46HBUng1H6voalfJgS2KdEo50wW
|
|
||||||
8EFZYMDkT1k4uynwJqkVN2QJK/2q4/A/VCov5h6SlM8Affg2W+1TLqvqkwAA
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
subject=/L=Internet/O=VeriSign, Inc./OU=VeriSign Class 2 CA - Individual Subscriber
|
|
||||||
issuer= /L=Internet/O=VeriSign, Inc./OU=VeriSign Class 2 CA - Individual Subscriber
|
|
||||||
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIEkzCCA/ygAwIBAgIRANDTUpSRL3nTFeMrMayFSPAwDQYJKoZIhvcNAQECBQAw
|
|
||||||
YjERMA8GA1UEBxMISW50ZXJuZXQxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTQw
|
|
||||||
MgYDVQQLEytWZXJpU2lnbiBDbGFzcyAyIENBIC0gSW5kaXZpZHVhbCBTdWJzY3Jp
|
|
||||||
YmVyMB4XDTk2MDYwNDAwMDAwMFoXDTk4MDYwNDIzNTk1OVowYjERMA8GA1UEBxMI
|
|
||||||
SW50ZXJuZXQxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTQwMgYDVQQLEytWZXJp
|
|
||||||
U2lnbiBDbGFzcyAyIENBIC0gSW5kaXZpZHVhbCBTdWJzY3JpYmVyMIGfMA0GCSqG
|
|
||||||
SIb3DQEBAQUAA4GNADCBiQKBgQC6A+2czKGRcYMfm8gdnk+0de99TDDzsqo0v5nb
|
|
||||||
RsbUmMcdRQ7nsMbRWe0SAb/9QoLTZ/cJ0iOBqdrkz7UpqqKarVoTSdlSMVM92tWp
|
|
||||||
3bJncZHQD1t4xd6lQVdI1/T6R+5J0T1ukOdsI9Jmf+F28S6g3R3L1SFwiHKeZKZv
|
|
||||||
z+793wIDAQABo4ICRzCCAkMwggIpBgNVHQMBAf8EggIdMIICGTCCAhUwggIRBgtg
|
|
||||||
hkgBhvhFAQcBATCCAgAWggGrVGhpcyBjZXJ0aWZpY2F0ZSBpbmNvcnBvcmF0ZXMg
|
|
||||||
YnkgcmVmZXJlbmNlLCBhbmQgaXRzIHVzZSBpcyBzdHJpY3RseSBzdWJqZWN0IHRv
|
|
||||||
LCB0aGUgVmVyaVNpZ24gQ2VydGlmaWNhdGlvbiBQcmFjdGljZSBTdGF0ZW1lbnQg
|
|
||||||
KENQUyksIGF2YWlsYWJsZSBhdDogaHR0cHM6Ly93d3cudmVyaXNpZ24uY29tL0NQ
|
|
||||||
Uy0xLjA7IGJ5IEUtbWFpbCBhdCBDUFMtcmVxdWVzdHNAdmVyaXNpZ24uY29tOyBv
|
|
||||||
ciBieSBtYWlsIGF0IFZlcmlTaWduLCBJbmMuLCAyNTkzIENvYXN0IEF2ZS4sIE1v
|
|
||||||
dW50YWluIFZpZXcsIENBIDk0MDQzIFVTQSBUZWwuICsxICg0MTUpIDk2MS04ODMw
|
|
||||||
IENvcHlyaWdodCAoYykgMTk5NiBWZXJpU2lnbiwgSW5jLiAgQWxsIFJpZ2h0cyBS
|
|
||||||
ZXNlcnZlZC4gQ0VSVEFJTiBXQVJSQU5USUVTIERJU0NMQUlNRUQgYW5kIExJQUJJ
|
|
||||||
TElUWSBMSU1JVEVELqAOBgxghkgBhvhFAQcBAQGhDgYMYIZIAYb4RQEHAQECMC8w
|
|
||||||
LRYraHR0cHM6Ly93d3cudmVyaXNpZ24uY29tL3JlcG9zaXRvcnkvQ1BTLTEuMDAU
|
|
||||||
BglghkgBhvhCAQEBAf8EBAMCAgQwDQYJKoZIhvcNAQECBQADgYEApRJRkNBqLLgs
|
|
||||||
53IR/d18ODdLOWMTZ+QOOxBrq460iBEdUwgF8vmPRX1ku7UiDeNzaLlurE6eFqHq
|
|
||||||
2zPyK5j60zfTLVJMWKcQWwTJLjHtXrW8pxhNtFc6Fdvy5ZkHnC/9NIl7/t4U6WqB
|
|
||||||
p4y+p7SdMIkEwIZfds0VbnQyX5MRUJY=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|
||||||
subject=/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
|
||||||
issuer= /C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICMTCCAZoCBQKhAAABMA0GCSqGSIb3DQEBAgUAMF8xCzAJBgNVBAYTAlVTMRcw
|
|
||||||
FQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMg
|
|
||||||
UHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NjAxMjkwMDAwMDBa
|
|
||||||
Fw05OTEyMzEyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2ln
|
|
||||||
biwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZp
|
|
||||||
Y2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAyVxZ
|
|
||||||
nvIbigEUtBDfBEDb41evakVAj4QMC9Ez2dkRz+4CWB8l9yqoRAWq7AMfeH+ek7ma
|
|
||||||
AKojfdashaJjRcdyJ8z0TMZ1cdI5709C8HXfCpDGjiBvmA/4rCNfcCk2pMmG57Ga
|
|
||||||
IMtTpYXnPb59mv4kRTPcdhXtD6JxZExlLoFoRacCAwEAATANBgkqhkiG9w0BAQIF
|
|
||||||
AAOBgQB1Zmw+0c2B27X4LzZRtvdCvM1Cr9wO+hVs+GeTVzrrtpLotgHKjLeOQ7RJ
|
|
||||||
Zfk+7r11Ri7J/CVdqMcvi5uPaM+0nJcYwE3vH9mvgrPmZLiEXIqaB1JDYft0nls6
|
|
||||||
NvxMsvwaPxUupVs8G5DsiCnkWRb5zget7Ond2tIxik/W2O8XjQ==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
subject=/C=US/O=VeriSign, Inc./OU=Class 4 Public Primary Certification Authority
|
|
||||||
issuer= /C=US/O=VeriSign, Inc./OU=Class 4 Public Primary Certification Authority
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIICMTCCAZoCBQKmAAABMA0GCSqGSIb3DQEBAgUAMF8xCzAJBgNVBAYTAlVTMRcw
|
|
||||||
FQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgNCBQdWJsaWMg
|
|
||||||
UHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05NjAxMjkwMDAwMDBa
|
|
||||||
Fw05OTEyMzEyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2ln
|
|
||||||
biwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgNCBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZp
|
|
||||||
Y2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEA0LJ1
|
|
||||||
9njQrlpQ9OlQqZ+M1++RlHDo0iSQdomF1t+s5gEXMoDwnZNHvJplnR+Xrr/phnVj
|
|
||||||
IIm9gFidBAydqMEk6QvlMXi9/C0MN2qeeIDpRnX57aP7E3vIwUzSo+/1PLBij0pd
|
|
||||||
O92VZ48TucE81qcmm+zDO3rZTbxtm+gVAePwR6kCAwEAATANBgkqhkiG9w0BAQIF
|
|
||||||
AAOBgQBT3dPwnCR+QKri/AAa19oM/DJhuBUNlvP6Vxt/M3yv6ZiaYch6s7f/sdyZ
|
|
||||||
g9ysEvxwyR84Qu1E9oAuW2szaayc01znX1oYx7EteQSWQZGZQbE8DbqEOcY7l/Am
|
|
||||||
yY7uvcxClf8exwI/VAx49byqYHwCaejcrOICdmHEPgPq0ook0Q==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
|
|||||||
@@ -90,6 +90,7 @@ int MAIN(int, char **);
|
|||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
SSL_SESSION *x=NULL;
|
SSL_SESSION *x=NULL;
|
||||||
|
X509 *peer = NULL;
|
||||||
int ret=1,i,num,badops=0;
|
int ret=1,i,num,badops=0;
|
||||||
BIO *out=NULL;
|
BIO *out=NULL;
|
||||||
int informat,outformat;
|
int informat,outformat;
|
||||||
@@ -163,16 +164,17 @@ bad:
|
|||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
x=load_sess_id(infile,informat);
|
x=load_sess_id(infile,informat);
|
||||||
if (x == NULL) { goto end; }
|
if (x == NULL) { goto end; }
|
||||||
|
peer = SSL_SESSION_get0_peer(x);
|
||||||
|
|
||||||
if(context)
|
if(context)
|
||||||
{
|
{
|
||||||
x->sid_ctx_length=strlen(context);
|
size_t ctx_len = strlen(context);
|
||||||
if(x->sid_ctx_length > SSL_MAX_SID_CTX_LENGTH)
|
if(ctx_len > SSL_MAX_SID_CTX_LENGTH)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"Context too long\n");
|
BIO_printf(bio_err,"Context too long\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
memcpy(x->sid_ctx,context,x->sid_ctx_length);
|
SSL_SESSION_set1_id_context(x, (unsigned char *)context, ctx_len);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef undef
|
#ifdef undef
|
||||||
@@ -231,10 +233,10 @@ bad:
|
|||||||
|
|
||||||
if (cert)
|
if (cert)
|
||||||
{
|
{
|
||||||
if (x->peer == NULL)
|
if (peer == NULL)
|
||||||
BIO_puts(out,"No certificate present\n");
|
BIO_puts(out,"No certificate present\n");
|
||||||
else
|
else
|
||||||
X509_print(out,x->peer);
|
X509_print(out,peer);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -253,12 +255,12 @@ bad:
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (!noout && (x->peer != NULL)) /* just print the certificate */
|
else if (!noout && (peer != NULL)) /* just print the certificate */
|
||||||
{
|
{
|
||||||
if (outformat == FORMAT_ASN1)
|
if (outformat == FORMAT_ASN1)
|
||||||
i=(int)i2d_X509_bio(out,x->peer);
|
i=(int)i2d_X509_bio(out,peer);
|
||||||
else if (outformat == FORMAT_PEM)
|
else if (outformat == FORMAT_PEM)
|
||||||
i=PEM_write_bio_X509(out,x->peer);
|
i=PEM_write_bio_X509(out,peer);
|
||||||
else {
|
else {
|
||||||
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
BIO_printf(bio_err,"bad output format specified for outfile\n");
|
||||||
goto end;
|
goto end;
|
||||||
|
|||||||
38
apps/smime.c
38
apps/smime.c
@@ -93,7 +93,7 @@ int MAIN(int argc, char **argv)
|
|||||||
const char *inmode = "r", *outmode = "w";
|
const char *inmode = "r", *outmode = "w";
|
||||||
char *infile = NULL, *outfile = NULL;
|
char *infile = NULL, *outfile = NULL;
|
||||||
char *signerfile = NULL, *recipfile = NULL;
|
char *signerfile = NULL, *recipfile = NULL;
|
||||||
STACK_OF(STRING) *sksigners = NULL, *skkeys = NULL;
|
STACK_OF(OPENSSL_STRING) *sksigners = NULL, *skkeys = NULL;
|
||||||
char *certfile = NULL, *keyfile = NULL, *contfile=NULL;
|
char *certfile = NULL, *keyfile = NULL, *contfile=NULL;
|
||||||
const EVP_CIPHER *cipher = NULL;
|
const EVP_CIPHER *cipher = NULL;
|
||||||
PKCS7 *p7 = NULL;
|
PKCS7 *p7 = NULL;
|
||||||
@@ -260,13 +260,13 @@ int MAIN(int argc, char **argv)
|
|||||||
if (signerfile)
|
if (signerfile)
|
||||||
{
|
{
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
sksigners = sk_STRING_new_null();
|
sksigners = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(sksigners, signerfile);
|
sk_OPENSSL_STRING_push(sksigners, signerfile);
|
||||||
if (!keyfile)
|
if (!keyfile)
|
||||||
keyfile = signerfile;
|
keyfile = signerfile;
|
||||||
if (!skkeys)
|
if (!skkeys)
|
||||||
skkeys = sk_STRING_new_null();
|
skkeys = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(skkeys, keyfile);
|
sk_OPENSSL_STRING_push(skkeys, keyfile);
|
||||||
keyfile = NULL;
|
keyfile = NULL;
|
||||||
}
|
}
|
||||||
signerfile = *++args;
|
signerfile = *++args;
|
||||||
@@ -302,12 +302,12 @@ int MAIN(int argc, char **argv)
|
|||||||
goto argerr;
|
goto argerr;
|
||||||
}
|
}
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
sksigners = sk_STRING_new_null();
|
sksigners = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(sksigners, signerfile);
|
sk_OPENSSL_STRING_push(sksigners, signerfile);
|
||||||
signerfile = NULL;
|
signerfile = NULL;
|
||||||
if (!skkeys)
|
if (!skkeys)
|
||||||
skkeys = sk_STRING_new_null();
|
skkeys = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(skkeys, keyfile);
|
sk_OPENSSL_STRING_push(skkeys, keyfile);
|
||||||
}
|
}
|
||||||
keyfile = *++args;
|
keyfile = *++args;
|
||||||
}
|
}
|
||||||
@@ -389,13 +389,13 @@ int MAIN(int argc, char **argv)
|
|||||||
if (signerfile)
|
if (signerfile)
|
||||||
{
|
{
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
sksigners = sk_STRING_new_null();
|
sksigners = sk_OPENSSL_STRING_new_null();
|
||||||
sk_STRING_push(sksigners, signerfile);
|
sk_OPENSSL_STRING_push(sksigners, signerfile);
|
||||||
if (!skkeys)
|
if (!skkeys)
|
||||||
skkeys = sk_STRING_new_null();
|
skkeys = sk_OPENSSL_STRING_new_null();
|
||||||
if (!keyfile)
|
if (!keyfile)
|
||||||
keyfile = signerfile;
|
keyfile = signerfile;
|
||||||
sk_STRING_push(skkeys, keyfile);
|
sk_OPENSSL_STRING_push(skkeys, keyfile);
|
||||||
}
|
}
|
||||||
if (!sksigners)
|
if (!sksigners)
|
||||||
{
|
{
|
||||||
@@ -671,7 +671,7 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
if (!(store = setup_verify(bio_err, CAfile, CApath)))
|
if (!(store = setup_verify(bio_err, CAfile, CApath)))
|
||||||
goto end;
|
goto end;
|
||||||
X509_STORE_set_verify_cb_func(store, smime_cb);
|
X509_STORE_set_verify_cb(store, smime_cb);
|
||||||
if (vpm)
|
if (vpm)
|
||||||
X509_STORE_set1_param(store, vpm);
|
X509_STORE_set1_param(store, vpm);
|
||||||
}
|
}
|
||||||
@@ -707,10 +707,10 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
flags |= PKCS7_REUSE_DIGEST;
|
flags |= PKCS7_REUSE_DIGEST;
|
||||||
for (i = 0; i < sk_STRING_num(sksigners); i++)
|
for (i = 0; i < sk_OPENSSL_STRING_num(sksigners); i++)
|
||||||
{
|
{
|
||||||
signerfile = sk_STRING_value(sksigners, i);
|
signerfile = sk_OPENSSL_STRING_value(sksigners, i);
|
||||||
keyfile = sk_STRING_value(skkeys, i);
|
keyfile = sk_OPENSSL_STRING_value(skkeys, i);
|
||||||
signer = load_cert(bio_err, signerfile,FORMAT_PEM, NULL,
|
signer = load_cert(bio_err, signerfile,FORMAT_PEM, NULL,
|
||||||
e, "signer certificate");
|
e, "signer certificate");
|
||||||
if (!signer)
|
if (!signer)
|
||||||
@@ -807,9 +807,9 @@ end:
|
|||||||
if (vpm)
|
if (vpm)
|
||||||
X509_VERIFY_PARAM_free(vpm);
|
X509_VERIFY_PARAM_free(vpm);
|
||||||
if (sksigners)
|
if (sksigners)
|
||||||
sk_STRING_free(sksigners);
|
sk_OPENSSL_STRING_free(sksigners);
|
||||||
if (skkeys)
|
if (skkeys)
|
||||||
sk_STRING_free(skkeys);
|
sk_OPENSSL_STRING_free(skkeys);
|
||||||
X509_STORE_free(store);
|
X509_STORE_free(store);
|
||||||
X509_free(cert);
|
X509_free(cert);
|
||||||
X509_free(recip);
|
X509_free(recip);
|
||||||
|
|||||||
129
apps/speed.c
129
apps/speed.c
@@ -108,8 +108,14 @@
|
|||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef _WIN32
|
#if defined(_WIN32) || defined(__CYGWIN__)
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
# if defined(__CYGWIN__) && !defined(_WIN32)
|
||||||
|
/* <windows.h> should define _WIN32, which normally is mutually
|
||||||
|
* exclusive with __CYGWIN__, but if it didn't... */
|
||||||
|
# define _WIN32
|
||||||
|
/* this is done because Cygwin alarm() fails sometimes. */
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <openssl/bn.h>
|
#include <openssl/bn.h>
|
||||||
@@ -183,9 +189,38 @@
|
|||||||
#ifndef OPENSSL_NO_ECDH
|
#ifndef OPENSSL_NO_ECDH
|
||||||
#include <openssl/ecdh.h>
|
#include <openssl/ecdh.h>
|
||||||
#endif
|
#endif
|
||||||
|
#include <openssl/modes.h>
|
||||||
|
|
||||||
#if !defined(OPENSSL_SYS_VMS) && !defined(OPENSSL_SYS_WINDOWS) && !defined(OPENSSL_SYS_MACINTOSH_CLASSIC) && !defined(OPENSSL_SYS_OS2) && !defined(OPENSSL_SYS_NETWARE)
|
#ifdef OPENSSL_FIPS
|
||||||
# define HAVE_FORK 1
|
#ifdef OPENSSL_DOING_MAKEDEPEND
|
||||||
|
#undef AES_set_encrypt_key
|
||||||
|
#undef AES_set_decrypt_key
|
||||||
|
#undef DES_set_key_unchecked
|
||||||
|
#endif
|
||||||
|
#define BF_set_key private_BF_set_key
|
||||||
|
#define CAST_set_key private_CAST_set_key
|
||||||
|
#define idea_set_encrypt_key private_idea_set_encrypt_key
|
||||||
|
#define SEED_set_key private_SEED_set_key
|
||||||
|
#define RC2_set_key private_RC2_set_key
|
||||||
|
#define RC4_set_key private_RC4_set_key
|
||||||
|
#define DES_set_key_unchecked private_DES_set_key_unchecked
|
||||||
|
#define AES_set_encrypt_key private_AES_set_encrypt_key
|
||||||
|
#define AES_set_decrypt_key private_AES_set_decrypt_key
|
||||||
|
#define Camellia_set_key private_Camellia_set_key
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_FORK
|
||||||
|
# if defined(OPENSSL_SYS_VMS) || defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_MACINTOSH_CLASSIC) || defined(OPENSSL_SYS_OS2) || defined(OPENSSL_SYS_NETWARE)
|
||||||
|
# define HAVE_FORK 0
|
||||||
|
# else
|
||||||
|
# define HAVE_FORK 1
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if HAVE_FORK
|
||||||
|
#undef NO_FORK
|
||||||
|
#else
|
||||||
|
#define NO_FORK
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#undef BUFSIZE
|
#undef BUFSIZE
|
||||||
@@ -200,11 +235,11 @@ static void print_message(const char *s,long num,int length);
|
|||||||
static void pkey_print_message(const char *str, const char *str2,
|
static void pkey_print_message(const char *str, const char *str2,
|
||||||
long num, int bits, int sec);
|
long num, int bits, int sec);
|
||||||
static void print_result(int alg,int run_no,int count,double time_used);
|
static void print_result(int alg,int run_no,int count,double time_used);
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
static int do_multi(int multi);
|
static int do_multi(int multi);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define ALGOR_NUM 29
|
#define ALGOR_NUM 30
|
||||||
#define SIZE_NUM 5
|
#define SIZE_NUM 5
|
||||||
#define RSA_NUM 4
|
#define RSA_NUM 4
|
||||||
#define DSA_NUM 3
|
#define DSA_NUM 3
|
||||||
@@ -219,11 +254,15 @@ static const char *names[ALGOR_NUM]={
|
|||||||
"aes-128 cbc","aes-192 cbc","aes-256 cbc",
|
"aes-128 cbc","aes-192 cbc","aes-256 cbc",
|
||||||
"camellia-128 cbc","camellia-192 cbc","camellia-256 cbc",
|
"camellia-128 cbc","camellia-192 cbc","camellia-256 cbc",
|
||||||
"evp","sha256","sha512","whirlpool",
|
"evp","sha256","sha512","whirlpool",
|
||||||
"aes-128 ige","aes-192 ige","aes-256 ige"};
|
"aes-128 ige","aes-192 ige","aes-256 ige","ghash" };
|
||||||
static double results[ALGOR_NUM][SIZE_NUM];
|
static double results[ALGOR_NUM][SIZE_NUM];
|
||||||
static int lengths[SIZE_NUM]={16,64,256,1024,8*1024};
|
static int lengths[SIZE_NUM]={16,64,256,1024,8*1024};
|
||||||
|
#ifndef OPENSSL_NO_RSA
|
||||||
static double rsa_results[RSA_NUM][2];
|
static double rsa_results[RSA_NUM][2];
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_DSA
|
||||||
static double dsa_results[DSA_NUM][2];
|
static double dsa_results[DSA_NUM][2];
|
||||||
|
#endif
|
||||||
#ifndef OPENSSL_NO_ECDSA
|
#ifndef OPENSSL_NO_ECDSA
|
||||||
static double ecdsa_results[EC_NUM][2];
|
static double ecdsa_results[EC_NUM][2];
|
||||||
#endif
|
#endif
|
||||||
@@ -259,9 +298,12 @@ static SIGRETTYPE sig_done(int sig)
|
|||||||
|
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
|
|
||||||
#define SIGALRM
|
#if !defined(SIGALRM)
|
||||||
|
# define SIGALRM
|
||||||
|
#endif
|
||||||
static unsigned int lapse,schlock;
|
static unsigned int lapse,schlock;
|
||||||
static void alarm(unsigned int secs) { lapse = secs*1000; }
|
static void alarm_win32(unsigned int secs) { lapse = secs*1000; }
|
||||||
|
#define alarm alarm_win32
|
||||||
|
|
||||||
static DWORD WINAPI sleepy(VOID *arg)
|
static DWORD WINAPI sleepy(VOID *arg)
|
||||||
{
|
{
|
||||||
@@ -320,9 +362,6 @@ int MAIN(int, char **);
|
|||||||
|
|
||||||
int MAIN(int argc, char **argv)
|
int MAIN(int argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
|
||||||
ENGINE *e = NULL;
|
|
||||||
#endif
|
|
||||||
unsigned char *buf=NULL,*buf2=NULL;
|
unsigned char *buf=NULL,*buf2=NULL;
|
||||||
int mret=1;
|
int mret=1;
|
||||||
long count=0,save_count=0;
|
long count=0,save_count=0;
|
||||||
@@ -416,7 +455,6 @@ int MAIN(int argc, char **argv)
|
|||||||
unsigned char DES_iv[8];
|
unsigned char DES_iv[8];
|
||||||
unsigned char iv[2*MAX_BLOCK_SIZE/8];
|
unsigned char iv[2*MAX_BLOCK_SIZE/8];
|
||||||
#ifndef OPENSSL_NO_DES
|
#ifndef OPENSSL_NO_DES
|
||||||
DES_cblock *buf_as_des_cblock = NULL;
|
|
||||||
static DES_cblock key ={0x12,0x34,0x56,0x78,0x9a,0xbc,0xde,0xf0};
|
static DES_cblock key ={0x12,0x34,0x56,0x78,0x9a,0xbc,0xde,0xf0};
|
||||||
static DES_cblock key2={0x34,0x56,0x78,0x9a,0xbc,0xde,0xf0,0x12};
|
static DES_cblock key2={0x34,0x56,0x78,0x9a,0xbc,0xde,0xf0,0x12};
|
||||||
static DES_cblock key3={0x56,0x78,0x9a,0xbc,0xde,0xf0,0x12,0x34};
|
static DES_cblock key3={0x56,0x78,0x9a,0xbc,0xde,0xf0,0x12,0x34};
|
||||||
@@ -459,6 +497,7 @@ int MAIN(int argc, char **argv)
|
|||||||
#define D_IGE_128_AES 26
|
#define D_IGE_128_AES 26
|
||||||
#define D_IGE_192_AES 27
|
#define D_IGE_192_AES 27
|
||||||
#define D_IGE_256_AES 28
|
#define D_IGE_256_AES 28
|
||||||
|
#define D_GHASH 29
|
||||||
double d=0.0;
|
double d=0.0;
|
||||||
long c[ALGOR_NUM][SIZE_NUM];
|
long c[ALGOR_NUM][SIZE_NUM];
|
||||||
#define R_DSA_512 0
|
#define R_DSA_512 0
|
||||||
@@ -587,7 +626,7 @@ int MAIN(int argc, char **argv)
|
|||||||
const EVP_CIPHER *evp_cipher=NULL;
|
const EVP_CIPHER *evp_cipher=NULL;
|
||||||
const EVP_MD *evp_md=NULL;
|
const EVP_MD *evp_md=NULL;
|
||||||
int decrypt=0;
|
int decrypt=0;
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
int multi=0;
|
int multi=0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -630,9 +669,6 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf(bio_err,"out of memory\n");
|
BIO_printf(bio_err,"out of memory\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
#ifndef OPENSSL_NO_DES
|
|
||||||
buf_as_des_cblock = (DES_cblock *)buf;
|
|
||||||
#endif
|
|
||||||
if ((buf2=(unsigned char *)OPENSSL_malloc((int)BUFSIZE)) == NULL)
|
if ((buf2=(unsigned char *)OPENSSL_malloc((int)BUFSIZE)) == NULL)
|
||||||
{
|
{
|
||||||
BIO_printf(bio_err,"out of memory\n");
|
BIO_printf(bio_err,"out of memory\n");
|
||||||
@@ -707,7 +743,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf(bio_err,"no engine given\n");
|
BIO_printf(bio_err,"no engine given\n");
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
e = setup_engine(bio_err, *argv, 0);
|
setup_engine(bio_err, *argv, 0);
|
||||||
/* j will be increased again further down. We just
|
/* j will be increased again further down. We just
|
||||||
don't want speed to confuse an engine with an
|
don't want speed to confuse an engine with an
|
||||||
algorithm, especially when none is given (which
|
algorithm, especially when none is given (which
|
||||||
@@ -715,7 +751,7 @@ int MAIN(int argc, char **argv)
|
|||||||
j--;
|
j--;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
else if ((argc > 0) && (strcmp(*argv,"-multi") == 0))
|
else if ((argc > 0) && (strcmp(*argv,"-multi") == 0))
|
||||||
{
|
{
|
||||||
argc--;
|
argc--;
|
||||||
@@ -887,6 +923,10 @@ int MAIN(int argc, char **argv)
|
|||||||
doit[D_CBC_192_AES]=1;
|
doit[D_CBC_192_AES]=1;
|
||||||
doit[D_CBC_256_AES]=1;
|
doit[D_CBC_256_AES]=1;
|
||||||
}
|
}
|
||||||
|
else if (strcmp(*argv,"ghash") == 0)
|
||||||
|
{
|
||||||
|
doit[D_GHASH]=1;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_CAMELLIA
|
#ifndef OPENSSL_NO_CAMELLIA
|
||||||
@@ -1103,7 +1143,7 @@ int MAIN(int argc, char **argv)
|
|||||||
BIO_printf(bio_err,"-evp e use EVP e.\n");
|
BIO_printf(bio_err,"-evp e use EVP e.\n");
|
||||||
BIO_printf(bio_err,"-decrypt time decryption instead of encryption (only EVP).\n");
|
BIO_printf(bio_err,"-decrypt time decryption instead of encryption (only EVP).\n");
|
||||||
BIO_printf(bio_err,"-mr produce machine readable output.\n");
|
BIO_printf(bio_err,"-mr produce machine readable output.\n");
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
BIO_printf(bio_err,"-multi n run n benchmarks in parallel.\n");
|
BIO_printf(bio_err,"-multi n run n benchmarks in parallel.\n");
|
||||||
#endif
|
#endif
|
||||||
goto end;
|
goto end;
|
||||||
@@ -1113,7 +1153,7 @@ int MAIN(int argc, char **argv)
|
|||||||
j++;
|
j++;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
if(multi && do_multi(multi))
|
if(multi && do_multi(multi))
|
||||||
goto show_res;
|
goto show_res;
|
||||||
#endif
|
#endif
|
||||||
@@ -1129,6 +1169,14 @@ int MAIN(int argc, char **argv)
|
|||||||
rsa_doit[i]=1;
|
rsa_doit[i]=1;
|
||||||
for (i=0; i<DSA_NUM; i++)
|
for (i=0; i<DSA_NUM; i++)
|
||||||
dsa_doit[i]=1;
|
dsa_doit[i]=1;
|
||||||
|
#ifndef OPENSSL_NO_ECDSA
|
||||||
|
for (i=0; i<EC_NUM; i++)
|
||||||
|
ecdsa_doit[i]=1;
|
||||||
|
#endif
|
||||||
|
#ifndef OPENSSL_NO_ECDH
|
||||||
|
for (i=0; i<EC_NUM; i++)
|
||||||
|
ecdh_doit[i]=1;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
for (i=0; i<ALGOR_NUM; i++)
|
for (i=0; i<ALGOR_NUM; i++)
|
||||||
if (doit[i]) pr_header++;
|
if (doit[i]) pr_header++;
|
||||||
@@ -1215,7 +1263,8 @@ int MAIN(int argc, char **argv)
|
|||||||
count*=2;
|
count*=2;
|
||||||
Time_F(START);
|
Time_F(START);
|
||||||
for (it=count; it; it--)
|
for (it=count; it; it--)
|
||||||
DES_ecb_encrypt(buf_as_des_cblock,buf_as_des_cblock,
|
DES_ecb_encrypt((DES_cblock *)buf,
|
||||||
|
(DES_cblock *)buf,
|
||||||
&sch,DES_ENCRYPT);
|
&sch,DES_ENCRYPT);
|
||||||
d=Time_F(STOP);
|
d=Time_F(STOP);
|
||||||
} while (d <3);
|
} while (d <3);
|
||||||
@@ -1248,6 +1297,7 @@ int MAIN(int argc, char **argv)
|
|||||||
c[D_IGE_128_AES][0]=count;
|
c[D_IGE_128_AES][0]=count;
|
||||||
c[D_IGE_192_AES][0]=count;
|
c[D_IGE_192_AES][0]=count;
|
||||||
c[D_IGE_256_AES][0]=count;
|
c[D_IGE_256_AES][0]=count;
|
||||||
|
c[D_GHASH][0]=count;
|
||||||
|
|
||||||
for (i=1; i<SIZE_NUM; i++)
|
for (i=1; i<SIZE_NUM; i++)
|
||||||
{
|
{
|
||||||
@@ -1442,7 +1492,7 @@ int MAIN(int argc, char **argv)
|
|||||||
# error "You cannot disable DES on systems without SIGALRM."
|
# error "You cannot disable DES on systems without SIGALRM."
|
||||||
#endif /* OPENSSL_NO_DES */
|
#endif /* OPENSSL_NO_DES */
|
||||||
#else
|
#else
|
||||||
#define COND(c) (run)
|
#define COND(c) (run && count<0x7fffffff)
|
||||||
#define COUNT(d) (count)
|
#define COUNT(d) (count)
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
signal(SIGALRM,sig_done);
|
signal(SIGALRM,sig_done);
|
||||||
@@ -1738,7 +1788,22 @@ int MAIN(int argc, char **argv)
|
|||||||
print_result(D_IGE_256_AES,j,count,d);
|
print_result(D_IGE_256_AES,j,count,d);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (doit[D_GHASH])
|
||||||
|
{
|
||||||
|
GCM128_CONTEXT *ctx = CRYPTO_gcm128_new(&aes_ks1,(block128_f)AES_encrypt);
|
||||||
|
CRYPTO_gcm128_setiv (ctx,(unsigned char *)"0123456789ab",12);
|
||||||
|
|
||||||
|
for (j=0; j<SIZE_NUM; j++)
|
||||||
|
{
|
||||||
|
print_message(names[D_GHASH],c[D_GHASH][j],lengths[j]);
|
||||||
|
Time_F(START);
|
||||||
|
for (count=0,run=1; COND(c[D_GHASH][j]); count++)
|
||||||
|
CRYPTO_gcm128_aad(ctx,buf,lengths[j]);
|
||||||
|
d=Time_F(STOP);
|
||||||
|
print_result(D_GHASH,j,count,d);
|
||||||
|
}
|
||||||
|
CRYPTO_gcm128_release(ctx);
|
||||||
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
#ifndef OPENSSL_NO_CAMELLIA
|
#ifndef OPENSSL_NO_CAMELLIA
|
||||||
@@ -2324,7 +2389,7 @@ int MAIN(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
if (rnd_fake) RAND_cleanup();
|
if (rnd_fake) RAND_cleanup();
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
show_res:
|
show_res:
|
||||||
#endif
|
#endif
|
||||||
if(!mr)
|
if(!mr)
|
||||||
@@ -2532,7 +2597,7 @@ static void pkey_print_message(const char *str, const char *str2, long num,
|
|||||||
BIO_printf(bio_err,mr ? "+DTP:%d:%s:%s:%d\n"
|
BIO_printf(bio_err,mr ? "+DTP:%d:%s:%s:%d\n"
|
||||||
: "Doing %d bit %s %s's for %ds: ",bits,str,str2,tm);
|
: "Doing %d bit %s %s's for %ds: ",bits,str,str2,tm);
|
||||||
(void)BIO_flush(bio_err);
|
(void)BIO_flush(bio_err);
|
||||||
alarm(RSA_SECONDS);
|
alarm(tm);
|
||||||
#else
|
#else
|
||||||
BIO_printf(bio_err,mr ? "+DNP:%ld:%d:%s:%s\n"
|
BIO_printf(bio_err,mr ? "+DNP:%ld:%d:%s:%s\n"
|
||||||
: "Doing %ld %d bit %s %s's: ",num,bits,str,str2);
|
: "Doing %ld %d bit %s %s's: ",num,bits,str,str2);
|
||||||
@@ -2550,7 +2615,7 @@ static void print_result(int alg,int run_no,int count,double time_used)
|
|||||||
results[alg][run_no]=((double)count)/time_used*lengths[run_no];
|
results[alg][run_no]=((double)count)/time_used*lengths[run_no];
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAVE_FORK
|
#ifndef NO_FORK
|
||||||
static char *sstrsep(char **string, const char *delim)
|
static char *sstrsep(char **string, const char *delim)
|
||||||
{
|
{
|
||||||
char isdelim[256];
|
char isdelim[256];
|
||||||
@@ -2592,7 +2657,11 @@ static int do_multi(int multi)
|
|||||||
fds=malloc(multi*sizeof *fds);
|
fds=malloc(multi*sizeof *fds);
|
||||||
for(n=0 ; n < multi ; ++n)
|
for(n=0 ; n < multi ; ++n)
|
||||||
{
|
{
|
||||||
pipe(fd);
|
if (pipe(fd) == -1)
|
||||||
|
{
|
||||||
|
fprintf(stderr, "pipe failure\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fflush(stderr);
|
fflush(stderr);
|
||||||
if(fork())
|
if(fork())
|
||||||
@@ -2604,7 +2673,11 @@ static int do_multi(int multi)
|
|||||||
{
|
{
|
||||||
close(fd[0]);
|
close(fd[0]);
|
||||||
close(1);
|
close(1);
|
||||||
dup(fd[1]);
|
if (dup(fd[1]) == -1)
|
||||||
|
{
|
||||||
|
fprintf(stderr, "dup failed\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
close(fd[1]);
|
close(fd[1]);
|
||||||
mr=1;
|
mr=1;
|
||||||
usertime=0;
|
usertime=0;
|
||||||
@@ -2687,6 +2760,7 @@ static int do_multi(int multi)
|
|||||||
else
|
else
|
||||||
rsa_results[k][1]=d;
|
rsa_results[k][1]=d;
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_DSA
|
||||||
else if(!strncmp(buf,"+F3:",4))
|
else if(!strncmp(buf,"+F3:",4))
|
||||||
{
|
{
|
||||||
int k;
|
int k;
|
||||||
@@ -2708,6 +2782,7 @@ static int do_multi(int multi)
|
|||||||
else
|
else
|
||||||
dsa_results[k][1]=d;
|
dsa_results[k][1]=d;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
#ifndef OPENSSL_NO_ECDSA
|
#ifndef OPENSSL_NO_ECDSA
|
||||||
else if(!strncmp(buf,"+F4:",4))
|
else if(!strncmp(buf,"+F4:",4))
|
||||||
{
|
{
|
||||||
|
|||||||
756
apps/srp.c
Normal file
756
apps/srp.c
Normal file
@@ -0,0 +1,756 @@
|
|||||||
|
/* apps/srp.c */
|
||||||
|
/* Written by Peter Sylvester (peter.sylvester@edelweb.fr)
|
||||||
|
* for the EdelKey project and contributed to the OpenSSL project 2004.
|
||||||
|
*/
|
||||||
|
/* ====================================================================
|
||||||
|
* 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
|
||||||
|
* licensing@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.
|
||||||
|
* ====================================================================
|
||||||
|
*
|
||||||
|
* This product includes cryptographic software written by Eric Young
|
||||||
|
* (eay@cryptsoft.com). This product includes software written by Tim
|
||||||
|
* Hudson (tjh@cryptsoft.com).
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#include <openssl/opensslconf.h>
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_SRP
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
#include <openssl/conf.h>
|
||||||
|
#include <openssl/bio.h>
|
||||||
|
#include <openssl/err.h>
|
||||||
|
#include <openssl/txt_db.h>
|
||||||
|
#include <openssl/buffer.h>
|
||||||
|
#include <openssl/srp.h>
|
||||||
|
|
||||||
|
#include "apps.h"
|
||||||
|
|
||||||
|
#undef PROG
|
||||||
|
#define PROG srp_main
|
||||||
|
|
||||||
|
#define BASE_SECTION "srp"
|
||||||
|
#define CONFIG_FILE "openssl.cnf"
|
||||||
|
|
||||||
|
#define ENV_RANDFILE "RANDFILE"
|
||||||
|
|
||||||
|
#define ENV_DATABASE "srpvfile"
|
||||||
|
#define ENV_DEFAULT_SRP "default_srp"
|
||||||
|
|
||||||
|
static char *srp_usage[]={
|
||||||
|
"usage: srp [args] [user] \n",
|
||||||
|
"\n",
|
||||||
|
" -verbose Talk alot while doing things\n",
|
||||||
|
" -config file A config file\n",
|
||||||
|
" -name arg The particular srp definition to use\n",
|
||||||
|
" -srpvfile arg The srp verifier file name\n",
|
||||||
|
" -add add an user and srp verifier\n",
|
||||||
|
" -modify modify the srp verifier of an existing user\n",
|
||||||
|
" -delete delete user from verifier file\n",
|
||||||
|
" -list list user\n",
|
||||||
|
" -gn arg g and N values to be used for new verifier\n",
|
||||||
|
" -userinfo arg additional info to be set for user\n",
|
||||||
|
" -passin arg input file pass phrase source\n",
|
||||||
|
" -passout arg output file pass phrase source\n",
|
||||||
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
|
" -engine e - use engine e, possibly a hardware device.\n",
|
||||||
|
#endif
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
|
#ifdef EFENCE
|
||||||
|
extern int EF_PROTECT_FREE;
|
||||||
|
extern int EF_PROTECT_BELOW;
|
||||||
|
extern int EF_ALIGNMENT;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
static CONF *conf=NULL;
|
||||||
|
static char *section=NULL;
|
||||||
|
|
||||||
|
#define VERBOSE if (verbose)
|
||||||
|
#define VVERBOSE if (verbose>1)
|
||||||
|
|
||||||
|
|
||||||
|
int MAIN(int, char **);
|
||||||
|
|
||||||
|
static int get_index(CA_DB *db, char* id, char type)
|
||||||
|
{
|
||||||
|
char ** pp;
|
||||||
|
int i;
|
||||||
|
if (id == NULL) return -1;
|
||||||
|
if (type == DB_SRP_INDEX)
|
||||||
|
for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
|
{
|
||||||
|
pp = sk_OPENSSL_PSTRING_value(db->db->data,i);
|
||||||
|
if (pp[DB_srptype][0] == DB_SRP_INDEX && !strcmp(id,pp[DB_srpid]))
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
else for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
|
{
|
||||||
|
pp = sk_OPENSSL_PSTRING_value(db->db->data,i);
|
||||||
|
|
||||||
|
if (pp[DB_srptype][0] != DB_SRP_INDEX && !strcmp(id,pp[DB_srpid]))
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
|
||||||
|
return -1 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void print_entry(CA_DB *db, BIO *bio, int indx, int verbose, char *s)
|
||||||
|
{
|
||||||
|
if (indx >= 0 && verbose)
|
||||||
|
{
|
||||||
|
int j;
|
||||||
|
char **pp = sk_OPENSSL_PSTRING_value(db->db->data, indx);
|
||||||
|
BIO_printf(bio, "%s \"%s\"\n", s, pp[DB_srpid]);
|
||||||
|
for (j = 0; j < DB_NUMBER; j++)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err," %d = \"%s\"\n", j, pp[j]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void print_index(CA_DB *db, BIO *bio, int indexindex, int verbose)
|
||||||
|
{
|
||||||
|
print_entry(db, bio, indexindex, verbose, "g N entry") ;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void print_user(CA_DB *db, BIO *bio, int userindex, int verbose)
|
||||||
|
{
|
||||||
|
if (verbose > 0)
|
||||||
|
{
|
||||||
|
char **pp = sk_OPENSSL_PSTRING_value(db->db->data,userindex);
|
||||||
|
|
||||||
|
if (pp[DB_srptype][0] != 'I')
|
||||||
|
{
|
||||||
|
print_entry(db, bio, userindex, verbose, "User entry");
|
||||||
|
print_entry(db, bio, get_index(db, pp[DB_srpgN], 'I'), verbose, "g N entry");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static int update_index(CA_DB *db, BIO *bio, char **row)
|
||||||
|
{
|
||||||
|
char ** irow;
|
||||||
|
int i;
|
||||||
|
|
||||||
|
if ((irow=(char **)OPENSSL_malloc(sizeof(char *)*(DB_NUMBER+1))) == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"Memory allocation failure\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
for (i=0; i<DB_NUMBER; i++)
|
||||||
|
{
|
||||||
|
irow[i]=row[i];
|
||||||
|
row[i]=NULL;
|
||||||
|
}
|
||||||
|
irow[DB_NUMBER]=NULL;
|
||||||
|
|
||||||
|
if (!TXT_DB_insert(db->db,irow))
|
||||||
|
{
|
||||||
|
BIO_printf(bio,"failed to update srpvfile\n");
|
||||||
|
BIO_printf(bio,"TXT_DB error number %ld\n",db->db->error);
|
||||||
|
OPENSSL_free(irow);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void lookup_fail(const char *name, char *tag)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"variable lookup failed for %s::%s\n",name,tag);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static char *srp_verify_user(const char *user, const char *srp_verifier,
|
||||||
|
char *srp_usersalt, const char *g, const char *N,
|
||||||
|
const char *passin, BIO *bio, int verbose)
|
||||||
|
{
|
||||||
|
char password[1024];
|
||||||
|
PW_CB_DATA cb_tmp;
|
||||||
|
char *verifier = NULL;
|
||||||
|
char *gNid = NULL;
|
||||||
|
|
||||||
|
cb_tmp.prompt_info = user;
|
||||||
|
cb_tmp.password = passin;
|
||||||
|
|
||||||
|
if (password_callback(password, 1024, 0, &cb_tmp) >0)
|
||||||
|
{
|
||||||
|
VERBOSE BIO_printf(bio,"Validating\n user=\"%s\"\n srp_verifier=\"%s\"\n srp_usersalt=\"%s\"\n g=\"%s\"\n N=\"%s\"\n",user,srp_verifier,srp_usersalt, g, N);
|
||||||
|
BIO_printf(bio, "Pass %s\n", password);
|
||||||
|
|
||||||
|
if (!(gNid=SRP_create_verifier(user, password, &srp_usersalt, &verifier, N, g)))
|
||||||
|
{
|
||||||
|
BIO_printf(bio, "Internal error validating SRP verifier\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (strcmp(verifier, srp_verifier))
|
||||||
|
gNid = NULL;
|
||||||
|
OPENSSL_free(verifier);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return gNid;
|
||||||
|
}
|
||||||
|
|
||||||
|
static char *srp_create_user(char *user, char **srp_verifier,
|
||||||
|
char **srp_usersalt, char *g, char *N,
|
||||||
|
char *passout, BIO *bio, int verbose)
|
||||||
|
{
|
||||||
|
char password[1024];
|
||||||
|
PW_CB_DATA cb_tmp;
|
||||||
|
char *gNid = NULL;
|
||||||
|
char *salt = NULL;
|
||||||
|
cb_tmp.prompt_info = user;
|
||||||
|
cb_tmp.password = passout;
|
||||||
|
|
||||||
|
if (password_callback(password,1024,1,&cb_tmp) >0)
|
||||||
|
{
|
||||||
|
VERBOSE BIO_printf(bio,"Creating\n user=\"%s\"\n g=\"%s\"\n N=\"%s\"\n",user,g,N);
|
||||||
|
if (!(gNid =SRP_create_verifier(user, password, &salt, srp_verifier, N, g)))
|
||||||
|
{
|
||||||
|
BIO_printf(bio,"Internal error creating SRP verifier\n");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
*srp_usersalt = salt;
|
||||||
|
VVERBOSE BIO_printf(bio,"gNid=%s salt =\"%s\"\n verifier =\"%s\"\n", gNid,salt, *srp_verifier);
|
||||||
|
|
||||||
|
}
|
||||||
|
return gNid;
|
||||||
|
}
|
||||||
|
|
||||||
|
int MAIN(int argc, char **argv)
|
||||||
|
{
|
||||||
|
int add_user = 0;
|
||||||
|
int list_user= 0;
|
||||||
|
int delete_user= 0;
|
||||||
|
int modify_user= 0;
|
||||||
|
char * user = NULL;
|
||||||
|
|
||||||
|
char *passargin = NULL, *passargout = NULL;
|
||||||
|
char *passin = NULL, *passout = NULL;
|
||||||
|
char * gN = NULL;
|
||||||
|
int gNindex = -1;
|
||||||
|
char ** gNrow = NULL;
|
||||||
|
int maxgN = -1;
|
||||||
|
|
||||||
|
char * userinfo = NULL;
|
||||||
|
|
||||||
|
int badops=0;
|
||||||
|
int ret=1;
|
||||||
|
int errors=0;
|
||||||
|
int verbose=0;
|
||||||
|
int doupdatedb=0;
|
||||||
|
char *configfile=NULL;
|
||||||
|
char *dbfile=NULL;
|
||||||
|
CA_DB *db=NULL;
|
||||||
|
char **pp ;
|
||||||
|
int i;
|
||||||
|
long errorline = -1;
|
||||||
|
char *randfile=NULL;
|
||||||
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
|
char *engine = NULL;
|
||||||
|
#endif
|
||||||
|
char *tofree=NULL;
|
||||||
|
DB_ATTR db_attr;
|
||||||
|
|
||||||
|
#ifdef EFENCE
|
||||||
|
EF_PROTECT_FREE=1;
|
||||||
|
EF_PROTECT_BELOW=1;
|
||||||
|
EF_ALIGNMENT=0;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
apps_startup();
|
||||||
|
|
||||||
|
conf = NULL;
|
||||||
|
section = NULL;
|
||||||
|
|
||||||
|
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 && badops == 0)
|
||||||
|
{
|
||||||
|
if (strcmp(*argv,"-verbose") == 0)
|
||||||
|
verbose++;
|
||||||
|
else if (strcmp(*argv,"-config") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
configfile= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-name") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
section= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-srpvfile") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
dbfile= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-add") == 0)
|
||||||
|
add_user=1;
|
||||||
|
else if (strcmp(*argv,"-delete") == 0)
|
||||||
|
delete_user=1;
|
||||||
|
else if (strcmp(*argv,"-modify") == 0)
|
||||||
|
modify_user=1;
|
||||||
|
else if (strcmp(*argv,"-list") == 0)
|
||||||
|
list_user=1;
|
||||||
|
else if (strcmp(*argv,"-gn") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
gN= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-userinfo") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
userinfo= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-passin") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
passargin= *(++argv);
|
||||||
|
}
|
||||||
|
else if (strcmp(*argv,"-passout") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
passargout= *(++argv);
|
||||||
|
}
|
||||||
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
|
else if (strcmp(*argv,"-engine") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1) goto bad;
|
||||||
|
engine= *(++argv);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
else if (**argv == '-')
|
||||||
|
{
|
||||||
|
bad:
|
||||||
|
BIO_printf(bio_err,"unknown option %s\n",*argv);
|
||||||
|
badops=1;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
break;
|
||||||
|
|
||||||
|
argc--;
|
||||||
|
argv++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (dbfile && configfile)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"-dbfile and -configfile cannot be specified together.\n");
|
||||||
|
badops = 1;
|
||||||
|
}
|
||||||
|
if (add_user+delete_user+modify_user+list_user != 1)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"Exactly one of the options -add, -delete, -modify -list must be specified.\n");
|
||||||
|
badops = 1;
|
||||||
|
}
|
||||||
|
if (delete_user+modify_user+delete_user== 1 && argc <= 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"Need at least one user for options -add, -delete, -modify. \n");
|
||||||
|
badops = 1;
|
||||||
|
}
|
||||||
|
if ((passin || passout) && argc != 1 )
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"-passin, -passout arguments only valid with one user.\n");
|
||||||
|
badops = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (badops)
|
||||||
|
{
|
||||||
|
for (pp=srp_usage; (*pp != NULL); pp++)
|
||||||
|
BIO_printf(bio_err,"%s",*pp);
|
||||||
|
|
||||||
|
BIO_printf(bio_err," -rand file%cfile%c...\n", LIST_SEPARATOR_CHAR, LIST_SEPARATOR_CHAR);
|
||||||
|
BIO_printf(bio_err," load the file (or the files in the directory) into\n");
|
||||||
|
BIO_printf(bio_err," the random number generator\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
|
setup_engine(bio_err, engine, 0);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if(!app_passwd(bio_err, passargin, passargout, &passin, &passout))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Error getting passwords\n");
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!dbfile)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
/*****************************************************************/
|
||||||
|
tofree=NULL;
|
||||||
|
if (configfile == NULL) configfile = getenv("OPENSSL_CONF");
|
||||||
|
if (configfile == NULL) configfile = getenv("SSLEAY_CONF");
|
||||||
|
if (configfile == NULL)
|
||||||
|
{
|
||||||
|
const char *s=X509_get_default_cert_area();
|
||||||
|
size_t len;
|
||||||
|
|
||||||
|
#ifdef OPENSSL_SYS_VMS
|
||||||
|
len = strlen(s)+sizeof(CONFIG_FILE);
|
||||||
|
tofree=OPENSSL_malloc(len);
|
||||||
|
strcpy(tofree,s);
|
||||||
|
#else
|
||||||
|
len = strlen(s)+sizeof(CONFIG_FILE)+1;
|
||||||
|
tofree=OPENSSL_malloc(len);
|
||||||
|
BUF_strlcpy(tofree,s,len);
|
||||||
|
BUF_strlcat(tofree,"/",len);
|
||||||
|
#endif
|
||||||
|
BUF_strlcat(tofree,CONFIG_FILE,len);
|
||||||
|
configfile=tofree;
|
||||||
|
}
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err,"Using configuration from %s\n",configfile);
|
||||||
|
conf = NCONF_new(NULL);
|
||||||
|
if (NCONF_load(conf,configfile,&errorline) <= 0)
|
||||||
|
{
|
||||||
|
if (errorline <= 0)
|
||||||
|
BIO_printf(bio_err,"error loading the config file '%s'\n",
|
||||||
|
configfile);
|
||||||
|
else
|
||||||
|
BIO_printf(bio_err,"error on line %ld of config file '%s'\n"
|
||||||
|
,errorline,configfile);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
if(tofree)
|
||||||
|
{
|
||||||
|
OPENSSL_free(tofree);
|
||||||
|
tofree = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!load_config(bio_err, conf))
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
/* Lets get the config section we are using */
|
||||||
|
if (section == NULL)
|
||||||
|
{
|
||||||
|
VERBOSE BIO_printf(bio_err,"trying to read " ENV_DEFAULT_SRP " in \" BASE_SECTION \"\n");
|
||||||
|
|
||||||
|
section=NCONF_get_string(conf,BASE_SECTION,ENV_DEFAULT_SRP);
|
||||||
|
if (section == NULL)
|
||||||
|
{
|
||||||
|
lookup_fail(BASE_SECTION,ENV_DEFAULT_SRP);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (randfile == NULL && conf)
|
||||||
|
randfile = NCONF_get_string(conf, BASE_SECTION, "RANDFILE");
|
||||||
|
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err,"trying to read " ENV_DATABASE " in section \"%s\"\n",section);
|
||||||
|
|
||||||
|
if ((dbfile=NCONF_get_string(conf,section,ENV_DATABASE)) == NULL)
|
||||||
|
{
|
||||||
|
lookup_fail(section,ENV_DATABASE);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
if (randfile == NULL)
|
||||||
|
ERR_clear_error();
|
||||||
|
else
|
||||||
|
app_RAND_load_file(randfile, bio_err, 0);
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err,"Trying to read SRP verifier file \"%s\"\n",dbfile);
|
||||||
|
|
||||||
|
db = load_index(dbfile, &db_attr);
|
||||||
|
if (db == NULL) goto err;
|
||||||
|
|
||||||
|
/* Lets check some fields */
|
||||||
|
for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
|
{
|
||||||
|
pp = sk_OPENSSL_PSTRING_value(db->db->data, i);
|
||||||
|
|
||||||
|
if (pp[DB_srptype][0] == DB_SRP_INDEX)
|
||||||
|
{
|
||||||
|
maxgN = i;
|
||||||
|
if (gNindex < 0 && gN != NULL && !strcmp(gN, pp[DB_srpid]))
|
||||||
|
gNindex = i;
|
||||||
|
|
||||||
|
print_index(db, bio_err, i, verbose > 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err, "Database initialised\n");
|
||||||
|
|
||||||
|
if (gNindex >= 0)
|
||||||
|
{
|
||||||
|
gNrow = sk_OPENSSL_PSTRING_value(db->db->data,gNindex);
|
||||||
|
print_entry(db, bio_err, gNindex, verbose > 1, "Default g and N");
|
||||||
|
}
|
||||||
|
else if (maxgN > 0 && !SRP_get_default_gN(gN))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "No g and N value for index \"%s\"\n", gN);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
VERBOSE BIO_printf(bio_err, "Database has no g N information.\n");
|
||||||
|
gNrow = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
VVERBOSE BIO_printf(bio_err,"Starting user processing\n");
|
||||||
|
|
||||||
|
if (argc > 0)
|
||||||
|
user = *(argv++) ;
|
||||||
|
|
||||||
|
while (list_user || user)
|
||||||
|
{
|
||||||
|
int userindex = -1;
|
||||||
|
if (user)
|
||||||
|
VVERBOSE BIO_printf(bio_err, "Processing user \"%s\"\n", user);
|
||||||
|
if ((userindex = get_index(db, user, 'U')) >= 0)
|
||||||
|
{
|
||||||
|
print_user(db, bio_err, userindex, (verbose > 0) || list_user);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (list_user)
|
||||||
|
{
|
||||||
|
if (user == NULL)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"List all users\n");
|
||||||
|
|
||||||
|
for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
|
{
|
||||||
|
print_user(db,bio_err, i, 1);
|
||||||
|
}
|
||||||
|
list_user = 0;
|
||||||
|
}
|
||||||
|
else if (userindex < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "user \"%s\" does not exist, ignored. t\n",
|
||||||
|
user);
|
||||||
|
errors++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (add_user)
|
||||||
|
{
|
||||||
|
if (userindex >= 0)
|
||||||
|
{
|
||||||
|
/* reactivation of a new user */
|
||||||
|
char **row = sk_OPENSSL_PSTRING_value(db->db->data, userindex);
|
||||||
|
BIO_printf(bio_err, "user \"%s\" reactivated.\n", user);
|
||||||
|
row[DB_srptype][0] = 'V';
|
||||||
|
|
||||||
|
doupdatedb = 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
char *row[DB_NUMBER] ; char *gNid;
|
||||||
|
row[DB_srpverifier] = NULL;
|
||||||
|
row[DB_srpsalt] = NULL;
|
||||||
|
row[DB_srpinfo] = NULL;
|
||||||
|
if (!(gNid = srp_create_user(user,&(row[DB_srpverifier]), &(row[DB_srpsalt]),gNrow?gNrow[DB_srpsalt]:gN,gNrow?gNrow[DB_srpverifier]:NULL, passout, bio_err,verbose)))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Cannot create srp verifier for user \"%s\", operation abandoned .\n", user);
|
||||||
|
errors++;
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
row[DB_srpid] = BUF_strdup(user);
|
||||||
|
row[DB_srptype] = BUF_strdup("v");
|
||||||
|
row[DB_srpgN] = BUF_strdup(gNid);
|
||||||
|
|
||||||
|
if (!row[DB_srpid] || !row[DB_srpgN] || !row[DB_srptype] || !row[DB_srpverifier] || !row[DB_srpsalt] ||
|
||||||
|
(userinfo && (!(row[DB_srpinfo] = BUF_strdup(userinfo)))) ||
|
||||||
|
!update_index(db, bio_err, row))
|
||||||
|
{
|
||||||
|
if (row[DB_srpid]) OPENSSL_free(row[DB_srpid]);
|
||||||
|
if (row[DB_srpgN]) OPENSSL_free(row[DB_srpgN]);
|
||||||
|
if (row[DB_srpinfo]) OPENSSL_free(row[DB_srpinfo]);
|
||||||
|
if (row[DB_srptype]) OPENSSL_free(row[DB_srptype]);
|
||||||
|
if (row[DB_srpverifier]) OPENSSL_free(row[DB_srpverifier]);
|
||||||
|
if (row[DB_srpsalt]) OPENSSL_free(row[DB_srpsalt]);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
doupdatedb = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (modify_user)
|
||||||
|
{
|
||||||
|
if (userindex < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"user \"%s\" does not exist, operation ignored.\n",user);
|
||||||
|
errors++;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
char **row = sk_OPENSSL_PSTRING_value(db->db->data, userindex);
|
||||||
|
char type = row[DB_srptype][0];
|
||||||
|
if (type == 'v')
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err,"user \"%s\" already updated, operation ignored.\n",user);
|
||||||
|
errors++;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
char *gNid;
|
||||||
|
|
||||||
|
if (row[DB_srptype][0] == 'V')
|
||||||
|
{
|
||||||
|
int user_gN;
|
||||||
|
char **irow = NULL;
|
||||||
|
VERBOSE BIO_printf(bio_err,"Verifying password for user \"%s\"\n",user);
|
||||||
|
if ( (user_gN = get_index(db, row[DB_srpgN], DB_SRP_INDEX)) >= 0)
|
||||||
|
irow = (char **)sk_OPENSSL_PSTRING_value(db->db->data, userindex);
|
||||||
|
|
||||||
|
if (!srp_verify_user(user, row[DB_srpverifier], row[DB_srpsalt], irow ? irow[DB_srpsalt] : row[DB_srpgN], irow ? irow[DB_srpverifier] : NULL, passin, bio_err, verbose))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Invalid password for user \"%s\", operation abandoned.\n", user);
|
||||||
|
errors++;
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
VERBOSE BIO_printf(bio_err,"Password for user \"%s\" ok.\n",user);
|
||||||
|
|
||||||
|
if (!(gNid=srp_create_user(user,&(row[DB_srpverifier]), &(row[DB_srpsalt]),gNrow?gNrow[DB_srpsalt]:NULL, gNrow?gNrow[DB_srpverifier]:NULL, passout, bio_err,verbose)))
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "Cannot create srp verifier for user \"%s\", operation abandoned.\n", user);
|
||||||
|
errors++;
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
row[DB_srptype][0] = 'v';
|
||||||
|
row[DB_srpgN] = BUF_strdup(gNid);
|
||||||
|
|
||||||
|
if (!row[DB_srpid] || !row[DB_srpgN] || !row[DB_srptype] || !row[DB_srpverifier] || !row[DB_srpsalt] ||
|
||||||
|
(userinfo && (!(row[DB_srpinfo] = BUF_strdup(userinfo)))))
|
||||||
|
goto err;
|
||||||
|
|
||||||
|
doupdatedb = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (delete_user)
|
||||||
|
{
|
||||||
|
if (userindex < 0)
|
||||||
|
{
|
||||||
|
BIO_printf(bio_err, "user \"%s\" does not exist, operation ignored. t\n", user);
|
||||||
|
errors++;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
char **xpp = sk_OPENSSL_PSTRING_value(db->db->data,userindex);
|
||||||
|
BIO_printf(bio_err, "user \"%s\" revoked. t\n", user);
|
||||||
|
|
||||||
|
xpp[DB_srptype][0] = 'R';
|
||||||
|
|
||||||
|
doupdatedb = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (--argc > 0)
|
||||||
|
user = *(argv++) ;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
user = NULL;
|
||||||
|
list_user = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err,"User procession done.\n");
|
||||||
|
|
||||||
|
|
||||||
|
if (doupdatedb)
|
||||||
|
{
|
||||||
|
/* Lets check some fields */
|
||||||
|
for (i = 0; i < sk_OPENSSL_PSTRING_num(db->db->data); i++)
|
||||||
|
{
|
||||||
|
pp = sk_OPENSSL_PSTRING_value(db->db->data,i);
|
||||||
|
|
||||||
|
if (pp[DB_srptype][0] == 'v')
|
||||||
|
{
|
||||||
|
pp[DB_srptype][0] = 'V';
|
||||||
|
print_user(db, bio_err, i, verbose);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err, "Trying to update srpvfile.\n");
|
||||||
|
if (!save_index(dbfile, "new", db)) goto err;
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err, "Temporary srpvfile created.\n");
|
||||||
|
if (!rotate_index(dbfile, "new", "old")) goto err;
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err, "srpvfile updated.\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
ret = (errors != 0);
|
||||||
|
err:
|
||||||
|
if (errors != 0)
|
||||||
|
VERBOSE BIO_printf(bio_err,"User errors %d.\n",errors);
|
||||||
|
|
||||||
|
VERBOSE BIO_printf(bio_err,"SRP terminating with code %d.\n",ret);
|
||||||
|
if(tofree)
|
||||||
|
OPENSSL_free(tofree);
|
||||||
|
if (ret) ERR_print_errors(bio_err);
|
||||||
|
if (randfile) app_RAND_write_file(randfile, bio_err);
|
||||||
|
if (conf) NCONF_free(conf);
|
||||||
|
if (db) free_index(db);
|
||||||
|
|
||||||
|
OBJ_cleanup();
|
||||||
|
apps_shutdown();
|
||||||
|
OPENSSL_EXIT(ret);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
@@ -165,6 +165,9 @@ int MAIN(int argc, char **argv)
|
|||||||
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 cleanup;
|
||||||
|
|
||||||
for (argc--, argv++; argc > 0; argc--, argv++)
|
for (argc--, argv++; argc > 0; argc--, argv++)
|
||||||
{
|
{
|
||||||
if (strcmp(*argv, "-config") == 0)
|
if (strcmp(*argv, "-config") == 0)
|
||||||
@@ -646,7 +649,7 @@ static ASN1_INTEGER *create_nonce(int bits)
|
|||||||
|
|
||||||
/* Generating random byte sequence. */
|
/* Generating random byte sequence. */
|
||||||
if (len > (int)sizeof(buf)) goto err;
|
if (len > (int)sizeof(buf)) goto err;
|
||||||
if (!RAND_bytes(buf, len)) goto err;
|
if (RAND_bytes(buf, len) <= 0) goto err;
|
||||||
|
|
||||||
/* Find the first non-zero byte and creating ASN1_INTEGER object. */
|
/* Find the first non-zero byte and creating ASN1_INTEGER object. */
|
||||||
for (i = 0; i < len && !buf[i]; ++i);
|
for (i = 0; i < len && !buf[i]; ++i);
|
||||||
@@ -1080,7 +1083,7 @@ static X509_STORE *create_cert_store(char *ca_path, char *ca_file)
|
|||||||
cert_ctx = X509_STORE_new();
|
cert_ctx = X509_STORE_new();
|
||||||
|
|
||||||
/* Setting the callback for certificate chain verification. */
|
/* Setting the callback for certificate chain verification. */
|
||||||
X509_STORE_set_verify_cb_func(cert_ctx, verify_cb);
|
X509_STORE_set_verify_cb(cert_ctx, verify_cb);
|
||||||
|
|
||||||
/* Adding a trusted certificate directory source. */
|
/* Adding a trusted certificate directory source. */
|
||||||
if (ca_path)
|
if (ca_path)
|
||||||
|
|||||||
13
apps/tsget
13
apps/tsget
@@ -1,13 +1,13 @@
|
|||||||
#!/usr/bin/perl -w
|
#!/usr/bin/perl -w
|
||||||
# Written by Zoltan Glozik <zglozik@stones.com>.
|
# Written by Zoltan Glozik <zglozik@stones.com>.
|
||||||
# Copyright (c) 2002 The OpenTSA Project. All rights reserved.
|
# Copyright (c) 2002 The OpenTSA Project. All rights reserved.
|
||||||
$::version = '$Id: tsget,v 1.1 2006/02/12 23:11:21 ulf Exp $';
|
$::version = '$Id: tsget,v 1.1.2.2 2009/09/07 17:57:02 steve Exp $';
|
||||||
|
|
||||||
use strict;
|
use strict;
|
||||||
use IO::Handle;
|
use IO::Handle;
|
||||||
use Getopt::Std;
|
use Getopt::Std;
|
||||||
use File::Basename;
|
use File::Basename;
|
||||||
use WWW::Curl::easy;
|
use WWW::Curl::Easy;
|
||||||
|
|
||||||
use vars qw(%options);
|
use vars qw(%options);
|
||||||
|
|
||||||
@@ -37,7 +37,7 @@ sub create_curl {
|
|||||||
my $url = shift;
|
my $url = shift;
|
||||||
|
|
||||||
# Create Curl object.
|
# Create Curl object.
|
||||||
my $curl = WWW::Curl::easy::new();
|
my $curl = WWW::Curl::Easy::new();
|
||||||
|
|
||||||
# Error-handling related options.
|
# Error-handling related options.
|
||||||
$curl->setopt(CURLOPT_VERBOSE, 1) if $options{d};
|
$curl->setopt(CURLOPT_VERBOSE, 1) if $options{d};
|
||||||
@@ -49,7 +49,7 @@ sub create_curl {
|
|||||||
$curl->setopt(CURLOPT_CUSTOMREQUEST, "POST");
|
$curl->setopt(CURLOPT_CUSTOMREQUEST, "POST");
|
||||||
$curl->setopt(CURLOPT_HTTPHEADER,
|
$curl->setopt(CURLOPT_HTTPHEADER,
|
||||||
["Content-Type: application/timestamp-query",
|
["Content-Type: application/timestamp-query",
|
||||||
"Accept: application/timestamp-reply"]);
|
"Accept: application/timestamp-reply,application/timestamp-response"]);
|
||||||
$curl->setopt(CURLOPT_READFUNCTION, \&read_body);
|
$curl->setopt(CURLOPT_READFUNCTION, \&read_body);
|
||||||
$curl->setopt(CURLOPT_HEADERFUNCTION, sub { return length($_[0]); });
|
$curl->setopt(CURLOPT_HEADERFUNCTION, sub { return length($_[0]); });
|
||||||
|
|
||||||
@@ -102,7 +102,8 @@ sub get_timestamp {
|
|||||||
$error_string .= " ($::error_buf)" if defined($::error_buf);
|
$error_string .= " ($::error_buf)" if defined($::error_buf);
|
||||||
} else {
|
} else {
|
||||||
my $ct = $curl->getinfo(CURLINFO_CONTENT_TYPE);
|
my $ct = $curl->getinfo(CURLINFO_CONTENT_TYPE);
|
||||||
if (lc($ct) ne "application/timestamp-reply") {
|
if (lc($ct) ne "application/timestamp-reply"
|
||||||
|
&& lc($ct) ne "application/timestamp-response") {
|
||||||
$error_string = "unexpected content type returned: $ct";
|
$error_string = "unexpected content type returned: $ct";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -192,4 +193,4 @@ REQUEST: foreach (@ARGV) {
|
|||||||
STDERR->printflush(", $output written.\n") if $options{v};
|
STDERR->printflush(", $output written.\n") if $options{v};
|
||||||
}
|
}
|
||||||
$curl->cleanup();
|
$curl->cleanup();
|
||||||
WWW::Curl::easy::global_cleanup();
|
WWW::Curl::Easy::global_cleanup();
|
||||||
|
|||||||
189
apps/verify.c
189
apps/verify.c
@@ -70,8 +70,9 @@
|
|||||||
#define PROG verify_main
|
#define PROG verify_main
|
||||||
|
|
||||||
static int MS_CALLBACK cb(int ok, X509_STORE_CTX *ctx);
|
static int MS_CALLBACK cb(int ok, X509_STORE_CTX *ctx);
|
||||||
static int check(X509_STORE *ctx, char *file, STACK_OF(X509) *uchain, STACK_OF(X509) *tchain, int purpose, ENGINE *e);
|
static int check(X509_STORE *ctx, char *file,
|
||||||
static STACK_OF(X509) *load_untrusted(char *file);
|
STACK_OF(X509) *uchain, STACK_OF(X509) *tchain,
|
||||||
|
STACK_OF(X509_CRL) *crls, ENGINE *e);
|
||||||
static int v_verbose=0, vflags = 0;
|
static int v_verbose=0, vflags = 0;
|
||||||
|
|
||||||
int MAIN(int, char **);
|
int MAIN(int, char **);
|
||||||
@@ -80,10 +81,10 @@ int MAIN(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
ENGINE *e = NULL;
|
ENGINE *e = NULL;
|
||||||
int i,ret=1, badarg = 0;
|
int i,ret=1, badarg = 0;
|
||||||
int purpose = -1;
|
|
||||||
char *CApath=NULL,*CAfile=NULL;
|
char *CApath=NULL,*CAfile=NULL;
|
||||||
char *untfile = NULL, *trustfile = NULL;
|
char *untfile = NULL, *trustfile = NULL, *crlfile = NULL;
|
||||||
STACK_OF(X509) *untrusted = NULL, *trusted = NULL;
|
STACK_OF(X509) *untrusted = NULL, *trusted = NULL;
|
||||||
|
STACK_OF(X509_CRL) *crls = NULL;
|
||||||
X509_STORE *cert_ctx=NULL;
|
X509_STORE *cert_ctx=NULL;
|
||||||
X509_LOOKUP *lookup=NULL;
|
X509_LOOKUP *lookup=NULL;
|
||||||
X509_VERIFY_PARAM *vpm = NULL;
|
X509_VERIFY_PARAM *vpm = NULL;
|
||||||
@@ -93,7 +94,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
cert_ctx=X509_STORE_new();
|
cert_ctx=X509_STORE_new();
|
||||||
if (cert_ctx == NULL) goto end;
|
if (cert_ctx == NULL) goto end;
|
||||||
X509_STORE_set_verify_cb_func(cert_ctx,cb);
|
X509_STORE_set_verify_cb(cert_ctx,cb);
|
||||||
|
|
||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
|
|
||||||
@@ -139,6 +140,11 @@ int MAIN(int argc, char **argv)
|
|||||||
if (argc-- < 1) goto end;
|
if (argc-- < 1) goto end;
|
||||||
trustfile= *(++argv);
|
trustfile= *(++argv);
|
||||||
}
|
}
|
||||||
|
else if (strcmp(*argv,"-CRLfile") == 0)
|
||||||
|
{
|
||||||
|
if (argc-- < 1) goto end;
|
||||||
|
crlfile= *(++argv);
|
||||||
|
}
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
else if (strcmp(*argv,"-engine") == 0)
|
else if (strcmp(*argv,"-engine") == 0)
|
||||||
{
|
{
|
||||||
@@ -192,51 +198,74 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
|
|
||||||
if(untfile) {
|
if(untfile)
|
||||||
if(!(untrusted = load_untrusted(untfile))) {
|
{
|
||||||
BIO_printf(bio_err, "Error loading untrusted file %s\n", untfile);
|
untrusted = load_certs(bio_err, untfile, FORMAT_PEM,
|
||||||
ERR_print_errors(bio_err);
|
NULL, e, "untrusted certificates");
|
||||||
|
if(!untrusted)
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if(trustfile) {
|
if(trustfile)
|
||||||
if(!(trusted = load_untrusted(trustfile))) {
|
{
|
||||||
BIO_printf(bio_err, "Error loading untrusted file %s\n", trustfile);
|
trusted = load_certs(bio_err, trustfile, FORMAT_PEM,
|
||||||
ERR_print_errors(bio_err);
|
NULL, e, "trusted certificates");
|
||||||
|
if(!trusted)
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (argc < 1) check(cert_ctx, NULL, untrusted, trusted, purpose, e);
|
if(crlfile)
|
||||||
|
{
|
||||||
|
crls = load_crls(bio_err, crlfile, FORMAT_PEM,
|
||||||
|
NULL, e, "other CRLs");
|
||||||
|
if(!crls)
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
ret = 0;
|
||||||
|
if (argc < 1)
|
||||||
|
{
|
||||||
|
if (1 != check(cert_ctx, NULL, untrusted, trusted, crls, e))
|
||||||
|
ret = -1;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
for (i=0; i<argc; i++)
|
for (i=0; i<argc; i++)
|
||||||
check(cert_ctx,argv[i], untrusted, trusted, purpose, e);
|
if (1 != check(cert_ctx,argv[i], untrusted, trusted, crls, e))
|
||||||
ret=0;
|
ret = -1;
|
||||||
|
}
|
||||||
|
|
||||||
end:
|
end:
|
||||||
if (ret == 1) {
|
if (ret == 1) {
|
||||||
BIO_printf(bio_err,"usage: verify [-verbose] [-CApath path] [-CAfile file] [-purpose purpose] [-crl_check]");
|
BIO_printf(bio_err,"usage: verify [-verbose] [-CApath path] [-CAfile file] [-purpose purpose] [-crl_check]");
|
||||||
|
BIO_printf(bio_err," [-attime timestamp]");
|
||||||
#ifndef OPENSSL_NO_ENGINE
|
#ifndef OPENSSL_NO_ENGINE
|
||||||
BIO_printf(bio_err," [-engine e]");
|
BIO_printf(bio_err," [-engine e]");
|
||||||
#endif
|
#endif
|
||||||
BIO_printf(bio_err," cert1 cert2 ...\n");
|
BIO_printf(bio_err," cert1 cert2 ...\n");
|
||||||
|
|
||||||
BIO_printf(bio_err,"recognized usages:\n");
|
BIO_printf(bio_err,"recognized usages:\n");
|
||||||
for(i = 0; i < X509_PURPOSE_get_count(); i++) {
|
for(i = 0; i < X509_PURPOSE_get_count(); i++)
|
||||||
|
{
|
||||||
X509_PURPOSE *ptmp;
|
X509_PURPOSE *ptmp;
|
||||||
ptmp = X509_PURPOSE_get0(i);
|
ptmp = X509_PURPOSE_get0(i);
|
||||||
BIO_printf(bio_err, "\t%-10s\t%s\n", X509_PURPOSE_get0_sname(ptmp),
|
BIO_printf(bio_err, "\t%-10s\t%s\n",
|
||||||
X509_PURPOSE_get0_name(ptmp));
|
X509_PURPOSE_get0_sname(ptmp),
|
||||||
}
|
X509_PURPOSE_get0_name(ptmp));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (vpm) X509_VERIFY_PARAM_free(vpm);
|
if (vpm) X509_VERIFY_PARAM_free(vpm);
|
||||||
if (cert_ctx != NULL) X509_STORE_free(cert_ctx);
|
if (cert_ctx != NULL) X509_STORE_free(cert_ctx);
|
||||||
sk_X509_pop_free(untrusted, X509_free);
|
sk_X509_pop_free(untrusted, X509_free);
|
||||||
sk_X509_pop_free(trusted, X509_free);
|
sk_X509_pop_free(trusted, X509_free);
|
||||||
|
sk_X509_CRL_pop_free(crls, X509_CRL_free);
|
||||||
apps_shutdown();
|
apps_shutdown();
|
||||||
OPENSSL_EXIT(ret);
|
OPENSSL_EXIT(ret < 0 ? 2 : ret);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int check(X509_STORE *ctx, char *file, STACK_OF(X509) *uchain, STACK_OF(X509) *tchain, int purpose, ENGINE *e)
|
static int check(X509_STORE *ctx, char *file,
|
||||||
|
STACK_OF(X509) *uchain, STACK_OF(X509) *tchain,
|
||||||
|
STACK_OF(X509_CRL) *crls, ENGINE *e)
|
||||||
{
|
{
|
||||||
X509 *x=NULL;
|
X509 *x=NULL;
|
||||||
int i=0,ret=0;
|
int i=0,ret=0;
|
||||||
@@ -260,7 +289,8 @@ static int check(X509_STORE *ctx, char *file, STACK_OF(X509) *uchain, STACK_OF(X
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
if(tchain) X509_STORE_CTX_trusted_stack(csc, tchain);
|
if(tchain) X509_STORE_CTX_trusted_stack(csc, tchain);
|
||||||
if(purpose >= 0) X509_STORE_CTX_set_purpose(csc, purpose);
|
if (crls)
|
||||||
|
X509_STORE_CTX_set0_crls(csc, crls);
|
||||||
i=X509_verify_cert(csc);
|
i=X509_verify_cert(csc);
|
||||||
X509_STORE_CTX_free(csc);
|
X509_STORE_CTX_free(csc);
|
||||||
|
|
||||||
@@ -278,90 +308,53 @@ end:
|
|||||||
return(ret);
|
return(ret);
|
||||||
}
|
}
|
||||||
|
|
||||||
static STACK_OF(X509) *load_untrusted(char *certfile)
|
|
||||||
{
|
|
||||||
STACK_OF(X509_INFO) *sk=NULL;
|
|
||||||
STACK_OF(X509) *stack=NULL, *ret=NULL;
|
|
||||||
BIO *in=NULL;
|
|
||||||
X509_INFO *xi;
|
|
||||||
|
|
||||||
if(!(stack = sk_X509_new_null())) {
|
|
||||||
BIO_printf(bio_err,"memory allocation failure\n");
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
|
|
||||||
if(!(in=BIO_new_file(certfile, "r"))) {
|
|
||||||
BIO_printf(bio_err,"error opening the file, %s\n",certfile);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This loads from a file, a stack of x509/crl/pkey sets */
|
|
||||||
if(!(sk=PEM_X509_INFO_read_bio(in,NULL,NULL,NULL))) {
|
|
||||||
BIO_printf(bio_err,"error reading the file, %s\n",certfile);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* scan over it and pull out the certs */
|
|
||||||
while (sk_X509_INFO_num(sk))
|
|
||||||
{
|
|
||||||
xi=sk_X509_INFO_shift(sk);
|
|
||||||
if (xi->x509 != NULL)
|
|
||||||
{
|
|
||||||
sk_X509_push(stack,xi->x509);
|
|
||||||
xi->x509=NULL;
|
|
||||||
}
|
|
||||||
X509_INFO_free(xi);
|
|
||||||
}
|
|
||||||
if(!sk_X509_num(stack)) {
|
|
||||||
BIO_printf(bio_err,"no certificates in file, %s\n",certfile);
|
|
||||||
sk_X509_free(stack);
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
ret=stack;
|
|
||||||
end:
|
|
||||||
BIO_free(in);
|
|
||||||
sk_X509_INFO_free(sk);
|
|
||||||
return(ret);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int MS_CALLBACK cb(int ok, X509_STORE_CTX *ctx)
|
static int MS_CALLBACK cb(int ok, X509_STORE_CTX *ctx)
|
||||||
{
|
{
|
||||||
char buf[256];
|
int cert_error = X509_STORE_CTX_get_error(ctx);
|
||||||
|
X509 *current_cert = X509_STORE_CTX_get_current_cert(ctx);
|
||||||
|
|
||||||
if (!ok)
|
if (!ok)
|
||||||
{
|
{
|
||||||
if (ctx->current_cert)
|
if (current_cert)
|
||||||
{
|
{
|
||||||
X509_NAME_oneline(
|
X509_NAME_print_ex_fp(stdout,
|
||||||
X509_get_subject_name(ctx->current_cert),buf,
|
X509_get_subject_name(current_cert),
|
||||||
sizeof buf);
|
0, XN_FLAG_ONELINE);
|
||||||
printf("%s\n",buf);
|
printf("\n");
|
||||||
|
}
|
||||||
|
printf("%serror %d at %d depth lookup:%s\n",
|
||||||
|
X509_STORE_CTX_get0_parent_ctx(ctx) ? "[CRL path]" : "",
|
||||||
|
cert_error,
|
||||||
|
X509_STORE_CTX_get_error_depth(ctx),
|
||||||
|
X509_verify_cert_error_string(cert_error));
|
||||||
|
switch(cert_error)
|
||||||
|
{
|
||||||
|
case X509_V_ERR_NO_EXPLICIT_POLICY:
|
||||||
|
policies_print(NULL, ctx);
|
||||||
|
case X509_V_ERR_CERT_HAS_EXPIRED:
|
||||||
|
|
||||||
|
/* since we are just checking the certificates, it is
|
||||||
|
* ok if they are self signed. But we should still warn
|
||||||
|
* the user.
|
||||||
|
*/
|
||||||
|
|
||||||
|
case X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT:
|
||||||
|
/* Continue after extension errors too */
|
||||||
|
case X509_V_ERR_INVALID_CA:
|
||||||
|
case X509_V_ERR_INVALID_NON_CA:
|
||||||
|
case X509_V_ERR_PATH_LENGTH_EXCEEDED:
|
||||||
|
case X509_V_ERR_INVALID_PURPOSE:
|
||||||
|
case X509_V_ERR_CRL_HAS_EXPIRED:
|
||||||
|
case X509_V_ERR_CRL_NOT_YET_VALID:
|
||||||
|
case X509_V_ERR_UNHANDLED_CRITICAL_EXTENSION:
|
||||||
|
ok = 1;
|
||||||
|
|
||||||
}
|
}
|
||||||
printf("error %d at %d depth lookup:%s\n",ctx->error,
|
|
||||||
ctx->error_depth,
|
|
||||||
X509_verify_cert_error_string(ctx->error));
|
|
||||||
if (ctx->error == X509_V_ERR_CERT_HAS_EXPIRED) ok=1;
|
|
||||||
/* since we are just checking the certificates, it is
|
|
||||||
* ok if they are self signed. But we should still warn
|
|
||||||
* the user.
|
|
||||||
*/
|
|
||||||
if (ctx->error == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) ok=1;
|
|
||||||
/* Continue after extension errors too */
|
|
||||||
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_INVALID_PURPOSE) ok=1;
|
|
||||||
if (ctx->error == X509_V_ERR_DEPTH_ZERO_SELF_SIGNED_CERT) ok=1;
|
|
||||||
if (ctx->error == X509_V_ERR_CRL_HAS_EXPIRED) ok=1;
|
|
||||||
if (ctx->error == X509_V_ERR_CRL_NOT_YET_VALID) ok=1;
|
|
||||||
if (ctx->error == X509_V_ERR_UNHANDLED_CRITICAL_EXTENSION) ok=1;
|
|
||||||
|
|
||||||
if (ctx->error == X509_V_ERR_NO_EXPLICIT_POLICY)
|
|
||||||
policies_print(NULL, ctx);
|
|
||||||
return ok;
|
return ok;
|
||||||
|
|
||||||
}
|
}
|
||||||
if ((ctx->error == X509_V_OK) && (ok == 2))
|
if (cert_error == X509_V_OK && ok == 2)
|
||||||
policies_print(NULL, ctx);
|
policies_print(NULL, ctx);
|
||||||
if (!v_verbose)
|
if (!v_verbose)
|
||||||
ERR_clear_error();
|
ERR_clear_error();
|
||||||
|
|||||||
188
apps/vms_decc_init.c
Executable file
188
apps/vms_decc_init.c
Executable file
@@ -0,0 +1,188 @@
|
|||||||
|
#if defined( __VMS) && !defined( OPENSSL_NO_DECC_INIT) && \
|
||||||
|
defined( __DECC) && !defined( __VAX) && (__CRTL_VER >= 70301000)
|
||||||
|
# define USE_DECC_INIT 1
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef USE_DECC_INIT
|
||||||
|
|
||||||
|
/*
|
||||||
|
* 2010-04-26 SMS.
|
||||||
|
*
|
||||||
|
*----------------------------------------------------------------------
|
||||||
|
*
|
||||||
|
* decc_init()
|
||||||
|
*
|
||||||
|
* On non-VAX systems, uses LIB$INITIALIZE to set a collection of C
|
||||||
|
* RTL features without using the DECC$* logical name method.
|
||||||
|
*
|
||||||
|
*----------------------------------------------------------------------
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <unixlib.h>
|
||||||
|
|
||||||
|
|
||||||
|
/* Global storage. */
|
||||||
|
|
||||||
|
/* Flag to sense if decc_init() was called. */
|
||||||
|
|
||||||
|
int decc_init_done = -1;
|
||||||
|
|
||||||
|
|
||||||
|
/* Structure to hold a DECC$* feature name and its desired value. */
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
char *name;
|
||||||
|
int value;
|
||||||
|
} decc_feat_t;
|
||||||
|
|
||||||
|
|
||||||
|
/* Array of DECC$* feature names and their desired values.
|
||||||
|
* Note: DECC$ARGV_PARSE_STYLE is the urgent one.
|
||||||
|
*/
|
||||||
|
|
||||||
|
decc_feat_t decc_feat_array[] =
|
||||||
|
{
|
||||||
|
/* Preserve command-line case with SET PROCESS/PARSE_STYLE=EXTENDED */
|
||||||
|
{ "DECC$ARGV_PARSE_STYLE", 1 },
|
||||||
|
|
||||||
|
/* Preserve case for file names on ODS5 disks. */
|
||||||
|
{ "DECC$EFS_CASE_PRESERVE", 1 },
|
||||||
|
|
||||||
|
/* Enable multiple dots (and most characters) in ODS5 file names,
|
||||||
|
* while preserving VMS-ness of ";version".
|
||||||
|
*/
|
||||||
|
{ "DECC$EFS_CHARSET", 1 },
|
||||||
|
|
||||||
|
/* List terminator. */
|
||||||
|
{ (char *)NULL, 0 }
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/* LIB$INITIALIZE initialization function. */
|
||||||
|
|
||||||
|
static void decc_init( void)
|
||||||
|
{
|
||||||
|
char *openssl_debug_decc_init;
|
||||||
|
int verbose = 0;
|
||||||
|
int feat_index;
|
||||||
|
int feat_value;
|
||||||
|
int feat_value_max;
|
||||||
|
int feat_value_min;
|
||||||
|
int i;
|
||||||
|
int sts;
|
||||||
|
|
||||||
|
/* Get debug option. */
|
||||||
|
openssl_debug_decc_init = getenv( "OPENSSL_DEBUG_DECC_INIT");
|
||||||
|
if (openssl_debug_decc_init != NULL)
|
||||||
|
{
|
||||||
|
verbose = strtol( openssl_debug_decc_init, NULL, 10);
|
||||||
|
if (verbose <= 0)
|
||||||
|
{
|
||||||
|
verbose = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Set the global flag to indicate that LIB$INITIALIZE worked. */
|
||||||
|
decc_init_done = 1;
|
||||||
|
|
||||||
|
/* Loop through all items in the decc_feat_array[]. */
|
||||||
|
|
||||||
|
for (i = 0; decc_feat_array[ i].name != NULL; i++)
|
||||||
|
{
|
||||||
|
/* Get the feature index. */
|
||||||
|
feat_index = decc$feature_get_index( decc_feat_array[ i].name);
|
||||||
|
if (feat_index >= 0)
|
||||||
|
{
|
||||||
|
/* Valid item. Collect its properties. */
|
||||||
|
feat_value = decc$feature_get_value( feat_index, 1);
|
||||||
|
feat_value_min = decc$feature_get_value( feat_index, 2);
|
||||||
|
feat_value_max = decc$feature_get_value( feat_index, 3);
|
||||||
|
|
||||||
|
/* Check the validity of our desired value. */
|
||||||
|
if ((decc_feat_array[ i].value >= feat_value_min) &&
|
||||||
|
(decc_feat_array[ i].value <= feat_value_max))
|
||||||
|
{
|
||||||
|
/* Valid value. Set it if necessary. */
|
||||||
|
if (feat_value != decc_feat_array[ i].value)
|
||||||
|
{
|
||||||
|
sts = decc$feature_set_value( feat_index,
|
||||||
|
1,
|
||||||
|
decc_feat_array[ i].value);
|
||||||
|
|
||||||
|
if (verbose > 1)
|
||||||
|
{
|
||||||
|
fprintf( stderr, " %s = %d, sts = %d.\n",
|
||||||
|
decc_feat_array[ i].name,
|
||||||
|
decc_feat_array[ i].value,
|
||||||
|
sts);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
/* Invalid DECC feature value. */
|
||||||
|
fprintf( stderr,
|
||||||
|
" INVALID DECC$FEATURE VALUE, %d: %d <= %s <= %d.\n",
|
||||||
|
feat_value,
|
||||||
|
feat_value_min, decc_feat_array[ i].name, feat_value_max);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
/* Invalid DECC feature name. */
|
||||||
|
fprintf( stderr,
|
||||||
|
" UNKNOWN DECC$FEATURE: %s.\n", decc_feat_array[ i].name);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (verbose > 0)
|
||||||
|
{
|
||||||
|
fprintf( stderr, " DECC_INIT complete.\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Get "decc_init()" into a valid, loaded LIB$INITIALIZE PSECT. */
|
||||||
|
|
||||||
|
#pragma nostandard
|
||||||
|
|
||||||
|
/* Establish the LIB$INITIALIZE PSECTs, with proper alignment and
|
||||||
|
* other attributes. Note that "nopic" is significant only on VAX.
|
||||||
|
*/
|
||||||
|
#pragma extern_model save
|
||||||
|
|
||||||
|
#if __INITIAL_POINTER_SIZE == 64
|
||||||
|
# define PSECT_ALIGN 3
|
||||||
|
#else
|
||||||
|
# define PSECT_ALIGN 2
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#pragma extern_model strict_refdef "LIB$INITIALIZ" PSECT_ALIGN, nopic, nowrt
|
||||||
|
const int spare[ 8] = { 0 };
|
||||||
|
|
||||||
|
#pragma extern_model strict_refdef "LIB$INITIALIZE" PSECT_ALIGN, nopic, nowrt
|
||||||
|
void (*const x_decc_init)() = decc_init;
|
||||||
|
|
||||||
|
#pragma extern_model restore
|
||||||
|
|
||||||
|
/* Fake reference to ensure loading the LIB$INITIALIZE PSECT. */
|
||||||
|
|
||||||
|
#pragma extern_model save
|
||||||
|
|
||||||
|
int LIB$INITIALIZE( void);
|
||||||
|
|
||||||
|
#pragma extern_model strict_refdef
|
||||||
|
int dmy_lib$initialize = (int) LIB$INITIALIZE;
|
||||||
|
|
||||||
|
#pragma extern_model restore
|
||||||
|
|
||||||
|
#pragma standard
|
||||||
|
|
||||||
|
#else /* def USE_DECC_INIT */
|
||||||
|
|
||||||
|
/* Dummy code to avoid a %CC-W-EMPTYFILE complaint. */
|
||||||
|
int decc_init_dummy( void);
|
||||||
|
|
||||||
|
#endif /* def USE_DECC_INIT */
|
||||||
82
apps/x509.c
82
apps/x509.c
@@ -99,7 +99,13 @@ static const char *x509_usage[]={
|
|||||||
" -passin arg - private key password source\n",
|
" -passin arg - private key password source\n",
|
||||||
" -serial - print serial number value\n",
|
" -serial - print serial number value\n",
|
||||||
" -subject_hash - print subject hash value\n",
|
" -subject_hash - print subject hash value\n",
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
" -subject_hash_old - print old-style (MD5) subject hash value\n",
|
||||||
|
#endif
|
||||||
" -issuer_hash - print issuer hash value\n",
|
" -issuer_hash - print issuer hash value\n",
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
" -issuer_hash_old - print old-style (MD5) issuer hash value\n",
|
||||||
|
#endif
|
||||||
" -hash - synonym for -subject_hash\n",
|
" -hash - synonym for -subject_hash\n",
|
||||||
" -subject - print subject DN\n",
|
" -subject - print subject DN\n",
|
||||||
" -issuer - print issuer DN\n",
|
" -issuer - print issuer DN\n",
|
||||||
@@ -151,9 +157,10 @@ static int MS_CALLBACK callb(int ok, X509_STORE_CTX *ctx);
|
|||||||
static int sign (X509 *x, EVP_PKEY *pkey,int days,int clrext, const EVP_MD *digest,
|
static int sign (X509 *x, EVP_PKEY *pkey,int days,int clrext, const EVP_MD *digest,
|
||||||
CONF *conf, char *section);
|
CONF *conf, char *section);
|
||||||
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,
|
||||||
X509 *x,X509 *xca,EVP_PKEY *pkey,char *serial,
|
X509 *x,X509 *xca,EVP_PKEY *pkey,
|
||||||
int create,int days, int clrext, CONF *conf, char *section,
|
STACK_OF(OPENSSL_STRING) *sigopts,
|
||||||
ASN1_INTEGER *sno);
|
char *serial, int create ,int days, int clrext,
|
||||||
|
CONF *conf, char *section, ASN1_INTEGER *sno);
|
||||||
static int purpose_print(BIO *bio, X509 *cert, X509_PURPOSE *pt);
|
static int purpose_print(BIO *bio, X509 *cert, X509_PURPOSE *pt);
|
||||||
static int reqfile=0;
|
static int reqfile=0;
|
||||||
|
|
||||||
@@ -166,6 +173,7 @@ int MAIN(int argc, char **argv)
|
|||||||
X509_REQ *req=NULL;
|
X509_REQ *req=NULL;
|
||||||
X509 *x=NULL,*xca=NULL;
|
X509 *x=NULL,*xca=NULL;
|
||||||
ASN1_OBJECT *objtmp;
|
ASN1_OBJECT *objtmp;
|
||||||
|
STACK_OF(OPENSSL_STRING) *sigopts = NULL;
|
||||||
EVP_PKEY *Upkey=NULL,*CApkey=NULL;
|
EVP_PKEY *Upkey=NULL,*CApkey=NULL;
|
||||||
ASN1_INTEGER *sno = NULL;
|
ASN1_INTEGER *sno = NULL;
|
||||||
int i,num,badops=0;
|
int i,num,badops=0;
|
||||||
@@ -179,6 +187,9 @@ int MAIN(int argc, char **argv)
|
|||||||
int text=0,serial=0,subject=0,issuer=0,startdate=0,enddate=0;
|
int text=0,serial=0,subject=0,issuer=0,startdate=0,enddate=0;
|
||||||
int next_serial=0;
|
int next_serial=0;
|
||||||
int subject_hash=0,issuer_hash=0,ocspid=0;
|
int subject_hash=0,issuer_hash=0,ocspid=0;
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
int subject_hash_old=0,issuer_hash_old=0;
|
||||||
|
#endif
|
||||||
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 ocsp_uri=0;
|
int ocsp_uri=0;
|
||||||
int trustout=0,clrtrust=0,clrreject=0,aliasout=0,clrext=0;
|
int trustout=0,clrtrust=0,clrreject=0,aliasout=0,clrext=0;
|
||||||
@@ -225,7 +236,7 @@ int MAIN(int argc, char **argv)
|
|||||||
|
|
||||||
ctx=X509_STORE_new();
|
ctx=X509_STORE_new();
|
||||||
if (ctx == NULL) goto end;
|
if (ctx == NULL) goto end;
|
||||||
X509_STORE_set_verify_cb_func(ctx,callb);
|
X509_STORE_set_verify_cb(ctx,callb);
|
||||||
|
|
||||||
argc--;
|
argc--;
|
||||||
argv++;
|
argv++;
|
||||||
@@ -262,13 +273,22 @@ int MAIN(int argc, char **argv)
|
|||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
CAkeyformat=str2fmt(*(++argv));
|
CAkeyformat=str2fmt(*(++argv));
|
||||||
}
|
}
|
||||||
|
else if (strcmp(*argv,"-sigopt") == 0)
|
||||||
|
{
|
||||||
|
if (--argc < 1)
|
||||||
|
goto bad;
|
||||||
|
if (!sigopts)
|
||||||
|
sigopts = sk_OPENSSL_STRING_new_null();
|
||||||
|
if (!sigopts || !sk_OPENSSL_STRING_push(sigopts, *(++argv)))
|
||||||
|
goto bad;
|
||||||
|
}
|
||||||
else if (strcmp(*argv,"-days") == 0)
|
else if (strcmp(*argv,"-days") == 0)
|
||||||
{
|
{
|
||||||
if (--argc < 1) goto bad;
|
if (--argc < 1) goto bad;
|
||||||
days=atoi(*(++argv));
|
days=atoi(*(++argv));
|
||||||
if (days == 0)
|
if (days == 0)
|
||||||
{
|
{
|
||||||
BIO_printf(STDout,"bad number of days\n");
|
BIO_printf(bio_err,"bad number of days\n");
|
||||||
goto bad;
|
goto bad;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -397,8 +417,16 @@ int MAIN(int argc, char **argv)
|
|||||||
else if (strcmp(*argv,"-hash") == 0
|
else if (strcmp(*argv,"-hash") == 0
|
||||||
|| strcmp(*argv,"-subject_hash") == 0)
|
|| strcmp(*argv,"-subject_hash") == 0)
|
||||||
subject_hash= ++num;
|
subject_hash= ++num;
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
else if (strcmp(*argv,"-subject_hash_old") == 0)
|
||||||
|
subject_hash_old= ++num;
|
||||||
|
#endif
|
||||||
else if (strcmp(*argv,"-issuer_hash") == 0)
|
else if (strcmp(*argv,"-issuer_hash") == 0)
|
||||||
issuer_hash= ++num;
|
issuer_hash= ++num;
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
else if (strcmp(*argv,"-issuer_hash_old") == 0)
|
||||||
|
issuer_hash_old= ++num;
|
||||||
|
#endif
|
||||||
else if (strcmp(*argv,"-subject") == 0)
|
else if (strcmp(*argv,"-subject") == 0)
|
||||||
subject= ++num;
|
subject= ++num;
|
||||||
else if (strcmp(*argv,"-issuer") == 0)
|
else if (strcmp(*argv,"-issuer") == 0)
|
||||||
@@ -539,7 +567,6 @@ bad:
|
|||||||
if (reqfile)
|
if (reqfile)
|
||||||
{
|
{
|
||||||
EVP_PKEY *pkey;
|
EVP_PKEY *pkey;
|
||||||
X509_CINF *ci;
|
|
||||||
BIO *in;
|
BIO *in;
|
||||||
|
|
||||||
if (!sign_flag && !CA_flag)
|
if (!sign_flag && !CA_flag)
|
||||||
@@ -607,7 +634,6 @@ bad:
|
|||||||
print_name(bio_err, "subject=", X509_REQ_get_subject_name(req), nmflag);
|
print_name(bio_err, "subject=", X509_REQ_get_subject_name(req), nmflag);
|
||||||
|
|
||||||
if ((x=X509_new()) == NULL) goto end;
|
if ((x=X509_new()) == NULL) goto end;
|
||||||
ci=x->cert_info;
|
|
||||||
|
|
||||||
if (sno == NULL)
|
if (sno == NULL)
|
||||||
{
|
{
|
||||||
@@ -626,7 +652,7 @@ bad:
|
|||||||
if (!X509_set_subject_name(x,req->req_info->subject)) goto end;
|
if (!X509_set_subject_name(x,req->req_info->subject)) goto end;
|
||||||
|
|
||||||
X509_gmtime_adj(X509_get_notBefore(x),0);
|
X509_gmtime_adj(X509_get_notBefore(x),0);
|
||||||
X509_gmtime_adj(X509_get_notAfter(x),(long)60*60*24*days);
|
X509_time_adj_ex(X509_get_notAfter(x),days, 0, NULL);
|
||||||
|
|
||||||
pkey = X509_REQ_get_pubkey(req);
|
pkey = X509_REQ_get_pubkey(req);
|
||||||
X509_set_pubkey(x,pkey);
|
X509_set_pubkey(x,pkey);
|
||||||
@@ -738,14 +764,14 @@ bad:
|
|||||||
else if ((email == i) || (ocsp_uri == i))
|
else if ((email == i) || (ocsp_uri == i))
|
||||||
{
|
{
|
||||||
int j;
|
int j;
|
||||||
STACK_OF(STRING) *emlst;
|
STACK_OF(OPENSSL_STRING) *emlst;
|
||||||
if (email == i)
|
if (email == i)
|
||||||
emlst = X509_get1_email(x);
|
emlst = X509_get1_email(x);
|
||||||
else
|
else
|
||||||
emlst = X509_get1_ocsp(x);
|
emlst = X509_get1_ocsp(x);
|
||||||
for (j = 0; j < sk_STRING_num(emlst); j++)
|
for (j = 0; j < sk_OPENSSL_STRING_num(emlst); j++)
|
||||||
BIO_printf(STDout, "%s\n",
|
BIO_printf(STDout, "%s\n",
|
||||||
sk_STRING_value(emlst, j));
|
sk_OPENSSL_STRING_value(emlst, j));
|
||||||
X509_email_free(emlst);
|
X509_email_free(emlst);
|
||||||
}
|
}
|
||||||
else if (aliasout == i)
|
else if (aliasout == i)
|
||||||
@@ -759,10 +785,22 @@ bad:
|
|||||||
{
|
{
|
||||||
BIO_printf(STDout,"%08lx\n",X509_subject_name_hash(x));
|
BIO_printf(STDout,"%08lx\n",X509_subject_name_hash(x));
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
else if (subject_hash_old == i)
|
||||||
|
{
|
||||||
|
BIO_printf(STDout,"%08lx\n",X509_subject_name_hash_old(x));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
else if (issuer_hash == i)
|
else if (issuer_hash == i)
|
||||||
{
|
{
|
||||||
BIO_printf(STDout,"%08lx\n",X509_issuer_name_hash(x));
|
BIO_printf(STDout,"%08lx\n",X509_issuer_name_hash(x));
|
||||||
}
|
}
|
||||||
|
#ifndef OPENSSL_NO_MD5
|
||||||
|
else if (issuer_hash_old == i)
|
||||||
|
{
|
||||||
|
BIO_printf(STDout,"%08lx\n",X509_issuer_name_hash_old(x));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
else if (pprint == i)
|
else if (pprint == i)
|
||||||
{
|
{
|
||||||
X509_PURPOSE *ptmp;
|
X509_PURPOSE *ptmp;
|
||||||
@@ -874,7 +912,7 @@ bad:
|
|||||||
}
|
}
|
||||||
else if (text == i)
|
else if (text == i)
|
||||||
{
|
{
|
||||||
X509_print_ex(out,x,nmflag, certflag);
|
X509_print_ex(STDout,x,nmflag, certflag);
|
||||||
}
|
}
|
||||||
else if (startdate == i)
|
else if (startdate == i)
|
||||||
{
|
{
|
||||||
@@ -943,7 +981,8 @@ bad:
|
|||||||
|
|
||||||
assert(need_rand);
|
assert(need_rand);
|
||||||
if (!x509_certify(ctx,CAfile,digest,x,xca,
|
if (!x509_certify(ctx,CAfile,digest,x,xca,
|
||||||
CApkey, CAserial,CA_createserial,days, clrext,
|
CApkey, sigopts,
|
||||||
|
CAserial,CA_createserial,days, clrext,
|
||||||
extconf, extsect, sno))
|
extconf, extsect, sno))
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
@@ -960,7 +999,7 @@ bad:
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
pk=load_key(bio_err,
|
pk=load_key(bio_err,
|
||||||
keyfile, FORMAT_PEM, 0,
|
keyfile, keyformat, 0,
|
||||||
passin, e, "request key");
|
passin, e, "request key");
|
||||||
if (pk == NULL) goto end;
|
if (pk == NULL) goto end;
|
||||||
}
|
}
|
||||||
@@ -1054,6 +1093,8 @@ end:
|
|||||||
X509_free(xca);
|
X509_free(xca);
|
||||||
EVP_PKEY_free(Upkey);
|
EVP_PKEY_free(Upkey);
|
||||||
EVP_PKEY_free(CApkey);
|
EVP_PKEY_free(CApkey);
|
||||||
|
if (sigopts)
|
||||||
|
sk_OPENSSL_STRING_free(sigopts);
|
||||||
X509_REQ_free(rq);
|
X509_REQ_free(rq);
|
||||||
ASN1_INTEGER_free(sno);
|
ASN1_INTEGER_free(sno);
|
||||||
sk_ASN1_OBJECT_pop_free(trust, ASN1_OBJECT_free);
|
sk_ASN1_OBJECT_pop_free(trust, ASN1_OBJECT_free);
|
||||||
@@ -1104,8 +1145,11 @@ static ASN1_INTEGER *x509_load_serial(char *CAfile, char *serialfile, int create
|
|||||||
}
|
}
|
||||||
|
|
||||||
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,
|
||||||
X509 *x, X509 *xca, EVP_PKEY *pkey, char *serialfile, int create,
|
X509 *x, X509 *xca, EVP_PKEY *pkey,
|
||||||
int days, int clrext, CONF *conf, char *section, ASN1_INTEGER *sno)
|
STACK_OF(OPENSSL_STRING) *sigopts,
|
||||||
|
char *serialfile, int create,
|
||||||
|
int days, int clrext, CONF *conf, char *section,
|
||||||
|
ASN1_INTEGER *sno)
|
||||||
{
|
{
|
||||||
int ret=0;
|
int ret=0;
|
||||||
ASN1_INTEGER *bs=NULL;
|
ASN1_INTEGER *bs=NULL;
|
||||||
@@ -1130,6 +1174,7 @@ static int x509_certify(X509_STORE *ctx, char *CAfile, const EVP_MD *digest,
|
|||||||
/* 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. */
|
||||||
X509_STORE_CTX_set_cert(&xsc,x);
|
X509_STORE_CTX_set_cert(&xsc,x);
|
||||||
|
X509_STORE_CTX_set_flags(&xsc, X509_V_FLAG_CHECK_SS_SIGNATURE);
|
||||||
if (!reqfile && X509_verify_cert(&xsc) <= 0)
|
if (!reqfile && X509_verify_cert(&xsc) <= 0)
|
||||||
goto end;
|
goto end;
|
||||||
|
|
||||||
@@ -1146,7 +1191,7 @@ static int x509_certify(X509_STORE *ctx, char *CAfile, const EVP_MD *digest,
|
|||||||
goto end;
|
goto end;
|
||||||
|
|
||||||
/* hardwired expired */
|
/* hardwired expired */
|
||||||
if (X509_gmtime_adj(X509_get_notAfter(x),(long)60*60*24*days) == NULL)
|
if (X509_time_adj_ex(X509_get_notAfter(x),days, 0, NULL) == NULL)
|
||||||
goto end;
|
goto end;
|
||||||
|
|
||||||
if (clrext)
|
if (clrext)
|
||||||
@@ -1163,7 +1208,8 @@ static int x509_certify(X509_STORE *ctx, char *CAfile, const EVP_MD *digest,
|
|||||||
if (!X509V3_EXT_add_nconf(conf, &ctx2, section, x)) goto end;
|
if (!X509V3_EXT_add_nconf(conf, &ctx2, section, x)) goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!X509_sign(x,pkey,digest)) goto end;
|
if (!do_X509_sign(bio_err, x, pkey, digest, sigopts))
|
||||||
|
goto end;
|
||||||
ret=1;
|
ret=1;
|
||||||
end:
|
end:
|
||||||
X509_STORE_CTX_cleanup(&xsc);
|
X509_STORE_CTX_cleanup(&xsc);
|
||||||
|
|||||||
124
config
124
config
@@ -48,10 +48,10 @@ done
|
|||||||
|
|
||||||
# First get uname entries that we use below
|
# First get uname entries that we use below
|
||||||
|
|
||||||
MACHINE=`(uname -m) 2>/dev/null` || MACHINE="unknown"
|
[ "$MACHINE" ] || MACHINE=`(uname -m) 2>/dev/null` || MACHINE="unknown"
|
||||||
RELEASE=`(uname -r) 2>/dev/null` || RELEASE="unknown"
|
[ "$RELEASE" ] || RELEASE=`(uname -r) 2>/dev/null` || RELEASE="unknown"
|
||||||
SYSTEM=`(uname -s) 2>/dev/null` || SYSTEM="unknown"
|
[ "$SYSTEM" ] || SYSTEM=`(uname -s) 2>/dev/null` || SYSTEM="unknown"
|
||||||
VERSION=`(uname -v) 2>/dev/null` || VERSION="unknown"
|
[ "$BUILD" ] || VERSION=`(uname -v) 2>/dev/null` || VERSION="unknown"
|
||||||
|
|
||||||
|
|
||||||
# Now test for ISC and SCO, since it is has a braindamaged uname.
|
# Now test for ISC and SCO, since it is has a braindamaged uname.
|
||||||
@@ -370,6 +370,10 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${MACHINE}" in
|
|||||||
NONSTOP_KERNEL*)
|
NONSTOP_KERNEL*)
|
||||||
echo "nsr-tandem-nsk"; exit 0;
|
echo "nsr-tandem-nsk"; exit 0;
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
vxworks*)
|
||||||
|
echo "${MACHINE}-whatever-vxworks"; exit 0;
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -407,23 +411,18 @@ exit 0
|
|||||||
# this is where the translation occurs into SSLeay terms
|
# this is where the translation occurs into SSLeay terms
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
|
|
||||||
GCCVER=`(gcc -dumpversion) 2>/dev/null`
|
|
||||||
if [ "$GCCVER" != "" ]; then
|
|
||||||
# then strip off whatever prefix egcs prepends the number with...
|
|
||||||
# Hopefully, this will work for any future prefixes as well.
|
|
||||||
GCCVER=`echo $GCCVER | LC_ALL=C sed 's/^[a-zA-Z]*\-//'`
|
|
||||||
# Since gcc 3.1 gcc --version behaviour has changed. gcc -dumpversion
|
|
||||||
# does give us what we want though, so we use that. We just just the
|
|
||||||
# major and minor version numbers.
|
|
||||||
# peak single digit before and after first dot, e.g. 2.95.1 gives 29
|
|
||||||
GCCVER=`echo $GCCVER | sed 's/\([0-9]\)\.\([0-9]\).*/\1\2/'`
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Only set CC if not supplied already
|
# Only set CC if not supplied already
|
||||||
if [ -z "$CC" ]; then
|
if [ -z "$CROSS_COMPILE$CC" ]; then
|
||||||
# figure out if gcc is available and if so we use it otherwise
|
GCCVER=`sh -c "gcc -dumpversion" 2>/dev/null`
|
||||||
# we fallback to whatever cc does on the system
|
|
||||||
if [ "$GCCVER" != "" ]; then
|
if [ "$GCCVER" != "" ]; then
|
||||||
|
# then strip off whatever prefix egcs prepends the number with...
|
||||||
|
# Hopefully, this will work for any future prefixes as well.
|
||||||
|
GCCVER=`echo $GCCVER | LC_ALL=C sed 's/^[a-zA-Z]*\-//'`
|
||||||
|
# Since gcc 3.1 gcc --version behaviour has changed. gcc -dumpversion
|
||||||
|
# does give us what we want though, so we use that. We just just the
|
||||||
|
# major and minor version numbers.
|
||||||
|
# peak single digit before and after first dot, e.g. 2.95.1 gives 29
|
||||||
|
GCCVER=`echo $GCCVER | sed 's/\([0-9]\)\.\([0-9]\).*/\1\2/'`
|
||||||
CC=gcc
|
CC=gcc
|
||||||
else
|
else
|
||||||
CC=cc
|
CC=cc
|
||||||
@@ -496,6 +495,12 @@ echo Operating system: $GUESSOS
|
|||||||
# script above so we end up with values in vars but that would take
|
# script above so we end up with values in vars but that would take
|
||||||
# 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
|
||||||
|
uClinux*64*)
|
||||||
|
OUT=uClinux-dist64
|
||||||
|
;;
|
||||||
|
uClinux*)
|
||||||
|
OUT=uClinux-dist
|
||||||
|
;;
|
||||||
mips2-sgi-irix)
|
mips2-sgi-irix)
|
||||||
CPU=`(hinv -t cpu) 2>/dev/null | head -1 | 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}
|
||||||
@@ -533,7 +538,7 @@ case "$GUESSOS" in
|
|||||||
ppc-apple-rhapsody) OUT="rhapsody-ppc-cc" ;;
|
ppc-apple-rhapsody) OUT="rhapsody-ppc-cc" ;;
|
||||||
ppc-apple-darwin*)
|
ppc-apple-darwin*)
|
||||||
ISA64=`(sysctl -n hw.optional.64bitops) 2>/dev/null`
|
ISA64=`(sysctl -n hw.optional.64bitops) 2>/dev/null`
|
||||||
if [ "$ISA64" = "1" ]; then
|
if [ "$ISA64" = "1" -a -z "$KERNEL_BITS" ]; 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 darwin64-ppc-cc' *manually*."
|
echo " invoke './Configure darwin64-ppc-cc' *manually*."
|
||||||
if [ "$TEST" = "false" -a -t 1 ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
@@ -541,10 +546,14 @@ case "$GUESSOS" in
|
|||||||
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
OUT="darwin-ppc-cc" ;;
|
if [ "$ISA64" = "1" -a "$KERNEL_BITS" = "64" ]; then
|
||||||
|
OUT="darwin64-ppc-cc"
|
||||||
|
else
|
||||||
|
OUT="darwin-ppc-cc"
|
||||||
|
fi ;;
|
||||||
i?86-apple-darwin*)
|
i?86-apple-darwin*)
|
||||||
ISA64=`(sysctl -n hw.optional.x86_64) 2>/dev/null`
|
ISA64=`(sysctl -n hw.optional.x86_64) 2>/dev/null`
|
||||||
if [ "$ISA64" = "1" ]; then
|
if [ "$ISA64" = "1" -a -z "$KERNEL_BITS" ]; 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 darwin64-x86_64-cc' *manually*."
|
echo " invoke './Configure darwin64-x86_64-cc' *manually*."
|
||||||
if [ "$TEST" = "false" -a -t 1 ]; then
|
if [ "$TEST" = "false" -a -t 1 ]; then
|
||||||
@@ -552,7 +561,17 @@ case "$GUESSOS" in
|
|||||||
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
OUT="darwin-i386-cc" ;;
|
if [ "$ISA64" = "1" -a "$KERNEL_BITS" = "64" ]; then
|
||||||
|
OUT="darwin64-x86_64-cc"
|
||||||
|
else
|
||||||
|
OUT="darwin-i386-cc"
|
||||||
|
fi ;;
|
||||||
|
armv6+7-*-iphoneos)
|
||||||
|
options="$options -arch%20armv6 -arch%20armv7"
|
||||||
|
OUT="iphoneos-cross" ;;
|
||||||
|
*-*-iphoneos)
|
||||||
|
options="$options -arch%20${MACHINE}"
|
||||||
|
OUT="iphoneos-cross" ;;
|
||||||
alpha-*-linux2)
|
alpha-*-linux2)
|
||||||
ISA=`awk '/cpu model/{print$4;exit(0);}' /proc/cpuinfo`
|
ISA=`awk '/cpu model/{print$4;exit(0);}' /proc/cpuinfo`
|
||||||
case ${ISA:-generic} in
|
case ${ISA:-generic} in
|
||||||
@@ -577,6 +596,11 @@ case "$GUESSOS" in
|
|||||||
OUT="linux-ppc"
|
OUT="linux-ppc"
|
||||||
;;
|
;;
|
||||||
ppc-*-linux2) OUT="linux-ppc" ;;
|
ppc-*-linux2) OUT="linux-ppc" ;;
|
||||||
|
ppc60x-*-vxworks*) OUT="vxworks-ppc60x" ;;
|
||||||
|
ppcgen-*-vxworks*) OUT="vxworks-ppcgen" ;;
|
||||||
|
pentium-*-vxworks*) OUT="vxworks-pentium" ;;
|
||||||
|
simlinux-*-vxworks*) OUT="vxworks-simlinux" ;;
|
||||||
|
mips-*-vxworks*) OUT="vxworks-mips";;
|
||||||
ia64-*-linux?) OUT="linux-ia64" ;;
|
ia64-*-linux?) OUT="linux-ia64" ;;
|
||||||
sparc64-*-linux2)
|
sparc64-*-linux2)
|
||||||
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"
|
||||||
@@ -618,12 +642,24 @@ case "$GUESSOS" in
|
|||||||
options="$options -DB_ENDIAN -mschedule=$CPUSCHEDULE -march=$CPUARCH"
|
options="$options -DB_ENDIAN -mschedule=$CPUSCHEDULE -march=$CPUARCH"
|
||||||
OUT="linux-generic32" ;;
|
OUT="linux-generic32" ;;
|
||||||
armv[1-3]*-*-linux2) OUT="linux-generic32" ;;
|
armv[1-3]*-*-linux2) OUT="linux-generic32" ;;
|
||||||
|
armv[7-9]*-*-linux2) OUT="linux-armv4"; options="$options -march=armv7-a" ;;
|
||||||
arm*-*-linux2) OUT="linux-armv4" ;;
|
arm*-*-linux2) OUT="linux-armv4" ;;
|
||||||
sh*b-*-linux2) OUT="linux-generic32"; options="$options -DB_ENDIAN" ;;
|
sh*b-*-linux2) OUT="linux-generic32"; options="$options -DB_ENDIAN" ;;
|
||||||
sh*-*-linux2) OUT="linux-generic32"; options="$options -DL_ENDIAN" ;;
|
sh*-*-linux2) OUT="linux-generic32"; options="$options -DL_ENDIAN" ;;
|
||||||
m68k*-*-linux2) OUT="linux-generic32"; options="$options -DB_ENDIAN" ;;
|
m68k*-*-linux2) OUT="linux-generic32"; options="$options -DB_ENDIAN" ;;
|
||||||
s390-*-linux2) OUT="linux-generic32"; options="$options -DB_ENDIAN" ;;
|
s390-*-linux2) OUT="linux-generic32"; options="$options -DB_ENDIAN" ;;
|
||||||
s390x-*-linux2) OUT="linux-s390x" ;;
|
s390x-*-linux2)
|
||||||
|
# To be uncommented when glibc bug is fixed, see Configure...
|
||||||
|
#if egrep -e '^features.* highgprs' /proc/cpuinfo >/dev/null ; then
|
||||||
|
# echo "WARNING! If you wish to build \"highgprs\" 32-bit library, then you"
|
||||||
|
# echo " have to invoke './Configure linux32-s390x' *manually*."
|
||||||
|
# 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
|
||||||
|
#fi
|
||||||
|
OUT="linux64-s390x"
|
||||||
|
;;
|
||||||
x86_64-*-linux?) OUT="linux-x86_64" ;;
|
x86_64-*-linux?) OUT="linux-x86_64" ;;
|
||||||
*86-*-linux2) OUT="linux-elf"
|
*86-*-linux2) OUT="linux-elf"
|
||||||
if [ "$GCCVER" -gt 28 ]; then
|
if [ "$GCCVER" -gt 28 ]; then
|
||||||
@@ -642,7 +678,7 @@ case "$GUESSOS" in
|
|||||||
sun4[uv]*-*-solaris2)
|
sun4[uv]*-*-solaris2)
|
||||||
OUT="solaris-sparcv9-$CC"
|
OUT="solaris-sparcv9-$CC"
|
||||||
ISA64=`(isalist) 2>/dev/null | grep sparcv9`
|
ISA64=`(isalist) 2>/dev/null | grep sparcv9`
|
||||||
if [ "$ISA64" != "" ]; then
|
if [ "$ISA64" != "" -a "$KERNEL_BITS" = "" ]; then
|
||||||
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*."
|
||||||
@@ -672,13 +708,16 @@ case "$GUESSOS" in
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if [ "$ISA64" != "" -a "$KERNEL_BITS" = "64" ]; then
|
||||||
|
OUT="solaris64-sparcv9-$CC"
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
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)
|
*86*-*-solaris2)
|
||||||
ISA64=`(isalist) 2>/dev/null | grep amd64`
|
ISA64=`(isalist) 2>/dev/null | grep amd64`
|
||||||
if [ "$ISA64" != "" ]; then
|
if [ "$ISA64" != "" -a ${KERNEL_BITS:-64} -eq 64 ]; then
|
||||||
OUT="solaris64-x86_64-$CC"
|
OUT="solaris64-x86_64-$CC"
|
||||||
else
|
else
|
||||||
OUT="solaris-x86-$CC"
|
OUT="solaris-x86-$CC"
|
||||||
@@ -700,7 +739,7 @@ case "$GUESSOS" in
|
|||||||
libc=/usr/lib/libc.so
|
libc=/usr/lib/libc.so
|
||||||
else # OpenBSD
|
else # OpenBSD
|
||||||
# ld searches for highest libc.so.* and so do we
|
# ld searches for highest libc.so.* and so do we
|
||||||
libc=`(ls /usr/lib/libc.so.* | tail -1) 2>/dev/null`
|
libc=`(ls /usr/lib/libc.so.* /lib/libc.so.* | tail -1) 2>/dev/null`
|
||||||
fi
|
fi
|
||||||
case "`(file -L $libc) 2>/dev/null`" in
|
case "`(file -L $libc) 2>/dev/null`" in
|
||||||
*ELF*) OUT="BSD-x86-elf" ;;
|
*ELF*) OUT="BSD-x86-elf" ;;
|
||||||
@@ -730,20 +769,17 @@ case "$GUESSOS" in
|
|||||||
if [ $CC = "gcc" -a $GCC_BITS = "64" ]; then
|
if [ $CC = "gcc" -a $GCC_BITS = "64" ]; then
|
||||||
OUT="hpux64-parisc2-gcc"
|
OUT="hpux64-parisc2-gcc"
|
||||||
fi
|
fi
|
||||||
KERNEL_BITS=`(getconf KERNEL_BITS) 2>/dev/null`
|
[ "$KERNEL_BITS" ] || KERNEL_BITS=`(getconf KERNEL_BITS) 2>/dev/null`
|
||||||
KERNEL_BITS=${KERNEL_BITS:-32}
|
KERNEL_BITS=${KERNEL_BITS:-32}
|
||||||
CPU_VERSION=`(getconf CPU_VERSION) 2>/dev/null`
|
CPU_VERSION=`(getconf CPU_VERSION) 2>/dev/null`
|
||||||
CPU_VERSION=${CPU_VERSION:-0}
|
CPU_VERSION=${CPU_VERSION:-0}
|
||||||
# See <sys/unistd.h> for further info on CPU_VERSION.
|
# See <sys/unistd.h> for further info on CPU_VERSION.
|
||||||
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."
|
if [ $KERNEL_BITS -eq 64 -a "$CC" = "cc" ]; then
|
||||||
echo " If you wish to build 32-bit library, the you have to"
|
OUT="hpux64-ia64-cc"
|
||||||
echo " invoke './Configure hpux-ia64-cc' *manually*."
|
else
|
||||||
if [ "$TEST" = "false" -a -t 1 ]; then
|
OUT="hpux-ia64-cc"
|
||||||
echo " You have about 5 seconds to press Ctrl-C to abort."
|
fi
|
||||||
(trap "stty `stty -g`" 2 0; stty -icanon min 0 time 50; read waste) <&1
|
|
||||||
fi
|
|
||||||
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
|
||||||
OUT=${OUT:-"hpux-parisc2-${CC}"}
|
OUT=${OUT:-"hpux-parisc2-${CC}"}
|
||||||
if [ $KERNEL_BITS -eq 64 -a "$CC" = "cc" ]; then
|
if [ $KERNEL_BITS -eq 64 -a "$CC" = "cc" ]; then
|
||||||
@@ -764,11 +800,15 @@ case "$GUESSOS" in
|
|||||||
options="$options -D_REENTRANT" ;;
|
options="$options -D_REENTRANT" ;;
|
||||||
*-hpux) OUT="hpux-parisc-$CC" ;;
|
*-hpux) OUT="hpux-parisc-$CC" ;;
|
||||||
*-aix)
|
*-aix)
|
||||||
KERNEL_BITS=`(getconf KERNEL_BITMODE) 2>/dev/null`
|
[ "$KERNEL_BITS" ] || KERNEL_BITS=`(getconf KERNEL_BITMODE) 2>/dev/null`
|
||||||
KERNEL_BITS=${KERNEL_BITS:-32}
|
KERNEL_BITS=${KERNEL_BITS:-32}
|
||||||
OBJECT_MODE=${OBJECT_MODE:-32}
|
OBJECT_MODE=${OBJECT_MODE:-32}
|
||||||
if [ "$CC" = "gcc" ]; then
|
if [ "$CC" = "gcc" ]; then
|
||||||
OUT="aix-gcc"
|
OUT="aix-gcc"
|
||||||
|
if [ $OBJECT_MODE -eq 64 ]; then
|
||||||
|
echo 'Your $OBJECT_MODE was found to be set to 64'
|
||||||
|
OUT="aix64-gcc"
|
||||||
|
fi
|
||||||
elif [ $OBJECT_MODE -eq 64 ]; then
|
elif [ $OBJECT_MODE -eq 64 ]; then
|
||||||
echo 'Your $OBJECT_MODE was found to be set to 64'
|
echo 'Your $OBJECT_MODE was found to be set to 64'
|
||||||
OUT="aix64-cc"
|
OUT="aix64-cc"
|
||||||
@@ -798,6 +838,10 @@ case "$GUESSOS" in
|
|||||||
j90-cray-unicos) OUT="cray-j90" ;;
|
j90-cray-unicos) OUT="cray-j90" ;;
|
||||||
nsr-tandem-nsk) OUT="tandem-c89" ;;
|
nsr-tandem-nsk) OUT="tandem-c89" ;;
|
||||||
beos-*) OUT="$GUESSOS" ;;
|
beos-*) OUT="$GUESSOS" ;;
|
||||||
|
x86pc-*-qnx6) OUT="QNX6-i386" ;;
|
||||||
|
*-*-qnx6) OUT="QNX6" ;;
|
||||||
|
x86-*-android|i?86-*-android) OUT="android-x86" ;;
|
||||||
|
armv[7-9]*-*-android) OUT="android-armv7" ;;
|
||||||
*) OUT=`echo $GUESSOS | awk -F- '{print $3}'`;;
|
*) OUT=`echo $GUESSOS | awk -F- '{print $3}'`;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@@ -813,6 +857,12 @@ esac
|
|||||||
# options="$options -DATALLA"
|
# options="$options -DATALLA"
|
||||||
#fi
|
#fi
|
||||||
|
|
||||||
|
if expr "$options" : '.*no\-asm' > /dev/null; then :; else
|
||||||
|
sh -c "$CROSS_COMPILE${CC:-gcc} -Wa,--help -c -o /tmp/null.$$.o -x assembler /dev/null && rm /tmp/null.$$.o" 2>&1 | \
|
||||||
|
grep \\--noexecstack >/dev/null && \
|
||||||
|
options="$options -Wa,--noexecstack"
|
||||||
|
fi
|
||||||
|
|
||||||
# gcc < 2.8 does not support -march=ultrasparc
|
# gcc < 2.8 does not support -march=ultrasparc
|
||||||
if [ "$OUT" = solaris-sparcv9-gcc -a $GCCVER -lt 28 ]
|
if [ "$OUT" = solaris-sparcv9-gcc -a $GCCVER -lt 28 ]
|
||||||
then
|
then
|
||||||
|
|||||||
@@ -40,22 +40,18 @@
|
|||||||
#ifndef LPDIR_H
|
#ifndef LPDIR_H
|
||||||
#include "LPdir.h"
|
#include "LPdir.h"
|
||||||
#endif
|
#endif
|
||||||
|
#include "vms_rms.h"
|
||||||
|
|
||||||
/* Because some compiler options hide this macor */
|
/* Some compiler options hide EVMSERR. */
|
||||||
#ifndef EVMSERR
|
#ifndef EVMSERR
|
||||||
#define EVMSERR 65535 /* error for non-translatable VMS errors */
|
# define EVMSERR 65535 /* error for non-translatable VMS errors */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
struct LP_dir_context_st
|
struct LP_dir_context_st
|
||||||
{
|
{
|
||||||
unsigned long VMS_context;
|
unsigned long VMS_context;
|
||||||
#ifdef NAML$C_MAXRSS
|
char filespec[ NAMX_MAXRSS+ 1];
|
||||||
char filespec[NAML$C_MAXRSS+1];
|
char result[ NAMX_MAXRSS+ 1];
|
||||||
char result[NAML$C_MAXRSS+1];
|
|
||||||
#else
|
|
||||||
char filespec[256];
|
|
||||||
char result[256];
|
|
||||||
#endif
|
|
||||||
struct dsc$descriptor_d filespec_dsc;
|
struct dsc$descriptor_d filespec_dsc;
|
||||||
struct dsc$descriptor_d result_dsc;
|
struct dsc$descriptor_d result_dsc;
|
||||||
};
|
};
|
||||||
@@ -66,6 +62,16 @@ const char *LP_find_file(LP_DIR_CTX **ctx, const char *directory)
|
|||||||
char *p, *r;
|
char *p, *r;
|
||||||
size_t l;
|
size_t l;
|
||||||
unsigned long flags = 0;
|
unsigned long flags = 0;
|
||||||
|
|
||||||
|
/* Arrange 32-bit pointer to (copied) string storage, if needed. */
|
||||||
|
#if __INITIAL_POINTER_SIZE == 64
|
||||||
|
# pragma pointer_size save
|
||||||
|
# pragma pointer_size 32
|
||||||
|
char *ctx_filespec_32p;
|
||||||
|
# pragma pointer_size restore
|
||||||
|
char ctx_filespec_32[ NAMX_MAXRSS+ 1];
|
||||||
|
#endif /* __INITIAL_POINTER_SIZE == 64 */
|
||||||
|
|
||||||
#ifdef NAML$C_MAXRSS
|
#ifdef NAML$C_MAXRSS
|
||||||
flags |= LIB$M_FIL_LONG_NAMES;
|
flags |= LIB$M_FIL_LONG_NAMES;
|
||||||
#endif
|
#endif
|
||||||
@@ -93,13 +99,7 @@ const char *LP_find_file(LP_DIR_CTX **ctx, const char *directory)
|
|||||||
|
|
||||||
filespeclen += 4; /* "*.*;" */
|
filespeclen += 4; /* "*.*;" */
|
||||||
|
|
||||||
if (filespeclen >
|
if (filespeclen > NAMX_MAXRSS)
|
||||||
#ifdef NAML$C_MAXRSS
|
|
||||||
NAML$C_MAXRSS
|
|
||||||
#else
|
|
||||||
255
|
|
||||||
#endif
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
errno = ENAMETOOLONG;
|
errno = ENAMETOOLONG;
|
||||||
return 0;
|
return 0;
|
||||||
@@ -115,14 +115,21 @@ const char *LP_find_file(LP_DIR_CTX **ctx, const char *directory)
|
|||||||
|
|
||||||
strcpy((*ctx)->filespec,directory);
|
strcpy((*ctx)->filespec,directory);
|
||||||
strcat((*ctx)->filespec,"*.*;");
|
strcat((*ctx)->filespec,"*.*;");
|
||||||
|
|
||||||
|
/* Arrange 32-bit pointer to (copied) string storage, if needed. */
|
||||||
|
#if __INITIAL_POINTER_SIZE == 64
|
||||||
|
# define CTX_FILESPEC ctx_filespec_32p
|
||||||
|
/* Copy the file name to storage with a 32-bit pointer. */
|
||||||
|
ctx_filespec_32p = ctx_filespec_32;
|
||||||
|
strcpy( ctx_filespec_32p, (*ctx)->filespec);
|
||||||
|
#else /* __INITIAL_POINTER_SIZE == 64 */
|
||||||
|
# define CTX_FILESPEC (*ctx)->filespec
|
||||||
|
#endif /* __INITIAL_POINTER_SIZE == 64 [else] */
|
||||||
|
|
||||||
(*ctx)->filespec_dsc.dsc$w_length = filespeclen;
|
(*ctx)->filespec_dsc.dsc$w_length = filespeclen;
|
||||||
(*ctx)->filespec_dsc.dsc$b_dtype = DSC$K_DTYPE_T;
|
(*ctx)->filespec_dsc.dsc$b_dtype = DSC$K_DTYPE_T;
|
||||||
(*ctx)->filespec_dsc.dsc$b_class = DSC$K_CLASS_S;
|
(*ctx)->filespec_dsc.dsc$b_class = DSC$K_CLASS_S;
|
||||||
(*ctx)->filespec_dsc.dsc$a_pointer = (*ctx)->filespec;
|
(*ctx)->filespec_dsc.dsc$a_pointer = CTX_FILESPEC;
|
||||||
(*ctx)->result_dsc.dsc$w_length = 0;
|
|
||||||
(*ctx)->result_dsc.dsc$b_dtype = DSC$K_DTYPE_T;
|
|
||||||
(*ctx)->result_dsc.dsc$b_class = DSC$K_CLASS_D;
|
|
||||||
(*ctx)->result_dsc.dsc$a_pointer = 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
(*ctx)->result_dsc.dsc$w_length = 0;
|
(*ctx)->result_dsc.dsc$w_length = 0;
|
||||||
|
|||||||
@@ -5,9 +5,9 @@
|
|||||||
DIR= crypto
|
DIR= crypto
|
||||||
TOP= ..
|
TOP= ..
|
||||||
CC= cc
|
CC= cc
|
||||||
INCLUDE= -I. -I$(TOP) -I../include
|
INCLUDE= -I. -I$(TOP) -I../include $(ZLIB_INCLUDE)
|
||||||
# INCLUDES targets sudbirs!
|
# INCLUDES targets sudbirs!
|
||||||
INCLUDES= -I.. -I../.. -I../asn1 -I../evp -I../../include
|
INCLUDES= -I.. -I../.. -I../modes -I../asn1 -I../evp -I../../include $(ZLIB_INCLUDE)
|
||||||
CFLAG= -g
|
CFLAG= -g
|
||||||
MAKEDEPPROG= makedepend
|
MAKEDEPPROG= makedepend
|
||||||
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
MAKEDEPEND= $(TOP)/util/domd $(TOP) -MD $(MAKEDEPPROG)
|
||||||
@@ -34,8 +34,10 @@ 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 cpt_err.c ebcdic.c uid.c o_time.c o_str.c o_dir.c
|
LIBSRC= cryptlib.c mem.c mem_clr.c mem_dbg.c cversion.c ex_data.c cpt_err.c \
|
||||||
LIBOBJ= cryptlib.o mem.o mem_dbg.o cversion.o ex_data.o cpt_err.o ebcdic.o uid.o o_time.o o_str.o o_dir.o $(CPUID_OBJ)
|
ebcdic.c uid.c o_time.c o_str.c o_dir.c o_fips.c o_init.c fips_ers.c
|
||||||
|
LIBOBJ= cryptlib.o mem.o mem_dbg.o cversion.o ex_data.o cpt_err.o ebcdic.o \
|
||||||
|
uid.o o_time.o o_str.o o_dir.o o_fips.o o_init.o fips_ers.o $(CPUID_OBJ)
|
||||||
|
|
||||||
SRC= $(LIBSRC)
|
SRC= $(LIBSRC)
|
||||||
|
|
||||||
@@ -67,14 +69,17 @@ applink.o: $(TOP)/ms/applink.c
|
|||||||
uplink.o: $(TOP)/ms/uplink.c applink.o
|
uplink.o: $(TOP)/ms/uplink.c applink.o
|
||||||
$(CC) $(CFLAGS) -c -o $@ $(TOP)/ms/uplink.c
|
$(CC) $(CFLAGS) -c -o $@ $(TOP)/ms/uplink.c
|
||||||
|
|
||||||
uplink-cof.s: $(TOP)/ms/uplink.pl
|
uplink-x86.s: $(TOP)/ms/uplink-x86.pl
|
||||||
$(PERL) $(TOP)/ms/uplink.pl coff > $@
|
$(PERL) $(TOP)/ms/uplink-x86.pl $(PERLASM_SCHEME) > $@
|
||||||
|
|
||||||
x86_64cpuid.s: x86_64cpuid.pl
|
x86_64cpuid.s: x86_64cpuid.pl; $(PERL) x86_64cpuid.pl $(PERLASM_SCHEME) > $@
|
||||||
$(PERL) x86_64cpuid.pl $(PERLASM_SCHEME) > $@
|
ia64cpuid.s: ia64cpuid.S; $(CC) $(CFLAGS) -E ia64cpuid.S > $@
|
||||||
ia64cpuid.s: ia64cpuid.S
|
ppccpuid.s: ppccpuid.pl; $(PERL) ppccpuid.pl $(PERLASM_SCHEME) $@
|
||||||
$(CC) $(CFLAGS) -E ia64cpuid.S > $@
|
pariscid.s: pariscid.pl; $(PERL) pariscid.pl $(PERLASM_SCHEME) $@
|
||||||
ppccpuid.s: ppccpuid.pl; $(PERL) ppccpuid.pl $(PERLASM_SCHEME) $@
|
alphacpuid.s: alphacpuid.pl
|
||||||
|
(preproc=/tmp/$$$$.$@; trap "rm $$preproc" INT; \
|
||||||
|
$(PERL) alphacpuid.pl > $$preproc && \
|
||||||
|
$(CC) -E $$preproc > $@ && rm $$preproc)
|
||||||
|
|
||||||
testapps:
|
testapps:
|
||||||
[ -z "$(THIS)" ] || ( if echo $(SDIRS) | fgrep ' des '; \
|
[ -z "$(THIS)" ] || ( if echo $(SDIRS) | fgrep ' des '; \
|
||||||
@@ -100,6 +105,7 @@ lib: $(LIB)
|
|||||||
@touch lib
|
@touch lib
|
||||||
$(LIB): $(LIBOBJ)
|
$(LIB): $(LIBOBJ)
|
||||||
$(AR) $(LIB) $(LIBOBJ)
|
$(AR) $(LIB) $(LIBOBJ)
|
||||||
|
[ -z "$(FIPSLIBDIR)" ] || $(AR) $(LIB) $(FIPSLIBDIR)fipscanister.o
|
||||||
$(RANLIB) $(LIB) || echo Never mind.
|
$(RANLIB) $(LIB) || echo Never mind.
|
||||||
|
|
||||||
shared: buildinf.h lib subdirs
|
shared: buildinf.h lib subdirs
|
||||||
@@ -169,6 +175,7 @@ ex_data.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
|||||||
ex_data.o: ../include/openssl/ossl_typ.h ../include/openssl/safestack.h
|
ex_data.o: ../include/openssl/ossl_typ.h ../include/openssl/safestack.h
|
||||||
ex_data.o: ../include/openssl/stack.h ../include/openssl/symhacks.h cryptlib.h
|
ex_data.o: ../include/openssl/stack.h ../include/openssl/symhacks.h cryptlib.h
|
||||||
ex_data.o: ex_data.c
|
ex_data.o: ex_data.c
|
||||||
|
fips_ers.o: ../include/openssl/opensslconf.h fips_ers.c
|
||||||
mem.o: ../e_os.h ../include/openssl/bio.h ../include/openssl/buffer.h
|
mem.o: ../e_os.h ../include/openssl/bio.h ../include/openssl/buffer.h
|
||||||
mem.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
mem.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
||||||
mem.o: ../include/openssl/err.h ../include/openssl/lhash.h
|
mem.o: ../include/openssl/err.h ../include/openssl/lhash.h
|
||||||
@@ -189,6 +196,19 @@ mem_dbg.o: ../include/openssl/stack.h ../include/openssl/symhacks.h cryptlib.h
|
|||||||
mem_dbg.o: mem_dbg.c
|
mem_dbg.o: mem_dbg.c
|
||||||
o_dir.o: ../e_os.h ../include/openssl/e_os2.h ../include/openssl/opensslconf.h
|
o_dir.o: ../e_os.h ../include/openssl/e_os2.h ../include/openssl/opensslconf.h
|
||||||
o_dir.o: LPdir_unix.c o_dir.c o_dir.h
|
o_dir.o: LPdir_unix.c o_dir.c o_dir.h
|
||||||
|
o_fips.o: ../e_os.h ../include/openssl/bio.h ../include/openssl/buffer.h
|
||||||
|
o_fips.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h
|
||||||
|
o_fips.o: ../include/openssl/err.h ../include/openssl/lhash.h
|
||||||
|
o_fips.o: ../include/openssl/opensslconf.h ../include/openssl/opensslv.h
|
||||||
|
o_fips.o: ../include/openssl/ossl_typ.h ../include/openssl/safestack.h
|
||||||
|
o_fips.o: ../include/openssl/stack.h ../include/openssl/symhacks.h cryptlib.h
|
||||||
|
o_fips.o: o_fips.c
|
||||||
|
o_init.o: ../e_os.h ../include/openssl/bio.h ../include/openssl/crypto.h
|
||||||
|
o_init.o: ../include/openssl/e_os2.h ../include/openssl/err.h
|
||||||
|
o_init.o: ../include/openssl/lhash.h ../include/openssl/opensslconf.h
|
||||||
|
o_init.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h
|
||||||
|
o_init.o: ../include/openssl/safestack.h ../include/openssl/stack.h
|
||||||
|
o_init.o: ../include/openssl/symhacks.h o_init.c
|
||||||
o_str.o: ../e_os.h ../include/openssl/e_os2.h ../include/openssl/opensslconf.h
|
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_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
|
||||||
|
|||||||
@@ -50,9 +50,21 @@ aes-ia64.s: asm/aes-ia64.S
|
|||||||
|
|
||||||
aes-586.s: asm/aes-586.pl ../perlasm/x86asm.pl
|
aes-586.s: asm/aes-586.pl ../perlasm/x86asm.pl
|
||||||
$(PERL) asm/aes-586.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
|
$(PERL) asm/aes-586.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
|
||||||
|
vpaes-x86.s: asm/vpaes-x86.pl ../perlasm/x86asm.pl
|
||||||
|
$(PERL) asm/vpaes-x86.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
|
||||||
|
aesni-x86.s: asm/aesni-x86.pl ../perlasm/x86asm.pl
|
||||||
|
$(PERL) asm/aesni-x86.pl $(PERLASM_SCHEME) $(CFLAGS) $(PROCESSOR) > $@
|
||||||
|
|
||||||
aes-x86_64.s: asm/aes-x86_64.pl
|
aes-x86_64.s: asm/aes-x86_64.pl
|
||||||
$(PERL) asm/aes-x86_64.pl $(PERLASM_SCHEME) > $@
|
$(PERL) asm/aes-x86_64.pl $(PERLASM_SCHEME) > $@
|
||||||
|
vpaes-x86_64.s: asm/vpaes-x86_64.pl
|
||||||
|
$(PERL) asm/vpaes-x86_64.pl $(PERLASM_SCHEME) > $@
|
||||||
|
bsaes-x86_64.s: asm/bsaes-x86_64.pl
|
||||||
|
$(PERL) asm/bsaes-x86_64.pl $(PERLASM_SCHEME) > $@
|
||||||
|
aesni-x86_64.s: asm/aesni-x86_64.pl
|
||||||
|
$(PERL) asm/aesni-x86_64.pl $(PERLASM_SCHEME) > $@
|
||||||
|
aesni-sha1-x86_64.s: asm/aesni-sha1-x86_64.pl
|
||||||
|
$(PERL) asm/aesni-sha1-x86_64.pl $(PERLASM_SCHEME) > $@
|
||||||
|
|
||||||
aes-sparcv9.s: asm/aes-sparcv9.pl
|
aes-sparcv9.s: asm/aes-sparcv9.pl
|
||||||
$(PERL) asm/aes-sparcv9.pl $(CFLAGS) > $@
|
$(PERL) asm/aes-sparcv9.pl $(CFLAGS) > $@
|
||||||
@@ -60,8 +72,15 @@ aes-sparcv9.s: asm/aes-sparcv9.pl
|
|||||||
aes-ppc.s: asm/aes-ppc.pl
|
aes-ppc.s: asm/aes-ppc.pl
|
||||||
$(PERL) asm/aes-ppc.pl $(PERLASM_SCHEME) $@
|
$(PERL) asm/aes-ppc.pl $(PERLASM_SCHEME) $@
|
||||||
|
|
||||||
|
aes-parisc.s: asm/aes-parisc.pl
|
||||||
|
$(PERL) asm/aes-parisc.pl $(PERLASM_SCHEME) $@
|
||||||
|
|
||||||
|
aes-mips.S: asm/aes-mips.pl
|
||||||
|
$(PERL) asm/aes-mips.pl $(PERLASM_SCHEME) $@
|
||||||
|
|
||||||
# GNU make "catch all"
|
# GNU make "catch all"
|
||||||
aes-%.s: asm/aes-%.pl; $(PERL) $< $(CFLAGS) > $@
|
aes-%.S: asm/aes-%.pl; $(PERL) $< $(PERLASM_SCHEME) > $@
|
||||||
|
aes-armv4.o: aes-armv4.S
|
||||||
|
|
||||||
files:
|
files:
|
||||||
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
|
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO
|
||||||
@@ -117,9 +136,11 @@ aes_ige.o: ../../include/openssl/lhash.h ../../include/openssl/opensslconf.h
|
|||||||
aes_ige.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
|
aes_ige.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
|
||||||
aes_ige.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
|
aes_ige.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
|
||||||
aes_ige.o: ../../include/openssl/symhacks.h ../cryptlib.h aes_ige.c aes_locl.h
|
aes_ige.o: ../../include/openssl/symhacks.h ../cryptlib.h aes_ige.c aes_locl.h
|
||||||
aes_misc.o: ../../include/openssl/aes.h ../../include/openssl/e_os2.h
|
aes_misc.o: ../../include/openssl/aes.h ../../include/openssl/crypto.h
|
||||||
aes_misc.o: ../../include/openssl/opensslconf.h
|
aes_misc.o: ../../include/openssl/e_os2.h ../../include/openssl/opensslconf.h
|
||||||
aes_misc.o: ../../include/openssl/opensslv.h aes_locl.h aes_misc.c
|
aes_misc.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
|
||||||
|
aes_misc.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
|
||||||
|
aes_misc.o: ../../include/openssl/symhacks.h aes_locl.h aes_misc.c
|
||||||
aes_ofb.o: ../../include/openssl/aes.h ../../include/openssl/modes.h
|
aes_ofb.o: ../../include/openssl/aes.h ../../include/openssl/modes.h
|
||||||
aes_ofb.o: ../../include/openssl/opensslconf.h aes_ofb.c
|
aes_ofb.o: ../../include/openssl/opensslconf.h aes_ofb.c
|
||||||
aes_wrap.o: ../../e_os.h ../../include/openssl/aes.h
|
aes_wrap.o: ../../e_os.h ../../include/openssl/aes.h
|
||||||
|
|||||||
@@ -90,6 +90,11 @@ int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
|||||||
int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
AES_KEY *key);
|
AES_KEY *key);
|
||||||
|
|
||||||
|
int private_AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||||
|
AES_KEY *key);
|
||||||
|
int private_AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
|
AES_KEY *key);
|
||||||
|
|
||||||
void AES_encrypt(const unsigned char *in, unsigned char *out,
|
void AES_encrypt(const unsigned char *in, unsigned char *out,
|
||||||
const AES_KEY *key);
|
const AES_KEY *key);
|
||||||
void AES_decrypt(const unsigned char *in, unsigned char *out,
|
void AES_decrypt(const unsigned char *in, unsigned char *out,
|
||||||
|
|||||||
@@ -625,7 +625,7 @@ static const u32 rcon[] = {
|
|||||||
/**
|
/**
|
||||||
* Expand the cipher key into the encryption key schedule.
|
* Expand the cipher key into the encryption key schedule.
|
||||||
*/
|
*/
|
||||||
int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
int private_AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||||
AES_KEY *key) {
|
AES_KEY *key) {
|
||||||
|
|
||||||
u32 *rk;
|
u32 *rk;
|
||||||
@@ -726,7 +726,7 @@ int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
|||||||
/**
|
/**
|
||||||
* Expand the cipher key into the decryption key schedule.
|
* Expand the cipher key into the decryption key schedule.
|
||||||
*/
|
*/
|
||||||
int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
int private_AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
AES_KEY *key) {
|
AES_KEY *key) {
|
||||||
|
|
||||||
u32 *rk;
|
u32 *rk;
|
||||||
@@ -734,7 +734,7 @@ int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
|||||||
u32 temp;
|
u32 temp;
|
||||||
|
|
||||||
/* first, start with an encryption schedule */
|
/* first, start with an encryption schedule */
|
||||||
status = AES_set_encrypt_key(userKey, bits, key);
|
status = private_AES_set_encrypt_key(userKey, bits, key);
|
||||||
if (status < 0)
|
if (status < 0)
|
||||||
return status;
|
return status;
|
||||||
|
|
||||||
@@ -1201,7 +1201,7 @@ static const u32 rcon[] = {
|
|||||||
/**
|
/**
|
||||||
* Expand the cipher key into the encryption key schedule.
|
* Expand the cipher key into the encryption key schedule.
|
||||||
*/
|
*/
|
||||||
int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
int private_AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||||
AES_KEY *key) {
|
AES_KEY *key) {
|
||||||
u32 *rk;
|
u32 *rk;
|
||||||
int i = 0;
|
int i = 0;
|
||||||
@@ -1301,7 +1301,7 @@ int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
|||||||
/**
|
/**
|
||||||
* Expand the cipher key into the decryption key schedule.
|
* Expand the cipher key into the decryption key schedule.
|
||||||
*/
|
*/
|
||||||
int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
int private_AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
AES_KEY *key) {
|
AES_KEY *key) {
|
||||||
|
|
||||||
u32 *rk;
|
u32 *rk;
|
||||||
@@ -1309,7 +1309,7 @@ int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
|||||||
u32 temp;
|
u32 temp;
|
||||||
|
|
||||||
/* first, start with an encryption schedule */
|
/* first, start with an encryption schedule */
|
||||||
status = AES_set_encrypt_key(userKey, bits, key);
|
status = private_AES_set_encrypt_key(userKey, bits, key);
|
||||||
if (status < 0)
|
if (status < 0)
|
||||||
return status;
|
return status;
|
||||||
|
|
||||||
|
|||||||
@@ -50,6 +50,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include <openssl/opensslv.h>
|
#include <openssl/opensslv.h>
|
||||||
|
#include <openssl/crypto.h>
|
||||||
#include <openssl/aes.h>
|
#include <openssl/aes.h>
|
||||||
#include "aes_locl.h"
|
#include "aes_locl.h"
|
||||||
|
|
||||||
@@ -62,3 +63,23 @@ const char *AES_options(void) {
|
|||||||
return "aes(partial)";
|
return "aes(partial)";
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* FIPS wrapper functions to block low level AES calls in FIPS mode */
|
||||||
|
|
||||||
|
int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||||
|
AES_KEY *key)
|
||||||
|
{
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
fips_cipher_abort(AES);
|
||||||
|
#endif
|
||||||
|
return private_AES_set_encrypt_key(userKey, bits, key);
|
||||||
|
}
|
||||||
|
|
||||||
|
int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
|
AES_KEY *key)
|
||||||
|
{
|
||||||
|
#ifdef OPENSSL_FIPS
|
||||||
|
fips_cipher_abort(AES);
|
||||||
|
#endif
|
||||||
|
return private_AES_set_decrypt_key(userKey, bits, key);
|
||||||
|
}
|
||||||
|
|||||||
@@ -85,9 +85,9 @@ int AES_wrap_key(AES_KEY *key, const unsigned char *iv,
|
|||||||
A[7] ^= (unsigned char)(t & 0xff);
|
A[7] ^= (unsigned char)(t & 0xff);
|
||||||
if (t > 0xff)
|
if (t > 0xff)
|
||||||
{
|
{
|
||||||
A[6] ^= (unsigned char)((t & 0xff) >> 8);
|
A[6] ^= (unsigned char)((t >> 8) & 0xff);
|
||||||
A[5] ^= (unsigned char)((t & 0xff) >> 16);
|
A[5] ^= (unsigned char)((t >> 16) & 0xff);
|
||||||
A[4] ^= (unsigned char)((t & 0xff) >> 24);
|
A[4] ^= (unsigned char)((t >> 24) & 0xff);
|
||||||
}
|
}
|
||||||
memcpy(R, B + 8, 8);
|
memcpy(R, B + 8, 8);
|
||||||
}
|
}
|
||||||
@@ -119,9 +119,9 @@ int AES_unwrap_key(AES_KEY *key, const unsigned char *iv,
|
|||||||
A[7] ^= (unsigned char)(t & 0xff);
|
A[7] ^= (unsigned char)(t & 0xff);
|
||||||
if (t > 0xff)
|
if (t > 0xff)
|
||||||
{
|
{
|
||||||
A[6] ^= (unsigned char)((t & 0xff) >> 8);
|
A[6] ^= (unsigned char)((t >> 8) & 0xff);
|
||||||
A[5] ^= (unsigned char)((t & 0xff) >> 16);
|
A[5] ^= (unsigned char)((t >> 16) & 0xff);
|
||||||
A[4] ^= (unsigned char)((t & 0xff) >> 24);
|
A[4] ^= (unsigned char)((t >> 24) & 0xff);
|
||||||
}
|
}
|
||||||
memcpy(B + 8, R, 8);
|
memcpy(B + 8, R, 8);
|
||||||
AES_decrypt(B, B, key);
|
AES_decrypt(B, B, key);
|
||||||
|
|||||||
@@ -39,7 +39,7 @@
|
|||||||
# but exhibits up to 10% improvement on other cores.
|
# but exhibits up to 10% improvement on other cores.
|
||||||
#
|
#
|
||||||
# Second version is "monolithic" replacement for aes_core.c, which in
|
# Second version is "monolithic" replacement for aes_core.c, which in
|
||||||
# addition to AES_[de|en]crypt implements AES_set_[de|en]cryption_key.
|
# addition to AES_[de|en]crypt implements private_AES_set_[de|en]cryption_key.
|
||||||
# This made it possible to implement little-endian variant of the
|
# This made it possible to implement little-endian variant of the
|
||||||
# algorithm without modifying the base C code. Motivating factor for
|
# algorithm without modifying the base C code. Motivating factor for
|
||||||
# the undertaken effort was that it appeared that in tight IA-32
|
# the undertaken effort was that it appeared that in tight IA-32
|
||||||
@@ -2854,12 +2854,12 @@ sub enckey()
|
|||||||
&set_label("exit");
|
&set_label("exit");
|
||||||
&function_end("_x86_AES_set_encrypt_key");
|
&function_end("_x86_AES_set_encrypt_key");
|
||||||
|
|
||||||
# int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
# int private_AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||||
# AES_KEY *key)
|
# AES_KEY *key)
|
||||||
&function_begin_B("AES_set_encrypt_key");
|
&function_begin_B("private_AES_set_encrypt_key");
|
||||||
&call ("_x86_AES_set_encrypt_key");
|
&call ("_x86_AES_set_encrypt_key");
|
||||||
&ret ();
|
&ret ();
|
||||||
&function_end_B("AES_set_encrypt_key");
|
&function_end_B("private_AES_set_encrypt_key");
|
||||||
|
|
||||||
sub deckey()
|
sub deckey()
|
||||||
{ my ($i,$key,$tp1,$tp2,$tp4,$tp8) = @_;
|
{ my ($i,$key,$tp1,$tp2,$tp4,$tp8) = @_;
|
||||||
@@ -2916,9 +2916,9 @@ sub deckey()
|
|||||||
&mov (&DWP(4*$i,$key),$tp1);
|
&mov (&DWP(4*$i,$key),$tp1);
|
||||||
}
|
}
|
||||||
|
|
||||||
# int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
# int private_AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
# AES_KEY *key)
|
# AES_KEY *key)
|
||||||
&function_begin_B("AES_set_decrypt_key");
|
&function_begin_B("private_AES_set_decrypt_key");
|
||||||
&call ("_x86_AES_set_encrypt_key");
|
&call ("_x86_AES_set_encrypt_key");
|
||||||
&cmp ("eax",0);
|
&cmp ("eax",0);
|
||||||
&je (&label("proceed"));
|
&je (&label("proceed"));
|
||||||
@@ -2974,7 +2974,7 @@ sub deckey()
|
|||||||
&jb (&label("permute"));
|
&jb (&label("permute"));
|
||||||
|
|
||||||
&xor ("eax","eax"); # return success
|
&xor ("eax","eax"); # return success
|
||||||
&function_end("AES_set_decrypt_key");
|
&function_end("private_AES_set_decrypt_key");
|
||||||
&asciz("AES for x86, CRYPTOGAMS by <appro\@openssl.org>");
|
&asciz("AES for x86, CRYPTOGAMS by <appro\@openssl.org>");
|
||||||
|
|
||||||
&asm_finish();
|
&asm_finish();
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
1611
crypto/aes/asm/aes-mips.pl
Normal file
1611
crypto/aes/asm/aes-mips.pl
Normal file
File diff suppressed because it is too large
Load Diff
1022
crypto/aes/asm/aes-parisc.pl
Normal file
1022
crypto/aes/asm/aes-parisc.pl
Normal file
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1176,6 +1176,7 @@ ___
|
|||||||
# As UltraSPARC T1, a.k.a. Niagara, has shared FPU, FP nops can have
|
# As UltraSPARC T1, a.k.a. Niagara, has shared FPU, FP nops can have
|
||||||
# undesired effect, so just omit them and sacrifice some portion of
|
# undesired effect, so just omit them and sacrifice some portion of
|
||||||
# percent in performance...
|
# percent in performance...
|
||||||
$code =~ s/fmovs.*$//gem;
|
$code =~ s/fmovs.*$//gm;
|
||||||
|
|
||||||
print $code;
|
print $code;
|
||||||
|
close STDOUT; # ensure flush
|
||||||
|
|||||||
@@ -36,7 +36,8 @@ $0 =~ m/(.*[\/\\])[^\/\\]+$/; $dir=$1;
|
|||||||
( $xlate="${dir}../../perlasm/x86_64-xlate.pl" and -f $xlate) or
|
( $xlate="${dir}../../perlasm/x86_64-xlate.pl" and -f $xlate) or
|
||||||
die "can't locate x86_64-xlate.pl";
|
die "can't locate x86_64-xlate.pl";
|
||||||
|
|
||||||
open STDOUT,"| $^X $xlate $flavour $output";
|
open OUT,"| \"$^X\" $xlate $flavour $output";
|
||||||
|
*STDOUT=*OUT;
|
||||||
|
|
||||||
$verticalspin=1; # unlike 32-bit version $verticalspin performs
|
$verticalspin=1; # unlike 32-bit version $verticalspin performs
|
||||||
# ~15% better on both AMD and Intel cores
|
# ~15% better on both AMD and Intel cores
|
||||||
@@ -588,6 +589,9 @@ $code.=<<___;
|
|||||||
.globl AES_encrypt
|
.globl AES_encrypt
|
||||||
.type AES_encrypt,\@function,3
|
.type AES_encrypt,\@function,3
|
||||||
.align 16
|
.align 16
|
||||||
|
.globl asm_AES_encrypt
|
||||||
|
.hidden asm_AES_encrypt
|
||||||
|
asm_AES_encrypt:
|
||||||
AES_encrypt:
|
AES_encrypt:
|
||||||
push %rbx
|
push %rbx
|
||||||
push %rbp
|
push %rbp
|
||||||
@@ -1184,6 +1188,9 @@ $code.=<<___;
|
|||||||
.globl AES_decrypt
|
.globl AES_decrypt
|
||||||
.type AES_decrypt,\@function,3
|
.type AES_decrypt,\@function,3
|
||||||
.align 16
|
.align 16
|
||||||
|
.globl asm_AES_decrypt
|
||||||
|
.hidden asm_AES_decrypt
|
||||||
|
asm_AES_decrypt:
|
||||||
AES_decrypt:
|
AES_decrypt:
|
||||||
push %rbx
|
push %rbx
|
||||||
push %rbp
|
push %rbp
|
||||||
@@ -1277,13 +1284,13 @@ $code.=<<___;
|
|||||||
___
|
___
|
||||||
}
|
}
|
||||||
|
|
||||||
# int AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
# int private_AES_set_encrypt_key(const unsigned char *userKey, const int bits,
|
||||||
# AES_KEY *key)
|
# AES_KEY *key)
|
||||||
$code.=<<___;
|
$code.=<<___;
|
||||||
.globl AES_set_encrypt_key
|
.globl private_AES_set_encrypt_key
|
||||||
.type AES_set_encrypt_key,\@function,3
|
.type private_AES_set_encrypt_key,\@function,3
|
||||||
.align 16
|
.align 16
|
||||||
AES_set_encrypt_key:
|
private_AES_set_encrypt_key:
|
||||||
push %rbx
|
push %rbx
|
||||||
push %rbp
|
push %rbp
|
||||||
push %r12 # redundant, but allows to share
|
push %r12 # redundant, but allows to share
|
||||||
@@ -1304,7 +1311,7 @@ AES_set_encrypt_key:
|
|||||||
add \$56,%rsp
|
add \$56,%rsp
|
||||||
.Lenc_key_epilogue:
|
.Lenc_key_epilogue:
|
||||||
ret
|
ret
|
||||||
.size AES_set_encrypt_key,.-AES_set_encrypt_key
|
.size private_AES_set_encrypt_key,.-private_AES_set_encrypt_key
|
||||||
|
|
||||||
.type _x86_64_AES_set_encrypt_key,\@abi-omnipotent
|
.type _x86_64_AES_set_encrypt_key,\@abi-omnipotent
|
||||||
.align 16
|
.align 16
|
||||||
@@ -1547,13 +1554,13 @@ $code.=<<___;
|
|||||||
___
|
___
|
||||||
}
|
}
|
||||||
|
|
||||||
# int AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
# int private_AES_set_decrypt_key(const unsigned char *userKey, const int bits,
|
||||||
# AES_KEY *key)
|
# AES_KEY *key)
|
||||||
$code.=<<___;
|
$code.=<<___;
|
||||||
.globl AES_set_decrypt_key
|
.globl private_AES_set_decrypt_key
|
||||||
.type AES_set_decrypt_key,\@function,3
|
.type private_AES_set_decrypt_key,\@function,3
|
||||||
.align 16
|
.align 16
|
||||||
AES_set_decrypt_key:
|
private_AES_set_decrypt_key:
|
||||||
push %rbx
|
push %rbx
|
||||||
push %rbp
|
push %rbp
|
||||||
push %r12
|
push %r12
|
||||||
@@ -1622,7 +1629,7 @@ $code.=<<___;
|
|||||||
add \$56,%rsp
|
add \$56,%rsp
|
||||||
.Ldec_key_epilogue:
|
.Ldec_key_epilogue:
|
||||||
ret
|
ret
|
||||||
.size AES_set_decrypt_key,.-AES_set_decrypt_key
|
.size private_AES_set_decrypt_key,.-private_AES_set_decrypt_key
|
||||||
___
|
___
|
||||||
|
|
||||||
# void AES_cbc_encrypt (const void char *inp, unsigned char *out,
|
# void AES_cbc_encrypt (const void char *inp, unsigned char *out,
|
||||||
@@ -1648,6 +1655,9 @@ $code.=<<___;
|
|||||||
.type AES_cbc_encrypt,\@function,6
|
.type AES_cbc_encrypt,\@function,6
|
||||||
.align 16
|
.align 16
|
||||||
.extern OPENSSL_ia32cap_P
|
.extern OPENSSL_ia32cap_P
|
||||||
|
.globl asm_AES_cbc_encrypt
|
||||||
|
.hidden asm_AES_cbc_encrypt
|
||||||
|
asm_AES_cbc_encrypt:
|
||||||
AES_cbc_encrypt:
|
AES_cbc_encrypt:
|
||||||
cmp \$0,%rdx # check length
|
cmp \$0,%rdx # check length
|
||||||
je .Lcbc_epilogue
|
je .Lcbc_epilogue
|
||||||
@@ -2766,13 +2776,13 @@ cbc_se_handler:
|
|||||||
.rva .LSEH_end_AES_decrypt
|
.rva .LSEH_end_AES_decrypt
|
||||||
.rva .LSEH_info_AES_decrypt
|
.rva .LSEH_info_AES_decrypt
|
||||||
|
|
||||||
.rva .LSEH_begin_AES_set_encrypt_key
|
.rva .LSEH_begin_private_AES_set_encrypt_key
|
||||||
.rva .LSEH_end_AES_set_encrypt_key
|
.rva .LSEH_end_private_AES_set_encrypt_key
|
||||||
.rva .LSEH_info_AES_set_encrypt_key
|
.rva .LSEH_info_private_AES_set_encrypt_key
|
||||||
|
|
||||||
.rva .LSEH_begin_AES_set_decrypt_key
|
.rva .LSEH_begin_private_AES_set_decrypt_key
|
||||||
.rva .LSEH_end_AES_set_decrypt_key
|
.rva .LSEH_end_private_AES_set_decrypt_key
|
||||||
.rva .LSEH_info_AES_set_decrypt_key
|
.rva .LSEH_info_private_AES_set_decrypt_key
|
||||||
|
|
||||||
.rva .LSEH_begin_AES_cbc_encrypt
|
.rva .LSEH_begin_AES_cbc_encrypt
|
||||||
.rva .LSEH_end_AES_cbc_encrypt
|
.rva .LSEH_end_AES_cbc_encrypt
|
||||||
@@ -2788,11 +2798,11 @@ cbc_se_handler:
|
|||||||
.byte 9,0,0,0
|
.byte 9,0,0,0
|
||||||
.rva block_se_handler
|
.rva block_se_handler
|
||||||
.rva .Ldec_prologue,.Ldec_epilogue # HandlerData[]
|
.rva .Ldec_prologue,.Ldec_epilogue # HandlerData[]
|
||||||
.LSEH_info_AES_set_encrypt_key:
|
.LSEH_info_private_AES_set_encrypt_key:
|
||||||
.byte 9,0,0,0
|
.byte 9,0,0,0
|
||||||
.rva key_se_handler
|
.rva key_se_handler
|
||||||
.rva .Lenc_key_prologue,.Lenc_key_epilogue # HandlerData[]
|
.rva .Lenc_key_prologue,.Lenc_key_epilogue # HandlerData[]
|
||||||
.LSEH_info_AES_set_decrypt_key:
|
.LSEH_info_private_AES_set_decrypt_key:
|
||||||
.byte 9,0,0,0
|
.byte 9,0,0,0
|
||||||
.rva key_se_handler
|
.rva key_se_handler
|
||||||
.rva .Ldec_key_prologue,.Ldec_key_epilogue # HandlerData[]
|
.rva .Ldec_key_prologue,.Ldec_key_epilogue # HandlerData[]
|
||||||
|
|||||||
1250
crypto/aes/asm/aesni-sha1-x86_64.pl
Normal file
1250
crypto/aes/asm/aesni-sha1-x86_64.pl
Normal file
File diff suppressed because it is too large
Load Diff
2189
crypto/aes/asm/aesni-x86.pl
Normal file
2189
crypto/aes/asm/aesni-x86.pl
Normal file
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user