EldoS | Feel safer!

Software components for data protection, secure storage and transfer

DetectKeyFileFormat help

Also by EldoS: CallbackDisk
Create virtual disks backed by memory or custom location, expose disk images as disks and more.
#148
Posted: 05/10/2006 05:49:08
by Santiago Castaño (Standard support level)
Joined: 04/16/2006
Posts: 155

Hi,

Some users (me included) when a opendialog with a filter appears, just type *.* and press the enter key; so when i(them) load a certificate or a key, they just see "invalid data certificate" for example.

So i just set the program to use DetectCertFileFormat and just works fine, but i'm trying now to figure out how to use DetectKeyFileFormat for loading the keys and i can't find any help in the lastest chm.

I saw the code of this function, and i see that (in my version) has commented the MS-keys. WHY? (i'm supposed to support them). I also see that you just load the keys, so another question is... if i use that function, the certificate already has the key or not??

Many thanks again and again
#149
Posted: 05/10/2006 06:09:17
by Eugene Mayevski (EldoS Corp.)

This is a quick 5-minute function to detect most common formats. If you have the source code, it should be enough for you to understand how it works. The method loads the file into the [temporary] instance of certificate and checks the result. That's all, no tricks. I don't know what you mean by MS-keys, and it's likely that you mean something different than we did.
For some formats there's no method in ElX509Certificate to load a key into the certificate. DetectKeyFileFormat doesn't detect such formats. You can write your own function easily and do whatever you want in this function.


Sincerely yours
Eugene Mayevski
#150
Posted: 05/10/2006 07:21:31
by Santiago Castaño (Standard support level)
Joined: 04/16/2006
Posts: 155

:D Sorry, it was my fault, i was looking at detectcertfileformat(tstream) instead of detectkeyfileformat.

Now, i've got another question... my program signs/verifies/(de)encrypt files in separate thread(s). And i put a "cancel" button. With that button, i do a .TERMINATE thread; but it doesn't stops it until de file is for example signed.

I don't want really to use terminatethread becaure of the resources allocation, is there anyway i can stop that thread or call my signer component to stop signing???? (how do you do it in crypto4files?)

Thanks
#151
Posted: 05/10/2006 07:35:09
by Ken Ivanov (EldoS Corp.)

Quote
Now, i've got another question... my program signs/verifies/(de)encrypt files in separate thread(s). And i put a "cancel" button. With that button, i do a .TERMINATE thread; but it doesn't stops it until de file is for example signed.

Unfortunately, there's no possibility to terminate signing/encryption operation at the moment. However, there exists a corresponding item in our to do list, so I hope it will be possible in one of the future SecureBlackbox build updates.
#156
Posted: 05/11/2006 04:32:51
by Eugene Mayevski (EldoS Corp.)

Quote
Santiago Castaño wrote:
is there anyway i can stop that thread or call my signer component to stop signing???? (how do you do it in crypto4files?)


We use TerminateThread. But since there's no resources allocated in secondary thread, it's not a big problem.


Sincerely yours
Eugene Mayevski
Also by EldoS: RawDisk
Access locked and protected files in Windows, read and write disks and partitions and more.

Reply

Statistics

Topic viewed 6418 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!