114. KeyManager

Manages GPG keys in the package manager

114.1. Summary of Module Globals

List of Global Functions

  • DeleteKey - Delete the key from the package manager

  • GetKeys - Return the current keys.

  • ImportFromFile - Import key from a file

  • Modified - Has been something changed?

  • Read - Read the current configuration from the package manager. The previous changes are lost (@see Reset). The target system of the package manager must be initialized before reading GPG keys!

  • Reset - Reset the internal state of the module. The current configuration and all changes are deleted.

  • SearchGPGKey - Search a GPG key in the known keys

  • Write - Apply the changes, update the current status

List of Global Variables

    114.2. Global Functions

    114.2.1. DeleteKey

    Delete the key from the package manager

    Function parameters

    • string key_id

    Return value

    • boolean - true on success

    114.2.2. GetKeys

    Return the current keys.

    Return value

    • list<map<string,any> > - list of known GPG keys ($[ "id" : string, "name" : string, "trusted" : boolean ])

    114.2.3. ImportFromFile

    Import key from a file

    Function parameters

    • string file

    • boolean trusted

    Return value

    • map<string,any> - map with the key, nil when import fails (invalid key, not existing file, already imported key...)

    114.2.4. Modified

    Has been something changed?

    Return value

    • boolean - true if something has been changed

    114.2.5. Read

    Read the current configuration from the package manager. The previous changes are lost (@see Reset). The target system of the package manager must be initialized before reading GPG keys!

    Return value

    • boolean - true on success

    114.2.6. Reset

    Reset the internal state of the module. The current configuration and all changes are deleted.

    Return value

    • void

    114.2.7. SearchGPGKey

    Search a GPG key in the known keys

    Function parameters

    • string key_id

    Return value

    • map<string,any> - Data about the key or nil if the key was not found

    114.2.8. Write

    Apply the changes, update the current status

    Return value

    • boolean - true on success

    114.3. Global Variables

    114.4. Module Requirements

    114.4.1. Module Imports

    • Directory
    • Report
    • String

    114.4.2. Module Includes