tor

package
Version: v1.2.3 Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2020 License: CC0-1.0 Imports: 8 Imported by: 0

Documentation

Overview

Package tor manages and automates starting a child tor process for exposing TCP services into onionland.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DataDir               string
	HashedControlPassword string
	ClearPassword         string
	Timeout               time.Duration
}

Config is a wrapper struct for tor configuration.

type Tor

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

Tor is a higher level wrapper to a child tor process

func StartTor

func StartTor(cfg Config) (*Tor, error)

StartTor starts a new instance of tor or doesn't with the reason why.

func (*Tor) AddOnion

func (t *Tor) AddOnion(pKey *rsa.PrivateKey, virtPort uint16, destination string) (*bulb.OnionInfo, error)

AddOnion adds an onion service to this machine with the given private key (can be nil for an auto-generated key), virtual onion port and TCP destunation.

Source Files

Jump to

Keyboard shortcuts

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