Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sbkclient
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李定达
sbkclient
Commits
e9eaf7dc
Commit
e9eaf7dc
authored
Aug 09, 2017
by
李定达
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.导出获取证书接口
parent
c7edf91b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
9 deletions
+11
-9
ZH_Client/sbk_client.cpp
+11
-9
No files found.
ZH_Client/sbk_client.cpp
View file @
e9eaf7dc
...
...
@@ -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
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment