Ruby  3.1.0dev(2021-09-10revisionb76ad15ed0da636161de0243c547ee1e6fc95681)
Macros | Functions | Variables
ossl_pkey_dh.c File Reference

(b76ad15ed0da636161de0243c547ee1e6fc95681)

#include "ossl.h"
Include dependency graph for ossl_pkey_dh.c:

Go to the source code of this file.

Macros

#define GetPKeyDH(obj, pkey)
 
#define GetDH(obj, dh)
 

Functions

void Init_ossl_dh (void)
 

Variables

VALUE cDH
 
VALUE eDHError
 

Macro Definition Documentation

◆ GetDH

#define GetDH (   obj,
  dh 
)
Value:
do { \
EVP_PKEY *_pkey; \
GetPKeyDH((obj), _pkey); \
(dh) = EVP_PKEY_get0_DH(_pkey); \
} while (0)

Definition at line 20 of file ossl_pkey_dh.c.

◆ GetPKeyDH

#define GetPKeyDH (   obj,
  pkey 
)
Value:
do { \
GetPKey((obj), (pkey)); \
if (EVP_PKEY_base_id(pkey) != EVP_PKEY_DH) { /* PARANOIA? */ \
ossl_raise(rb_eRuntimeError, "THIS IS NOT A DH!") ; \
} \
} while (0)

Definition at line 14 of file ossl_pkey_dh.c.

Function Documentation

◆ Init_ossl_dh()

void Init_ossl_dh ( void  )

Variable Documentation

◆ cDH

VALUE cDH

Definition at line 29 of file ossl_pkey_dh.c.

Referenced by Init_ossl_dh().

◆ eDHError

VALUE eDHError

Definition at line 30 of file ossl_pkey_dh.c.

Referenced by Init_ossl_dh().

rb_eRuntimeError
VALUE rb_eRuntimeError
Definition: error.c:1091