|
@@ -536,6 +536,12 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
{
|
|
|
LOG_FUNCTION();
|
|
|
|
|
|
+ ULLINT OpenRFControlTime = 0;
|
|
|
+ ULLINT CloseRFControlTime = 0;
|
|
|
+ ULLINT IDCerAuthenticateTime = 0;
|
|
|
+ ULLINT IDCerGetDataEx2Time = 0;
|
|
|
+ ULLINT ScanIDAndSaveImageTime = 0;
|
|
|
+
|
|
|
DWORD elapsed = 0;
|
|
|
DWORD dwStart = SP::Module::Comm::RVCGetTickCount();
|
|
|
DWORD dwEnd = SP::Module::Comm::RVCGetTickCount();
|
|
@@ -589,10 +595,12 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
errRfOpen = m_hDevHelper->IDCerRFControl(true);
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ OpenRFControlTime = m_ullEndTime - m_ullBeginTime;
|
|
|
if (Error_Succeed == errRfOpen)
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)
|
|
|
- .setAPI("DevAdapter::IDCerRFControl").setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ .setAPI("DevAdapter::IDCerRFControl").setLogCode(IDCertService_LogCode_OpenIDCerRFControl)
|
|
|
+ .setCostTime(OpenRFControlTime)();
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -609,6 +617,7 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
errAuth = m_hDevHelper->IDCerAuthenticate();
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ IDCerAuthenticateTime = m_ullEndTime - m_ullBeginTime;
|
|
|
if (Error_Succeed != errAuth)
|
|
|
{
|
|
|
dwEnd = SP::Module::Comm::RVCGetTickCount();
|
|
@@ -618,12 +627,13 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
else
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)
|
|
|
- .setAPI("DevAdapter::IDCerAuthenticate").setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ .setAPI("DevAdapter::IDCerAuthenticate").setCostTime(IDCerAuthenticateTime)();
|
|
|
bIDCerAuthenticate = true;
|
|
|
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
errReadEx2 = m_hDevHelper->IDCerGetDataEx2(idInfoEx2);
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ IDCerGetDataEx2Time = m_ullEndTime - m_ullBeginTime;
|
|
|
|
|
|
if (errReadEx2 == Error_NotImpl)
|
|
|
{
|
|
@@ -659,8 +669,7 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
unsigned char IssuedSN[1024]; memset(IssuedSN, 0, 1024); //换证次数
|
|
|
|
|
|
DbgWithLink(LOG_LEVEL_INFO, ctx->link.checkEmpty() ? LOG_TYPE_SYSTEM : LOG_TYPE_USER)
|
|
|
- .setAPI("DevAdapter::IDCerGetDataEx2").setCostTime(m_ullEndTime - m_ullBeginTime)
|
|
|
- .setLogCode(IDCertService_LogCode_ReadAndScanUTF8)();
|
|
|
+ .setAPI("DevAdapter::IDCerGetDataEx2").setCostTime(IDCerGetDataEx2Time)();
|
|
|
bReadSuccess = true;
|
|
|
LogEvent(Severity_Middle, LOG_EVT_IDCERTIFICATE_OP, "IDCertifacate op.");
|
|
|
|
|
@@ -816,10 +825,13 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
eErr = m_hDevHelper->ScanIDAndSaveImage();
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ ScanIDAndSaveImageTime = m_ullEndTime - m_ullBeginTime;
|
|
|
+
|
|
|
if (eErr == Error_Succeed)
|
|
|
{
|
|
|
curDeleteType = Bmp_ZP | Bmp_SCAN;
|
|
|
- DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM).setAPI("DevAdapter::ScanIDAndSaveImage").setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM).setAPI("DevAdapter::ScanIDAndSaveImage")
|
|
|
+ .setCostTime(ScanIDAndSaveImageTime)();
|
|
|
|
|
|
transImgMsg.Clear();
|
|
|
//idfront.bmp" and "idback.bmp
|
|
@@ -867,7 +879,7 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
{
|
|
|
if (eErr != Error_NotImpl)
|
|
|
SetErrorAndLog(eErr, MEC_DEVAPI_IDCER_ScanIDAndSaveImage, "DevAdapter::ScanIDAndSaveImage", __FUNCTION__,
|
|
|
- false, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8);
|
|
|
+ false, ScanIDAndSaveImageTime);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -907,15 +919,18 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
ErrorCodeEnum eErr1 = m_hDevHelper->IDCerRFControl(false);
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ CloseRFControlTime = m_ullEndTime - m_ullBeginTime;
|
|
|
+
|
|
|
if (eErr1 != Error_Succeed)
|
|
|
{
|
|
|
SetErrorAndLog(eErr1, MEC_DEVAPI_IDCER_IDCerRFControl, "DevAdapter::IDCerRFControl", __FUNCTION__,
|
|
|
- false, m_ullEndTime - m_ullBeginTime, "", SetRFControlContext(false).GetData());
|
|
|
+ false, CloseRFControlTime, IDCertService_LogCode_CloseIDCerRFControl);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM).setAPI("DevAdapter::IDCerRFControl")
|
|
|
- .setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ .setLogCode(IDCertService_LogCode_CloseIDCerRFControl)
|
|
|
+ .setCostTime(CloseRFControlTime)();
|
|
|
}
|
|
|
|
|
|
if (bGetIDCert)
|
|
@@ -932,14 +947,14 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
if (bInvokeReadEx2 && !bReadSuccess) {
|
|
|
|
|
|
SetErrorAndLog(errReadEx2, MEC_DEVAPI_IDCER_IDCerGetDataEx2, "DevAdapter::IDCerGetDataEx2", __FUNCTION__,
|
|
|
- true, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8);
|
|
|
+ true, IDCerGetDataEx2Time);
|
|
|
ctx->Answer(Error_TimeOut, GetAlarmDEC()); //RTA2109
|
|
|
}
|
|
|
}
|
|
|
else if (!bOpenRF)
|
|
|
{
|
|
|
SetErrorAndLog(errRfOpen, MEC_DEVAPI_IDCER_IDCerRFControl, "DevAdapter::IDCerRFControl", __FUNCTION__,
|
|
|
- true, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8, SetRFControlContext(true).GetData());
|
|
|
+ true, OpenRFControlTime, IDCertService_LogCode_OpenIDCerRFControl);
|
|
|
ctx->Answer(Error_TimeOut, GetAlarmDEC());
|
|
|
}
|
|
|
else
|
|
@@ -947,26 +962,26 @@ int CIDCertFSM::ReadAndScanUTF8(SpReqAnsContext<IDCert_ReadAndScanUTF8_Req, IDCe
|
|
|
if (errAuth == Error_DevMedia)
|
|
|
{
|
|
|
LogWarn(Severity_Low, Error_Unexpect, IDCertificate_UserErrorCode_Timeout_OtherCard, "读证超时,插入的卡片非身份.");
|
|
|
- DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setLogCode(IDCertService_LogCode_ReadAndScanUTF8)();
|
|
|
+ DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setAPI("DevAdapter::IDCerAuthenticate").setCostTime(IDCerAuthenticateTime)();
|
|
|
ctx->Answer(Error_TimeOut);
|
|
|
}
|
|
|
else if(errAuth == Error_Dev_IDCardNotFound)
|
|
|
{
|
|
|
LogWarn(Severity_Low, Error_Unexpect, IDCertificate_UserErrorCode_Timeout_NoCard, "读证超时,未检测到有卡片插入.");
|
|
|
- DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setLogCode(IDCertService_LogCode_ReadAndScanUTF8)();
|
|
|
+ DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setAPI("DevAdapter::IDCerAuthenticate").setCostTime(IDCerAuthenticateTime)();
|
|
|
ctx->Answer(Error_TimeOut);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
SetErrorAndLog(errAuth, MEC_DEVAPI_IDCER_IDCerAuthenticate, "DevAdapter::IDCerAuthenticate", __FUNCTION__,
|
|
|
- false, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8); //RTA2107
|
|
|
+ false, IDCerAuthenticateTime); //RTA2107
|
|
|
ctx->Answer(Error_Unexpect, GetAlarmDEC());
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- DbgWithLink(LOG_LEVEL_ERROR, LOG_TYPE_USER).setLogCode(IDCertService_LogCode_ReadAndScanUTF8).setResultCode("RTA2104")("ReadAndScanUTF8 some thing wrong.");
|
|
|
+ DbgWithLink(LOG_LEVEL_ERROR, LOG_TYPE_USER).setResultCode("RTA2104")("ReadAndScanUTF8JS some thing wrong.");
|
|
|
ctx->Answer(Error_Unexpect, IDCertificate_UserErrorCode_ReadAndScan_Failed);
|
|
|
LogError(Severity_High, Error_Unexpect, IDCertificate_UserErrorCode_ReadAndScan_Failed, "ReadAndScanUTF8 some thing wrong.");
|
|
|
}
|
|
@@ -993,6 +1008,12 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
{
|
|
|
LOG_FUNCTION();
|
|
|
|
|
|
+ ULLINT OpenRFControlTime = 0;
|
|
|
+ ULLINT CloseRFControlTime = 0;
|
|
|
+ ULLINT IDCerAuthenticateTime = 0;
|
|
|
+ ULLINT IDCerGetDataEx2Time = 0;
|
|
|
+ ULLINT ScanIDAndSaveImageTime = 0;
|
|
|
+
|
|
|
DWORD elapsed = 0;
|
|
|
DWORD dwStart = SP::Module::Comm::RVCGetTickCount();
|
|
|
DWORD dwEnd = SP::Module::Comm::RVCGetTickCount();
|
|
@@ -1046,11 +1067,13 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
errRfOpen = m_hDevHelper->IDCerRFControl(true);
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ OpenRFControlTime = m_ullEndTime - m_ullBeginTime;
|
|
|
|
|
|
if (Error_Succeed == errRfOpen)
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)
|
|
|
- .setAPI("DevAdapter::IDCerRFControl").setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ .setAPI("DevAdapter::IDCerRFControl").setLogCode(IDCertService_LogCode_OpenIDCerRFControl)
|
|
|
+ .setCostTime(OpenRFControlTime)();
|
|
|
}
|
|
|
else
|
|
|
{
|
|
@@ -1067,6 +1090,8 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
errAuth = m_hDevHelper->IDCerAuthenticate();
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ IDCerAuthenticateTime = m_ullEndTime - m_ullBeginTime;
|
|
|
+
|
|
|
if (Error_Succeed != errAuth)
|
|
|
{
|
|
|
dwEnd = SP::Module::Comm::RVCGetTickCount();
|
|
@@ -1076,12 +1101,14 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
else
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)
|
|
|
- .setAPI("DevAdapter::IDCerAuthenticate").setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ .setAPI("DevAdapter::IDCerAuthenticate").setCostTime(IDCerAuthenticateTime)();
|
|
|
bIDCerAuthenticate = true;
|
|
|
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
errReadEx2 = m_hDevHelper->IDCerGetDataEx2(idInfoEx2);
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ IDCerGetDataEx2Time = m_ullEndTime - m_ullBeginTime;
|
|
|
+
|
|
|
if (errReadEx2 == Error_NotImpl)
|
|
|
{
|
|
|
ctx->Ans.msgtype = 0; //旧字段传递,GBK、字符串传递文字信息
|
|
@@ -1116,8 +1143,7 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
unsigned char IssuedSN[1024]; memset(IssuedSN, 0, 1024); //换证次数
|
|
|
|
|
|
DbgWithLink(LOG_LEVEL_INFO, ctx->link.checkEmpty() ? LOG_TYPE_SYSTEM : LOG_TYPE_USER)
|
|
|
- .setAPI("DevAdapter::IDCerGetDataEx2").setCostTime(m_ullEndTime - m_ullBeginTime)
|
|
|
- .setLogCode(IDCertService_LogCode_ReadAndScanUTF8JS)();
|
|
|
+ .setAPI("DevAdapter::IDCerGetDataEx2").setCostTime(IDCerGetDataEx2Time)();
|
|
|
bReadSuccess = true;
|
|
|
LogEvent(Severity_Middle, LOG_EVT_IDCERTIFICATE_OP, "IDCertifacate op.");
|
|
|
|
|
@@ -1273,10 +1299,13 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
eErr = m_hDevHelper->ScanIDAndSaveImage();
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ ScanIDAndSaveImageTime = m_ullEndTime - m_ullBeginTime;
|
|
|
+
|
|
|
if (eErr == Error_Succeed)
|
|
|
{
|
|
|
curDeleteType = Bmp_ZP | Bmp_SCAN;
|
|
|
- DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM).setAPI("DevAdapter::ScanIDAndSaveImage").setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM).setAPI("DevAdapter::ScanIDAndSaveImage")
|
|
|
+ .setCostTime(ScanIDAndSaveImageTime)();
|
|
|
|
|
|
transImgMsg.Clear();
|
|
|
//idfront.bmp" and "idback.bmp
|
|
@@ -1324,7 +1353,7 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
{
|
|
|
if(eErr != Error_NotImpl)
|
|
|
SetErrorAndLog(eErr, MEC_DEVAPI_IDCER_ScanIDAndSaveImage, "DevAdapter::ScanIDAndSaveImage", __FUNCTION__,
|
|
|
- false, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8JS);
|
|
|
+ false, ScanIDAndSaveImageTime);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -1364,15 +1393,18 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
m_ullBeginTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
ErrorCodeEnum eErr1 = m_hDevHelper->IDCerRFControl(false);
|
|
|
m_ullEndTime = SP::Module::Comm::RVCGetTickCount();
|
|
|
+ CloseRFControlTime = m_ullEndTime - m_ullBeginTime;
|
|
|
+
|
|
|
if (eErr1 != Error_Succeed)
|
|
|
{
|
|
|
SetErrorAndLog(eErr1, MEC_DEVAPI_IDCER_IDCerRFControl, "DevAdapter::IDCerRFControl", __FUNCTION__,
|
|
|
- false, m_ullEndTime - m_ullBeginTime, "", SetRFControlContext(false).GetData());
|
|
|
+ false, CloseRFControlTime, IDCertService_LogCode_CloseIDCerRFControl);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM).setAPI("DevAdapter::IDCerRFControl")
|
|
|
- .setCostTime(m_ullEndTime - m_ullBeginTime)();
|
|
|
+ .setLogCode(IDCertService_LogCode_CloseIDCerRFControl)
|
|
|
+ .setCostTime(CloseRFControlTime)();
|
|
|
}
|
|
|
|
|
|
if (bGetIDCert)
|
|
@@ -1389,7 +1421,7 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
if (bInvokeReadEx2 && !bReadSuccess) {
|
|
|
|
|
|
SetErrorAndLog(errReadEx2, MEC_DEVAPI_IDCER_IDCerGetDataEx2, "DevAdapter::IDCerGetDataEx2", __FUNCTION__,
|
|
|
- true, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8JS);
|
|
|
+ true, IDCerGetDataEx2Time);
|
|
|
//DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("Invoke IDCerGetDataEx2(Timeout) failed: %s", SpStrError(errReadEx2));
|
|
|
|
|
|
ctx->Answer(Error_TimeOut, GetAlarmDEC()); //RTA2109
|
|
@@ -1398,7 +1430,7 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
else if (!bOpenRF)
|
|
|
{
|
|
|
SetErrorAndLog(errRfOpen, MEC_DEVAPI_IDCER_IDCerRFControl, "DevAdapter::IDCerRFControl", __FUNCTION__,
|
|
|
- true, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8JS, SetRFControlContext(true).GetData());
|
|
|
+ true, OpenRFControlTime, IDCertService_LogCode_OpenIDCerRFControl);
|
|
|
//DbgWithLink(LOG_LEVEL_WARN, LOG_TYPE_SYSTEM)("Open IDCerRFControl(Timeout) failed: %s", SpStrError(errRfOpen));
|
|
|
|
|
|
ctx->Answer(Error_TimeOut, GetAlarmDEC());
|
|
@@ -1409,26 +1441,26 @@ int CIDCertFSM::ReadAndScanUTF8JS(SpReqAnsContext<IDCert_ReadAndScanUTF8JS_Req,
|
|
|
if (errAuth == Error_DevMedia)
|
|
|
{
|
|
|
LogWarn(Severity_Low, Error_Unexpect, IDCertificate_UserErrorCode_Timeout_OtherCard, "读证超时,插入的卡片非身份.");
|
|
|
- DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setLogCode(IDCertService_LogCode_ReadAndScanUTF8JS)();
|
|
|
+ DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setAPI("DevAdapter::IDCerAuthenticate").setCostTime(IDCerAuthenticateTime)();
|
|
|
ctx->Answer(Error_TimeOut);
|
|
|
}
|
|
|
else if (errAuth == Error_Dev_IDCardNotFound)
|
|
|
{
|
|
|
LogWarn(Severity_Low, Error_Unexpect, IDCertificate_UserErrorCode_Timeout_NoCard, "读证超时,未检测到有卡片插入.");
|
|
|
- DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setLogCode(IDCertService_LogCode_ReadAndScanUTF8JS)();
|
|
|
+ DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_USER).setAPI("DevAdapter::IDCerAuthenticate").setCostTime(IDCerAuthenticateTime)();
|
|
|
ctx->Answer(Error_TimeOut);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
SetErrorAndLog(errAuth, MEC_DEVAPI_IDCER_IDCerAuthenticate, "DevAdapter::IDCerAuthenticate", __FUNCTION__,
|
|
|
- false, m_ullEndTime - m_ullBeginTime, IDCertService_LogCode_ReadAndScanUTF8JS); //RTA2107
|
|
|
+ false, IDCerAuthenticateTime); //RTA2107
|
|
|
ctx->Answer(Error_Unexpect, GetAlarmDEC());
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- DbgWithLink(LOG_LEVEL_ERROR, LOG_TYPE_USER).setLogCode(IDCertService_LogCode_ReadAndScanUTF8JS).setResultCode("RTA2104")("ReadAndScanUTF8JS some thing wrong.");
|
|
|
+ DbgWithLink(LOG_LEVEL_ERROR, LOG_TYPE_USER).setResultCode("RTA2104")("ReadAndScanUTF8JS some thing wrong.");
|
|
|
ctx->Answer(Error_Unexpect, IDCertificate_UserErrorCode_ReadAndScan_Failed);
|
|
|
LogError(Severity_High, Error_Unexpect, IDCertificate_UserErrorCode_ReadAndScan_Failed, "ReadAndScanUTF8 some thing wrong.");
|
|
|
}
|
|
@@ -2137,26 +2169,6 @@ CSimpleStringA CIDCertFSM::GetFileLastModifyTime(CSimpleStringA filePath)
|
|
|
#endif
|
|
|
}
|
|
|
|
|
|
-CSimpleStringA CIDCertFSM::SetRFControlContext(bool bControl)
|
|
|
-{
|
|
|
- CSimpleStringA keyContext = "";
|
|
|
- if (bControl) //true
|
|
|
- {
|
|
|
- keyContext = "Open";
|
|
|
- }
|
|
|
- else //false
|
|
|
- {
|
|
|
- keyContext = "Close";
|
|
|
- }
|
|
|
- std::map<std::string, std::string> msgInfo;
|
|
|
- msgInfo["RFControlFlag"] = keyContext.GetData();
|
|
|
- std::pair<bool, std::string> strResult;
|
|
|
- strResult = generateJsonStr(msgInfo);
|
|
|
- CSimpleStringA rfContext = strResult.second.c_str();
|
|
|
-
|
|
|
- return rfContext;
|
|
|
-}
|
|
|
-
|
|
|
#ifdef RVC_OS_WIN
|
|
|
void CIDCertFSM::HttpsLogCallBack(const char* logtxt)
|
|
|
{
|