00001 /* 00002 * $Id: ossl_x509.h 25189 2009-10-02 12:04:37Z akr $ 00003 * 'OpenSSL for Ruby' project 00004 * Copyright (C) 2001-2002 Michal Rokos <m.rokos@sh.cvut.cz> 00005 * All rights reserved. 00006 */ 00007 /* 00008 * This program is licenced under the same licence as Ruby. 00009 * (See the file 'LICENCE'.) 00010 */ 00011 #if !defined(_OSSL_X509_H_) 00012 #define _OSSL_X509_H_ 00013 00014 /* 00015 * X509 main module 00016 */ 00017 extern VALUE mX509; 00018 00019 void Init_ossl_x509(void); 00020 00021 /* 00022 * X509Attr 00023 */ 00024 extern VALUE cX509Attr; 00025 extern VALUE eX509AttrError; 00026 00027 VALUE ossl_x509attr_new(X509_ATTRIBUTE *); 00028 X509_ATTRIBUTE *DupX509AttrPtr(VALUE); 00029 void Init_ossl_x509attr(void); 00030 00031 /* 00032 * X509Cert 00033 */ 00034 extern VALUE cX509Cert; 00035 extern VALUE eX509CertError; 00036 00037 VALUE ossl_x509_new(X509 *); 00038 VALUE ossl_x509_new_from_file(VALUE); 00039 X509 *GetX509CertPtr(VALUE); 00040 X509 *DupX509CertPtr(VALUE); 00041 void Init_ossl_x509cert(void); 00042 00043 /* 00044 * X509CRL 00045 */ 00046 extern VALUE cX509CRL; 00047 extern VALUE eX509CRLError; 00048 00049 VALUE ossl_x509crl_new(X509_CRL *); 00050 X509_CRL *GetX509CRLPtr(VALUE); 00051 X509_CRL *DupX509CRLPtr(VALUE); 00052 void Init_ossl_x509crl(void); 00053 00054 /* 00055 * X509Extension 00056 */ 00057 extern VALUE cX509Ext; 00058 extern VALUE cX509ExtFactory; 00059 extern VALUE eX509ExtError; 00060 00061 VALUE ossl_x509ext_new(X509_EXTENSION *); 00062 X509_EXTENSION *GetX509ExtPtr(VALUE); 00063 X509_EXTENSION *DupX509ExtPtr(VALUE); 00064 void Init_ossl_x509ext(void); 00065 00066 /* 00067 * X509Name 00068 */ 00069 extern VALUE cX509Name; 00070 extern VALUE eX509NameError; 00071 00072 VALUE ossl_x509name_new(X509_NAME *); 00073 X509_NAME *GetX509NamePtr(VALUE); 00074 void Init_ossl_x509name(void); 00075 00076 /* 00077 * X509Request 00078 */ 00079 extern VALUE cX509Req; 00080 extern VALUE eX509ReqError; 00081 00082 VALUE ossl_x509req_new(X509_REQ *); 00083 X509_REQ *GetX509ReqPtr(VALUE); 00084 X509_REQ *DupX509ReqPtr(VALUE); 00085 void Init_ossl_x509req(void); 00086 00087 /* 00088 * X509Revoked 00089 */ 00090 extern VALUE cX509Rev; 00091 extern VALUE eX509RevError; 00092 00093 VALUE ossl_x509revoked_new(X509_REVOKED *); 00094 X509_REVOKED *DupX509RevokedPtr(VALUE); 00095 void Init_ossl_x509revoked(void); 00096 00097 /* 00098 * X509Store and X509StoreContext 00099 */ 00100 extern VALUE cX509Store; 00101 extern VALUE cX509StoreContext; 00102 extern VALUE eX509StoreError; 00103 00104 VALUE ossl_x509store_new(X509_STORE *); 00105 X509_STORE *GetX509StorePtr(VALUE); 00106 X509_STORE *DupX509StorePtr(VALUE); 00107 00108 VALUE ossl_x509stctx_new(X509_STORE_CTX *); 00109 VALUE ossl_x509stctx_clear_ptr(VALUE); 00110 X509_STORE_CTX *GetX509StCtxtPtr(VALUE); 00111 00112 void Init_ossl_x509store(void); 00113 00114 #endif /* _OSSL_X509_H_ */ 00115