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

Side by Side Diff: openssl/crypto/evp/e_idea.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/crypto/evp/e_des3.c ('k') | openssl/crypto/evp/e_null.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 /* crypto/evp/e_idea.c */ 1 /* crypto/evp/e_idea.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 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 #include <openssl/idea.h> 66 #include <openssl/idea.h>
67 67
68 static int idea_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key, 68 static int idea_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key,
69 const unsigned char *iv,int enc); 69 const unsigned char *iv,int enc);
70 70
71 /* NB idea_ecb_encrypt doesn't take an 'encrypt' argument so we treat it as a sp ecial 71 /* NB idea_ecb_encrypt doesn't take an 'encrypt' argument so we treat it as a sp ecial
72 * case 72 * case
73 */ 73 */
74 74
75 static int idea_ecb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out, 75 static int idea_ecb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
76 » » » const unsigned char *in, unsigned int inl) 76 » » » const unsigned char *in, size_t inl)
77 { 77 {
78 BLOCK_CIPHER_ecb_loop() 78 BLOCK_CIPHER_ecb_loop()
79 idea_ecb_encrypt(in + i, out + i, ctx->cipher_data); 79 idea_ecb_encrypt(in + i, out + i, ctx->cipher_data);
80 return 1; 80 return 1;
81 } 81 }
82 82
83 /* Can't use IMPLEMENT_BLOCK_CIPHER because idea_ecb_encrypt is different */ 83 /* Can't use IMPLEMENT_BLOCK_CIPHER because idea_ecb_encrypt is different */
84 84
85 typedef struct 85 typedef struct
86 { 86 {
(...skipping 22 matching lines...) Expand all
109 109
110 idea_set_encrypt_key(key,&tmp); 110 idea_set_encrypt_key(key,&tmp);
111 idea_set_decrypt_key(&tmp,ctx->cipher_data); 111 idea_set_decrypt_key(&tmp,ctx->cipher_data);
112 OPENSSL_cleanse((unsigned char *)&tmp, 112 OPENSSL_cleanse((unsigned char *)&tmp,
113 sizeof(IDEA_KEY_SCHEDULE)); 113 sizeof(IDEA_KEY_SCHEDULE));
114 } 114 }
115 return 1; 115 return 1;
116 } 116 }
117 117
118 #endif 118 #endif
OLDNEW
« no previous file with comments | « openssl/crypto/evp/e_des3.c ('k') | openssl/crypto/evp/e_null.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698