Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(130)

Side by Side Diff: openssl/ssl/ssl_txt.c

Issue 9254031: Upgrade chrome's OpenSSL to same version Android ships with. (Closed) Base URL: http://src.chromium.org/svn/trunk/deps/third_party/openssl/
Patch Set: '' Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « openssl/ssl/ssl_stat.c ('k') | openssl/ssl/ssltest.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* ssl/ssl_txt.c */ 1 /* ssl/ssl_txt.c */
2 /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2 /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
5 * This package is an SSL implementation written 5 * This package is an SSL implementation written
6 * by Eric Young (eay@cryptsoft.com). 6 * by Eric Young (eay@cryptsoft.com).
7 * The implementation was written so as to conform with Netscapes SSL. 7 * The implementation was written so as to conform with Netscapes SSL.
8 * 8 *
9 * This library is free for commercial and non-commercial use as long as 9 * This library is free for commercial and non-commercial use as long as
10 * the following conditions are aheared to. The following conditions 10 * the following conditions are aheared to. The following conditions
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 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 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 50 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
51 * SUCH DAMAGE. 51 * SUCH DAMAGE.
52 * 52 *
53 * The licence and distribution terms for any publically available version or 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 54 * derivative of this code cannot be changed. i.e. this code cannot simply be
55 * copied and put under another distribution licence 55 * copied and put under another distribution licence
56 * [including the GNU Public Licence.] 56 * [including the GNU Public Licence.]
57 */ 57 */
58 /* ====================================================================
59 * Copyright 2005 Nokia. All rights reserved.
60 *
61 * The portions of the attached software ("Contribution") is developed by
62 * Nokia Corporation and is licensed pursuant to the OpenSSL open source
63 * license.
64 *
65 * The Contribution, originally written by Mika Kousa and Pasi Eronen of
66 * Nokia Corporation, consists of the "PSK" (Pre-Shared Key) ciphersuites
67 * support (see RFC 4279) to OpenSSL.
68 *
69 * No patent licenses or other rights except those expressly stated in
70 * the OpenSSL open source license shall be deemed granted or received
71 * expressly, by implication, estoppel, or otherwise.
72 *
73 * No assurances are provided by Nokia that the Contribution does not
74 * infringe the patent or other intellectual property rights of any third
75 * party or that the license provides you with all the necessary rights
76 * to make use of the Contribution.
77 *
78 * THE SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. IN
79 * ADDITION TO THE DISCLAIMERS INCLUDED IN THE LICENSE, NOKIA
80 * SPECIFICALLY DISCLAIMS ANY LIABILITY FOR CLAIMS BROUGHT BY YOU OR ANY
81 * OTHER ENTITY BASED ON INFRINGEMENT OF INTELLECTUAL PROPERTY RIGHTS OR
82 * OTHERWISE.
83 */
58 84
59 #include <stdio.h> 85 #include <stdio.h>
60 #include <openssl/buffer.h> 86 #include <openssl/buffer.h>
61 #include "ssl_locl.h" 87 #include "ssl_locl.h"
62 88
63 #ifndef OPENSSL_NO_FP_API 89 #ifndef OPENSSL_NO_FP_API
64 int SSL_SESSION_print_fp(FILE *fp, const SSL_SESSION *x) 90 int SSL_SESSION_print_fp(FILE *fp, const SSL_SESSION *x)
65 { 91 {
66 BIO *b; 92 BIO *b;
67 int ret; 93 int ret;
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 if (x->krb5_client_princ_len == 0) 174 if (x->krb5_client_princ_len == 0)
149 { 175 {
150 if (BIO_puts(bp,"None") <= 0) goto err; 176 if (BIO_puts(bp,"None") <= 0) goto err;
151 } 177 }
152 else 178 else
153 for (i=0; i<x->krb5_client_princ_len; i++) 179 for (i=0; i<x->krb5_client_princ_len; i++)
154 { 180 {
155 if (BIO_printf(bp,"%02X",x->krb5_client_princ[i]) <= 0) goto err; 181 if (BIO_printf(bp,"%02X",x->krb5_client_princ[i]) <= 0) goto err;
156 } 182 }
157 #endif /* OPENSSL_NO_KRB5 */ 183 #endif /* OPENSSL_NO_KRB5 */
184 #ifndef OPENSSL_NO_PSK
185 if (BIO_puts(bp,"\n PSK identity: ") <= 0) goto err;
186 if (BIO_printf(bp, "%s", x->psk_identity ? x->psk_identity : "None") <= 0) goto err;
187 if (BIO_puts(bp,"\n PSK identity hint: ") <= 0) goto err;
188 if (BIO_printf(bp, "%s", x->psk_identity_hint ? x->psk_identity_hint : " None") <= 0) goto err;
189 #endif
158 #ifndef OPENSSL_NO_TLSEXT 190 #ifndef OPENSSL_NO_TLSEXT
159 if (x->tlsext_tick_lifetime_hint) 191 if (x->tlsext_tick_lifetime_hint)
160 { 192 {
161 if (BIO_printf(bp, 193 if (BIO_printf(bp,
162 "\n TLS session ticket lifetime hint: %ld (seconds)", 194 "\n TLS session ticket lifetime hint: %ld (seconds)",
163 x->tlsext_tick_lifetime_hint) <=0) 195 x->tlsext_tick_lifetime_hint) <=0)
164 goto err; 196 goto err;
165 } 197 }
166 if (x->tlsext_tick) 198 if (x->tlsext_tick)
167 { 199 {
168 if (BIO_puts(bp, "\n TLS session ticket:\n") <= 0) goto err; 200 if (BIO_puts(bp, "\n TLS session ticket:\n") <= 0) goto err;
169 if (BIO_dump_indent(bp, (char *)x->tlsext_tick, x->tlsext_tickle n, 4) <= 0) 201 if (BIO_dump_indent(bp, (char *)x->tlsext_tick, x->tlsext_tickle n, 4) <= 0)
170 goto err; 202 goto err;
171 } 203 }
172 #endif 204 #endif
205
173 #ifndef OPENSSL_NO_COMP 206 #ifndef OPENSSL_NO_COMP
174 if (x->compress_meth != 0) 207 if (x->compress_meth != 0)
175 { 208 {
176 SSL_COMP *comp = NULL; 209 SSL_COMP *comp = NULL;
177 210
178 » » ssl_cipher_get_evp(x,NULL,NULL,&comp); 211 » » ssl_cipher_get_evp(x,NULL,NULL,NULL,NULL,&comp);
179 if (comp == NULL) 212 if (comp == NULL)
180 { 213 {
181 if (BIO_printf(bp,"\n Compression: %d",x->compress_me th) <= 0) goto err; 214 if (BIO_printf(bp,"\n Compression: %d",x->compress_me th) <= 0) goto err;
182 } 215 }
183 else 216 else
184 { 217 {
185 if (BIO_printf(bp,"\n Compression: %d (%s)", comp->id ,comp->method->name) <= 0) goto err; 218 if (BIO_printf(bp,"\n Compression: %d (%s)", comp->id ,comp->method->name) <= 0) goto err;
186 } 219 }
187 } 220 }
188 #endif 221 #endif
189 if (x->time != 0L) 222 if (x->time != 0L)
190 { 223 {
191 if (BIO_printf(bp, "\n Start Time: %ld",x->time) <= 0) goto e rr; 224 if (BIO_printf(bp, "\n Start Time: %ld",x->time) <= 0) goto e rr;
192 } 225 }
193 if (x->timeout != 0L) 226 if (x->timeout != 0L)
194 { 227 {
195 if (BIO_printf(bp, "\n Timeout : %ld (sec)",x->timeout) <= 0) goto err; 228 if (BIO_printf(bp, "\n Timeout : %ld (sec)",x->timeout) <= 0) goto err;
196 } 229 }
197 if (BIO_puts(bp,"\n") <= 0) goto err; 230 if (BIO_puts(bp,"\n") <= 0) goto err;
198 231
199 if (BIO_puts(bp, " Verify return code: ") <= 0) goto err; 232 if (BIO_puts(bp, " Verify return code: ") <= 0) goto err;
200 if (BIO_printf(bp, "%ld (%s)\n", x->verify_result, 233 if (BIO_printf(bp, "%ld (%s)\n", x->verify_result,
201 X509_verify_cert_error_string(x->verify_result)) <= 0) goto err; 234 X509_verify_cert_error_string(x->verify_result)) <= 0) goto err;
202 235
203 return(1); 236 return(1);
204 err: 237 err:
205 return(0); 238 return(0);
206 } 239 }
207 240
OLDNEW
« no previous file with comments | « openssl/ssl/ssl_stat.c ('k') | openssl/ssl/ssltest.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698