Skip to content

Commit 34afb8d

Browse files
committed
modify:try verification add type reply
1 parent 5616c86 commit 34afb8d

File tree

4 files changed

+22
-5
lines changed

4 files changed

+22
-5
lines changed

XEngine_Module/XEngine_Verification/Verification_Define.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -763,12 +763,17 @@ extern "C" bool Verification_XAuthKey_ReadMemory(LPCXSTR lpszMsgBuffer, int nMsg
763763
类型:常量字符指针
764764
可空:Y
765765
意思:输入密码,如果服务端设置了密码客户端也必须使用加密通信
766+
参数.三:pInt_Type
767+
In/Out:Out
768+
类型:整数型指针
769+
可空:Y
770+
意思:输出验证类型
766771
返回值
767772
类型:逻辑型
768773
意思:是否成功
769774
备注:
770775
*********************************************************************/
771-
extern "C" bool Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass = NULL);
776+
extern "C" bool Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass = NULL, int* pInt_Type = NULL);
772777
/********************************************************************
773778
函数名称:Verification_XAuthNet_GetDCode
774779
函数功能:获取动态码

XEngine_Module/XEngine_Verification/Verification_XAuth/Verification_XAuthNet.cpp

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,17 @@ CVerification_XAuthNet::~CVerification_XAuthNet()
3333
类型:常量字符指针
3434
可空:Y
3535
意思:输入密码,如果服务端设置了密码客户端也必须使用加密通信
36+
参数.三:pInt_Type
37+
In/Out:Out
38+
类型:整数型指针
39+
可空:Y
40+
意思:输出验证类型
3641
返回值
3742
类型:逻辑型
3843
意思:是否成功
3944
备注:
4045
*********************************************************************/
41-
bool CVerification_XAuthNet::Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass /* = NULL */)
46+
bool CVerification_XAuthNet::Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass /* = NULL */, int* pInt_Type /* = NULL */)
4247
{
4348
Verification_IsErrorOccur = true;
4449

@@ -120,6 +125,13 @@ bool CVerification_XAuthNet::Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAdd
120125
BaseLib_Memory_FreeCStyle((XPPMEM)&ptszMsgBuffer);
121126
return false;
122127
}
128+
if (NULL != pInt_Type)
129+
{
130+
if (!st_JsonRoot["type"].isNull())
131+
{
132+
*pInt_Type = st_JsonRoot["type"].asInt();
133+
}
134+
}
123135
BaseLib_Memory_FreeCStyle((XPPMEM)&ptszMsgBuffer);
124136
return true;
125137
}

XEngine_Module/XEngine_Verification/Verification_XAuth/Verification_XAuthNet.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class CVerification_XAuthNet
2323
CVerification_XAuthNet();
2424
~CVerification_XAuthNet();
2525
public:
26-
bool Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass = NULL);
26+
bool Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass = NULL, int* pInt_Type = NULL);
2727
bool Verification_XAuthNet_GetDCode(LPCXSTR lpszURLAddr, int* pInt_DYCode, XNETHANDLE* pxhToken, int* pInt_Timeout = NULL, LPCXSTR lpszPass = NULL);
2828
public:
2929
bool Verification_XAuthNet_Connect(LPCXSTR lpszClientAddr, int nPort, LPCXSTR lpszPass = NULL);

XEngine_Module/XEngine_Verification/pch.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,9 +137,9 @@ extern "C" bool Verification_XAuthKey_ReadMemory(LPCXSTR lpszMsgBuffer, int nMsg
137137
{
138138
return m_XAuthKeyVerification.Verification_XAuthKey_ReadMemory(lpszMsgBuffer, nMsgLen, pSt_AuthLocal);
139139
}
140-
extern "C" bool Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass)
140+
extern "C" bool Verification_XAuthNet_TryRequest(LPCXSTR lpszURLAddr, LPCXSTR lpszPass, int* pInt_Type)
141141
{
142-
return m_XAuthNetVerification.Verification_XAuthNet_TryRequest(lpszURLAddr, lpszPass);
142+
return m_XAuthNetVerification.Verification_XAuthNet_TryRequest(lpszURLAddr, lpszPass, pInt_Type);
143143
}
144144
extern "C" bool Verification_XAuthNet_GetDCode(LPCXSTR lpszURLAddr, int* pInt_DYCode, XNETHANDLE* pxhToken, int* pInt_Timeout, LPCXSTR lpszPass)
145145
{

0 commit comments

Comments
 (0)