Documentation ¶
Index ¶
- Variables
- func GenerateChecksum(sourcePack, destinationDir, hashFunction string) error
- func GenerateSignedChecksum(packPath, keyPath, destinationDir, passphrase string, base64 bool) error
- func GetDigestList(sourcePack, hashFunction string) (map[string]string, error)
- func VerifyChecksum(packPath, checksumPath string) error
- func VerifySignature(checksumPath, keyPath, signaturePath, passphrase string) error
- func WriteChecksumFile(digests map[string]string, filename string) error
Constants ¶
This section is empty.
Variables ¶
View Source
var Hashes = [1]string{"sha256"}
Hashes is the list of supported Cryptographic Hash Functions used for the checksum feature
Functions ¶
func GenerateChecksum ¶
GenerateChecksum creates a .checksum file for a pack.
func GenerateSignedChecksum ¶ added in v0.8.0
func GenerateSignedChecksum(packPath, keyPath, destinationDir, passphrase string, base64 bool) error
GenerateSignature creates a .signature file based on a pack
func GetDigestList ¶ added in v0.8.0
GetDigestList computes the digests of a pack according to the specified hash function.
func VerifyChecksum ¶
VerifyChecksum validates the contents of a pack according to a provided .checksum file.
func VerifySignature ¶ added in v0.8.0
VerifyChecksum validates a signed .checksum. Currently for demo purposes it validates the checksum file against its detached .signature and only accepts a private key, preferably created through "cpackget signature-create"
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.