margo / specification

Margo Specification
https://specification.margo.org/
Other
16 stars 4 forks source link

Security - Access to Private Registries #15

Open arne-broering opened 1 week ago

arne-broering commented 1 week ago

What authentication method? e.g.:

Who provides credentials?

Where / how to store credentials?

arne-broering commented 1 week ago

The following sequence represents the current state of discussion:

  1. WOA (representing the device) offers a way for the device owner to put a key pair (as first step).
  2. Public key is sent by the WOA (maybe as part of device onboarding) to the WOS.
  3. Once a desired state is requested, the WOS encrypts the secret with the public key and sends it along the desired state.
  4. WOA can then decrypt the secret, interpret the deployment spec and get the required packages from the registry.

Image

Open questions are:

arne-broering commented 1 week ago

This extended sequence diagram attempts to answer the open question (1):

image

phil-abb commented 4 days ago

I think this can get quite complicated depending on what we need (or want) to support.

I don't know that application vendors are going to want to be giving out credentials to customers.

In addition to credentials, do we also need to ensure the application is only installed by the customer who has the right to install the application? I don't think we want to get into software licensing with Margo but do we need to do something as part of Margo to ensure the application is only deployable by customers getting access to the application through approved means?

So, how complex does this need to be, and what options do we have?

I can think of several different options:

If we add on top of this the need to support air-gapped deployments then the problems just keep getting bigger.

stormc commented 3 days ago

I think this can get quite complicated depending on what we need (or want) to support.

This is the very question to answer IMO. What is the concern of Margo and what is out of scope, i.e., not the concern of Margo. There are many ― secure ― ways how to transport an application from a registry/repository down to the device and likewise many how an app developer gets the apps into such a registry/repository. Alike, there are many ways how to do licensing and license enforcement, even neglecting it altogether because of the effort-result ratio :) For any of these, you can find a technical solution to cater for them, however, IMO, this is not a pure technical but rather a business question: What would a Margo user/app developer expect improving the current situation out there?

I don't know that application vendors are going to want to be giving out credentials to customers.

With imposing this on app developers/vendors, we impose on them a particular Margo way how their process has to look like. The next question would be how to handle/advertise application updates, deprecations, ...

So, IMO, given all the different ways how to handle (a) app distribution and (b) licensing and no unifying layer in sight (to my knowledge at least), shouldn't we sidestep the problem and define+implement an interface including hooks for both concerns into which you can then hook the various ways of doing things out there in the field(s)... ?

phil-abb commented 3 hours ago

Regardless of where we end up with securing credentials for OCI registries, I think the approach above can still be applied to enable the use of secret parameters that a customer may need to enter as part of configuring their application to be deployed to the edge. For example, configuring database passwords or sensitive connection strings.