EldoS | Feel safer!

Software components for data protection, secure storage and transfer

TElMessageDecryptor and fixed line widths on larger files

Also by EldoS: BizCrypto
Components for BizTalk® and SQL Server® Integration Services that let you securely store and transfer information in your business automation solutions.
Posted: 11/10/2006 13:06:40
by Sean Ryan (Basic support level)
Joined: 11/09/2006
Posts: 5

Following on from my previous post, I'm now using TElMessageDecryptor with a degree of success.

However, on larger messages the lines are 'word wrapped' to a max of 75 characters with an equals sign (=) at the end of the line (always at position 76 in the line) to denote that the original line is carried on to the next line.

These aren't in the original files when I open them with Outlook/CrytoAPI.

It's not a biggy as I can stitch the lines back together programatically, but I was wondering if there's something simple I'm missing within TElMessageDecryptor?
Posted: 11/10/2006 13:43:11
by Eugene Mayevski (EldoS Corp.)

In fact, something in the process is wrong. What you get from the EasyMAPI (or how it is called) is unprocessed contents of the attachment. It's a BUG - if the data is extracted, it should be processed. So you don't have a valid pkcs7 data, you have just some text which, under certain circumstances, can turn into the valid PKCS7. PKCS7 is a binary format, and when you have text, you don't have PKCS7. And it's your job to convert this "something" to PKCS7.

Alternatively, extract the complete message from MAPI and use SecureBlackbox's MIME classes to process the data.

Sincerely yours
Eugene Mayevski
Posted: 11/12/2006 14:29:02
by Sean Ryan (Basic support level)
Joined: 11/09/2006
Posts: 5

Again Eugene, thanks for your prompt reply.

Bascially within our application EasyMAPI is extracting the SMIME.P7M file and your component is decrypting it.

EasyMAPI does not handle decryption/encryption of any type and is not loaded with any public/private keys. It is blissfully unware that it is extracting encrypted attachments.

If, as you suggest, EasyMAPI is altering the contents of the encrypted binary SMIME.P7M file then wouldn't that reneder the file completely un-decryptable by your component?
Posted: 11/12/2006 15:15:48
by Eugene Mayevski (EldoS Corp.)

I think I was not clear in my explanation. You describe some long text which is wrapped. This text is unrelated to security part, so your question can't be answered in this forum. The reason is that PKCS#7 is the binary format, and if you see text, than this is not PKCS#7. Hope this makes more sense.

Sincerely yours
Eugene Mayevski
Posted: 11/13/2006 12:35:41
by Sean Ryan (Basic support level)
Joined: 11/09/2006
Posts: 5

I figured out what is happening. The equals signs are part of the standard MIME encoding of the raw unencryped file.

Obviously Outlook/CrypoAPI is doing a lot of the work when removing the encrypted text attachment file, which we now reproduce programmatically with our application using EasyMAPI/Blackbox.

Here's an example of what I meant:


Problem solved, many thanks!
Also by EldoS: CallbackFilter
A component to monitor and control disk activity, track file and directory operations (create, read, write, rename etc.), alter file data, encrypt files, create virtual files.



Topic viewed 2820 times

Number of guests: 1, registered members: 0, in total hidden: 0


Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!