Commit e9eaf7dc by 李定达

1.导出获取证书接口

parent c7edf91b
......@@ -36,7 +36,7 @@ using std::string;
int CheckRSASign();
int SendMsg(const std::string &text, const string &url, int iscret = 1);
int UTF8ToGBK(unsigned char * lpUTF8Str,unsigned char * lpGBKStr,int nGBKStrLen);
int GetRSACret(int partnerId,const char *storeID,const char *posNo);
//int GetRSACret(int partnerId,const char *storeID,const char *posNo);
typedef struct
{
......@@ -397,10 +397,10 @@ int ProcessPosReqData(const char *indata, string &in, int *needrbk, int *reqType
}
tmps << string((char *)json_string_value(stationId));
if(initflag == 0 && GetRSACret((int)json_integer_value(partnerId), json_string_value(storeId), json_string_value(stationId)) == 1)
{
initflag = 1;
}
//if(initflag == 0 && GetRSACret((int)json_integer_value(partnerId), json_string_value(storeId), json_string_value(stationId)) == 1)
//{
// initflag = 1;
//}
time_t tt = time(NULL);
tm *t = localtime(&tt);
......@@ -1128,9 +1128,9 @@ int CheckCret()
/******************************************
*GetCret :从签名服务获取************/
//extern "C"
//{
int GetRSACret(int partnerId,const char *storeID,const char *posNo)
extern "C"
{
int _stdcall GetRSACret(int partnerId,const char *storeID,const char *posNo)
{
if(storeID == NULL || posNo == NULL || strlen(storeID) == 0 || strlen(posNo) == 0)
{
......@@ -1194,10 +1194,12 @@ int CheckCret()
return 0;
}
initflag = 1;
return 1;
}
//}
}
#ifdef FM_TEST
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment