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"/> Name="VCCustomBuildTool"/>
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="micasacache.lib"
LinkIncremental="2" LinkIncremental="2"
AdditionalLibraryDirectories="" AdditionalLibraryDirectories="C:\source\CASA\micasacache\Debug"
ModuleDefinitionFile=".\micasa.def" ModuleDefinitionFile=".\micasa.def"
GenerateDebugInformation="TRUE" GenerateDebugInformation="TRUE"
ProgramDatabaseFile="$(OutDir)/c_micasadk.pdb" ProgramDatabaseFile="$(OutDir)/c_micasadk.pdb"

View File

@ -1738,7 +1738,7 @@ miCASAWriteBinaryKey
goto errorLevel2; 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; rc = NSSCS_E_SYSTEM_FAILURE;
goto errorLevel1; goto errorLevel1;
@ -1746,7 +1746,7 @@ miCASAWriteBinaryKey
memset(secretID.id, 0, NSSCS_MAX_SECRET_ID_LEN); memset(secretID.id, 0, NSSCS_MAX_SECRET_ID_LEN);
memset(escapedSHSName, 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 // escape delimited characters
if(sharedSecretID->len > NSSCS_MAX_SECRET_ID_LEN) if(sharedSecretID->len > NSSCS_MAX_SECRET_ID_LEN)
@ -1782,7 +1782,7 @@ miCASAWriteBinaryKey
keyChainID, keyChainID,
&secretID, &secretID,
escapedSHSKey, escapedSHSKey,
escNameLen, keyLen,
val, val,
*valLen, *valLen,
epPassword, epPassword,