Hi, At 23:26 9/12/96 +0500, "Dana Frank Raymond" wrote: >I am implementing a data block encryption algorithm using a CRC-CCITT >style filter. The SR is preloaded with a key. The clear text is shifted >into the SR one bit at a time, and the msb of the SR gives each clear >text bit it's encrypted equivelant. I'm not sure if your aproach will work. The most close as I understand it, is called a "stream cipher" (as opposite with the "block ciphers", wich work with a set of bits, at time) and do the XOR of the bits of the clear text with the output of some form of LFSR, one bit at time. >Now here's the question: If I use the above algorithm what is the >inverse method? How does one convert it back? I'm pretty sure that it is >possible as their are no folded (lost) states. For the implementations that I know, the decipher algorithm is the same (preload the key in the register and do the XOR of the ciphertext bits with the output of the LFSR). The LFSR can be implemented in many forms (the used for the CRC compute is one) and the outputs bits can be all of the SR or with any form of decimation (take one of each N output bits). Regretably, the cryptographic streng of this ciphers isn't very hard and there are algorithms to crack almost all of them. By example, the PKZIP data compresion program is using a stream cipher (if the user request a encrypted file) and also has been cracked (and I'm not talking about "guessing" the password with a huge dictionary...). >I hope someone has a pointer to a solution for me. Thanks. A book of the most interest (about 740 pages of algorithms, sources and a lot of references), for this matters is: Applied Cryptography (second edition) Bruce Schneier John Wiley & Sons, Inc. ISBN 0-471-11709-9 Best regards: -- Roberto Deza Asensio | rdeza@popmail.cti.unav.es Universidad de Navarra | rdeza@cun.unav.es Data Procesing Center | rda@cpd.unav.es