httpstorage

package
v0.0.0-...-f19ae85 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2015 License: AGPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Client

func Client(addr string) storage.Storage

Client returns a storage object that will talk to the storage server at the given network address (see Serve)

func ClientTLS

func ClientTLS(addr string, caCertPEM string, authkey string) (storage.Storage, error)

ClientTLS returns a storage object that will talk to the storage server at the given network address (see Serve), using TLS. The client is given an authentication key, which the server will verify for Put and Remove* operations.

func Serve

func Serve(addr string, stor storage.Storage) (net.Listener, error)

Serve runs a storage server on the given network address, relaying requests to the given storage implementation. It returns the network listener. This can then be attached to with Client.

func ServeTLS

func ServeTLS(addr string, stor storage.Storage, caCertPEM, caKeyPEM string, hostnames []string, authkey string) (net.Listener, error)

ServeTLS runs a storage server on the given network address, relaying requests to the given storage implementation. The server runs a TLS listener, and verifies client certificates (if given) against the specified CA certificate. A client certificate is only required for PUT and DELETE methods.

This method returns the network listener, which can then be attached to with ClientTLS.

Types

This section is empty.

Jump to

Keyboard shortcuts

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