Documentation
¶
Index ¶
- Constants
- func MarshalUpdateManifestV2(manifest UpdateManifestV2) ([]byte, error)
- func SHA256(data []byte) string
- func UpdateArchiveName(version, goos, goarch string) string
- func ValidateCask(data []byte, expected CaskExpectation) error
- func ValidateUpdateManifestV2(manifest UpdateManifestV2) error
- func VerifySignedUpdateManifest(manifestRaw, bundleRaw []byte) error
- type CaskExpectation
- type UpdateAssetV2
- type UpdateManifestV2
Constants ¶
View Source
const ( OSSBaseURL = "https://ros-public-tools.oss-cn-beijing.aliyuncs.com/github-releases/aliyun/elastic-compute-control-cli" Homepage = "https://github.com/aliyun/elastic-compute-control-cli" Description = "Agent-first command-line controller for Alibaba Cloud elastic computing resources" )
View Source
const ( UpdateManifestV2Schema = "ecctl-update-manifest-v2" UpdateManifestV2Name = "ecctl-update-manifest-v2.json" UpdateManifestV2BundleName = "ecctl-update-manifest-v2.sigstore.json" )
Variables ¶
This section is empty.
Functions ¶
func MarshalUpdateManifestV2 ¶ added in v0.2.2
func MarshalUpdateManifestV2(manifest UpdateManifestV2) ([]byte, error)
func UpdateArchiveName ¶ added in v0.2.2
func ValidateCask ¶
func ValidateCask(data []byte, expected CaskExpectation) error
ValidateCask validates data without evaluating Ruby. The accepted program is deliberately limited to the Cask emitted for ecctl by GoReleaser.
func ValidateUpdateManifestV2 ¶ added in v0.2.2
func ValidateUpdateManifestV2(manifest UpdateManifestV2) error
func VerifySignedUpdateManifest ¶ added in v0.2.2
VerifySignedUpdateManifest exercises the production offline trust policy and then validates the signed manifest protocol. Signature verification must happen before parsing fields from the untrusted manifest.
Types ¶
type CaskExpectation ¶
type UpdateAssetV2 ¶ added in v0.2.2
type UpdateManifestV2 ¶ added in v0.2.2
type UpdateManifestV2 struct {
Schema string `json:"schema"`
Version string `json:"version"`
Prerelease bool `json:"prerelease"`
Assets []UpdateAssetV2 `json:"assets"`
}
func BuildUpdateManifestV2 ¶ added in v0.2.2
func BuildUpdateManifestV2(version, distDir, versionPath, caskPath string) (UpdateManifestV2, error)
func ParseUpdateManifestV2 ¶ added in v0.2.2
func ParseUpdateManifestV2(raw []byte) (UpdateManifestV2, error)
Click to show internal directories.
Click to hide internal directories.