WvStreams
|
An DSA public key or public/private key pair that can be used for encryption. More...
#include <wvdsa.h>
Public Member Functions | |
WvDSAKey (const WvDSAKey &k) | |
WvDSAKey (struct dsa_st *_dsa, bool priv) | |
WvDSAKey (WvStringParm keystr, bool priv) | |
Populate the DSA key with a hexified() key. | |
WvDSAKey (int bits) | |
Create a new DSA key of bits strength. | |
virtual bool | isok () const |
By default, returns true if geterr() == 0. | |
WvString | private_str () const |
Retrieve the private key as a hexified string returns WvString::null if there is only a public key. | |
WvString | public_str () const |
Retrieve the public key as a hexified string. | |
WvString | getpem (bool privkey) |
Retrieve the public or private key in PEM encoded format. | |
WvDSAKey (const WvDSAKey &k) | |
WvDSAKey (struct dsa_st *_dsa, bool priv) | |
WvDSAKey (WvStringParm keystr, bool priv) | |
Populate the DSA key with a hexified() key. | |
WvDSAKey (int bits) | |
Create a new DSA key of bits strength. | |
virtual bool | isok () const |
By default, returns true if geterr() == 0. | |
WvString | private_str () const |
Retrieve the private key as a hexified string returns WvString::null if there is only a public key. | |
WvString | public_str () const |
Retrieve the public key as a hexified string. | |
WvString | getpem (bool privkey) |
Retrieve the public or private key in PEM encoded format. | |
virtual int | geterr () const |
If isok() is false, return the system error number corresponding to the error, -1 for a special error string (which you can obtain with errstr()) or 0 on end of file. | |
virtual int | geterr () const |
If isok() is false, return the system error number corresponding to the error, -1 for a special error string (which you can obtain with errstr()) or 0 on end of file. | |
virtual WvString | errstr () const |
virtual WvString | errstr () const |
virtual void | seterr (int _errnum) |
Set the errnum variable – we have an error. | |
void | seterr (WvStringParm specialerr) |
void | seterr (WVSTRING_FORMAT_DECL) |
void | seterr (const WvErrorBase &err) |
virtual void | seterr (int _errnum) |
Set the errnum variable – we have an error. | |
void | seterr (WvStringParm specialerr) |
void | seterr (WVSTRING_FORMAT_DECL) |
void | seterr (const WvErrorBase &err) |
void | seterr_both (int _errnum, WvStringParm specialerr) |
void | seterr_both (int _errnum, WVSTRING_FORMAT_DECL) |
void | seterr_both (int _errnum, WvStringParm specialerr) |
void | seterr_both (int _errnum, WVSTRING_FORMAT_DECL) |
void | noerr () |
Reset our error state - there's no error condition anymore. | |
void | noerr () |
Reset our error state - there's no error condition anymore. | |
Static Public Member Functions | |
static WvString | strerror (int errnum) |
A replacement for the operating system strerror() function that can map more kinds of error strings (especially in win32). | |
static WvString | strerror (int errnum) |
A replacement for the operating system strerror() function that can map more kinds of error strings (especially in win32). | |
Public Attributes | |
struct dsa_st * | dsa |
Protected Attributes | |
int | errnum |
WvString | errstring |
An DSA public key or public/private key pair that can be used for encryption.
Knows how to encode/decode itself into a string of hex digits for easy transport.
Definition at line 23 of file debian/libwvstreams-dev/usr/include/wvstreams/wvdsa.h.
WvDSAKey::WvDSAKey | ( | WvStringParm | keystr, |
bool | priv | ||
) |
WvDSAKey::WvDSAKey | ( | int | bits | ) |
|
virtual |
By default, returns true if geterr() == 0.
Might be overridden so that isok() == false even though no error code has been specified.
Reimplemented from WvErrorBase.
|
inline |
Retrieve the private key as a hexified string returns WvString::null if there is only a public key.
Definition at line 56 of file debian/libwvstreams-dev/usr/include/wvstreams/wvdsa.h.
|
inline |
Retrieve the public key as a hexified string.
Definition at line 62 of file debian/libwvstreams-dev/usr/include/wvstreams/wvdsa.h.
WvString WvDSAKey::getpem | ( | bool | privkey | ) |
Retrieve the public or private key in PEM encoded format.
Definition at line 116 of file wvdsa.cc.
References WvBufBaseCommonImpl< T >::alloc(), WvErrorBase::seterr(), and WvBufBaseCommonImpl< T >::unalloc().
|
virtual |
By default, returns true if geterr() == 0.
Might be overridden so that isok() == false even though no error code has been specified.
Reimplemented from WvErrorBase.
|
inline |
Retrieve the private key as a hexified string returns WvString::null if there is only a public key.
Definition at line 56 of file include/wvdsa.h.
|
inline |
Retrieve the public key as a hexified string.
Definition at line 62 of file include/wvdsa.h.
|
inlinevirtualinherited |
If isok() is false, return the system error number corresponding to the error, -1 for a special error string (which you can obtain with errstr()) or 0 on end of file.
If isok() is true, returns an undefined number.
Reimplemented in WvDBusServer, WvStreamClone, WvDBusServer, and WvStreamClone.
Definition at line 48 of file debian/libwvstreams-dev/usr/include/wvstreams/wverror.h.
Referenced by UniIniGen::commit(), UniFileSystemGen::get(), WvDBusServer::geterr(), WvStreamClone::geterr(), WvEncoderStream::isok(), UniConfDaemon::listen(), UniIniGen::refresh(), WvStream::seterr(), and WvMagicCircle::WvMagicCircle().
|
inlinevirtualinherited |
If isok() is false, return the system error number corresponding to the error, -1 for a special error string (which you can obtain with errstr()) or 0 on end of file.
If isok() is true, returns an undefined number.
Reimplemented in WvDBusServer, WvStreamClone, WvDBusServer, and WvStreamClone.
Definition at line 48 of file include/wverror.h.
|
virtualinherited |
Definition at line 127 of file wverror.cc.
|
staticinherited |
A replacement for the operating system strerror() function that can map more kinds of error strings (especially in win32).
Definition at line 91 of file wverror.cc.
References WvErrorBase::strerror().
Referenced by WvLog::perror(), WvErrorBase::strerror(), WvSSLStream::uread(), and WvSSLStream::uwrite().
|
virtualinherited |
Set the errnum variable – we have an error.
If called more than once, seterr() doesn't change the error code away from the previous one. That way, we remember the original cause of our problems.
Subclasses may want to override seterr(int) to shut themselves down (eg. WvStream::close()) when an error condition is set.
Note that seterr(WvString) will call seterr(-1).
Reimplemented in WvStream, and WvStream.
Definition at line 144 of file wverror.cc.
Referenced by WvTCPListener::accept(), WvUnixListener::accept(), getpem(), WvGlob::set(), WvStream::seterr(), WvMagicCircle::WvMagicCircle(), WvPam::WvPam(), WvPam::WvPam(), WvShmZone::WvShmZone(), and WvTCPListener::WvTCPListener().
|
inherited |
Definition at line 159 of file wverror.cc.
|
inlineinherited |
Definition at line 70 of file debian/libwvstreams-dev/usr/include/wvstreams/wverror.h.
|
inherited |
Definition at line 170 of file wverror.cc.
|
virtualinherited |
Set the errnum variable – we have an error.
If called more than once, seterr() doesn't change the error code away from the previous one. That way, we remember the original cause of our problems.
Subclasses may want to override seterr(int) to shut themselves down (eg. WvStream::close()) when an error condition is set.
Note that seterr(WvString) will call seterr(-1).
|
inlineinherited |
Definition at line 70 of file include/wverror.h.
|
inherited |
Definition at line 179 of file wverror.cc.
|
inlineinherited |
Definition at line 73 of file debian/libwvstreams-dev/usr/include/wvstreams/wverror.h.
|
inlineinherited |
Definition at line 73 of file include/wverror.h.
|
inlineinherited |
Reset our error state - there's no error condition anymore.
Definition at line 78 of file debian/libwvstreams-dev/usr/include/wvstreams/wverror.h.
|
inlineinherited |
Reset our error state - there's no error condition anymore.
Definition at line 78 of file include/wverror.h.
struct dsa_st * WvDSAKey::dsa |
Definition at line 32 of file debian/libwvstreams-dev/usr/include/wvstreams/wvdsa.h.
|
protectedinherited |
Definition at line 26 of file debian/libwvstreams-dev/usr/include/wvstreams/wverror.h.
|
protectedinherited |
Definition at line 27 of file debian/libwvstreams-dev/usr/include/wvstreams/wverror.h.