This commit is contained in:
Ren RenJuan 2014-01-10 22:01:44 +00:00
parent 0384277007
commit 01cd5452c6
2 changed files with 3 additions and 20 deletions

View File

@ -8,7 +8,7 @@ class ausRegEPPTK {
public: int tkScenario; public: int tkScenario;
// See the Toolkit Overview. At this level supposedly it can do everything. // See the Toolkit Overview. At this level supposedly it can do everything.
ausRegEPPTK() { tkScenario = 0; } ausRegEPPTK() { tkScenario = 1; }
bool didInit(const std::string propertiesFilePath); bool didInit(const std::string propertiesFilePath);

View File

@ -6,29 +6,12 @@ bool ausRegEPPTK::didInit(const std::string propPath) {
bool did=false; bool did=false;
getPeerService:
switch(tkScenario) {
case 0:
try {
init( propPath );
did = true;
}
catch(std::exception &e) {
theseLogs->logN(1,"Scenario Zero TK Exception: %s .",e.what());
}
if (!did) { if (tkScenario++ <= MAX_SCENARIO) goto getPeerService; }
break;
case 1: // Our first level of implementation, allow an insecure partially authenticated TLS Session.
try { try {
scenario( tkScenario ); scenario( tkScenario );
did = true; did = true;
} }
catch(std::exception &e) { catch(std::exception &e) {
theseLogs->logN(1,"Scenario One TK Exception: %s .",e.what()); theseLogs->logN(2,"Scenario %d TK Exception: %s .",tkScenario,e.what());
}
if (!did) { if (tkScenario++ <= MAX_SCENARIO) goto getPeerService; }
break;
} }
return did; return did;