---
title: llarp::vpn

---

# llarp::vpn



## Classes

|                | Name           |
| -------------- | -------------- |
| struct | **[llarp::vpn::InterfaceAddress](Classes/structllarp_1_1vpn_1_1InterfaceAddress.md)**  |
| struct | **[llarp::vpn::InterfaceInfo](Classes/structllarp_1_1vpn_1_1InterfaceInfo.md)**  |
| class | **[llarp::vpn::NetworkInterface](Classes/classllarp_1_1vpn_1_1NetworkInterface.md)** <br>a vpn network interface  |
| class | **[llarp::vpn::IRouteManager](Classes/classllarp_1_1vpn_1_1IRouteManager.md)**  |
| class | **[llarp::vpn::Platform](Classes/classllarp_1_1vpn_1_1Platform.md)** <br>a vpn platform responsible for obtaining vpn interfaces  |
| class | **[llarp::vpn::AndroidInterface](Classes/classllarp_1_1vpn_1_1AndroidInterface.md)**  |
| class | **[llarp::vpn::AndroidRouteManager](Classes/classllarp_1_1vpn_1_1AndroidRouteManager.md)**  |
| class | **[llarp::vpn::AndroidPlatform](Classes/classllarp_1_1vpn_1_1AndroidPlatform.md)**  |
| class | **[llarp::vpn::permission_error](Classes/classllarp_1_1vpn_1_1permission__error.md)**  |
| struct | **[llarp::vpn::IOCTL](Classes/structllarp_1_1vpn_1_1IOCTL.md)**  |
| struct | **[llarp::vpn::EgresLayer4Handler](Classes/structllarp_1_1vpn_1_1EgresLayer4Handler.md)**  |
| class | **[llarp::vpn::EgresPacketRouter](Classes/classllarp_1_1vpn_1_1EgresPacketRouter.md)**  |
| struct | **[llarp::vpn::in6_ifreq](Classes/structllarp_1_1vpn_1_1in6__ifreq.md)**  |
| class | **[llarp::vpn::LinuxInterface](Classes/classllarp_1_1vpn_1_1LinuxInterface.md)**  |
| class | **[llarp::vpn::LinuxRouteManager](Classes/classllarp_1_1vpn_1_1LinuxRouteManager.md)**  |
| class | **[llarp::vpn::LinuxPlatform](Classes/classllarp_1_1vpn_1_1LinuxPlatform.md)**  |
| struct | **[llarp::vpn::Layer4Handler](Classes/structllarp_1_1vpn_1_1Layer4Handler.md)**  |
| class | **[llarp::vpn::PacketRouter](Classes/classllarp_1_1vpn_1_1PacketRouter.md)**  |
| class | **[llarp::vpn::Win32Interface](Classes/classllarp_1_1vpn_1_1Win32Interface.md)**  |
| class | **[llarp::vpn::Win32RouteManager](Classes/classllarp_1_1vpn_1_1Win32RouteManager.md)**  |
| class | **[llarp::vpn::Win32Platform](Classes/classllarp_1_1vpn_1_1Win32Platform.md)**  |

## Types

|                | Name           |
| -------------- | -------------- |
| using llarp::EndpointBase::AddressVariant_t | **[AddressVariant_t](Namespaces/namespacellarp_1_1vpn.md#using-addressvariant-t)**  |
| using std::function< void(AddressVariant_t, [net::IPPacket](Classes/structllarp_1_1net_1_1IPPacket.md))> | **[EgresPacketHandlerFunc](Namespaces/namespacellarp_1_1vpn.md#using-egrespackethandlerfunc)**  |
| using std::function< void([llarp::net::IPPacket](Classes/structllarp_1_1net_1_1IPPacket.md))> | **[PacketHandlerFunc](Namespaces/namespacellarp_1_1vpn.md#using-packethandlerfunc)**  |

## Functions

|                | Name           |
| -------------- | -------------- |
| std::shared_ptr< [Platform](Classes/classllarp_1_1vpn_1_1Platform.md) > | **[MakeNativePlatform](Namespaces/namespacellarp_1_1vpn.md#function-makenativeplatform)**(llarp::Context * ctx)<br>create native vpn platform  |
| char * | **[reg_query](Namespaces/namespacellarp_1_1vpn.md#function-reg-query)**(char * key_name) |
| template <typename Visit \> <br>void | **[ForEachWIN32Interface](Namespaces/namespacellarp_1_1vpn.md#function-foreachwin32interface)**(Visit visit) |
| std::optional< int > | **[GetInterfaceIndex](Namespaces/namespacellarp_1_1vpn.md#function-getinterfaceindex)**([huint32_t](Classes/structllarp_1_1huint__t.md) ip) |

## Types Documentation

### using AddressVariant_t

```cpp
using llarp::vpn::AddressVariant_t = typedef llarp::EndpointBase::AddressVariant_t;
```


### using EgresPacketHandlerFunc

```cpp
using llarp::vpn::EgresPacketHandlerFunc = typedef std::function<void(AddressVariant_t, net::IPPacket)>;
```


### using PacketHandlerFunc

```cpp
using llarp::vpn::PacketHandlerFunc = typedef std::function<void(llarp::net::IPPacket)>;
```



## Functions Documentation

### function MakeNativePlatform

```cpp
std::shared_ptr< Platform > MakeNativePlatform(
    llarp::Context * ctx
)
```

create native vpn platform 

### function reg_query

```cpp
static char * reg_query(
    char * key_name
)
```


### function ForEachWIN32Interface

```cpp
template <typename Visit >
void ForEachWIN32Interface(
    Visit visit
)
```


### function GetInterfaceIndex

```cpp
std::optional< int > GetInterfaceIndex(
    huint32_t ip
)
```






-------------------------------

Updated on 2022-08-30 at 18:09:28 +0000