PcapPlusPlus
Next
|
#include <X509Decoder.h>
Public Member Functions | |
X509Timestamp (Asn1TimeRecord *timeRecord) | |
std::string | toString (const std::string &format="%Y-%m-%d %H:%M:%S", const std::string &timezone="Z", bool includeMilliseconds=false) const |
std::chrono::system_clock::time_point | getTimestamp (const std::string &timezone="Z") const |
Represents a timestamp in an X.509 certificate
|
inlineexplicit |
Constructs an X509Timestamp from an ASN.1 time record
[in] | timeRecord | Pointer to the ASN.1 time record. Note: this class doesn't assume ownership over the record |
std::chrono::system_clock::time_point pcpp::X509Timestamp::getTimestamp | ( | const std::string & | timezone = "Z" | ) | const |
Gets the timestamp as a system_clock::time_point
[in] | timezone | The timezone to use in the format of "Z" for UTC or +=HHMM for other timezones (default: "Z" for UTC) |
std::string pcpp::X509Timestamp::toString | ( | const std::string & | format = "%Y-%m-%d %H:%M:%S" , |
const std::string & | timezone = "Z" , |
||
bool | includeMilliseconds = false |
||
) | const |
Converts the timestamp to a formatted string
[in] | format | The format string (strftime format, default: "%Y-%m-%d %H:%M:%S") |
[in] | timezone | The timezone to use in the format of "Z" for UTC or +=HHMM for other timezones (default: "Z" for UTC) |
[in] | includeMilliseconds | Whether to include milliseconds in the output |