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

Side by Side Diff: openssl/crypto/rand/rand.h

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/rand/md_rand.c ('k') | openssl/crypto/rand/rand_egd.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/rand/rand.h */ 1 /* crypto/rand/rand.h */
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 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 65
66 #if defined(OPENSSL_SYS_WINDOWS) 66 #if defined(OPENSSL_SYS_WINDOWS)
67 #include <windows.h> 67 #include <windows.h>
68 #endif 68 #endif
69 69
70 #ifdef __cplusplus 70 #ifdef __cplusplus
71 extern "C" { 71 extern "C" {
72 #endif 72 #endif
73 73
74 #if defined(OPENSSL_FIPS) 74 #if defined(OPENSSL_FIPS)
75 #define FIPS_RAND_SIZE_T int 75 #define FIPS_RAND_SIZE_T size_t
76 #endif 76 #endif
77 77
78 /* Already defined in ossl_typ.h */ 78 /* Already defined in ossl_typ.h */
79 /* typedef struct rand_meth_st RAND_METHOD; */ 79 /* typedef struct rand_meth_st RAND_METHOD; */
80 80
81 struct rand_meth_st 81 struct rand_meth_st
82 { 82 {
83 void (*seed)(const void *buf, int num); 83 void (*seed)(const void *buf, int num);
84 int (*bytes)(unsigned char *buf, int num); 84 int (*bytes)(unsigned char *buf, int num);
85 void (*cleanup)(void); 85 void (*cleanup)(void);
(...skipping 18 matching lines...) Expand all
104 void RAND_seed(const void *buf,int num); 104 void RAND_seed(const void *buf,int num);
105 void RAND_add(const void *buf,int num,double entropy); 105 void RAND_add(const void *buf,int num,double entropy);
106 int RAND_load_file(const char *file,long max_bytes); 106 int RAND_load_file(const char *file,long max_bytes);
107 int RAND_write_file(const char *file); 107 int RAND_write_file(const char *file);
108 const char *RAND_file_name(char *file,size_t num); 108 const char *RAND_file_name(char *file,size_t num);
109 int RAND_status(void); 109 int RAND_status(void);
110 int RAND_query_egd_bytes(const char *path, unsigned char *buf, int bytes); 110 int RAND_query_egd_bytes(const char *path, unsigned char *buf, int bytes);
111 int RAND_egd(const char *path); 111 int RAND_egd(const char *path);
112 int RAND_egd_bytes(const char *path,int bytes); 112 int RAND_egd_bytes(const char *path,int bytes);
113 int RAND_poll(void); 113 int RAND_poll(void);
114 #ifndef OPENSSL_NO_ENGINE
115 #ifdef OPENSSL_FIPS
116 void int_RAND_init_engine_callbacks(void);
117 void int_RAND_set_callbacks(
118 int (*set_rand_func)(const RAND_METHOD *meth,
119 const RAND_METHOD **pmeth),
120 const RAND_METHOD *(*get_rand_func)(const RAND_METHOD **pmeth));
121 #endif
122 #endif
123 114
124 #if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_WIN32) 115 #if defined(OPENSSL_SYS_WINDOWS) || defined(OPENSSL_SYS_WIN32)
125 116
126 void RAND_screen(void); 117 void RAND_screen(void);
127 int RAND_event(UINT, WPARAM, LPARAM); 118 int RAND_event(UINT, WPARAM, LPARAM);
128 119
129 #endif 120 #endif
130 121
131 /* BEGIN ERROR CODES */ 122 /* BEGIN ERROR CODES */
132 /* The following lines are auto generated by the script mkerr.pl. Any changes 123 /* The following lines are auto generated by the script mkerr.pl. Any changes
133 * made after this point may be overwritten when the script is next run. 124 * made after this point may be overwritten when the script is next run.
134 */ 125 */
135 void ERR_load_RAND_strings(void); 126 void ERR_load_RAND_strings(void);
136 127
137 /* Error codes for the RAND functions. */ 128 /* Error codes for the RAND functions. */
138 129
139 /* Function codes. */ 130 /* Function codes. */
140 #define RAND_F_ENG_RAND_GET_RAND_METHOD 108
141 #define RAND_F_FIPS_RAND 103
142 #define RAND_F_FIPS_RAND_BYTES 102
143 #define RAND_F_FIPS_RAND_GET_RAND_METHOD 109
144 #define RAND_F_FIPS_RAND_SET_DT 106
145 #define RAND_F_FIPS_SET_DT 104
146 #define RAND_F_FIPS_SET_PRNG_SEED 107
147 #define RAND_F_FIPS_SET_TEST_MODE 105
148 #define RAND_F_RAND_GET_RAND_METHOD 101 131 #define RAND_F_RAND_GET_RAND_METHOD 101
149 #define RAND_F_SSLEAY_RAND_BYTES 100 132 #define RAND_F_SSLEAY_RAND_BYTES 100
150 133
151 /* Reason codes. */ 134 /* Reason codes. */
152 #define RAND_R_NON_FIPS_METHOD 105
153 #define RAND_R_NOT_IN_TEST_MODE 106
154 #define RAND_R_NO_KEY_SET 107
155 #define RAND_R_PRNG_ASKING_FOR_TOO_MUCH 101
156 #define RAND_R_PRNG_ERROR 108
157 #define RAND_R_PRNG_KEYED 109
158 #define RAND_R_PRNG_NOT_REKEYED 102
159 #define RAND_R_PRNG_NOT_RESEEDED 103
160 #define RAND_R_PRNG_NOT_SEEDED 100 135 #define RAND_R_PRNG_NOT_SEEDED 100
161 #define RAND_R_PRNG_SEED_MUST_NOT_MATCH_KEY 110
162 #define RAND_R_PRNG_STUCK 104
163 136
164 #ifdef __cplusplus 137 #ifdef __cplusplus
165 } 138 }
166 #endif 139 #endif
167 #endif 140 #endif
OLDNEW
« no previous file with comments | « openssl/crypto/rand/md_rand.c ('k') | openssl/crypto/rand/rand_egd.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698