vpn

package
v6.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 26, 2024 License: MPL-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// IPSecTunnelDiffieHellmanGroups is a list of supported Diffie-Hellman groups
	IPSecTunnelDiffieHellmanGroups = []string{"15-MODP3072", "16-MODP4096", "19-ECP256", "20-ECP384", "21-ECP521", "28-ECP256BP", "29-ECP384BP", "30-ECP512BP"}

	// IPSecTunnelEncryptionAlgorithms is a list of supported encryption algorithms
	IPSecTunnelEncryptionAlgorithms = []string{
		"AES128", "AES256", "AES128-CTR", "AES256-CTR", "AES128-GCM-16", "AES256-GCM-16", "AES128-GCM-12", "AES256-GCM-12", "AES128-CCM-12", "AES256-CCM-12",
	}

	// IPSecTunnelIntegrityAlgorithms is a list of supported integrity algorithms
	IPSecTunnelIntegrityAlgorithms = []string{"SHA256", "SHA384", "SHA512", "AES-XCBC"}
)
View Source
var (
	// AvailableLocations is a list of supported locations for VPN
	AvailableLocations = []string{"de/fra", "de/txl"}
)

Functions

func SetIPSecGatewayData

func SetIPSecGatewayData(d *schema.ResourceData, gateway vpn.IPSecGatewayRead) error

SetIPSecGatewayData sets the VPN IPSec Gateway data to the Terraform schema

func SetIPSecTunnelData

func SetIPSecTunnelData(d *schema.ResourceData, tunnel vpn.IPSecTunnelRead) error

SetIPSecTunnelData sets the VPN IPSec Tunnel data to the terraform schema

func SetWireguardGWData

func SetWireguardGWData(d *schema.ResourceData, wireguard vpnSdk.WireguardGatewayRead) error

SetWireguardGWData sets the wireguard gateway data

func SetWireguardPeerData

func SetWireguardPeerData(d *schema.ResourceData, wireguard vpn.WireguardPeerRead) error

SetWireguardPeerData sets the wireguard peer data

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client is a wrapper for the VPN SDK client

func NewClient

func NewClient(username, password, token, url, terraformVersion string) *Client

NewClient returns a new ionoscloud logging client

func (*Client) CreateIPSecGateway

func (c *Client) CreateIPSecGateway(ctx context.Context, d *schema.ResourceData) (vpn.IPSecGatewayRead, *shared.APIResponse, error)

CreateIPSecGateway creates a new VPN IPSec Gateway

func (*Client) CreateIPSecTunnel

func (c *Client) CreateIPSecTunnel(ctx context.Context, d *schema.ResourceData) (vpn.IPSecTunnelRead, *shared.APIResponse, error)

CreateIPSecTunnel creates a new VPN IPSec Tunnel

func (*Client) CreateWireguardGateway

CreateWireguardGateway creates a new wireguard gateway

func (*Client) CreateWireguardGatewayPeers

func (c *Client) CreateWireguardGatewayPeers(ctx context.Context, d *schema.ResourceData, gatewayID string) (vpn.WireguardPeerRead, utils.ApiResponseInfo, error)

CreateWireguardGatewayPeers creates a new wireguard peer

func (*Client) DeleteIPSecGateway

func (c *Client) DeleteIPSecGateway(ctx context.Context, id string, location string) (utils.ApiResponseInfo, error)

DeleteIPSecGateway deletes a VPN IPSec Gateway by its ID and location

func (*Client) DeleteIPSecTunnel

func (c *Client) DeleteIPSecTunnel(ctx context.Context, id string, gatewayID string, location string) (utils.ApiResponseInfo, error)

DeleteIPSecTunnel deletes a VPN IPSec Tunnel using its ID and location

func (*Client) DeleteWireguardGateway

func (c *Client) DeleteWireguardGateway(ctx context.Context, id, location string) (utils.ApiResponseInfo, error)

DeleteWireguardGateway deletes a wireguard gateway

func (*Client) DeleteWireguardPeer

func (c *Client) DeleteWireguardPeer(ctx context.Context, gatewayID, id, location string) (utils.ApiResponseInfo, error)

DeleteWireguardPeer deletes a wireguard peer

func (*Client) GetIPSecGatewayByID

func (c *Client) GetIPSecGatewayByID(ctx context.Context, id string, location string) (vpn.IPSecGatewayRead, *shared.APIResponse, error)

GetIPSecGatewayByID retrieves a VPN IPSec Gateway by its ID and location

func (*Client) GetIPSecTunnelByID

func (c *Client) GetIPSecTunnelByID(ctx context.Context, id string, gatewayID string, location string) (vpn.IPSecTunnelRead, *shared.APIResponse, error)

GetIPSecTunnelByID retrieves a VPN IPSec Tunnel by its ID and location

func (*Client) GetWireguardGatewayByID

