ciris-verify 22.2.2__tar.gz → 22.2.4__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.
Files changed (39) hide show
  1. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/PKG-INFO +1 -1
  2. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/__init__.py +5 -1
  3. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/types.py +41 -0
  4. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify.egg-info/PKG-INFO +1 -1
  5. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/pyproject.toml +1 -1
  6. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/tests/test_types.py +47 -0
  7. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/README.md +0 -0
  8. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_accord_custody.py +0 -0
  9. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_accord_invocation.py +0 -0
  10. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_bin_sign.py +0 -0
  11. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_bin_verify.py +0 -0
  12. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_canonical_subject.py +0 -0
  13. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_epoch_key.py +0 -0
  14. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_evm_tx.py +0 -0
  15. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_federation_identity.py +0 -0
  16. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_jcs.py +0 -0
  17. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_manifest_contribution.py +0 -0
  18. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_operational_admit.py +0 -0
  19. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_raw_verify.py +0 -0
  20. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_rns_dest_hash.py +0 -0
  21. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_scope_privacy.py +0 -0
  22. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_self_enc.py +0 -0
  23. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_test_anchor.py +0 -0
  24. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_wheel_hybrid_kex.py +0 -0
  25. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_wheel_key_grant.py +0 -0
  26. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_wheel_locale_merkle.py +0 -0
  27. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_wheel_reconsider_dos.py +0 -0
  28. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/_wheel_skill_import.py +0 -0
  29. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/client.py +0 -0
  30. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/exceptions.py +0 -0
  31. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify/py.typed +0 -0
  32. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify.egg-info/SOURCES.txt +0 -0
  33. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify.egg-info/dependency_links.txt +0 -0
  34. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify.egg-info/entry_points.txt +0 -0
  35. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify.egg-info/requires.txt +0 -0
  36. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/ciris_verify.egg-info/top_level.txt +0 -0
  37. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/setup.cfg +0 -0
  38. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/tests/test_client.py +0 -0
  39. {ciris_verify-22.2.2 → ciris_verify-22.2.4}/tests/test_memory_baseline.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ciris-verify
3
- Version: 22.2.2
3
+ Version: 22.2.4
4
4
  Summary: Python bindings for CIRISVerify hardware-rooted license verification
5
5
  Author-email: CIRIS Engineering <engineering@ciris.ai>
6
6
  License-Expression: AGPL-3.0-or-later
