artifact

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: May 27, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const DownloadTimeout = 5 * time.Minute

Variables

This section is empty.

Functions

func NewHasher

func NewHasher(algorithm string) (hash.Hash, error)

func VerifyHashFromDigest

func VerifyHashFromDigest(digest []byte, expectedHash, algorithm string) error

Types

type ExtractionResult

type ExtractionResult struct {
	Files       map[string]string
	Verified    bool
	VerifyError *string
}

func StreamExtractAndVerify

func StreamExtractAndVerify(ctx context.Context, dist *models.DistributionInfo, filename, ecosystem string) (*ExtractionResult, error)

type StreamResult

type StreamResult struct {
	Body        io.ReadCloser
	ContentType string
}

func StreamDownload

func StreamDownload(ctx context.Context, url string) (*StreamResult, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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