diff options
author | markus <> | 2004-04-07 20:42:12 +0000 |
---|---|---|
committer | markus <> | 2004-04-07 20:42:12 +0000 |
commit | cbf88de39286be06cd20e0c65b6cb7633dce25a5 (patch) | |
tree | cb12a4cb9d300ed3fa5ac3bc6fdba7773235dfd4 | |
parent | a4ab668c13b41cdc59a6f7dc9cf6c88c39d2466b (diff) | |
parent | 00b426069b0dfa8f0d9b87308646e9684f45c515 (diff) | |
download | openbsd-cbf88de39286be06cd20e0c65b6cb7633dce25a5.tar.gz openbsd-cbf88de39286be06cd20e0c65b6cb7633dce25a5.tar.bz2 openbsd-cbf88de39286be06cd20e0c65b6cb7633dce25a5.zip |
This commit was generated by cvs2git to track changes on a CVS vendor
branch.
-rw-r--r-- | src/lib/libcrypto/rc5/rc5_locl.h | 207 | ||||
-rw-r--r-- | src/lib/libcrypto/util/extract-names.pl | 2 | ||||
-rw-r--r-- | src/lib/libssl/src/certs/expired/vsign3.pem | 18 | ||||
-rw-r--r-- | src/lib/libssl/src/crypto/bn/asm/x86_64-gcc.c | 2 | ||||
-rw-r--r-- | src/lib/libssl/src/crypto/rc5/rc5_locl.h | 207 | ||||
-rw-r--r-- | src/lib/libssl/src/doc/apps/s_time.pod | 173 | ||||
-rw-r--r-- | src/lib/libssl/src/doc/crypto/CONF_modules_free.pod | 47 | ||||
-rw-r--r-- | src/lib/libssl/src/doc/crypto/CONF_modules_load_file.pod | 60 | ||||
-rw-r--r-- | src/lib/libssl/src/doc/crypto/OPENSSL_config.pod | 82 | ||||
-rw-r--r-- | src/lib/libssl/src/doc/crypto/OPENSSL_load_builtin_modules.pod | 51 | ||||
-rw-r--r-- | src/lib/libssl/src/doc/crypto/d2i_DSAPublicKey.pod | 5 | ||||
-rw-r--r-- | src/lib/libssl/src/os2/backwardify.pl | 32 | ||||
-rw-r--r-- | src/lib/libssl/src/util/extract-names.pl | 2 |
13 files changed, 885 insertions, 3 deletions
diff --git a/src/lib/libcrypto/rc5/rc5_locl.h b/src/lib/libcrypto/rc5/rc5_locl.h new file mode 100644 index 0000000000..f4ebc23004 --- /dev/null +++ b/src/lib/libcrypto/rc5/rc5_locl.h | |||
@@ -0,0 +1,207 @@ | |||
1 | /* crypto/rc5/rc5_locl.h */ | ||
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | ||
3 | * All rights reserved. | ||
4 | * | ||
5 | * This package is an SSL implementation written | ||
6 | * by Eric Young (eay@cryptsoft.com). | ||
7 | * The implementation was written so as to conform with Netscapes SSL. | ||
8 | * | ||
9 | * This library is free for commercial and non-commercial use as long as | ||
10 | * the following conditions are aheared to. The following conditions | ||
11 | * apply to all code found in this distribution, be it the RC4, RSA, | ||
12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation | ||
13 | * included with this distribution is covered by the same copyright terms | ||
14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). | ||
15 | * | ||
16 | * Copyright remains Eric Young's, and as such any Copyright notices in | ||
17 | * the code are not to be removed. | ||
18 | * If this package is used in a product, Eric Young should be given attribution | ||
19 | * as the author of the parts of the library used. | ||
20 | * This can be in the form of a textual message at program startup or | ||
21 | * in documentation (online or textual) provided with the package. | ||
22 | * | ||
23 | * Redistribution and use in source and binary forms, with or without | ||
24 | * modification, are permitted provided that the following conditions | ||
25 | * are met: | ||
26 | * 1. Redistributions of source code must retain the copyright | ||
27 | * notice, this list of conditions and the following disclaimer. | ||
28 | * 2. Redistributions in binary form must reproduce the above copyright | ||
29 | * notice, this list of conditions and the following disclaimer in the | ||
30 | * documentation and/or other materials provided with the distribution. | ||
31 | * 3. All advertising materials mentioning features or use of this software | ||
32 | * must display the following acknowledgement: | ||
33 | * "This product includes cryptographic software written by | ||
34 | * Eric Young (eay@cryptsoft.com)" | ||
35 | * The word 'cryptographic' can be left out if the rouines from the library | ||
36 | * being used are not cryptographic related :-). | ||
37 | * 4. If you include any Windows specific code (or a derivative thereof) from | ||
38 | * the apps directory (application code) you must include an acknowledgement: | ||
39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" | ||
40 | * | ||
41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND | ||
42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE | ||
45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | ||
47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||
48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | ||
49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | ||
50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | ||
51 | * SUCH DAMAGE. | ||
52 | * | ||
53 | * The licence and distribution terms for any publically available version or | ||
54 | * derivative of this code cannot be changed. i.e. this code cannot simply be | ||
55 | * copied and put under another distribution licence | ||
56 | * [including the GNU Public Licence.] | ||
57 | */ | ||
58 | |||
59 | #include <stdlib.h> | ||
60 | |||
61 | #undef c2l | ||
62 | #define c2l(c,l) (l =((unsigned long)(*((c)++))) , \ | ||
63 | l|=((unsigned long)(*((c)++)))<< 8L, \ | ||
64 | l|=((unsigned long)(*((c)++)))<<16L, \ | ||
65 | l|=((unsigned long)(*((c)++)))<<24L) | ||
66 | |||
67 | /* NOTE - c is not incremented as per c2l */ | ||
68 | #undef c2ln | ||
69 | #define c2ln(c,l1,l2,n) { \ | ||
70 | c+=n; \ | ||
71 | l1=l2=0; \ | ||
72 | switch (n) { \ | ||
73 | case 8: l2 =((unsigned long)(*(--(c))))<<24L; \ | ||
74 | case 7: l2|=((unsigned long)(*(--(c))))<<16L; \ | ||
75 | case 6: l2|=((unsigned long)(*(--(c))))<< 8L; \ | ||
76 | case 5: l2|=((unsigned long)(*(--(c)))); \ | ||
77 | case 4: l1 =((unsigned long)(*(--(c))))<<24L; \ | ||
78 | case 3: l1|=((unsigned long)(*(--(c))))<<16L; \ | ||
79 | case 2: l1|=((unsigned long)(*(--(c))))<< 8L; \ | ||
80 | case 1: l1|=((unsigned long)(*(--(c)))); \ | ||
81 | } \ | ||
82 | } | ||
83 | |||
84 | #undef l2c | ||
85 | #define l2c(l,c) (*((c)++)=(unsigned char)(((l) )&0xff), \ | ||
86 | *((c)++)=(unsigned char)(((l)>> 8L)&0xff), \ | ||
87 | *((c)++)=(unsigned char)(((l)>>16L)&0xff), \ | ||
88 | *((c)++)=(unsigned char)(((l)>>24L)&0xff)) | ||
89 | |||
90 | /* NOTE - c is not incremented as per l2c */ | ||
91 | #undef l2cn | ||
92 | #define l2cn(l1,l2,c,n) { \ | ||
93 | c+=n; \ | ||
94 | switch (n) { \ | ||
95 | case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \ | ||
96 | case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \ | ||
97 | case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \ | ||
98 | case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \ | ||
99 | case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \ | ||
100 | case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \ | ||
101 | case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \ | ||
102 | case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \ | ||
103 | } \ | ||
104 | } | ||
105 | |||
106 | /* NOTE - c is not incremented as per n2l */ | ||
107 | #define n2ln(c,l1,l2,n) { \ | ||
108 | c+=n; \ | ||
109 | l1=l2=0; \ | ||
110 | switch (n) { \ | ||
111 | case 8: l2 =((unsigned long)(*(--(c)))) ; \ | ||
112 | case 7: l2|=((unsigned long)(*(--(c))))<< 8; \ | ||
113 | case 6: l2|=((unsigned long)(*(--(c))))<<16; \ | ||
114 | case 5: l2|=((unsigned long)(*(--(c))))<<24; \ | ||
115 | case 4: l1 =((unsigned long)(*(--(c)))) ; \ | ||
116 | case 3: l1|=((unsigned long)(*(--(c))))<< 8; \ | ||
117 | case 2: l1|=((unsigned long)(*(--(c))))<<16; \ | ||
118 | case 1: l1|=((unsigned long)(*(--(c))))<<24; \ | ||
119 | } \ | ||
120 | } | ||
121 | |||
122 | /* NOTE - c is not incremented as per l2n */ | ||
123 | #define l2nn(l1,l2,c,n) { \ | ||
124 | c+=n; \ | ||
125 | switch (n) { \ | ||
126 | case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \ | ||
127 | case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \ | ||
128 | case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \ | ||
129 | case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \ | ||
130 | case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \ | ||
131 | case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \ | ||
132 | case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \ | ||
133 | case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \ | ||
134 | } \ | ||
135 | } | ||
136 | |||
137 | #undef n2l | ||
138 | #define n2l(c,l) (l =((unsigned long)(*((c)++)))<<24L, \ | ||
139 | l|=((unsigned long)(*((c)++)))<<16L, \ | ||
140 | l|=((unsigned long)(*((c)++)))<< 8L, \ | ||
141 | l|=((unsigned long)(*((c)++)))) | ||
142 | |||
143 | #undef l2n | ||
144 | #define l2n(l,c) (*((c)++)=(unsigned char)(((l)>>24L)&0xff), \ | ||
145 | *((c)++)=(unsigned char)(((l)>>16L)&0xff), \ | ||
146 | *((c)++)=(unsigned char)(((l)>> 8L)&0xff), \ | ||
147 | *((c)++)=(unsigned char)(((l) )&0xff)) | ||
148 | |||
149 | #if defined(OPENSSL_SYS_WIN32) && defined(_MSC_VER) | ||
150 | #define ROTATE_l32(a,n) _lrotl(a,n) | ||
151 | #define ROTATE_r32(a,n) _lrotr(a,n) | ||
152 | #elif defined(__GNUC__) && __GNUC__>=2 && !defined(__STRICT_ANSI__) && !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_NO_INLINE_ASM) && !defined(PEDANTIC) | ||
153 | # if defined(__i386) || defined(__i386__) || defined(__x86_64) || defined(__x86_64__) | ||
154 | # define ROTATE_l32(a,n) ({ register unsigned int ret; \ | ||
155 | asm ("roll %%cl,%0" \ | ||
156 | : "=r"(ret) \ | ||
157 | : "c"(n),"0"(a) \ | ||
158 | : "cc"); \ | ||
159 | ret; \ | ||
160 | }) | ||
161 | # define ROTATE_r32(a,n) ({ register unsigned int ret; \ | ||
162 | asm ("rorl %%cl,%0" \ | ||
163 | : "=r"(ret) \ | ||
164 | : "c"(n),"0"(a) \ | ||
165 | : "cc"); \ | ||
166 | ret; \ | ||
167 | }) | ||
168 | # endif | ||
169 | #endif | ||
170 | #ifndef ROTATE_l32 | ||
171 | #define ROTATE_l32(a,n) (((a)<<(n&0x1f))|(((a)&0xffffffff)>>(32-(n&0x1f)))) | ||
172 | #endif | ||
173 | #ifndef ROTATE_r32 | ||
174 | #define ROTATE_r32(a,n) (((a)<<(32-(n&0x1f)))|(((a)&0xffffffff)>>(n&0x1f))) | ||
175 | #endif | ||
176 | |||
177 | #define RC5_32_MASK 0xffffffffL | ||
178 | |||
179 | #define RC5_16_P 0xB7E1 | ||
180 | #define RC5_16_Q 0x9E37 | ||
181 | #define RC5_32_P 0xB7E15163L | ||
182 | #define RC5_32_Q 0x9E3779B9L | ||
183 | #define RC5_64_P 0xB7E151628AED2A6BLL | ||
184 | #define RC5_64_Q 0x9E3779B97F4A7C15LL | ||
185 | |||
186 | #define E_RC5_32(a,b,s,n) \ | ||
187 | a^=b; \ | ||
188 | a=ROTATE_l32(a,b); \ | ||
189 | a+=s[n]; \ | ||
190 | a&=RC5_32_MASK; \ | ||
191 | b^=a; \ | ||
192 | b=ROTATE_l32(b,a); \ | ||
193 | b+=s[n+1]; \ | ||
194 | b&=RC5_32_MASK; | ||
195 | |||
196 | #define D_RC5_32(a,b,s,n) \ | ||
197 | b-=s[n+1]; \ | ||
198 | b&=RC5_32_MASK; \ | ||
199 | b=ROTATE_r32(b,a); \ | ||
200 | b^=a; \ | ||
201 | a-=s[n]; \ | ||
202 | a&=RC5_32_MASK; \ | ||
203 | a=ROTATE_r32(a,b); \ | ||
204 | a^=b; | ||
205 | |||
206 | |||
207 | |||
diff --git a/src/lib/libcrypto/util/extract-names.pl b/src/lib/libcrypto/util/extract-names.pl index 9f2ad5ef16..744a8e2324 100644 --- a/src/lib/libcrypto/util/extract-names.pl +++ b/src/lib/libcrypto/util/extract-names.pl | |||
@@ -10,6 +10,8 @@ while(<STDIN>) { | |||
10 | if (/ - /) { | 10 | if (/ - /) { |
11 | s/ - .*//; | 11 | s/ - .*//; |
12 | s/,[ \t]+/,/g; | 12 | s/,[ \t]+/,/g; |
13 | s/^[ \t]+//g; | ||
14 | s/[ \t]+$//g; | ||
13 | push @words, split ','; | 15 | push @words, split ','; |
14 | } | 16 | } |
15 | } | 17 | } |
diff --git a/src/lib/libssl/src/certs/expired/vsign3.pem b/src/lib/libssl/src/certs/expired/vsign3.pem new file mode 100644 index 0000000000..aa5bb4c1f3 --- /dev/null +++ b/src/lib/libssl/src/certs/expired/vsign3.pem | |||
@@ -0,0 +1,18 @@ | |||
1 | subject=/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority | ||
2 | notBefore=Jan 29 00:00:00 1996 GMT | ||
3 | notAfter=Jan 7 23:59:59 2004 GMT | ||
4 | -----BEGIN CERTIFICATE----- | ||
5 | MIICPTCCAaYCEQDknv3zOugOz6URPhmkJAIyMA0GCSqGSIb3DQEBAgUAMF8xCzAJ | ||
6 | BgNVBAYTAlVTMRcwFQYDVQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xh | ||
7 | c3MgMyBQdWJsaWMgUHJpbWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw05 | ||
8 | NjAxMjkwMDAwMDBaFw0wNDAxMDcyMzU5NTlaMF8xCzAJBgNVBAYTAlVTMRcwFQYD | ||
9 | VQQKEw5WZXJpU2lnbiwgSW5jLjE3MDUGA1UECxMuQ2xhc3MgMyBQdWJsaWMgUHJp | ||
10 | bWFyeSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCBnzANBgkqhkiG9w0BAQEFAAOB | ||
11 | jQAwgYkCgYEAyVxZnvIbigEUtBDfBEDb41evakVAj4QMC9Ez2dkRz+4CWB8l9yqo | ||
12 | RAWq7AMfeH+ek7maAKojfdashaJjRcdyJ8z0TMZ1cdI5709C8HXfCpDGjiBvmA/4 | ||
13 | rCNfcCk2pMmG57GaIMtTpYXnPb59mv4kRTPcdhXtD6JxZExlLoFoRacCAwEAATAN | ||
14 | BgkqhkiG9w0BAQIFAAOBgQBhcOwvP579K+ZoVCGwZ3kIDCCWMYoNer62Jt95LCJp | ||
15 | STbjl3diYaIy13pUITa6Ask05yXaRDWw0lyAXbOU+Pms7qRgdSoflUkjsUp89LNH | ||
16 | ciFbfperVKxi513srpvSybIk+4Kt6WcVS7qqpvCXoPawl1cAyAw8CaCCBLpB2veZ | ||
17 | pA== | ||
18 | -----END CERTIFICATE----- | ||
diff --git a/src/lib/libssl/src/crypto/bn/asm/x86_64-gcc.c b/src/lib/libssl/src/crypto/bn/asm/x86_64-gcc.c index b97b394661..450e8e4322 100644 --- a/src/lib/libssl/src/crypto/bn/asm/x86_64-gcc.c +++ b/src/lib/libssl/src/crypto/bn/asm/x86_64-gcc.c | |||
@@ -142,7 +142,7 @@ void bn_sqr_words(BN_ULONG *r, BN_ULONG *a, int n) | |||
142 | BN_ULONG bn_div_words(BN_ULONG h, BN_ULONG l, BN_ULONG d) | 142 | BN_ULONG bn_div_words(BN_ULONG h, BN_ULONG l, BN_ULONG d) |
143 | { BN_ULONG ret,waste; | 143 | { BN_ULONG ret,waste; |
144 | 144 | ||
145 | asm ("divq %3" | 145 | asm ("divq %4" |
146 | : "=a"(ret),"=d"(waste) | 146 | : "=a"(ret),"=d"(waste) |
147 | : "a"(l),"d"(h),"g"(d) | 147 | : "a"(l),"d"(h),"g"(d) |
148 | : "cc"); | 148 | : "cc"); |
diff --git a/src/lib/libssl/src/crypto/rc5/rc5_locl.h b/src/lib/libssl/src/crypto/rc5/rc5_locl.h new file mode 100644 index 0000000000..f4ebc23004 --- /dev/null +++ b/src/lib/libssl/src/crypto/rc5/rc5_locl.h | |||
@@ -0,0 +1,207 @@ | |||
1 | /* crypto/rc5/rc5_locl.h */ | ||
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | ||
3 | * All rights reserved. | ||
4 | * | ||
5 | * This package is an SSL implementation written | ||
6 | * by Eric Young (eay@cryptsoft.com). | ||
7 | * The implementation was written so as to conform with Netscapes SSL. | ||
8 | * | ||
9 | * This library is free for commercial and non-commercial use as long as | ||
10 | * the following conditions are aheared to. The following conditions | ||
11 | * apply to all code found in this distribution, be it the RC4, RSA, | ||
12 | * lhash, DES, etc., code; not just the SSL code. The SSL documentation | ||
13 | * included with this distribution is covered by the same copyright terms | ||
14 | * except that the holder is Tim Hudson (tjh@cryptsoft.com). | ||
15 | * | ||
16 | * Copyright remains Eric Young's, and as such any Copyright notices in | ||
17 | * the code are not to be removed. | ||
18 | * If this package is used in a product, Eric Young should be given attribution | ||
19 | * as the author of the parts of the library used. | ||
20 | * This can be in the form of a textual message at program startup or | ||
21 | * in documentation (online or textual) provided with the package. | ||
22 | * | ||
23 | * Redistribution and use in source and binary forms, with or without | ||
24 | * modification, are permitted provided that the following conditions | ||
25 | * are met: | ||
26 | * 1. Redistributions of source code must retain the copyright | ||
27 | * notice, this list of conditions and the following disclaimer. | ||
28 | * 2. Redistributions in binary form must reproduce the above copyright | ||
29 | * notice, this list of conditions and the following disclaimer in the | ||
30 | * documentation and/or other materials provided with the distribution. | ||
31 | * 3. All advertising materials mentioning features or use of this software | ||
32 | * must display the following acknowledgement: | ||
33 | * "This product includes cryptographic software written by | ||
34 | * Eric Young (eay@cryptsoft.com)" | ||
35 | * The word 'cryptographic' can be left out if the rouines from the library | ||
36 | * being used are not cryptographic related :-). | ||
37 | * 4. If you include any Windows specific code (or a derivative thereof) from | ||
38 | * the apps directory (application code) you must include an acknowledgement: | ||
39 | * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" | ||
40 | * | ||
41 | * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND | ||
42 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
43 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
44 | * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE | ||
45 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
46 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | ||
47 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||
48 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | ||
49 | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | ||
50 | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | ||
51 | * SUCH DAMAGE. | ||
52 | * | ||
53 | * The licence and distribution terms for any publically available version or | ||
54 | * derivative of this code cannot be changed. i.e. this code cannot simply be | ||
55 | * copied and put under another distribution licence | ||
56 | * [including the GNU Public Licence.] | ||
57 | */ | ||
58 | |||
59 | #include <stdlib.h> | ||
60 | |||
61 | #undef c2l | ||
62 | #define c2l(c,l) (l =((unsigned long)(*((c)++))) , \ | ||
63 | l|=((unsigned long)(*((c)++)))<< 8L, \ | ||
64 | l|=((unsigned long)(*((c)++)))<<16L, \ | ||
65 | l|=((unsigned long)(*((c)++)))<<24L) | ||
66 | |||
67 | /* NOTE - c is not incremented as per c2l */ | ||
68 | #undef c2ln | ||
69 | #define c2ln(c,l1,l2,n) { \ | ||
70 | c+=n; \ | ||
71 | l1=l2=0; \ | ||
72 | switch (n) { \ | ||
73 | case 8: l2 =((unsigned long)(*(--(c))))<<24L; \ | ||
74 | case 7: l2|=((unsigned long)(*(--(c))))<<16L; \ | ||
75 | case 6: l2|=((unsigned long)(*(--(c))))<< 8L; \ | ||
76 | case 5: l2|=((unsigned long)(*(--(c)))); \ | ||
77 | case 4: l1 =((unsigned long)(*(--(c))))<<24L; \ | ||
78 | case 3: l1|=((unsigned long)(*(--(c))))<<16L; \ | ||
79 | case 2: l1|=((unsigned long)(*(--(c))))<< 8L; \ | ||
80 | case 1: l1|=((unsigned long)(*(--(c)))); \ | ||
81 | } \ | ||
82 | } | ||
83 | |||
84 | #undef l2c | ||
85 | #define l2c(l,c) (*((c)++)=(unsigned char)(((l) )&0xff), \ | ||
86 | *((c)++)=(unsigned char)(((l)>> 8L)&0xff), \ | ||
87 | *((c)++)=(unsigned char)(((l)>>16L)&0xff), \ | ||
88 | *((c)++)=(unsigned char)(((l)>>24L)&0xff)) | ||
89 | |||
90 | /* NOTE - c is not incremented as per l2c */ | ||
91 | #undef l2cn | ||
92 | #define l2cn(l1,l2,c,n) { \ | ||
93 | c+=n; \ | ||
94 | switch (n) { \ | ||
95 | case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \ | ||
96 | case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \ | ||
97 | case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \ | ||
98 | case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \ | ||
99 | case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \ | ||
100 | case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \ | ||
101 | case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \ | ||
102 | case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \ | ||
103 | } \ | ||
104 | } | ||
105 | |||
106 | /* NOTE - c is not incremented as per n2l */ | ||
107 | #define n2ln(c,l1,l2,n) { \ | ||
108 | c+=n; \ | ||
109 | l1=l2=0; \ | ||
110 | switch (n) { \ | ||
111 | case 8: l2 =((unsigned long)(*(--(c)))) ; \ | ||
112 | case 7: l2|=((unsigned long)(*(--(c))))<< 8; \ | ||
113 | case 6: l2|=((unsigned long)(*(--(c))))<<16; \ | ||
114 | case 5: l2|=((unsigned long)(*(--(c))))<<24; \ | ||
115 | case 4: l1 =((unsigned long)(*(--(c)))) ; \ | ||
116 | case 3: l1|=((unsigned long)(*(--(c))))<< 8; \ | ||
117 | case 2: l1|=((unsigned long)(*(--(c))))<<16; \ | ||
118 | case 1: l1|=((unsigned long)(*(--(c))))<<24; \ | ||
119 | } \ | ||
120 | } | ||
121 | |||
122 | /* NOTE - c is not incremented as per l2n */ | ||
123 | #define l2nn(l1,l2,c,n) { \ | ||
124 | c+=n; \ | ||
125 | switch (n) { \ | ||
126 | case 8: *(--(c))=(unsigned char)(((l2) )&0xff); \ | ||
127 | case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \ | ||
128 | case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \ | ||
129 | case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \ | ||
130 | case 4: *(--(c))=(unsigned char)(((l1) )&0xff); \ | ||
131 | case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \ | ||
132 | case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \ | ||
133 | case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \ | ||
134 | } \ | ||
135 | } | ||
136 | |||
137 | #undef n2l | ||
138 | #define n2l(c,l) (l =((unsigned long)(*((c)++)))<<24L, \ | ||
139 | l|=((unsigned long)(*((c)++)))<<16L, \ | ||
140 | l|=((unsigned long)(*((c)++)))<< 8L, \ | ||
141 | l|=((unsigned long)(*((c)++)))) | ||
142 | |||
143 | #undef l2n | ||
144 | #define l2n(l,c) (*((c)++)=(unsigned char)(((l)>>24L)&0xff), \ | ||
145 | *((c)++)=(unsigned char)(((l)>>16L)&0xff), \ | ||
146 | *((c)++)=(unsigned char)(((l)>> 8L)&0xff), \ | ||
147 | *((c)++)=(unsigned char)(((l) )&0xff)) | ||
148 | |||
149 | #if defined(OPENSSL_SYS_WIN32) && defined(_MSC_VER) | ||
150 | #define ROTATE_l32(a,n) _lrotl(a,n) | ||
151 | #define ROTATE_r32(a,n) _lrotr(a,n) | ||
152 | #elif defined(__GNUC__) && __GNUC__>=2 && !defined(__STRICT_ANSI__) && !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_NO_INLINE_ASM) && !defined(PEDANTIC) | ||
153 | # if defined(__i386) || defined(__i386__) || defined(__x86_64) || defined(__x86_64__) | ||
154 | # define ROTATE_l32(a,n) ({ register unsigned int ret; \ | ||
155 | asm ("roll %%cl,%0" \ | ||
156 | : "=r"(ret) \ | ||
157 | : "c"(n),"0"(a) \ | ||
158 | : "cc"); \ | ||
159 | ret; \ | ||
160 | }) | ||
161 | # define ROTATE_r32(a,n) ({ register unsigned int ret; \ | ||
162 | asm ("rorl %%cl,%0" \ | ||
163 | : "=r"(ret) \ | ||
164 | : "c"(n),"0"(a) \ | ||
165 | : "cc"); \ | ||
166 | ret; \ | ||
167 | }) | ||
168 | # endif | ||
169 | #endif | ||
170 | #ifndef ROTATE_l32 | ||
171 | #define ROTATE_l32(a,n) (((a)<<(n&0x1f))|(((a)&0xffffffff)>>(32-(n&0x1f)))) | ||
172 | #endif | ||
173 | #ifndef ROTATE_r32 | ||
174 | #define ROTATE_r32(a,n) (((a)<<(32-(n&0x1f)))|(((a)&0xffffffff)>>(n&0x1f))) | ||
175 | #endif | ||
176 | |||
177 | #define RC5_32_MASK 0xffffffffL | ||
178 | |||
179 | #define RC5_16_P 0xB7E1 | ||
180 | #define RC5_16_Q 0x9E37 | ||
181 | #define RC5_32_P 0xB7E15163L | ||
182 | #define RC5_32_Q 0x9E3779B9L | ||
183 | #define RC5_64_P 0xB7E151628AED2A6BLL | ||
184 | #define RC5_64_Q 0x9E3779B97F4A7C15LL | ||
185 | |||
186 | #define E_RC5_32(a,b,s,n) \ | ||
187 | a^=b; \ | ||
188 | a=ROTATE_l32(a,b); \ | ||
189 | a+=s[n]; \ | ||
190 | a&=RC5_32_MASK; \ | ||
191 | b^=a; \ | ||
192 | b=ROTATE_l32(b,a); \ | ||
193 | b+=s[n+1]; \ | ||
194 | b&=RC5_32_MASK; | ||
195 | |||
196 | #define D_RC5_32(a,b,s,n) \ | ||
197 | b-=s[n+1]; \ | ||
198 | b&=RC5_32_MASK; \ | ||
199 | b=ROTATE_r32(b,a); \ | ||
200 | b^=a; \ | ||
201 | a-=s[n]; \ | ||
202 | a&=RC5_32_MASK; \ | ||
203 | a=ROTATE_r32(a,b); \ | ||
204 | a^=b; | ||
205 | |||
206 | |||
207 | |||
diff --git a/src/lib/libssl/src/doc/apps/s_time.pod b/src/lib/libssl/src/doc/apps/s_time.pod new file mode 100644 index 0000000000..5a38aa2e03 --- /dev/null +++ b/src/lib/libssl/src/doc/apps/s_time.pod | |||
@@ -0,0 +1,173 @@ | |||
1 | |||
2 | =pod | ||
3 | |||
4 | =head1 NAME | ||
5 | |||
6 | s_time - SSL/TLS performance timing program | ||
7 | |||
8 | =head1 SYNOPSIS | ||
9 | |||
10 | B<openssl> B<s_time> | ||
11 | [B<-connect host:port>] | ||
12 | [B<-www page>] | ||
13 | [B<-cert filename>] | ||
14 | [B<-key filename>] | ||
15 | [B<-CApath directory>] | ||
16 | [B<-CAfile filename>] | ||
17 | [B<-reuse>] | ||
18 | [B<-new>] | ||
19 | [B<-verify depth>] | ||
20 | [B<-nbio>] | ||
21 | [B<-time seconds>] | ||
22 | [B<-ssl2>] | ||
23 | [B<-ssl3>] | ||
24 | [B<-bugs>] | ||
25 | [B<-cipher cipherlist>] | ||
26 | |||
27 | =head1 DESCRIPTION | ||
28 | |||
29 | The B<s_client> command implements a generic SSL/TLS client which connects to a | ||
30 | remote host using SSL/TLS. It can request a page from the server and includes | ||
31 | the time to transfer the payload data in its timing measurements. It measures | ||
32 | the number of connections within a given timeframe, the amount of data | ||
33 | transferred (if any), and calculates the average time spent for one connection. | ||
34 | |||
35 | =head1 OPTIONS | ||
36 | |||
37 | =over 4 | ||
38 | |||
39 | =item B<-connect host:port> | ||
40 | |||
41 | This specifies the host and optional port to connect to. | ||
42 | |||
43 | =item B<-www page> | ||
44 | |||
45 | This specifies the page to GET from the server. A value of '/' gets the | ||
46 | index.htm[l] page. If this parameter is not specified, then B<s_time> will only | ||
47 | perform the handshake to establish SSL connections but not transfer any | ||
48 | payload data. | ||
49 | |||
50 | =item B<-cert certname> | ||
51 | |||
52 | The certificate to use, if one is requested by the server. The default is | ||
53 | not to use a certificate. The file is in PEM format. | ||
54 | |||
55 | =item B<-key keyfile> | ||
56 | |||
57 | The private key to use. If not specified then the certificate file will | ||
58 | be used. The file is in PEM format. | ||
59 | |||
60 | =item B<-verify depth> | ||
61 | |||
62 | The verify depth to use. This specifies the maximum length of the | ||
63 | server certificate chain and turns on server certificate verification. | ||
64 | Currently the verify operation continues after errors so all the problems | ||
65 | with a certificate chain can be seen. As a side effect the connection | ||
66 | will never fail due to a server certificate verify failure. | ||
67 | |||
68 | =item B<-CApath directory> | ||
69 | |||
70 | The directory to use for server certificate verification. This directory | ||
71 | must be in "hash format", see B<verify> for more information. These are | ||
72 | also used when building the client certificate chain. | ||
73 | |||
74 | =item B<-CAfile file> | ||
75 | |||
76 | A file containing trusted certificates to use during server authentication | ||
77 | and to use when attempting to build the client certificate chain. | ||
78 | |||
79 | =item B<-new> | ||
80 | |||
81 | performs the timing test using a new session ID for each connection. | ||
82 | If neither B<-new> nor B<-reuse> are specified, they are both on by default | ||
83 | and executed in sequence. | ||
84 | |||
85 | =item B<-reuse> | ||
86 | |||
87 | performs the timing test using the same session ID; this can be used as a test | ||
88 | that session caching is working. If neither B<-new> nor B<-reuse> are | ||
89 | specified, they are both on by default and executed in sequence. | ||
90 | |||
91 | =item B<-nbio> | ||
92 | |||
93 | turns on non-blocking I/O. | ||
94 | |||
95 | =item B<-ssl2>, B<-ssl3> | ||
96 | |||
97 | these options disable the use of certain SSL or TLS protocols. By default | ||
98 | the initial handshake uses a method which should be compatible with all | ||
99 | servers and permit them to use SSL v3, SSL v2 or TLS as appropriate. | ||
100 | The timing program is not as rich in options to turn protocols on and off as | ||
101 | the L<s_client(1)|s_client(1)> program and may not connect to all servers. | ||
102 | |||
103 | Unfortunately there are a lot of ancient and broken servers in use which | ||
104 | cannot handle this technique and will fail to connect. Some servers only | ||
105 | work if TLS is turned off with the B<-ssl3> option; others | ||
106 | will only support SSL v2 and may need the B<-ssl2> option. | ||
107 | |||
108 | =item B<-bugs> | ||
109 | |||
110 | there are several known bug in SSL and TLS implementations. Adding this | ||
111 | option enables various workarounds. | ||
112 | |||
113 | =item B<-cipher cipherlist> | ||
114 | |||
115 | this allows the cipher list sent by the client to be modified. Although | ||
116 | the server determines which cipher suite is used it should take the first | ||
117 | supported cipher in the list sent by the client. | ||
118 | See the L<ciphers(1)|ciphers(1)> command for more information. | ||
119 | |||
120 | =item B<-time length> | ||
121 | |||
122 | specifies how long (in seconds) B<s_time> should establish connections and | ||
123 | optionally transfer payload data from a server. Server and client performance | ||
124 | and the link speed determine how many connections B<s_time> can establish. | ||
125 | |||
126 | =back | ||
127 | |||
128 | =head1 NOTES | ||
129 | |||
130 | B<s_client> can be used to measure the performance of an SSL connection. | ||
131 | To connect to an SSL HTTP server and get the default page the command | ||
132 | |||
133 | openssl s_time -connect servername:443 -www / -CApath yourdir -CAfile yourfile.pem -cipher commoncipher [-ssl3] | ||
134 | |||
135 | would typically be used (https uses port 443). 'commoncipher' is a cipher to | ||
136 | which both client and server can agree, see the L<ciphers(1)|ciphers(1)> command | ||
137 | for details. | ||
138 | |||
139 | If the handshake fails then there are several possible causes, if it is | ||
140 | nothing obvious like no client certificate then the B<-bugs>, B<-ssl2>, | ||
141 | B<-ssl3> options can be tried | ||
142 | in case it is a buggy server. In particular you should play with these | ||
143 | options B<before> submitting a bug report to an OpenSSL mailing list. | ||
144 | |||
145 | A frequent problem when attempting to get client certificates working | ||
146 | is that a web client complains it has no certificates or gives an empty | ||
147 | list to choose from. This is normally because the server is not sending | ||
148 | the clients certificate authority in its "acceptable CA list" when it | ||
149 | requests a certificate. By using L<s_client(1)|s_client(1)> the CA list can be | ||
150 | viewed and checked. However some servers only request client authentication | ||
151 | after a specific URL is requested. To obtain the list in this case it | ||
152 | is necessary to use the B<-prexit> option of L<s_client(1)|s_client(1)> and | ||
153 | send an HTTP request for an appropriate page. | ||
154 | |||
155 | If a certificate is specified on the command line using the B<-cert> | ||
156 | option it will not be used unless the server specifically requests | ||
157 | a client certificate. Therefor merely including a client certificate | ||
158 | on the command line is no guarantee that the certificate works. | ||
159 | |||
160 | =head1 BUGS | ||
161 | |||
162 | Because this program does not have all the options of the | ||
163 | L<s_client(1)|s_client(1)> program to turn protocols on and off, you may not be | ||
164 | able to measure the performance of all protocols with all servers. | ||
165 | |||
166 | The B<-verify> option should really exit if the server verification | ||
167 | fails. | ||
168 | |||
169 | =head1 SEE ALSO | ||
170 | |||
171 | L<s_client(1)|s_client(1)>, L<s_server(1)|s_server(1)>, L<ciphers(1)|ciphers(1)> | ||
172 | |||
173 | =cut | ||
diff --git a/src/lib/libssl/src/doc/crypto/CONF_modules_free.pod b/src/lib/libssl/src/doc/crypto/CONF_modules_free.pod new file mode 100644 index 0000000000..af8ae6a5c9 --- /dev/null +++ b/src/lib/libssl/src/doc/crypto/CONF_modules_free.pod | |||
@@ -0,0 +1,47 @@ | |||
1 | =pod | ||
2 | |||
3 | =head1 NAME | ||
4 | |||
5 | CONF_modules_free, CONF_modules_load, CONF_modules_unload - | ||
6 | OpenSSL configuration cleanup functions | ||
7 | |||
8 | =head1 SYNOPSIS | ||
9 | |||
10 | #include <openssl/conf.h> | ||
11 | |||
12 | void CONF_modules_free(void); | ||
13 | void CONF_modules_unload(int all); | ||
14 | void CONF_modules_finish(void); | ||
15 | |||
16 | =head1 DESCRIPTION | ||
17 | |||
18 | CONF_modules_free() closes down and frees up all memory allocated by all | ||
19 | configuration modules. | ||
20 | |||
21 | CONF_modules_finish() calls each configuration modules B<finish> handler | ||
22 | to free up any configuration that module may have performed. | ||
23 | |||
24 | CONF_modules_unload() finishes and unloads configuration modules. If | ||
25 | B<all> is set to B<0> only modules loaded from DSOs will be unloads. If | ||
26 | B<all> is B<1> all modules, including builtin modules will be unloaded. | ||
27 | |||
28 | =head1 NOTES | ||
29 | |||
30 | Normally applications will only call CONF_modules_free() at application to | ||
31 | tidy up any configuration performed. | ||
32 | |||
33 | =head1 RETURN VALUE | ||
34 | |||
35 | None of the functions return a value. | ||
36 | |||
37 | =head1 SEE ALSO | ||
38 | |||
39 | L<conf(5)|conf(5)>, L<OPENSSL_config(3)|OPENSSL_config(3)>, | ||
40 | L<CONF_modules_load_file(3), CONF_modules_load_file(3)> | ||
41 | |||
42 | =head1 HISTORY | ||
43 | |||
44 | CONF_modules_free(), CONF_modules_unload(), and CONF_modules_finish() | ||
45 | first appeared in OpenSSL 0.9.7. | ||
46 | |||
47 | =cut | ||
diff --git a/src/lib/libssl/src/doc/crypto/CONF_modules_load_file.pod b/src/lib/libssl/src/doc/crypto/CONF_modules_load_file.pod new file mode 100644 index 0000000000..9965d69bf2 --- /dev/null +++ b/src/lib/libssl/src/doc/crypto/CONF_modules_load_file.pod | |||
@@ -0,0 +1,60 @@ | |||
1 | =pod | ||
2 | |||
3 | =head1 NAME | ||
4 | |||
5 | CONF_modules_load_file, CONF_modules_load - OpenSSL configuration functions | ||
6 | |||
7 | =head1 SYNOPSIS | ||
8 | |||
9 | #include <openssl/conf.h> | ||
10 | |||
11 | int CONF_modules_load_file(const char *filename, const char *appname, | ||
12 | unsigned long flags); | ||
13 | int CONF_modules_load(const CONF *cnf, const char *appname, | ||
14 | unsigned long flags); | ||
15 | |||
16 | =head1 DESCRIPTION | ||
17 | |||
18 | The function CONF_modules_load_file() configures OpenSSL using file | ||
19 | B<filename> and application name B<appname>. If B<filename> is NULL | ||
20 | the standard OpenSSL configuration file is used. If B<appname> is | ||
21 | NULL the standard OpenSSL application name B<openssl_conf> is used. | ||
22 | The behaviour can be cutomized using B<flags>. | ||
23 | |||
24 | CONF_modules_load() is idential to CONF_modules_load_file() except it | ||
25 | read configuration information from B<cnf>. | ||
26 | |||
27 | =head1 NOTES | ||
28 | |||
29 | The following B<flags> are currently recognized: | ||
30 | |||
31 | B<CONF_MFLAGS_IGNORE_ERRORS> if set errors returned by individual | ||
32 | configuration modules are ignored. If not set the first module error is | ||
33 | considered fatal and no further modules are loads. | ||
34 | |||
35 | Normally any modules errors will add error information to the error queue. If | ||
36 | B<CONF_MFLAGS_SILENT> is set no error information is added. | ||
37 | |||
38 | If B<CONF_MFLAGS_NO_DSO> is set configuration module loading from DSOs is | ||
39 | disabled. | ||
40 | |||
41 | B<CONF_MFLAGS_IGNORE_MISSING_FILE> if set will make CONF_load_modules_file() | ||
42 | ignore missing configuration files. Normally a missing configuration file | ||
43 | return an error. | ||
44 | |||
45 | =head1 RETURN VALUE | ||
46 | |||
47 | These functions return 1 for success and a zero or negative value for | ||
48 | failure. If module errors are not ignored the return code will reflect the | ||
49 | return value of the failing module (this will always be zero or negative). | ||
50 | |||
51 | =head1 SEE ALSO | ||
52 | |||
53 | L<conf(5)|conf(5)>, L<OPENSSL_config(3)|OPENSSL_config(3)>, | ||
54 | L<CONF_free(3), CONF_free(3)>, L<err(3),err(3)> | ||
55 | |||
56 | =head1 HISTORY | ||
57 | |||
58 | CONF_modules_load_file and CONF_modules_load first appeared in OpenSSL 0.9.7. | ||
59 | |||
60 | =cut | ||
diff --git a/src/lib/libssl/src/doc/crypto/OPENSSL_config.pod b/src/lib/libssl/src/doc/crypto/OPENSSL_config.pod new file mode 100644 index 0000000000..16600620cc --- /dev/null +++ b/src/lib/libssl/src/doc/crypto/OPENSSL_config.pod | |||
@@ -0,0 +1,82 @@ | |||
1 | =pod | ||
2 | |||
3 | =head1 NAME | ||
4 | |||
5 | OPENSSL_config, OPENSSL_no_config - simple OpenSSL configuration functions | ||
6 | |||
7 | =head1 SYNOPSIS | ||
8 | |||
9 | #include <openssl/conf.h> | ||
10 | |||
11 | void OPENSSL_config(const char *config_name); | ||
12 | void OPENSSL_no_config(void); | ||
13 | |||
14 | =head1 DESCRIPTION | ||
15 | |||
16 | OPENSSL_config() configures OpenSSL using the standard B<openssl.cnf> | ||
17 | configuration file name using B<config_name>. If B<config_name> is NULL then | ||
18 | the default name B<openssl_conf> will be used. Any errors are ignored. Further | ||
19 | calls to OPENSSL_config() will have no effect. The configuration file format | ||
20 | is documented in the L<conf(5)|conf(5)> manual page. | ||
21 | |||
22 | OPENSSL_no_config() disables configuration. If called before OPENSSL_config() | ||
23 | no configuration takes place. | ||
24 | |||
25 | =head1 NOTES | ||
26 | |||
27 | It is B<strongly> recommended that B<all> new applications call OPENSSL_config() | ||
28 | or the more sophisticated functions such as CONF_modules_load() during | ||
29 | initialization (that is before starting any threads). By doing this | ||
30 | an application does not need to keep track of all configuration options | ||
31 | and some new functionality can be supported automatically. | ||
32 | |||
33 | It is also possible to automatically call OPENSSL_config() when an application | ||
34 | calls OPENSSL_add_all_algorithms() by compiling an application with the | ||
35 | preprocessor symbol B<OPENSSL_LOAD_CONF> #define'd. In this way configuration | ||
36 | can be added without source changes. | ||
37 | |||
38 | The environment variable B<OPENSSL_CONFIG> can be set to specify the location | ||
39 | of the configuration file. | ||
40 | |||
41 | Currently ASN1 OBJECTs and ENGINE configuration can be performed future | ||
42 | versions of OpenSSL will add new configuration options. | ||
43 | |||
44 | There are several reasons why calling the OpenSSL configuration routines is | ||
45 | advisable. For example new ENGINE functionality was added to OpenSSL 0.9.7. | ||
46 | In OpenSSL 0.9.7 control functions can be supported by ENGINEs, this can be | ||
47 | used (among other things) to load dynamic ENGINEs from shared libraries (DSOs). | ||
48 | However very few applications currently support the control interface and so | ||
49 | very few can load and use dynamic ENGINEs. Equally in future more sophisticated | ||
50 | ENGINEs will require certain control operations to customize them. If an | ||
51 | application calls OPENSSL_config() it doesn't need to know or care about | ||
52 | ENGINE control operations because they can be performed by editing a | ||
53 | configuration file. | ||
54 | |||
55 | Applications should free up configuration at application closedown by calling | ||
56 | CONF_modules_free(). | ||
57 | |||
58 | =head1 RESTRICTIONS | ||
59 | |||
60 | The OPENSSL_config() function is designed to be a very simple "call it and | ||
61 | forget it" function. As a result its behaviour is somewhat limited. It ignores | ||
62 | all errors silently and it can only load from the standard configuration file | ||
63 | location for example. | ||
64 | |||
65 | It is however B<much> better than nothing. Applications which need finer | ||
66 | control over their configuration functionality should use the configuration | ||
67 | functions such as CONF_load_modules() directly. | ||
68 | |||
69 | =head1 RETURN VALUES | ||
70 | |||
71 | Neither OPENSSL_config() nor OPENSSL_no_config() return a value. | ||
72 | |||
73 | =head1 SEE ALSO | ||
74 | |||
75 | L<conf(5)|conf(5)>, L<CONF_load_modules_file(3)|CONF_load_modules_file(3)>, | ||
76 | L<CONF_modules_free(3),CONF_modules_free(3)> | ||
77 | |||
78 | =head1 HISTORY | ||
79 | |||
80 | OPENSSL_config() and OPENSSL_no_config() first appeared in OpenSSL 0.9.7 | ||
81 | |||
82 | =cut | ||
diff --git a/src/lib/libssl/src/doc/crypto/OPENSSL_load_builtin_modules.pod b/src/lib/libssl/src/doc/crypto/OPENSSL_load_builtin_modules.pod new file mode 100644 index 0000000000..f14dfaf005 --- /dev/null +++ b/src/lib/libssl/src/doc/crypto/OPENSSL_load_builtin_modules.pod | |||
@@ -0,0 +1,51 @@ | |||
1 | =pod | ||
2 | |||
3 | =head1 NAME | ||
4 | |||
5 | OPENSSL_load_builtin_modules - add standard configuration modules | ||
6 | |||
7 | =head1 SYNOPSIS | ||
8 | |||
9 | #include <openssl/conf.h> | ||
10 | |||
11 | void OPENSSL_load_builtin_modules(void); | ||
12 | void ASN1_add_oid_module(void); | ||
13 | ENGINE_add_conf_module(); | ||
14 | |||
15 | =head1 DESCRIPTION | ||
16 | |||
17 | The function OPENSSL_load_builtin_modules() adds all the standard OpenSSL | ||
18 | configuration modules to the internal list. They can then be used by the | ||
19 | OpenSSL configuration code. | ||
20 | |||
21 | ASN1_add_oid_module() adds just the ASN1 OBJECT module. | ||
22 | |||
23 | ENGINE_add_conf_module() adds just the ENGINE configuration module. | ||
24 | |||
25 | =head1 NOTES | ||
26 | |||
27 | If the simple configuration function OPENSSL_config() is called then | ||
28 | OPENSSL_load_builtin_modules() is called automatically. | ||
29 | |||
30 | Applications which use the configuration functions directly will need to | ||
31 | call OPENSSL_load_builtin_modules() themselves I<before> any other | ||
32 | configuration code. | ||
33 | |||
34 | Applications should call OPENSSL_load_builtin_modules() to load all | ||
35 | configuration modules instead of adding modules selectively: otherwise | ||
36 | functionality may be missing from the application if an when new | ||
37 | modules are added. | ||
38 | |||
39 | =head1 RETURN VALUE | ||
40 | |||
41 | None of the functions return a value. | ||
42 | |||
43 | =head1 SEE ALSO | ||
44 | |||
45 | L<conf(3)|conf(3)>, L<OPENSSL_config(3)|OPENSSL_config(3)> | ||
46 | |||
47 | =head1 HISTORY | ||
48 | |||
49 | These functions first appeared in OpenSSL 0.9.7. | ||
50 | |||
51 | =cut | ||
diff --git a/src/lib/libssl/src/doc/crypto/d2i_DSAPublicKey.pod b/src/lib/libssl/src/doc/crypto/d2i_DSAPublicKey.pod index 6ebd30427b..22c1b50f22 100644 --- a/src/lib/libssl/src/doc/crypto/d2i_DSAPublicKey.pod +++ b/src/lib/libssl/src/doc/crypto/d2i_DSAPublicKey.pod | |||
@@ -9,6 +9,7 @@ and parsing functions. | |||
9 | =head1 SYNOPSIS | 9 | =head1 SYNOPSIS |
10 | 10 | ||
11 | #include <openssl/dsa.h> | 11 | #include <openssl/dsa.h> |
12 | #include <openssl/x509.h> | ||
12 | 13 | ||
13 | DSA * d2i_DSAPublicKey(DSA **a, const unsigned char **pp, long length); | 14 | DSA * d2i_DSAPublicKey(DSA **a, const unsigned char **pp, long length); |
14 | 15 | ||
@@ -35,8 +36,8 @@ and parsing functions. | |||
35 | d2i_DSAPublicKey() and i2d_DSAPublicKey() decode and encode the DSA public key | 36 | d2i_DSAPublicKey() and i2d_DSAPublicKey() decode and encode the DSA public key |
36 | components structure. | 37 | components structure. |
37 | 38 | ||
38 | d2i_DSA_PUKEY() and i2d_DSA_PUKEY() decode and encode an DSA public key using a | 39 | d2i_DSA_PUBKEY() and i2d_DSA_PUBKEY() decode and encode an DSA public key using |
39 | SubjectPublicKeyInfo (certificate public key) structure. | 40 | a SubjectPublicKeyInfo (certificate public key) structure. |
40 | 41 | ||
41 | d2i_DSAPrivateKey(), i2d_DSAPrivateKey() decode and encode the DSA private key | 42 | d2i_DSAPrivateKey(), i2d_DSAPrivateKey() decode and encode the DSA private key |
42 | components. | 43 | components. |
diff --git a/src/lib/libssl/src/os2/backwardify.pl b/src/lib/libssl/src/os2/backwardify.pl new file mode 100644 index 0000000000..272423c8fa --- /dev/null +++ b/src/lib/libssl/src/os2/backwardify.pl | |||
@@ -0,0 +1,32 @@ | |||
1 | #!/usr/bin/perl -w | ||
2 | use strict; | ||
3 | |||
4 | # Use as $0 | ||
5 | # Use as $0 -noname | ||
6 | |||
7 | my $did_library; | ||
8 | my $did_description; | ||
9 | my $do_exports; | ||
10 | my @imports; | ||
11 | my $noname = (@ARGV and $ARGV[0] eq '-noname' and shift); | ||
12 | while (<>) { | ||
13 | unless ($did_library) { | ||
14 | s/\b(cryptssl)\b/crypto/ and $did_library = $1 if /^LIBRARY\s+cryptssl\b/; | ||
15 | s/\b(open_ssl)\b/ssl/ and $did_library = $1 if /^LIBRARY\s+open_ssl\b/; | ||
16 | } | ||
17 | unless ($did_description) { | ||
18 | s&^(DESCRIPTION\s+(['"])).*&${1}\@#www.openssl.org/:#\@forwarder DLL for pre-0.9.7c+ OpenSSL to the new dll naming scheme$2& and $did_description++; | ||
19 | } | ||
20 | if ($do_exports) {{ | ||
21 | last unless /\S/; | ||
22 | warn, last unless /^ \s* ( \w+ ) \s+ \@(\d+)\s*$/x; | ||
23 | push @imports, [$1, $2]; | ||
24 | s/$/ NONAME/ if $noname; | ||
25 | }} | ||
26 | $do_exports++ if not $do_exports and /^EXPORTS/; | ||
27 | print $_; | ||
28 | } | ||
29 | print "IMPORTS\n"; | ||
30 | for my $imp (@imports) { | ||
31 | print "\t$imp->[0]=$did_library.$imp->[1]\n"; | ||
32 | } | ||
diff --git a/src/lib/libssl/src/util/extract-names.pl b/src/lib/libssl/src/util/extract-names.pl index 9f2ad5ef16..744a8e2324 100644 --- a/src/lib/libssl/src/util/extract-names.pl +++ b/src/lib/libssl/src/util/extract-names.pl | |||
@@ -10,6 +10,8 @@ while(<STDIN>) { | |||
10 | if (/ - /) { | 10 | if (/ - /) { |
11 | s/ - .*//; | 11 | s/ - .*//; |
12 | s/,[ \t]+/,/g; | 12 | s/,[ \t]+/,/g; |
13 | s/^[ \t]+//g; | ||
14 | s/[ \t]+$//g; | ||
13 | push @words, split ','; | 15 | push @words, split ','; |
14 | } | 16 | } |
15 | } | 17 | } |