Skip to main content

Bind ODBC / DB-API database operations to the AlgoVoi keystone -- each statement gets a content-addressed execution_ref (keystone-only edition, Apache-2.0)

Project description

algovoi-keystone-odbc

Keystone Integration

Bind ODBC / DB-API database operations to the AlgoVoi keystone. Wrap any DB-API 2.0 cursor (pyodbc, sqlite3, psycopg, …) and every executed statement gets a content-addressed execution_ref binding that operation to the keystone decision that authorised it. Open, keystone-only edition, Apache-2.0.

execution_ref = "sha256:" + SHA-256(JCS({ decision_ref, action_type, scope, outcome, executed_at_ms }))
import pyodbc
from algovoi_keystone_odbc import keystone_cursor

conn = pyodbc.connect(dsn)
cur = keystone_cursor(conn.cursor(), decision_ref="sha256:…", scope="orders")

cur.execute("INSERT INTO orders (id, total) VALUES (?, ?)", 1, 4200)
cur.execution_ref   # sha256:… — binds that INSERT to the authorising keystone decision
cur.executions      # [{statement, action_type: "db:insert", outcome: "COMMITTED", execution_ref, …}]

A failed statement is recorded with outcome FAILED and the error re-raised. action_type is derived from the SQL verb (db:insert, db:update, db:delete, db:select, …). The wrapper is a drop-in: attribute access (fetchone, description, …) falls through to the real cursor.

Standalone, without the cursor:

from algovoi_keystone_odbc import db_execution_ref, tamper_detected

ref = db_execution_ref(decision_ref="sha256:…", statement="UPDATE orders SET total=0",
                       scope="orders", outcome="REVERSED", executed_at_ms=1716460800000)
tamper_detected(ref, decision_ref="sha256:…", statement="UPDATE orders SET total=0",
                scope="orders", outcome="REVERSED", executed_at_ms=1716460800000)  # -> False

Keystone-only edition

Open (this package) Commercial
Per-operation execution_ref binding yes yes
Drop-in cursor instrumentation yes yes
Tamper detection (recompute) yes yes
Signed, hash-linked chain of operations yes
PQC signing + CCC evidence ingest yes

This edition binds and verifies each database operation. Chaining operations into a signed, tamper-evident audit log is the commercial tier.

License

Apache-2.0. Copyright AlgoVoi. Byte-compatible with algovoi-execution-ref.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

algovoi_keystone_odbc-0.2.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (235.4 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

algovoi_keystone_odbc-0.2.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (270.1 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

algovoi_keystone_odbc-0.2.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (227.2 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

algovoi_keystone_odbc-0.2.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (216.2 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

File details

Details for the file algovoi_keystone_odbc-0.2.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for algovoi_keystone_odbc-0.2.0-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b8fbf1d3cfaad9a9f39187c7b023c73cc73b240d5d406fe86dba7bb547b43ff6
MD5 8d3a55b546b46fb75340eb4421b4f191
BLAKE2b-256 9338282c206065dd48afef7d13a46cf201675789cf16be66f891b00632dfc9ec

See more details on using hashes here.

File details

Details for the file algovoi_keystone_odbc-0.2.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for algovoi_keystone_odbc-0.2.0-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 fdff9fcbf4e34aac3b0dabba5a9a5519403755249fe287fe2bcf7cb75e9cdac5
MD5 e829ade70d654f0f8ca79edb3c305fc0
BLAKE2b-256 eeaf2321f94dc774f29bbfca7a198edf7468a1f86cbb53da5f5ab26d5c1f121c

See more details on using hashes here.

File details

Details for the file algovoi_keystone_odbc-0.2.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for algovoi_keystone_odbc-0.2.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 626712a6c4df42cbe38da61963c3822143f69de0f707987528ecc57068c6bd4b
MD5 1d1031320024586f631233a550fc43ef
BLAKE2b-256 4af885bd467f2981566e246d788537740c9bdc1929586d034e16923c3943a8e0

See more details on using hashes here.

File details

Details for the file algovoi_keystone_odbc-0.2.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for algovoi_keystone_odbc-0.2.0-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 2a67d31f2b3b90595660e9121a949531eac34ae099d94b0eb2e3ed892da5e032
MD5 4e771a3be3d0c36e98a0da8e71ee4a1c
BLAKE2b-256 54c7d5340c40c0079981867abc581d642cad448b8952924cd1feca669d6ebab6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page