sharing

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2024 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KB = 1 << (10 * (iota + 1))
	MB
	GB
)
View Source
const ChunkSize = 1 * MB
View Source
const MaxConcurrentShare = 0

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
}

func NewService

func NewService() *Service

func (*Service) GenerateKey

func (s *Service) GenerateKey(relays []string) (string, uuid.UUID)

func (*Service) ParseKey

func (s *Service) ParseKey(key string) (relays []string, id uuid.UUID, err error)

func (*Service) Receive

func (s *Service) Receive(ctx context.Context, uid uuid.UUID, servers []string, caPath string, withTLS, skipVerify bool) (string, error)

func (*Service) Share

func (s *Service) Share(ctx context.Context, filePath string, uid uuid.UUID, relays []string, caPath string, withTLS, insecure bool) error

func (*Service) VerifyRelays

func (s *Service) VerifyRelays(ctx context.Context, relays []string, caPath string, withTLS, skipVerify bool) error

Jump to

Keyboard shortcuts

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