From d6b4eae8eb0a5ca3119414005e483fedd63a62d6 Mon Sep 17 00:00:00 2001 From: forsyth Date: Mon, 17 Jan 2011 11:10:35 +0000 Subject: 20110117-1110 --- appl/cmd/ssh/cipherblowfish.b | 43 ------------------------------------------- 1 file changed, 43 deletions(-) delete mode 100644 appl/cmd/ssh/cipherblowfish.b (limited to 'appl/cmd/ssh/cipherblowfish.b') diff --git a/appl/cmd/ssh/cipherblowfish.b b/appl/cmd/ssh/cipherblowfish.b deleted file mode 100644 index 8d3b0c31..00000000 --- a/appl/cmd/ssh/cipherblowfish.b +++ /dev/null @@ -1,43 +0,0 @@ -implement Cipher; - -include "sys.m"; - -include "ipints.m"; - ipints: IPints; - IPint: import ipints; - -include "crypt.m"; - crypt: Crypt; - BFstate: import crypt; - -include "sshio.m"; - -Cipherstate: adt -{ - enc: ref BFstate; - dec: ref BFstate; -}; - -cs: ref Cipherstate; - -id(): int -{ - return SSH_CIPHER_BLOWFISH; -} - -init(key: array of byte, nil: int) -{ - ipints = load IPints IPints->PATH; - crypt = load Crypt Crypt->PATH; - cs = ref Cipherstate(crypt->blowfishsetup(key, nil), crypt->blowfishsetup(key, nil)); -} - -encrypt(buf: array of byte, nbuf: int) -{ - crypt->blowfishcbc(cs.enc, buf, nbuf, Crypt->Encrypt); -} - -decrypt(buf: array of byte, nbuf: int) -{ - crypt->blowfishcbc(cs.dec, buf, nbuf, Crypt->Decrypt); -} -- cgit v1.2.3