man des () - Perform DES encryption of Tcl data

NAME

des - Perform DES encryption of Tcl data

SYNOPSIS

package require Tcl 8.3 package require des 0.8.2 ::DES::des -mode encode|decode -key string (-file filename | ?--? string)

DESCRIPTION

This is a Tcl implementation of the Data Encryption Standard (DES) written by Jochen Loewer and based upon an implementation by Eric Young.

NOTE: this version only implements the Electronic Code Book (ECB) mode of DES. This is NOT suitable for general use encryption of large blocks or streams of data. Until Cipher Block Chaining (CBC) or Cipher/Output Feed Back (CFB / OFB) modes are implemented this should not be considered for real encryption. The Trfcrypt package has C-based implementations of these modes.

COMMANDS

::DES::des -mode encode|decode -key string (-file filename | ?--? string)
Encode or decode a string or file.

EXAMPLES

% set ciphertext [DES::des -mode encode -key $secret $plaintext]
% set plaintext [DES::des -mode decode -key $secret $ciphertext]

% set ciphertext [DES::des -mode encode -key $secret -file $filename]
% set f [open $filename.des w] ; puts -nonewline $ciphertext ; close $f
% set plaintext [DES::des -mode decode -key $secret -file $filename.des]

AUTHORS

Jochen C Loewer

SEE ALSO

md5(n), sha1(n)

KEYWORDS

DES, data integrity, encryption, security

COPYRIGHT

Copyright (c) 2003, Jochen C Loewer