| | |
about 'CryptDestroyKey' function!
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Sep 2008
Posts: 4
Reputation:
Solved Threads: 0
I have some questions about using Cavium CSP, which need your kindness help.
According to the explain in MSDN, the function 'CryptDestroyKey' of CRYPTAPI
will not only destory the key handle, but also free the memory that the key
occupied.
But using Cavium CSP, the function does not free the memory. What is the
problem?
It is my code below. This circle will only run 64 times around, then it
fails because of lack of memory in Card.
Thank you for your help!
According to the explain in MSDN, the function 'CryptDestroyKey' of CRYPTAPI
will not only destory the key handle, but also free the memory that the key
occupied.
But using Cavium CSP, the function does not free the memory. What is the
problem?
It is my code below. This circle will only run 64 times around, then it
fails because of lack of memory in Card.
C++ Syntax (Toggle Plain Text)
while(1) { if(!CryptImportPublicKeyInfo(hCryptProv, MY_ENCODING_TYPE,&(pCertContext->pCertInfo->SubjectPublicKeyInfo),&hPubKey)) { cout<<hex<<GetLastError()<<endl; break; goto while_end; } else { bSuceess = TURE; } while_end: if(hPubKey) CryptDestroyKey(hPubKey); if(bSuceess){iSuccess++;} else{iFalse++;} }
Thank you for your help!
Last edited by cscgal; Sep 4th, 2008 at 3:43 am. Reason: Fixed code tags
![]() |
Other Threads in the C++ Forum
- Previous Thread: An equivalent to a vector<ifstream> member variable
- Next Thread: Line count not working....
| Thread Tools | Search this Thread |
api array beginner binary bitmap c++ c/c++ calculator char char* class classes coding compile compiler console conversion convert count data database delete desktop developer directshow dll download dynamic email encryption error file forms fstream function functions game getline google graph gui homeworkhelper iamthwee ifstream input int integer java lib linkedlist linker linux loop looping loops map math matrix memory multiple news node number numbertoword output parameter pointer problem program programming project proxy python random read recursion recursive reference return sorting string strings struct template templates test text text-file tree unix url vector video visualstudio win32 windows winsock word wordfrequency wxwidgets





