#include "testParams.h"
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <string.h>
#include <utilLib/common.h>
#include <utilLib/cspwrap.h>
#include <Security/Security.h>
#include <Security/SecTrustSettingsPriv.h>
#include <stddef.h>
#include <unistd.h>
int copyRootsInit(
TestParams *testParams)
{
return 0;
}
int copyRootsTest(TestParams *testParams)
{
for(unsigned loop=0; loop<testParams->numLoops; loop++) {
if(testParams->verbose) {
printf("derDecode thread %d: loop %d\n",
testParams->threadNum, loop);
}
else if(!testParams->quiet) {
printChar(testParams->progressChar);
}
CFArrayRef theArray = NULL;
OSStatus ortn = SecTrustSettingsCopyQualifiedCerts(&CSSMOID_APPLE_TP_SSL,
"localhost", 10, CSSM_KEYUSE_ENCRYPT, &theArray);
if(ortn) {
cssmPerror("SecTrustSettingsCopyQualifiedCerts", ortn);
return 1;
}
CFRelease(theArray);
}
return 0;
}