Article View: sci.crypt
Article #2968Re: Toggle rot-13 decode..
From: Harald Hanche-Olsen
Date: Wed, 27 Jan 1993 18:42
Date: Wed, 27 Jan 1993 18:42
27 lines
1451 bytes
1451 bytes
>>>>> In article <1993Jan27.094456.10542@hsr.no>, frank@hsr.no (Frank
>>>>> A Stevenson) writes:
Frank> Here is a small c-source that reads from standard input and
Frank> writes the encrypted text to standard out. Note the cipher is
Frank> symmetrical and the same routine will thus encipher and
Frank> decipher a text
Frank> examples of usagege (UNIX)
Frank> %rot <infile >outfile
[ twentyish-line C program deleted ]
Hrmf. The rot program is already there, on any Unix box. It is
called tr:
$ rot () { tr 'a-zA-Z' 'n-za-mN-ZA-M' }
# for csh users: alias rot tr 'a-zA-Z' 'n-za-mN-ZA-M'
$ echo 'Render unto Caesar...' | rot
Eraqre hagb Pnrfne...
$ echo 'Render unto Caesar...' | rot | rot
Render unto Caesar...
[ I hope I am not violating the ITAR by posting this ... :-) ]
- Harald
Technical Details
Message-ID:
<HANCHE.93Jan27134217@ptolemy.ams.sunysb.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!tcsi.com!iat.holonet.net!news.cerf.net!usc!howland.reston.ans.net!bogus.sura.net!udel!sbcs.sunysb.edu!hancheReferences:
<C1Ho7r.J1M@eis.calstate.edu> <1993Jan27.094456.10542@hsr.no>Show Full Headers
Complete Article Headers
Newsgroups: sci.crypt Path: arc1-ca.pugleaf.net!sparky!uunet!tcsi.com!iat.holonet.net!news.cerf.net!usc!howland.reston.ans.net!bogus.sura.net!udel!sbcs.sunysb.edu!hanche From: hanche@ams.sunysb.edu (Harald Hanche-Olsen) Subject: Re: Toggle rot-13 decode.. In-Reply-To: frank@hsr.no's message of Wed, 27 Jan 1993 09: 44:56 GMT Message-ID: <HANCHE.93Jan27134217@ptolemy.ams.sunysb.edu> Sender: usenet@sbcs.sunysb.edu (Usenet poster) Nntp-Posting-Host: ptolemy.ams.sunysb.edu Organization: University at Stony Brook, NY References: <C1Ho7r.J1M@eis.calstate.edu> <1993Jan27.094456.10542@hsr.no> Date: Wed, 27 Jan 1993 18:42:17 GMT Lines: 27