diff options
author | Michal Rokos <m.rokos@sh.cvut.cz> | 2001-11-20 19:39:37 +0000 |
---|---|---|
committer | Michal Rokos <m.rokos@sh.cvut.cz> | 2001-11-20 19:39:37 +0000 |
commit | e588321f8a5ae949ae246b480b1639f176be870a (patch) | |
tree | d04bf1b41dbb451360b0031c0e5a41f989e5e11f /ossl_rand.c | |
parent | cceffafefe8d78e8b7b8d0c4563ec0d48f44eed3 (diff) | |
download | ruby-openssl-history-e588321f8a5ae949ae246b480b1639f176be870a.tar.gz |
- HMAC added
- Config came back
- API changed in PKCS7 (param. order)
- API changed in Cipher (can't add data in .new)
- indentation changed (only half of files, 2nd half to do)
- some API doc added to README
Diffstat (limited to 'ossl_rand.c')
-rw-r--r-- | ossl_rand.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/ossl_rand.c b/ossl_rand.c index ed78111..f13ce29 100644 --- a/ossl_rand.c +++ b/ossl_rand.c @@ -21,20 +21,22 @@ VALUE eRandomError; */ /* - * public + * Public */ /* - * private + * Private */ -static VALUE ossl_rand_seed(VALUE self, VALUE str) +static VALUE +ossl_rand_seed(VALUE self, VALUE str) { Check_SafeStr(str); RAND_seed(RSTRING(str)->ptr, RSTRING(str)->len); return str; } -static VALUE ossl_rand_load_file(VALUE self, VALUE filename) +static VALUE +ossl_rand_load_file(VALUE self, VALUE filename) { Check_SafeStr(filename); if(!RAND_load_file(RSTRING(filename)->ptr, -1)) { @@ -44,7 +46,8 @@ static VALUE ossl_rand_load_file(VALUE self, VALUE filename) return Qtrue; } -static VALUE ossl_rand_write_file(VALUE self, VALUE filename) +static VALUE +ossl_rand_write_file(VALUE self, VALUE filename) { Check_SafeStr(filename); if (RAND_write_file(RSTRING(filename)->ptr) == -1) { @@ -54,7 +57,8 @@ static VALUE ossl_rand_write_file(VALUE self, VALUE filename) return Qtrue; } -static VALUE ossl_rand_bytes(VALUE self, VALUE len) +static VALUE +ossl_rand_bytes(VALUE self, VALUE len) { unsigned char *buffer = NULL; VALUE str; @@ -76,7 +80,7 @@ static VALUE ossl_rand_bytes(VALUE self, VALUE len) } /* - * RAND init + * INIT */ void Init_ossl_rand(VALUE mOSSL) { |