Fixes for miCASAReadBinaryKey and miCASAWriteBinaryKey to work.
This commit is contained in:
		| @@ -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" | ||||
|   | ||||
| @@ -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,  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user