Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Add Passbolt Provider #3334

Merged
merged 4 commits into from Apr 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
32 changes: 32 additions & 0 deletions apis/externalsecrets/v1beta1/secretsstore_passbolt_types.go
@@ -0,0 +1,32 @@
/*
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

package v1beta1

import (
esmeta "github.com/external-secrets/external-secrets/apis/meta/v1"
)

// Passbolt contains a secretRef for the passbolt credentials.
type PassboltAuth struct {
PasswordSecretRef *esmeta.SecretKeySelector `json:"passwordSecretRef"`
PrivateKeySecretRef *esmeta.SecretKeySelector `json:"privateKeySecretRef"`
}

type PassboltProvider struct {
// Auth defines the information necessary to authenticate against Passbolt Server
Auth *PassboltAuth `json:"auth"`
// Host defines the Passbolt Server to connect to
Host string `json:"host"`
}
3 changes: 3 additions & 0 deletions apis/externalsecrets/v1beta1/secretstore_types.go
Expand Up @@ -160,6 +160,9 @@ type SecretStoreProvider struct {

// +optional
PasswordDepot *PasswordDepotProvider `json:"passworddepot,omitempty"`

// +optional
Passbolt *PassboltProvider `json:"passbolt,omitempty"`
}

type CAProviderType string
Expand Down
50 changes: 50 additions & 0 deletions apis/externalsecrets/v1beta1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

57 changes: 57 additions & 0 deletions config/crds/bases/external-secrets.io_clustersecretstores.yaml
Expand Up @@ -3263,6 +3263,63 @@ spec:
- region
- vault
type: object
passbolt:
properties:
auth:
description: Auth defines the information necessary to authenticate
against Passbolt Server
properties:
passwordSecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being
referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
privateKeySecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being
referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
required:
- passwordSecretRef
- privateKeySecretRef
type: object
host:
description: Host defines the Passbolt Server to connect to
type: string
required:
- auth
- host
type: object
passworddepot:
description: Configures a store to sync secrets with a Password
Depot instance.
Expand Down
57 changes: 57 additions & 0 deletions config/crds/bases/external-secrets.io_secretstores.yaml
Expand Up @@ -3263,6 +3263,63 @@ spec:
- region
- vault
type: object
passbolt:
properties:
auth:
description: Auth defines the information necessary to authenticate
against Passbolt Server
properties:
passwordSecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being
referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
privateKeySecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being
referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
required:
- passwordSecretRef
- privateKeySecretRef
type: object
host:
description: Host defines the Passbolt Server to connect to
type: string
required:
- auth
- host
type: object
passworddepot:
description: Configures a store to sync secrets with a Password
Depot instance.
Expand Down
108 changes: 108 additions & 0 deletions deploy/crds/bundle.yaml
Expand Up @@ -3685,6 +3685,60 @@ spec:
- region
- vault
type: object
passbolt:
properties:
auth:
description: Auth defines the information necessary to authenticate against Passbolt Server
properties:
passwordSecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
privateKeySecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
required:
- passwordSecretRef
- privateKeySecretRef
type: object
host:
description: Host defines the Passbolt Server to connect to
type: string
required:
- auth
- host
type: object
passworddepot:
description: Configures a store to sync secrets with a Password Depot instance.
properties:
Expand Down Expand Up @@ -8955,6 +9009,60 @@ spec:
- region
- vault
type: object
passbolt:
properties:
auth:
description: Auth defines the information necessary to authenticate against Passbolt Server
properties:
passwordSecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
privateKeySecretRef:
description: |-
A reference to a specific 'key' within a Secret resource,
In some instances, `key` is a required field.
properties:
key:
description: |-
The key of the entry in the Secret resource's `data` field to be used. Some instances of this field may be
defaulted, in others it may be required.
type: string
name:
description: The name of the Secret resource being referred to.
type: string
namespace:
description: |-
Namespace of the resource being referred to. Ignored if referent is not cluster-scoped. cluster-scoped defaults
to the namespace of the referent.
type: string
type: object
required:
- passwordSecretRef
- privateKeySecretRef
type: object
host:
description: Host defines the Passbolt Server to connect to
type: string
required:
- auth
- host
type: object
passworddepot:
description: Configures a store to sync secrets with a Password Depot instance.
properties:
Expand Down