tlsgnutlsserveranon.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef TLSGNUTLSSERVERANON_H__
00016 #define TLSGNUTLSSERVERANON_H__
00017
00018 #include "tlsgnutlsbase.h"
00019
00020 #ifdef _WIN32
00021 # include "../config.h.win"
00022 #elif defined( _WIN32_WCE )
00023 # include "../config.h.win"
00024 #else
00025 # include "config.h"
00026 #endif
00027
00028 #ifdef HAVE_GNUTLS
00029
00030 #include <gnutls/gnutls.h>
00031 #include <gnutls/x509.h>
00032
00033 namespace gloox
00034 {
00035
00044 class GnuTLSServerAnon : public GnuTLSBase
00045 {
00046 public:
00051 GnuTLSServerAnon( TLSHandler *th );
00052
00056 virtual ~GnuTLSServerAnon();
00057
00058
00059 virtual void cleanup();
00060
00061 private:
00062 virtual void init();
00063 virtual void getCertInfo();
00064 void generateDH();
00065
00066 gnutls_anon_server_credentials_t m_anoncred;
00067 gnutls_dh_params_t m_dhParams;
00068
00069 const int m_dhBits;
00070
00071 };
00072
00073 }
00074
00075 #endif // HAVE_GNUTLS
00076
00077 #endif // TLSGNUTLSSERVERANON_H__