@opentdf/sdk 0.3.0 → 0.3.2-beta.1

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.
Files changed (227) hide show
  1. package/dist/cjs/src/access/access-fetch.js +155 -0
  2. package/dist/cjs/src/access/access-rpc.js +131 -0
  3. package/dist/cjs/src/access.js +81 -107
  4. package/dist/cjs/src/auth/oidc.js +2 -2
  5. package/dist/cjs/src/nanotdf/Client.js +17 -13
  6. package/dist/cjs/src/nanotdf/models/Header.js +2 -2
  7. package/dist/cjs/src/nanotdf-crypto/keyAgreement.js +2 -2
  8. package/dist/cjs/src/opentdf.js +43 -9
  9. package/dist/cjs/src/platform/authorization/authorization_pb.js +138 -0
  10. package/dist/cjs/src/platform/buf/validate/validate_pb.js +410 -0
  11. package/dist/cjs/src/platform/common/common_pb.js +79 -0
  12. package/dist/cjs/src/platform/entityresolution/entity_resolution_pb.js +49 -0
  13. package/dist/cjs/src/platform/google/api/annotations_pb.js +30 -0
  14. package/dist/cjs/src/platform/google/api/http_pb.js +37 -0
  15. package/dist/cjs/src/platform/kas/kas_pb.js +96 -0
  16. package/dist/cjs/src/platform/policy/actions/actions_pb.js +70 -0
  17. package/dist/cjs/src/platform/policy/attributes/attributes_pb.js +240 -0
  18. package/dist/cjs/src/platform/policy/kasregistry/key_access_server_registry_pb.js +236 -0
  19. package/dist/cjs/src/platform/policy/keymanagement/key_management_pb.js +70 -0
  20. package/dist/cjs/src/platform/policy/namespaces/namespaces_pb.js +121 -0
  21. package/dist/cjs/src/platform/policy/objects_pb.js +395 -0
  22. package/dist/cjs/src/platform/policy/registeredresources/registered_resources_pb.js +132 -0
  23. package/dist/cjs/src/platform/policy/resourcemapping/resource_mapping_pb.js +139 -0
  24. package/dist/cjs/src/platform/policy/selectors_pb.js +67 -0
  25. package/dist/cjs/src/platform/policy/subjectmapping/subject_mapping_pb.js +146 -0
  26. package/dist/cjs/src/platform/policy/unsafe/unsafe_pb.js +124 -0
  27. package/dist/cjs/src/platform/protoc-gen-openapiv2/options/annotations_pb.js +68 -0
  28. package/dist/cjs/src/platform/protoc-gen-openapiv2/options/openapiv2_pb.js +307 -0
  29. package/dist/cjs/src/platform/wellknownconfiguration/wellknown_configuration_pb.js +33 -0
  30. package/dist/cjs/src/platform.js +124 -0
  31. package/dist/cjs/src/policy/api.js +21 -38
  32. package/dist/cjs/src/policy/attributes.js +4 -1
  33. package/dist/cjs/src/policy/granter.js +9 -9
  34. package/dist/cjs/src/utils.js +31 -1
  35. package/dist/cjs/src/version.js +2 -2
  36. package/dist/cjs/tdf3/src/assertions.js +5 -5
  37. package/dist/cjs/tdf3/src/client/index.js +24 -18
  38. package/dist/cjs/tdf3/src/tdf.js +16 -10
  39. package/dist/types/src/access/access-fetch.d.ts +21 -0
  40. package/dist/types/src/access/access-fetch.d.ts.map +1 -0
  41. package/dist/types/src/access/access-rpc.d.ts +22 -0
  42. package/dist/types/src/access/access-rpc.d.ts.map +1 -0
  43. package/dist/types/src/access.d.ts +19 -11
  44. package/dist/types/src/access.d.ts.map +1 -1
  45. package/dist/types/src/nanotdf/Client.d.ts +3 -1
  46. package/dist/types/src/nanotdf/Client.d.ts.map +1 -1
  47. package/dist/types/src/opentdf.d.ts +5 -1
  48. package/dist/types/src/opentdf.d.ts.map +1 -1
  49. package/dist/types/src/platform/authorization/authorization_pb.d.ts +609 -0
  50. package/dist/types/src/platform/authorization/authorization_pb.d.ts.map +1 -0
  51. package/dist/types/src/platform/buf/validate/validate_pb.d.ts +4466 -0
  52. package/dist/types/src/platform/buf/validate/validate_pb.d.ts.map +1 -0
  53. package/dist/types/src/platform/common/common_pb.d.ts +112 -0
  54. package/dist/types/src/platform/common/common_pb.d.ts.map +1 -0
  55. package/dist/types/src/platform/entityresolution/entity_resolution_pb.d.ts +199 -0
  56. package/dist/types/src/platform/entityresolution/entity_resolution_pb.d.ts.map +1 -0
  57. package/dist/types/src/platform/google/api/annotations_pb.d.ts +14 -0
  58. package/dist/types/src/platform/google/api/annotations_pb.d.ts.map +1 -0
  59. package/dist/types/src/platform/google/api/http_pb.d.ts +441 -0
  60. package/dist/types/src/platform/google/api/http_pb.d.ts.map +1 -0
  61. package/dist/types/src/platform/kas/kas_pb.d.ts +404 -0
  62. package/dist/types/src/platform/kas/kas_pb.d.ts.map +1 -0
  63. package/dist/types/src/platform/policy/actions/actions_pb.d.ts +265 -0
  64. package/dist/types/src/platform/policy/actions/actions_pb.d.ts.map +1 -0
  65. package/dist/types/src/platform/policy/attributes/attributes_pb.d.ts +1022 -0
  66. package/dist/types/src/platform/policy/attributes/attributes_pb.d.ts.map +1 -0
  67. package/dist/types/src/platform/policy/kasregistry/key_access_server_registry_pb.d.ts +1306 -0
  68. package/dist/types/src/platform/policy/kasregistry/key_access_server_registry_pb.d.ts.map +1 -0
  69. package/dist/types/src/platform/policy/keymanagement/key_management_pb.d.ts +269 -0
  70. package/dist/types/src/platform/policy/keymanagement/key_management_pb.d.ts.map +1 -0
  71. package/dist/types/src/platform/policy/namespaces/namespaces_pb.d.ts +448 -0
  72. package/dist/types/src/platform/policy/namespaces/namespaces_pb.d.ts.map +1 -0
  73. package/dist/types/src/platform/policy/objects_pb.d.ts +1112 -0
  74. package/dist/types/src/platform/policy/objects_pb.d.ts.map +1 -0
  75. package/dist/types/src/platform/policy/registeredresources/registered_resources_pb.d.ts +539 -0
  76. package/dist/types/src/platform/policy/registeredresources/registered_resources_pb.d.ts.map +1 -0
  77. package/dist/types/src/platform/policy/resourcemapping/resource_mapping_pb.d.ts +558 -0
  78. package/dist/types/src/platform/policy/resourcemapping/resource_mapping_pb.d.ts.map +1 -0
  79. package/dist/types/src/platform/policy/selectors_pb.d.ts +221 -0
  80. package/dist/types/src/platform/policy/selectors_pb.d.ts.map +1 -0
  81. package/dist/types/src/platform/policy/subjectmapping/subject_mapping_pb.d.ts +582 -0
  82. package/dist/types/src/platform/policy/subjectmapping/subject_mapping_pb.d.ts.map +1 -0
  83. package/dist/types/src/platform/policy/unsafe/unsafe_pb.d.ts +513 -0
  84. package/dist/types/src/platform/policy/unsafe/unsafe_pb.d.ts.map +1 -0
  85. package/dist/types/src/platform/protoc-gen-openapiv2/options/annotations_pb.d.ts +62 -0
  86. package/dist/types/src/platform/protoc-gen-openapiv2/options/annotations_pb.d.ts.map +1 -0
  87. package/dist/types/src/platform/protoc-gen-openapiv2/options/openapiv2_pb.d.ts +1441 -0
  88. package/dist/types/src/platform/protoc-gen-openapiv2/options/openapiv2_pb.d.ts.map +1 -0
  89. package/dist/types/src/platform/wellknownconfiguration/wellknown_configuration_pb.d.ts +59 -0
  90. package/dist/types/src/platform/wellknownconfiguration/wellknown_configuration_pb.d.ts.map +1 -0
  91. package/dist/types/src/platform.d.ts +49 -0
  92. package/dist/types/src/platform.d.ts.map +1 -0
  93. package/dist/types/src/policy/api.d.ts +1 -1
  94. package/dist/types/src/policy/api.d.ts.map +1 -1
  95. package/dist/types/src/policy/attributes.d.ts +10 -87
  96. package/dist/types/src/policy/attributes.d.ts.map +1 -1
  97. package/dist/types/src/policy/granter.d.ts.map +1 -1
  98. package/dist/types/src/utils.d.ts +10 -0
  99. package/dist/types/src/utils.d.ts.map +1 -1
  100. package/dist/types/src/version.d.ts +1 -1
  101. package/dist/types/tdf3/src/assertions.d.ts +1 -1
  102. package/dist/types/tdf3/src/assertions.d.ts.map +1 -1
  103. package/dist/types/tdf3/src/client/index.d.ts +8 -3
  104. package/dist/types/tdf3/src/client/index.d.ts.map +1 -1
  105. package/dist/types/tdf3/src/models/manifest.d.ts +1 -1
  106. package/dist/types/tdf3/src/models/manifest.d.ts.map +1 -1
  107. package/dist/types/tdf3/src/tdf.d.ts.map +1 -1
  108. package/dist/web/src/access/access-fetch.js +150 -0
  109. package/dist/web/src/access/access-rpc.js +125 -0
  110. package/dist/web/src/access.js +82 -110
  111. package/dist/web/src/auth/oidc.js +2 -2
  112. package/dist/web/src/nanotdf/Client.js +18 -14
  113. package/dist/web/src/nanotdf/models/Header.js +2 -2
  114. package/dist/web/src/nanotdf-crypto/keyAgreement.js +2 -2
  115. package/dist/web/src/opentdf.js +44 -10
  116. package/dist/web/src/platform/authorization/authorization_pb.js +135 -0
  117. package/dist/web/src/platform/buf/validate/validate_pb.js +407 -0
  118. package/dist/web/src/platform/common/common_pb.js +76 -0
  119. package/dist/web/src/platform/entityresolution/entity_resolution_pb.js +46 -0
  120. package/dist/web/src/platform/google/api/annotations_pb.js +27 -0
  121. package/dist/web/src/platform/google/api/http_pb.js +34 -0
  122. package/dist/web/src/platform/kas/kas_pb.js +93 -0
  123. package/dist/web/src/platform/policy/actions/actions_pb.js +67 -0
  124. package/dist/web/src/platform/policy/attributes/attributes_pb.js +237 -0
  125. package/dist/web/src/platform/policy/kasregistry/key_access_server_registry_pb.js +233 -0
  126. package/dist/web/src/platform/policy/keymanagement/key_management_pb.js +67 -0
  127. package/dist/web/src/platform/policy/namespaces/namespaces_pb.js +118 -0
  128. package/dist/web/src/platform/policy/objects_pb.js +392 -0
  129. package/dist/web/src/platform/policy/registeredresources/registered_resources_pb.js +129 -0
  130. package/dist/web/src/platform/policy/resourcemapping/resource_mapping_pb.js +136 -0
  131. package/dist/web/src/platform/policy/selectors_pb.js +64 -0
  132. package/dist/web/src/platform/policy/subjectmapping/subject_mapping_pb.js +143 -0
  133. package/dist/web/src/platform/policy/unsafe/unsafe_pb.js +121 -0
  134. package/dist/web/src/platform/protoc-gen-openapiv2/options/annotations_pb.js +65 -0
  135. package/dist/web/src/platform/protoc-gen-openapiv2/options/openapiv2_pb.js +304 -0
  136. package/dist/web/src/platform/wellknownconfiguration/wellknown_configuration_pb.js +30 -0
  137. package/dist/web/src/platform.js +87 -0
  138. package/dist/web/src/policy/api.js +23 -40
  139. package/dist/web/src/policy/attributes.js +3 -2
  140. package/dist/web/src/policy/granter.js +9 -9
  141. package/dist/web/src/utils.js +29 -1
  142. package/dist/web/src/version.js +2 -2
  143. package/dist/web/tdf3/src/assertions.js +5 -5
  144. package/dist/web/tdf3/src/client/index.js +26 -20
  145. package/dist/web/tdf3/src/tdf.js +16 -10
  146. package/package.json +17 -1
  147. package/src/access/access-fetch.ts +202 -0
  148. package/src/access/access-rpc.ts +175 -0
  149. package/src/access.ts +113 -138
  150. package/src/auth/oidc.ts +1 -1
  151. package/src/nanotdf/Client.ts +28 -18
  152. package/src/nanotdf/models/Header.ts +1 -1
  153. package/src/nanotdf-crypto/keyAgreement.ts +1 -1
  154. package/src/opentdf.ts +67 -11
  155. package/src/platform/authorization/authorization_pb.ts +689 -0
  156. package/src/platform/buf/validate/validate_pb.ts +4626 -0
  157. package/src/platform/common/common_pb.ts +135 -0
  158. package/src/platform/entityresolution/entity_resolution_pb.ts +233 -0
  159. package/src/platform/google/api/annotations_pb.ts +39 -0
  160. package/src/platform/google/api/http_pb.ts +474 -0
  161. package/src/platform/kas/kas_pb.ts +484 -0
  162. package/src/platform/policy/actions/actions_pb.ts +312 -0
  163. package/src/platform/policy/attributes/attributes_pb.ts +1181 -0
  164. package/src/platform/policy/kasregistry/key_access_server_registry_pb.ts +1482 -0
  165. package/src/platform/policy/keymanagement/key_management_pb.ts +316 -0
  166. package/src/platform/policy/namespaces/namespaces_pb.ts +528 -0
  167. package/src/platform/policy/objects_pb.ts +1319 -0
  168. package/src/platform/policy/registeredresources/registered_resources_pb.ts +623 -0
  169. package/src/platform/policy/resourcemapping/resource_mapping_pb.ts +658 -0
  170. package/src/platform/policy/selectors_pb.ts +277 -0
  171. package/src/platform/policy/subjectmapping/subject_mapping_pb.ts +687 -0
  172. package/src/platform/policy/unsafe/unsafe_pb.ts +593 -0
  173. package/src/platform/protoc-gen-openapiv2/options/annotations_pb.ts +83 -0
  174. package/src/platform/protoc-gen-openapiv2/options/openapiv2_pb.ts +1615 -0
  175. package/src/platform/wellknownconfiguration/wellknown_configuration_pb.ts +78 -0
  176. package/src/platform.ts +122 -0
  177. package/src/policy/api.ts +29 -42
  178. package/src/policy/attributes.ts +12 -108
  179. package/src/policy/granter.ts +7 -8
  180. package/src/utils.ts +30 -0
  181. package/src/version.ts +1 -1
  182. package/tdf3/src/assertions.ts +4 -4
  183. package/tdf3/src/client/index.ts +42 -19
  184. package/tdf3/src/models/manifest.ts +2 -1
  185. package/tdf3/src/tdf.ts +25 -16
  186. package/src/platform/authorization/authorization_connect.d.ts +0 -44
  187. package/src/platform/authorization/authorization_connect.js +0 -44
  188. package/src/platform/authorization/authorization_pb.d.ts +0 -707
  189. package/src/platform/authorization/authorization_pb.js +0 -372
  190. package/src/platform/common/common_pb.d.ts +0 -129
  191. package/src/platform/common/common_pb.js +0 -58
  192. package/src/platform/entityresolution/entity_resolution_connect.d.ts +0 -35
  193. package/src/platform/entityresolution/entity_resolution_connect.js +0 -35
  194. package/src/platform/entityresolution/entity_resolution_pb.d.ts +0 -242
  195. package/src/platform/entityresolution/entity_resolution_pb.js +0 -139
  196. package/src/platform/kas/kas_connect.d.ts +0 -59
  197. package/src/platform/kas/kas_connect.js +0 -59
  198. package/src/platform/kas/kas_pb.d.ts +0 -200
  199. package/src/platform/kas/kas_pb.js +0 -84
  200. package/src/platform/policy/attributes/attributes_connect.d.ts +0 -168
  201. package/src/platform/policy/attributes/attributes_connect.js +0 -168
  202. package/src/platform/policy/attributes/attributes_pb.d.ts +0 -929
  203. package/src/platform/policy/attributes/attributes_pb.js +0 -363
  204. package/src/platform/policy/kasregistry/key_access_server_registry_connect.d.ts +0 -62
  205. package/src/platform/policy/kasregistry/key_access_server_registry_connect.js +0 -62
  206. package/src/platform/policy/kasregistry/key_access_server_registry_pb.d.ts +0 -283
  207. package/src/platform/policy/kasregistry/key_access_server_registry_pb.js +0 -113
  208. package/src/platform/policy/namespaces/namespaces_connect.d.ts +0 -62
  209. package/src/platform/policy/namespaces/namespaces_connect.js +0 -62
  210. package/src/platform/policy/namespaces/namespaces_pb.d.ts +0 -270
  211. package/src/platform/policy/namespaces/namespaces_pb.js +0 -110
  212. package/src/platform/policy/objects_pb.d.ts +0 -725
  213. package/src/platform/policy/objects_pb.js +0 -288
  214. package/src/platform/policy/resourcemapping/resource_mapping_connect.d.ts +0 -259
  215. package/src/platform/policy/resourcemapping/resource_mapping_connect.js +0 -259
  216. package/src/platform/policy/resourcemapping/resource_mapping_pb.d.ts +0 -314
  217. package/src/platform/policy/resourcemapping/resource_mapping_pb.js +0 -142
  218. package/src/platform/policy/selectors_pb.d.ts +0 -269
  219. package/src/platform/policy/selectors_pb.js +0 -110
  220. package/src/platform/policy/subjectmapping/subject_mapping_connect.d.ts +0 -118
  221. package/src/platform/policy/subjectmapping/subject_mapping_connect.js +0 -118
  222. package/src/platform/policy/subjectmapping/subject_mapping_pb.d.ts +0 -672
  223. package/src/platform/policy/subjectmapping/subject_mapping_pb.js +0 -260
  224. package/src/platform/wellknownconfiguration/wellknown_configuration_connect.d.ts +0 -26
  225. package/src/platform/wellknownconfiguration/wellknown_configuration_connect.js +0 -26
  226. package/src/platform/wellknownconfiguration/wellknown_configuration_pb.d.ts +0 -75
  227. package/src/platform/wellknownconfiguration/wellknown_configuration_pb.js +0 -35
