Ruby: ext/openssl/ossl_x509.h Source File

Ruby 3.0.5p211 (2022-11-24 revision ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf)

ossl_x509.h
Go to the documentation of this file.
1/*
2 * 'OpenSSL for Ruby' project
3 * Copyright (C) 2001-2002 Michal Rokos <m.rokos@sh.cvut.cz>
4 * All rights reserved.
5 */
6/*
7 * This program is licensed under the same licence as Ruby.
8 * (See the file 'LICENCE'.)
9 */
10#if !defined(_OSSL_X509_H_)
11#define _OSSL_X509_H_
12
13/*
14 * X509 main module
15 */
16extern VALUE mX509;
17
18/*
19 * Converts the VALUE into Integer and set it to the ASN1_TIME. This is a
20 * wrapper for X509_time_adj_ex() so passing NULL creates a new ASN1_TIME.
21 * Note that the caller must check the NULL return.
22 */
23ASN1_TIME *ossl_x509_time_adjust(ASN1_TIME *, VALUE);
24
25void Init_ossl_x509(void);
26
27/*
28 * X509Attr
29 */
30extern VALUE cX509Attr;
31extern VALUE eX509AttrError;
32
33 VALUE ossl_x509attr_new(X509_ATTRIBUTE *);
34X509_ATTRIBUTE *GetX509AttrPtr(VALUE);
35void Init_ossl_x509attr(void);
36
37/*
38 * X509Cert
39 */
40extern VALUE cX509Cert;
41extern VALUE eX509CertError;
42
43 VALUE ossl_x509_new(X509 *);
44X509 *GetX509CertPtr(VALUE);
45X509 *DupX509CertPtr(VALUE);
46void Init_ossl_x509cert(void);
47
48/*
49 * X509CRL
50 */
51extern VALUE cX509CRL;
52extern VALUE eX509CRLError;
53
54 VALUE ossl_x509crl_new(X509_CRL *);
55X509_CRL *GetX509CRLPtr(VALUE);
56void Init_ossl_x509crl(void);
57
58/*
59 * X509Extension
60 */
61extern VALUE cX509Ext;
62extern VALUE cX509ExtFactory;
63extern VALUE eX509ExtError;
64
65 VALUE ossl_x509ext_new(X509_EXTENSION *);
66X509_EXTENSION *GetX509ExtPtr(VALUE);
67void Init_ossl_x509ext(void);
68
69/*
70 * X509Name
71 */
72extern VALUE cX509Name;
73extern VALUE eX509NameError;
74
75 VALUE ossl_x509name_new(X509_NAME *);
76X509_NAME *GetX509NamePtr(VALUE);
77void Init_ossl_x509name(void);
78
79/*
80 * X509Request
81 */
82extern VALUE cX509Req;
83extern VALUE eX509ReqError;
84
85X509_REQ *GetX509ReqPtr(VALUE);
86void Init_ossl_x509req(void);
87
88/*
89 * X509Revoked
90 */
91extern VALUE cX509Rev;
92extern VALUE eX509RevError;
93
94 VALUE ossl_x509revoked_new(X509_REVOKED *);
95X509_REVOKED *DupX509RevokedPtr(VALUE);
96void Init_ossl_x509revoked(void);
97
98/*
99 * X509Store and X509StoreContext
100 */
101extern VALUE cX509Store;
102extern VALUE cX509StoreContext;
103extern VALUE eX509StoreError;
104
105X509_STORE *GetX509StorePtr(VALUE);
106
107void Init_ossl_x509store(void);
108
109/*
110 * Calls the verify callback Proc (the first parameter) with given pre-verify
111 * result and the X509_STORE_CTX.
112 */
113int ossl_verify_cb_call(VALUE, int, X509_STORE_CTX *);
114
115#endif /* _OSSL_X509_H_ */
ossl_x509attr_new
VALUE ossl_x509attr_new(X509_ATTRIBUTE *)
Definition: ossl_x509attr.c:51
ossl_x509_time_adjust
ASN1_TIME * ossl_x509_time_adjust(ASN1_TIME *, VALUE)
Definition: ossl_x509.c:19
ossl_x509_new
VALUE ossl_x509_new(X509 *)
Definition: ossl_x509cert.c:51
GetX509StorePtr
X509_STORE * GetX509StorePtr(VALUE)
Definition: ossl_x509store.c:133
ossl_x509name_new
VALUE ossl_x509name_new(X509_NAME *)
Definition: ossl_x509name.c:56
cX509Req
VALUE cX509Req
Definition: ossl_x509req.c:30
Init_ossl_x509ext
void Init_ossl_x509ext(void)
Definition: ossl_x509ext.c:451
Init_ossl_x509revoked
void Init_ossl_x509revoked(void)
Definition: ossl_x509revoked.c:276
Init_ossl_x509attr
void Init_ossl_x509attr(void)
Definition: ossl_x509attr.c:305
GetX509NamePtr
X509_NAME * GetX509NamePtr(VALUE)
Definition: ossl_x509name.c:76
eX509RevError
VALUE eX509RevError
Definition: ossl_x509revoked.c:31
eX509NameError
VALUE eX509NameError
Definition: ossl_x509name.c:36
Init_ossl_x509cert
void Init_ossl_x509cert(void)
Definition: ossl_x509cert.c:711
eX509ExtError
VALUE eX509ExtError
Definition: ossl_x509ext.c:45
cX509Name
VALUE cX509Name
Definition: ossl_x509name.c:35
eX509CRLError
VALUE eX509CRLError
Definition: ossl_x509crl.c:31
cX509Attr
VALUE cX509Attr
Definition: ossl_x509attr.c:30
Init_ossl_x509name
void Init_ossl_x509name(void)
Definition: ossl_x509name.c:507
cX509CRL
VALUE cX509CRL
Definition: ossl_x509crl.c:30
cX509Store
VALUE cX509Store
Definition: ossl_x509store.c:104
GetX509ReqPtr
X509_REQ * GetX509ReqPtr(VALUE)
Definition: ossl_x509req.c:51
ossl_verify_cb_call
int ossl_verify_cb_call(VALUE, int, X509_STORE_CTX *)
Definition: ossl_x509store.c:62
DupX509RevokedPtr
X509_REVOKED * DupX509RevokedPtr(VALUE)
Definition: ossl_x509revoked.c:71
cX509Rev
VALUE cX509Rev
Definition: ossl_x509revoked.c:30
DupX509CertPtr
X509 * DupX509CertPtr(VALUE)
Definition: ossl_x509cert.c:81
mX509
VALUE mX509
Definition: ossl_x509.c:12
cX509Ext
VALUE cX509Ext
Definition: ossl_x509ext.c:43
Init_ossl_x509store
void Init_ossl_x509store(void)
Definition: ossl_x509store.c:789
eX509ReqError
VALUE eX509ReqError
Definition: ossl_x509req.c:31
Init_ossl_x509
void Init_ossl_x509(void)
Definition: ossl_x509.c:30
ossl_x509ext_new
VALUE ossl_x509ext_new(X509_EXTENSION *)
Definition: ossl_x509ext.c:65
ossl_x509revoked_new
VALUE ossl_x509revoked_new(X509_REVOKED *)
Definition: ossl_x509revoked.c:51
cX509Cert
VALUE cX509Cert
Definition: ossl_x509cert.c:30
GetX509AttrPtr
X509_ATTRIBUTE * GetX509AttrPtr(VALUE)
Definition: ossl_x509attr.c:71
cX509StoreContext
VALUE cX509StoreContext
Definition: ossl_x509store.c:105
Init_ossl_x509crl
void Init_ossl_x509crl(void)
Definition: ossl_x509crl.c:505
eX509StoreError
VALUE eX509StoreError
Definition: ossl_x509store.c:106
cX509ExtFactory
VALUE cX509ExtFactory
Definition: ossl_x509ext.c:44
Init_ossl_x509req
void Init_ossl_x509req(void)
Definition: ossl_x509req.c:409
GetX509CertPtr
X509 * GetX509CertPtr(VALUE)
Definition: ossl_x509cert.c:71
eX509AttrError
VALUE eX509AttrError
Definition: ossl_x509attr.c:31
GetX509CRLPtr
X509_CRL * GetX509CRLPtr(VALUE)
Definition: ossl_x509crl.c:51
GetX509ExtPtr
X509_EXTENSION * GetX509ExtPtr(VALUE)
Definition: ossl_x509ext.c:85
eX509CertError
VALUE eX509CertError
Definition: ossl_x509cert.c:31
ossl_x509crl_new
VALUE ossl_x509crl_new(X509_CRL *)
Definition: ossl_x509crl.c:61
VALUE
unsigned long VALUE
Definition: value.h:38