HighTechTalks DotNet Forums  

Exchanging keys between custom CSP's and MS CSP's

Dotnet Security microsoft.public.dotnet.security


Discuss Exchanging keys between custom CSP's and MS CSP's in the Dotnet Security forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Miroslav Havram
 
Posts: n/a

Default Exchanging keys between custom CSP's and MS CSP's - 03-02-2005 , 09:35 AM






I'm trying to exchange AES keys between MS RSA & AES CSP and my custom CSP.
Scenario is as follows:

- Create RSA exchange key with custom CSP
- Export PUBLICKEYBLOB from custom CSP (as little-endian)
- Import exported blob into MS CSP as public RSA key
- Generate AES key with MS CSP (as CRYPT_EXPORTABLE)
- Export AES key SIMLEBLOB encrypted with public key exported with custom
CSP
- Trying to import that blob into custom CSP

During last step I always got an error that imported key cipher (remaining
of blob after removing blob header) is not properly padded (it should be
PKCS1 type 2, by MSDN).

Does anybody has any idea what could be wrong with this?



Reply With Quote
  #2  
Old   
Miroslav Havram
 
Posts: n/a

Default Re: Exchanging keys between custom CSP's and MS CSP's - 03-02-2005 , 10:52 AM






Sorry, I've missed newsgroup

"Miroslav Havram" <havramm_no_spam (AT) softhome (DOT) net> wrote

Quote:
I'm trying to exchange AES keys between MS RSA & AES CSP and my custom
CSP. Scenario is as follows:

- Create RSA exchange key with custom CSP
- Export PUBLICKEYBLOB from custom CSP (as little-endian)
- Import exported blob into MS CSP as public RSA key
- Generate AES key with MS CSP (as CRYPT_EXPORTABLE)
- Export AES key SIMLEBLOB encrypted with public key exported with custom
CSP
- Trying to import that blob into custom CSP

During last step I always got an error that imported key cipher (remaining
of blob after removing blob header) is not properly padded (it should be
PKCS1 type 2, by MSDN).

Does anybody has any idea what could be wrong with this?




Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.