Documentation ¶ Overview ¶ Package plugintrust persists approvals for Lua plugin content. Index ¶ Variables func Approve(dir, name, path string) (string, error) func HashFile(path string) (string, error) func Save(dir string, m Manifest) error func Verify(m Manifest, name, path string) error type Manifest func Load(dir string) (Manifest, error) Constants ¶ This section is empty. Variables ¶ View Source var ( ErrUntrusted = errors.New("plugin is not trusted") ErrHashMismatch = errors.New("plugin content changed since approval") ) Functions ¶ func Approve ¶ func Approve(dir, name, path string) (string, error) func HashFile ¶ func HashFile(path string) (string, error) func Save ¶ func Save(dir string, m Manifest) error func Verify ¶ func Verify(m Manifest, name, path string) error Types ¶ type Manifest ¶ type Manifest struct { Version int `json:"version"` Plugins map[string]string `json:"plugins"` } func Load ¶ func Load(dir string) (Manifest, error) Source Files ¶ View all Source files trust.go Click to show internal directories. Click to hide internal directories.