Publish curated ITWorx-ModelForge source from 990401737f96c8d46a9f7b0d84994516cadcb6a0
This commit is contained in:
1 parent
7082ab955a
commit
848f0d8f8a
434 files changed
+67298
-4315
No files matched your search
@@ -593,13 +593,17 @@ def test_exact_aliased_delete_and_head_rewrite_poc_is_refused(
|
||||
"statement",
|
||||
[
|
||||
"/* leading /* nested */ comment */ DELETE\nFROM [main].[audit_events]",
|
||||
"-- leading decoy\nUPDATE `main`.`audit_chain_heads` "
|
||||
"SET event_count=0, last_sequence=0, last_event_hash=NULL",
|
||||
(
|
||||
"-- leading decoy\nUPDATE `main`.`audit_chain_heads` "
|
||||
"SET event_count=0, last_sequence=0, last_event_hash=NULL"
|
||||
),
|
||||
'INSERT /* gap */ INTO "public"."audit_events" (id) VALUES (NULL)',
|
||||
"WITH doomed AS (SELECT 1) DELETE FROM audit_events",
|
||||
"TRUNCATE TABLE harmless_table, audit_events",
|
||||
"MERGE INTO public.audit_chain_heads AS head USING incoming ON false "
|
||||
"WHEN MATCHED THEN DELETE",
|
||||
(
|
||||
"MERGE INTO public.audit_chain_heads AS head USING incoming ON false "
|
||||
"WHEN MATCHED THEN DELETE"
|
||||
),
|
||||
"COPY audit_events FROM STDIN",
|
||||
"DROP TABLE harmless_table, audit_chain_heads",
|
||||
"DO $$ BEGIN DELETE FROM audit_events; END $$",
|
||||
@@ -736,8 +740,10 @@ def test_late_statement_rewrite_is_rolled_back_before_commit(tmp_path: Any) -> N
|
||||
[
|
||||
r'ALTER TABLE IF EXISTS U&"audit\005fevents" DISABLE TRIGGER ALL',
|
||||
r'''ALTER TABLE IF EXISTS U&"audit!005fchain!005fheads" UESCAPE '!' DISABLE TRIGGER ALL''',
|
||||
"CREATE OR REPLACE FUNCTION reset_chain() RETURNS void LANGUAGE SQL AS $$ "
|
||||
"DELETE FROM audit_events $$",
|
||||
(
|
||||
"CREATE OR REPLACE FUNCTION reset_chain() RETURNS void LANGUAGE SQL AS $$ "
|
||||
"DELETE FROM audit_events $$"
|
||||
),
|
||||
"SELECT public.reset_chain()",
|
||||
"CALL reset_chain()",
|
||||
"DO $$ BEGIN EXECUTE 'DELETE FROM audit_events'; END $$",
|
||||
@@ -756,8 +762,10 @@ def test_runtime_sql_classifier_defaults_procedural_and_obfuscated_mutation_to_d
|
||||
[
|
||||
"SELECT count(*) FROM audit_events",
|
||||
"SELECT * FROM audit_chain_heads",
|
||||
"SELECT * FROM modelforge_audit.append_event_v2(NULL, NULL, NULL, NULL, NULL, "
|
||||
"NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)",
|
||||
(
|
||||
"SELECT * FROM modelforge_audit.append_event_v2(NULL, NULL, NULL, NULL, NULL, "
|
||||
"NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)"
|
||||
),
|
||||
],
|
||||
)
|
||||
def test_runtime_sql_classifier_keeps_read_and_canonical_append_controls(
|
||||
|
||||
Reference in new issue
Block a user