OpenVPN 3 Core Library
|
Class for handling gateway rerouting configuration. More...
#include <capture.hpp>
Public Member Functions | |
std::string | to_string () const |
Converts the object to a human-readable string representation. | |
Json::Value | to_json () const |
Serializes the object to a JSON value. | |
void | from_json (const Json::Value &root, const std::string &title) |
Deserializes the object from a JSON value. | |
Public Attributes | |
bool | ipv4 = false |
bool | ipv6 = false |
unsigned int | flags = 0 |
Class for handling gateway rerouting configuration.
This class encapsulates settings for redirecting gateway traffic in an OpenVPN connection, supporting both IPv4 and IPv6 protocols with configurable flags. It provides string representation and JSON serialization/deserialization capabilities (when JSON support is enabled).
Definition at line 132 of file capture.hpp.
|
inline |
Deserializes the object from a JSON value.
Populates the object's fields from a JSON object. Only available when JSON support is enabled (HAVE_JSON defined).
root | The JSON object to extract values from. |
title | A title/context string used for error reporting. |
Definition at line 177 of file capture.hpp.
|
inline |
Serializes the object to a JSON value.
Creates a JSON object containing the current IPv4, IPv6, and flags values. Only available when JSON support is enabled (HAVE_JSON defined).
Definition at line 161 of file capture.hpp.
|
inline |
Converts the object to a human-readable string representation.
Creates a string describing the current state of the object, including IPv4/IPv6 status and flags using the RedirectGatewayFlags
helper class.
Definition at line 145 of file capture.hpp.
unsigned int openvpn::TunBuilderCapture::RerouteGW::flags = 0 |
Definition at line 137 of file capture.hpp.
bool openvpn::TunBuilderCapture::RerouteGW::ipv4 = false |
Definition at line 135 of file capture.hpp.
bool openvpn::TunBuilderCapture::RerouteGW::ipv6 = false |
Definition at line 136 of file capture.hpp.