TDE core libraries
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

96 lines
2.4KB

  1. /* This file is part of the KDE project
  2. *
  3. * Copyright (C) 2000-2003 George Staikos <staikos@kde.org>
  4. *
  5. * This library is free software; you can redistribute it and/or
  6. * modify it under the terms of the GNU Library General Public
  7. * License as published by the Free Software Foundation; either
  8. * version 2 of the License, or (at your option) any later version.
  9. *
  10. * This library is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  13. * Library General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU Library General Public License
  16. * along with this library; see the file COPYING.LIB. If not, write to
  17. * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  18. * Boston, MA 02110-1301, USA.
  19. */
  20. #ifndef _KSSLCONNECTIONINFO_H
  21. #define _KSSLCONNECTIONINFO_H
  22. #include <tqstring.h>
  23. #include <tdelibs_export.h>
  24. class KSSL;
  25. /**
  26. * KDE SSL Connection Information
  27. *
  28. * This class contains the information about an SSL connection. It is
  29. * generally referenced through KSSL.
  30. *
  31. * @author George Staikos <staikos@kde.org>
  32. * @see KSSL
  33. * @short KDE SSL Connection Information
  34. */
  35. class TDEIO_EXPORT KSSLConnectionInfo {
  36. friend class KSSL;
  37. public:
  38. /**
  39. * Destroy this object.
  40. */
  41. ~KSSLConnectionInfo();
  42. /**
  43. * Get the cipher in use.
  44. * @return the cipher in use
  45. */
  46. const TQString& getCipher() const;
  47. /**
  48. * Describe the cipher in use.
  49. * @return the cipher description (from OpenSSL)
  50. */
  51. const TQString& getCipherDescription() const;
  52. /**
  53. * Get the version of the cipher in use.
  54. * @return the version of the cipher
  55. */
  56. const TQString& getCipherVersion() const;
  57. /**
  58. * Get the number of bits of the cipher that are actually used.
  59. * @return the number of bits in use
  60. */
  61. int getCipherUsedBits() const;
  62. /**
  63. * Get bit-size of the cipher
  64. * @return the number of bits
  65. */
  66. int getCipherBits() const;
  67. protected:
  68. KSSLConnectionInfo();
  69. void clean();
  70. // These are here so KSSL can access them directly
  71. // It's just as easy as making accessors - they're friends afterall!
  72. int m_iCipherUsedBits, m_iCipherBits;
  73. TQString m_cipherName;
  74. TQString m_cipherDescription;
  75. TQString m_cipherVersion;
  76. private:
  77. class KSSLConnectionInfoPrivate;
  78. KSSLConnectionInfoPrivate *d;
  79. };
  80. #endif