xrootd
Loading...
Searching...
No Matches
XrdCryptosslX509Req.hh
Go to the documentation of this file.
1#ifndef __CRYPTO_SSLX509REQ_H__
2#define __CRYPTO_SSLX509REQ_H__
3/******************************************************************************/
4/* */
5/* X r d C r y p t o s s l X 5 0 9 R e q . h h */
6/* */
7/* (c) 2005 G. Ganis , CERN */
8/* */
9/* This file is part of the XRootD software suite. */
10/* */
11/* XRootD is free software: you can redistribute it and/or modify it under */
12/* the terms of the GNU Lesser General Public License as published by the */
13/* Free Software Foundation, either version 3 of the License, or (at your */
14/* option) any later version. */
15/* */
16/* XRootD is distributed in the hope that it will be useful, but WITHOUT */
17/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */
18/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */
19/* License for more details. */
20/* */
21/* You should have received a copy of the GNU Lesser General Public License */
22/* along with XRootD in a file called COPYING.LESSER (LGPL license) and file */
23/* COPYING (GPL license). If not, see <http://www.gnu.org/licenses/>. */
24/* */
25/* The copyright holder's institutional names and contributor's names may not */
26/* be used to endorse or promote products derived from this software without */
27/* specific prior written permission of the institution or contributor. */
28/* */
29/******************************************************************************/
30
31/* ************************************************************************** */
32/* */
33/* OpenSSL implementation of XrdCryptoX509 */
34/* */
35/* ************************************************************************** */
36
38
39#include <openssl/x509v3.h>
40#include <openssl/bio.h>
41
42// ---------------------------------------------------------------------------//
43//
44// OpenSSL X509 request implementation
45//
46// ---------------------------------------------------------------------------//
48{
49
50public:
54
55 // Access underlying data (in opaque form: used in chains)
57
58 // Access certificate key
59 XrdCryptoRSA *PKI() { return pki; }
60
61 // Export in form of bucket (for transfers)
63
64 // Relevant Names
65 const char *Subject(); // get subject name
66
67 // Relevant hashes
68 const char *SubjectHash(int); // get hash of subject name
69
70 // Retrieve a given extension if there (in opaque form)
72
73 // Verify signature
74 bool Verify();
75
76private:
77 X509_REQ *creq; // The certificate request object
78 XrdOucString subject; // subject;
79 XrdOucString subjecthash; // hash of subject (default algorithm);
80 XrdOucString subjectoldhash; // hash of subject (md5 algorithm);
81 XrdSutBucket *bucket; // Bucket for export operations
82 XrdCryptoRSA *pki; // PKI of the certificate
83};
84
85#endif
void * XrdCryptoX509Reqdata
Definition XrdCryptoX509Req.hh:42
Definition XrdCryptoRSA.hh:51
Definition XrdCryptoX509Req.hh:50
Definition XrdCryptosslX509Req.hh:48
virtual ~XrdCryptosslX509Req()
X509_REQ * creq
Definition XrdCryptosslX509Req.hh:77
XrdCryptoRSA * PKI()
Definition XrdCryptosslX509Req.hh:59
XrdCryptosslX509Req(X509_REQ *creq)
const char * SubjectHash(int)
XrdCryptoRSA * pki
Definition XrdCryptosslX509Req.hh:82
XrdOucString subjecthash
Definition XrdCryptosslX509Req.hh:79
XrdOucString subject
Definition XrdCryptosslX509Req.hh:78
XrdCryptoX509Reqdata Opaque()
Definition XrdCryptosslX509Req.hh:56
XrdCryptosslX509Req(XrdSutBucket *bck)
XrdCryptoX509Reqdata GetExtension(const char *oid)
XrdSutBucket * bucket
Definition XrdCryptosslX509Req.hh:81
XrdSutBucket * Export()
const char * Subject()
XrdOucString subjectoldhash
Definition XrdCryptosslX509Req.hh:80
Definition XrdOucString.hh:254
Definition XrdSutBucket.hh:44