func (c *Client) GetWireguardGatewayByID(ctx context.Context, id, location string) (vpnSdk.WireguardGatewayRead, *shared.APIResponse, error)

GetWireguardGatewayByID returns a wireguard by its ID

func (*Client) GetWireguardPeerByID

func (c *Client) GetWireguardPeerByID(ctx context.Context, gatewayID, id, location string) (vpn.WireguardPeerRead, *shared.APIResponse, error)

GetWireguardPeerByID returns a wireguard by its ID

func (*Client) IsIPSecGatewayDeleted

func (c *Client) IsIPSecGatewayDeleted(ctx context.Context, d *schema.ResourceData) (bool, error)

IsIPSecGatewayDeleted checks if a VPN IPSec Gateway has been deleted

func (*Client) IsIPSecGatewayReady

func (c *Client) IsIPSecGatewayReady(ctx context.Context, d *schema.ResourceData) (bool, error)

IsIPSecGatewayReady checks if a VPN IPSec Gateway is ready to use

func (*Client) IsIPSecTunnelDeleted

func (c *Client) IsIPSecTunnelDeleted(ctx context.Context, d *schema.ResourceData) (bool, error)

IsIPSecTunnelDeleted checks if a VPN IPSec Tunnel has been deleted

func (*Client) IsIPSecTunnelReady

func (c *Client) IsIPSecTunnelReady(ctx context.Context, d *schema.ResourceData) (bool, error)

IsIPSecTunnelReady checks if a VPN IPSec Tunnel is ready to use

func (*Client) IsWireguardAvailable

func (c *Client) IsWireguardAvailable(ctx context.Context, d *schema.ResourceData) (bool, error)

IsWireguardAvailable checks if the wireguard is available

func (*Client) IsWireguardGatewayDeleted

func (c *Client) IsWireguardGatewayDeleted(ctx context.Context, d *schema.ResourceData) (bool, error)

IsWireguardGatewayDeleted checks if the wireguard gateway is deleted

func (*Client) IsWireguardGatewayReady

func (c *Client) IsWireguardGatewayReady(ctx context.Context, d *schema.ResourceData) (bool, error)

IsWireguardGatewayReady checks if the wireguard gateway is ready

func (*Client) IsWireguardPeerAvailable

func (c *Client) IsWireguardPeerAvailable(ctx context.Context, d *schema.ResourceData) (bool, error)

IsWireguardPeerAvailable checks if the wireguard peer is available

func (*Client) IsWireguardPeerDeleted

func (c *Client) IsWireguardPeerDeleted(ctx context.Context, d *schema.ResourceData) (bool, error)

IsWireguardPeerDeleted checks if the wireguard peer is deleted

func (*Client) IsWireguardPeerReady

func (c *Client) IsWireguardPeerReady(ctx context.Context, d *schema.ResourceData) (bool, error)

IsWireguardPeerReady checks if the wireguard peer is ready

func (*Client) ListIPSecGateway

func (c *Client) ListIPSecGateway(ctx context.Context, location string) (vpn.IPSecGatewayReadList, *shared.APIResponse, error)

ListIPSecGateway retrieves all VPN IPSec Gateways from a given location

func (*Client) ListIPSecTunnel

func (c *Client) ListIPSecTunnel(ctx context.Context, gatewayID string, location string) (vpn.IPSecTunnelReadList, *shared.APIResponse, error)

ListIPSecTunnel retrieves all VPN IPSec Tunnels from a given gateway and location

func (*Client) ListWireguardGateways

func (c *Client) ListWireguardGateways(ctx context.Context, location string) (vpnSdk.WireguardGatewayReadList, *shared.APIResponse, error)

ListWireguardGateways returns a list of all wireguards

func (*Client) ListWireguardPeers

func (c *Client) ListWireguardPeers(ctx context.Context, gatewayID, location string) (vpn.WireguardPeerReadList, *shared.APIResponse, error)

ListWireguardPeers returns a list of all wireguards

func (*Client) UpdateIPSecGateway

func (c *Client) UpdateIPSecGateway(ctx context.Context, d *schema.ResourceData) (vpn.IPSecGatewayRead, *shared.APIResponse, error)

UpdateIPSecGateway updates a VPN IPSec Gateway

func (*Client) UpdateIPSecTunnel

func (c *Client) UpdateIPSecTunnel(ctx context.Context, d *schema.ResourceData) (vpn.IPSecTunnelRead, *shared.APIResponse, error)

UpdateIPSecTunnel updates a VPN IPSec Tunnel

func (*Client) UpdateWireguardGateway

UpdateWireguardGateway updates a wireguard gateway

func (*Client) UpdateWireguardPeer

func (c *Client) UpdateWireguardPeer(ctx context.Context, gatewayID, id string, d *schema.ResourceData) (vpn.WireguardPeerRead, utils.ApiResponseInfo, error)

UpdateWireguardPeer updates a wireguard peer

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL