Path: utzoo!attcan!uunet!wyse!vsi1!ubvax!ames!ncar!oddjob!uwvax!umn-d-ub!umn-cs!bungia!com50!n0atp!barry From: barry@n0atp.UUCP (Barry S. Berg) Newsgroups: comp.mail.elm Subject: Re: Crypt() in Elm - This may be a problem! Message-ID: <23@n0atp.UUCP> Date: 30 Jun 88 12:22:40 GMT References: <470@altnet.ALTOS.COM> <278@clout.Jhereg.MN.ORG> <485@altnet.ALTOS.COM> <10291@ncc.Nexus.CA> <1060@datapg.DataPg.MN.ORG> <520@a Reply-To: barry@n0atp.UUCP (Barry S. Berg) Organization: N0ATP, Amateur Radio Packet Gateway, St. Paul, MN Lines: 83 In article <520@altnet.ALTOS.COM> edc@altnet.UUCP (Eric Christensen) writes: >In article <10291@ncc.Nexus.CA> lyndon@ncc.nexus.ca (Lyndon Nerenberg) writes: >> >>As far as I am concerned, if two people want to send each other encrypted >>mail they should implement their own compatable (with each others) I agree with Lyndon as well on this one. >My proposed solution: remove the crypt option from Elm. Wait!!!! > [... justification ....] In fact, you may >be decreasing it's worth, based on the fact that you're adding more code, which >makes it harder to maintain and keep portable (can you sy 80286? :-). Agreed... especially since I have a 286... > >If nobody comes up with a real good reason to keep the crypt calls, I'm going >to yank them (or at least ifdef them out). And I don't plan on spending any >more time working on this issue. After all, there are "real" bugs to be fixed, >and a release to get out. What I propose is to put a dummy local routine in. IBM calls this a user exit on their mainframe software. The local definiation would overide the external definition, not a lot of code would be generated, and the system would allow the use of crypt(1) or a PD crypt if desired. The following would be a code sample. #ifndef CRYPT /* if std encryption not desired */ char * crypt(key, salt) char *key, *salt; { #ifndef LOCAL_CRYPT return(key); #else /* put your locally defined code here */ #endif } void setkey(key) char *key; { #ifndef LOCAL_CRYPT return; #else /* put your locally defined code here */ #endif } void encrypt(block, edflag) char *block; int edflag; { #ifndef LOCAL_CRYPT return; #else /* put your locally defined code here */ #endif } #endif By undefing CRYPT and LOCAL_CRYPT selectively all sides could be accomodated, still maintaining a consistant interface, and standard code distribution. Also, the overhead in code size would be faily small. There will also be specific code hacks for the 80286 systems. Can we isolate them as follows. This will work automatically for SCO Xenix, no defines needed. #ifndef I_286 regular way #else for the 286 #endif Comments?? -- Barry S. Berg DOMAIN: barry@n0atp.N0ATP.MN.ORG N0ATP Packet Radio Gateway UUCP: {...}amdahl!bungia!n0atp!barry "Speech is civilization itself--it is silence which isolates." --Thomas Mann "Moderation in all things, most especially moderation." --Author as yet unknown.