cipher.h (18a711954e9b847ddf362ad1fc8675a6842aeff2) cipher.h (a8f6863aa612ce6941e7bad9cf809a8d0608a7ca)
1/*
2 *
3 * cipher.h
4 *
5 * Author: Tatu Ylonen <ylo@cs.hut.fi>
6 *
7 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
8 * All rights reserved
9 *
10 * Created: Wed Apr 19 16:50:42 1995 ylo
11 *
1/*
2 *
3 * cipher.h
4 *
5 * Author: Tatu Ylonen <ylo@cs.hut.fi>
6 *
7 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
8 * All rights reserved
9 *
10 * Created: Wed Apr 19 16:50:42 1995 ylo
11 *
12 * $FreeBSD$
13 */
14
12 */
13
15/* RCSID("$Id: cipher.h,v 1.10 1999/11/24 19:53:46 markus Exp $"); */
14/* RCSID("$Id: cipher.h,v 1.11 2000/03/22 09:55:10 markus Exp $"); */
16
17#ifndef CIPHER_H
18#define CIPHER_H
19
15
16#ifndef CIPHER_H
17#define CIPHER_H
18
20#include <openssl/des.h>
21#include <openssl/blowfish.h>
19#include <ssl/des.h>
20#include <ssl/blowfish.h>
22
23/* Cipher types. New types can be added, but old types should not be removed
24 for compatibility. The maximum allowed value is 31. */
25#define SSH_CIPHER_NOT_SET -1 /* None selected (invalid number). */
26#define SSH_CIPHER_NONE 0 /* no encryption */
27#define SSH_CIPHER_IDEA 1 /* IDEA CFB */
28#define SSH_CIPHER_DES 2 /* DES CBC */
29#define SSH_CIPHER_3DES 3 /* 3DES CBC */

--- 54 unchanged lines hidden (view full) ---

84cipher_encrypt(CipherContext * context, unsigned char *dest,
85 const unsigned char *src, unsigned int len);
86
87/* Decrypts data using the cipher. */
88void
89cipher_decrypt(CipherContext * context, unsigned char *dest,
90 const unsigned char *src, unsigned int len);
91
21
22/* Cipher types. New types can be added, but old types should not be removed
23 for compatibility. The maximum allowed value is 31. */
24#define SSH_CIPHER_NOT_SET -1 /* None selected (invalid number). */
25#define SSH_CIPHER_NONE 0 /* no encryption */
26#define SSH_CIPHER_IDEA 1 /* IDEA CFB */
27#define SSH_CIPHER_DES 2 /* DES CBC */
28#define SSH_CIPHER_3DES 3 /* 3DES CBC */

--- 54 unchanged lines hidden (view full) ---

83cipher_encrypt(CipherContext * context, unsigned char *dest,
84 const unsigned char *src, unsigned int len);
85
86/* Decrypts data using the cipher. */
87void
88cipher_decrypt(CipherContext * context, unsigned char *dest,
89 const unsigned char *src, unsigned int len);
90
92/*
93 * If and CRC-32 attack is detected this function is called. Defaults to
94 * fatal, changed to packet_disconnect in sshd and ssh.
95 */
96extern void (*cipher_attack_detected) (const char *fmt, ...);
97
98#endif /* CIPHER_H */
91#endif /* CIPHER_H */