Ruby
3.1.0dev(2021-09-10revisionb76ad15ed0da636161de0243c547ee1e6fc95681)
|
Go to the source code of this file.
Macros | |
#define | OSSL_PKEY_SET_PRIVATE(obj) rb_iv_set((obj), "private", Qtrue) |
#define | OSSL_PKEY_SET_PUBLIC(obj) rb_iv_set((obj), "private", Qfalse) |
#define | OSSL_PKEY_IS_PRIVATE(obj) (rb_iv_get((obj), "private") == Qtrue) |
#define | NewPKey(klass) TypedData_Wrap_Struct((klass), &ossl_evp_pkey_type, 0) |
#define | SetPKey(obj, pkey) |
#define | GetPKey(obj, pkey) |
#define | OSSL_PKEY_BN_DEF_GETTER0(_keytype, _type, _name, _get) |
#define | OSSL_PKEY_BN_DEF_GETTER3(_keytype, _type, _group, a1, a2, a3) |
#define | OSSL_PKEY_BN_DEF_GETTER2(_keytype, _type, _group, a1, a2) |
#define | OSSL_PKEY_BN_DEF_SETTER3(_keytype, _type, _group, a1, a2, a3) |
#define | OSSL_PKEY_BN_DEF_SETTER2(_keytype, _type, _group, a1, a2) |
#define | OSSL_PKEY_BN_DEF3(_keytype, _type, _group, a1, a2, a3) |
#define | OSSL_PKEY_BN_DEF2(_keytype, _type, _group, a1, a2) |
#define | DEF_OSSL_PKEY_BN(class, keytype, name) rb_define_method((class), #name, ossl_##keytype##_get_##name, 0) |
Functions | |
VALUE | ossl_pkey_new (EVP_PKEY *) |
void | ossl_pkey_check_public_key (const EVP_PKEY *) |
EVP_PKEY * | ossl_pkey_read_generic (BIO *, VALUE) |
EVP_PKEY * | GetPKeyPtr (VALUE) |
EVP_PKEY * | DupPKeyPtr (VALUE) |
EVP_PKEY * | GetPrivPKeyPtr (VALUE) |
VALUE | ossl_pkey_export_spki (VALUE self, int to_der) |
VALUE | ossl_pkey_export_traditional (int argc, VALUE *argv, VALUE self, int to_der) |
void | Init_ossl_pkey (void) |
void | Init_ossl_rsa (void) |
void | Init_ossl_dsa (void) |
void | Init_ossl_dh (void) |
VALUE | ossl_ec_new (EVP_PKEY *) |
void | Init_ossl_ec (void) |
#define DEF_OSSL_PKEY_BN | ( | class, | |
keytype, | |||
name | |||
) | rb_define_method((class), #name, ossl_##keytype##_get_##name, 0) |
Definition at line 184 of file ossl_pkey.h.
#define GetPKey | ( | obj, | |
pkey | |||
) |
Definition at line 31 of file ossl_pkey.h.
#define NewPKey | ( | klass | ) | TypedData_Wrap_Struct((klass), &ossl_evp_pkey_type, 0) |
Definition at line 22 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF2 | ( | _keytype, | |
_type, | |||
_group, | |||
a1, | |||
a2 | |||
) |
Definition at line 180 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF3 | ( | _keytype, | |
_type, | |||
_group, | |||
a1, | |||
a2, | |||
a3 | |||
) |
Definition at line 176 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF_GETTER0 | ( | _keytype, | |
_type, | |||
_name, | |||
_get | |||
) |
Definition at line 96 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF_GETTER2 | ( | _keytype, | |
_type, | |||
_group, | |||
a1, | |||
a2 | |||
) |
Definition at line 118 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF_GETTER3 | ( | _keytype, | |
_type, | |||
_group, | |||
a1, | |||
a2, | |||
a3 | |||
) |
Definition at line 110 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF_SETTER2 | ( | _keytype, | |
_type, | |||
_group, | |||
a1, | |||
a2 | |||
) |
Definition at line 152 of file ossl_pkey.h.
#define OSSL_PKEY_BN_DEF_SETTER3 | ( | _keytype, | |
_type, | |||
_group, | |||
a1, | |||
a2, | |||
a3 | |||
) |
Definition at line 124 of file ossl_pkey.h.
#define OSSL_PKEY_IS_PRIVATE | ( | obj | ) | (rb_iv_get((obj), "private") == Qtrue) |
Definition at line 20 of file ossl_pkey.h.
#define OSSL_PKEY_SET_PRIVATE | ( | obj | ) | rb_iv_set((obj), "private", Qtrue) |
Definition at line 18 of file ossl_pkey.h.
#define OSSL_PKEY_SET_PUBLIC | ( | obj | ) | rb_iv_set((obj), "private", Qfalse) |
Definition at line 19 of file ossl_pkey.h.
#define SetPKey | ( | obj, | |
pkey | |||
) |
Definition at line 24 of file ossl_pkey.h.
EVP_PKEY* DupPKeyPtr | ( | VALUE | ) |
Definition at line 462 of file ossl_pkey.c.
References EVP_PKEY_up_ref, GetPKey, and pkey_blocking_generate_arg::pkey.
EVP_PKEY* GetPKeyPtr | ( | VALUE | ) |
Definition at line 432 of file ossl_pkey.c.
References GetPKey, and pkey_blocking_generate_arg::pkey.
EVP_PKEY* GetPrivPKeyPtr | ( | VALUE | ) |
Definition at line 442 of file ossl_pkey.c.
References GetPKey, OSSL_PKEY_IS_PRIVATE, pkey_blocking_generate_arg::pkey, and rb_respond_to().
void Init_ossl_dh | ( | void | ) |
Definition at line 331 of file ossl_pkey_dh.c.
References cDH, cPKey, eDHError, eOSSLError, ePKeyError, mOSSL, mPKey, rb_cObject, rb_define_class_under(), rb_define_method, and rb_define_module_under().
void Init_ossl_dsa | ( | void | ) |
Definition at line 288 of file ossl_pkey_dsa.c.
References cDSA, cPKey, eDSAError, eOSSLError, ePKeyError, mOSSL, mPKey, rb_cObject, rb_define_class_under(), rb_define_method, and rb_define_module_under().
void Init_ossl_ec | ( | void | ) |
Definition at line 1462 of file ossl_pkey_ec.c.
References cEC, cEC_GROUP, cEC_POINT, cPKey, eEC_GROUP, eEC_POINT, eECError, eOSSLError, ePKeyError, mOSSL, mPKey, rb_cObject, rb_define_class_under(), rb_define_module_under(), and rb_eStandardError.
void Init_ossl_pkey | ( | void | ) |
Definition at line 1399 of file ossl_pkey.c.
References cPKey, eOSSLError, ePKeyError, mOSSL, mPKey, rb_cObject, rb_define_class_under(), rb_define_module(), rb_define_module_function, rb_define_module_under(), and rb_eStandardError.
void Init_ossl_rsa | ( | void | ) |
Definition at line 491 of file ossl_pkey_rsa.c.
References cPKey, cRSA, eOSSLError, ePKeyError, eRSAError, mOSSL, mPKey, rb_cObject, rb_define_class_under(), rb_define_method, and rb_define_module_under().
VALUE ossl_ec_new | ( | EVP_PKEY * | ) |
void ossl_pkey_check_public_key | ( | const EVP_PKEY * | ) |
Definition at line 392 of file ossl_pkey.c.
References ePKeyError, NULL, ossl_raise(), pkey_blocking_generate_arg::pkey, and ptr.
Definition at line 695 of file ossl_pkey.c.
References ePKeyError, GetPKey, ossl_membio2str(), ossl_raise(), and pkey_blocking_generate_arg::pkey.
Definition at line 580 of file ossl_pkey.c.
References argc, argv, ePKeyError, GetPKey, NIL_P, NULL, ossl_evp_get_cipherbyname(), ossl_membio2str(), ossl_pem_passwd_cb(), ossl_pem_passwd_value(), ossl_raise(), pkey_blocking_generate_arg::pkey, rb_scan_args(), and snprintf.
VALUE ossl_pkey_new | ( | EVP_PKEY * | ) |
Definition at line 67 of file ossl_pkey.c.
References rb_protect().
EVP_PKEY* ossl_pkey_read_generic | ( | BIO * | , |
VALUE | |||
) |
Definition at line 82 of file ossl_pkey.c.
References NULL, OSSL_BIO_reset, and ossl_pem_passwd_cb().
VALUE cDH |
Definition at line 29 of file ossl_pkey_dh.c.
Referenced by Init_ossl_dh().
VALUE cDSA |
Definition at line 43 of file ossl_pkey_dsa.c.
Referenced by Init_ossl_dsa().
VALUE cEC |
Definition at line 43 of file ossl_pkey_ec.c.
Referenced by Init_ossl_ec().
VALUE cEC_GROUP |
Definition at line 45 of file ossl_pkey_ec.c.
Referenced by Init_ossl_ec().
VALUE cEC_POINT |
Definition at line 47 of file ossl_pkey_ec.c.
Referenced by Init_ossl_ec().
VALUE cPKey |
Definition at line 16 of file ossl_pkey.c.
Referenced by Init_ossl_dh(), Init_ossl_dsa(), Init_ossl_ec(), Init_ossl_pkey(), and Init_ossl_rsa().
VALUE cRSA |
Definition at line 44 of file ossl_pkey_rsa.c.
Referenced by Init_ossl_rsa().
VALUE eDHError |
Definition at line 30 of file ossl_pkey_dh.c.
Referenced by Init_ossl_dh().
VALUE eDSAError |
Definition at line 44 of file ossl_pkey_dsa.c.
Referenced by Init_ossl_dsa().
VALUE eEC_GROUP |
Definition at line 46 of file ossl_pkey_ec.c.
Referenced by Init_ossl_ec().
VALUE eEC_POINT |
Definition at line 48 of file ossl_pkey_ec.c.
Referenced by Init_ossl_ec().
VALUE eECError |
Definition at line 44 of file ossl_pkey_ec.c.
Referenced by Init_ossl_ec().
VALUE ePKeyError |
Definition at line 17 of file ossl_pkey.c.
Referenced by Init_ossl_dh(), Init_ossl_dsa(), Init_ossl_ec(), Init_ossl_pkey(), Init_ossl_rsa(), ossl_pkey_check_public_key(), ossl_pkey_export_spki(), and ossl_pkey_export_traditional().
VALUE eRSAError |
Definition at line 45 of file ossl_pkey_rsa.c.
Referenced by Init_ossl_rsa().
VALUE mPKey |
Definition at line 15 of file ossl_pkey.c.
Referenced by Init_ossl_dh(), Init_ossl_dsa(), Init_ossl_ec(), Init_ossl_pkey(), and Init_ossl_rsa().
const rb_data_type_t ossl_evp_pkey_type |
Definition at line 29 of file ossl_pkey.c.