21 #include "core/auth/User_odb.h" 47 auto now = boost::posix_time::second_clock::local_time();
UserPtr owner_
The user owning the token.
This is the header file for a generated source file, GitSHA1.cpp.
UserPtr owner() const
Retrieve a shared_ptr to the user owning the token.
const std::string & id() const
Return the token identifier.
boost::posix_time::ptime expiration() const
Retrieve the unix timestamp at which the token will/has expire(d).
Holds classes relevant to the Authentication and Authorization subsystem.
bool is_valid() const
Check if the token is still active.
void expire_in(const T &duration)
Set the expiration point of the token to be now + duration.
boost::posix_time::ptime expiration_
std::shared_ptr< User > UserPtr
std::string token_
The string representation of the token.
const std::string & token() const
Retrieve the string representation of the token.