Skip to content

Multi-user signing #65

@makew0rld

Description

@makew0rld

It would be useful for AA to support multiple signers within one database. On a schema level this is possible, but the API doesn't support it.

Library changes

  • Add keystore functionality, storing signing keys per database ID
    • Can be key pairs or just public keys (for syncing a third-party database)
    • Should keys have names?
  • Remove setSigningKey
  • Change validating functions like dbGet to support the keystore
  • Change writing functions like dbPut to use the keystore
  • Change demo files, update lib docs, examples

HTTP API

  • No changes, except the JWT is examined and the appropriate key is used
  • Old JWTs with no key indicator are not accepted instead of using a default key

Rationale

The idea behind this setup is to keep the keys with the server. Overall this would be a major breaking change on the library side, but shouldn't require changes for any HTTP API users, other than updating their JWT.

Pros

  • Secret keys are kept safe
  • Clients don't have to:
    • Sign data themselves (complex), or
    • Send private keys to the server (insecure)

Cons

  • Less client agency since they don't hold their own keys (do we care about this?)

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions