@virtru/dsp-sdk 0.2.3 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.rush/temp/chunked-rush-logs/dsp-sdk._phase_build.chunks.jsonl +3 -3
- package/.rush/temp/chunked-rush-logs/dsp-sdk._phase_test.chunks.jsonl +37 -9
- package/.rush/temp/package-deps__phase_build.json +16 -8
- package/.rush/temp/shrinkwrap-deps.json +39 -35
- package/CHANGELOG.json +28 -0
- package/CHANGELOG.md +15 -1
- package/README.md +55 -0
- package/buf.gen.yaml +17 -0
- package/buf.yaml +4 -0
- package/dist/src/gen/virtru/common/common_pb.d.ts +151 -0
- package/dist/src/gen/virtru/common/common_pb.js +57 -0
- package/dist/src/gen/virtru/policy/certificates/v1/certificates_pb.d.ts +215 -0
- package/dist/src/gen/virtru/policy/certificates/v1/certificates_pb.js +50 -0
- package/dist/src/gen/virtru/policy/objects_pb.d.ts +188 -0
- package/dist/src/gen/virtru/policy/objects_pb.js +126 -0
- package/dist/src/index.d.ts +1 -1
- package/dist/src/index.js +1 -1
- package/dist/src/lib/client.d.ts +2 -0
- package/dist/src/lib/client.js +2 -0
- package/dist/src/lib/consts.d.ts +2 -0
- package/dist/src/lib/consts.js +7 -0
- package/dist/src/lib/utils.d.ts +136 -0
- package/dist/src/lib/utils.js +355 -2
- package/package.json +5 -3
- package/src/gen/virtru/common/common_pb.ts +179 -0
- package/src/gen/virtru/policy/certificates/v1/certificates_connect.ts +44 -0
- package/src/gen/virtru/policy/certificates/v1/certificates_pb.ts +260 -0
- package/src/gen/virtru/policy/objects_pb.ts +235 -0
- package/src/index.ts +15 -1
- package/src/lib/client.ts +3 -0
- package/src/lib/consts.ts +8 -0
- package/src/lib/utils.test.ts +376 -0
- package/src/lib/utils.ts +460 -4
package/buf.gen.yaml
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
version: v2
|
|
2
|
+
managed:
|
|
3
|
+
enabled: true
|
|
4
|
+
disable:
|
|
5
|
+
- file_option: go_package
|
|
6
|
+
module: buf.build/bufbuild/protovalidate
|
|
7
|
+
- file_option: go_package
|
|
8
|
+
module: buf.build/googleapis/googleapis
|
|
9
|
+
plugins:
|
|
10
|
+
- remote: buf.build/bufbuild/es:v2.3.0
|
|
11
|
+
out: src/gen
|
|
12
|
+
opt:
|
|
13
|
+
- target=ts
|
|
14
|
+
- remote: buf.build/connectrpc/es:v1.6.1
|
|
15
|
+
out: src/gen
|
|
16
|
+
opt:
|
|
17
|
+
- target=ts
|
package/buf.yaml
ADDED
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
import type { GenEnum, GenFile, GenMessage } from "@bufbuild/protobuf/codegenv1";
|
|
2
|
+
import type { Timestamp } from "@bufbuild/protobuf/wkt";
|
|
3
|
+
import type { Message } from "@bufbuild/protobuf";
|
|
4
|
+
/**
|
|
5
|
+
* Describes the file virtru/common/common.proto.
|
|
6
|
+
*/
|
|
7
|
+
export declare const file_virtru_common_common: GenFile;
|
|
8
|
+
/**
|
|
9
|
+
* @generated from message virtru.common.Metadata
|
|
10
|
+
*/
|
|
11
|
+
export type Metadata = Message<"virtru.common.Metadata"> & {
|
|
12
|
+
/**
|
|
13
|
+
* @generated from field: google.protobuf.Timestamp created_at = 1;
|
|
14
|
+
*/
|
|
15
|
+
createdAt?: Timestamp;
|
|
16
|
+
/**
|
|
17
|
+
* @generated from field: google.protobuf.Timestamp updated_at = 2;
|
|
18
|
+
*/
|
|
19
|
+
updatedAt?: Timestamp;
|
|
20
|
+
/**
|
|
21
|
+
* @generated from field: map<string, string> labels = 3;
|
|
22
|
+
*/
|
|
23
|
+
labels: {
|
|
24
|
+
[key: string]: string;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* Describes the message virtru.common.Metadata.
|
|
29
|
+
* Use `create(MetadataSchema)` to create a new message.
|
|
30
|
+
*/
|
|
31
|
+
export declare const MetadataSchema: GenMessage<Metadata>;
|
|
32
|
+
/**
|
|
33
|
+
* @generated from message virtru.common.MetadataMutable
|
|
34
|
+
*/
|
|
35
|
+
export type MetadataMutable = Message<"virtru.common.MetadataMutable"> & {
|
|
36
|
+
/**
|
|
37
|
+
* @generated from field: map<string, string> labels = 3;
|
|
38
|
+
*/
|
|
39
|
+
labels: {
|
|
40
|
+
[key: string]: string;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* Describes the message virtru.common.MetadataMutable.
|
|
45
|
+
* Use `create(MetadataMutableSchema)` to create a new message.
|
|
46
|
+
*/
|
|
47
|
+
export declare const MetadataMutableSchema: GenMessage<MetadataMutable>;
|
|
48
|
+
/**
|
|
49
|
+
* @generated from message virtru.common.IdFqnIdentifier
|
|
50
|
+
*/
|
|
51
|
+
export type IdFqnIdentifier = Message<"virtru.common.IdFqnIdentifier"> & {
|
|
52
|
+
/**
|
|
53
|
+
* @generated from oneof virtru.common.IdFqnIdentifier.identifier
|
|
54
|
+
*/
|
|
55
|
+
identifier: {
|
|
56
|
+
/**
|
|
57
|
+
* @generated from field: string id = 1;
|
|
58
|
+
*/
|
|
59
|
+
value: string;
|
|
60
|
+
case: "id";
|
|
61
|
+
} | {
|
|
62
|
+
/**
|
|
63
|
+
* @generated from field: string fqn = 2;
|
|
64
|
+
*/
|
|
65
|
+
value: string;
|
|
66
|
+
case: "fqn";
|
|
67
|
+
} | {
|
|
68
|
+
case: undefined;
|
|
69
|
+
value?: undefined;
|
|
70
|
+
};
|
|
71
|
+
};
|
|
72
|
+
/**
|
|
73
|
+
* Describes the message virtru.common.IdFqnIdentifier.
|
|
74
|
+
* Use `create(IdFqnIdentifierSchema)` to create a new message.
|
|
75
|
+
*/
|
|
76
|
+
export declare const IdFqnIdentifierSchema: GenMessage<IdFqnIdentifier>;
|
|
77
|
+
/**
|
|
78
|
+
* @generated from message virtru.common.PageRequest
|
|
79
|
+
*/
|
|
80
|
+
export type PageRequest = Message<"virtru.common.PageRequest"> & {
|
|
81
|
+
/**
|
|
82
|
+
* Optional
|
|
83
|
+
* Set to configured default limit if not provided
|
|
84
|
+
* Maximum limit set in platform config and enforced by services
|
|
85
|
+
*
|
|
86
|
+
* @generated from field: int32 limit = 1;
|
|
87
|
+
*/
|
|
88
|
+
limit: number;
|
|
89
|
+
/**
|
|
90
|
+
* Optional
|
|
91
|
+
* Defaulted if not provided
|
|
92
|
+
*
|
|
93
|
+
* @generated from field: int32 offset = 2;
|
|
94
|
+
*/
|
|
95
|
+
offset: number;
|
|
96
|
+
};
|
|
97
|
+
/**
|
|
98
|
+
* Describes the message virtru.common.PageRequest.
|
|
99
|
+
* Use `create(PageRequestSchema)` to create a new message.
|
|
100
|
+
*/
|
|
101
|
+
export declare const PageRequestSchema: GenMessage<PageRequest>;
|
|
102
|
+
/**
|
|
103
|
+
* @generated from message virtru.common.PageResponse
|
|
104
|
+
*/
|
|
105
|
+
export type PageResponse = Message<"virtru.common.PageResponse"> & {
|
|
106
|
+
/**
|
|
107
|
+
* Requested pagination offset
|
|
108
|
+
*
|
|
109
|
+
* @generated from field: int32 current_offset = 1;
|
|
110
|
+
*/
|
|
111
|
+
currentOffset: number;
|
|
112
|
+
/**
|
|
113
|
+
* Calculated with request limit + offset or defaults
|
|
114
|
+
* Empty when none remain after current page
|
|
115
|
+
*
|
|
116
|
+
* @generated from field: int32 next_offset = 2;
|
|
117
|
+
*/
|
|
118
|
+
nextOffset: number;
|
|
119
|
+
/**
|
|
120
|
+
* Total count of entire list
|
|
121
|
+
*
|
|
122
|
+
* @generated from field: int32 total = 3;
|
|
123
|
+
*/
|
|
124
|
+
total: number;
|
|
125
|
+
};
|
|
126
|
+
/**
|
|
127
|
+
* Describes the message virtru.common.PageResponse.
|
|
128
|
+
* Use `create(PageResponseSchema)` to create a new message.
|
|
129
|
+
*/
|
|
130
|
+
export declare const PageResponseSchema: GenMessage<PageResponse>;
|
|
131
|
+
/**
|
|
132
|
+
* @generated from enum virtru.common.MetadataUpdateEnum
|
|
133
|
+
*/
|
|
134
|
+
export declare enum MetadataUpdateEnum {
|
|
135
|
+
/**
|
|
136
|
+
* @generated from enum value: METADATA_UPDATE_ENUM_UNSPECIFIED = 0;
|
|
137
|
+
*/
|
|
138
|
+
UNSPECIFIED = 0,
|
|
139
|
+
/**
|
|
140
|
+
* @generated from enum value: METADATA_UPDATE_ENUM_EXTEND = 1;
|
|
141
|
+
*/
|
|
142
|
+
EXTEND = 1,
|
|
143
|
+
/**
|
|
144
|
+
* @generated from enum value: METADATA_UPDATE_ENUM_REPLACE = 2;
|
|
145
|
+
*/
|
|
146
|
+
REPLACE = 2
|
|
147
|
+
}
|
|
148
|
+
/**
|
|
149
|
+
* Describes the enum virtru.common.MetadataUpdateEnum.
|
|
150
|
+
*/
|
|
151
|
+
export declare const MetadataUpdateEnumSchema: GenEnum<MetadataUpdateEnum>;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
// @generated by protoc-gen-es v2.3.0 with parameter "target=ts"
|
|
2
|
+
// @generated from file virtru/common/common.proto (package virtru.common, syntax proto3)
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
import { enumDesc, fileDesc, messageDesc } from "@bufbuild/protobuf/codegenv1";
|
|
5
|
+
import { file_buf_validate_validate } from "../../buf/validate/validate_pb";
|
|
6
|
+
import { file_google_protobuf_timestamp } from "@bufbuild/protobuf/wkt";
|
|
7
|
+
/**
|
|
8
|
+
* Describes the file virtru/common/common.proto.
|
|
9
|
+
*/
|
|
10
|
+
export const file_virtru_common_common = /*@__PURE__*/ fileDesc("Chp2aXJ0cnUvY29tbW9uL2NvbW1vbi5wcm90bxINdmlydHJ1LmNvbW1vbiLOAQoITWV0YWRhdGESLgoKY3JlYXRlZF9hdBgBIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3RhbXASLgoKdXBkYXRlZF9hdBgCIAEoCzIaLmdvb2dsZS5wcm90b2J1Zi5UaW1lc3RhbXASMwoGbGFiZWxzGAMgAygLMiMudmlydHJ1LmNvbW1vbi5NZXRhZGF0YS5MYWJlbHNFbnRyeRotCgtMYWJlbHNFbnRyeRILCgNrZXkYASABKAkSDQoFdmFsdWUYAiABKAk6AjgBInwKD01ldGFkYXRhTXV0YWJsZRI6CgZsYWJlbHMYAyADKAsyKi52aXJ0cnUuY29tbW9uLk1ldGFkYXRhTXV0YWJsZS5MYWJlbHNFbnRyeRotCgtMYWJlbHNFbnRyeRILCgNrZXkYASABKAkSDQoFdmFsdWUYAiABKAk6AjgBIlkKD0lkRnFuSWRlbnRpZmllchIWCgJpZBgBIAEoCUIIukgFcgOwAQFIABIZCgNmcW4YAiABKAlCCrpIB3IFEAGIAQFIAEITCgppZGVudGlmaWVyEgW6SAIIASIsCgtQYWdlUmVxdWVzdBINCgVsaW1pdBgBIAEoBRIOCgZvZmZzZXQYAiABKAUiSgoMUGFnZVJlc3BvbnNlEhYKDmN1cnJlbnRfb2Zmc2V0GAEgASgFEhMKC25leHRfb2Zmc2V0GAIgASgFEg0KBXRvdGFsGAMgASgFKn0KEk1ldGFkYXRhVXBkYXRlRW51bRIkCiBNRVRBREFUQV9VUERBVEVfRU5VTV9VTlNQRUNJRklFRBAAEh8KG01FVEFEQVRBX1VQREFURV9FTlVNX0VYVEVORBABEiAKHE1FVEFEQVRBX1VQREFURV9FTlVNX1JFUExBQ0UQAkJ1ChFjb20udmlydHJ1LmNvbW1vbkILQ29tbW9uUHJvdG9QAaICA1ZDWKoCDVZpcnRydS5Db21tb27KAg1WaXJ0cnVcQ29tbW9u4gIZVmlydHJ1XENvbW1vblxHUEJNZXRhZGF0YeoCDlZpcnRydTo6Q29tbW9uYgZwcm90bzM", [file_buf_validate_validate, file_google_protobuf_timestamp]);
|
|
11
|
+
/**
|
|
12
|
+
* Describes the message virtru.common.Metadata.
|
|
13
|
+
* Use `create(MetadataSchema)` to create a new message.
|
|
14
|
+
*/
|
|
15
|
+
export const MetadataSchema = /*@__PURE__*/ messageDesc(file_virtru_common_common, 0);
|
|
16
|
+
/**
|
|
17
|
+
* Describes the message virtru.common.MetadataMutable.
|
|
18
|
+
* Use `create(MetadataMutableSchema)` to create a new message.
|
|
19
|
+
*/
|
|
20
|
+
export const MetadataMutableSchema = /*@__PURE__*/ messageDesc(file_virtru_common_common, 1);
|
|
21
|
+
/**
|
|
22
|
+
* Describes the message virtru.common.IdFqnIdentifier.
|
|
23
|
+
* Use `create(IdFqnIdentifierSchema)` to create a new message.
|
|
24
|
+
*/
|
|
25
|
+
export const IdFqnIdentifierSchema = /*@__PURE__*/ messageDesc(file_virtru_common_common, 2);
|
|
26
|
+
/**
|
|
27
|
+
* Describes the message virtru.common.PageRequest.
|
|
28
|
+
* Use `create(PageRequestSchema)` to create a new message.
|
|
29
|
+
*/
|
|
30
|
+
export const PageRequestSchema = /*@__PURE__*/ messageDesc(file_virtru_common_common, 3);
|
|
31
|
+
/**
|
|
32
|
+
* Describes the message virtru.common.PageResponse.
|
|
33
|
+
* Use `create(PageResponseSchema)` to create a new message.
|
|
34
|
+
*/
|
|
35
|
+
export const PageResponseSchema = /*@__PURE__*/ messageDesc(file_virtru_common_common, 4);
|
|
36
|
+
/**
|
|
37
|
+
* @generated from enum virtru.common.MetadataUpdateEnum
|
|
38
|
+
*/
|
|
39
|
+
export var MetadataUpdateEnum;
|
|
40
|
+
(function (MetadataUpdateEnum) {
|
|
41
|
+
/**
|
|
42
|
+
* @generated from enum value: METADATA_UPDATE_ENUM_UNSPECIFIED = 0;
|
|
43
|
+
*/
|
|
44
|
+
MetadataUpdateEnum[MetadataUpdateEnum["UNSPECIFIED"] = 0] = "UNSPECIFIED";
|
|
45
|
+
/**
|
|
46
|
+
* @generated from enum value: METADATA_UPDATE_ENUM_EXTEND = 1;
|
|
47
|
+
*/
|
|
48
|
+
MetadataUpdateEnum[MetadataUpdateEnum["EXTEND"] = 1] = "EXTEND";
|
|
49
|
+
/**
|
|
50
|
+
* @generated from enum value: METADATA_UPDATE_ENUM_REPLACE = 2;
|
|
51
|
+
*/
|
|
52
|
+
MetadataUpdateEnum[MetadataUpdateEnum["REPLACE"] = 2] = "REPLACE";
|
|
53
|
+
})(MetadataUpdateEnum || (MetadataUpdateEnum = {}));
|
|
54
|
+
/**
|
|
55
|
+
* Describes the enum virtru.common.MetadataUpdateEnum.
|
|
56
|
+
*/
|
|
57
|
+
export const MetadataUpdateEnumSchema = /*@__PURE__*/ enumDesc(file_virtru_common_common, 0);
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv1";
|
|
2
|
+
import type { MetadataMutable, PageRequest, PageResponse } from "../../../common/common_pb";
|
|
3
|
+
import type { Algorithm, Certificate, KeyMode, KeyStatus } from "../../objects_pb";
|
|
4
|
+
import type { Message } from "@bufbuild/protobuf";
|
|
5
|
+
/**
|
|
6
|
+
* Describes the file virtru/policy/certificates/v1/certificates.proto.
|
|
7
|
+
*/
|
|
8
|
+
export declare const file_virtru_policy_certificates_v1_certificates: GenFile;
|
|
9
|
+
/**
|
|
10
|
+
* Maps a namespace to a certificate (similar to NamespaceKey pattern)
|
|
11
|
+
*
|
|
12
|
+
* @generated from message virtru.policy.certificates.v1.NamespaceCertificate
|
|
13
|
+
*/
|
|
14
|
+
export type NamespaceCertificate = Message<"virtru.policy.certificates.v1.NamespaceCertificate"> & {
|
|
15
|
+
/**
|
|
16
|
+
* Required - namespace id
|
|
17
|
+
*
|
|
18
|
+
* @generated from field: string namespace_id = 1;
|
|
19
|
+
*/
|
|
20
|
+
namespaceId: string;
|
|
21
|
+
/**
|
|
22
|
+
* Required (The id from the Certificate object)
|
|
23
|
+
*
|
|
24
|
+
* @generated from field: string certificate_id = 2;
|
|
25
|
+
*/
|
|
26
|
+
certificateId: string;
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Describes the message virtru.policy.certificates.v1.NamespaceCertificate.
|
|
30
|
+
* Use `create(NamespaceCertificateSchema)` to create a new message.
|
|
31
|
+
*/
|
|
32
|
+
export declare const NamespaceCertificateSchema: GenMessage<NamespaceCertificate>;
|
|
33
|
+
/**
|
|
34
|
+
* @generated from message virtru.policy.certificates.v1.ListCertificatesByNamespaceRequest
|
|
35
|
+
*/
|
|
36
|
+
export type ListCertificatesByNamespaceRequest = Message<"virtru.policy.certificates.v1.ListCertificatesByNamespaceRequest"> & {
|
|
37
|
+
/**
|
|
38
|
+
* Required - namespace id
|
|
39
|
+
*
|
|
40
|
+
* @generated from field: string namespace_id = 1;
|
|
41
|
+
*/
|
|
42
|
+
namespaceId: string;
|
|
43
|
+
/**
|
|
44
|
+
* Optional pagination information
|
|
45
|
+
*
|
|
46
|
+
* @generated from field: virtru.common.PageRequest pagination = 10;
|
|
47
|
+
*/
|
|
48
|
+
pagination?: PageRequest;
|
|
49
|
+
};
|
|
50
|
+
/**
|
|
51
|
+
* Describes the message virtru.policy.certificates.v1.ListCertificatesByNamespaceRequest.
|
|
52
|
+
* Use `create(ListCertificatesByNamespaceRequestSchema)` to create a new message.
|
|
53
|
+
*/
|
|
54
|
+
export declare const ListCertificatesByNamespaceRequestSchema: GenMessage<ListCertificatesByNamespaceRequest>;
|
|
55
|
+
/**
|
|
56
|
+
* ListCertificatesByNamespaceResponse is the response message for the ListCertificatesByNamespace method.
|
|
57
|
+
*
|
|
58
|
+
* @generated from message virtru.policy.certificates.v1.ListCertificatesByNamespaceResponse
|
|
59
|
+
*/
|
|
60
|
+
export type ListCertificatesByNamespaceResponse = Message<"virtru.policy.certificates.v1.ListCertificatesByNamespaceResponse"> & {
|
|
61
|
+
/**
|
|
62
|
+
* The list of certificates for the specified namespace.
|
|
63
|
+
*
|
|
64
|
+
* @generated from field: repeated virtru.policy.Certificate certificates = 1;
|
|
65
|
+
*/
|
|
66
|
+
certificates: Certificate[];
|
|
67
|
+
/**
|
|
68
|
+
* Pagination information
|
|
69
|
+
*
|
|
70
|
+
* @generated from field: virtru.common.PageResponse pagination = 10;
|
|
71
|
+
*/
|
|
72
|
+
pagination?: PageResponse;
|
|
73
|
+
};
|
|
74
|
+
/**
|
|
75
|
+
* Describes the message virtru.policy.certificates.v1.ListCertificatesByNamespaceResponse.
|
|
76
|
+
* Use `create(ListCertificatesByNamespaceResponseSchema)` to create a new message.
|
|
77
|
+
*/
|
|
78
|
+
export declare const ListCertificatesByNamespaceResponseSchema: GenMessage<ListCertificatesByNamespaceResponse>;
|
|
79
|
+
/**
|
|
80
|
+
* @generated from message virtru.policy.certificates.v1.AssignCertificateToNamespaceRequest
|
|
81
|
+
*/
|
|
82
|
+
export type AssignCertificateToNamespaceRequest = Message<"virtru.policy.certificates.v1.AssignCertificateToNamespaceRequest"> & {
|
|
83
|
+
/**
|
|
84
|
+
* Required - namespace id
|
|
85
|
+
*
|
|
86
|
+
* @generated from field: string namespace_id = 1;
|
|
87
|
+
*/
|
|
88
|
+
namespaceId: string;
|
|
89
|
+
/**
|
|
90
|
+
* Required - PEM format certificate
|
|
91
|
+
*
|
|
92
|
+
* @generated from field: string pem = 2;
|
|
93
|
+
*/
|
|
94
|
+
pem: string;
|
|
95
|
+
/**
|
|
96
|
+
* @generated from field: string key_id = 3;
|
|
97
|
+
*/
|
|
98
|
+
keyId: string;
|
|
99
|
+
/**
|
|
100
|
+
* The algorithm to be used for the key
|
|
101
|
+
*
|
|
102
|
+
* @generated from field: virtru.policy.Algorithm key_algorithm = 4;
|
|
103
|
+
*/
|
|
104
|
+
keyAlgorithm: Algorithm;
|
|
105
|
+
/**
|
|
106
|
+
* @generated from field: string name = 5;
|
|
107
|
+
*/
|
|
108
|
+
name: string;
|
|
109
|
+
/**
|
|
110
|
+
* The status of the key
|
|
111
|
+
*
|
|
112
|
+
* @generated from field: virtru.policy.KeyStatus key_status = 6;
|
|
113
|
+
*/
|
|
114
|
+
keyStatus: KeyStatus;
|
|
115
|
+
/**
|
|
116
|
+
* The mode of the key
|
|
117
|
+
*
|
|
118
|
+
* @generated from field: virtru.policy.KeyMode key_mode = 7;
|
|
119
|
+
*/
|
|
120
|
+
keyMode: KeyMode;
|
|
121
|
+
/**
|
|
122
|
+
* Optional
|
|
123
|
+
*
|
|
124
|
+
* @generated from field: virtru.common.MetadataMutable metadata = 100;
|
|
125
|
+
*/
|
|
126
|
+
metadata?: MetadataMutable;
|
|
127
|
+
};
|
|
128
|
+
/**
|
|
129
|
+
* Describes the message virtru.policy.certificates.v1.AssignCertificateToNamespaceRequest.
|
|
130
|
+
* Use `create(AssignCertificateToNamespaceRequestSchema)` to create a new message.
|
|
131
|
+
*/
|
|
132
|
+
export declare const AssignCertificateToNamespaceRequestSchema: GenMessage<AssignCertificateToNamespaceRequest>;
|
|
133
|
+
/**
|
|
134
|
+
* @generated from message virtru.policy.certificates.v1.AssignCertificateToNamespaceResponse
|
|
135
|
+
*/
|
|
136
|
+
export type AssignCertificateToNamespaceResponse = Message<"virtru.policy.certificates.v1.AssignCertificateToNamespaceResponse"> & {
|
|
137
|
+
/**
|
|
138
|
+
* The mapping of the namespace to the certificate.
|
|
139
|
+
*
|
|
140
|
+
* @generated from field: virtru.policy.certificates.v1.NamespaceCertificate namespace_certificate = 1;
|
|
141
|
+
*/
|
|
142
|
+
namespaceCertificate?: NamespaceCertificate;
|
|
143
|
+
/**
|
|
144
|
+
* Return the full certificate object for convenience
|
|
145
|
+
*
|
|
146
|
+
* @generated from field: virtru.policy.Certificate certificate = 2;
|
|
147
|
+
*/
|
|
148
|
+
certificate?: Certificate;
|
|
149
|
+
};
|
|
150
|
+
/**
|
|
151
|
+
* Describes the message virtru.policy.certificates.v1.AssignCertificateToNamespaceResponse.
|
|
152
|
+
* Use `create(AssignCertificateToNamespaceResponseSchema)` to create a new message.
|
|
153
|
+
*/
|
|
154
|
+
export declare const AssignCertificateToNamespaceResponseSchema: GenMessage<AssignCertificateToNamespaceResponse>;
|
|
155
|
+
/**
|
|
156
|
+
* @generated from message virtru.policy.certificates.v1.RemoveCertificateFromNamespaceRequest
|
|
157
|
+
*/
|
|
158
|
+
export type RemoveCertificateFromNamespaceRequest = Message<"virtru.policy.certificates.v1.RemoveCertificateFromNamespaceRequest"> & {
|
|
159
|
+
/**
|
|
160
|
+
* The namespace and certificate to unassign.
|
|
161
|
+
*
|
|
162
|
+
* @generated from field: virtru.policy.certificates.v1.NamespaceCertificate namespace_certificate = 1;
|
|
163
|
+
*/
|
|
164
|
+
namespaceCertificate?: NamespaceCertificate;
|
|
165
|
+
};
|
|
166
|
+
/**
|
|
167
|
+
* Describes the message virtru.policy.certificates.v1.RemoveCertificateFromNamespaceRequest.
|
|
168
|
+
* Use `create(RemoveCertificateFromNamespaceRequestSchema)` to create a new message.
|
|
169
|
+
*/
|
|
170
|
+
export declare const RemoveCertificateFromNamespaceRequestSchema: GenMessage<RemoveCertificateFromNamespaceRequest>;
|
|
171
|
+
/**
|
|
172
|
+
* @generated from message virtru.policy.certificates.v1.RemoveCertificateFromNamespaceResponse
|
|
173
|
+
*/
|
|
174
|
+
export type RemoveCertificateFromNamespaceResponse = Message<"virtru.policy.certificates.v1.RemoveCertificateFromNamespaceResponse"> & {
|
|
175
|
+
/**
|
|
176
|
+
* The unassigned namespace and certificate.
|
|
177
|
+
*
|
|
178
|
+
* @generated from field: virtru.policy.certificates.v1.NamespaceCertificate namespace_certificate = 1;
|
|
179
|
+
*/
|
|
180
|
+
namespaceCertificate?: NamespaceCertificate;
|
|
181
|
+
};
|
|
182
|
+
/**
|
|
183
|
+
* Describes the message virtru.policy.certificates.v1.RemoveCertificateFromNamespaceResponse.
|
|
184
|
+
* Use `create(RemoveCertificateFromNamespaceResponseSchema)` to create a new message.
|
|
185
|
+
*/
|
|
186
|
+
export declare const RemoveCertificateFromNamespaceResponseSchema: GenMessage<RemoveCertificateFromNamespaceResponse>;
|
|
187
|
+
/**
|
|
188
|
+
* @generated from service virtru.policy.certificates.v1.CertificateService
|
|
189
|
+
*/
|
|
190
|
+
export declare const CertificateService: GenService<{
|
|
191
|
+
/**
|
|
192
|
+
* @generated from rpc virtru.policy.certificates.v1.CertificateService.ListCertificatesByNamespace
|
|
193
|
+
*/
|
|
194
|
+
listCertificatesByNamespace: {
|
|
195
|
+
methodKind: "unary";
|
|
196
|
+
input: typeof ListCertificatesByNamespaceRequestSchema;
|
|
197
|
+
output: typeof ListCertificatesByNamespaceResponseSchema;
|
|
198
|
+
};
|
|
199
|
+
/**
|
|
200
|
+
* @generated from rpc virtru.policy.certificates.v1.CertificateService.AssignCertificateToNamespace
|
|
201
|
+
*/
|
|
202
|
+
assignCertificateToNamespace: {
|
|
203
|
+
methodKind: "unary";
|
|
204
|
+
input: typeof AssignCertificateToNamespaceRequestSchema;
|
|
205
|
+
output: typeof AssignCertificateToNamespaceResponseSchema;
|
|
206
|
+
};
|
|
207
|
+
/**
|
|
208
|
+
* @generated from rpc virtru.policy.certificates.v1.CertificateService.RemoveCertificateFromNamespace
|
|
209
|
+
*/
|
|
210
|
+
removeCertificateFromNamespace: {
|
|
211
|
+
methodKind: "unary";
|
|
212
|
+
input: typeof RemoveCertificateFromNamespaceRequestSchema;
|
|
213
|
+
output: typeof RemoveCertificateFromNamespaceResponseSchema;
|
|
214
|
+
};
|
|
215
|
+
}>;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
// @generated by protoc-gen-es v2.3.0 with parameter "target=ts"
|
|
2
|
+
// @generated from file virtru/policy/certificates/v1/certificates.proto (package virtru.policy.certificates.v1, syntax proto3)
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
import { fileDesc, messageDesc, serviceDesc } from "@bufbuild/protobuf/codegenv1";
|
|
5
|
+
import { file_buf_validate_validate } from "../../../../buf/validate/validate_pb";
|
|
6
|
+
import { file_virtru_common_common } from "../../../common/common_pb";
|
|
7
|
+
import { file_virtru_policy_objects } from "../../objects_pb";
|
|
8
|
+
/**
|
|
9
|
+
* Describes the file virtru/policy/certificates/v1/certificates.proto.
|
|
10
|
+
*/
|
|
11
|
+
export const file_virtru_policy_certificates_v1_certificates = /*@__PURE__*/ fileDesc("CjB2aXJ0cnUvcG9saWN5L2NlcnRpZmljYXRlcy92MS9jZXJ0aWZpY2F0ZXMucHJvdG8SHXZpcnRydS5wb2xpY3kuY2VydGlmaWNhdGVzLnYxIl4KFE5hbWVzcGFjZUNlcnRpZmljYXRlEiEKDG5hbWVzcGFjZV9pZBgBIAEoCUILukgIyAEBcgOwAQESIwoOY2VydGlmaWNhdGVfaWQYAiABKAlCC7pICMgBAXIDsAEBIncKIkxpc3RDZXJ0aWZpY2F0ZXNCeU5hbWVzcGFjZVJlcXVlc3QSIQoMbmFtZXNwYWNlX2lkGAEgASgJQgu6SAjIAQFyA7ABARIuCgpwYWdpbmF0aW9uGAogASgLMhoudmlydHJ1LmNvbW1vbi5QYWdlUmVxdWVzdCKIAQojTGlzdENlcnRpZmljYXRlc0J5TmFtZXNwYWNlUmVzcG9uc2USMAoMY2VydGlmaWNhdGVzGAEgAygLMhoudmlydHJ1LnBvbGljeS5DZXJ0aWZpY2F0ZRIvCgpwYWdpbmF0aW9uGAogASgLMhsudmlydHJ1LmNvbW1vbi5QYWdlUmVzcG9uc2UiugMKI0Fzc2lnbkNlcnRpZmljYXRlVG9OYW1lc3BhY2VSZXF1ZXN0EiEKDG5hbWVzcGFjZV9pZBgBIAEoCUILukgIyAEBcgOwAQESEwoDcGVtGAIgASgJQga6SAPIAQESGwoGa2V5X2lkGAMgASgJQgu6SAjIAQFyA7ABARKdAQoNa2V5X2FsZ29yaXRobRgEIAEoDjIYLnZpcnRydS5wb2xpY3kuQWxnb3JpdGhtQmy6SGm6AWYKFWtleV9hbGdvcml0aG1fZGVmaW5lZBI0VGhlIGtleV9hbGdvcml0aG0gbXVzdCBiZSBvbmUgb2YgdGhlIGRlZmluZWQgdmFsdWVzLhoXdGhpcyBpbiBbMSwgMiwgMywgNCwgNV0SFAoEbmFtZRgFIAEoCUIGukgDyAEBEiwKCmtleV9zdGF0dXMYBiABKA4yGC52aXJ0cnUucG9saWN5LktleVN0YXR1cxIoCghrZXlfbW9kZRgHIAEoDjIWLnZpcnRydS5wb2xpY3kuS2V5TW9kZRIwCghtZXRhZGF0YRhkIAEoCzIeLnZpcnRydS5jb21tb24uTWV0YWRhdGFNdXRhYmxlIqsBCiRBc3NpZ25DZXJ0aWZpY2F0ZVRvTmFtZXNwYWNlUmVzcG9uc2USUgoVbmFtZXNwYWNlX2NlcnRpZmljYXRlGAEgASgLMjMudmlydHJ1LnBvbGljeS5jZXJ0aWZpY2F0ZXMudjEuTmFtZXNwYWNlQ2VydGlmaWNhdGUSLwoLY2VydGlmaWNhdGUYAiABKAsyGi52aXJ0cnUucG9saWN5LkNlcnRpZmljYXRlIoMBCiVSZW1vdmVDZXJ0aWZpY2F0ZUZyb21OYW1lc3BhY2VSZXF1ZXN0EloKFW5hbWVzcGFjZV9jZXJ0aWZpY2F0ZRgBIAEoCzIzLnZpcnRydS5wb2xpY3kuY2VydGlmaWNhdGVzLnYxLk5hbWVzcGFjZUNlcnRpZmljYXRlQga6SAPIAQEifAomUmVtb3ZlQ2VydGlmaWNhdGVGcm9tTmFtZXNwYWNlUmVzcG9uc2USUgoVbmFtZXNwYWNlX2NlcnRpZmljYXRlGAEgASgLMjMudmlydHJ1LnBvbGljeS5jZXJ0aWZpY2F0ZXMudjEuTmFtZXNwYWNlQ2VydGlmaWNhdGUymwQKEkNlcnRpZmljYXRlU2VydmljZRKmAQobTGlzdENlcnRpZmljYXRlc0J5TmFtZXNwYWNlEkEudmlydHJ1LnBvbGljeS5jZXJ0aWZpY2F0ZXMudjEuTGlzdENlcnRpZmljYXRlc0J5TmFtZXNwYWNlUmVxdWVzdBpCLnZpcnRydS5wb2xpY3kuY2VydGlmaWNhdGVzLnYxLkxpc3RDZXJ0aWZpY2F0ZXNCeU5hbWVzcGFjZVJlc3BvbnNlIgASqQEKHEFzc2lnbkNlcnRpZmljYXRlVG9OYW1lc3BhY2USQi52aXJ0cnUucG9saWN5LmNlcnRpZmljYXRlcy52MS5Bc3NpZ25DZXJ0aWZpY2F0ZVRvTmFtZXNwYWNlUmVxdWVzdBpDLnZpcnRydS5wb2xpY3kuY2VydGlmaWNhdGVzLnYxLkFzc2lnbkNlcnRpZmljYXRlVG9OYW1lc3BhY2VSZXNwb25zZSIAEq8BCh5SZW1vdmVDZXJ0aWZpY2F0ZUZyb21OYW1lc3BhY2USRC52aXJ0cnUucG9saWN5LmNlcnRpZmljYXRlcy52MS5SZW1vdmVDZXJ0aWZpY2F0ZUZyb21OYW1lc3BhY2VSZXF1ZXN0GkUudmlydHJ1LnBvbGljeS5jZXJ0aWZpY2F0ZXMudjEuUmVtb3ZlQ2VydGlmaWNhdGVGcm9tTmFtZXNwYWNlUmVzcG9uc2UiAELNAQohY29tLnZpcnRydS5wb2xpY3kuY2VydGlmaWNhdGVzLnYxQhFDZXJ0aWZpY2F0ZXNQcm90b1ABogIDVlBDqgIdVmlydHJ1LlBvbGljeS5DZXJ0aWZpY2F0ZXMuVjHKAh1WaXJ0cnVcUG9saWN5XENlcnRpZmljYXRlc1xWMeICKVZpcnRydVxQb2xpY3lcQ2VydGlmaWNhdGVzXFYxXEdQQk1ldGFkYXRh6gIgVmlydHJ1OjpQb2xpY3k6OkNlcnRpZmljYXRlczo6VjFiBnByb3RvMw", [file_buf_validate_validate, file_virtru_common_common, file_virtru_policy_objects]);
|
|
12
|
+
/**
|
|
13
|
+
* Describes the message virtru.policy.certificates.v1.NamespaceCertificate.
|
|
14
|
+
* Use `create(NamespaceCertificateSchema)` to create a new message.
|
|
15
|
+
*/
|
|
16
|
+
export const NamespaceCertificateSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 0);
|
|
17
|
+
/**
|
|
18
|
+
* Describes the message virtru.policy.certificates.v1.ListCertificatesByNamespaceRequest.
|
|
19
|
+
* Use `create(ListCertificatesByNamespaceRequestSchema)` to create a new message.
|
|
20
|
+
*/
|
|
21
|
+
export const ListCertificatesByNamespaceRequestSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 1);
|
|
22
|
+
/**
|
|
23
|
+
* Describes the message virtru.policy.certificates.v1.ListCertificatesByNamespaceResponse.
|
|
24
|
+
* Use `create(ListCertificatesByNamespaceResponseSchema)` to create a new message.
|
|
25
|
+
*/
|
|
26
|
+
export const ListCertificatesByNamespaceResponseSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 2);
|
|
27
|
+
/**
|
|
28
|
+
* Describes the message virtru.policy.certificates.v1.AssignCertificateToNamespaceRequest.
|
|
29
|
+
* Use `create(AssignCertificateToNamespaceRequestSchema)` to create a new message.
|
|
30
|
+
*/
|
|
31
|
+
export const AssignCertificateToNamespaceRequestSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 3);
|
|
32
|
+
/**
|
|
33
|
+
* Describes the message virtru.policy.certificates.v1.AssignCertificateToNamespaceResponse.
|
|
34
|
+
* Use `create(AssignCertificateToNamespaceResponseSchema)` to create a new message.
|
|
35
|
+
*/
|
|
36
|
+
export const AssignCertificateToNamespaceResponseSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 4);
|
|
37
|
+
/**
|
|
38
|
+
* Describes the message virtru.policy.certificates.v1.RemoveCertificateFromNamespaceRequest.
|
|
39
|
+
* Use `create(RemoveCertificateFromNamespaceRequestSchema)` to create a new message.
|
|
40
|
+
*/
|
|
41
|
+
export const RemoveCertificateFromNamespaceRequestSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 5);
|
|
42
|
+
/**
|
|
43
|
+
* Describes the message virtru.policy.certificates.v1.RemoveCertificateFromNamespaceResponse.
|
|
44
|
+
* Use `create(RemoveCertificateFromNamespaceResponseSchema)` to create a new message.
|
|
45
|
+
*/
|
|
46
|
+
export const RemoveCertificateFromNamespaceResponseSchema = /*@__PURE__*/ messageDesc(file_virtru_policy_certificates_v1_certificates, 6);
|
|
47
|
+
/**
|
|
48
|
+
* @generated from service virtru.policy.certificates.v1.CertificateService
|
|
49
|
+
*/
|
|
50
|
+
export const CertificateService = /*@__PURE__*/ serviceDesc(file_virtru_policy_certificates_v1_certificates, 0);
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
import type { GenEnum, GenFile, GenMessage } from "@bufbuild/protobuf/codegenv1";
|
|
2
|
+
import type { Metadata } from "../common/common_pb";
|
|
3
|
+
import type { Message } from "@bufbuild/protobuf";
|
|
4
|
+
/**
|
|
5
|
+
* Describes the file virtru/policy/objects.proto.
|
|
6
|
+
*/
|
|
7
|
+
export declare const file_virtru_policy_objects: GenFile;
|
|
8
|
+
/**
|
|
9
|
+
* @generated from message virtru.policy.Certificate
|
|
10
|
+
*/
|
|
11
|
+
export type Certificate = Message<"virtru.policy.Certificate"> & {
|
|
12
|
+
/**
|
|
13
|
+
* @generated from field: string id = 1;
|
|
14
|
+
*/
|
|
15
|
+
id: string;
|
|
16
|
+
/**
|
|
17
|
+
* @generated from field: string key_id = 2;
|
|
18
|
+
*/
|
|
19
|
+
keyId: string;
|
|
20
|
+
/**
|
|
21
|
+
* @generated from field: virtru.policy.Algorithm key_algorithm = 3;
|
|
22
|
+
*/
|
|
23
|
+
keyAlgorithm: Algorithm;
|
|
24
|
+
/**
|
|
25
|
+
* @generated from field: virtru.policy.KeyStatus key_status = 4;
|
|
26
|
+
*/
|
|
27
|
+
keyStatus: KeyStatus;
|
|
28
|
+
/**
|
|
29
|
+
* @generated from field: string pem = 5;
|
|
30
|
+
*/
|
|
31
|
+
pem: string;
|
|
32
|
+
/**
|
|
33
|
+
* The name of the certificate.
|
|
34
|
+
*
|
|
35
|
+
* @generated from field: string name = 6;
|
|
36
|
+
*/
|
|
37
|
+
name: string;
|
|
38
|
+
/**
|
|
39
|
+
* The key mode of the certificate.
|
|
40
|
+
*
|
|
41
|
+
* @generated from field: virtru.policy.KeyMode key_mode = 7;
|
|
42
|
+
*/
|
|
43
|
+
keyMode: KeyMode;
|
|
44
|
+
/**
|
|
45
|
+
* The fingerprint of the certificate.
|
|
46
|
+
*
|
|
47
|
+
* @generated from field: string fingerprint = 8;
|
|
48
|
+
*/
|
|
49
|
+
fingerprint: string;
|
|
50
|
+
/**
|
|
51
|
+
* @generated from field: virtru.common.Metadata metadata = 100;
|
|
52
|
+
*/
|
|
53
|
+
metadata?: Metadata;
|
|
54
|
+
};
|
|
55
|
+
/**
|
|
56
|
+
* Describes the message virtru.policy.Certificate.
|
|
57
|
+
* Use `create(CertificateSchema)` to create a new message.
|
|
58
|
+
*/
|
|
59
|
+
export declare const CertificateSchema: GenMessage<Certificate>;
|
|
60
|
+
/**
|
|
61
|
+
* @generated from message virtru.policy.CertificateMapping
|
|
62
|
+
*/
|
|
63
|
+
export type CertificateMapping = Message<"virtru.policy.CertificateMapping"> & {
|
|
64
|
+
/**
|
|
65
|
+
* @generated from field: string id = 1;
|
|
66
|
+
*/
|
|
67
|
+
id: string;
|
|
68
|
+
/**
|
|
69
|
+
* @generated from field: string certificate_id = 2;
|
|
70
|
+
*/
|
|
71
|
+
certificateId: string;
|
|
72
|
+
/**
|
|
73
|
+
* @generated from field: string namespace_id = 3;
|
|
74
|
+
*/
|
|
75
|
+
namespaceId: string;
|
|
76
|
+
/**
|
|
77
|
+
* @generated from field: virtru.common.Metadata metadata = 100;
|
|
78
|
+
*/
|
|
79
|
+
metadata?: Metadata;
|
|
80
|
+
};
|
|
81
|
+
/**
|
|
82
|
+
* Describes the message virtru.policy.CertificateMapping.
|
|
83
|
+
* Use `create(CertificateMappingSchema)` to create a new message.
|
|
84
|
+
*/
|
|
85
|
+
export declare const CertificateMappingSchema: GenMessage<CertificateMapping>;
|
|
86
|
+
/**
|
|
87
|
+
* @generated from enum virtru.policy.Algorithm
|
|
88
|
+
*/
|
|
89
|
+
export declare enum Algorithm {
|
|
90
|
+
/**
|
|
91
|
+
* @generated from enum value: ALGORITHM_UNSPECIFIED = 0;
|
|
92
|
+
*/
|
|
93
|
+
UNSPECIFIED = 0,
|
|
94
|
+
/**
|
|
95
|
+
* @generated from enum value: ALGORITHM_RSA_2048 = 1;
|
|
96
|
+
*/
|
|
97
|
+
RSA_2048 = 1,
|
|
98
|
+
/**
|
|
99
|
+
* @generated from enum value: ALGORITHM_RSA_4096 = 2;
|
|
100
|
+
*/
|
|
101
|
+
RSA_4096 = 2,
|
|
102
|
+
/**
|
|
103
|
+
* @generated from enum value: ALGORITHM_EC_P256 = 3;
|
|
104
|
+
*/
|
|
105
|
+
EC_P256 = 3,
|
|
106
|
+
/**
|
|
107
|
+
* @generated from enum value: ALGORITHM_EC_P384 = 4;
|
|
108
|
+
*/
|
|
109
|
+
EC_P384 = 4,
|
|
110
|
+
/**
|
|
111
|
+
* @generated from enum value: ALGORITHM_EC_P521 = 5;
|
|
112
|
+
*/
|
|
113
|
+
EC_P521 = 5
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Describes the enum virtru.policy.Algorithm.
|
|
117
|
+
*/
|
|
118
|
+
export declare const AlgorithmSchema: GenEnum<Algorithm>;
|
|
119
|
+
/**
|
|
120
|
+
* @generated from enum virtru.policy.KeyStatus
|
|
121
|
+
*/
|
|
122
|
+
export declare enum KeyStatus {
|
|
123
|
+
/**
|
|
124
|
+
* @generated from enum value: KEY_STATUS_UNSPECIFIED = 0;
|
|
125
|
+
*/
|
|
126
|
+
UNSPECIFIED = 0,
|
|
127
|
+
/**
|
|
128
|
+
* @generated from enum value: KEY_STATUS_ACTIVE = 1;
|
|
129
|
+
*/
|
|
130
|
+
ACTIVE = 1,
|
|
131
|
+
/**
|
|
132
|
+
* @generated from enum value: KEY_STATUS_ROTATED = 2;
|
|
133
|
+
*/
|
|
134
|
+
ROTATED = 2
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Describes the enum virtru.policy.KeyStatus.
|
|
138
|
+
*/
|
|
139
|
+
export declare const KeyStatusSchema: GenEnum<KeyStatus>;
|
|
140
|
+
/**
|
|
141
|
+
* Describes the management and operational mode of a cryptographic key.
|
|
142
|
+
*
|
|
143
|
+
* @generated from enum virtru.policy.KeyMode
|
|
144
|
+
*/
|
|
145
|
+
export declare enum KeyMode {
|
|
146
|
+
/**
|
|
147
|
+
* KEY_MODE_UNSPECIFIED: Default, unspecified key mode. Indicates an uninitialized or error state.
|
|
148
|
+
*
|
|
149
|
+
* @generated from enum value: KEY_MODE_UNSPECIFIED = 0;
|
|
150
|
+
*/
|
|
151
|
+
UNSPECIFIED = 0,
|
|
152
|
+
/**
|
|
153
|
+
* KEY_MODE_CONFIG_ROOT_KEY: Local key management where the private key is wrapped by a Key Encryption Key (KEK)
|
|
154
|
+
* sourced from local configuration. Unwrapping and all cryptographic operations are performed locally.
|
|
155
|
+
*
|
|
156
|
+
* @generated from enum value: KEY_MODE_CONFIG_ROOT_KEY = 1;
|
|
157
|
+
*/
|
|
158
|
+
CONFIG_ROOT_KEY = 1,
|
|
159
|
+
/**
|
|
160
|
+
* KEY_MODE_PROVIDER_ROOT_KEY: Local key management where the private key is wrapped by a Key Encryption Key (KEK)
|
|
161
|
+
* managed by an external provider (e.g., a Hardware Security Module or Cloud KMS).
|
|
162
|
+
* Key unwrapping is delegated to the external provider; subsequent cryptographic operations
|
|
163
|
+
* are performed locally using the unwrapped key.
|
|
164
|
+
*
|
|
165
|
+
* @generated from enum value: KEY_MODE_PROVIDER_ROOT_KEY = 2;
|
|
166
|
+
*/
|
|
167
|
+
PROVIDER_ROOT_KEY = 2,
|
|
168
|
+
/**
|
|
169
|
+
* KEY_MODE_REMOTE: Remote key management where the private key is stored in, and all cryptographic
|
|
170
|
+
* operations are performed by, a remote Key Management Service (KMS) or HSM.
|
|
171
|
+
* The private key material never leaves the secure boundary of the remote system.
|
|
172
|
+
*
|
|
173
|
+
* @generated from enum value: KEY_MODE_REMOTE = 3;
|
|
174
|
+
*/
|
|
175
|
+
REMOTE = 3,
|
|
176
|
+
/**
|
|
177
|
+
* KEY_MODE_PUBLIC_KEY_ONLY: Public key only mode. Used when only a public key is available or required,
|
|
178
|
+
* typically for wrapping operations (e.g., encrypting a Data Encryption Key (DEK) for an external KAS).
|
|
179
|
+
* The corresponding private key is not managed or accessible by this system.
|
|
180
|
+
*
|
|
181
|
+
* @generated from enum value: KEY_MODE_PUBLIC_KEY_ONLY = 4;
|
|
182
|
+
*/
|
|
183
|
+
PUBLIC_KEY_ONLY = 4
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* Describes the enum virtru.policy.KeyMode.
|
|
187
|
+
*/
|
|
188
|
+
export declare const KeyModeSchema: GenEnum<KeyMode>;
|