uncensored

package
v3.14.0-beta Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2022 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Overview

Package uncensored contains code used by Jafar to evade its own censorship efforts by taking alternate routes.

Index

Constants

This section is empty.

Variables

View Source
var DefaultClient = Must(NewClient(""))

DefaultClient is the default client for DNS, HTTP, and TCP.

Functions

This section is empty.

Types

type Client

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

Client is DNS, HTTP, and TCP client.

func Must

func Must(client *Client, err error) *Client

Must panics if it's not possible to create a Client. Usually you should use it like `uncensored.Must(uncensored.NewClient(URL))`.

func NewClient

func NewClient(resolverURL string) (*Client, error)

NewClient creates a new Client.

func (*Client) Address

func (c *Client) Address() string

Address implements Resolver.Address

func (*Client) CloseIdleConnections

func (c *Client) CloseIdleConnections()

CloseIdleConnections implement HTTPRoundTripper.CloseIdleConnections

func (*Client) DialContext

func (c *Client) DialContext(ctx context.Context, network, address string) (net.Conn, error)

DialContext implements Dialer.DialContext

func (*Client) LookupHTTPS added in v3.14.0

func (c *Client) LookupHTTPS(ctx context.Context, domain string) (*model.HTTPSSvc, error)

LookupHTTPS implements model.Resolver.LookupHTTPS.

func (*Client) LookupHost

func (c *Client) LookupHost(ctx context.Context, domain string) ([]string, error)

LookupHost implements Resolver.LookupHost

func (*Client) Network

func (c *Client) Network() string

Network implements Resolver.Network

func (*Client) RoundTrip

func (c *Client) RoundTrip(req *http.Request) (*http.Response, error)

RoundTrip implement HTTPRoundTripper.RoundTrip

Jump to

Keyboard shortcuts

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