• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • kio/kssl
 

kio/kssl

  • kio
  • kssl
ksmimecrypto.h
1 /* This file is part of the KDE project
2  *
3  * Copyright (C) 2003 Stefan Rompf <sux@loplof.de>
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 
21 #ifndef __KSMIMECRYPTO_H
22 #define __KSMIMECRYPTO_H
23 
24 
25 #include <tqcstring.h>
26 #include <tqptrlist.h>
27 #include "ksslpkcs12.h"
28 #include "ksslcertificate.h"
29 
30 class KOpenSSLProxy;
31 class KSMIMECryptoPrivate;
32 
33 class KIO_EXPORT KSMIMECrypto {
34  public:
35  KSMIMECrypto();
36  ~KSMIMECrypto();
37 
38  enum algo { KSC_C_DES3_CBC = 1,
39  KSC_C_RC2_CBC_128,
40  KSC_C_RC2_CBC_64,
41  KSC_C_DES_CBC,
42  KSC_C_RC2_CBC_40 };
43 
44  enum rc { KSC_R_OK, /* everything ok */
45  KSC_R_OTHER, /* unspecified error */
46  KSC_R_NO_SSL, /* No crypto lib / compiled without SSL */
47  KSC_R_NOCIPHER, /* encryption cipher n/a */
48  KSC_R_NOMEM, /* out of memory */
49  KSC_R_FORMAT, /* wrong input data format */
50  KSC_R_WRONGKEY, /* wrong decryption/signature key */
51  KSC_R_VERIFY /* data does not match signature */
52  };
53 
63  rc signMessage(const TQCString &clearText,
64  TQByteArray &cipherText,
65  const KSSLPKCS12 &privKey,
66  const TQPtrList<KSSLCertificate> &certs,
67  bool detached);
68 
78  rc checkDetachedSignature(const TQCString &clearText,
79  const TQByteArray &signature,
80  TQPtrList<KSSLCertificate> &foundCerts);
81 
91  rc checkOpaqueSignature(const TQByteArray &signedText,
92  TQCString &clearText,
93  TQPtrList<KSSLCertificate> &foundCerts);
94 
107  rc encryptMessage(const TQCString &clearText,
108  TQByteArray &cipherText,
109  algo algorithm,
110  const TQPtrList<KSSLCertificate> &recip);
111 
119  rc decryptMessage(const TQByteArray &cipherText,
120  TQCString &clearText,
121  const KSSLPKCS12 &privKey);
122 
123  private:
124  KSMIMECryptoPrivate *priv;
125  KOpenSSLProxy *kossl;
126 };
127 
128 #endif

kio/kssl

Skip menu "kio/kssl"
  • Main Page
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

kio/kssl

Skip menu "kio/kssl"
  • arts
  • dcop
  • dnssd
  • interfaces
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for kio/kssl by doxygen 1.8.1.2
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |