dialer

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package dialer provides a grpc dialer that can be used to create grpc client connections with different levels of ATLS encryption / verification.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dialer

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

Dialer can open grpc client connections with different levels of ATLS encryption / verification.

func New

func New(issuer atls.Issuer, validator atls.Validator, netDialer NetDialer) *Dialer

New creates a new Dialer.

func (*Dialer) Dial

func (d *Dialer) Dial(target string) (*grpc.ClientConn, error)

Dial creates a new grpc client connection to the given target using the atls validator.

func (*Dialer) DialInsecure

func (d *Dialer) DialInsecure(target string) (*grpc.ClientConn, error)

DialInsecure creates a new grpc client connection to the given target without using encryption or verification. Only use this method when using another kind of encryption / verification (VPN, etc).

func (*Dialer) DialNoVerify

func (d *Dialer) DialNoVerify(target string) (*grpc.ClientConn, error)

DialNoVerify creates a new grpc client connection to the given target without verifying the server's attestation.

type NetDialer

type NetDialer interface {
	DialContext(ctx context.Context, network, address string) (net.Conn, error)
}

NetDialer implements the net Dialer interface.

Jump to

Keyboard shortcuts

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