#include <ruby/ruby.h>
#include "../digest.h"
#include "sha2.h"
Go to the source code of this file.
◆ DECLARE_ALGO_CLASS
#define DECLARE_ALGO_CLASS |
( |
|
bitlen | ) |
VALUE cDigest_SHA##bitlen; |
◆ DEFINE_ALGO_CLASS
#define DEFINE_ALGO_CLASS |
( |
|
bitlen | ) |
|
Value:VALUE rb_define_class_under(VALUE outer, const char *name, VALUE super)
Defines a class under the namespace of outer.
#define Data_Wrap_Struct(klass, mark, free, sval)
VALUE rb_ivar_set(VALUE, ID, VALUE)
◆ DEFINE_ALGO_METADATA
#define DEFINE_ALGO_METADATA |
( |
|
bitlen | ) |
|
Value: RUBY_DIGEST_API_VERSION, \
SHA##bitlen##_DIGEST_LENGTH, \
SHA##bitlen##_BLOCK_LENGTH, \
sizeof(SHA##bitlen##_CTX), \
};
int(* rb_digest_hash_finish_func_t)(void *, unsigned char *)
void(* rb_digest_hash_update_func_t)(void *, unsigned char *, size_t)
int(* rb_digest_hash_init_func_t)(void *)
Definition at line 16 of file sha2init.c.
◆ FOREACH_BITLEN
#define FOREACH_BITLEN |
( |
|
func | ) |
func(256) func(384) func(512) |
◆ RUBY_UNTYPED_DATA_WARNING
#define RUBY_UNTYPED_DATA_WARNING 0 |
◆ Init_sha2()