Skip to content

Add Delegate as an easy method for extending the delegation chain #36

@smoyer64

Description

@smoyer64

Given I have a UCAN delegation token with (one of?) my DID(s) in the aud field, add a Delegate method that makes it easier to continue the delegation chain. This can be accomplished but the New constructor but almost every field must then be copied by the library user.

The method signature would be something like:

func (t *Token) Delegate(privKey crypto.PrivKey, aud did.DID, opts ...DelegateOption) (*Token, error)

And DelegateOption would include the following implementations:

  • WithAttenuatedCommand
  • `WithAttenuatedPolicy
  • WithAdditionalPolicyPredicates
  • WithoutInheritedPolicy

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions