OT: base64 decoding

John Esak john at valar.com
Thu May 7 13:14:30 PDT 2009


It was me. I wrote the base64 conversion.  I needed to because Mr. Mailman
or whatever Dave Stauble's program was called Mail Manager or something like
that I forget...used to have a feature in it that would let you take
anything that was attached to an eamil as a base64 file and do something
with it... Anything... It was a command you "named" and listed in a config
text file somewhere on Unix. Then When any piece of mail to a particular
named person came in, the program would detach any base64 attachment, and
give it to the command or set of commands.  First thing I did was convert it
to regular text and then pass it into our order system.  Getting that code
now would be tough, not working for Nexus anymore.  I might have it
somewhere, but I doubt it. 

I essentially copied out a small C script I got from somewhere and just
translated it to filePro lingo.  It is so weird, strange, enlightening and
fascinating to see how precisely the filePro if-then combination mimics the
same functionality in C. This was not an exceedingly hard thing to do... In
fact, I probably could have done it simply as a big "logic" problem.  I
mean, I don't think you would have to know anything about C or filePro, if
you just nip and tuck the function in a way to make it into an if-then
without the else... Then move it into a processing table, I don't think it
was more than a dozen lines when it was done.  However, and here's the rub.
Getting this tiny conversion function inside the middle of a prc that opens
the right file, checks the type of encoding, moves the data around to where
you need it, etc., etc. Eventually, it becasme a large table that I just
CALL'd I think.  Any problems I had with it were always with the incoming
data, separating it out of the mail message and mail files,  and not the
conversion. So, Richard, honestly, I would do just what ken suggested... Get
a hold of one of the many conversions out there, and just pass your file to
it.  The whole thing could be done with file i/o now so much easier then
whatever way I did it way back then. 

John


> -----Original Message-----
> From: filepro-list-bounces+john=valar.com at lists.celestial.com 
> [mailto:filepro-list-bounces+john=valar.com at lists.celestial.co
m] On Behalf Of Kenneth Brody
> Sent: Thursday, May 07, 2009 11:26 AM
> To: rkreiss at gccconsulting.net
> Cc: filepro-list at lists.celestial.com
> Subject: Re: OT: base64 decoding
> 
> Richard Kreiss wrote:
> > Received an email from my wife which had been bounced back 
> as undeliverable
> > to another party.
> > 
> > In the body of the email is text apparently encoded in base64.
> > 
> > Windows xp - Outlook 2007.
> > 
> > Are there an tools I can use to decode (make readable) this 
> information.
> > 
> > Subject:
> > =?utf-8?B?UmVzdGF1cmFudCBJbnZpdGF0aW9uIGZyb20gU3VzYW4gS3JlaXNz?=
> > Content-Type: text/html; charset=utf-8
> > Content-Transfer-Encoding: base64
> 
> Well, I have a plugin for Thunderbird that does it:
> 
>      UmVzdGF1cmFudCBJbnZpdGF0aW9uIGZyb20gU3VzYW4gS3JlaXNz
> ==>
>      Restaurant Invitation from Susan Kreiss
> 
> I think I recall someone writing a BASE64 encode/decode in 
> filePro some time 
> back?  (Or maybe someone was just talking about it, but 
> didn't actually do 
> it?  It's been several years.)
> 
> If you need, there are plenty of online BASE64 decoders 
> available.  Just 
> search for "base64 decoder".
> 
>      http://www.opinionatedgeek.com/dotnet/tools/Base64Decode/
> 
> -- 
> Kenneth Brody
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> http://mailman.celestial.com/mailman/listinfo/filepro-list
> 



More information about the Filepro-list mailing list