@@ -1,288 +0,0 @@
1
- // @generated by protoc-gen-es v1.9.0 with parameter "target=js+dts,import_extension=none"
2
- // @generated from file policy/objects.proto (package policy, syntax proto3)
3
- /* eslint-disable */
4
- // @ts-nocheck
5
-
6
- import { BoolValue, proto3 } from "@bufbuild/protobuf";
7
- import { Metadata } from "../common/common_pb";
8
-
9
- /**
10
- * buflint ENUM_VALUE_PREFIX: to make sure that C++ scoping rules aren't violated when users add new enum values to an enum in a given package
11
- *
12
- * @generated from enum policy.AttributeRuleTypeEnum
13
- */
14
- export const AttributeRuleTypeEnum = /*@__PURE__*/ proto3.makeEnum(
15
- "policy.AttributeRuleTypeEnum",
16
- [
17
- {no: 0, name: "ATTRIBUTE_RULE_TYPE_ENUM_UNSPECIFIED", localName: "UNSPECIFIED"},
18
- {no: 1, name: "ATTRIBUTE_RULE_TYPE_ENUM_ALL_OF", localName: "ALL_OF"},
19
- {no: 2, name: "ATTRIBUTE_RULE_TYPE_ENUM_ANY_OF", localName: "ANY_OF"},
20
- {no: 3, name: "ATTRIBUTE_RULE_TYPE_ENUM_HIERARCHY", localName: "HIERARCHY"},
21
- ],
22
- );
23
-
24
- /**
25
- * buflint ENUM_VALUE_PREFIX: to make sure that C++ scoping rules aren't violated when users add new enum values to an enum in a given package
26
- *
27
- * @generated from enum policy.SubjectMappingOperatorEnum
28
- */
29
- export const SubjectMappingOperatorEnum = /*@__PURE__*/ proto3.makeEnum(
30
- "policy.SubjectMappingOperatorEnum",
31
- [
32
- {no: 0, name: "SUBJECT_MAPPING_OPERATOR_ENUM_UNSPECIFIED", localName: "UNSPECIFIED"},
33
- {no: 1, name: "SUBJECT_MAPPING_OPERATOR_ENUM_IN", localName: "IN"},
34
- {no: 2, name: "SUBJECT_MAPPING_OPERATOR_ENUM_NOT_IN", localName: "NOT_IN"},
35
- ],
36
- );
37
-
38
- /**
39
- * buflint ENUM_VALUE_PREFIX: to make sure that C++ scoping rules aren't violated when users add new enum values to an enum in a given package
40
- *
41
- * @generated from enum policy.ConditionBooleanTypeEnum
42
- */
43
- export const ConditionBooleanTypeEnum = /*@__PURE__*/ proto3.makeEnum(
44
- "policy.ConditionBooleanTypeEnum",
45
- [
46
- {no: 0, name: "CONDITION_BOOLEAN_TYPE_ENUM_UNSPECIFIED", localName: "UNSPECIFIED"},
47
- {no: 1, name: "CONDITION_BOOLEAN_TYPE_ENUM_AND", localName: "AND"},
48
- {no: 2, name: "CONDITION_BOOLEAN_TYPE_ENUM_OR", localName: "OR"},
49
- ],
50
- );
51
-
52
- /**
53
- * @generated from message policy.Namespace
54
- */
55
- export const Namespace = /*@__PURE__*/ proto3.makeMessageType(
56
- "policy.Namespace",
57
- () => [
58
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
59
- { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
60
- { no: 3, name: "fqn", kind: "scalar", T: 9 /* ScalarType.STRING */ },
61
- { no: 4, name: "active", kind: "message", T: BoolValue },
62
- { no: 5, name: "metadata", kind: "message", T: Metadata },
63
- ],
64
- );
65
-
66
- /**
67
- * @generated from message policy.Attribute
68
- */
69
- export const Attribute = /*@__PURE__*/ proto3.makeMessageType(
70
- "policy.Attribute",
71
- () => [
72
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
73
- { no: 2, name: "namespace", kind: "message", T: Namespace },
74
- { no: 3, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
75
- { no: 4, name: "rule", kind: "enum", T: proto3.getEnumType(AttributeRuleTypeEnum) },
76
- { no: 5, name: "values", kind: "message", T: Value, repeated: true },
77
- { no: 6, name: "grants", kind: "message", T: KeyAccessServer, repeated: true },
78
- { no: 7, name: "fqn", kind: "scalar", T: 9 /* ScalarType.STRING */ },
79
- { no: 8, name: "active", kind: "message", T: BoolValue },
80
- { no: 100, name: "metadata", kind: "message", T: Metadata },
81
- ],
82
- );
83
-
84
- /**
85
- * @generated from message policy.Value
86
- */
87
- export const Value = /*@__PURE__*/ proto3.makeMessageType(
88
- "policy.Value",
89
- () => [
90
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
91
- { no: 2, name: "attribute", kind: "message", T: Attribute },
92
- { no: 3, name: "value", kind: "scalar", T: 9 /* ScalarType.STRING */ },
93
- { no: 4, name: "members", kind: "message", T: Value, repeated: true },
94
- { no: 5, name: "grants", kind: "message", T: KeyAccessServer, repeated: true },
95
- { no: 6, name: "fqn", kind: "scalar", T: 9 /* ScalarType.STRING */ },
96
- { no: 7, name: "active", kind: "message", T: BoolValue },
97
- { no: 8, name: "subject_mappings", kind: "message", T: SubjectMapping, repeated: true },
98
- { no: 100, name: "metadata", kind: "message", T: Metadata },
99
- ],
100
- );
101
-
102
- /**
103
- * An action an entity can take
104
- *
105
- * @generated from message policy.Action
106
- */
107
- export const Action = /*@__PURE__*/ proto3.makeMessageType(
108
- "policy.Action",
109
- () => [
110
- { no: 1, name: "standard", kind: "enum", T: proto3.getEnumType(Action_StandardAction), oneof: "value" },
111
- { no: 2, name: "custom", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "value" },
112
- ],
113
- );
114
-
115
- /**
116
- * Standard actions supported by the platform
117
- *
118
- * @generated from enum policy.Action.StandardAction
119
- */
120
- export const Action_StandardAction = /*@__PURE__*/ proto3.makeEnum(
121
- "policy.Action.StandardAction",
122
- [
123
- {no: 0, name: "STANDARD_ACTION_UNSPECIFIED", localName: "UNSPECIFIED"},
124
- {no: 1, name: "STANDARD_ACTION_DECRYPT", localName: "DECRYPT"},
125
- {no: 2, name: "STANDARD_ACTION_TRANSMIT", localName: "TRANSMIT"},
126
- ],
127
- );
128
-
129
- /**
130
- *
131
- * Subject Mapping: A Policy assigning Subject Set(s) to a permitted attribute value + action(s) combination
132
- *
133
- * Example: Subjects in sets 1 and 2 are entitled attribute value http://wwww.example.org/attr/example/value/one
134
- * with permitted actions TRANSMIT and DECRYPT
135
- * {
136
- * "id": "someid",
137
- * "attribute_value": {example_one_attribute_value...},
138
- * "subject_condition_set": {"subject_sets":[{subject_set_1},{subject_set_2}]...},
139
- * "actions": [{"standard": "STANDARD_ACTION_DECRYPT"}", {"standard": "STANDARD_ACTION_TRANSMIT"}]
140
- * }
141
- *
142
- * @generated from message policy.SubjectMapping
143
- */
144
- export const SubjectMapping = /*@__PURE__*/ proto3.makeMessageType(
145
- "policy.SubjectMapping",
146
- () => [
147
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
148
- { no: 2, name: "attribute_value", kind: "message", T: Value },
149
- { no: 3, name: "subject_condition_set", kind: "message", T: SubjectConditionSet },
150
- { no: 4, name: "actions", kind: "message", T: Action, repeated: true },
151
- { no: 100, name: "metadata", kind: "message", T: Metadata },
152
- ],
153
- );
154
-
155
- /**
156
- * *
157
- * A Condition defines a rule of <the value at the flattened 'selector value' location> <operator> <subject external values>
158
- *
159
- * Example: Subjects with a field selected by the flattened selector "'.division'" and a value of "Accounting" or "Marketing":
160
- * {
161
- * "subject_external_selector_value": "'.division'",
162
- * "operator": "SUBJECT_MAPPING_OPERATOR_ENUM_IN",
163
- * "subject_external_values" : ["Accounting", "Marketing"]
164
- * }
165
- *
166
- * Example: Subjects that are not part of the Fantastic Four according to their alias field:
167
- * {
168
- * "subject_external_selector_value": "'.data[0].alias'",
169
- * "operator": "SUBJECT_MAPPING_OPERATOR_ENUM_NOT_IN",
170
- * "subject_external_values" : ["mister_fantastic", "the_thing", "human_torch", "invisible_woman"]
171
- * }
172
- *
173
- * @generated from message policy.Condition
174
- */
175
- export const Condition = /*@__PURE__*/ proto3.makeMessageType(
176
- "policy.Condition",
177
- () => [
178
- { no: 1, name: "subject_external_selector_value", kind: "scalar", T: 9 /* ScalarType.STRING */ },
179
- { no: 2, name: "operator", kind: "enum", T: proto3.getEnumType(SubjectMappingOperatorEnum) },
180
- { no: 3, name: "subject_external_values", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
181
- ],
182
- );
183
-
184
- /**
185
- * A collection of Conditions evaluated by the boolean_operator provided
186
- *
187
- * @generated from message policy.ConditionGroup
188
- */
189
- export const ConditionGroup = /*@__PURE__*/ proto3.makeMessageType(
190
- "policy.ConditionGroup",
191
- () => [
192
- { no: 1, name: "conditions", kind: "message", T: Condition, repeated: true },
193
- { no: 2, name: "boolean_operator", kind: "enum", T: proto3.getEnumType(ConditionBooleanTypeEnum) },
194
- ],
195
- );
196
-
197
- /**
198
- * A collection of Condition Groups
199
- *
200
- * @generated from message policy.SubjectSet
201
- */
202
- export const SubjectSet = /*@__PURE__*/ proto3.makeMessageType(
203
- "policy.SubjectSet",
204
- () => [
205
- { no: 1, name: "condition_groups", kind: "message", T: ConditionGroup, repeated: true },
206
- ],
207
- );
208
-
209
- /**
210
- *
211
- * A container for multiple Subject Sets, each containing Condition Groups, each containing Conditions. Multiple Subject Sets in a SubjectConditionSet
212
- * are evaluated with AND logic. As each Subject Mapping has only one Attribute Value, the SubjectConditionSet is reusable across multiple
213
- * Subject Mappings / Attribute Values and is an independent unit.
214
- *
215
- * @generated from message policy.SubjectConditionSet
216
- */
217
- export const SubjectConditionSet = /*@__PURE__*/ proto3.makeMessageType(
218
- "policy.SubjectConditionSet",
219
- () => [
220
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
221
- { no: 3, name: "subject_sets", kind: "message", T: SubjectSet, repeated: true },
222
- { no: 100, name: "metadata", kind: "message", T: Metadata },
223
- ],
224
- );
225
-
226
- /**
227
- *
228
- *
229
- * A property of a Subject/Entity as its selector expression -> value result pair. This would mirror external user attributes retrieved
230
- * from an authoritative source such as an IDP (Identity Provider) or User Store. Examples include such ADFS/LDAP, OKTA, etc.
231
- * For now, a valid property must contain both a selector expression & a resulting value.
232
- *
233
- * The external_selector_value is a specifier to select a value from a flattened external representation of an Entity (such as from idP/LDAP),
234
- * and the external_value is the value selected by the external_selector_value on that Entity Representation (Subject Context). These mirror the Condition.
235
- *
236
- * @generated from message policy.SubjectProperty
237
- */
238
- export const SubjectProperty = /*@__PURE__*/ proto3.makeMessageType(
239
- "policy.SubjectProperty",
240
- () => [
241
- { no: 1, name: "external_selector_value", kind: "scalar", T: 9 /* ScalarType.STRING */ },
242
- { no: 2, name: "external_value", kind: "scalar", T: 9 /* ScalarType.STRING */ },
243
- ],
244
- );
245
-
246
- /**
247
- *
248
- * Resource Mappings (aka Access Control Resource Encodings aka ACRE) are structures supporting the mapping of Resources and Attribute Values
249
- *
250
- * @generated from message policy.ResourceMapping
251
- */
252
- export const ResourceMapping = /*@__PURE__*/ proto3.makeMessageType(
253
- "policy.ResourceMapping",
254
- () => [
255
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
256
- { no: 2, name: "metadata", kind: "message", T: Metadata },
257
- { no: 3, name: "attribute_value", kind: "message", T: Value },
258
- { no: 4, name: "terms", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
259
- ],
260
- );
261
-
262
- /**
263
- *
264
- * Key Access Server Registry
265
- *
266
- * @generated from message policy.KeyAccessServer
267
- */
268
- export const KeyAccessServer = /*@__PURE__*/ proto3.makeMessageType(
269
- "policy.KeyAccessServer",
270
- () => [
271
- { no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
272
- { no: 2, name: "uri", kind: "scalar", T: 9 /* ScalarType.STRING */ },
273
- { no: 3, name: "public_key", kind: "message", T: PublicKey },
274
- { no: 100, name: "metadata", kind: "message", T: Metadata },
275
- ],
276
- );
277
-
278
- /**
279
- * @generated from message policy.PublicKey
280
- */
281
- export const PublicKey = /*@__PURE__*/ proto3.makeMessageType(
282
- "policy.PublicKey",
283
- () => [
284
- { no: 1, name: "remote", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "public_key" },
285
- { no: 2, name: "local", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "public_key" },
286
- ],
287
- );
288
-
@@ -1,259 +0,0 @@
1
- // @generated by protoc-gen-connect-es v1.4.0 with parameter "target=js+dts,import_extension=none"
2
- // @generated from file policy/resourcemapping/resource_mapping.proto (package policy.resourcemapping, syntax proto3)
3
- /* eslint-disable */
4
- // @ts-nocheck
5
-
6
- import { CreateResourceMappingRequest, CreateResourceMappingResponse, DeleteResourceMappingRequest, DeleteResourceMappingResponse, GetResourceMappingRequest, GetResourceMappingResponse, ListResourceMappingsRequest, ListResourceMappingsResponse, UpdateResourceMappingRequest, UpdateResourceMappingResponse } from "./resource_mapping_pb";
7
- import { MethodKind } from "@bufbuild/protobuf";
8
-
9
- /**
10
- *
11
- * Resource Mappings
12
- *
13
- * @generated from service policy.resourcemapping.ResourceMappingService
14
- */
15
- export declare const ResourceMappingService: {
16
- readonly typeName: "policy.resourcemapping.ResourceMappingService",
17
- readonly methods: {
18
- /**
19
- *
20
- * Request Example:
21
- * - empty body
22
- *
23
- * Response Example:
24
- * {
25
- * "resource_mappings": [
26
- * {
27
- * "terms": [
28
- * "TOPSECRET",
29
- * "TS",
30
- * ],
31
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e",
32
- * "metadata": {
33
- * "labels": [],
34
- * "created_at": {
35
- * "seconds": "1706103276",
36
- * "nanos": 510718000
37
- * },
38
- * "updated_at": {
39
- * "seconds": "1706107873",
40
- * "nanos": 399786000
41
- * },
42
- * "description": ""
43
- * },
44
- * "attribute_value": {
45
- * "members": [],
46
- * "id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
47
- * "metadata": null,
48
- * "attribute_id": "",
49
- * "value": "value1"
50
- * }
51
- * }
52
- * ]
53
- * }
54
- *
55
- * @generated from rpc policy.resourcemapping.ResourceMappingService.ListResourceMappings
56
- */
57
- readonly listResourceMappings: {
58
- readonly name: "ListResourceMappings",
59
- readonly I: typeof ListResourceMappingsRequest,
60
- readonly O: typeof ListResourceMappingsResponse,
61
- readonly kind: MethodKind.Unary,
62
- },
63
- /**
64
- *
65
- * Request Example:
66
- * {
67
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e"
68
- * }
69
- *
70
- * Response Example:
71
- * {
72
- * "resource_mapping": {
73
- * "terms": [
74
- * "TOPSECRET",
75
- * "TS",
76
- * ],
77
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e",
78
- * "metadata": {
79
- * "labels": [],
80
- * "created_at": {
81
- * "seconds": "1706103276",
82
- * "nanos": 510718000
83
- * },
84
- * "updated_at": {
85
- * "seconds": "1706107873",
86
- * "nanos": 399786000
87
- * },
88
- * "description": ""
89
- * },
90
- * "attribute_value": {
91
- * "members": [],
92
- * "id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
93
- * "metadata": null,
94
- * "attribute_id": "",
95
- * "value": "value1"
96
- * }
97
- * }
98
- * }
99
- *
100
- * @generated from rpc policy.resourcemapping.ResourceMappingService.GetResourceMapping
101
- */
102
- readonly getResourceMapping: {
103
- readonly name: "GetResourceMapping",
104
- readonly I: typeof GetResourceMappingRequest,
105
- readonly O: typeof GetResourceMappingResponse,
106
- readonly kind: MethodKind.Unary,
107
- },
108
- /**
109
- *
110
- * Request Example:
111
- * {
112
- * "resource_mapping": {
113
- * "attribute_value_id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
114
- * "terms": [
115
- * "TOPSECRET",
116
- * "TS",
117
- * ]
118
- * }
119
- * }
120
- *
121
- * Response Example:
122
- * {
123
- * "resource_mapping": {
124
- * "terms": [
125
- * "TOPSECRET",
126
- * "TS",
127
- * ],
128
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e",
129
- * "metadata": {
130
- * "labels": [],
131
- * "created_at": {
132
- * "seconds": "1706103276",
133
- * "nanos": 510718000
134
- * },
135
- * "updated_at": {
136
- * "seconds": "1706107873",
137
- * "nanos": 399786000
138
- * },
139
- * "description": ""
140
- * },
141
- * "attribute_value": {
142
- * "members": [],
143
- * "id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
144
- * "metadata": null,
145
- * "attribute_id": "",
146
- * "value": "value1"
147
- * }
148
- * }
149
- * }
150
- *
151
- * @generated from rpc policy.resourcemapping.ResourceMappingService.CreateResourceMapping
152
- */
153
- readonly createResourceMapping: {
154
- readonly name: "CreateResourceMapping",
155
- readonly I: typeof CreateResourceMappingRequest,
156
- readonly O: typeof CreateResourceMappingResponse,
157
- readonly kind: MethodKind.Unary,
158
- },
159
- /**
160
- *
161
- * Request Example:
162
- * {
163
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e",
164
- * "resource_mapping": {
165
- * "attribute_value_id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
166
- * "terms": [
167
- * "TOPSECRET",
168
- * "TS",
169
- * "NEWTERM"
170
- * ]
171
- * }
172
- * }
173
- *
174
- * Response Example:
175
- * {
176
- * "resource_mapping": {
177
- * "terms": [
178
- * "TOPSECRET",
179
- * "TS",
180
- * ],
181
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e",
182
- * "metadata": {
183
- * "labels": [],
184
- * "created_at": {
185
- * "seconds": "1706103276",
186
- * "nanos": 510718000
187
- * },
188
- * "updated_at": {
189
- * "seconds": "1706107873",
190
- * "nanos": 399786000
191
- * },
192
- * "description": ""
193
- * },
194
- * "attribute_value": {
195
- * "members": [],
196
- * "id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
197
- * "metadata": null,
198
- * "attribute_id": "",
199
- * "value": "value1"
200
- * }
201
- * }
202
- * }
203
- *
204
- * @generated from rpc policy.resourcemapping.ResourceMappingService.UpdateResourceMapping
205
- */
206
- readonly updateResourceMapping: {
207
- readonly name: "UpdateResourceMapping",
208
- readonly I: typeof UpdateResourceMappingRequest,
209
- readonly O: typeof UpdateResourceMappingResponse,
210
- readonly kind: MethodKind.Unary,
211
- },
212
- /**
213
- *
214
- * Request Example:
215
- * {
216
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e"
217
- * }
218
- *
219
- * Response Example:
220
- * {
221
- * "resource_mapping": {
222
- * "terms": [
223
- * "TOPSECRET",
224
- * "TS",
225
- * ],
226
- * "id": "3c649464-95b4-4fe0-a09c-ca4b1fecbb0e",
227
- * "metadata": {
228
- * "labels": [],
229
- * "created_at": {
230
- * "seconds": "1706103276",
231
- * "nanos": 510718000
232
- * },
233
- * "updated_at": {
234
- * "seconds": "1706107873",
235
- * "nanos": 399786000
236
- * },
237
- * "description": ""
238
- * },
239
- * "attribute_value": {
240
- * "members": [],
241
- * "id": "f0d1d4f6-bff9-45fd-8170-607b6b559349",
242
- * "metadata": null,
243
- * "attribute_id": "",
244
- * "value": "value1"
245
- * }
246
- * }
247
- * }
248
- *
249
- * @generated from rpc policy.resourcemapping.ResourceMappingService.DeleteResourceMapping
250
- */
251
- readonly deleteResourceMapping: {
252
- readonly name: "DeleteResourceMapping",
253
- readonly I: typeof DeleteResourceMappingRequest,
254
- readonly O: typeof DeleteResourceMappingResponse,
255
- readonly kind: MethodKind.Unary,
256
- },
257
- }
258
- };
259
-