tibet-sam 0.1.0__tar.gz

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.
@@ -0,0 +1,21 @@
1
+ {
2
+ "package": "tibet-sam",
3
+ "description": "Sealed Authority Module — bounded authority capsules for gateway execution and sealed receipts",
4
+ "registries": {
5
+ "pypi": {
6
+ "url": "https://pypi.org/project/tibet-sam/",
7
+ "version": "0.1.0",
8
+ "deprecated": false
9
+ },
10
+ "github": {
11
+ "url": "https://github.com/Humotica/tibet-sam",
12
+ "remote": "https://github.com/Humotica/tibet-sam.git"
13
+ }
14
+ },
15
+ "publish": {
16
+ "pypi": {
17
+ "command": "cd /srv/jtel-stack/packages/tibet-sam && python -m build && twine upload dist/*",
18
+ "auth": "~/.pypirc [pypi] token"
19
+ }
20
+ }
21
+ }
@@ -0,0 +1,210 @@
1
+ Metadata-Version: 2.4
2
+ Name: tibet-sam
3
+ Version: 0.1.0
4
+ Summary: Sealed Authority Module — intent-bound scoped authority capsules for bounded gateway execution
5
+ Project-URL: Homepage, https://humotica.com
6
+ Project-URL: Repository, https://github.com/Humotica/tibet-sam
7
+ Project-URL: TIBET Ecosystem, https://pypi.org/project/tibet/
8
+ Project-URL: Semantic Surface Manifest, https://datatracker.ietf.org/doc/draft-vandemeent-tibet-semantic-surface-manifest/
9
+ Author-email: Jasper van de Meent <info@humotica.com>, Root AI <root_idd@humotica.nl>, Codex <codex@humotica.nl>
10
+ License-Expression: MIT
11
+ Keywords: authority,bounded-execution,capability,cbom,continuity,gateway,sam,sealed,secret-custody,tibet
12
+ Classifier: Development Status :: 4 - Beta
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Intended Audience :: Information Technology
15
+ Classifier: Intended Audience :: System Administrators
16
+ Classifier: License :: OSI Approved :: MIT License
17
+ Classifier: Operating System :: OS Independent
18
+ Classifier: Programming Language :: Python :: 3
19
+ Classifier: Programming Language :: Python :: 3.10
20
+ Classifier: Programming Language :: Python :: 3.11
21
+ Classifier: Programming Language :: Python :: 3.12
22
+ Classifier: Programming Language :: Python :: 3.13
23
+ Classifier: Topic :: Security :: Cryptography
24
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
25
+ Requires-Python: >=3.10
26
+ Requires-Dist: cryptography>=42.0
27
+ Requires-Dist: tibet-drop>=0.3.0
28
+ Provides-Extra: cbom
29
+ Requires-Dist: tibet-cbom>=0.1.1; extra == 'cbom'
30
+ Provides-Extra: dev
31
+ Requires-Dist: pytest>=8.0; extra == 'dev'
32
+ Description-Content-Type: text/markdown
33
+
34
+ # tibet-sam
35
+
36
+ **Sealed Authority Module.**
37
+
38
+ `tibet-sam` is the bounded-authority primitive in the TIBET four-W
39
+ family:
40
+
41
+ - `tibet-vault` = **WHEN**
42
+ - `tibet-keychain` = **WHERE/HOW**
43
+ - `tibet-sam` = **WHY**
44
+ - `tibet-gateway` = **WHERE-EXEC**
45
+
46
+ The point of SAM is simple:
47
+
48
+ - authorize one bounded act
49
+ - without releasing the underlying secret to the caller
50
+
51
+ ## Core shape
52
+
53
+ An agent does not receive a raw API key.
54
+
55
+ Instead it asks for a sealed authority module that says:
56
+
57
+ - which intent is allowed
58
+ - against which target action
59
+ - with which scope constraints
60
+ - until when
61
+ - under which ephemeral session id
62
+
63
+ The gateway then:
64
+
65
+ 1. breaks seal inside the boundary
66
+ 2. validates manifest constraints
67
+ 3. executes the allowed upstream action
68
+ 4. destroys the ephemeral session
69
+ 5. emits a provenance-sealed response
70
+
71
+ ## Sandbox scope
72
+
73
+ This sketch now emits a real sealed `.tza` capsule, lets a local
74
+ gateway runtime read that capsule directly, and emits a sealed gateway
75
+ receipt back out.
76
+
77
+ It provides:
78
+
79
+ - package shape
80
+ - SAM types
81
+ - inspect and verify surfaces
82
+ - materialization payload shape
83
+ - sealed `.tza` materialization
84
+ - local gateway runtime for break-seal, validate, execute, destroy
85
+ - sealed gateway receipt shape
86
+ - human and JSON rendering
87
+ - a small CLI to inspect the model
88
+
89
+ ## Commands
90
+
91
+ ```bash
92
+ tibet-sam info
93
+ tibet-sam types
94
+ tibet-sam runtime
95
+ tibet-sam inspect /tmp/upload-pypi-v4.sam.tza
96
+ tibet-sam verify /tmp/upload-pypi-v4.sam.tza
97
+ tibet-sam materialize \
98
+ --intent upload_package \
99
+ --secret-id sec_pypi_001 \
100
+ --target-action /upload/pypi \
101
+ --actor-id jis:humotica:agent.ai \
102
+ --constraint package=tibet-zip \
103
+ --constraint registry=pypi \
104
+ --valid-for-seconds 300 \
105
+ --json
106
+
107
+ tibet-sam materialize \
108
+ --intent upload_package \
109
+ --secret-id sec_pypi_001 \
110
+ --target-action /upload/pypi \
111
+ --actor-id jis:humotica:agent.ai \
112
+ --constraint package=tibet-zip \
113
+ --constraint registry=pypi \
114
+ --identity-dir /tmp/sam-identity \
115
+ --emit-bundle /tmp/upload-pypi.sam.tza \
116
+ --json
117
+
118
+ tibet-sam execute \
119
+ --sam-file /tmp/upload-pypi.sam.tza \
120
+ --requested-action /upload/pypi \
121
+ --request-actor jis:humotica:agent.ai \
122
+ --gateway-actor jis:humotica:tibet-gateway \
123
+ --gateway-identity-dir /tmp/gateway-identity \
124
+ --response-bundle /tmp/upload-pypi.sam-receipt.tza \
125
+ --constraint package=tibet-zip \
126
+ --constraint registry=pypi \
127
+ --json
128
+ ```
129
+
130
+ Example SAM payload:
131
+
132
+ - [examples/sam-upload-pypi.json](/srv/jtel-stack/sandbox/ai/codex/tibet-sam-sketch/examples/sam-upload-pypi.json:1)
133
+
134
+ ## Denied Paths
135
+
136
+ The package should be able to show why a capsule is denied, not only
137
+ why a capsule is accepted.
138
+
139
+ Typical denied cases:
140
+
141
+ - actor mismatch
142
+ - expired SAM
143
+ - constraint mismatch
144
+
145
+ Example:
146
+
147
+ ```bash
148
+ tibet-sam execute \
149
+ --sam-file /tmp/upload-pypi-v4.sam.tza \
150
+ --requested-action /upload/pypi \
151
+ --request-actor jis:humotica:wrong.actor \
152
+ --gateway-actor webshop.admin \
153
+ --constraint package=tibet-zip \
154
+ --constraint registry=pypi \
155
+ --json
156
+ ```
157
+
158
+ And for a structural check:
159
+
160
+ ```bash
161
+ tibet-sam verify /tmp/upload-pypi-v4.sam.tza --json
162
+ ```
163
+
164
+ ## Current Runtime Boundary
165
+
166
+ The current sandbox runtime already performs the bounded flow:
167
+
168
+ 1. break seal inside the gateway boundary
169
+ 2. validate actor, target action, and constraints
170
+ 3. open an ephemeral gateway session
171
+ 4. proxy secret use through a local runtime adapter
172
+ 5. destroy the session
173
+ 6. emit a sealed receipt
174
+
175
+ Current local adapters:
176
+
177
+ - `upload_package` to `/upload/pypi`
178
+ - a generic bounded fallback executor for other intents
179
+
180
+ This is enough to prove the runtime shape end-to-end.
181
+ What still remains for production is not the authority flow itself, but
182
+ real upstream adapters inside the actual `tibet-gateway` package.
183
+
184
+ ## Release Notes For Package Lift
185
+
186
+ This sandbox is now mature enough for a lift into `/packages/tibet-sam`
187
+ because it already proves:
188
+
189
+ - sealed authority materialization
190
+ - direct `.tza` execution path
191
+ - explicit session lifecycle
192
+ - sealed receipt emission
193
+ - inspect and verify operator surfaces
194
+
195
+ What is still production-later:
196
+
197
+ - real upstream adapters inside `tibet-gateway`
198
+ - real external secret backends behind `tibet-keychain`
199
+ - richer policy lanes and revocation handling
200
+
201
+ ## Intended next steps
202
+
203
+ - move the sandbox runtime shape into real `tibet-gateway` boundary hooks
204
+ - deepen destroy-session semantics around real external adapters
205
+ - link to `tibet-keychain` custody records
206
+
207
+ ## Short formulation
208
+
209
+ SAM authorizes the right to perform one bounded act, without
210
+ releasing the underlying secret.
@@ -0,0 +1,177 @@
1
+ # tibet-sam
2
+
3
+ **Sealed Authority Module.**
4
+
5
+ `tibet-sam` is the bounded-authority primitive in the TIBET four-W
6
+ family:
7
+
8
+ - `tibet-vault` = **WHEN**
9
+ - `tibet-keychain` = **WHERE/HOW**
10
+ - `tibet-sam` = **WHY**
11
+ - `tibet-gateway` = **WHERE-EXEC**
12
+
13
+ The point of SAM is simple:
14
+
15
+ - authorize one bounded act
16
+ - without releasing the underlying secret to the caller
17
+
18
+ ## Core shape
19
+
20
+ An agent does not receive a raw API key.
21
+
22
+ Instead it asks for a sealed authority module that says:
23
+
24
+ - which intent is allowed
25
+ - against which target action
26
+ - with which scope constraints
27
+ - until when
28
+ - under which ephemeral session id
29
+
30
+ The gateway then:
31
+
32
+ 1. breaks seal inside the boundary
33
+ 2. validates manifest constraints
34
+ 3. executes the allowed upstream action
35
+ 4. destroys the ephemeral session
36
+ 5. emits a provenance-sealed response
37
+
38
+ ## Sandbox scope
39
+
40
+ This sketch now emits a real sealed `.tza` capsule, lets a local
41
+ gateway runtime read that capsule directly, and emits a sealed gateway
42
+ receipt back out.
43
+
44
+ It provides:
45
+
46
+ - package shape
47
+ - SAM types
48
+ - inspect and verify surfaces
49
+ - materialization payload shape
50
+ - sealed `.tza` materialization
51
+ - local gateway runtime for break-seal, validate, execute, destroy
52
+ - sealed gateway receipt shape
53
+ - human and JSON rendering
54
+ - a small CLI to inspect the model
55
+
56
+ ## Commands
57
+
58
+ ```bash
59
+ tibet-sam info
60
+ tibet-sam types
61
+ tibet-sam runtime
62
+ tibet-sam inspect /tmp/upload-pypi-v4.sam.tza
63
+ tibet-sam verify /tmp/upload-pypi-v4.sam.tza
64
+ tibet-sam materialize \
65
+ --intent upload_package \
66
+ --secret-id sec_pypi_001 \
67
+ --target-action /upload/pypi \
68
+ --actor-id jis:humotica:agent.ai \
69
+ --constraint package=tibet-zip \
70
+ --constraint registry=pypi \
71
+ --valid-for-seconds 300 \
72
+ --json
73
+
74
+ tibet-sam materialize \
75
+ --intent upload_package \
76
+ --secret-id sec_pypi_001 \
77
+ --target-action /upload/pypi \
78
+ --actor-id jis:humotica:agent.ai \
79
+ --constraint package=tibet-zip \
80
+ --constraint registry=pypi \
81
+ --identity-dir /tmp/sam-identity \
82
+ --emit-bundle /tmp/upload-pypi.sam.tza \
83
+ --json
84
+
85
+ tibet-sam execute \
86
+ --sam-file /tmp/upload-pypi.sam.tza \
87
+ --requested-action /upload/pypi \
88
+ --request-actor jis:humotica:agent.ai \
89
+ --gateway-actor jis:humotica:tibet-gateway \
90
+ --gateway-identity-dir /tmp/gateway-identity \
91
+ --response-bundle /tmp/upload-pypi.sam-receipt.tza \
92
+ --constraint package=tibet-zip \
93
+ --constraint registry=pypi \
94
+ --json
95
+ ```
96
+
97
+ Example SAM payload:
98
+
99
+ - [examples/sam-upload-pypi.json](/srv/jtel-stack/sandbox/ai/codex/tibet-sam-sketch/examples/sam-upload-pypi.json:1)
100
+
101
+ ## Denied Paths
102
+
103
+ The package should be able to show why a capsule is denied, not only
104
+ why a capsule is accepted.
105
+
106
+ Typical denied cases:
107
+
108
+ - actor mismatch
109
+ - expired SAM
110
+ - constraint mismatch
111
+
112
+ Example:
113
+
114
+ ```bash
115
+ tibet-sam execute \
116
+ --sam-file /tmp/upload-pypi-v4.sam.tza \
117
+ --requested-action /upload/pypi \
118
+ --request-actor jis:humotica:wrong.actor \
119
+ --gateway-actor webshop.admin \
120
+ --constraint package=tibet-zip \
121
+ --constraint registry=pypi \
122
+ --json
123
+ ```
124
+
125
+ And for a structural check:
126
+
127
+ ```bash
128
+ tibet-sam verify /tmp/upload-pypi-v4.sam.tza --json
129
+ ```
130
+
131
+ ## Current Runtime Boundary
132
+
133
+ The current sandbox runtime already performs the bounded flow:
134
+
135
+ 1. break seal inside the gateway boundary
136
+ 2. validate actor, target action, and constraints
137
+ 3. open an ephemeral gateway session
138
+ 4. proxy secret use through a local runtime adapter
139
+ 5. destroy the session
140
+ 6. emit a sealed receipt
141
+
142
+ Current local adapters:
143
+
144
+ - `upload_package` to `/upload/pypi`
145
+ - a generic bounded fallback executor for other intents
146
+
147
+ This is enough to prove the runtime shape end-to-end.
148
+ What still remains for production is not the authority flow itself, but
149
+ real upstream adapters inside the actual `tibet-gateway` package.
150
+
151
+ ## Release Notes For Package Lift
152
+
153
+ This sandbox is now mature enough for a lift into `/packages/tibet-sam`
154
+ because it already proves:
155
+
156
+ - sealed authority materialization
157
+ - direct `.tza` execution path
158
+ - explicit session lifecycle
159
+ - sealed receipt emission
160
+ - inspect and verify operator surfaces
161
+
162
+ What is still production-later:
163
+
164
+ - real upstream adapters inside `tibet-gateway`
165
+ - real external secret backends behind `tibet-keychain`
166
+ - richer policy lanes and revocation handling
167
+
168
+ ## Intended next steps
169
+
170
+ - move the sandbox runtime shape into real `tibet-gateway` boundary hooks
171
+ - deepen destroy-session semantics around real external adapters
172
+ - link to `tibet-keychain` custody records
173
+
174
+ ## Short formulation
175
+
176
+ SAM authorizes the right to perform one bounded act, without
177
+ releasing the underlying secret.
@@ -0,0 +1,24 @@
1
+ {
2
+ "actor_id": "jis:humotica:agent.ai",
3
+ "constraints": [
4
+ {
5
+ "key": "package",
6
+ "value": "tibet-zip"
7
+ },
8
+ {
9
+ "key": "registry",
10
+ "value": "pypi"
11
+ }
12
+ ],
13
+ "ephemeral_id": "eph_example_upload001",
14
+ "intent": "upload_package",
15
+ "notes": [
16
+ "sandbox sketch example",
17
+ "not yet sealed as .tza",
18
+ "intended to become an intent-bound one-shot authority capsule"
19
+ ],
20
+ "sam_id": "sam_example_upload001",
21
+ "secret_id": "sec_pypi_001",
22
+ "target_action": "/upload/pypi",
23
+ "valid_until": "2026-06-17T12:00:00Z"
24
+ }
@@ -0,0 +1,60 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "tibet-sam"
7
+ version = "0.1.0"
8
+ description = "Sealed Authority Module — intent-bound scoped authority capsules for bounded gateway execution"
9
+ readme = "README.md"
10
+ license = "MIT"
11
+ requires-python = ">=3.10"
12
+ authors = [
13
+ { name = "Jasper van de Meent", email = "info@humotica.com" },
14
+ { name = "Root AI", email = "root_idd@humotica.nl" },
15
+ { name = "Codex", email = "codex@humotica.nl" }
16
+ ]
17
+ keywords = [
18
+ "tibet", "sam", "authority", "gateway", "sealed", "capability",
19
+ "secret-custody", "bounded-execution", "cbom", "continuity"
20
+ ]
21
+ classifiers = [
22
+ "Development Status :: 4 - Beta",
23
+ "Intended Audience :: Developers",
24
+ "Intended Audience :: Information Technology",
25
+ "Intended Audience :: System Administrators",
26
+ "License :: OSI Approved :: MIT License",
27
+ "Operating System :: OS Independent",
28
+ "Programming Language :: Python :: 3",
29
+ "Programming Language :: Python :: 3.10",
30
+ "Programming Language :: Python :: 3.11",
31
+ "Programming Language :: Python :: 3.12",
32
+ "Programming Language :: Python :: 3.13",
33
+ "Topic :: Security :: Cryptography",
34
+ "Topic :: Software Development :: Libraries :: Python Modules"
35
+ ]
36
+ dependencies = [
37
+ "cryptography>=42.0",
38
+ "tibet-drop>=0.3.0"
39
+ ]
40
+
41
+ [project.optional-dependencies]
42
+ cbom = [
43
+ "tibet-cbom>=0.1.1",
44
+ ]
45
+ dev = [
46
+ "pytest>=8.0",
47
+ ]
48
+
49
+ [project.scripts]
50
+ tibet-sam = "tibet_sam.cli:main"
51
+ tsam = "tibet_sam.cli:main"
52
+
53
+ [project.urls]
54
+ Homepage = "https://humotica.com"
55
+ Repository = "https://github.com/Humotica/tibet-sam"
56
+ "TIBET Ecosystem" = "https://pypi.org/project/tibet/"
57
+ "Semantic Surface Manifest" = "https://datatracker.ietf.org/doc/draft-vandemeent-tibet-semantic-surface-manifest/"
58
+
59
+ [tool.hatch.build.targets.wheel]
60
+ packages = ["src/tibet_sam"]
@@ -0,0 +1,3 @@
1
+ __all__ = ["__version__"]
2
+
3
+ __version__ = "0.1.0"