@@ -94,6 +94,8 @@ from .types import (
94
94
  FileIntegrityResult,
95
95
  FileCheckStatus,
96
96
  BinaryIntegrityStatus,
97
+ SelfVerificationResult,
98
+ EMBEDDED_NO_MANIFEST,
97
99
  HardwareType,
98
100
  ValidationStatus,
99
101
  PythonModuleHashes,
@@ -172,7 +174,7 @@ def get_library_version() -> str:
172
174
  return __version__
173
175
 
174
176
 
175
- __version__ = "22.2.2"
177
+ __version__ = "22.2.4"
176
178
  __all__ = [
177
179
  "CIRISVerify",
178
180
  "MockCIRISVerify",
@@ -222,6 +224,8 @@ __all__ = [
222
224
  "FileIntegrityResult",
223
225
  "FileCheckStatus",
224
226
  "BinaryIntegrityStatus",
227
+ "SelfVerificationResult",
228
+ "EMBEDDED_NO_MANIFEST",
225
229
  "HardwareType",
226
230
  "ValidationStatus",
227
231
  "PythonModuleHashes",
@@ -467,6 +467,47 @@ class BinaryIntegrityStatus(BaseModel):
467
467
  return self.status not in ("unavailable", "not_found", "pending")
468
468
 
469
469
 
470
+ class SelfVerificationResult(BaseModel):
471
+ """Level 1 self-verification, the `self_verification` member of
472
+ `run_attestation`'s result (`SelfVerificationResult` in Rust).
473
+
474
+ `module_path` and `embedded_in_host` (22.2.3+ and 23.4.1+, CIRISVerify#210) are
475
+ measurements: `embedded_in_host` is true when verify runs statically folded
476
+ into a host binary rather than from its own library or executable. When
477
+ the registry has no manifest for that host binary, `error` is
478
+ `EMBEDDED_NO_MANIFEST` and `binary_valid` / `functions_valid` stay false:
479
+ not a pass. Payloads from earlier libraries lack both fields and parse to
480
+ `None` / `False`.
481
+ """
482
+ model_config = ConfigDict(frozen=True, extra="ignore")
483
+
484
+ binary_valid: bool = False
485
+ functions_valid: bool = False
486
+ valid: bool = False
487
+ binary_version: str = ""
488
+ target: str = ""
489
+ binary_hash: str = ""
490
+ expected_hash: Optional[str] = None
491
+ functions_checked: int = 0
492
+ functions_passed: int = 0
493
+ registry_reachable: bool = False
494
+ error: Optional[str] = None
495
+ module_path: Optional[str] = Field(
496
+ default=None, description="File verify's code runs from (found by address)"
497
+ )
498
+ embedded_in_host: bool = Field(
499
+ default=False, description="module_path is a host binary, not verify's own artifact"
500
+ )
501
+
502
+ def is_embedded_without_manifest(self) -> bool:
503
+ """Embedded in a host binary the registry has no manifest for."""
504
+ return self.error == EMBEDDED_NO_MANIFEST
505
+
506
+
507
+ EMBEDDED_NO_MANIFEST = "embedded_in_host: no manifest for host binary"
508
+ """`SelfVerificationResult.error` for an embedded install without a manifest."""
509
+
510
+
470
511
  class PythonModuleHashes(BaseModel):
471
512
  """Python module hashes for Android/mobile code integrity (v0.8.1).
472
513
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ciris-verify
3
- Version: 22.2.2
3
+ Version: 22.2.4
4
4
  Summary: Python bindings for CIRISVerify hardware-rooted license verification
5
5
  Author-email: CIRIS Engineering <engineering@ciris.ai>
6
6
  License-Expression: AGPL-3.0-or-later
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "ciris-verify"
7
- version = "22.2.2"
7
+ version = "22.2.4"
8
8
  description = "Python bindings for CIRISVerify hardware-rooted license verification"
9
9
  readme = "README.md"
10
10
  license = "AGPL-3.0-or-later"
@@ -221,3 +221,50 @@ class TestSourceDetails:
221
221
  details = SourceDetails(validation_status=ValidationStatus.VALIDATION_ERROR)
222
222
  assert details.trust_root is None
223
223
  assert details.sources == []
224
+
225
+
226
+ class TestSelfVerificationResult:
227
+ """CIRISVerify#210: embedded-install measurement fields."""
228
+
229
+ def test_parses_embedded_payload(self):
230
+ from ciris_verify.types import SelfVerificationResult, EMBEDDED_NO_MANIFEST
231
+
232
+ sv = SelfVerificationResult.model_validate({
233
+ "binary_valid": False,
234
+ "functions_valid": False,
235
+ "valid": False,
236
+ "binary_version": "23.4.1",
237
+ "target": "x86_64-unknown-linux-gnu",
238
+ "binary_hash": "ab" * 32,
239
+ "expected_hash": "cd" * 32,
240
+ "functions_checked": 0,
241
+ "functions_passed": 0,
242
+ "registry_reachable": True,
243
+ "error": EMBEDDED_NO_MANIFEST,
244
+ "module_path": "/srv/ciris_server/_native.abi3.so",
245
+ "embedded_in_host": True,
246
+ })
247
+ assert sv.embedded_in_host
248
+ assert sv.module_path == "/srv/ciris_server/_native.abi3.so"
249
+ assert sv.is_embedded_without_manifest()
250
+ assert not sv.valid
251
+
252
+ def test_parses_payload_without_new_fields(self):
253
+ from ciris_verify.types import SelfVerificationResult
254
+
255
+ sv = SelfVerificationResult.model_validate({
256
+ "binary_valid": True,
257
+ "functions_valid": True,
258
+ "valid": True,
259
+ "binary_version": "23.4.0",
260
+ "target": "x86_64-unknown-linux-gnu",
261
+ "binary_hash": "ab" * 32,
262
+ "expected_hash": "ab" * 32,
263
+ "functions_checked": 10,
264
+ "functions_passed": 10,
265
+ "registry_reachable": True,
266
+ "error": None,
267
+ })
268
+ assert sv.module_path is None
269
+ assert sv.embedded_in_host is False
270
+ assert not sv.is_embedded_without_manifest()
File without changes
File without changes