Article View: comp.lang.pascal.misc
Article #149Re: *******REVERSE ASCII**********
From: Scott Earnest
Date: Sat, 28 Sep 1996 00:00
Date: Sat, 28 Sep 1996 00:00
37 lines
1827 bytes
1827 bytes
Richard Elbert Davis wrote:
>
> Hey,
> I know of a college who reversed ASCII values for an encryption
> program. DOES ANYONE KNOW THE CODE TO DO THIS.
Well, depending on what you mean by "reverse", sure. But why on earth would you
want to do that if you want encryption? It's pathetically easy to break.
program this_is_lousy_encryption;
var
fi, fo : file of byte;
b : byte;
begin
assign (fi,'source.dat');
assign (fo,'dest.dat');
while not eof(fi) do
begin
read (fi,b);
b := 255-b;
write (fo,b);
end;
close (fi);
close (fo);
end.
(Yes, I'm intentionally demoing this in about the slowest way possible.)
> -Jarrod
--
Scott Earnest | _,-""-_,-""-_,-""-_,-""-_,-""-_,-" |
setech@ix.netcom.com (primary) | We now return you to our regularly |
sinykal@cyberspace.org (alternate) | scheduled chaos and mayhem. . . . |
Technical Details
Message-ID:
<324DA8BC.2057@ix.netcom.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<1996Sep27.160013.6675@arl.mil> <52jbao$c98@dfw-ixnews4.ix.netcom.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11185f,8746d3f6e7cf3444 X-Google-Attributes: gid11185f,public X-Google-Thread: 10261c,38608a28b5863775 X-Google-Attributes: gid10261c,public X-Google-Thread: 102601,8746d3f6e7cf3444 X-Google-Attributes: gid102601,public X-Google-Thread: 111659,8746d3f6e7cf3444 X-Google-Attributes: gid111659,public From: Scott Earnest <setech@ix.netcom.com> Subject: Re: *******REVERSE ASCII********** Date: 1996/09/28 Message-ID: <324DA8BC.2057@ix.netcom.com> X-Deja-AN: 185907304 references: <1996Sep27.160013.6675@arl.mil> <52jbao$c98@dfw-ixnews4.ix.netcom.com> content-type: text/plain; charset=us-ascii organization: Who me? Surely you jest. x-netcom-date: Sat Sep 28 12:36:37 PM PDT 1996 mime-version: 1.0 newsgroups: comp.lang.pascal.misc,comp.lang.pascal.borland,ctdl.lang.pascal,osu.pascal x-mailer: Mozilla 2.01 (Win16; I)