Mixe for Privacy and Anonymity in the Internet
CASymCipherNull.hpp
Go to the documentation of this file.
1 /*
2 Copyright (c) 2000, The JAP-Team
3 All rights reserved.
4 Redistribution and use in source and binary forms, with or without modification,
5 are permitted provided that the following conditions are met:
6 
7  - Redistributions of source code must retain the above copyright notice,
8  this list of conditions and the following disclaimer.
9 
10  - Redistributions in binary form must reproduce the above copyright notice,
11  this list of conditions and the following disclaimer in the documentation and/or
12  other materials provided with the distribution.
13 
14  - Neither the name of the University of Technology Dresden, Germany nor the names of its contributors
15  may be used to endorse or promote products derived from this software without specific
16  prior written permission.
17 
18 
19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS
20 OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
21 AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS
22 BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
24 OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
25 IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE
27 */
28 #ifndef __CASYMCIPHERNULL__
29 #define __CASYMCIPHERNULL__
30 
31 
32 #include "CALockAble.hpp"
33 #include "CAMutex.hpp"
34 #include "CASymChannelCipher.hpp"
38 
39  {
40  public:
42  {
43  }
44 
46  {
47 #ifndef ONLY_LOCAL_PROXY
49 #endif
50  }
51  bool isKeyValid()
52  {
53  return true;
54  }
55 
57  SINT32 setKey(const UINT8* key)
58  {
59  return E_SUCCESS;
60  }
61 
64  SINT32 setKeys(const UINT8* key,UINT32 keysize)
65  {
66  return E_SUCCESS;
67  }
68 
69 
74  SINT32 setIVs(const UINT8* p_iv)
75  {
76  return E_SUCCESS;
77  }
78 
83  SINT32 setIV2(const UINT8* p_iv)
84  {
85  return E_SUCCESS;
86  }
87 
88  SINT32 crypt1(const UINT8* in,UINT8* out,UINT32 len)
89  {
90  memmove(out, in, len);
91  return E_SUCCESS;
92  }
93 
94  SINT32 crypt2(const UINT8* in,UINT8* out,UINT32 len)
95  {
96  memmove(out, in, len);
97  return E_SUCCESS;
98  }
99 
100 
101  };
102 
103 #endif
signed int SINT32
Definition: basetypedefs.h:132
unsigned char UINT8
Definition: basetypedefs.h:135
unsigned int UINT32
Definition: basetypedefs.h:131
SINT32 waitForDestroy()
If called checks if the reference counter equals zero.
Definition: CALockAble.hpp:82
This class implemtns the symmetric channel cipher interface - but does not do eny encryption!...
SINT32 crypt2(const UINT8 *in, UINT8 *out, UINT32 len)
SINT32 setIV2(const UINT8 *p_iv)
Sets iv2 to p_iv.
SINT32 setIVs(const UINT8 *p_iv)
Sets iv1 and iv2 to p_iv.
SINT32 crypt1(const UINT8 *in, UINT8 *out, UINT32 len)
SINT32 setKeys(const UINT8 *key, UINT32 keysize)
Sets the keys for crypt1() and crypt2() either to the same key (if keysize==KEY_SIZE) or to different...
SINT32 setKey(const UINT8 *key)
Sets the keys for crypt1() and crypt2() to the same key.
const SINT32 E_SUCCESS
Definition: errorcodes.hpp:2
UINT16 len
Definition: typedefs.hpp:0