parallaxsecond / parsec

Platform AbstRaction for SECurity service
https://parsec.community/
Apache License 2.0
467 stars 67 forks source link

Design OnDisk->SQLite KIM migration script. #518

Open MattDavis00 opened 3 years ago

MattDavis00 commented 3 years ago

Design the OnDisk->SQLite KIM migration script.

This script could have a config file for setting required fields such as the authenticator_id & provider_name. provider_uuid, key_name & application_name can be inferred from the values held within the OnDisk KIM.

Design considerations:

# Generic rules to handle non-duplicate cases.
[config]
  authenticator_type = "UnixPeerCredentials"

##############################################################

# Explicit mapping to handle duplicate cases.
[[key_mapping]]

  # The old key_triple identifier information.
  [key_mapping.old]
    application_name = "1523"
    provider_type = "MbedCrypto"
    key_name = "My Key 🔑"

  # What this should be mapped to.
  [key_mapping.new]
    key_name = "My MbedCrypto Key 🔑"
    [key_mapping.new.application_identity]
      authenticator_type = "UnixPeerCredentials" # Could accept either authenticator_id (int) or authenticator_type (AuthType).
      application_name = "1523"
    [key_mapping.new.provider_identity]
      provider_uuid = "1c1139dc-ad7c-47dc-ad6b-db6fdb466552" # Could accept either provider_uuid (str) or provider_type (ProviderId).
      provider_name = "mbed-crypto-provider-3"

Figure. 1

paulhowardarm commented 2 years ago

We probably want to ask some more "existential" questions before diving into lots of detail here, for example: