IBR-DTNSuite  0.10
dtn::security::SecurityKey Class Reference

#include <SecurityKey.h>

Collaboration diagram for dtn::security::SecurityKey:
Collaboration graph

Public Types

enum  KeyType { KEY_UNSPEC = 0, KEY_SHARED = 1, KEY_PRIVATE = 2, KEY_PUBLIC = 3 }
 

Public Member Functions

 SecurityKey ()
 
virtual ~SecurityKey ()
 
virtual RSAgetRSA () const
 
virtual EVP_PKEY * getEVP () const
 
virtual const std::string getData () const
 

Static Public Member Functions

static void free (RSA *key)
 
static void free (EVP_PKEY *key)
 

Public Attributes

KeyType type
 
dtn::data::EID reference
 
dtn::data::DTNTime lastupdate
 
ibrcommon::File file
 

Friends

std::ostream & operator<< (std::ostream &stream, const SecurityKey &key)
 
std::istream & operator>> (std::istream &stream, SecurityKey &key)
 

Detailed Description

Definition at line 39 of file SecurityKey.h.

Member Enumeration Documentation

Enumerator
KEY_UNSPEC 
KEY_SHARED 
KEY_PRIVATE 
KEY_PUBLIC 

Definition at line 42 of file SecurityKey.h.

Constructor & Destructor Documentation

dtn::security::SecurityKey::SecurityKey ( )

Definition at line 34 of file SecurityKey.cpp.

dtn::security::SecurityKey::~SecurityKey ( )
virtual

Definition at line 38 of file SecurityKey.cpp.

Member Function Documentation

void dtn::security::SecurityKey::free ( RSA key)
static
void dtn::security::SecurityKey::free ( EVP_PKEY *  key)
static

Definition at line 46 of file SecurityKey.cpp.

const std::string dtn::security::SecurityKey::getData ( ) const
virtual

Definition at line 51 of file SecurityKey.cpp.

References file, and ibrcommon::File::getPath().

Referenced by dtn::security::BundleAuthenticationBlock::calcMAC().

Here is the call graph for this function:

EVP_PKEY * dtn::security::SecurityKey::getEVP ( ) const
virtual

Definition at line 76 of file SecurityKey.cpp.

References file, ibrcommon::File::getPath(), KEY_PRIVATE, KEY_PUBLIC, and type.

Here is the call graph for this function:

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  stream,
const SecurityKey key 
)
friend

Definition at line 74 of file SecurityKey.h.

std::istream& operator>> ( std::istream &  stream,
SecurityKey key 
)
friend

Definition at line 89 of file SecurityKey.h.

Member Data Documentation

ibrcommon::File dtn::security::SecurityKey::file

Definition at line 63 of file SecurityKey.h.

Referenced by dtn::security::SecurityKeyManager::get(), getData(), and getEVP().

dtn::data::DTNTime dtn::security::SecurityKey::lastupdate

Definition at line 60 of file SecurityKey.h.

Referenced by dtn::security::SecurityKeyManager::get().

KeyType dtn::security::SecurityKey::type

Definition at line 54 of file SecurityKey.h.

Referenced by dtn::security::SecurityKeyManager::get(), getEVP(), and getRSA().


The documentation for this class was generated from the following files: