Fixes for miCASAReadBinaryKey and miCASAWriteBinaryKey to work.

This commit is contained in:
Todd Throne 2006-06-21 15:47:45 +00:00
parent 8f96e7cbc1
commit 726e545f31
2 changed files with 5 additions and 4 deletions

View File

@ -32,8 +32,9 @@
Name="VCCustomBuildTool"/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="micasacache.lib"
LinkIncremental="2"
AdditionalLibraryDirectories=""
AdditionalLibraryDirectories="C:\source\CASA\micasacache\Debug"
ModuleDefinitionFile=".\micasa.def"
GenerateDebugInformation="TRUE"
ProgramDatabaseFile="$(OutDir)/c_micasadk.pdb"

View File

@ -1738,7 +1738,7 @@ miCASAWriteBinaryKey
goto errorLevel2;
}
if((escapedSHSKey = (SS_UTF8_T *) malloc(NSSCS_MAX_PASSCODE_LEN)) == NULL)
if((escapedSHSKey = (SS_UTF8_T *) malloc(NSSCS_MAX_SECRET_ID_LEN)) == NULL)
{
rc = NSSCS_E_SYSTEM_FAILURE;
goto errorLevel1;
@ -1746,7 +1746,7 @@ miCASAWriteBinaryKey
memset(secretID.id, 0, NSSCS_MAX_SECRET_ID_LEN);
memset(escapedSHSName, 0, NSSCS_MAX_SECRET_ID_LEN);
memset(escapedSHSKey, 0, NSSCS_MAX_PASSCODE_LEN);
memset(escapedSHSKey, 0, NSSCS_MAX_SECRET_ID_LEN);
// escape delimited characters
if(sharedSecretID->len > NSSCS_MAX_SECRET_ID_LEN)
@ -1782,7 +1782,7 @@ miCASAWriteBinaryKey
keyChainID,
&secretID,
escapedSHSKey,
escNameLen,
keyLen,
val,
*valLen,
epPassword,