File: ccipher_8h-source.html

package info (click to toggle)
klone 1.1.1.dfsg1-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 6,480 kB
  • ctags: 4,238
  • sloc: ansic: 16,288; makefile: 384; sh: 351
file content (72 lines) | stat: -rw-r--r-- 4,752 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>KLone: ccipher.h Source File</title>
<link href="kl.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.3.9.1 -->
<div class="qindex"><a class="qindex" href="index.html">Main&nbsp;Page</a> | <a class="qindex" href="modules.html">Modules</a> | <a class="qindex" href="annotated.html">Data&nbsp;Structures</a> | <a class="qindex" href="dirs.html">Directories</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="functions.html">Data&nbsp;Fields</a> | <a class="qindex" href="globals.html">Globals</a></div>
<div class="nav">
<a class="el" href="dir_000002.html">klone</a></div>
<h1>ccipher.h</h1><a href="ccipher_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment">00001 <span class="comment">/*</span>
00002 <span class="comment"> * Copyright (c) 2005, 2006 by KoanLogic s.r.l. &lt;http://www.koanlogic.com&gt;</span>
00003 <span class="comment"> * All rights reserved.</span>
00004 <span class="comment"> *</span>
00005 <span class="comment"> * This file is part of KLone, and as such it is subject to the license stated</span>
00006 <span class="comment"> * in the LICENSE file which you have received as part of this distribution.</span>
00007 <span class="comment"> *</span>
00008 <span class="comment"> * $Id: ccipher.h,v 1.8 2006/01/09 12:38:37 tat Exp $</span>
00009 <span class="comment"> */</span>
00010 
00011 <span class="preprocessor">#ifndef _KLONE_CODEC_CIPHER_H_</span>
00012 <span class="preprocessor"></span><span class="preprocessor">#define _KLONE_CODEC_CIPHER_H_</span>
00013 <span class="preprocessor"></span>
00014 <span class="preprocessor">#include "klone_conf.h"</span>
00015 <span class="preprocessor">#include &lt;<a class="code" href="codec_8h.html">klone/codec.h</a>&gt;</span>
00016 
00017 <span class="preprocessor">#ifdef HAVE_LIBOPENSSL</span>
00018 <span class="preprocessor"></span><span class="preprocessor">#include &lt;openssl/evp.h&gt;</span>
00019 
00020 <span class="preprocessor">#ifdef __cplusplus</span>
00021 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="stringliteral">"C"</span> {
00022 <span class="preprocessor">#endif </span>
00023 <span class="preprocessor"></span>
00024 <span class="comment">/* possibile values for io_gzip_create */</span>
00025 <span class="keyword">enum</span> { CIPHER_ENCRYPT, CIPHER_DECRYPT };
00026 
00027 <span class="keyword">enum</span> {
00028     <a class="code" href="ccipher_8h.html#a3a0">CODEC_CIPHER_KEY_SIZE</a>   = EVP_MAX_KEY_LENGTH, 
00029     <a class="code" href="ccipher_8h.html#a3a1">CODEC_CIPHER_IV_SIZE</a>    = EVP_MAX_IV_LENGTH,
00030     <a class="code" href="ccipher_8h.html#a3a2">CODEC_CIPHER_BLOCK_SIZE</a> = EVP_MAX_BLOCK_LENGTH
00031 };
00032 
00033 <span class="keywordtype">int</span> <a class="code" href="group__codec__t.html#ga2">codec_cipher_create</a>(<span class="keywordtype">int</span> op, <span class="keyword">const</span> EVP_CIPHER *cipher, 
00034     <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *key, <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> *iv, <a class="code" href="structcodec__s.html">codec_t</a> **pcc);
00035 
00036 <span class="preprocessor">#ifdef __cplusplus</span>
00037 <span class="preprocessor"></span>}
00038 <span class="preprocessor">#endif </span>
00039 <span class="preprocessor"></span>
00040 <span class="preprocessor">#else </span><span class="comment">/* HAVE_LIBOPENSSL */</span>
00041 <span class="comment">/* to avoid ifdefs in local variable declaration (such vars will not be used </span>
00042 <span class="comment">   anyway because the code that use them is ifdef-out) */</span>
00043 <span class="keyword">enum</span> {
00044     <a class="code" href="ccipher_8h.html#a3a0">CODEC_CIPHER_KEY_SIZE</a>   = 0, 
00045     <a class="code" href="ccipher_8h.html#a3a1">CODEC_CIPHER_IV_SIZE</a>    = 0,
00046     <a class="code" href="ccipher_8h.html#a3a2">CODEC_CIPHER_BLOCK_SIZE</a> = 0
00047 };
00048 
00049 <span class="preprocessor">#endif </span><span class="comment">/* HAVE_LIBOPENSSL */</span>
00050 
00051 <span class="preprocessor">#endif </span><span class="comment">/* !_KLONE_CODEC_CIPHER_H_ */</span>
</pre></div><hr>
<div> 
  <div style="text-align:left">
    <a href="http://www.koanlogic.com/kl/cont/gb/html/products.html">&larr;Products</a>
  </div>
  <div style="text-align:center;">
    &copy; 2005-2006 - <a href="http://www.koanlogic.com">KoanLogic S.r.l.</a> - All rights reserved
  </div>
</div>

</body>
</html>