Skip to content

ACL integration into the CLI #207

@CMCDragonkai

Description

@CMCDragonkai

Specification

  • The ACL stores permissions for gestalts and actions
  • The CLI should expose the ACL permissions/actions to the pk identities for gestalts and pk vaults for vaults
  • This means being able to set permissions and to show/introspect the permissions available
  • The permissions are structured as sets of actions
    • Gestalts:
      • notify
      • scan
    • Vaults:
      • pull
      • clone
  • Users must be able to set a permission idempotently, and to unset a permission idempotently
  • Setting and unsetting of permissions to should map to semantic subcommands
  • Or the setting and unsetting of permissions can be its own acl-specific subcommands

Actions

The actions we may want to take are:

  • set, Set a specific permission, EG notify, scan.
  • del, delete permissions.
  • get, get the permission that is set,
  • list, List all that have permissions, maybe list specific permissions too?

Command domain.

We can add the commands to the vaults and identities domains. the commands in this case will take the form of.
PK gestalts trust set <ID> <permission>or
PK gestalts trust --action set --ID <ID> --permmission <permission>.

However we can make a new command domain just for trust and have a subcommand for each action.
PK trust setGestalt --ID <ID> --permission <permission>
PK trust listGestalt --ID <ID> --permission <permission>

Tasks

  1. Determine if we want to create a trust command domain or add trust commands to vaults and identities.
  2. create GRPC commands.
    • identities
      • getGestaltActionsByNode
      • getGestaltActionsByIdentity
      • setGestaltActionByNode
      • setGestaltActionByIdentity
      • unsetGestaltActionByNode
      • unsetGestaltActionByIdentity
    • vaults
      • vaultsShare
      • vaultsPermissions
  3. create CLI commands.
    • (subject to change based on decision)
      • pk identities trust: handles set, delete, get
      • pk identities allow: fine grain permissions, set, delete, get
      • pk identities list: list gestalts + permissions.
  4. tests
    • grpc
      • getGestaltActionsByNode
      • getGestaltActionsByIdentity
      • setGestaltActionByNode
      • setGestaltActionByIdentity
      • unsetGestaltActionByNode
      • unsetGestaltActionByIdentity
      • vaultsShare
      • vaultsPermissions
    • CLI
      • pk identities trust
      • pk identities allow
      • pk identities list
      • vaults share (set, unset)
      • vaults Permissions (get)

notes:

  • pk identities list-trust: list permissions. Might be part of identities list. We'd have to list complete gestalts to have a complete picture anyway.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions