mirror of
https://github.com/Telecominfraproject/wlan-cloud-ucentralsec.git
synced 2025-11-01 19:27:59 +00:00
Fixing token revocatiopn/
This commit is contained in:
@@ -47,9 +47,11 @@ namespace OpenWifi {
|
|||||||
|
|
||||||
Poco::Data::Session Sess = Pool_->get();
|
Poco::Data::Session Sess = Pool_->get();
|
||||||
Poco::Data::Statement Select(Sess);
|
Poco::Data::Statement Select(Sess);
|
||||||
|
std::cout << __func__ << " : " << __LINE__ << std::endl;
|
||||||
RevocationDate = 0 ;
|
RevocationDate = 0 ;
|
||||||
|
std::cout << __func__ << " : " << __LINE__ << std::endl;
|
||||||
std::string St2{"SELECT " + AllTokensValuesForSelect + " From Tokens WHERE Token=?"};
|
std::string St2{"SELECT " + AllTokensValuesForSelect + " From Tokens WHERE Token=?"};
|
||||||
|
std::cout << __func__ << " : " << __LINE__ << std::endl;
|
||||||
Select << ConvertParams(St2),
|
Select << ConvertParams(St2),
|
||||||
Poco::Data::Keywords::into(UInfo.webtoken.access_token_),
|
Poco::Data::Keywords::into(UInfo.webtoken.access_token_),
|
||||||
Poco::Data::Keywords::into(UInfo.webtoken.refresh_token_),
|
Poco::Data::Keywords::into(UInfo.webtoken.refresh_token_),
|
||||||
@@ -60,10 +62,9 @@ namespace OpenWifi {
|
|||||||
Poco::Data::Keywords::into(UInfo.webtoken.idle_timeout_),
|
Poco::Data::Keywords::into(UInfo.webtoken.idle_timeout_),
|
||||||
Poco::Data::Keywords::into(RevocationDate),
|
Poco::Data::Keywords::into(RevocationDate),
|
||||||
Poco::Data::Keywords::use(Token);
|
Poco::Data::Keywords::use(Token);
|
||||||
|
std::cout << __func__ << " : " << __LINE__ << std::endl;
|
||||||
Select.execute();
|
Select.execute();
|
||||||
|
std::cout << __func__ << " : " << __LINE__ << " Rev:" << RevocationDate << std::endl;
|
||||||
if(RevocationDate>0)
|
|
||||||
return false;
|
|
||||||
return true;
|
return true;
|
||||||
} catch (const Poco::Exception &E) {
|
} catch (const Poco::Exception &E) {
|
||||||
Logger_.log(E);
|
Logger_.log(E);
|
||||||
|
|||||||
Reference in New Issue
Block a user