From 087c2a7621543a36b9d9013c24c58db65a0c04d6 Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 6 Aug 2026 18:10:12 -0300 Subject: [PATCH 01/36] test: e2e stack hostname is now 'ai' (was artifact-index-e2e) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The e2e docker-compose stack renamed its services to canonical short names; the artifact-index API service there is now reachable as 'ai'. The suite's hardcoded live-stack URIs and all VCR cassettes follow (VCR matches on host, so the cassettes must carry the same hostname the tests dial; this is a mechanical hostname substitution — method/path/query/bodies untouched). --- test/async_client_test.py | 4 +- test/client_scan_test.py | 52 ++-- test/vcr/test_add_known_good_host.vcr | 4 +- test/vcr/test_async_add_known_good_host.vcr | 4 +- test/vcr/test_async_check_known_host.vcr | 8 +- .../vcr/test_async_delete_known_good_host.vcr | 8 +- test/vcr/test_async_download_to_handle.vcr | 16 +- ...xistence_probe_against_the_real_server.vcr | 64 ++--- test/vcr/test_async_hash_search.vcr | 136 ++++----- test/vcr/test_async_historical.vcr | 12 +- test/vcr/test_async_historical_results.vcr | 8 +- test/vcr/test_async_iocs_by_hash.vcr | 48 ++-- test/vcr/test_async_known_good_lifecycle.vcr | 36 +-- test/vcr/test_async_list_historical.vcr | 24 +- test/vcr/test_async_live.vcr | 168 +++++------ test/vcr/test_async_metadata_search.vcr | 136 ++++----- test/vcr/test_async_rescans.vcr | 264 ++++++++--------- test/vcr/test_async_rules.vcr | 24 +- test/vcr/test_async_sample.vcr | 112 ++++---- test/vcr/test_async_sandbox_providers.vcr | 4 +- test/vcr/test_async_sandboxtask_latest.vcr | 48 ++-- test/vcr/test_async_sandboxtask_list.vcr | 32 +-- test/vcr/test_async_sandboxtask_submit.vcr | 20 +- test/vcr/test_async_search_by_ioc.vcr | 124 ++++---- test/vcr/test_async_submission.vcr | 132 ++++----- test/vcr/test_async_tool_metadata.vcr | 20 +- .../vcr/test_async_update_known_good_host.vcr | 8 +- test/vcr/test_check_known_host.vcr | 8 +- test/vcr/test_delete_known_good_host.vcr | 8 +- test/vcr/test_download.vcr | 16 +- test/vcr/test_download_to_handle.vcr | 16 +- ...xistence_probe_against_the_real_server.vcr | 56 ++-- test/vcr/test_hash_search.vcr | 136 ++++----- test/vcr/test_historical.vcr | 12 +- test/vcr/test_historical_results.vcr | 8 +- test/vcr/test_iocs_by_hash.vcr | 48 ++-- test/vcr/test_known_good_lifecycle.vcr | 36 +-- test/vcr/test_list_historical.vcr | 24 +- test/vcr/test_live.vcr | 168 +++++------ test/vcr/test_metadata_search.vcr | 136 ++++----- test/vcr/test_rescans.vcr | 268 +++++++++--------- test/vcr/test_rules.vcr | 24 +- test/vcr/test_sample.vcr | 28 +- test/vcr/test_sandbox_providers.vcr | 4 +- test/vcr/test_sandboxtask_latest.vcr | 48 ++-- test/vcr/test_sandboxtask_list.vcr | 36 +-- test/vcr/test_sandboxtask_submit.vcr | 20 +- test/vcr/test_search_by_ioc.vcr | 144 +++++----- test/vcr/test_stream.vcr | 92 +++--- test/vcr/test_submission.vcr | 132 ++++----- test/vcr/test_tool_metadata.vcr | 20 +- test/vcr/test_update_known_good_host.vcr | 8 +- 52 files changed, 1506 insertions(+), 1506 deletions(-) diff --git a/test/async_client_test.py b/test/async_client_test.py index 95602710..cf51fb8e 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -244,7 +244,7 @@ class TestAsyncScanCase: def _api(self, community='gamma'): return PolySwarmAsyncAPI( self.test_api_key, - uri=f'http://artifact-index-e2e:9696/{self.api_version}', + uri=f'http://ai:9696/{self.api_version}', community=community, ) @@ -877,7 +877,7 @@ async def test_async_engine_cache_empty_raises(self): # ── Error handling (no cassettes) — mirrors no-cassette sync tests ──────────── -BASE_URL = 'http://artifact-index-e2e:9696/v3' +BASE_URL = 'http://ai:9696/v3' API_KEY = '11111111111111111111111111111111' diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 46b22804..70573cf1 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -232,7 +232,7 @@ def __init__(self, *args, **kwargs): @vcr.use_cassette() def test_submission(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Canonical "a file goes in and gets scanned" path: submit_and_scan waits # for the scan to complete and asserts the entry carries assertions/votes. instance, sha = submit_and_scan(api, self._testMethodName) @@ -240,7 +240,7 @@ def test_submission(self): @vcr.use_cassette() def test_rescans(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Submit this test's own unique artifact, then rescan it by hash and by # id. rescan_and_scan confirms each rescan actually re-runs the scan # (assertions/votes land), not merely that the call was accepted. @@ -251,7 +251,7 @@ def test_rescans(self): @vcr.use_cassette() def test_download(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Self-contained: submit this test's own artifact, then download ITS sha # and assert the bytes round-trip. content, sha = malicious_artifact(self._testMethodName) @@ -269,7 +269,7 @@ def test_download(self): @vcr.use_cassette() def test_download_to_handle(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') content, sha = malicious_artifact(self._testMethodName) with artifact_file(content) as fpath: api.submit(fpath) @@ -286,7 +286,7 @@ def test_download_to_handle(self): @vcr.use_cassette() def test_stream(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # The archiver batches submitted instances into a downloadable archive # once ARTIFACT_ARCHIVES_INSTANCE_COUNT (3 in e2e) is *exceeded*, after an # ARCHIVES_CREATION_DELAY. The batch is global, so we submit enough of OUR @@ -340,7 +340,7 @@ def _submit(content): @vcr.use_cassette() def test_hash_search(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Submit + scan this test's own artifact (confirms it scanned), then # search for ITS sha. The search index can lag the scan, so poll. _, sha = submit_and_scan(api, self._testMethodName) @@ -349,7 +349,7 @@ def test_hash_search(self): @vcr.use_cassette() def test_metadata_search(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Submit + scan this test's own artifact, then search the ES metadata # index for ITS sha (sha-scoped query). The metadata write can lag, so poll. _, sha = submit_and_scan(api, self._testMethodName) @@ -451,7 +451,7 @@ def test_resolve_engine_name(self): @vcr.use_cassette() def test_live(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Self-contained: a per-test ruleset whose YARA matches ONLY this test's # artifact (uid_yara keys on the uid embedded by malicious_artifact), so # the live hunt surfaces just this run's submission — no cross-test feed @@ -528,7 +528,7 @@ def test_live(self): @vcr.use_cassette() def test_historical(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') historical_hunt = api.historical_create(uid_yara(self._testMethodName)) assert historical_hunt.status == 'PENDING' get_historical_hunt = api.historical_get(historical_hunt.id) @@ -538,7 +538,7 @@ def test_historical(self): @vcr.use_cassette() def test_list_historical(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Create this test's own hunts and assert each created id is present in # the list (subset check is isolation-safe: other tests' hunts may also # be listed on the shared stack). @@ -552,7 +552,7 @@ def test_list_historical(self): @vcr.use_cassette() def test_historical_results(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Self-contained: our own unique hunt (uid_yara). The e2e historical scan # is asynchronous and does not reliably populate results within a test # window, so accept an empty result set — end-to-end YARA matching is @@ -568,7 +568,7 @@ def test_historical_results(self): @vcr.use_cassette() def test_rules(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # creating with open('test/eicar.yara') as rule: contents = rule.read() @@ -600,7 +600,7 @@ def test_rules(self): @vcr.use_cassette() def test_tool_metadata(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Self-contained: submit this test's own artifact and attach two tool # blobs. Tool metadata is instance-scoped, so the tool names need no # namespacing — they can't collide across tests' distinct instances. @@ -624,7 +624,7 @@ def test_tool_metadata(self): @vcr.use_cassette() def test_iocs_by_hash(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Forward IOC lookup: /v3/ioc-beta/sha256/ resolves the sha via # SandboxTaskSearchHash (seeded for the EICAR fixture in e2e) and reads # the resulting instance's metadata. We don't need a live sandbox: @@ -670,7 +670,7 @@ def test_iocs_by_hash(self): @vcr.use_cassette() def test_search_by_ioc(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Reverse IOC search (/v3/ioc/search?ip=): given an IOC, find the sha256 # that reported it. Same artificial cape_sandbox_v2 trick as the forward # test_iocs_by_hash (no live sandbox needed), but the reverse view reads @@ -722,7 +722,7 @@ def test_search_by_ioc(self): @vcr.use_cassette() def test_add_known_good_host(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') # Unique per-test host on the ephemeral stack => the create branch with # no prior cleanup needed. host = uid_host(self._testMethodName) @@ -732,7 +732,7 @@ def test_add_known_good_host(self): @vcr.use_cassette() def test_update_known_good_host(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') # Add a unique host, capture its real id, then update it to a unique IP. host = uid_host(self._testMethodName) ip = uid_ip(self._testMethodName) @@ -743,7 +743,7 @@ def test_update_known_good_host(self): @vcr.use_cassette() def test_delete_known_good_host(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') host = uid_host(self._testMethodName) added = v3api.add_known_good_host("domain", "test", host) known = v3api.delete_known_good_host(added.json['id']) @@ -752,7 +752,7 @@ def test_delete_known_good_host(self): @vcr.use_cassette() def test_check_known_host(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') # Add a unique known-good IP and list it back. ip = uid_ip(self._testMethodName) added = v3api.add_known_good_host('ip', 'test', ip) @@ -766,7 +766,7 @@ def test_known_good_lifecycle(self): # internal plan). The sha comes from this test's unique EICAR variant # (same convention as the scan tests) => the create branch runs first; # the trailing delete keeps live re-runs deterministic. - v3api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') _content, sha = malicious_artifact(self._testMethodName) created = v3api.known_good_create( sha256=sha, source='nsrl', filename='kg-sample.exe', @@ -847,7 +847,7 @@ def test_hash_existence_probe_against_the_real_server(self): # # So this asserts the server's behaviour rather than the SDK's mapping, on both sides # of the 200/204 boundary, using the ordinary provisioning path. - v3api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Two distinct EICAR variants, both deterministic: one this test submits, and one # NOTHING ever submits. Deriving the absent case from its own uid is what keeps this # test re-runnable against a reused stack — probing the sha we are about to submit @@ -882,14 +882,14 @@ def test_hash_existence_probe_against_the_real_server(self): @vcr.use_cassette() def test_sandbox_providers(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') response = v3api.sandbox_providers() assert response.json['result']['cape']['slug'] == 'cape' assert response.json['result']['triage']['slug'] == 'triage' @vcr.use_cassette() def test_sandboxtask_submit(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') # Self-contained: submit this test's own artifact and dispatch sandbox # tasks against ITS instance id. The submit response carries the real id. instance, _ = submit_and_scan(v3api, self._testMethodName, wait=False) @@ -902,7 +902,7 @@ def test_sandboxtask_submit(self): @vcr.use_cassette() def test_sandboxtask_latest(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') # Self-contained: submit our own artifact and drive cape + triage to # SUCCEEDED by replaying the sandbox worker's HTTP calls (no analysis VMs # in e2e). Completing a task creates its SandboxTaskSearchHash row, which @@ -926,7 +926,7 @@ def test_sandboxtask_latest(self): @vcr.use_cassette() def test_sandboxtask_list(self): - v3api = PolyswarmAPI(self.test_api_key, uri='http://artifact-index-e2e:9696/v3', community='gamma') + v3api = PolyswarmAPI(self.test_api_key, uri='http://ai:9696/v3', community='gamma') # Self-contained: submit our own artifact and queue cape + triage for ITS # sha. Assertions are scoped to our sha, so they're exact for this run. instance, sha256 = submit_and_scan(v3api, self._testMethodName, wait=False) @@ -961,7 +961,7 @@ def test_sandboxtask_list(self): @vcr.use_cassette() def test_sample(self): - api = PolyswarmAPI(self.test_api_key, uri=f'http://artifact-index-e2e:9696/{self.api_version}', community='gamma') + api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') # Self-contained: submit our own artifact and drive cape + triage to # COMPLETED, then GET the aggregated sample for OUR sha. Reaching the # sample with a completed sandbox dep auto-triggers an LLM report; it diff --git a/test/vcr/test_add_known_good_host.vcr b/test/vcr/test_add_known_good_host.vcr index 23bf7cdb..e93d6293 100644 --- a/test/vcr/test_add_known_good_host.vcr +++ b/test/vcr/test_add_known_good_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"test-add-known-good-host.sdk.test","id":1,"source":"test","type":"domain"},"status":"OK"} diff --git a/test/vcr/test_async_add_known_good_host.vcr b/test/vcr/test_async_add_known_good_host.vcr index cbe4546d..1d0b659f 100644 --- a/test/vcr/test_async_add_known_good_host.vcr +++ b/test/vcr/test_async_add_known_good_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"test-async-add-known-good-host.sdk.test","id":5,"source":"test","type":"domain"},"status":"OK"} diff --git a/test/vcr/test_async_check_known_host.vcr b/test/vcr/test_async_check_known_host.vcr index 346ffb69..3f2dd0df 100644 --- a/test/vcr/test_async_check_known_host.vcr +++ b/test/vcr/test_async_check_known_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"9.42.21.167","id":8,"source":"test","type":"ip"},"status":"OK"} @@ -57,11 +57,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/known?ip=9.42.21.167 + uri: http://ai:9696/v3/ioc/known?ip=9.42.21.167 response: body: string: '{"result":[{"good":true,"host":"9.42.21.167","id":8,"source":"test","type":"ip"}],"status":"OK"} diff --git a/test/vcr/test_async_delete_known_good_host.vcr b/test/vcr/test_async_delete_known_good_host.vcr index 16e1c0c5..d8c92c8b 100644 --- a/test/vcr/test_async_delete_known_good_host.vcr +++ b/test/vcr/test_async_delete_known_good_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"9.42.27.226","id":7,"source":"test","type":"ip"},"status":"OK"} @@ -57,11 +57,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/ioc/known?id=7 + uri: http://ai:9696/v3/ioc/known?id=7 response: body: string: '{"result":{"good":true,"host":"9.42.27.226","id":7,"source":"test","type":"ip"},"status":"OK"} diff --git a/test/vcr/test_async_download_to_handle.vcr b/test/vcr/test_async_download_to_handle.vcr index 8e801e6f..2473e473 100644 --- a/test/vcr/test_async_download_to_handle.vcr +++ b/test/vcr/test_async_download_to_handle.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"91146897712374264","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:52.901008+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:52.901008+00:00","id":"91146897712374264","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/91146897712374264","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1d/48/4d/1d484d24-377b-4017-b360-851a0fd498bc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223752Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=21d28aa47289d7c962d34226ed183162da86045573fc9f3810b88d78b0ef09ff","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=91146897712374264 + uri: http://ai:9696/v3/instance?id=91146897712374264 response: body: string: '{"result":{"artifact_id":"91146897712374264","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:52.901008+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:52.901008+00:00","id":"91146897712374264","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/91146897712374264","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1d/48/4d/1d484d24-377b-4017-b360-851a0fd498bc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223752Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=21d28aa47289d7c962d34226ed183162da86045573fc9f3810b88d78b0ef09ff","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/e2e4696fdcd4f626578f0c9d4ca5f3d32d2256b2130d87bb910c56ac90f26533?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/e2e4696fdcd4f626578f0c9d4ca5f3d32d2256b2130d87bb910c56ac90f26533?community=gamma response: body: string: '{"errors":null,"result":"No instance found for the hash sha256=e2e4696fdcd4f626578f0c9d4ca5f3d32d2256b2130d87bb910c56ac90f26533 @@ -199,11 +199,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/e2e4696fdcd4f626578f0c9d4ca5f3d32d2256b2130d87bb910c56ac90f26533?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/e2e4696fdcd4f626578f0c9d4ca5f3d32d2256b2130d87bb910c56ac90f26533?community=gamma response: body: string: ' diff --git a/test/vcr/test_async_hash_existence_probe_against_the_real_server.vcr b/test/vcr/test_async_hash_existence_probe_against_the_real_server.vcr index 65dcea9e..3ee42f26 100644 --- a/test/vcr/test_async_hash_existence_probe_against_the_real_server.vcr +++ b/test/vcr/test_async_hash_existence_probe_against_the_real_server.vcr @@ -11,11 +11,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=f38912693d48718b922fc4b78d0f797b5174d030284e1e2b09f4bd1c8caed82e&community=gamma&require_scan=false + uri: http://ai:9696/v3/search/hash/sha256?hash=f38912693d48718b922fc4b78d0f797b5174d030284e1e2b09f4bd1c8caed82e&community=gamma&require_scan=false response: body: string: '' @@ -47,11 +47,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=f38912693d48718b922fc4b78d0f797b5174d030284e1e2b09f4bd1c8caed82e&community=gamma&require_scan=true + uri: http://ai:9696/v3/search/hash/sha256?hash=f38912693d48718b922fc4b78d0f797b5174d030284e1e2b09f4bd1c8caed82e&community=gamma&require_scan=true response: body: string: '' @@ -87,11 +87,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-07-30T01:18:57.953044+00:00","id":"851018633677295","known_good":null,"last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/851018633677295","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"state":"CREATED","type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/87/88/c9/8788c928-45cf-41d1-8c2c-d2ba36b408bd?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260730%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260730T011857Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5d83f94cf24e611cf8f87d74fc2cef53e5d70d01dcbce44871f4ad669ee640c5","votes":[],"window_closed":false},"status":"OK"} @@ -188,11 +188,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=851018633677295 + uri: http://ai:9696/v3/instance?id=851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-07-30T01:18:57.953044+00:00","id":"851018633677295","known_good":null,"last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/851018633677295","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"state":"CREATED","type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/87/88/c9/8788c928-45cf-41d1-8c2c-d2ba36b408bd?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260730%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260730T011857Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5d83f94cf24e611cf8f87d74fc2cef53e5d70d01dcbce44871f4ad669ee640c5","votes":[],"window_closed":false},"status":"OK"} @@ -230,11 +230,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-07-30T01:18:57.953044+00:00","id":"851018633677295","known_good":null,"last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/851018633677295","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"state":"CREATED","type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/87/88/c9/8788c928-45cf-41d1-8c2c-d2ba36b408bd?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260730%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260730T011857Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5d83f94cf24e611cf8f87d74fc2cef53e5d70d01dcbce44871f4ad669ee640c5","votes":[],"window_closed":false},"status":"OK"} @@ -272,11 +272,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -319,11 +319,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -366,11 +366,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -413,11 +413,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -460,11 +460,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -507,11 +507,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -554,11 +554,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -601,11 +601,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -648,11 +648,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/851018633677295 + uri: http://ai:9696/v3/consumer/submission/gamma/851018633677295 response: body: string: '{"result":{"artifact_id":"851018633677295","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-07-30T01:18:57.953044+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -695,11 +695,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=7adb535fe74b357800da978ff12973349110d895928e56b5b0a24049f7894502&community=gamma&require_scan=true + uri: http://ai:9696/v3/search/hash/sha256?hash=7adb535fe74b357800da978ff12973349110d895928e56b5b0a24049f7894502&community=gamma&require_scan=true response: body: string: '' @@ -735,11 +735,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=7adb535fe74b357800da978ff12973349110d895928e56b5b0a24049f7894502&community=gamma&require_scan=false + uri: http://ai:9696/v3/search/hash/sha256?hash=7adb535fe74b357800da978ff12973349110d895928e56b5b0a24049f7894502&community=gamma&require_scan=false response: body: string: '' diff --git a/test/vcr/test_async_hash_search.vcr b/test/vcr/test_async_hash_search.vcr index 1cefe1f2..4bdc112c 100644 --- a/test/vcr/test_async_hash_search.vcr +++ b/test/vcr/test_async_hash_search.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:10:17.414078+00:00","id":"97654789543216667","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/97654789543216667","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0f/52/17/0f521793-56ed-4916-b67d-6f81e57b6bd6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T191017Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=a478d67b7262a94fae1744a085fadf185387395e47a8155936543c9889453eef","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=97654789543216667 + uri: http://ai:9696/v3/instance?id=97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:10:17.414078+00:00","id":"97654789543216667","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/97654789543216667","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0f/52/17/0f521793-56ed-4916-b67d-6f81e57b6bd6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T191017Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=a478d67b7262a94fae1744a085fadf185387395e47a8155936543c9889453eef","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:10:17.414078+00:00","id":"97654789543216667","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/97654789543216667","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0f/52/17/0f521793-56ed-4916-b67d-6f81e57b6bd6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T191017Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=a478d67b7262a94fae1744a085fadf185387395e47a8155936543c9889453eef","votes":[],"window_closed":false},"status":"OK"} @@ -200,11 +200,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -247,11 +247,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -294,11 +294,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -341,11 +341,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -388,11 +388,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -435,11 +435,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -482,11 +482,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -529,11 +529,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -576,11 +576,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -623,11 +623,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -717,11 +717,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -811,11 +811,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -858,11 +858,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -905,11 +905,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -952,11 +952,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -999,11 +999,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1046,11 +1046,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1093,11 +1093,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1234,11 +1234,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1281,11 +1281,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1328,11 +1328,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1375,11 +1375,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1422,11 +1422,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1469,11 +1469,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1516,11 +1516,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1563,11 +1563,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/97654789543216667 + uri: http://ai:9696/v3/consumer/submission/gamma/97654789543216667 response: body: string: '{"result":{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1610,11 +1610,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=180312fb09e9dc626020333682d049e65ba028bd1f7164dad92eb200844af758&community=gamma + uri: http://ai:9696/v3/search/hash/sha256?hash=180312fb09e9dc626020333682d049e65ba028bd1f7164dad92eb200844af758&community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"artifact_id":"97654789543216667","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:10:17.414078+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_async_historical.vcr b/test/vcr/test_async_historical.vcr index 3790dc88..359fb21a 100644 --- a/test/vcr/test_async_historical.vcr +++ b/test/vcr/test_async_historical.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.403459+00:00","failed_max_retries":0,"failed_other":0,"id":"35934095384555821","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -60,11 +60,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/historical?id=35934095384555821&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=35934095384555821&community=gamma response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.403459+00:00","failed_max_retries":0,"failed_other":0,"id":"35934095384555821","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -108,11 +108,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/historical?id=35934095384555821 + uri: http://ai:9696/v3/hunt/historical?id=35934095384555821 response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.403459+00:00","failed_max_retries":0,"failed_other":0,"id":"35934095384555821","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule diff --git a/test/vcr/test_async_historical_results.vcr b/test/vcr/test_async_historical_results.vcr index da17aea1..33303359 100644 --- a/test/vcr/test_async_historical_results.vcr +++ b/test/vcr/test_async_historical_results.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.755351+00:00","failed_max_retries":0,"failed_other":0,"id":"51213972298513151","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -60,11 +60,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/historical/results/list?id=51213972298513151&community=gamma + uri: http://ai:9696/v3/hunt/historical/results/list?id=51213972298513151&community=gamma response: body: string: '' diff --git a/test/vcr/test_async_iocs_by_hash.vcr b/test/vcr/test_async_iocs_by_hash.vcr index 5366bfea..28820560 100644 --- a/test/vcr/test_async_iocs_by_hash.vcr +++ b/test/vcr/test_async_iocs_by_hash.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"72653625433638735","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:19:02.821901+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:19:02.821901+00:00","id":"72653625433638735","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/72653625433638735","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1b/ad/89/1bad89d8-0145-4c96-b1f2-82a836de5dff?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T231902Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=c5a88542e8c41fa2410329df3c71ee74462c14801f1e74019463c5257954abd2","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=72653625433638735 + uri: http://ai:9696/v3/instance?id=72653625433638735 response: body: string: '{"result":{"artifact_id":"72653625433638735","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:19:02.821901+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:19:02.821901+00:00","id":"72653625433638735","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/72653625433638735","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1b/ad/89/1bad89d8-0145-4c96-b1f2-82a836de5dff?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T231902Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=c5a88542e8c41fa2410329df3c71ee74462c14801f1e74019463c5257954abd2","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 72653625433638735.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -494,11 +494,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e&sandbox=cape response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -544,11 +544,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T23:19:10.005447+00:00","tool":"cape_sandbox_v2","tool_metadata":{"extracted_c2_ips":["9.42.36.31"],"extracted_c2_urls":["www.mock-ioc.test"],"ttp":["T1081","T1060","T1069"]},"updated":"2026-06-03T23:19:10.005447+00:00"},"status":"OK"} @@ -586,11 +586,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -628,11 +628,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -712,11 +712,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -754,11 +754,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -796,11 +796,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/547e4965bea116ae4addfdd97f5157db9c2b6bd9c62be781e26ab9aa1f8ed16e?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":["9.42.36.31"],"ttps":["T1069","T1060","T1081"],"urls":[]},"status":"OK"} diff --git a/test/vcr/test_async_known_good_lifecycle.vcr b/test/vcr/test_async_known_good_lifecycle.vcr index 9fcb476d..6a28f7d2 100644 --- a/test/vcr/test_async_known_good_lifecycle.vcr +++ b/test/vcr/test_async_known_good_lifecycle.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: POST - uri: http://artifact-index-e2e:9696/v3/known-good + uri: http://ai:9696/v3/known-good response: body: string: '{"result":{"artifact_instance_id":"99771098961774556","created":"2026-07-29T23:04:40.642152+00:00","id":"73600979008822536","sha256":"d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b","sources":["nsrl"]},"status":"OK"} @@ -57,11 +57,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b?community=gamma response: body: string: '{"errors":{"code":"KNOWN_GOOD","known_good":true,"sources":["nsrl"]},"result":"Unable @@ -99,11 +99,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma&require_scan=false + uri: http://ai:9696/v3/search/hash/sha256?hash=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma&require_scan=false response: body: string: '' @@ -139,11 +139,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma&require_scan=true + uri: http://ai:9696/v3/search/hash/sha256?hash=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma&require_scan=true response: body: string: '' @@ -179,11 +179,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: POST - uri: http://artifact-index-e2e:9696/v3/known-good + uri: http://ai:9696/v3/known-good response: body: string: '{"result":{"artifact_instance_id":"99771098961774556","created":"2026-07-29T23:04:40.642152+00:00","id":"73600979008822536","sha256":"d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b","sources":["commercial","nsrl"]},"status":"OK"} @@ -221,11 +221,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/known-good?sha256=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma + uri: http://ai:9696/v3/known-good?sha256=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma response: body: string: '{"result":{"artifact_instance_id":"99771098961774556","created":"2026-07-29T23:04:40.642152+00:00","id":"73600979008822536","sha256":"d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b","sources":["commercial","nsrl"]},"status":"OK"} @@ -263,11 +263,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b?community=gamma response: body: string: '{"errors":{"code":"KNOWN_GOOD","known_good":true,"sources":["commercial","nsrl"]},"result":"Unable @@ -305,11 +305,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: DELETE - uri: http://artifact-index-e2e:9696/v3/known-good?sha256=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b + uri: http://ai:9696/v3/known-good?sha256=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b response: body: string: '{"result":{"deleted":true,"sha256":"d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b"},"status":"OK"} @@ -347,11 +347,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/known-good?sha256=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma + uri: http://ai:9696/v3/known-good?sha256=d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b&community=gamma response: body: string: '{"errors":null,"result":"No known-good entry found for sha256 d474e08e835f8e538f8aeb6944b4bc73a31db2be96625b0bdfe0ab8bf239226b.","status":"error"} diff --git a/test/vcr/test_async_list_historical.vcr b/test/vcr/test_async_list_historical.vcr index 8a976a44..b05e4c0f 100644 --- a/test/vcr/test_async_list_historical.vcr +++ b/test/vcr/test_async_list_historical.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.504860+00:00","failed_max_retries":0,"failed_other":0,"id":"8290930961482725","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -65,11 +65,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.550525+00:00","failed_max_retries":0,"failed_other":0,"id":"45949838125672986","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -114,11 +114,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.592366+00:00","failed_max_retries":0,"failed_other":0,"id":"15725209613415703","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -163,11 +163,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.656995+00:00","failed_max_retries":0,"failed_other":0,"id":"88826403627398312","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -212,11 +212,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:37:20.695183+00:00","failed_max_retries":0,"failed_other":0,"id":"13919779479626947","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -256,11 +256,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/historical/list?community=gamma + uri: http://ai:9696/v3/hunt/historical/list?community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:37:20.695183+00:00","id":"13919779479626947","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:37:20.656995+00:00","id":"88826403627398312","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:37:20.592366+00:00","id":"15725209613415703","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:37:20.550525+00:00","id":"45949838125672986","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:37:20.504860+00:00","id":"8290930961482725","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.562853+00:00","id":"53359932363657862","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.521466+00:00","id":"24956296142984681","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.480348+00:00","id":"54272719094803031","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.441527+00:00","id":"58288022169534211","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.397319+00:00","id":"86221284475520679","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.255339+00:00","id":"46026864008511354","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:31:26.868688+00:00","id":"51603247373653891","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null}],"status":"OK"} diff --git a/test/vcr/test_async_live.vcr b/test/vcr/test_async_live.vcr index f8644b84..9becae4c 100644 --- a/test/vcr/test_async_live.vcr +++ b/test/vcr/test_async_live.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/rule + uri: http://ai:9696/v3/hunt/rule response: body: string: '{"result":{"created":"2026-06-03T22:37:20.835178+00:00","deleted":false,"description":null,"id":"21319123963942093","livescan_created":null,"livescan_id":null,"modified":"2026-06-03T22:37:20.835178+00:00","name":"sdk-test_async_live","yara":"rule @@ -63,11 +63,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/rule/live + uri: http://ai:9696/v3/hunt/rule/live response: body: string: '{"result":{"created":"2026-06-03T22:37:20.835178+00:00","deleted":false,"description":null,"id":"21319123963942093","livescan_created":"2026-06-03T22:37:20.890721+00:00","livescan_id":null,"modified":"2026-06-03T22:37:20.835178+00:00","name":"sdk-test_async_live","yara":"rule @@ -106,11 +106,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=21319123963942093&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=21319123963942093&community=gamma response: body: string: '{"result":{"created":"2026-06-03T22:37:20.835178+00:00","deleted":false,"description":null,"id":"21319123963942093","livescan_created":"2026-06-03T22:37:20.890721+00:00","livescan_id":88206418106491329,"modified":"2026-06-03T22:37:20.863779+00:00","name":"sdk-test_async_live","yara":"rule @@ -153,11 +153,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"94943400355321313","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:21.946455+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:21.946455+00:00","id":"94943400355321313","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/94943400355321313","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/7e/34/70/7e34708c-caf6-4dd7-b5d2-9e1029e0dafc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223721Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=ef5a83090f1169483ad45b80d4b6bf9bf2a46ca939f4070b11ccc19254e68a8e","votes":[],"window_closed":false},"status":"OK"} @@ -254,11 +254,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=94943400355321313 + uri: http://ai:9696/v3/instance?id=94943400355321313 response: body: string: '{"result":{"artifact_id":"94943400355321313","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:21.946455+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:21.946455+00:00","id":"94943400355321313","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/94943400355321313","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/7e/34/70/7e34708c-caf6-4dd7-b5d2-9e1029e0dafc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223721Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=ef5a83090f1169483ad45b80d4b6bf9bf2a46ca939f4070b11ccc19254e68a8e","votes":[],"window_closed":false},"status":"OK"} @@ -296,11 +296,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -332,11 +332,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -368,11 +368,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -404,11 +404,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -440,11 +440,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -476,11 +476,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -512,11 +512,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -548,11 +548,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -584,11 +584,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -620,11 +620,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -656,11 +656,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -692,11 +692,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -728,11 +728,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -800,11 +800,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -836,11 +836,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -872,11 +872,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -908,11 +908,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -944,11 +944,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -980,11 +980,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1016,11 +1016,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1052,11 +1052,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1088,11 +1088,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1124,11 +1124,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1160,11 +1160,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1196,11 +1196,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1232,11 +1232,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1268,11 +1268,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1304,11 +1304,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1340,11 +1340,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"community":"gamma","created":"2026-06-03T22:37:52.083918+00:00","detections":{"benign":0,"malicious":1,"total":1},"download_url":null,"first_seen":"2026-06-03T22:37:21.946455+00:00","id":"74599466085661100","instance_id":"94943400355321313","livescan_id":"88206418106491329","malware_family":"EICAR","md5":"6ac59cd96a9a3ee9d52f9ebc3ec22f70","polyscore":null,"rule_name":"sdk_test_async_live","sha1":"fade22953ce5af251e2dbd7491124c818bf35e5e","sha256":"ff2b25f3bff7613e391b4d87e32f18c172d531bee5ae562bd13b6421d8b104a5","tags":"{}","yara":null}],"status":"OK"} @@ -1382,11 +1382,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live?id=74599466085661100 + uri: http://ai:9696/v3/hunt/live?id=74599466085661100 response: body: string: '{"result":{"community":"gamma","created":"2026-06-03T22:37:52.083918+00:00","detections":{"benign":0,"malicious":1,"total":1},"download_url":"http://minio:9000/public-cache/ff/2b/25/ff2b25f3bff7613e391b4d87e32f18c172d531bee5ae562bd13b6421d8b104a5fade22953ce5af251e2dbd7491124c818bf35e5e6ac59cd96a9a3ee9d52f9ebc3ec22f70?response-content-disposition=attachment%3Bfilename%3Dinfected&response-content-type=application%2Foctet-stream&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223752Z&X-Amz-Expires=3600&X-Amz-SignedHeaders=host&X-Amz-Signature=d5b9d22359ba7a730490da90c750dafa5f483a11e6d0631784f1badf5ef753ac","first_seen":"2026-06-03T22:37:21.946455+00:00","id":"74599466085661100","instance_id":"94943400355321313","livescan_id":"88206418106491329","malware_family":"EICAR","md5":"6ac59cd96a9a3ee9d52f9ebc3ec22f70","polyscore":null,"rule_name":"sdk_test_async_live","sha1":"fade22953ce5af251e2dbd7491124c818bf35e5e","sha256":"ff2b25f3bff7613e391b4d87e32f18c172d531bee5ae562bd13b6421d8b104a5","tags":"{}","yara":"rule @@ -1429,11 +1429,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/live/list + uri: http://ai:9696/v3/hunt/live/list response: body: string: '{"has_more":true,"limit":50,"result":[{"community":"gamma","created":"2026-06-03T22:37:52.083918+00:00","detections":{"benign":0,"malicious":1,"total":1},"download_url":null,"first_seen":"2026-06-03T22:37:21.946455+00:00","id":"74599466085661100","instance_id":"94943400355321313","livescan_id":"88206418106491329","malware_family":"EICAR","md5":"6ac59cd96a9a3ee9d52f9ebc3ec22f70","polyscore":null,"rule_name":"sdk_test_async_live","sha1":"fade22953ce5af251e2dbd7491124c818bf35e5e","sha256":"ff2b25f3bff7613e391b4d87e32f18c172d531bee5ae562bd13b6421d8b104a5","tags":"{}","yara":null}],"status":"OK"} @@ -1471,11 +1471,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live?id=74599466085661100 + uri: http://ai:9696/v3/hunt/live?id=74599466085661100 response: body: string: '{"errors":null,"result":"Could not find requested live hunt result: @@ -1516,11 +1516,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule/live + uri: http://ai:9696/v3/hunt/rule/live response: body: string: '{"result":{"created":"2026-06-03T22:37:20.835178+00:00","deleted":false,"description":null,"id":"21319123963942093","livescan_created":"2026-06-03T22:37:20.890721+00:00","livescan_id":88206418106491329,"modified":"2026-06-03T22:37:20.863779+00:00","name":"sdk-test_async_live","yara":"rule @@ -1559,11 +1559,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=21319123963942093&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=21319123963942093&community=gamma response: body: string: '{"result":{"created":"2026-06-03T22:37:20.835178+00:00","deleted":false,"description":null,"id":"21319123963942093","livescan_created":"2026-06-03T22:37:20.890721+00:00","livescan_id":null,"modified":"2026-06-03T22:37:52.675202+00:00","name":"sdk-test_async_live","yara":"rule @@ -1606,11 +1606,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule/live + uri: http://ai:9696/v3/hunt/rule/live response: body: string: '{"errors":null,"result":"Ruleset does not have an active live scan.","status":"error"} @@ -1650,11 +1650,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=21319123963942093 + uri: http://ai:9696/v3/hunt/rule?id=21319123963942093 response: body: string: '{"result":{"created":"2026-06-03T22:37:20.835178+00:00","deleted":true,"description":null,"id":"21319123963942093","livescan_created":"2026-06-03T22:37:20.890721+00:00","livescan_id":null,"modified":"2026-06-03T22:37:52.675202+00:00","name":"sdk-test_async_live","yara":"rule diff --git a/test/vcr/test_async_metadata_search.vcr b/test/vcr/test_async_metadata_search.vcr index 8a3fe29b..c9a7586d 100644 --- a/test/vcr/test_async_metadata_search.vcr +++ b/test/vcr/test_async_metadata_search.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:10:48.240029+00:00","id":"98211506705718323","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/98211506705718323","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/7d/79/ef/7d79ef33-48d4-46cb-9b21-72c015b2b3e4?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T191048Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=970031a0357731c2b8e4436487f3cf58c1064e99fe8a27f997548625b9f91f61","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=98211506705718323 + uri: http://ai:9696/v3/instance?id=98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:10:48.240029+00:00","id":"98211506705718323","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/98211506705718323","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/7d/79/ef/7d79ef33-48d4-46cb-9b21-72c015b2b3e4?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T191048Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=970031a0357731c2b8e4436487f3cf58c1064e99fe8a27f997548625b9f91f61","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:10:48.240029+00:00","id":"98211506705718323","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/98211506705718323","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/7d/79/ef/7d79ef33-48d4-46cb-9b21-72c015b2b3e4?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T191048Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=970031a0357731c2b8e4436487f3cf58c1064e99fe8a27f997548625b9f91f61","votes":[],"window_closed":false},"status":"OK"} @@ -200,11 +200,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -247,11 +247,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -294,11 +294,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -341,11 +341,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -388,11 +388,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -435,11 +435,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -482,11 +482,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -529,11 +529,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -576,11 +576,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -623,11 +623,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -717,11 +717,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -811,11 +811,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -858,11 +858,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -905,11 +905,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -952,11 +952,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -999,11 +999,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1046,11 +1046,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1093,11 +1093,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1234,11 +1234,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1281,11 +1281,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1328,11 +1328,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1375,11 +1375,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1422,11 +1422,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1469,11 +1469,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1516,11 +1516,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1563,11 +1563,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/98211506705718323 + uri: http://ai:9696/v3/consumer/submission/gamma/98211506705718323 response: body: string: '{"result":{"artifact_id":"98211506705718323","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:10:48.240029+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1610,11 +1610,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/search/metadata/query?query=artifact.sha256%3Aaac70fdc613bbb9dde083a8230cbf576dd8c68c02d8e47047420cd67f6ff4895&community=gamma + uri: http://ai:9696/v3/search/metadata/query?query=artifact.sha256%3Aaac70fdc613bbb9dde083a8230cbf576dd8c68c02d8e47047420cd67f6ff4895&community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"artifact":{"created":"2026-06-05T18:57:52.467724+00:00","id":"83884896733565390","md5":"0c1f216df4714fed5a330e73aefb626a","sha1":"dec06c43c2c77a453860dd0663739e10c12ed47d","sha256":"aac70fdc613bbb9dde083a8230cbf576dd8c68c02d8e47047420cd67f6ff4895","size":95},"exiftool":{"filesize":"95 diff --git a/test/vcr/test_async_rescans.vcr b/test/vcr/test_async_rescans.vcr index a865fdbc..63a42902 100644 --- a/test/vcr/test_async_rescans.vcr +++ b/test/vcr/test_async_rescans.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"64169538086358193","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:09:15.708498+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:09:15.708498+00:00","id":"64169538086358193","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/64169538086358193","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/cb/5b/55/cb5b556f-52f5-4407-b2d9-1643d665fa1f?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190915Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=27d2e9d62bef616804aaf1c3d8332598db794fb121bb9b9d9e0d72fd694e86b9","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=64169538086358193 + uri: http://ai:9696/v3/instance?id=64169538086358193 response: body: string: '{"result":{"artifact_id":"64169538086358193","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:09:15.708498+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:09:15.708498+00:00","id":"64169538086358193","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/64169538086358193","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/cb/5b/55/cb5b556f-52f5-4407-b2d9-1643d665fa1f?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190915Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=27d2e9d62bef616804aaf1c3d8332598db794fb121bb9b9d9e0d72fd694e86b9","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/x-www-form-urlencoded host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/rescan/sha256/2c2980cb27db9b3584bfb16c84feff262279b7e666ba42b96ee285b2aa0dc524 + uri: http://ai:9696/v3/consumer/submission/gamma/rescan/sha256/2c2980cb27db9b3584bfb16c84feff262279b7e666ba42b96ee285b2aa0dc524 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[],"bounty_state":1,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -205,11 +205,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -248,11 +248,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -295,11 +295,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -342,11 +342,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -389,11 +389,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -436,11 +436,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -483,11 +483,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -530,11 +530,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -577,11 +577,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -624,11 +624,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -671,11 +671,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -718,11 +718,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -765,11 +765,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -812,11 +812,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -859,11 +859,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -906,11 +906,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -953,11 +953,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1000,11 +1000,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1047,11 +1047,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1094,11 +1094,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1141,11 +1141,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1188,11 +1188,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1235,11 +1235,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1282,11 +1282,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1329,11 +1329,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1376,11 +1376,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1423,11 +1423,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1470,11 +1470,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1517,11 +1517,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1564,11 +1564,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1611,11 +1611,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/5315742191955108 response: body: string: '{"result":{"artifact_id":"5315742191955108","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:09:15.766548+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1660,11 +1660,11 @@ interactions: content-length: - '0' host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/rescan/5315742191955108 + uri: http://ai:9696/v3/consumer/submission/gamma/rescan/5315742191955108 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[],"bounty_state":1,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1703,11 +1703,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1746,11 +1746,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1793,11 +1793,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1840,11 +1840,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1887,11 +1887,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1934,11 +1934,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1981,11 +1981,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2028,11 +2028,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2075,11 +2075,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2122,11 +2122,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2169,11 +2169,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2216,11 +2216,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2263,11 +2263,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2310,11 +2310,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2357,11 +2357,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2404,11 +2404,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2451,11 +2451,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2498,11 +2498,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2545,11 +2545,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2592,11 +2592,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2639,11 +2639,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2686,11 +2686,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2733,11 +2733,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2780,11 +2780,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2827,11 +2827,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2874,11 +2874,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2921,11 +2921,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2968,11 +2968,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3015,11 +3015,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3062,11 +3062,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3109,11 +3109,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/38302166752497486 + uri: http://ai:9696/v3/consumer/submission/gamma/38302166752497486 response: body: string: '{"result":{"artifact_id":"38302166752497486","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:09:46.630448+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_async_rules.vcr b/test/vcr/test_async_rules.vcr index fc6324d1..751c4b2a 100644 --- a/test/vcr/test_async_rules.vcr +++ b/test/vcr/test_async_rules.vcr @@ -26,11 +26,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/rule + uri: http://ai:9696/v3/hunt/rule response: body: string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":null,"id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test","yara":"rule @@ -81,11 +81,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule/list?community=gamma + uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":null,"id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test","yara":null}],"status":"OK"} @@ -123,11 +123,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=40732127887168358&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=40732127887168358&community=gamma response: body: string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":null,"id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test","yara":"rule @@ -182,11 +182,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=40732127887168358 + uri: http://ai:9696/v3/hunt/rule?id=40732127887168358 response: body: string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":"test","id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test2","yara":"rule @@ -241,11 +241,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=40732127887168358 + uri: http://ai:9696/v3/hunt/rule?id=40732127887168358 response: body: string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":true,"description":"test","id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.152617+00:00","name":"test2","yara":"rule @@ -296,11 +296,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule/list?community=gamma + uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: string: '' diff --git a/test/vcr/test_async_sample.vcr b/test/vcr/test_async_sample.vcr index a155fa96..96589f43 100644 --- a/test/vcr/test_async_sample.vcr +++ b/test/vcr/test_async_sample.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"53155931477724566","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:51:48.054788+00:00","id":"53155931477724566","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/53155931477724566","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/00/53/ba/0053ba29-3b8f-44f1-acf2-ac2c70284952?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225148Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=44f29d84b6979893fc339dbe40edbbc4c94c9aedb34b000da8d5edd74e3a650b","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=53155931477724566 + uri: http://ai:9696/v3/instance?id=53155931477724566 response: body: string: '{"result":{"artifact_id":"53155931477724566","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:51:48.054788+00:00","id":"53155931477724566","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/53155931477724566","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/00/53/ba/0053ba29-3b8f-44f1-acf2-ac2c70284952?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225148Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=44f29d84b6979893fc339dbe40edbbc4c94c9aedb34b000da8d5edd74e3a650b","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 53155931477724566.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -935,11 +935,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -986,11 +986,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1037,11 +1037,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1088,11 +1088,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1139,11 +1139,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1190,11 +1190,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1241,11 +1241,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1300,11 +1300,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1359,11 +1359,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1418,11 +1418,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1477,11 +1477,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1536,11 +1536,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1595,11 +1595,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1654,11 +1654,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1713,11 +1713,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1772,11 +1772,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1831,11 +1831,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1890,11 +1890,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1949,11 +1949,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2008,11 +2008,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2067,11 +2067,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2126,11 +2126,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2185,11 +2185,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 + uri: http://ai:9696/v3/sample/525bc9e282258a89e633d88668239b0f9bd90ea02a5665a9438949a4b5ec9062 response: body: string: '{"result":{"artifact_instance":{"artifact_id":"53155931477724566","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-03T22:51:48.054788+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_async_sandbox_providers.vcr b/test/vcr/test_async_sandbox_providers.vcr index 395fcd21..143a9271 100644 --- a/test/vcr/test_async_sandbox_providers.vcr +++ b/test/vcr/test_async_sandbox_providers.vcr @@ -11,11 +11,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/provider/list + uri: http://ai:9696/v3/sandbox/provider/list response: body: string: '{"result":{"cape":{"id":"1","name":"cape","slug":"cape","tool":"cape_sandbox_v2","vms":{"win-10-build-19041":{"architecture":"x64","id":"100","language":"English diff --git a/test/vcr/test_async_sandboxtask_latest.vcr b/test/vcr/test_async_sandboxtask_latest.vcr index 4942cd63..559e6a9f 100644 --- a/test/vcr/test_async_sandboxtask_latest.vcr +++ b/test/vcr/test_async_sandboxtask_latest.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"6649978215910256","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:51:35.303597+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:51:35.303597+00:00","id":"6649978215910256","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/6649978215910256","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0c/df/2c/0cdf2c70-78ce-4c17-a5a6-5b255b7957d3?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225135Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=6381450cc3d48e81f67defa29d1c1cea6a2a68a54d831eaf4dddd2d64d110ff2","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=6649978215910256 + uri: http://ai:9696/v3/instance?id=6649978215910256 response: body: string: '{"result":{"artifact_id":"6649978215910256","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:51:35.303597+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:51:35.303597+00:00","id":"6649978215910256","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/6649978215910256","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0c/df/2c/0cdf2c70-78ce-4c17-a5a6-5b255b7957d3?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225135Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=6381450cc3d48e81f67defa29d1c1cea6a2a68a54d831eaf4dddd2d64d110ff2","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 6649978215910256.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -931,11 +931,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -971,11 +971,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1011,11 +1011,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1051,11 +1051,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1091,11 +1091,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1131,11 +1131,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=cape response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -1177,11 +1177,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=triage + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=7afc273dfa8e1198063a20272c314fd48414bec77f98d6878666364f24680747&sandbox=triage response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR diff --git a/test/vcr/test_async_sandboxtask_list.vcr b/test/vcr/test_async_sandboxtask_list.vcr index 5ab46b8b..46f089e6 100644 --- a/test/vcr/test_async_sandboxtask_list.vcr +++ b/test/vcr/test_async_sandboxtask_list.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"49659709795584114","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:51:47.794622+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:51:47.794622+00:00","id":"49659709795584114","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/49659709795584114","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/c0/5a/6c/c05a6cde-fdf1-4277-9752-decaf874df67?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225147Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=9f3d8ec09ef3c2a66a375cdefbd5a7b59798bcbe0dcaac133140b9adf36c7365","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=49659709795584114 + uri: http://ai:9696/v3/instance?id=49659709795584114 response: body: string: '{"result":{"artifact_id":"49659709795584114","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:51:47.794622+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:51:47.794622+00:00","id":"49659709795584114","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/49659709795584114","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/c0/5a/6c/c05a6cde-fdf1-4277-9752-decaf874df67?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225147Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=9f3d8ec09ef3c2a66a375cdefbd5a7b59798bcbe0dcaac133140b9adf36c7365","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -211,11 +211,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -256,11 +256,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123 + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123 response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR @@ -304,11 +304,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123&sandbox=cape response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR @@ -349,11 +349,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123&sandbox=triage + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123&sandbox=triage response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR @@ -394,11 +394,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123 + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=a25755bdc34758030825c334a87fadf2f690d648dd1af0bc82e826bf084e5123 response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR diff --git a/test/vcr/test_async_sandboxtask_submit.vcr b/test/vcr/test_async_sandboxtask_submit.vcr index d7653230..c435ba12 100644 --- a/test/vcr/test_async_sandboxtask_submit.vcr +++ b/test/vcr/test_async_sandboxtask_submit.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"87578351900465983","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:19.165140+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:19.165140+00:00","id":"87578351900465983","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/87578351900465983","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0b/d6/30/0bd630bc-491f-4049-a6a8-59b5a2f13de0?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223719Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=63e5974584d075ef736ff464f48f4149ac18976399474fbb849cd8401aaf1933","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=87578351900465983 + uri: http://ai:9696/v3/instance?id=87578351900465983 response: body: string: '{"result":{"artifact_id":"87578351900465983","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:19.165140+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:19.165140+00:00","id":"87578351900465983","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/87578351900465983","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/0b/d6/30/0bd630bc-491f-4049-a6a8-59b5a2f13de0?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223719Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=63e5974584d075ef736ff464f48f4149ac18976399474fbb849cd8401aaf1933","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 87578351900465983.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR diff --git a/test/vcr/test_async_search_by_ioc.vcr b/test/vcr/test_async_search_by_ioc.vcr index 050413c0..4e7f389a 100644 --- a/test/vcr/test_async_search_by_ioc.vcr +++ b/test/vcr/test_async_search_by_ioc.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"52135846770494741","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:20:50.651682+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:20:50.651682+00:00","id":"52135846770494741","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/52135846770494741","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/fc/a4/6b/fca46b8f-0e9a-4dda-8586-c05bc3f33c1a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T222050Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=e62d91405cc9e5631d75d60970c16ff249d0371e412fa11628ca19b28fb88b6e","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=52135846770494741 + uri: http://ai:9696/v3/instance?id=52135846770494741 response: body: string: '{"result":{"artifact_id":"52135846770494741","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:20:50.651682+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:20:50.651682+00:00","id":"52135846770494741","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/52135846770494741","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/fc/a4/6b/fca46b8f-0e9a-4dda-8586-c05bc3f33c1a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T222050Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=e62d91405cc9e5631d75d60970c16ff249d0371e412fa11628ca19b28fb88b6e","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T22:20:50.701441+00:00","tool":"cape_sandbox_v2","tool_metadata":{"extracted_c2_ips":["9.42.154.68"],"extracted_c2_urls":["www.mock-ioc.test"],"ttp":["T1081","T1060","T1069"]},"updated":"2026-06-03T22:20:50.701441+00:00"},"status":"OK"} @@ -204,11 +204,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -240,11 +240,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -276,11 +276,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -312,11 +312,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -348,11 +348,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -384,11 +384,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -420,11 +420,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -456,11 +456,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -492,11 +492,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -528,11 +528,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -564,11 +564,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -600,11 +600,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -636,11 +636,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -672,11 +672,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -708,11 +708,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -744,11 +744,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -780,11 +780,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -816,11 +816,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -852,11 +852,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -888,11 +888,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -924,11 +924,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -960,11 +960,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -996,11 +996,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -1032,11 +1032,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -1068,11 +1068,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -1104,11 +1104,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '' @@ -1176,11 +1176,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.154.68 response: body: string: '{"has_more":false,"limit":50,"result":["903b32d15854635ff609c18fcdd686ce8b23b65ab7f451876555cd66d7135137"],"status":"OK"} diff --git a/test/vcr/test_async_submission.vcr b/test/vcr/test_async_submission.vcr index dc61155f..25dffcf7 100644 --- a/test/vcr/test_async_submission.vcr +++ b/test/vcr/test_async_submission.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:08:44.930117+00:00","id":"92227041984381888","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/92227041984381888","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d3/df/46/d3df46d3-4f2f-4c73-bd31-96d9efecd805?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190844Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=79448ae981813376f6bce62faa255bebcc7266855afb5cd4a8f38a1f060b44e7","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=92227041984381888 + uri: http://ai:9696/v3/instance?id=92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:08:44.930117+00:00","id":"92227041984381888","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/92227041984381888","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d3/df/46/d3df46d3-4f2f-4c73-bd31-96d9efecd805?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190844Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=79448ae981813376f6bce62faa255bebcc7266855afb5cd4a8f38a1f060b44e7","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:08:44.930117+00:00","id":"92227041984381888","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/92227041984381888","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d3/df/46/d3df46d3-4f2f-4c73-bd31-96d9efecd805?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190844Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=79448ae981813376f6bce62faa255bebcc7266855afb5cd4a8f38a1f060b44e7","votes":[],"window_closed":false},"status":"OK"} @@ -200,11 +200,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -247,11 +247,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -294,11 +294,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -341,11 +341,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -388,11 +388,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -435,11 +435,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -482,11 +482,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -529,11 +529,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -576,11 +576,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -623,11 +623,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -717,11 +717,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -811,11 +811,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -858,11 +858,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -905,11 +905,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -952,11 +952,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -999,11 +999,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1046,11 +1046,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1093,11 +1093,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1234,11 +1234,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1281,11 +1281,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1328,11 +1328,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1375,11 +1375,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1422,11 +1422,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1469,11 +1469,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1516,11 +1516,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1563,11 +1563,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/92227041984381888 + uri: http://ai:9696/v3/consumer/submission/gamma/92227041984381888 response: body: string: '{"result":{"artifact_id":"92227041984381888","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:08:44.930117+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_async_tool_metadata.vcr b/test/vcr/test_async_tool_metadata.vcr index 65f44a3b..de9e03b9 100644 --- a/test/vcr/test_async_tool_metadata.vcr +++ b/test/vcr/test_async_tool_metadata.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"29849643211896425","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:52.795919+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:52.795919+00:00","id":"29849643211896425","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/29849643211896425","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/12/cc/95/12cc955a-e8f5-4ab1-9804-bdc2b9986eea?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223752Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d6830b08c0f0cb4002aa8dc6598f7517407c5ce4a33aa43385efdfeb200990a1","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=29849643211896425 + uri: http://ai:9696/v3/instance?id=29849643211896425 response: body: string: '{"result":{"artifact_id":"29849643211896425","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:37:52.795919+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:37:52.795919+00:00","id":"29849643211896425","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/29849643211896425","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/12/cc/95/12cc955a-e8f5-4ab1-9804-bdc2b9986eea?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223752Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d6830b08c0f0cb4002aa8dc6598f7517407c5ce4a33aa43385efdfeb200990a1","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T22:37:52.838776+00:00","tool":"test_tool_1","tool_metadata":{"key":"value"},"updated":"2026-06-03T22:37:52.838776+00:00"},"status":"OK"} @@ -208,11 +208,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T22:37:52.855377+00:00","tool":"test_tool_2","tool_metadata":{"key2":"value2"},"updated":"2026-06-03T22:37:52.855377+00:00"},"status":"OK"} @@ -250,11 +250,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/artifact/metadata/list?instance_id=29849643211896425 + uri: http://ai:9696/v3/artifact/metadata/list?instance_id=29849643211896425 response: body: string: '{"has_more":false,"limit":50,"result":[{"created":"2026-06-03T22:37:52.858234+00:00","tool":"test_tool_2","tool_metadata":{"key2":"value2"},"updated":"2026-06-03T22:37:52.858234+00:00"},{"created":"2026-06-03T22:37:52.843573+00:00","tool":"test_tool_1","tool_metadata":{"key":"value"},"updated":"2026-06-03T22:37:52.843573+00:00"}],"status":"OK"} diff --git a/test/vcr/test_async_update_known_good_host.vcr b/test/vcr/test_async_update_known_good_host.vcr index 50cba1b1..45f67df6 100644 --- a/test/vcr/test_async_update_known_good_host.vcr +++ b/test/vcr/test_async_update_known_good_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"test-async-update-known-good-host.sdk.test","id":6,"source":"test","type":"domain"},"status":"OK"} @@ -61,11 +61,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"9.42.182.192","id":6,"source":"test","type":"ip"},"status":"OK"} diff --git a/test/vcr/test_check_known_host.vcr b/test/vcr/test_check_known_host.vcr index cb1af878..62f1edea 100644 --- a/test/vcr/test_check_known_host.vcr +++ b/test/vcr/test_check_known_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"9.42.37.148","id":2,"source":"test","type":"ip"},"status":"OK"} @@ -57,11 +57,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/known?ip=9.42.37.148 + uri: http://ai:9696/v3/ioc/known?ip=9.42.37.148 response: body: string: '{"result":[{"good":true,"host":"9.42.37.148","id":2,"source":"test","type":"ip"}],"status":"OK"} diff --git a/test/vcr/test_delete_known_good_host.vcr b/test/vcr/test_delete_known_good_host.vcr index a419131a..8b36adda 100644 --- a/test/vcr/test_delete_known_good_host.vcr +++ b/test/vcr/test_delete_known_good_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"test-delete-known-good-host.sdk.test","id":3,"source":"test","type":"domain"},"status":"OK"} @@ -57,11 +57,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/ioc/known?id=3 + uri: http://ai:9696/v3/ioc/known?id=3 response: body: string: '{"result":{"good":true,"host":"test-delete-known-good-host.sdk.test","id":3,"source":"test","type":"domain"},"status":"OK"} diff --git a/test/vcr/test_download.vcr b/test/vcr/test_download.vcr index 07b76e86..cbfb7190 100644 --- a/test/vcr/test_download.vcr +++ b/test/vcr/test_download.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"93011363713565479","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:35:43.769716+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:35:43.769716+00:00","id":"93011363713565479","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/93011363713565479","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/6a/84/2d/6a842dd6-5eed-418e-ad78-4e13aef3c4ec?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223543Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d9211c5eefb2f83a085cf86a5b67ad7d15d24d221c95ce886fd3e72f2a6f470f","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=93011363713565479 + uri: http://ai:9696/v3/instance?id=93011363713565479 response: body: string: '{"result":{"artifact_id":"93011363713565479","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:35:43.769716+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:35:43.769716+00:00","id":"93011363713565479","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/93011363713565479","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/6a/84/2d/6a842dd6-5eed-418e-ad78-4e13aef3c4ec?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223543Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d9211c5eefb2f83a085cf86a5b67ad7d15d24d221c95ce886fd3e72f2a6f470f","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/411f392d6a42f76e585b15c7fb948345c24488a5a1d504f861c5f65766999dfc?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/411f392d6a42f76e585b15c7fb948345c24488a5a1d504f861c5f65766999dfc?community=gamma response: body: string: '{"errors":null,"result":"No instance found for the hash sha256=411f392d6a42f76e585b15c7fb948345c24488a5a1d504f861c5f65766999dfc @@ -199,11 +199,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/411f392d6a42f76e585b15c7fb948345c24488a5a1d504f861c5f65766999dfc?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/411f392d6a42f76e585b15c7fb948345c24488a5a1d504f861c5f65766999dfc?community=gamma response: body: string: ' diff --git a/test/vcr/test_download_to_handle.vcr b/test/vcr/test_download_to_handle.vcr index a92ccbfc..afff790b 100644 --- a/test/vcr/test_download_to_handle.vcr +++ b/test/vcr/test_download_to_handle.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"29152862847351025","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:35:44.915261+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:35:44.915261+00:00","id":"29152862847351025","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/29152862847351025","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/37/13/1a/37131a9d-bf28-40c8-8095-567dbf778ba5?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223544Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=3a8929adc02e7b591f861614ff264c593dfab4ad913679679db0e17d8efc69e9","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=29152862847351025 + uri: http://ai:9696/v3/instance?id=29152862847351025 response: body: string: '{"result":{"artifact_id":"29152862847351025","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:35:44.915261+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:35:44.915261+00:00","id":"29152862847351025","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/29152862847351025","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/37/13/1a/37131a9d-bf28-40c8-8095-567dbf778ba5?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223544Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=3a8929adc02e7b591f861614ff264c593dfab4ad913679679db0e17d8efc69e9","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/bee565ba44c3d33c79d550681ac02b983910ca2da4653dad27d5fd89af3d11ac?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/bee565ba44c3d33c79d550681ac02b983910ca2da4653dad27d5fd89af3d11ac?community=gamma response: body: string: '{"errors":null,"result":"No instance found for the hash sha256=bee565ba44c3d33c79d550681ac02b983910ca2da4653dad27d5fd89af3d11ac @@ -199,11 +199,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/bee565ba44c3d33c79d550681ac02b983910ca2da4653dad27d5fd89af3d11ac?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/bee565ba44c3d33c79d550681ac02b983910ca2da4653dad27d5fd89af3d11ac?community=gamma response: body: string: ' diff --git a/test/vcr/test_hash_existence_probe_against_the_real_server.vcr b/test/vcr/test_hash_existence_probe_against_the_real_server.vcr index e67fba98..d10cf98a 100644 --- a/test/vcr/test_hash_existence_probe_against_the_real_server.vcr +++ b/test/vcr/test_hash_existence_probe_against_the_real_server.vcr @@ -11,11 +11,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=8114c0209d6e20ad5a8cbec01782f065be5cf9804d78801a90583e04551c05a8&community=gamma&require_scan=false + uri: http://ai:9696/v3/search/hash/sha256?hash=8114c0209d6e20ad5a8cbec01782f065be5cf9804d78801a90583e04551c05a8&community=gamma&require_scan=false response: body: string: '' @@ -47,11 +47,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=8114c0209d6e20ad5a8cbec01782f065be5cf9804d78801a90583e04551c05a8&community=gamma&require_scan=true + uri: http://ai:9696/v3/search/hash/sha256?hash=8114c0209d6e20ad5a8cbec01782f065be5cf9804d78801a90583e04551c05a8&community=gamma&require_scan=true response: body: string: '' @@ -87,11 +87,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-07-30T01:18:50.605483+00:00","id":"88492900747453910","known_good":null,"last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/88492900747453910","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"state":"CREATED","type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/68/f7/8e/68f78e92-72a3-47ab-a126-55a836c38bf6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260730%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260730T011850Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=2fb4d42512b5103856af4c1f5f8e51d2ce3ca5557f30aa8e9125a55fa310eccd","votes":[],"window_closed":false},"status":"OK"} @@ -188,11 +188,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=88492900747453910 + uri: http://ai:9696/v3/instance?id=88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-07-30T01:18:50.605483+00:00","id":"88492900747453910","known_good":null,"last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/88492900747453910","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"state":"CREATED","type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/68/f7/8e/68f78e92-72a3-47ab-a126-55a836c38bf6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260730%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260730T011850Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=2fb4d42512b5103856af4c1f5f8e51d2ce3ca5557f30aa8e9125a55fa310eccd","votes":[],"window_closed":false},"status":"OK"} @@ -230,11 +230,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-07-30T01:18:50.605483+00:00","id":"88492900747453910","known_good":null,"last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/88492900747453910","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"state":"CREATED","type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/68/f7/8e/68f78e92-72a3-47ab-a126-55a836c38bf6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260730%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260730T011850Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=2fb4d42512b5103856af4c1f5f8e51d2ce3ca5557f30aa8e9125a55fa310eccd","votes":[],"window_closed":false},"status":"OK"} @@ -272,11 +272,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -319,11 +319,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -366,11 +366,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -413,11 +413,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -460,11 +460,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -507,11 +507,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -554,11 +554,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/88492900747453910 + uri: http://ai:9696/v3/consumer/submission/gamma/88492900747453910 response: body: string: '{"result":{"artifact_id":"88492900747453910","assertions":[{"author":"86494354581135","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-07-30T01:18:50.605483+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -601,11 +601,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=1d74a0b7915342db3f07dc10d2f4ac9160d7fb6dc70c2956e8d0dd2fd2dcbc58&community=gamma&require_scan=true + uri: http://ai:9696/v3/search/hash/sha256?hash=1d74a0b7915342db3f07dc10d2f4ac9160d7fb6dc70c2956e8d0dd2fd2dcbc58&community=gamma&require_scan=true response: body: string: '' @@ -641,11 +641,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.14.4) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=1d74a0b7915342db3f07dc10d2f4ac9160d7fb6dc70c2956e8d0dd2fd2dcbc58&community=gamma&require_scan=false + uri: http://ai:9696/v3/search/hash/sha256?hash=1d74a0b7915342db3f07dc10d2f4ac9160d7fb6dc70c2956e8d0dd2fd2dcbc58&community=gamma&require_scan=false response: body: string: '' diff --git a/test/vcr/test_hash_search.vcr b/test/vcr/test_hash_search.vcr index 139e8c07..a206f5ef 100644 --- a/test/vcr/test_hash_search.vcr +++ b/test/vcr/test_hash_search.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:06:09.660618+00:00","id":"76173666141586127","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/76173666141586127","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/16/00/6b/16006bec-c2e5-4ac3-8078-514e5d7d03a9?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190609Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=8168aa41f19ea466ad4d22b80d15ab53cfa6238bba31e84a0e95aaf853d34c20","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=76173666141586127 + uri: http://ai:9696/v3/instance?id=76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:06:09.660618+00:00","id":"76173666141586127","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/76173666141586127","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/16/00/6b/16006bec-c2e5-4ac3-8078-514e5d7d03a9?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190609Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=8168aa41f19ea466ad4d22b80d15ab53cfa6238bba31e84a0e95aaf853d34c20","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:06:09.660618+00:00","id":"76173666141586127","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/76173666141586127","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/16/00/6b/16006bec-c2e5-4ac3-8078-514e5d7d03a9?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190609Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=8168aa41f19ea466ad4d22b80d15ab53cfa6238bba31e84a0e95aaf853d34c20","votes":[],"window_closed":false},"status":"OK"} @@ -200,11 +200,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -247,11 +247,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -294,11 +294,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -341,11 +341,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -388,11 +388,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -435,11 +435,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -482,11 +482,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -529,11 +529,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -576,11 +576,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -623,11 +623,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -717,11 +717,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -811,11 +811,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -858,11 +858,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -905,11 +905,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -952,11 +952,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -999,11 +999,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1046,11 +1046,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1093,11 +1093,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1234,11 +1234,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1281,11 +1281,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1328,11 +1328,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1375,11 +1375,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1422,11 +1422,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1469,11 +1469,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1516,11 +1516,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1563,11 +1563,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/76173666141586127 + uri: http://ai:9696/v3/consumer/submission/gamma/76173666141586127 response: body: string: '{"result":{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1610,11 +1610,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=2895784d40a16a2d013161de9fa4400b92cf63288412fbef8e105975c92fb39d&community=gamma + uri: http://ai:9696/v3/search/hash/sha256?hash=2895784d40a16a2d013161de9fa4400b92cf63288412fbef8e105975c92fb39d&community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"artifact_id":"76173666141586127","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:06:09.660618+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_historical.vcr b/test/vcr/test_historical.vcr index a42c5de7..28a8b201 100644 --- a/test/vcr/test_historical.vcr +++ b/test/vcr/test_historical.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.115323+00:00","failed_max_retries":0,"failed_other":0,"id":"29328811284340624","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -59,11 +59,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/historical?id=29328811284340624&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=29328811284340624&community=gamma response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.115323+00:00","failed_max_retries":0,"failed_other":0,"id":"29328811284340624","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -106,11 +106,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/historical?id=29328811284340624 + uri: http://ai:9696/v3/hunt/historical?id=29328811284340624 response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.115323+00:00","failed_max_retries":0,"failed_other":0,"id":"29328811284340624","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule diff --git a/test/vcr/test_historical_results.vcr b/test/vcr/test_historical_results.vcr index 52203f6d..1756c2ff 100644 --- a/test/vcr/test_historical_results.vcr +++ b/test/vcr/test_historical_results.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.255339+00:00","failed_max_retries":0,"failed_other":0,"id":"46026864008511354","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -60,11 +60,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/historical/results/list?id=46026864008511354&community=gamma + uri: http://ai:9696/v3/hunt/historical/results/list?id=46026864008511354&community=gamma response: body: string: '' diff --git a/test/vcr/test_iocs_by_hash.vcr b/test/vcr/test_iocs_by_hash.vcr index 634f7a35..10b6366a 100644 --- a/test/vcr/test_iocs_by_hash.vcr +++ b/test/vcr/test_iocs_by_hash.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"7779577867950164","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:18:50.373264+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:18:50.373264+00:00","id":"7779577867950164","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/7779577867950164","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/89/e3/02/89e3022b-9d27-4339-b494-f98261dd98fc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T231850Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=54593b7ba65161b3f14a287d571dce9165c785e2478008d4aafc41665cc089f9","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=7779577867950164 + uri: http://ai:9696/v3/instance?id=7779577867950164 response: body: string: '{"result":{"artifact_id":"7779577867950164","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:18:50.373264+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:18:50.373264+00:00","id":"7779577867950164","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/7779577867950164","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/89/e3/02/89e3022b-9d27-4339-b494-f98261dd98fc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T231850Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=54593b7ba65161b3f14a287d571dce9165c785e2478008d4aafc41665cc089f9","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 7779577867950164.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -494,11 +494,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee&sandbox=cape response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -544,11 +544,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T23:18:57.545540+00:00","tool":"cape_sandbox_v2","tool_metadata":{"extracted_c2_ips":["9.42.121.179"],"extracted_c2_urls":["www.mock-ioc.test"],"ttp":["T1081","T1060","T1069"]},"updated":"2026-06-03T23:18:57.545540+00:00"},"status":"OK"} @@ -586,11 +586,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -628,11 +628,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -712,11 +712,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -754,11 +754,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":[],"ttps":[],"urls":[]},"status":"OK"} @@ -796,11 +796,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma + uri: http://ai:9696/v3/ioc/sha256/1e09244674510371328fa46a23f9705ad52f1dc959884db384a34ed4c84464ee?hide_known_good=False&community=gamma response: body: string: '{"result":{"imphash":"","ips":["9.42.121.179"],"ttps":["T1069","T1060","T1081"],"urls":[]},"status":"OK"} diff --git a/test/vcr/test_known_good_lifecycle.vcr b/test/vcr/test_known_good_lifecycle.vcr index dea39d68..6c249b56 100644 --- a/test/vcr/test_known_good_lifecycle.vcr +++ b/test/vcr/test_known_good_lifecycle.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: POST - uri: http://artifact-index-e2e:9696/v3/known-good + uri: http://ai:9696/v3/known-good response: body: string: '{"result":{"artifact_instance_id":"38756881504693724","created":"2026-07-29T23:04:40.151450+00:00","id":"31218224787620566","sha256":"9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df","sources":["nsrl"]},"status":"OK"} @@ -57,11 +57,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df?community=gamma response: body: string: '{"errors":{"code":"KNOWN_GOOD","known_good":true,"sources":["nsrl"]},"result":"Unable @@ -99,11 +99,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma&require_scan=false + uri: http://ai:9696/v3/search/hash/sha256?hash=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma&require_scan=false response: body: string: '' @@ -139,11 +139,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: HEAD - uri: http://artifact-index-e2e:9696/v3/search/hash/sha256?hash=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma&require_scan=true + uri: http://ai:9696/v3/search/hash/sha256?hash=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma&require_scan=true response: body: string: '' @@ -179,11 +179,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: POST - uri: http://artifact-index-e2e:9696/v3/known-good + uri: http://ai:9696/v3/known-good response: body: string: '{"result":{"artifact_instance_id":"38756881504693724","created":"2026-07-29T23:04:40.151450+00:00","id":"31218224787620566","sha256":"9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df","sources":["commercial","nsrl"]},"status":"OK"} @@ -221,11 +221,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/known-good?sha256=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma + uri: http://ai:9696/v3/known-good?sha256=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma response: body: string: '{"result":{"artifact_instance_id":"38756881504693724","created":"2026-07-29T23:04:40.151450+00:00","id":"31218224787620566","sha256":"9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df","sources":["commercial","nsrl"]},"status":"OK"} @@ -263,11 +263,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/sha256/9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df?community=gamma + uri: http://ai:9696/v3/consumer/download/sha256/9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df?community=gamma response: body: string: '{"errors":{"code":"KNOWN_GOOD","known_good":true,"sources":["commercial","nsrl"]},"result":"Unable @@ -305,11 +305,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: DELETE - uri: http://artifact-index-e2e:9696/v3/known-good?sha256=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df + uri: http://ai:9696/v3/known-good?sha256=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df response: body: string: '{"result":{"deleted":true,"sha256":"9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df"},"status":"OK"} @@ -347,11 +347,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/4.2.0 (x86_64-Linux-CPython-3.12.13) method: GET - uri: http://artifact-index-e2e:9696/v3/known-good?sha256=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma + uri: http://ai:9696/v3/known-good?sha256=9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df&community=gamma response: body: string: '{"errors":null,"result":"No known-good entry found for sha256 9c0258ed4cc98056773bcf0c57fe4bc79618802357f0703c503b4cb172a263df.","status":"error"} diff --git a/test/vcr/test_list_historical.vcr b/test/vcr/test_list_historical.vcr index 4706bd41..f735f4b5 100644 --- a/test/vcr/test_list_historical.vcr +++ b/test/vcr/test_list_historical.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.397319+00:00","failed_max_retries":0,"failed_other":0,"id":"86221284475520679","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -65,11 +65,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.441527+00:00","failed_max_retries":0,"failed_other":0,"id":"58288022169534211","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -114,11 +114,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.480348+00:00","failed_max_retries":0,"failed_other":0,"id":"54272719094803031","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -163,11 +163,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.521466+00:00","failed_max_retries":0,"failed_other":0,"id":"24956296142984681","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -212,11 +212,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/historical + uri: http://ai:9696/v3/hunt/historical response: body: string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-06-03T22:35:46.562853+00:00","failed_max_retries":0,"failed_other":0,"id":"53359932363657862","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule @@ -256,11 +256,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/historical/list?community=gamma + uri: http://ai:9696/v3/hunt/historical/list?community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.562853+00:00","id":"53359932363657862","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.521466+00:00","id":"24956296142984681","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.480348+00:00","id":"54272719094803031","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.441527+00:00","id":"58288022169534211","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.397319+00:00","id":"86221284475520679","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:35:46.255339+00:00","id":"46026864008511354","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null},{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"created":"2026-06-03T22:31:26.868688+00:00","id":"51603247373653891","progress":null,"results_csv_uri":null,"ruleset_name":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":null}],"status":"OK"} diff --git a/test/vcr/test_live.vcr b/test/vcr/test_live.vcr index c48c04d6..8d4df416 100644 --- a/test/vcr/test_live.vcr +++ b/test/vcr/test_live.vcr @@ -16,11 +16,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/rule + uri: http://ai:9696/v3/hunt/rule response: body: string: '{"result":{"created":"2026-06-03T22:35:46.641576+00:00","deleted":false,"description":null,"id":"63962466091392300","livescan_created":null,"livescan_id":null,"modified":"2026-06-03T22:35:46.641576+00:00","name":"sdk-test_live","yara":"rule @@ -63,11 +63,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/rule/live + uri: http://ai:9696/v3/hunt/rule/live response: body: string: '{"result":{"created":"2026-06-03T22:35:46.641576+00:00","deleted":false,"description":null,"id":"63962466091392300","livescan_created":"2026-06-03T22:35:46.690992+00:00","livescan_id":null,"modified":"2026-06-03T22:35:46.641576+00:00","name":"sdk-test_live","yara":"rule @@ -106,11 +106,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=63962466091392300&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=63962466091392300&community=gamma response: body: string: '{"result":{"created":"2026-06-03T22:35:46.641576+00:00","deleted":false,"description":null,"id":"63962466091392300","livescan_created":"2026-06-03T22:35:46.690992+00:00","livescan_id":68378491128619407,"modified":"2026-06-03T22:35:46.666460+00:00","name":"sdk-test_live","yara":"rule @@ -153,11 +153,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"27835191001619039","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:35:47.744500+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:35:47.744500+00:00","id":"27835191001619039","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/27835191001619039","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/41/9e/e7/419ee76d-f760-45c0-bc48-f9c7f1cf44e6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223547Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4a67c52be38b98e5fe6ccc916e1b8072e87fe9f0c266e81617c6969a74f14469","votes":[],"window_closed":false},"status":"OK"} @@ -254,11 +254,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=27835191001619039 + uri: http://ai:9696/v3/instance?id=27835191001619039 response: body: string: '{"result":{"artifact_id":"27835191001619039","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:35:47.744500+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:35:47.744500+00:00","id":"27835191001619039","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/27835191001619039","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/41/9e/e7/419ee76d-f760-45c0-bc48-f9c7f1cf44e6?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223547Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4a67c52be38b98e5fe6ccc916e1b8072e87fe9f0c266e81617c6969a74f14469","votes":[],"window_closed":false},"status":"OK"} @@ -296,11 +296,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -332,11 +332,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -368,11 +368,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -404,11 +404,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -440,11 +440,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -476,11 +476,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -512,11 +512,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -548,11 +548,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -584,11 +584,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -620,11 +620,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -656,11 +656,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -692,11 +692,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -728,11 +728,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -800,11 +800,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -836,11 +836,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -872,11 +872,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -908,11 +908,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -944,11 +944,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -980,11 +980,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1016,11 +1016,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1052,11 +1052,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1088,11 +1088,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1124,11 +1124,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1160,11 +1160,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1196,11 +1196,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1232,11 +1232,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1268,11 +1268,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1304,11 +1304,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '' @@ -1340,11 +1340,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live/list?since=600&community=gamma + uri: http://ai:9696/v3/hunt/live/list?since=600&community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"community":"gamma","created":"2026-06-03T22:36:17.918027+00:00","detections":{"benign":0,"malicious":1,"total":1},"download_url":null,"first_seen":"2026-06-03T22:33:00.053959+00:00","id":"8018942810283908","instance_id":"27835191001619039","livescan_id":"68378491128619407","malware_family":"EICAR","md5":"564296ca17d5e063856e0b92c8ad6ca6","polyscore":null,"rule_name":"sdk_test_live","sha1":"adec7bf2f04d1b710cbc3304f8dccd0f8d09d34a","sha256":"14e3a40dc4da0e6d9b331976e9d5611d51b25e64f5010bbdfc6c8a32b23eb190","tags":"{}","yara":null}],"status":"OK"} @@ -1382,11 +1382,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live?id=8018942810283908 + uri: http://ai:9696/v3/hunt/live?id=8018942810283908 response: body: string: '{"result":{"community":"gamma","created":"2026-06-03T22:36:17.918027+00:00","detections":{"benign":0,"malicious":1,"total":1},"download_url":"http://minio:9000/public-cache/14/e3/a4/14e3a40dc4da0e6d9b331976e9d5611d51b25e64f5010bbdfc6c8a32b23eb190adec7bf2f04d1b710cbc3304f8dccd0f8d09d34a564296ca17d5e063856e0b92c8ad6ca6?response-content-disposition=attachment%3Bfilename%3Dinfected&response-content-type=application%2Foctet-stream&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223618Z&X-Amz-Expires=3600&X-Amz-SignedHeaders=host&X-Amz-Signature=dc5cf083031090e9c5266463a7f34d3180cc5cde2fccfc6204cc23d4481b22a5","first_seen":"2026-06-03T22:33:00.053959+00:00","id":"8018942810283908","instance_id":"27835191001619039","livescan_id":"68378491128619407","malware_family":"EICAR","md5":"564296ca17d5e063856e0b92c8ad6ca6","polyscore":null,"rule_name":"sdk_test_live","sha1":"adec7bf2f04d1b710cbc3304f8dccd0f8d09d34a","sha256":"14e3a40dc4da0e6d9b331976e9d5611d51b25e64f5010bbdfc6c8a32b23eb190","tags":"{}","yara":"rule @@ -1429,11 +1429,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/live/list + uri: http://ai:9696/v3/hunt/live/list response: body: string: '{"has_more":true,"limit":50,"result":[{"community":"gamma","created":"2026-06-03T22:36:17.918027+00:00","detections":{"benign":0,"malicious":1,"total":1},"download_url":null,"first_seen":"2026-06-03T22:33:00.053959+00:00","id":"8018942810283908","instance_id":"27835191001619039","livescan_id":"68378491128619407","malware_family":"EICAR","md5":"564296ca17d5e063856e0b92c8ad6ca6","polyscore":null,"rule_name":"sdk_test_live","sha1":"adec7bf2f04d1b710cbc3304f8dccd0f8d09d34a","sha256":"14e3a40dc4da0e6d9b331976e9d5611d51b25e64f5010bbdfc6c8a32b23eb190","tags":"{}","yara":null}],"status":"OK"} @@ -1471,11 +1471,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/live?id=8018942810283908 + uri: http://ai:9696/v3/hunt/live?id=8018942810283908 response: body: string: '{"errors":null,"result":"Could not find requested live hunt result: @@ -1516,11 +1516,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule/live + uri: http://ai:9696/v3/hunt/rule/live response: body: string: '{"result":{"created":"2026-06-03T22:35:46.641576+00:00","deleted":false,"description":null,"id":"63962466091392300","livescan_created":"2026-06-03T22:35:46.690992+00:00","livescan_id":68378491128619407,"modified":"2026-06-03T22:35:46.666460+00:00","name":"sdk-test_live","yara":"rule @@ -1559,11 +1559,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=63962466091392300&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=63962466091392300&community=gamma response: body: string: '{"result":{"created":"2026-06-03T22:35:46.641576+00:00","deleted":false,"description":null,"id":"63962466091392300","livescan_created":"2026-06-03T22:35:46.690992+00:00","livescan_id":null,"modified":"2026-06-03T22:36:18.435557+00:00","name":"sdk-test_live","yara":"rule @@ -1606,11 +1606,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule/live + uri: http://ai:9696/v3/hunt/rule/live response: body: string: '{"errors":null,"result":"Ruleset does not have an active live scan.","status":"error"} @@ -1650,11 +1650,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=63962466091392300 + uri: http://ai:9696/v3/hunt/rule?id=63962466091392300 response: body: string: '{"result":{"created":"2026-06-03T22:35:46.641576+00:00","deleted":true,"description":null,"id":"63962466091392300","livescan_created":"2026-06-03T22:35:46.690992+00:00","livescan_id":null,"modified":"2026-06-03T22:36:18.435557+00:00","name":"sdk-test_live","yara":"rule diff --git a/test/vcr/test_metadata_search.vcr b/test/vcr/test_metadata_search.vcr index 1377eba9..e429c0c3 100644 --- a/test/vcr/test_metadata_search.vcr +++ b/test/vcr/test_metadata_search.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:06:40.446982+00:00","id":"43068161308630781","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/43068161308630781","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/86/f4/35/86f43553-7e0c-48f3-bb1f-ca27688516cf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190640Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=100dee9a29f33f64d0e68f47bf48abb46e112442b47fb087b84d4eee5fa83a81","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=43068161308630781 + uri: http://ai:9696/v3/instance?id=43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:06:40.446982+00:00","id":"43068161308630781","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/43068161308630781","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/86/f4/35/86f43553-7e0c-48f3-bb1f-ca27688516cf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190640Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=100dee9a29f33f64d0e68f47bf48abb46e112442b47fb087b84d4eee5fa83a81","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:06:40.446982+00:00","id":"43068161308630781","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/43068161308630781","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/86/f4/35/86f43553-7e0c-48f3-bb1f-ca27688516cf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190640Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=100dee9a29f33f64d0e68f47bf48abb46e112442b47fb087b84d4eee5fa83a81","votes":[],"window_closed":false},"status":"OK"} @@ -200,11 +200,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -247,11 +247,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -294,11 +294,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -341,11 +341,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -388,11 +388,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -435,11 +435,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -482,11 +482,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -529,11 +529,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -576,11 +576,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -623,11 +623,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -717,11 +717,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -811,11 +811,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -858,11 +858,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -905,11 +905,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -952,11 +952,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -999,11 +999,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1046,11 +1046,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1093,11 +1093,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1234,11 +1234,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1281,11 +1281,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1328,11 +1328,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1375,11 +1375,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1422,11 +1422,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1469,11 +1469,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1516,11 +1516,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1563,11 +1563,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/43068161308630781 + uri: http://ai:9696/v3/consumer/submission/gamma/43068161308630781 response: body: string: '{"result":{"artifact_id":"43068161308630781","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:06:40.446982+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1610,11 +1610,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/search/metadata/query?query=artifact.sha256%3A0285922fdd731d6905d5a6dc51d75e3bd504c5ac418b8c7b431063c6cee8d064&community=gamma + uri: http://ai:9696/v3/search/metadata/query?query=artifact.sha256%3A0285922fdd731d6905d5a6dc51d75e3bd504c5ac418b8c7b431063c6cee8d064&community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"artifact":{"created":"2026-06-05T19:01:38.104756+00:00","id":"31542742786663251","md5":"5d3bc3c626be6b6f59195afc4ab80fc8","sha1":"f1d73dcb1286cf42e707b5d7fcf918dd45290411","sha256":"0285922fdd731d6905d5a6dc51d75e3bd504c5ac418b8c7b431063c6cee8d064","size":89},"exiftool":{"filesize":"89 diff --git a/test/vcr/test_rescans.vcr b/test/vcr/test_rescans.vcr index 1e70d518..ac93525b 100644 --- a/test/vcr/test_rescans.vcr +++ b/test/vcr/test_rescans.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"42933081276879938","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:07:11.237475+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:07:11.237475+00:00","id":"42933081276879938","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/42933081276879938","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/e7/f5/9a/e7f59ac9-bfab-4574-863c-28b6562ad108?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190711Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=fa12d2a42d97b0e173028cf12af9fcb75dabdb7e8b6c8ae4e4a05cfea83db640","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=42933081276879938 + uri: http://ai:9696/v3/instance?id=42933081276879938 response: body: string: '{"result":{"artifact_id":"42933081276879938","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:07:11.237475+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:07:11.237475+00:00","id":"42933081276879938","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/42933081276879938","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/e7/f5/9a/e7f59ac9-bfab-4574-863c-28b6562ad108?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190711Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=fa12d2a42d97b0e173028cf12af9fcb75dabdb7e8b6c8ae4e4a05cfea83db640","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/x-www-form-urlencoded host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/rescan/sha256/cd4657c2fb9bb86d0cdc8c78a2c01cff0c1dcfaf740e66b25ba0a0d47c4e03f4 + uri: http://ai:9696/v3/consumer/submission/gamma/rescan/sha256/cd4657c2fb9bb86d0cdc8c78a2c01cff0c1dcfaf740e66b25ba0a0d47c4e03f4 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[],"bounty_state":1,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -205,11 +205,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[],"bounty_state":1,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -248,11 +248,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -295,11 +295,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -342,11 +342,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -389,11 +389,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -436,11 +436,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -483,11 +483,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -530,11 +530,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -577,11 +577,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -624,11 +624,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -671,11 +671,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -718,11 +718,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -765,11 +765,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -812,11 +812,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -859,11 +859,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -906,11 +906,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -953,11 +953,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1000,11 +1000,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1047,11 +1047,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1094,11 +1094,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1141,11 +1141,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1188,11 +1188,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1235,11 +1235,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1282,11 +1282,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1329,11 +1329,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1376,11 +1376,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1423,11 +1423,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1470,11 +1470,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1517,11 +1517,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1564,11 +1564,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1611,11 +1611,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1658,11 +1658,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/86481460634015297 response: body: string: '{"result":{"artifact_id":"86481460634015297","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:07:11.353886+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1707,11 +1707,11 @@ interactions: content-length: - '0' host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/rescan/86481460634015297 + uri: http://ai:9696/v3/consumer/submission/gamma/rescan/86481460634015297 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[],"bounty_state":1,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1750,11 +1750,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1793,11 +1793,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1840,11 +1840,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1887,11 +1887,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1934,11 +1934,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1981,11 +1981,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2028,11 +2028,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2075,11 +2075,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2122,11 +2122,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2169,11 +2169,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2216,11 +2216,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2263,11 +2263,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2310,11 +2310,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2357,11 +2357,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2404,11 +2404,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2451,11 +2451,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2498,11 +2498,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2545,11 +2545,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2592,11 +2592,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2639,11 +2639,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2686,11 +2686,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2733,11 +2733,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2780,11 +2780,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2827,11 +2827,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2874,11 +2874,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2921,11 +2921,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -2968,11 +2968,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3015,11 +3015,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3062,11 +3062,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3109,11 +3109,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -3156,11 +3156,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/3525095652778256 + uri: http://ai:9696/v3/consumer/submission/gamma/3525095652778256 response: body: string: '{"result":{"artifact_id":"3525095652778256","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:07:43.226087+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_rules.vcr b/test/vcr/test_rules.vcr index 01b1c302..7a3d8518 100644 --- a/test/vcr/test_rules.vcr +++ b/test/vcr/test_rules.vcr @@ -26,11 +26,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/hunt/rule + uri: http://ai:9696/v3/hunt/rule response: body: string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":null,"id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test","yara":"rule @@ -81,11 +81,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule/list?community=gamma + uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: string: '{"has_more":false,"limit":50,"result":[{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":null,"id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test","yara":null}],"status":"OK"} @@ -123,11 +123,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=68232116824597140&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=68232116824597140&community=gamma response: body: string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":null,"id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test","yara":"rule @@ -182,11 +182,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=68232116824597140 + uri: http://ai:9696/v3/hunt/rule?id=68232116824597140 response: body: string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":"test","id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test2","yara":"rule @@ -241,11 +241,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: DELETE - uri: http://artifact-index-e2e:9696/v3/hunt/rule?id=68232116824597140 + uri: http://ai:9696/v3/hunt/rule?id=68232116824597140 response: body: string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":true,"description":"test","id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.766631+00:00","name":"test2","yara":"rule @@ -296,11 +296,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/hunt/rule/list?community=gamma + uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: string: '' diff --git a/test/vcr/test_sample.vcr b/test/vcr/test_sample.vcr index 102f740a..4c5efc71 100644 --- a/test/vcr/test_sample.vcr +++ b/test/vcr/test_sample.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"78915913879990408","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:49:21.173135+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:49:21.173135+00:00","id":"78915913879990408","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/78915913879990408","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/be/6a/f6/be6af674-686a-45fb-be27-0abde7157f62?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224921Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=de10a0a51c1f7016b895fee138394c46b11a40a05cbf87880f7a2532d62c52a9","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=78915913879990408 + uri: http://ai:9696/v3/instance?id=78915913879990408 response: body: string: '{"result":{"artifact_id":"78915913879990408","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:49:21.173135+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:49:21.173135+00:00","id":"78915913879990408","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/78915913879990408","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/be/6a/f6/be6af674-686a-45fb-be27-0abde7157f62?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224921Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=de10a0a51c1f7016b895fee138394c46b11a40a05cbf87880f7a2532d62c52a9","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 78915913879990408.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -935,11 +935,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/3209cdc9fe8336e1c553b92b8fe80821d1c88b987cccbbbfc1fc507c3598074a + uri: http://ai:9696/v3/sample/3209cdc9fe8336e1c553b92b8fe80821d1c88b987cccbbbfc1fc507c3598074a response: body: string: '{"result":{"artifact_instance":{"artifact_id":"88057514927591659","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-03T22:44:17.987653+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -996,11 +996,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sample/3209cdc9fe8336e1c553b92b8fe80821d1c88b987cccbbbfc1fc507c3598074a + uri: http://ai:9696/v3/sample/3209cdc9fe8336e1c553b92b8fe80821d1c88b987cccbbbfc1fc507c3598074a response: body: string: '{"result":{"artifact_instance":{"artifact_id":"88057514927591659","assertions":[{"author":"170195234701403","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-03T22:44:17.987653+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_sandbox_providers.vcr b/test/vcr/test_sandbox_providers.vcr index 759427b6..9528c3ab 100644 --- a/test/vcr/test_sandbox_providers.vcr +++ b/test/vcr/test_sandbox_providers.vcr @@ -11,11 +11,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/provider/list + uri: http://ai:9696/v3/sandbox/provider/list response: body: string: '{"result":{"cape":{"id":"1","name":"cape","slug":"cape","tool":"cape_sandbox_v2","vms":{"win-10-build-19041":{"architecture":"x64","id":"100","language":"English diff --git a/test/vcr/test_sandboxtask_latest.vcr b/test/vcr/test_sandboxtask_latest.vcr index 9bd6cbd6..9488e16d 100644 --- a/test/vcr/test_sandboxtask_latest.vcr +++ b/test/vcr/test_sandboxtask_latest.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"43321632522162928","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:41:12.601884+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:41:12.601884+00:00","id":"43321632522162928","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/43321632522162928","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/3d/8e/90/3d8e902e-173e-4061-a98c-284165dcbe3d?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224112Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=f89f5a037deb24b2e611cc102963f07b0cf4609eac47a8fec1c43e7aec37349c","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=43321632522162928 + uri: http://ai:9696/v3/instance?id=43321632522162928 response: body: string: '{"result":{"artifact_id":"43321632522162928","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:41:12.601884+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:41:12.601884+00:00","id":"43321632522162928","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/43321632522162928","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/3d/8e/90/3d8e902e-173e-4061-a98c-284165dcbe3d?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224112Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=f89f5a037deb24b2e611cc102963f07b0cf4609eac47a8fec1c43e7aec37349c","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 43321632522162928.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -931,11 +931,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -971,11 +971,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1011,11 +1011,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1051,11 +1051,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1091,11 +1091,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape response: body: string: '{"errors":null,"result":"No tasks found.","status":"error"} @@ -1131,11 +1131,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=cape response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -1177,11 +1177,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=triage + uri: http://ai:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=c0afec2f69f7ec49a9a9d13ab9c5119daeaa9c956b35380dd34d4afeec489a83&sandbox=triage response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR diff --git a/test/vcr/test_sandboxtask_list.vcr b/test/vcr/test_sandboxtask_list.vcr index b43e5511..d25e565c 100644 --- a/test/vcr/test_sandboxtask_list.vcr +++ b/test/vcr/test_sandboxtask_list.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"58969745895714176","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:41:25.019443+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:41:25.019443+00:00","id":"58969745895714176","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/58969745895714176","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/5b/75/27/5b7527e2-75f6-47c2-9d28-a84dc7587ebf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224125Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=7026d46f1c65653f3e886301c7fd63b00c4fbce7394f51ce00fcf525ca8fc9d7","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=58969745895714176 + uri: http://ai:9696/v3/instance?id=58969745895714176 response: body: string: '{"result":{"artifact_id":"58969745895714176","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:41:25.019443+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:41:25.019443+00:00","id":"58969745895714176","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/58969745895714176","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/5b/75/27/5b7527e2-75f6-47c2-9d28-a84dc7587ebf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224125Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=7026d46f1c65653f3e886301c7fd63b00c4fbce7394f51ce00fcf525ca8fc9d7","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 58969745895714176.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -300,11 +300,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR @@ -348,11 +348,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f&sandbox=cape + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f&sandbox=cape response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR @@ -393,11 +393,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f&sandbox=triage + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f&sandbox=triage response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR @@ -438,11 +438,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f + uri: http://ai:9696/v3/sandbox/sandboxtask/list?sha256=486d0e452557572a3845220ccd3559e2f4475579bbb3e60a31b58e4b4cdcf20f response: body: string: '{"has_more":false,"limit":50,"result":[{"account_number":null,"artifact":{"extended_type":"EICAR diff --git a/test/vcr/test_sandboxtask_submit.vcr b/test/vcr/test_sandboxtask_submit.vcr index 9e86dcb7..93bc140e 100644 --- a/test/vcr/test_sandboxtask_submit.vcr +++ b/test/vcr/test_sandboxtask_submit.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"28438671969668813","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:36:48.580266+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:36:48.580266+00:00","id":"28438671969668813","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/28438671969668813","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/75/0f/73/750f73d6-9e0a-4707-be01-39141878ed43?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223648Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=7b606b7c440aace87ecb0d5e719ebef978d3957a666783620450c956a50db8c8","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=28438671969668813 + uri: http://ai:9696/v3/instance?id=28438671969668813 response: body: string: '{"result":{"artifact_id":"28438671969668813","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:36:48.580266+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:36:48.580266+00:00","id":"28438671969668813","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/28438671969668813","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/75/0f/73/750f73d6-9e0a-4707-be01-39141878ed43?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223648Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=7b606b7c440aace87ecb0d5e719ebef978d3957a666783620450c956a50db8c8","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"errors":null,"result":"Could not find storage path for instance 28438671969668813.","status":"error"} @@ -206,11 +206,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR @@ -255,11 +255,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/sandbox/sandboxtask + uri: http://ai:9696/v3/sandbox/sandboxtask response: body: string: '{"result":{"account_number":null,"artifact":{"extended_type":"EICAR diff --git a/test/vcr/test_search_by_ioc.vcr b/test/vcr/test_search_by_ioc.vcr index 48c7fcfd..fcf21ecb 100644 --- a/test/vcr/test_search_by_ioc.vcr +++ b/test/vcr/test_search_by_ioc.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"18758446912256777","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:20:15.083179+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:20:15.083179+00:00","id":"18758446912256777","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/18758446912256777","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/a0/e9/61/a0e961c4-4694-45b2-9047-de13d8afce65?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T222015Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=cf13e8ed829c5fe9845fc2e7133f17949ff9c3bc1ecbf158724b262382b7de19","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=18758446912256777 + uri: http://ai:9696/v3/instance?id=18758446912256777 response: body: string: '{"result":{"artifact_id":"18758446912256777","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:20:15.083179+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:20:15.083179+00:00","id":"18758446912256777","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/18758446912256777","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/a0/e9/61/a0e961c4-4694-45b2-9047-de13d8afce65?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T222015Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=cf13e8ed829c5fe9845fc2e7133f17949ff9c3bc1ecbf158724b262382b7de19","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T22:20:15.123576+00:00","tool":"cape_sandbox_v2","tool_metadata":{"extracted_c2_ips":["9.42.137.243"],"extracted_c2_urls":["www.mock-ioc.test"],"ttp":["T1081","T1060","T1069"]},"updated":"2026-06-03T22:20:15.123576+00:00"},"status":"OK"} @@ -204,11 +204,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -240,11 +240,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -276,11 +276,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -312,11 +312,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -348,11 +348,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -384,11 +384,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -420,11 +420,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -456,11 +456,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -492,11 +492,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -528,11 +528,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -564,11 +564,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -600,11 +600,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -636,11 +636,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -672,11 +672,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -708,11 +708,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -744,11 +744,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -780,11 +780,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -816,11 +816,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -852,11 +852,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -888,11 +888,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -924,11 +924,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -960,11 +960,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -996,11 +996,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1032,11 +1032,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1068,11 +1068,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1104,11 +1104,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1176,11 +1176,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1212,11 +1212,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1248,11 +1248,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1284,11 +1284,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1320,11 +1320,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '' @@ -1356,11 +1356,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 + uri: http://ai:9696/v3/ioc/search?community=gamma&ip=9.42.137.243 response: body: string: '{"has_more":false,"limit":50,"result":["dbb2ebb101d529e8552c91fb3f950e53063cace34a7c4bcfb6dc9eca7de5517a"],"status":"OK"} diff --git a/test/vcr/test_stream.vcr b/test/vcr/test_stream.vcr index 8e5a09de..e0e31828 100644 --- a/test/vcr/test_stream.vcr +++ b/test/vcr/test_stream.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"91022508925826342","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.288426+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.288426+00:00","id":"91022508925826342","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/91022508925826342","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/01/94/71/01947126-fd4e-4a45-b80c-2d626f9653bf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=bbc60540b11477f5fb5c1be6eeff5d9a2639e1d0031573d71fa1b7b0862b38fc","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=91022508925826342 + uri: http://ai:9696/v3/instance?id=91022508925826342 response: body: string: '{"result":{"artifact_id":"91022508925826342","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.288426+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.288426+00:00","id":"91022508925826342","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/91022508925826342","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/01/94/71/01947126-fd4e-4a45-b80c-2d626f9653bf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=bbc60540b11477f5fb5c1be6eeff5d9a2639e1d0031573d71fa1b7b0862b38fc","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"72588160952354698","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.334463+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.334463+00:00","id":"72588160952354698","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/72588160952354698","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/a1/0e/e2/a10ee298-4ab8-4197-b768-e3a9b2640ffe?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=f3d54d32d7d797d7607ab4059ecd7f29e0bc7526a530e8cb5b66c35710282dc6","votes":[],"window_closed":false},"status":"OK"} @@ -263,11 +263,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=72588160952354698 + uri: http://ai:9696/v3/instance?id=72588160952354698 response: body: string: '{"result":{"artifact_id":"72588160952354698","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.334463+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.334463+00:00","id":"72588160952354698","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/72588160952354698","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/a1/0e/e2/a10ee298-4ab8-4197-b768-e3a9b2640ffe?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=f3d54d32d7d797d7607ab4059ecd7f29e0bc7526a530e8cb5b66c35710282dc6","votes":[],"window_closed":false},"status":"OK"} @@ -309,11 +309,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"60954358989668236","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.379392+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.379392+00:00","id":"60954358989668236","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/60954358989668236","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/9c/f6/ab/9cf6ab03-45c6-46c1-bafc-40474208df8e?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5ba4de8f74df4bdb8ac7aa72190d530d14471f7fe1012e37925718606613b607","votes":[],"window_closed":false},"status":"OK"} @@ -410,11 +410,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=60954358989668236 + uri: http://ai:9696/v3/instance?id=60954358989668236 response: body: string: '{"result":{"artifact_id":"60954358989668236","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.379392+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.379392+00:00","id":"60954358989668236","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/60954358989668236","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/9c/f6/ab/9cf6ab03-45c6-46c1-bafc-40474208df8e?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5ba4de8f74df4bdb8ac7aa72190d530d14471f7fe1012e37925718606613b607","votes":[],"window_closed":false},"status":"OK"} @@ -456,11 +456,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"62145600481990175","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.429886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.429886+00:00","id":"62145600481990175","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/62145600481990175","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d3/a7/9a/d3a79ab9-9edb-42f2-91fd-7fa2e9cfb323?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5def782b5238295150e0daae1eebedc1a68698d1f10e640615d41762d9bc4b81","votes":[],"window_closed":false},"status":"OK"} @@ -557,11 +557,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=62145600481990175 + uri: http://ai:9696/v3/instance?id=62145600481990175 response: body: string: '{"result":{"artifact_id":"62145600481990175","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.429886+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.429886+00:00","id":"62145600481990175","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/62145600481990175","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d3/a7/9a/d3a79ab9-9edb-42f2-91fd-7fa2e9cfb323?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=5def782b5238295150e0daae1eebedc1a68698d1f10e640615d41762d9bc4b81","votes":[],"window_closed":false},"status":"OK"} @@ -603,11 +603,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"97345219300247911","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.481471+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.481471+00:00","id":"97345219300247911","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/97345219300247911","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d6/10/02/d6100222-8850-4c59-abfa-199f1801e1c1?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=837c7854df35c5787edb6aec41c034dc5149e5e4e2f680aacbf74e50d312d212","votes":[],"window_closed":false},"status":"OK"} @@ -704,11 +704,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=97345219300247911 + uri: http://ai:9696/v3/instance?id=97345219300247911 response: body: string: '{"result":{"artifact_id":"97345219300247911","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.481471+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.481471+00:00","id":"97345219300247911","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/97345219300247911","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d6/10/02/d6100222-8850-4c59-abfa-199f1801e1c1?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=837c7854df35c5787edb6aec41c034dc5149e5e4e2f680aacbf74e50d312d212","votes":[],"window_closed":false},"status":"OK"} @@ -750,11 +750,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"35024334453294850","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.530408+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.530408+00:00","id":"35024334453294850","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/35024334453294850","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/21/5a/a1/215aa1bc-5708-4744-8dbd-720aff05b313?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=40b58e426794be4e12f38c97b5b00019bcc36fd0b74354e272094e5df22b4cf4","votes":[],"window_closed":false},"status":"OK"} @@ -851,11 +851,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=35024334453294850 + uri: http://ai:9696/v3/instance?id=35024334453294850 response: body: string: '{"result":{"artifact_id":"35024334453294850","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.530408+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.530408+00:00","id":"35024334453294850","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/35024334453294850","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/21/5a/a1/215aa1bc-5708-4744-8dbd-720aff05b313?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=40b58e426794be4e12f38c97b5b00019bcc36fd0b74354e272094e5df22b4cf4","votes":[],"window_closed":false},"status":"OK"} @@ -897,11 +897,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"15265044106299347","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.581094+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.581094+00:00","id":"15265044106299347","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/15265044106299347","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d2/1d/b2/d21db2bf-a20e-4024-9871-e74a960ea1ce?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d7ca23795381a3ef9d26fe0e506d304e313414b0a0b8b03665e1c75e92e97878","votes":[],"window_closed":false},"status":"OK"} @@ -998,11 +998,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=15265044106299347 + uri: http://ai:9696/v3/instance?id=15265044106299347 response: body: string: '{"result":{"artifact_id":"15265044106299347","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.581094+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.581094+00:00","id":"15265044106299347","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/15265044106299347","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/d2/1d/b2/d21db2bf-a20e-4024-9871-e74a960ea1ce?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d7ca23795381a3ef9d26fe0e506d304e313414b0a0b8b03665e1c75e92e97878","votes":[],"window_closed":false},"status":"OK"} @@ -1044,11 +1044,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"961703212604307","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.633488+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.633488+00:00","id":"961703212604307","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/961703212604307","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/16/b6/b3/16b6b316-a171-418f-852e-0f96827fc2de?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=44fdf5abfcc5cee2ee31e8ece18e91b5ba024e04456e6dba39b83d5641a34591","votes":[],"window_closed":false},"status":"OK"} @@ -1145,11 +1145,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=961703212604307 + uri: http://ai:9696/v3/instance?id=961703212604307 response: body: string: '{"result":{"artifact_id":"961703212604307","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T23:09:35.633488+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T23:09:35.633488+00:00","id":"961703212604307","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/961703212604307","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/16/b6/b3/16b6b316-a171-418f-852e-0f96827fc2de?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230935Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=44fdf5abfcc5cee2ee31e8ece18e91b5ba024e04456e6dba39b83d5641a34591","votes":[],"window_closed":false},"status":"OK"} @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '' @@ -1223,11 +1223,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '' @@ -1259,11 +1259,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '' @@ -1295,11 +1295,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '' @@ -1331,11 +1331,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '' @@ -1367,11 +1367,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '{"has_more":false,"limit":50,"result":[{"community":null,"created":"2026-06-03T23:09:35.489361+00:00","id":"6468870320263417","uri":"http://minio:9000/artifact-index/archives/36/51/5f/36515f536bb9835062f7dd090b6180177af13f13a68d212e51e625486d8f29238f19ed12aca0456d0b6394152a895006d3ea51f1f4ced6f84ddf49c57e12578ab878d451?response-content-disposition=attachment%3Bfilename%3D6468870320263417.tar.gz&response-content-type=application%2Foctet-stream&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230940Z&X-Amz-Expires=3600&X-Amz-SignedHeaders=host&X-Amz-Signature=cefab4bf4cb9f254f739d2929026fa5305a4bb52167d4643c435fdb78e13ef35"}],"status":"OK"} @@ -1473,11 +1473,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/download/stream?since=2 + uri: http://ai:9696/v3/consumer/download/stream?since=2 response: body: string: '{"has_more":false,"limit":50,"result":[{"community":null,"created":"2026-06-03T23:09:35.640326+00:00","id":"58648405722001270","uri":"http://minio:9000/artifact-index/archives/24/2f/40/242f4093d709430d3f52bc45566fe5dba01dd128c2d074a38e925e8a02226189940ef6f9206a157f6a2d7609e1aad5cda2e87b613f792d3fa78b58fe438e17146becd7cf?response-content-disposition=attachment%3Bfilename%3D58648405722001270.tar.gz&response-content-type=application%2Foctet-stream&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230941Z&X-Amz-Expires=3600&X-Amz-SignedHeaders=host&X-Amz-Signature=f343d0863d5bb46db2a844cecc57a4a485af819ee751975ada7988498826effd"},{"community":null,"created":"2026-06-03T23:09:35.489361+00:00","id":"6468870320263417","uri":"http://minio:9000/artifact-index/archives/36/51/5f/36515f536bb9835062f7dd090b6180177af13f13a68d212e51e625486d8f29238f19ed12aca0456d0b6394152a895006d3ea51f1f4ced6f84ddf49c57e12578ab878d451?response-content-disposition=attachment%3Bfilename%3D6468870320263417.tar.gz&response-content-type=application%2Foctet-stream&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T230941Z&X-Amz-Expires=3600&X-Amz-SignedHeaders=host&X-Amz-Signature=529381da676c9f1b87aa6eb3c501de7265a08e68224116dc2adb37875a9fd5b1"}],"status":"OK"} diff --git a/test/vcr/test_submission.vcr b/test/vcr/test_submission.vcr index 07f0db8a..9729fe8d 100644 --- a/test/vcr/test_submission.vcr +++ b/test/vcr/test_submission.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:08:14.028221+00:00","id":"1571270037855879","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/1571270037855879","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1c/91/1f/1c911ffa-3ba9-4d08-9152-a36b18091203?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190814Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=02685afd619c48a1343a59a56e069ba47ada8cbca516438958f857fd0f406236","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=1571270037855879 + uri: http://ai:9696/v3/instance?id=1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:08:14.028221+00:00","id":"1571270037855879","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/1571270037855879","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1c/91/1f/1c911ffa-3ba9-4d08-9152-a36b18091203?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190814Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=02685afd619c48a1343a59a56e069ba47ada8cbca516438958f857fd0f406236","votes":[],"window_closed":false},"status":"OK"} @@ -158,11 +158,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-05T19:08:14.028221+00:00","id":"1571270037855879","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/1571270037855879","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/1c/91/1f/1c911ffa-3ba9-4d08-9152-a36b18091203?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260605%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260605T190814Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=02685afd619c48a1343a59a56e069ba47ada8cbca516438958f857fd0f406236","votes":[],"window_closed":false},"status":"OK"} @@ -200,11 +200,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -247,11 +247,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -294,11 +294,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -341,11 +341,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -388,11 +388,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -435,11 +435,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -482,11 +482,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -529,11 +529,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -576,11 +576,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -623,11 +623,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -670,11 +670,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -717,11 +717,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -764,11 +764,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -811,11 +811,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -858,11 +858,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -905,11 +905,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -952,11 +952,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -999,11 +999,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1046,11 +1046,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1093,11 +1093,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1140,11 +1140,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1187,11 +1187,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1234,11 +1234,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1281,11 +1281,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1328,11 +1328,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1375,11 +1375,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1422,11 +1422,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1469,11 +1469,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1516,11 +1516,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":2,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":"EICAR @@ -1563,11 +1563,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/consumer/submission/gamma/1571270037855879 + uri: http://ai:9696/v3/consumer/submission/gamma/1571270037855879 response: body: string: '{"result":{"artifact_id":"1571270037855879","assertions":[{"author":"354237453029617","author_name":"engine-eicar","bid":"1000000000000000000","engine":{"description":"webhook-microengine-description","name":"engine-eicar"},"mask":true,"metadata":{"malware_family":"EICAR","product":"eicar","scanner":{"environment":{"architecture":"x86_64","operating_system":"Linux"}}},"verdict":true}],"bounty_state":3,"community":"gamma","country":"","created":"2026-06-05T19:08:14.028221+00:00","detections":{"benign":0,"malicious":1,"total":1},"expiration_window":null,"expire_at":null,"extended_type":"EICAR diff --git a/test/vcr/test_tool_metadata.vcr b/test/vcr/test_tool_metadata.vcr index e8caa6a7..2f8799bd 100644 --- a/test/vcr/test_tool_metadata.vcr +++ b/test/vcr/test_tool_metadata.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/instance + uri: http://ai:9696/v3/instance response: body: string: '{"result":{"artifact_id":"64625941818817200","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:36:49.931921+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:36:49.931921+00:00","id":"64625941818817200","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/64625941818817200","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/c1/e2/6e/c1e26e49-7311-47d3-b74e-0745b006467a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223649Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=9b838169541d89a92df1d55eba1c195521b7189b0bf7c092ab99137d6fe57199","votes":[],"window_closed":false},"status":"OK"} @@ -116,11 +116,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/instance?id=64625941818817200 + uri: http://ai:9696/v3/instance?id=64625941818817200 response: body: string: '{"result":{"artifact_id":"64625941818817200","assertions":[],"bounty_state":0,"community":"gamma","country":"","created":"2026-06-03T22:36:49.931921+00:00","detections":null,"expiration_window":null,"expire_at":null,"extended_type":null,"failed":false,"filename":"artifact","first_seen":"2026-06-03T22:36:49.931921+00:00","id":"64625941818817200","last_scanned":null,"last_seen":null,"md5":null,"metadata":[],"mimetype":null,"permalink":"https://polyswarm.network/scan/results/file/None/64625941818817200","polyscore":null,"result":null,"sha1":null,"sha256":null,"size":null,"type":"FILE","upload_url":"http://minio:9000/artifact-index/instances/c1/e2/6e/c1e26e49-7311-47d3-b74e-0745b006467a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T223649Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=9b838169541d89a92df1d55eba1c195521b7189b0bf7c092ab99137d6fe57199","votes":[],"window_closed":false},"status":"OK"} @@ -162,11 +162,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T22:36:49.972655+00:00","tool":"test_tool_1","tool_metadata":{"key":"value"},"updated":"2026-06-03T22:36:49.972655+00:00"},"status":"OK"} @@ -208,11 +208,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/artifact/metadata + uri: http://ai:9696/v3/artifact/metadata response: body: string: '{"result":{"created":"2026-06-03T22:36:49.988737+00:00","tool":"test_tool_2","tool_metadata":{"key2":"value2"},"updated":"2026-06-03T22:36:49.988737+00:00"},"status":"OK"} @@ -250,11 +250,11 @@ interactions: connection: - keep-alive host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: GET - uri: http://artifact-index-e2e:9696/v3/artifact/metadata/list?instance_id=64625941818817200 + uri: http://ai:9696/v3/artifact/metadata/list?instance_id=64625941818817200 response: body: string: '{"has_more":false,"limit":50,"result":[{"created":"2026-06-03T22:36:49.991172+00:00","tool":"test_tool_2","tool_metadata":{"key2":"value2"},"updated":"2026-06-03T22:36:49.991172+00:00"},{"created":"2026-06-03T22:36:49.976422+00:00","tool":"test_tool_1","tool_metadata":{"key":"value"},"updated":"2026-06-03T22:36:49.976422+00:00"}],"status":"OK"} diff --git a/test/vcr/test_update_known_good_host.vcr b/test/vcr/test_update_known_good_host.vcr index 061b4237..49bc66a3 100644 --- a/test/vcr/test_update_known_good_host.vcr +++ b/test/vcr/test_update_known_good_host.vcr @@ -15,11 +15,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: POST - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"test-update-known-good-host.sdk.test","id":4,"source":"test","type":"domain"},"status":"OK"} @@ -61,11 +61,11 @@ interactions: content-type: - application/json host: - - artifact-index-e2e:9696 + - ai:9696 user-agent: - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) method: PUT - uri: http://artifact-index-e2e:9696/v3/ioc/known + uri: http://ai:9696/v3/ioc/known response: body: string: '{"result":{"good":true,"host":"9.42.248.55","id":4,"source":"test","type":"ip"},"status":"OK"} From a0f4a9b06f3a00b534047b953771ac3a3fd96cfb Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 6 Aug 2026 18:32:50 -0300 Subject: [PATCH 02/36] test: the e2e sandbox service hostname is now 'sandbox' (was sandbox-service-e2e) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Companion to the 'ai' rename: SANDBOX_SERVICE_URI in both suite files plus the sandbox-bearing cassettes (byte-safe replace — one cassette carries binary recording bodies). Suite verified locally VCR-on: 163 passed. --- test/vcr/test_async_iocs_by_hash.vcr | 16 ++++----- test/vcr/test_async_sample.vcr | 40 +++++++++++----------- test/vcr/test_async_sandboxtask_latest.vcr | 40 +++++++++++----------- test/vcr/test_iocs_by_hash.vcr | 16 ++++----- test/vcr/test_sample.vcr | 40 +++++++++++----------- test/vcr/test_sandboxtask_latest.vcr | 40 +++++++++++----------- 6 files changed, 96 insertions(+), 96 deletions(-) diff --git a/test/vcr/test_async_iocs_by_hash.vcr b/test/vcr/test_async_iocs_by_hash.vcr index 28820560..e12e50bc 100644 --- a/test/vcr/test_async_iocs_by_hash.vcr +++ b/test/vcr/test_async_iocs_by_hash.vcr @@ -253,11 +253,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -302,11 +302,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":88,"created":"2026-06-03T23:19:09.925784Z","sandbox_task_id":23356546211344354,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/88/88?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T231909Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4c31c27f1fc8312f82721dee763cb5f7aa3bf859d3e13982c892224af9eb13a2","name":"cape_report.json","mimetype":"application/json","extended_type":"JSON @@ -400,11 +400,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/88/ + uri: http://sandbox:54110/api/sandbox-artifact/88/ response: body: string: '{"status":"OK"}' @@ -448,11 +448,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' diff --git a/test/vcr/test_async_sample.vcr b/test/vcr/test_async_sample.vcr index 96589f43..d643e4d7 100644 --- a/test/vcr/test_async_sample.vcr +++ b/test/vcr/test_async_sample.vcr @@ -302,11 +302,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -351,11 +351,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":50,"created":"2026-06-03T22:51:55.181731Z","sandbox_task_id":72170755296603329,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/05/05?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225155Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4b83340faee9ee7a632701ab6efa5bef8dd6b02ca0a6ab5a878ec45dffc2b354","name":"cape_report.json","mimetype":"application/json","extended_type":"JSON @@ -449,11 +449,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/50/ + uri: http://sandbox:54110/api/sandbox-artifact/50/ response: body: string: '{"status":"OK"}' @@ -497,11 +497,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -545,11 +545,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -594,11 +594,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":51,"created":"2026-06-03T22:51:55.215798Z","sandbox_task_id":77255104432408221,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/15/15?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225155Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=d489d0cf7e6ab0fe183e6d8c972d8b97cecc6561c938bf69868ea56be67bf1cd","name":"triage_report.json","mimetype":"application/json","extended_type":"JSON @@ -692,11 +692,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/51/ + uri: http://sandbox:54110/api/sandbox-artifact/51/ response: body: string: '{"status":"OK"}' @@ -740,11 +740,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":52,"created":"2026-06-03T22:51:55.241927Z","sandbox_task_id":77255104432408221,"instance_number":null,"artifact_type":"recording","meta_community":"","sandbox":"","sha256":"3e819ced39f63e97a494d4c1af4b320ea970f2f6fc45cf2b4bc844622f7d1f08","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/25/25?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225155Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=bd9fae2b14b063549d2ecd63f617dcefdcaf847031aad75b4504091105993a10","name":"recording.cast","mimetype":"application/octet-stream","extended_type":"data","description":"","callback_uri":null,"content_type":"application/octet-stream","status":"created"}' @@ -837,11 +837,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/52/ + uri: http://sandbox:54110/api/sandbox-artifact/52/ response: body: string: '{"status":"OK"}' @@ -885,11 +885,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' diff --git a/test/vcr/test_async_sandboxtask_latest.vcr b/test/vcr/test_async_sandboxtask_latest.vcr index 559e6a9f..0e2d76f8 100644 --- a/test/vcr/test_async_sandboxtask_latest.vcr +++ b/test/vcr/test_async_sandboxtask_latest.vcr @@ -302,11 +302,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -351,11 +351,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":43,"created":"2026-06-03T22:51:42.464066Z","sandbox_task_id":29098827909925940,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/34/34?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225142Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=71ec279f0b7d6eba4ffab7a68e039a57aabfb5067ee592997189ba26a4d2aeee","name":"cape_report.json","mimetype":"application/json","extended_type":"JSON @@ -449,11 +449,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/43/ + uri: http://sandbox:54110/api/sandbox-artifact/43/ response: body: string: '{"status":"OK"}' @@ -497,11 +497,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -545,11 +545,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -594,11 +594,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":44,"created":"2026-06-03T22:51:42.515681Z","sandbox_task_id":70329544145302373,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/44/44?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225142Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=87b17e33e5e087be326ddc9429eb7c806dfa1b882f58f849a14eb0bd05df6bd7","name":"triage_report.json","mimetype":"application/json","extended_type":"JSON @@ -692,11 +692,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/44/ + uri: http://sandbox:54110/api/sandbox-artifact/44/ response: body: string: '{"status":"OK"}' @@ -740,11 +740,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":45,"created":"2026-06-03T22:51:42.551874Z","sandbox_task_id":70329544145302373,"instance_number":null,"artifact_type":"recording","meta_community":"","sandbox":"","sha256":"3e819ced39f63e97a494d4c1af4b320ea970f2f6fc45cf2b4bc844622f7d1f08","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/54/54?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T225142Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=f0d224c8347f944154eafa649b7816355924a0a25fde0b1abd08373068a9dccb","name":"recording.cast","mimetype":"application/octet-stream","extended_type":"data","description":"","callback_uri":null,"content_type":"application/octet-stream","status":"created"}' @@ -837,11 +837,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/45/ + uri: http://sandbox:54110/api/sandbox-artifact/45/ response: body: string: '{"status":"OK"}' @@ -885,11 +885,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' diff --git a/test/vcr/test_iocs_by_hash.vcr b/test/vcr/test_iocs_by_hash.vcr index 10b6366a..ea400d6a 100644 --- a/test/vcr/test_iocs_by_hash.vcr +++ b/test/vcr/test_iocs_by_hash.vcr @@ -253,11 +253,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -302,11 +302,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":86,"created":"2026-06-03T23:18:57.468875Z","sandbox_task_id":65789145233407297,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/68/68?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T231857Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=7d07340eab3262ff840ea2bbacebc6992cc81ee4857eaadf40115cd5ca576e6c","name":"cape_report.json","mimetype":"application/json","extended_type":"JSON @@ -400,11 +400,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/86/ + uri: http://sandbox:54110/api/sandbox-artifact/86/ response: body: string: '{"status":"OK"}' @@ -448,11 +448,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' diff --git a/test/vcr/test_sample.vcr b/test/vcr/test_sample.vcr index 4c5efc71..3e2f6fe5 100644 --- a/test/vcr/test_sample.vcr +++ b/test/vcr/test_sample.vcr @@ -302,11 +302,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -351,11 +351,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":36,"created":"2026-06-03T22:49:28.294971Z","sandbox_task_id":31255528163809489,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/63/63?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224928Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=3800340ba53fb062109e3b665e791b4fb43c8bcf89950dde00597607311a5ea8","name":"cape_report.json","mimetype":"application/json","extended_type":"JSON @@ -449,11 +449,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/36/ + uri: http://sandbox:54110/api/sandbox-artifact/36/ response: body: string: '{"status":"OK"}' @@ -497,11 +497,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -545,11 +545,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -594,11 +594,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":37,"created":"2026-06-03T22:49:28.340780Z","sandbox_task_id":4401068627098637,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/73/73?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224928Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=4e5497e851538a359fa2a4e4d0939e8c2d60e8eec8973126a5c7217d80ff5f82","name":"triage_report.json","mimetype":"application/json","extended_type":"JSON @@ -692,11 +692,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/37/ + uri: http://sandbox:54110/api/sandbox-artifact/37/ response: body: string: '{"status":"OK"}' @@ -740,11 +740,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":38,"created":"2026-06-03T22:49:28.372834Z","sandbox_task_id":4401068627098637,"instance_number":null,"artifact_type":"recording","meta_community":"","sandbox":"","sha256":"3e819ced39f63e97a494d4c1af4b320ea970f2f6fc45cf2b4bc844622f7d1f08","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/83/83?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224928Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=8fff13a32fee63b11f24d5be001d48b8c05e86167199b8c4f857ad3cfbf831f6","name":"recording.cast","mimetype":"application/octet-stream","extended_type":"data","description":"","callback_uri":null,"content_type":"application/octet-stream","status":"created"}' @@ -837,11 +837,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/38/ + uri: http://sandbox:54110/api/sandbox-artifact/38/ response: body: string: '{"status":"OK"}' @@ -885,11 +885,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' diff --git a/test/vcr/test_sandboxtask_latest.vcr b/test/vcr/test_sandboxtask_latest.vcr index 9488e16d..f1c99bf7 100644 --- a/test/vcr/test_sandboxtask_latest.vcr +++ b/test/vcr/test_sandboxtask_latest.vcr @@ -302,11 +302,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -351,11 +351,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":14,"created":"2026-06-03T22:41:19.717282Z","sandbox_task_id":4003121578156118,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/41/41?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224119Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=ed5c31b9fe469b9c34a2f2e65a2d1763994aaac07124a80c6ec9ccccd418e385","name":"cape_report.json","mimetype":"application/json","extended_type":"JSON @@ -449,11 +449,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/14/ + uri: http://sandbox:54110/api/sandbox-artifact/14/ response: body: string: '{"status":"OK"}' @@ -497,11 +497,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -545,11 +545,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' @@ -594,11 +594,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":15,"created":"2026-06-03T22:41:19.766329Z","sandbox_task_id":39946594963020419,"instance_number":null,"artifact_type":"report","meta_community":"","sandbox":"","sha256":"703014278b978e8772c8188f6d66b7d43519abe6af896352181d2ba5758afaa5","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/51/51?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224119Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=6062b8dad4faf263f3b283e810f78bd23e5c034d3a3683fcd9c512a42d616ac8","name":"triage_report.json","mimetype":"application/json","extended_type":"JSON @@ -692,11 +692,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/15/ + uri: http://sandbox:54110/api/sandbox-artifact/15/ response: body: string: '{"status":"OK"}' @@ -740,11 +740,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/ + uri: http://sandbox:54110/api/sandbox-artifact/ response: body: string: '{"id":16,"created":"2026-06-03T22:41:19.798237Z","sandbox_task_id":39946594963020419,"instance_number":null,"artifact_type":"recording","meta_community":"","sandbox":"","sha256":"3e819ced39f63e97a494d4c1af4b320ea970f2f6fc45cf2b4bc844622f7d1f08","parent":null,"upload_url":"http://minio:9000/sandbox-dropped/61/61?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260603%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260603T224119Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=de0809cd4078d3d9e193ee25800090fc9353c72a3dc9dedadb374aba8a5173fa","name":"recording.cast","mimetype":"application/octet-stream","extended_type":"data","description":"","callback_uri":null,"content_type":"application/octet-stream","status":"created"}' @@ -837,11 +837,11 @@ interactions: content-length: - '0' host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: PATCH - uri: http://sandbox-service-e2e:54110/api/sandbox-artifact/16/ + uri: http://sandbox:54110/api/sandbox-artifact/16/ response: body: string: '{"status":"OK"}' @@ -885,11 +885,11 @@ interactions: content-type: - application/json host: - - sandbox-service-e2e:54110 + - sandbox:54110 user-agent: - python-httpx/0.28.1 method: POST - uri: http://sandbox-service-e2e:54110/api/sandbox-task/ + uri: http://sandbox:54110/api/sandbox-task/ response: body: string: '{"status":"OK"}' From 165b5edf45f7185ccbc276372a5e90c3a18e5eb0 Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 6 Aug 2026 18:33:38 -0300 Subject: [PATCH 03/36] =?UTF-8?q?test:=20finish=20the=20sandbox=20hostname?= =?UTF-8?q?=20rename=20=E2=80=94=20the=20SANDBOX=5FSERVICE=5FURI=20constan?= =?UTF-8?q?ts?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The previous commit's replace loop aborted on a binary-bodied cassette midway through the file list, leaving the two SANDBOX_SERVICE_URI constants on the old hostname while the cassettes had moved — suite verified VCR-on after this fix: 163 passed. --- test/async_client_test.py | 2 +- test/client_scan_test.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/async_client_test.py b/test/async_client_test.py index cf51fb8e..b633553e 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -136,7 +136,7 @@ async def _poll_results(agen_factory, tries=30, delay=1): # sandbox service to drive a dispatched SandboxTask to SUCCEEDED (the only state # that makes sandbox_task_latest resolve). Requires the e2e sandbox-service # worker to be running. -SANDBOX_SERVICE_URI = 'http://sandbox-service-e2e:54110' +SANDBOX_SERVICE_URI = 'http://sandbox:54110' async def _post_sandbox_status(client, task_id, status): diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 70573cf1..443f4a56 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -139,7 +139,7 @@ def _poll_results(call, tries=30, delay=1): # sandbox worker makes to the sandbox service (POST api/sandbox-task/ for status; # POST + PUT + PATCH api/sandbox-artifact/ for results), which drive the task to # completion server-side. Requires the e2e sandbox-service worker to be running. -SANDBOX_SERVICE_URI = 'http://sandbox-service-e2e:54110' +SANDBOX_SERVICE_URI = 'http://sandbox:54110' def _post_sandbox_status(task_id, status): From 593eb7570e9d31011851281459cd992054802b38 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Thu, 20 Aug 2026 20:32:05 -0400 Subject: [PATCH 04/36] =?UTF-8?q?feat:=20hunt-page=20ruleset=20tracking=20?= =?UTF-8?q?=E2=80=94=20favorites,=20rule=20counts,=20hunt=20provenance?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit New fields parsed on existing resources (all additive; an older server leaves them None): - YaraRuleset: favorite, favorited_at, rule_count (None means the server had no answer, distinct from 0), historical_hunt_count, and new_results_count (only when the list is asked to include counts). - HistoricalHunt: rule_id (the source ruleset), rule_modified (freeze-time audit value), and source_rule_changed — a tri-state answering "has the source ruleset's body changed since the hunt froze it?" (None = unknown, not 'unchanged'). New endpoints and filters: - ruleset_favorite(id, favorite): idempotent star/unstar; the response carries favorites_used/favorites_limit; over-budget refusals surface a machine-readable FAVORITE_LIMIT error. - ruleset_list(name=, status=, favorites_only=, has_new_results=, since=, include_counts=): the hunt-page filters, conjunctive and optional. - live_results_count(since=): per-live-hunt result counts in a window, one aggregate for every 'new results' badge. - live_feed(livescan_id=): scope the feed to one live hunt. Sync and asyncio clients both. The rules live-suite tests now create a uid-namespaced single-rule ruleset (deterministic rule_count, no name collisions on the shared stack) and exercise the favorite round-trip, provenance, counter increment, and the changed-since-freeze flip; their cassettes are removed to re-record against a stack that serves the new fields. --- src/polyswarm_api/aio/api.py | 54 +++++- src/polyswarm_api/api.py | 62 ++++++- src/polyswarm_api/resources.py | 52 ++++++ test/async_client_test.py | 55 +++++- test/client_scan_test.py | 57 +++++- test/vcr/test_async_rules.vcr | 323 --------------------------------- test/vcr/test_rules.vcr | 323 --------------------------------- 7 files changed, 257 insertions(+), 669 deletions(-) delete mode 100644 test/vcr/test_async_rules.vcr delete mode 100644 test/vcr/test_rules.vcr diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index 18ab4921..ec286cb3 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -502,7 +502,8 @@ async def live_stop(self, rule_id): return await self._single(resources.LiveYaraRuleset.delete(self, rule_id=rule_id)) async def live_feed(self, since=None, rule_name=None, family=None, - polyscore_lower=None, polyscore_upper=None, community=None): + polyscore_lower=None, polyscore_upper=None, community=None, + livescan_id=None): """ Get live hunts feed @@ -512,14 +513,29 @@ async def live_feed(self, since=None, rule_name=None, family=None, :param polyscore_lower: Polyscore lower bound for the hunt results. :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. + :param livescan_id: Scope the feed to one live hunt's results. :return: Generator of HuntResult resources """ async for item in self._paginate(resources.LiveHuntResult.list( self, since=since, rule_name=rule_name, family=family, polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, + livescan_id=livescan_id, community=community or self.community)): yield item + async def live_results_count(self, since=None): + """ + Per-live-hunt result counts for the current account, grouped by + livescan_id. One request answers every "new results in the window" + badge; a hunt absent from counts collected 0. + + :param since: Window in seconds (server default: 86400 — 24 hours) + :return: A LiveHuntResultCounts resource + """ + logger.info('Live results count since %s', since) + return await self._single( + resources.LiveHuntResultCounts.get(self, since=since, community=self.community)) + async def live_feed_delete(self, result_ids): """ Delete live feed results @@ -684,15 +700,47 @@ async def ruleset_delete(self, ruleset_id): logger.info('Delete ruleset %s', ruleset_id) return await self._single(resources.YaraRuleset.delete(self, id=ruleset_id, community=self.community)) - async def ruleset_list(self): + async def ruleset_list(self, name=None, status=None, favorites_only=None, + has_new_results=None, since=None, include_counts=None): """ List all YaraRulesets for the current account. + + All filters are optional and conjunctive: + :param name: Case-insensitive substring match on the ruleset name. + :param status: 'active' returns only rulesets whose live hunt is + currently running. + :param favorites_only: True returns only favorited rulesets. + :param has_new_results: True returns only rulesets whose live hunt + collected results inside the window. + :param since: Window in seconds for has_new_results/include_counts + (server default: 86400). + :param include_counts: True attaches new_results_count to each + ruleset that has a live hunt. :return: A generator of YaraRuleset resources """ logger.info('List rulesets') - async for item in self._paginate(resources.YaraRuleset.list(self, community=self.community)): + async for item in self._paginate(resources.YaraRuleset.list( + self, name=name, status=status, favorites_only=favorites_only, + has_new_results=has_new_results, since=since, + include_counts=include_counts, community=self.community)): yield item + async def ruleset_favorite(self, ruleset_id, favorite=True): + """ + Favorite or unfavorite a YaraRuleset. Idempotent; works while a live + hunt is running. Favorites are shared by the whole team and capped + (the response carries favorites_used / favorites_limit); when the + budget is exhausted the server refuses with a machine-readable + FAVORITE_LIMIT error. + + :param ruleset_id: Id of the ruleset + :param favorite: True to star, False to unstar + :return: A YaraRulesetFavorite resource + """ + logger.info('%s ruleset %s', 'Favorite' if favorite else 'Unfavorite', ruleset_id) + return await self._single(resources.YaraRulesetFavorite.update( + self, id=ruleset_id, favorite=favorite, community=self.community)) + async def tag_link_get(self, sha256): """ Fetch the Tags and Families associated with the given sha256. diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 53400201..40e98315 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -568,6 +568,7 @@ def live_feed( polyscore_lower=None, polyscore_upper=None, community=None, + livescan_id=None, ): """ Get live hunts feed @@ -578,6 +579,7 @@ def live_feed( :param polyscore_lower: Polyscore lower bound for the hunt results. :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. + :param livescan_id: Scope the feed to one live hunt's results. :return: Generator of HuntResult resources """ for item in self._paginate( @@ -588,6 +590,7 @@ def live_feed( family=family, polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, + livescan_id=livescan_id, community=community or self.community, ) ): @@ -823,17 +826,72 @@ def ruleset_delete(self, ruleset_id): resources.YaraRuleset.delete(self, id=ruleset_id, community=self.community) ) - def ruleset_list(self): + def ruleset_list(self, name=None, status=None, favorites_only=None, + has_new_results=None, since=None, include_counts=None): """ List all YaraRulesets for the current account. + + All filters are optional and conjunctive: + :param name: Case-insensitive substring match on the ruleset name. + :param status: 'active' returns only rulesets whose live hunt is + currently running. + :param favorites_only: True returns only favorited rulesets. + :param has_new_results: True returns only rulesets whose live hunt + collected results inside the window. + :param since: Window in seconds for has_new_results/include_counts + (server default: 86400). + :param include_counts: True attaches new_results_count to each + ruleset that has a live hunt. :return: A generator of YaraRuleset resources """ logger.info("List rulesets") for item in self._paginate( - resources.YaraRuleset.list(self, community=self.community) + resources.YaraRuleset.list( + self, + name=name, + status=status, + favorites_only=favorites_only, + has_new_results=has_new_results, + since=since, + include_counts=include_counts, + community=self.community, + ) ): yield item + def ruleset_favorite(self, ruleset_id, favorite=True): + """ + Favorite or unfavorite a YaraRuleset. Idempotent; works while a live + hunt is running. Favorites are shared by the whole team and capped + (the response carries favorites_used / favorites_limit); when the + budget is exhausted the server refuses with a machine-readable + FAVORITE_LIMIT error. + + :param ruleset_id: Id of the ruleset + :param favorite: True to star, False to unstar + :return: A YaraRulesetFavorite resource + """ + logger.info("%s ruleset %s", "Favorite" if favorite else "Unfavorite", ruleset_id) + return self._single( + resources.YaraRulesetFavorite.update( + self, id=ruleset_id, favorite=favorite, community=self.community + ) + ) + + def live_results_count(self, since=None): + """ + Per-live-hunt result counts for the current account, grouped by + livescan_id. One request answers every "new results in the window" + badge; a hunt absent from counts collected 0. + + :param since: Window in seconds (server default: 86400 — 24 hours) + :return: A LiveHuntResultCounts resource + """ + logger.info("Live results count since %s", since) + return self._single( + resources.LiveHuntResultCounts.get(self, since=since, community=self.community) + ) + def tag_link_get(self, sha256): """ Fetch the Tags and Families associated with the given sha256. diff --git a/src/polyswarm_api/resources.py b/src/polyswarm_api/resources.py index fa5f1c1d..22de9654 100644 --- a/src/polyswarm_api/resources.py +++ b/src/polyswarm_api/resources.py @@ -746,12 +746,41 @@ def __init__(self, content, api=None): self.modified = core.parse_isoformat(content.get('modified')) self.deleted = content.get('deleted') self.yara = content.get('yara') + # Hunt-page tracking fields. All additive — an older server simply + # leaves them None. + self.favorite = content.get('favorite') + self.favorited_at = core.parse_isoformat(content.get('favorited_at')) + # Number of rules in the ruleset body. None means "no answer" (the + # server could not or has not counted), which is different from 0. + self.rule_count = content.get('rule_count') + self.historical_hunt_count = content.get('historical_hunt_count') + # Live results collected in the requested window; only present when + # the list was asked to include counts, and only for rulesets with a + # live hunt — None otherwise. + self.new_results_count = content.get('new_results_count') class LiveYaraRuleset(YaraRuleset): RESOURCE_ENDPOINT = '/hunt/rule/live' +class YaraRulesetFavorite(core.BaseJsonResource): + """The favorite-toggle response: the ruleset's new star state plus the + team's budget usage, so callers can render "N of M used" without counting + client-side.""" + RESOURCE_ENDPOINT = '/hunt/rule/favorite' + # No query-string keys: the toggle takes {id, favorite} in the JSON body. + RESOURCE_ID_KEYS = [] + + def __init__(self, content, api=None): + super().__init__(content, api=api) + self.id = content.get('id') + self.favorite = content.get('favorite') + self.favorited_at = core.parse_isoformat(content.get('favorited_at')) + self.favorites_used = content.get('favorites_used') + self.favorites_limit = content.get('favorites_limit') + + class LiveHuntResult(core.BaseJsonResource): RESOURCE_ENDPOINT = '/hunt/live' @@ -778,6 +807,19 @@ class LiveHuntResultList(LiveHuntResult): RESOURCE_ENDPOINT = '/hunt/live/list' +class LiveHuntResultCounts(core.BaseJsonResource): + """Per-live-hunt result counts inside a window: ``since`` (seconds) plus + ``counts``, a list of ``{livescan_id, count}`` — one aggregate request for + every "new results" badge. A hunt with no results in the window is simply + absent from ``counts``; absence means 0.""" + RESOURCE_ENDPOINT = '/hunt/live/results/count' + + def __init__(self, content, api=None): + super().__init__(content, api=api) + self.since = content.get('since') + self.counts = content.get('counts') or [] + + class HistoricalHunt(core.BaseJsonResource): RESOURCE_ENDPOINT = '/hunt/historical' @@ -794,6 +836,16 @@ def __init__(self, content, api=None): self.progress = content['progress'] self.results_csv_uri = content['results_csv_uri'] self.communities = content.get('communities') + # Source-rule provenance. rule_id is the ruleset this hunt was + # triggered from (None for raw-yara hunts and hunts predating the + # tracking); rule_modified is a freeze-time audit timestamp. + self.rule_id = content.get('rule_id') + self.rule_modified = core.parse_isoformat(content.get('rule_modified')) + # Tri-state: has the source ruleset's body changed SINCE THE HUNT + # FROZE IT? True/False when the server could compare; None means + # unknown (no source rule, or nothing to compare against) — not + # "unchanged". + self.source_rule_changed = content.get('source_rule_changed') class HistoricalHuntList(HistoricalHunt): diff --git a/test/async_client_test.py b/test/async_client_test.py index b633553e..b495799d 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -608,26 +608,63 @@ async def test_async_sample(self, uid): # ── YARA Rulesets ───────────────────────────────────────────────────────── @vcr.use_cassette() - async def test_async_rules(self): + async def test_async_rules(self, uid): async with self._api() as api: - with open('test/eicar.yara') as f: - contents = f.read() - rule = await api.ruleset_create('test', contents) - assert rule.name == 'test' + # A uid-namespaced single-rule body: unique name on the shared + # stack, deterministic rule_count of 1. + contents = uid_yara(uid) + rule = await api.ruleset_create(uid, contents) + assert rule.name == uid assert rule.yara == contents + # Tracking fields are live from creation. + assert rule.rule_count == 1 + assert rule.favorite is False + assert rule.favorited_at is None + assert rule.historical_hunt_count == 0 + hunt = None try: # The e2e may carry leftover rulesets from prior runs; use # a presence assertion instead of an exact count. rules = [r async for r in api.ruleset_list()] assert any(r.id == rule.id for r in rules) + by_name = [r.id async for r in api.ruleset_list(name=uid)] + assert rule.id in by_name got = await api.ruleset_get(rule.id) - assert got.name == 'test' - - updated = await api.ruleset_update(rule.id, name='test2', description='test') - assert updated.name == 'test2' + assert got.name == uid + + # favorite round-trip with the server-owned budget counts + fav = await api.ruleset_favorite(rule.id, True) + assert fav.favorite is True + assert fav.favorited_at is not None + assert fav.favorites_limit == 5 + assert 1 <= fav.favorites_used <= fav.favorites_limit + favorites = [r async for r in api.ruleset_list(favorites_only=True)] + assert any(r.id == rule.id and r.favorite for r in favorites) + unfav = await api.ruleset_favorite(rule.id, False) + assert unfav.favorite is False + assert unfav.favorited_at is None + + # a hunt triggered FROM the ruleset carries provenance and + # bumps the counter; the create response's comparison is + # unknown (None) and a read resolves it + hunt = await api.historical_create(int(rule.id)) + assert hunt.rule_id == rule.id + assert hunt.rule_modified is not None + assert hunt.source_rule_changed is None + assert (await api.ruleset_get(rule.id)).historical_hunt_count == 1 + hunt_read = await api.historical_get(hunt.id) + assert hunt_read.source_rule_changed is False + + # a body edit flips the hunt's source_rule_changed + updated = await api.ruleset_update( + rule.id, name=f'{uid}2', rules=f'{contents}\n// edited', description='test') + assert updated.name == f'{uid}2' assert updated.description == 'test' + assert (await api.historical_get(hunt.id)).source_rule_changed is True finally: + if hunt is not None: + await api.historical_delete(hunt.id) await api.ruleset_delete(rule.id) remaining_ids = [] try: diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 443f4a56..65d383d1 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -569,26 +569,65 @@ def test_historical_results(self): @vcr.use_cassette() def test_rules(self): api = PolyswarmAPI(self.test_api_key, uri=f'http://ai:9696/{self.api_version}', community='gamma') - # creating - with open('test/eicar.yara') as rule: - contents = rule.read() - rule = api.ruleset_create('test', contents) - assert rule.name == 'test' + # creating — a uid-namespaced single-rule body, so the name is unique + # on the shared stack and rule_count is deterministically 1. + uid = self._testMethodName + contents = uid_yara(uid) + rule = api.ruleset_create(uid, contents) + assert rule.name == uid assert rule.yara == contents + # The tracking fields are live from creation: the body was counted on + # the way in, nothing is starred yet, no hunts have been triggered. + assert rule.rule_count == 1 + assert rule.favorite is False + assert rule.favorited_at is None + assert rule.historical_hunt_count == 0 + hunt = None try: # listing — the created rule must be in the list; the e2e may carry # other rulesets from earlier runs, so use a presence assertion # rather than an exact count. rules = list(api.ruleset_list()) assert any(r.id == rule.id for r in rules) + # the name filter narrows to this test's own rule + by_name = [r.id for r in api.ruleset_list(name=uid)] + assert rule.id in by_name # getting got = api.ruleset_get(rule.id) - assert got.name == 'test' - # updating - updated = api.ruleset_update(rule.id, name='test2', description='test') - assert updated.name == 'test2' + assert got.name == uid + # favorite round-trip, with the budget counts the server owns + fav = api.ruleset_favorite(rule.id, True) + assert fav.favorite is True + assert fav.favorited_at is not None + assert fav.favorites_limit == 5 + # other runs may hold stars on the shared stack — bound, not pin + assert 1 <= fav.favorites_used <= fav.favorites_limit + favorites = list(api.ruleset_list(favorites_only=True)) + assert any(r.id == rule.id and r.favorite for r in favorites) + unfav = api.ruleset_favorite(rule.id, False) + assert unfav.favorite is False + assert unfav.favorited_at is None + # a historical hunt triggered FROM the ruleset carries the + # provenance and bumps the ruleset's counter; the create response's + # source_rule_changed is None (unknown until a read re-resolves it) + hunt = api.historical_create(int(rule.id)) + assert hunt.rule_id == rule.id + assert hunt.rule_modified is not None + assert hunt.source_rule_changed is None + assert api.ruleset_get(rule.id).historical_hunt_count == 1 + # a read of the fresh hunt resolves the comparison: unchanged body + hunt_read = api.historical_get(hunt.id) + assert hunt_read.rule_id == rule.id + assert hunt_read.source_rule_changed is False + # updating — a body edit flips the hunt's source_rule_changed + updated = api.ruleset_update( + rule.id, name=f'{uid}2', rules=f'{contents}\n// edited', description='test') + assert updated.name == f'{uid}2' assert updated.description == 'test' + assert api.historical_get(hunt.id).source_rule_changed is True finally: + if hunt is not None: + api.historical_delete(hunt.id) # deleting — the created rule disappears from the list. api.ruleset_delete(rule.id) remaining_ids = [] diff --git a/test/vcr/test_async_rules.vcr b/test/vcr/test_async_rules.vcr deleted file mode 100644 index 751c4b2a..00000000 --- a/test/vcr/test_async_rules.vcr +++ /dev/null @@ -1,323 +0,0 @@ -interactions: -- request: - body: '{"yara":"rule eicar_av_test {\n /*\n Per standard, match only - if entire file is EICAR string plus optional trailing whitespace.\n The - raw EICAR string to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = \"Austin - Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}","name":"test"}' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - content-length: - - '1126' - content-type: - - application/json - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: POST - uri: http://ai:9696/v3/hunt/rule - response: - body: - string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":null,"id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1346' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:30:27 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: GET - uri: http://ai:9696/v3/hunt/rule/list?community=gamma - response: - body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":null,"id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test","yara":null}],"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '277' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:30:27 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: GET - uri: http://ai:9696/v3/hunt/rule?id=40732127887168358&community=gamma - response: - body: - string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":null,"id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1346' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:30:27 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '{"name":"test2","description":"test","community":"gamma"}' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - content-length: - - '57' - content-type: - - application/json - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: PUT - uri: http://ai:9696/v3/hunt/rule?id=40732127887168358 - response: - body: - string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":false,"description":"test","id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.081195+00:00","name":"test2","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1349' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:30:27 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '{"community":"gamma"}' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - content-length: - - '21' - content-type: - - application/json - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: DELETE - uri: http://ai:9696/v3/hunt/rule?id=40732127887168358 - response: - body: - string: '{"result":{"created":"2026-06-02T21:30:27.081195+00:00","deleted":true,"description":"test","id":"40732127887168358","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:30:27.152617+00:00","name":"test2","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1348' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:30:27 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: GET - uri: http://ai:9696/v3/hunt/rule/list?community=gamma - response: - body: - string: '' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Type: - - text/html; charset=utf-8 - Date: - - Tue, 02 Jun 2026 21:30:27 GMT - Server: - - gunicorn - status: - code: 204 - message: NO CONTENT -version: 1 diff --git a/test/vcr/test_rules.vcr b/test/vcr/test_rules.vcr deleted file mode 100644 index 7a3d8518..00000000 --- a/test/vcr/test_rules.vcr +++ /dev/null @@ -1,323 +0,0 @@ -interactions: -- request: - body: '{"yara":"rule eicar_av_test {\n /*\n Per standard, match only - if entire file is EICAR string plus optional trailing whitespace.\n The - raw EICAR string to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = \"Austin - Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}","name":"test"}' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - content-length: - - '1126' - content-type: - - application/json - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: POST - uri: http://ai:9696/v3/hunt/rule - response: - body: - string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":null,"id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1346' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:32:01 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: GET - uri: http://ai:9696/v3/hunt/rule/list?community=gamma - response: - body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":null,"id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test","yara":null}],"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '277' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:32:01 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: GET - uri: http://ai:9696/v3/hunt/rule?id=68232116824597140&community=gamma - response: - body: - string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":null,"id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1346' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:32:01 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '{"name":"test2","description":"test","community":"gamma"}' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - content-length: - - '57' - content-type: - - application/json - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: PUT - uri: http://ai:9696/v3/hunt/rule?id=68232116824597140 - response: - body: - string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":false,"description":"test","id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.681881+00:00","name":"test2","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1349' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:32:01 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '{"community":"gamma"}' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - content-length: - - '21' - content-type: - - application/json - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: DELETE - uri: http://ai:9696/v3/hunt/rule?id=68232116824597140 - response: - body: - string: '{"result":{"created":"2026-06-02T21:32:01.681881+00:00","deleted":true,"description":"test","id":"68232116824597140","livescan_created":null,"livescan_id":null,"modified":"2026-06-02T21:32:01.766631+00:00","name":"test2","yara":"rule - eicar_av_test {\n /*\n Per standard, match only if entire file is - EICAR string plus optional trailing whitespace.\n The raw EICAR string - to be matched is:\n X5O!P%@AP[4\\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*\n */\n\n meta:\n description - = \"This is a standard AV test, intended to verify that BinaryAlert is working - correctly.\"\n author = \"Austin Byers | Airbnb CSIRT\"\n reference - = \"http://www.eicar.org/86-0-Intended-use.html\"\n\n strings:\n $eicar_regex - = /^X5O!P%@AP\\[4\\\\PZX54\\(P\\^\\)7CC\\)7\\}\\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\\$H\\+H\\*\\s*$/\n\n condition:\n all - of them\n}\n\nrule eicar_substring_test {\n /*\n More generic - match - just the embedded EICAR string (e.g. in packed executables, PDFs, etc)\n */\n\n meta:\n description - = \"Standard AV test, checking for an EICAR substring\"\n author = - \"Austin Byers | Airbnb CSIRT\"\n\n strings:\n $eicar_substring - = \"$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\"\n\n condition:\n all - of them\n}"},"status":"OK"} - - ' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Length: - - '1348' - Content-Type: - - application/json - Date: - - Tue, 02 Jun 2026 21:32:01 GMT - Server: - - gunicorn - X-Billing-ID: - - '111' - status: - code: 200 - message: OK -- request: - body: '' - headers: - accept: - - '*/*' - accept-encoding: - - gzip, deflate - authorization: - - '11111111111111111111111111111111' - connection: - - keep-alive - host: - - ai:9696 - user-agent: - - polyswarm_api/3.21.0 (x86_64-Linux-CPython-3.14.4) - method: GET - uri: http://ai:9696/v3/hunt/rule/list?community=gamma - response: - body: - string: '' - headers: - Access-Control-Allow-Origin: - - '*' - Access-Control-Expose-Headers: - - Authorization - Connection: - - keep-alive - Content-Type: - - text/html; charset=utf-8 - Date: - - Tue, 02 Jun 2026 21:32:01 GMT - Server: - - gunicorn - status: - code: 204 - message: NO CONTENT -version: 1 From 3c1861ffdbffacb1a728e13fd08f0510cc09f516 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Thu, 20 Aug 2026 21:38:50 -0400 Subject: [PATCH 05/36] fix: regenerate the sync mirror; poll replica-backed assertions The sync api.py was hand-edited; scripts/regenerate_sync.py places live_results_count in aio's order and applies ruff's formatting, which is what the unasync-mirror CI gate diffs against. The rules live-tests' three read-after-write assertions (the counter, and both sides of the changed-since-freeze flip) now poll: those GETs read the replica, and on a real-replica stack the stale read of the flip is a silent False. Sleeps are free on VCR replay. --- src/polyswarm_api/api.py | 45 ++++++++++++++++++++++++--------------- test/_e2e_helpers.py | 40 ++++++++++++++++++++++++++++++++++ test/async_client_test.py | 19 ++++++++++++----- test/client_scan_test.py | 14 ++++++++---- 4 files changed, 92 insertions(+), 26 deletions(-) diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 40e98315..62b27d70 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -596,6 +596,22 @@ def live_feed( ): yield item + def live_results_count(self, since=None): + """ + Per-live-hunt result counts for the current account, grouped by + livescan_id. One request answers every "new results in the window" + badge; a hunt absent from counts collected 0. + + :param since: Window in seconds (server default: 86400 — 24 hours) + :return: A LiveHuntResultCounts resource + """ + logger.info("Live results count since %s", since) + return self._single( + resources.LiveHuntResultCounts.get( + self, since=since, community=self.community + ) + ) + def live_feed_delete(self, result_ids): """ Delete live feed results @@ -826,8 +842,15 @@ def ruleset_delete(self, ruleset_id): resources.YaraRuleset.delete(self, id=ruleset_id, community=self.community) ) - def ruleset_list(self, name=None, status=None, favorites_only=None, - has_new_results=None, since=None, include_counts=None): + def ruleset_list( + self, + name=None, + status=None, + favorites_only=None, + has_new_results=None, + since=None, + include_counts=None, + ): """ List all YaraRulesets for the current account. @@ -871,27 +894,15 @@ def ruleset_favorite(self, ruleset_id, favorite=True): :param favorite: True to star, False to unstar :return: A YaraRulesetFavorite resource """ - logger.info("%s ruleset %s", "Favorite" if favorite else "Unfavorite", ruleset_id) + logger.info( + "%s ruleset %s", "Favorite" if favorite else "Unfavorite", ruleset_id + ) return self._single( resources.YaraRulesetFavorite.update( self, id=ruleset_id, favorite=favorite, community=self.community ) ) - def live_results_count(self, since=None): - """ - Per-live-hunt result counts for the current account, grouped by - livescan_id. One request answers every "new results in the window" - badge; a hunt absent from counts collected 0. - - :param since: Window in seconds (server default: 86400 — 24 hours) - :return: A LiveHuntResultCounts resource - """ - logger.info("Live results count since %s", since) - return self._single( - resources.LiveHuntResultCounts.get(self, since=since, community=self.community) - ) - def tag_link_get(self, sha256): """ Fetch the Tags and Families associated with the given sha256. diff --git a/test/_e2e_helpers.py b/test/_e2e_helpers.py index 59c5d21c..d150fa75 100644 --- a/test/_e2e_helpers.py +++ b/test/_e2e_helpers.py @@ -23,6 +23,7 @@ import os import re import tempfile +import time from concurrent.futures import ThreadPoolExecutor from contextlib import contextmanager @@ -132,3 +133,42 @@ async def run_concurrently_async(coros): if _vcr_off() and len(coros) > 1: return await asyncio.gather(*coros) return [await c for c in coros] + + +def poll_equals(read, want, tries=30, delay=1.0): + """Poll a zero-arg ``read`` until it returns ``want`` (or tries run out), + returning the last value read. For read-after-write assertions against + replica-backed GET endpoints (specs/04 in the server repo): on the e2e + stack the replica IS the primary so the first read usually wins, but a + real-replica stack lags — without the poll those assertions are + lag-flaky, and the changed-since-freeze one flakes in the silent + direction (stale source body reads as "unchanged"). Not-found during the + lag window counts as "not yet". Sleeps are free on VCR replay + (``_skip_poll_sleep_on_replay``).""" + from polyswarm_api import exceptions as _exceptions + value = None + for _ in range(tries): + try: + value = read() + except (_exceptions.NotFoundException, _exceptions.NoResultsException): + value = None + if value == want: + return value + time.sleep(delay) + return value + + +async def poll_equals_async(read, want, tries=30, delay=1.0): + """The asyncio twin of ``poll_equals`` (``read`` is a zero-arg coroutine + function).""" + from polyswarm_api import exceptions as _exceptions + value = None + for _ in range(tries): + try: + value = await read() + except (_exceptions.NotFoundException, _exceptions.NoResultsException): + value = None + if value == want: + return value + await asyncio.sleep(delay) + return value diff --git a/test/async_client_test.py b/test/async_client_test.py index b495799d..b281bb5c 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -29,7 +29,7 @@ from polyswarm_api import exceptions from test._e2e_helpers import ( - EICAR_STRING, malicious_artifact, artifact_file, uid_ip, uid_host, uid_yara, + EICAR_STRING, malicious_artifact, artifact_file, uid_ip, uid_host, uid_yara, poll_equals_async, assert_scanned, run_concurrently_async, ) @@ -652,16 +652,25 @@ async def test_async_rules(self, uid): assert hunt.rule_id == rule.id assert hunt.rule_modified is not None assert hunt.source_rule_changed is None - assert (await api.ruleset_get(rule.id)).historical_hunt_count == 1 - hunt_read = await api.historical_get(hunt.id) - assert hunt_read.source_rule_changed is False + + # replica-backed GETs: poll so a lagging replica (real + # stacks, not e2e) can't flake these — the changed-since- + # freeze flip's stale read is a silent False + async def _hunt_count(): + return (await api.ruleset_get(rule.id)).historical_hunt_count + + async def _changed(): + return (await api.historical_get(hunt.id)).source_rule_changed + + assert await poll_equals_async(_hunt_count, 1) == 1 + assert await poll_equals_async(_changed, False) is False # a body edit flips the hunt's source_rule_changed updated = await api.ruleset_update( rule.id, name=f'{uid}2', rules=f'{contents}\n// edited', description='test') assert updated.name == f'{uid}2' assert updated.description == 'test' - assert (await api.historical_get(hunt.id)).source_rule_changed is True + assert await poll_equals_async(_changed, True) is True finally: if hunt is not None: await api.historical_delete(hunt.id) diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 65d383d1..a48cb140 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -17,7 +17,7 @@ from polyswarm_api import exceptions from test._e2e_helpers import ( - EICAR_STRING, malicious_artifact, artifact_file, uid_ip, uid_host, uid_yara, + EICAR_STRING, malicious_artifact, artifact_file, uid_ip, uid_host, uid_yara, poll_equals, assert_scanned, run_concurrently, ) @@ -614,17 +614,23 @@ def test_rules(self): assert hunt.rule_id == rule.id assert hunt.rule_modified is not None assert hunt.source_rule_changed is None - assert api.ruleset_get(rule.id).historical_hunt_count == 1 + # the GETs below read the replica; poll so a lagging replica + # (real stacks, not e2e) can't flake these — especially the + # changed-since-freeze flip, whose stale read is a silent False + assert poll_equals( + lambda: api.ruleset_get(rule.id).historical_hunt_count, 1) == 1 # a read of the fresh hunt resolves the comparison: unchanged body hunt_read = api.historical_get(hunt.id) assert hunt_read.rule_id == rule.id - assert hunt_read.source_rule_changed is False + assert poll_equals( + lambda: api.historical_get(hunt.id).source_rule_changed, False) is False # updating — a body edit flips the hunt's source_rule_changed updated = api.ruleset_update( rule.id, name=f'{uid}2', rules=f'{contents}\n// edited', description='test') assert updated.name == f'{uid}2' assert updated.description == 'test' - assert api.historical_get(hunt.id).source_rule_changed is True + assert poll_equals( + lambda: api.historical_get(hunt.id).source_rule_changed, True) is True finally: if hunt is not None: api.historical_delete(hunt.id) From 8aeaa03d7f265fe4daedf70937838fe2434970cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Thu, 20 Aug 2026 22:55:39 -0400 Subject: [PATCH 06/36] docs: livescan_id join key is a digit string Ids exceed JavaScript's safe-integer range; the counts entries carry the same digit string YaraRuleset.livescan_id does. --- src/polyswarm_api/resources.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/polyswarm_api/resources.py b/src/polyswarm_api/resources.py index 22de9654..10b909b0 100644 --- a/src/polyswarm_api/resources.py +++ b/src/polyswarm_api/resources.py @@ -810,8 +810,11 @@ class LiveHuntResultList(LiveHuntResult): class LiveHuntResultCounts(core.BaseJsonResource): """Per-live-hunt result counts inside a window: ``since`` (seconds) plus ``counts``, a list of ``{livescan_id, count}`` — one aggregate request for - every "new results" badge. A hunt with no results in the window is simply - absent from ``counts``; absence means 0.""" + every "new results" badge. ``livescan_id`` is a digit string, the same + value ``YaraRuleset.livescan_id`` carries (the join key; ids exceed + JavaScript's safe-integer range, so they are never bare JSON ints). A hunt + with no results in the window is simply absent from ``counts``; absence + means 0.""" RESOURCE_ENDPOINT = '/hunt/live/results/count' def __init__(self, content, api=None): From b66f9d473e9b82f0f89d11f22be4eb2615db5e48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Fri, 21 Aug 2026 09:59:54 -0400 Subject: [PATCH 07/36] test: record the rules cassettes against a live stack MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Recorded against the branch server image (both tests green live first); the offline suite replays them — 163 passed with no stack. --- test/vcr/test_async_rules.vcr | 667 ++++++++++++++++++++++++++++++++ test/vcr/test_rules.vcr | 708 ++++++++++++++++++++++++++++++++++ 2 files changed, 1375 insertions(+) create mode 100644 test/vcr/test_async_rules.vcr create mode 100644 test/vcr/test_rules.vcr diff --git a/test/vcr/test_async_rules.vcr b/test/vcr/test_async_rules.vcr new file mode 100644 index 00000000..0c27690a --- /dev/null +++ b/test/vcr/test_async_rules.vcr @@ -0,0 +1,667 @@ +interactions: +- request: + body: '{"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" + condition: $u }","name":"test_async_rules"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '115' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: POST + uri: http://ai:9696/v3/hunt/rule + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '413' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:21 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '392' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:21 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?name=test_async_rules&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '392' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule?id=69323308443642315&community=gamma + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '413' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"id":"69323308443642315","favorite":1,"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '59' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: PUT + uri: http://ai:9696/v3/hunt/rule/favorite + response: + body: + string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T13:59:22.129436+00:00","favorites_limit":5,"favorites_used":1,"id":"69323308443642315"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '157' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?favorites_only=1&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T13:59:22.129436+00:00","historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '421' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"id":"69323308443642315","favorite":0,"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '59' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: PUT + uri: http://ai:9696/v3/hunt/rule/favorite + response: + body: + string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"69323308443642315"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '128' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"rule_id":"69323308443642315","community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '51' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: POST + uri: http://ai:9696/v3/hunt/historical + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '578' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule?id=69323308443642315&community=gamma + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '413' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/historical?id=95693942031500728&community=gamma + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '579' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"name":"test_async_rules2","yara":"rule sdk_test_async_rules { strings: + $u = \"test_async_rules\" condition: $u }\n// edited","description":"test","community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '168' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: PUT + uri: http://ai:9696/v3/hunt/rule?id=69323308443642315 + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:22.863472+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }\n// + edited"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '427' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/historical?id=95693942031500728&community=gamma + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '578' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:22 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '21' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: DELETE + uri: http://ai:9696/v3/hunt/historical?id=95693942031500728 + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '579' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:23 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '21' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: DELETE + uri: http://ai:9696/v3/hunt/rule?id=69323308443642315 + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:23.191803+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }\n// + edited"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '426' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:23 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Fri, 21 Aug 2026 13:59:23 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +version: 1 diff --git a/test/vcr/test_rules.vcr b/test/vcr/test_rules.vcr new file mode 100644 index 00000000..eb759388 --- /dev/null +++ b/test/vcr/test_rules.vcr @@ -0,0 +1,708 @@ +interactions: +- request: + body: '{"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: + $u }","name":"test_rules"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '97' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: POST + uri: http://ai:9696/v3/hunt/rule + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '395' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:17 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '386' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:18 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?name=test_rules&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '386' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:18 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule?id=14693852690318397&community=gamma + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '395' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:18 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"id":"14693852690318397","favorite":1,"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '59' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: PUT + uri: http://ai:9696/v3/hunt/rule/favorite + response: + body: + string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T13:59:18.816554+00:00","favorites_limit":5,"favorites_used":1,"id":"14693852690318397"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '157' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:18 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?favorites_only=1&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T13:59:18.816554+00:00","historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '415' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:18 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"id":"14693852690318397","favorite":0,"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '59' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: PUT + uri: http://ai:9696/v3/hunt/rule/favorite + response: + body: + string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"14693852690318397"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '128' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:18 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"rule_id":"14693852690318397","community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '51' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: POST + uri: http://ai:9696/v3/hunt/historical + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '560' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule?id=14693852690318397&community=gamma + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '395' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/historical?id=21276230498013503&community=gamma + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '561' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/historical?id=21276230498013503&community=gamma + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '561' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"name":"test_rules2","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" + condition: $u }\n// edited","description":"test","community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '150' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: PUT + uri: http://ai:9696/v3/hunt/rule?id=14693852690318397 + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:19.602433+00:00","name":"test_rules2","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }\n// edited"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '409' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/historical?id=21276230498013503&community=gamma + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '560' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '21' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: DELETE + uri: http://ai:9696/v3/hunt/historical?id=21276230498013503 + response: + body: + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '561' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:19 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '{"community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '21' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: DELETE + uri: http://ai:9696/v3/hunt/rule?id=14693852690318397 + response: + body: + string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:20.153029+00:00","name":"test_rules2","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }\n// edited"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '408' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 13:59:20 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Fri, 21 Aug 2026 13:59:20 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +version: 1 From 40bc463ab5decda7924469ce63ec4e74e0686b3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Fri, 21 Aug 2026 10:31:10 -0400 Subject: [PATCH 08/36] test+docs: cover the new surfaces end to end; spec the contract (review) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Review findings, all four: - specs updated in the same PR as required: 03-endpoints gains ruleset_favorite / live_results_count rows, the real ruleset_list signature and live_feed's livescan_id; 02-resources catalogues both new resources — including why YaraRulesetFavorite empties RESOURCE_ID_KEYS (the server reads the toggle from the PUT body; the empty key list is the only thing routing id there) and the bool→int body serialisation; 05's commonly-imported list carries both. - the rules live-tests now exercise every previously-uncovered surface against the real stack (and the cassettes record it): live_start → status=active filter → include_counts observed as a computed 0 (distinct from null) → live_results_count (our zero-result hunt ABSENT from counts, keyed by the same digit strings ruleset_get renders) → the livescan_id-scoped feed → live_stop, with the stop in a finally because a running hunt blocks ruleset deletion. - pure-unit builder tests (hunt_tracking_builder_test.py, the known_good_test pattern) pin the request shapes: the favorite PUT's body routing incl. 1/0 bools, counts query routing + None omission, the list filters' int bools and byte-compatible no-filter request, and livescan_id stringification. - the unstar stays a contract assertion with slot hygiene documented: ruleset_delete soft-deletes and the budget counts only deleted=false rows, so a failed run's star frees itself with the rule. The limit pin vs used bound is now commented as deliberate. Also: test/eicar.yara deleted (no test references it since the uid_yara move; the helper docstring no longer names the file). --- specs/02-resources.md | 6 +- specs/03-endpoints.md | 6 +- specs/05-downstream-contract.md | 4 +- test/_e2e_helpers.py | 4 +- test/async_client_test.py | 41 +++ test/client_scan_test.py | 38 ++- test/eicar.yara | 34 --- test/hunt_tracking_builder_test.py | 99 +++++++ test/vcr/test_async_rules.vcr | 447 +++++++++++++++++++++++++---- test/vcr/test_rules.vcr | 419 ++++++++++++++++++++++++--- 10 files changed, 958 insertions(+), 140 deletions(-) delete mode 100644 test/eicar.yara create mode 100644 test/hunt_tracking_builder_test.py diff --git a/specs/02-resources.md b/specs/02-resources.md index 181bbd81..fb626629 100644 --- a/specs/02-resources.md +++ b/specs/02-resources.md @@ -36,7 +36,9 @@ BaseResource # holds .api, ._content, .parse_result cla ├── HistoricalHunt # /hunt/historical ├── HistoricalHuntResult / List # /hunt/historical/results (+ /results/list) ├── LiveHuntResult / List # /hunt/live (+ /hunt/live/list) + ├── LiveHuntResultCounts # /hunt/live/results/count ├── YaraRuleset # /hunt/rule + ├── YaraRulesetFavorite # /hunt/rule/favorite ├── Tag, MalwareFamily, TagLink # /tags/tag, /tags/family, /tags/link ├── AssertionsJob, VotesJob # /consumer/assertions-job, /consumer/votes-job ├── SandboxTask, SandboxProvider # /sandbox/sandboxtask, /sandbox/provider @@ -343,7 +345,9 @@ Holds `handle`, `artifact_name`, `artifact_type`, `sha256`, `sha1`, `md5`. Also Several resources add domain-specific classmethods on top of the standard CRUD set: - `IOC` — `iocs_by_hash`, `ioc_search`, `check_known_hosts`, `create_known_good`, `create_known_bad`, `update_known_good`, `delete_known_good`. -- `LiveYaraRuleset` / `HistoricalHunt` / `YaraRuleset` — standard CRUD plus list/delete-batch variants. +- `LiveYaraRuleset` / `HistoricalHunt` / `YaraRuleset` — standard CRUD plus list/delete-batch variants. `YaraRuleset` also parses the hunt-page tracking fields (`favorite`, `favorited_at`, `rule_count` — `None` means the server had no answer, distinct from 0 — `historical_hunt_count`, `new_results_count`), and `HistoricalHunt` the source-rule provenance (`rule_id`, `rule_modified`, and the tri-state `source_rule_changed` — `None` is "unknown", never "unchanged"). All additive `.get()` parses; an older server leaves them `None`. +- `YaraRulesetFavorite` — `RESOURCE_ENDPOINT = '/hunt/rule/favorite'`, **`RESOURCE_ID_KEYS = []`**: a deliberate deviation from the default `['id']`, because the server reads the toggle exclusively from the PUT **body** — emptying the key list is the only thing routing `id` (plus `favorite`/`community`) into `json` instead of the query string. `favorite` serialises as `1`/`0` (the `_params` bool→int coercion), which the server's boolean parser accepts. Response carries the star state plus the team's `favorites_used`/`favorites_limit`. Pinned by `test/hunt_tracking_builder_test.py`. +- `LiveHuntResultCounts` — `RESOURCE_ENDPOINT = '/hunt/live/results/count'`, GET-only; `since` (seconds) rides the query and is omitted when unset (server default window). `counts` is a list of `{livescan_id, count}` with `livescan_id` as a digit string — the same join key `YaraRuleset.livescan_id` carries; a hunt absent from `counts` collected 0. - `SandboxTask` — `create_file`, `update_file`, `latest`, `my_tasks` for the various sandbox-submission shapes. **No `upload_file` instance method** in 4.0. - `Sample` — `create` with `endpoint_fmt={'sha256': sha256}` for the URL-parametrised path. - `Webhook` — `test(api, webhook_id)` for the test-payload endpoint. diff --git a/specs/03-endpoints.md b/specs/03-endpoints.md index eea14fd5..b33e2bbe 100644 --- a/specs/03-endpoints.md +++ b/specs/03-endpoints.md @@ -86,6 +86,7 @@ Internal-only CRUD for the `/known-good` binary resource (distinct from the IOC | `ruleset_create(name, rules, description=None)` | `YaraRuleset.create` | | `ruleset_get(ruleset_id=None)` | `YaraRuleset.get` | | `ruleset_update(ruleset_id, name=None, rules=None, description=None)` | `YaraRuleset.update` | +| `ruleset_favorite(ruleset_id, favorite=True)` | `YaraRulesetFavorite.update` — idempotent star/unstar; the response carries the team's `favorites_used`/`favorites_limit`, and an over-budget star is refused with a machine-readable `FAVORITE_LIMIT` error. The id rides the PUT **body**, not the query (see the `RESOURCE_ID_KEYS = []` note in specs/02) | | `ruleset_delete(ruleset_id)` | `YaraRuleset.delete` | | `tag_link_get(sha256)` | `TagLink.get` | | `tag_link_update(sha256, tags=None, families=None, emerging=None, remove=False)` | `TagLink.update` | @@ -186,10 +187,11 @@ refusal. | `iocs_by_hash(hash_type, hash_value, hide_known_good=False, beta=False)` | `IOC.iocs_by_hash` | | `search_by_ioc(ip=None, domain=None, ttp=None, imphash=None)` | `IOC.ioc_search` | | `check_known_hosts(ips=[], domains=[])` | `IOC.check_known_hosts` | -| `live_feed(since=None, …)` | `LiveHuntResult.list` | +| `live_feed(since=None, …, livescan_id=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed) | +| `live_results_count(since=None)` | `LiveHuntResultCounts.get` — per-live-hunt result counts in a window, grouped by `livescan_id` (digit strings, the same join key `YaraRuleset.livescan_id` carries); a hunt absent from `counts` collected 0 | | `historical_list(since=None)` | `HistoricalHunt.list` | | `historical_results(hunt=None, …)` | `HistoricalHuntResultList.get` | -| `ruleset_list()` | `YaraRuleset.list` | +| `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None, since=None, include_counts=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract | | `tag_list()` | `Tag.list` | | `family_list()` | `MalwareFamily.list` | | `assertions_list(engine_id)` | `AssertionsJob.list` | diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 2b40d018..555754a8 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -147,9 +147,9 @@ ArtifactInstance, LocalArtifact, Hash Engine Metadata, MetadataMapping, MetadataFieldProperties IOC -LiveYaraRuleset, LiveHuntResult, LiveHuntResultList +LiveYaraRuleset, LiveHuntResult, LiveHuntResultList, LiveHuntResultCounts HistoricalHunt, HistoricalHuntResult, HistoricalHuntResultList, HistoricalHuntList -YaraRuleset +YaraRuleset, YaraRulesetFavorite Tag, MalwareFamily, TagLink AssertionsJob, VotesJob SandboxTask, SandboxProvider diff --git a/test/_e2e_helpers.py b/test/_e2e_helpers.py index d150fa75..d4f14ca6 100644 --- a/test/_e2e_helpers.py +++ b/test/_e2e_helpers.py @@ -76,8 +76,8 @@ def uid_yara(uid): The artifact embeds ``uid`` (see ``malicious_artifact``), so a rule keying on that literal matches just this run's submission — isolating a live/historical - hunt from every other test's EICAR artifact (the generic eicar.yara substring - rule would match them all). + hunt from every other test's EICAR artifact (a generic EICAR-substring rule + would match them all). """ ident = re.sub(r'\W', '_', uid) return f'rule sdk_{ident} {{ strings: $u = "{uid}" condition: $u }}' diff --git a/test/async_client_test.py b/test/async_client_test.py index b281bb5c..22531ba3 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -637,14 +637,55 @@ async def test_async_rules(self, uid): fav = await api.ruleset_favorite(rule.id, True) assert fav.favorite is True assert fav.favorited_at is not None + # limit is a PIN (fixed product cap); used is a BOUND (the + # stack budget is shared across runs) assert fav.favorites_limit == 5 assert 1 <= fav.favorites_used <= fav.favorites_limit favorites = [r async for r in api.ruleset_list(favorites_only=True)] assert any(r.id == rule.id and r.favorite for r in favorites) + # unstarring here is the CONTRACT assertion; slot hygiene does + # not depend on reaching it — the finally's ruleset_delete + # soft-deletes and the budget counts only deleted=false rows unfav = await api.ruleset_favorite(rule.id, False) assert unfav.favorite is False assert unfav.favorited_at is None + # live-hunt scope: counts, include_counts and the livescan_id + # feed all need a running hunt; the fresh ruleset matches + # nothing, so every count is a computed ZERO (distinct from + # null = no live hunt to count against) + await api.live_start(int(rule.id)) + try: + livescan_id = (await api.ruleset_get(rule.id)).livescan_id + assert livescan_id is not None # a digit string + active = {r.id async for r in api.ruleset_list(status='active')} + assert rule.id in active + with_counts = None + async for r in api.ruleset_list(include_counts=True): + if r.id == rule.id: + with_counts = r + assert with_counts is not None + assert with_counts.new_results_count == 0 + counts = await api.live_results_count(since=86400) + assert counts.since == 86400 + # zero results -> our hunt is ABSENT (absence means 0) + assert livescan_id not in {entry['livescan_id'] + for entry in counts.counts} + try: + feed = [r async for r in api.live_feed(livescan_id=livescan_id)] + assert feed == [] + except exceptions.NoResultsException: + pass + finally: + # MUST stop before the outer finally's ruleset_delete — a + # running live hunt blocks deletion server-side + await api.live_stop(int(rule.id)) + try: + still_active = {r.id async for r in api.ruleset_list(status='active')} + except exceptions.NoResultsException: + still_active = set() # nothing live anywhere: also a pass + assert rule.id not in still_active + # a hunt triggered FROM the ruleset carries provenance and # bumps the counter; the create response's comparison is # unknown (None) and a read resolves it diff --git a/test/client_scan_test.py b/test/client_scan_test.py index a48cb140..00f4c6e2 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -599,14 +599,50 @@ def test_rules(self): fav = api.ruleset_favorite(rule.id, True) assert fav.favorite is True assert fav.favorited_at is not None + # the limit is a PIN (the fixed product cap, no plan scaling); + # used is a BOUND because the stack budget is shared across runs assert fav.favorites_limit == 5 - # other runs may hold stars on the shared stack — bound, not pin assert 1 <= fav.favorites_used <= fav.favorites_limit favorites = list(api.ruleset_list(favorites_only=True)) assert any(r.id == rule.id and r.favorite for r in favorites) + # unstarring here is the CONTRACT assertion; slot hygiene does not + # depend on reaching it — the finally's ruleset_delete soft-deletes + # and the server's budget counts only deleted=false rows, so a + # failed run's star frees itself with the rule unfav = api.ruleset_favorite(rule.id, False) assert unfav.favorite is False assert unfav.favorited_at is None + # live-hunt scope: the counts endpoint, include_counts and the + # livescan_id feed all need a running hunt. The fresh ruleset + # matches nothing, so every count is a computed ZERO — still + # distinct from null (= no live hunt to count against). + api.live_start(int(rule.id)) + try: + livescan_id = api.ruleset_get(rule.id).livescan_id + assert livescan_id is not None # a digit string + assert rule.id in {r.id for r in api.ruleset_list(status='active')} + with_counts = next(r for r in api.ruleset_list(include_counts=True) + if r.id == rule.id) + assert with_counts.new_results_count == 0 + counts = api.live_results_count(since=86400) + assert counts.since == 86400 + # zero results -> our hunt is ABSENT (absence means 0); the + # keys are the same digit strings ruleset_get renders + assert livescan_id not in {entry['livescan_id'] + for entry in counts.counts} + try: + assert list(api.live_feed(livescan_id=livescan_id)) == [] + except exceptions.NoResultsException: + pass + finally: + # MUST stop before the outer finally's ruleset_delete — a + # running live hunt blocks deletion server-side + api.live_stop(int(rule.id)) + try: + still_active = {r.id for r in api.ruleset_list(status='active')} + except exceptions.NoResultsException: + still_active = set() # nothing live anywhere: also a pass + assert rule.id not in still_active # a historical hunt triggered FROM the ruleset carries the # provenance and bumps the ruleset's counter; the create response's # source_rule_changed is None (unknown until a read re-resolves it) diff --git a/test/eicar.yara b/test/eicar.yara deleted file mode 100644 index 0c32b59f..00000000 --- a/test/eicar.yara +++ /dev/null @@ -1,34 +0,0 @@ -rule eicar_av_test { - /* - Per standard, match only if entire file is EICAR string plus optional trailing whitespace. - The raw EICAR string to be matched is: - X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H* - */ - - meta: - description = "This is a standard AV test, intended to verify that BinaryAlert is working correctly." - author = "Austin Byers | Airbnb CSIRT" - reference = "http://www.eicar.org/86-0-Intended-use.html" - - strings: - $eicar_regex = /^X5O!P%@AP\[4\\PZX54\(P\^\)7CC\)7\}\$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!\$H\+H\*\s*$/ - - condition: - all of them -} - -rule eicar_substring_test { - /* - More generic - match just the embedded EICAR string (e.g. in packed executables, PDFs, etc) - */ - - meta: - description = "Standard AV test, checking for an EICAR substring" - author = "Austin Byers | Airbnb CSIRT" - - strings: - $eicar_substring = "$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!" - - condition: - all of them -} \ No newline at end of file diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py new file mode 100644 index 00000000..464d6b7a --- /dev/null +++ b/test/hunt_tracking_builder_test.py @@ -0,0 +1,99 @@ +"""Pure-unit request-shape tests for the hunt-page tracking builders. + +No HTTP at all (the pure-unit tier — see specs/04-testing.md): these pin the +request *construction* for the new surfaces — and specifically the two shapes +that are entirely consequences of ``core._params`` plumbing rather than +anything visible at the call site: + +* ``YaraRulesetFavorite`` empties ``RESOURCE_ID_KEYS``, which is the ONLY + thing routing ``id`` (and ``favorite``/``community``) into the PUT's JSON + body instead of the query string — the server reads the toggle exclusively + from the body; and +* booleans serialise as ``1``/``0`` ints, not JSON ``true``/``false`` + (``core._params`` coerces before body/query routing) — the server's + boolean parser accepts exactly that, so the int-vs-bool body contract is + load-bearing. + +Endpoint *behaviour* is covered by the live-e2e VCR lifecycle tests +(``test_rules`` / ``test_async_rules``). +""" +from polyswarm_api import resources + + +class _FakeApi: + uri = 'https://api.example.test' + community = 'gamma' + + +class TestYaraRulesetFavoriteBuilder: + def test_update_routes_everything_to_the_put_body(self): + api = _FakeApi() + req = resources.YaraRulesetFavorite.update( + api, id=5, favorite=True, community=api.community) + assert req.method == 'PUT' + assert req.url == f'{api.uri}/hunt/rule/favorite' + # RESOURCE_ID_KEYS = [] is load-bearing: with the base ['id'] the id + # would ride the query string on a PUT, and the server only reads the + # body. favorite serialises as int 1, not JSON true. + assert req.params is None + assert req.input_json == {'id': '5', 'favorite': 1, 'community': 'gamma'} + assert req.result_parser is resources.YaraRulesetFavorite + + def test_unfavorite_serialises_false_as_zero(self): + req = resources.YaraRulesetFavorite.update( + _FakeApi(), id=5, favorite=False, community='gamma') + assert req.input_json['favorite'] == 0 + + +class TestLiveHuntResultCountsBuilder: + def test_get_routes_since_and_community_to_the_query(self): + api = _FakeApi() + req = resources.LiveHuntResultCounts.get( + api, since=86400, community=api.community) + assert req.method == 'GET' + assert req.url == f'{api.uri}/hunt/live/results/count' + assert req.params == {'since': 86400, 'community': 'gamma'} + assert req.input_json is None + assert req.result_parser is resources.LiveHuntResultCounts + + def test_get_omits_unset_since(self): + # None is dropped, so the server applies its own default window. + req = resources.LiveHuntResultCounts.get( + _FakeApi(), since=None, community='gamma') + assert req.params == {'community': 'gamma'} + + +class TestRulesetListFilterBuilder: + def test_list_routes_filters_to_the_query_with_int_bools(self): + api = _FakeApi() + req = resources.YaraRuleset.list( + api, name='alpha', status='active', favorites_only=True, + has_new_results=True, since=86400, include_counts=True, + community=api.community) + assert req.method == 'GET' + assert req.url == f'{api.uri}/hunt/rule/list' + assert req.params == { + 'name': 'alpha', 'status': 'active', 'favorites_only': 1, + 'has_new_results': 1, 'since': 86400, 'include_counts': 1, + 'community': 'gamma'} + + def test_list_omits_every_unset_filter(self): + # The no-filter request is byte-compatible with the pre-filter + # contract: nothing but community rides the query string. + req = resources.YaraRuleset.list( + _FakeApi(), name=None, status=None, favorites_only=None, + has_new_results=None, since=None, include_counts=None, + community='gamma') + assert req.params == {'community': 'gamma'} + + +class TestLiveFeedScopeBuilder: + def test_list_routes_livescan_id_to_the_query_as_digit_string(self): + # *_id kwargs stringify (core._params); the server casts back to int. + req = resources.LiveHuntResult.list( + _FakeApi(), since=60, livescan_id=45392847561029383, + rule_name=None, family=None, polyscore_lower=None, + polyscore_upper=None, community='gamma') + assert req.url == 'https://api.example.test/hunt/live/list' + assert req.params == {'since': 60, 'livescan_id': '45392847561029383', + 'community': 'gamma'} diff --git a/test/vcr/test_async_rules.vcr b/test/vcr/test_async_rules.vcr index 0c27690a..1b4cb8d6 100644 --- a/test/vcr/test_async_rules.vcr +++ b/test/vcr/test_async_rules.vcr @@ -23,7 +23,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule response: body: - string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -35,11 +35,11 @@ interactions: connection: - keep-alive content-length: - - '413' + - '412' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:21 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -66,7 +66,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -77,11 +77,11 @@ interactions: connection: - keep-alive content-length: - - '392' + - '391' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:21 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -108,7 +108,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?name=test_async_rules&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -119,11 +119,11 @@ interactions: connection: - keep-alive content-length: - - '392' + - '391' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -147,10 +147,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=69323308443642315&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=4466967201833338&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -162,11 +162,11 @@ interactions: connection: - keep-alive content-length: - - '413' + - '412' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -175,7 +175,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"69323308443642315","favorite":1,"community":"gamma"}' + body: '{"id":"4466967201833338","favorite":1,"community":"gamma"}' headers: accept: - '*/*' @@ -186,7 +186,7 @@ interactions: connection: - keep-alive content-length: - - '59' + - '58' content-type: - application/json host: @@ -197,7 +197,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/favorite response: body: - string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T13:59:22.129436+00:00","favorites_limit":5,"favorites_used":1,"id":"69323308443642315"},"status":"OK"} + string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T14:29:52.846750+00:00","favorites_limit":5,"favorites_used":1,"id":"4466967201833338"},"status":"OK"} ' headers: @@ -208,11 +208,11 @@ interactions: connection: - keep-alive content-length: - - '157' + - '156' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -239,7 +239,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?favorites_only=1&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T13:59:22.129436+00:00","historical_hunt_count":0,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T14:29:52.846750+00:00","historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -250,11 +250,11 @@ interactions: connection: - keep-alive content-length: - - '421' + - '420' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -263,7 +263,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"69323308443642315","favorite":0,"community":"gamma"}' + body: '{"id":"4466967201833338","favorite":0,"community":"gamma"}' headers: accept: - '*/*' @@ -274,7 +274,7 @@ interactions: connection: - keep-alive content-length: - - '59' + - '58' content-type: - application/json host: @@ -285,7 +285,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/favorite response: body: - string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"69323308443642315"},"status":"OK"} + string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"4466967201833338"},"status":"OK"} ' headers: @@ -296,11 +296,11 @@ interactions: connection: - keep-alive content-length: - - '128' + - '127' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:52 GMT server: - gunicorn x-billing-id: @@ -309,7 +309,7 @@ interactions: code: 200 message: OK - request: - body: '{"rule_id":"69323308443642315","community":"gamma"}' + body: '{"rule_id":"4466967201833338"}' headers: accept: - '*/*' @@ -320,7 +320,342 @@ interactions: connection: - keep-alive content-length: - - '51' + - '30' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: POST + uri: http://ai:9696/v3/hunt/rule/live + response: + body: + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '457' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule?id=4466967201833338&community=gamma + response: + body: + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '457' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '436' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?include_counts=1&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","new_results_count":0,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '433' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/live/results/count?since=86400&community=gamma + response: + body: + string: '{"result":{"counts":[],"since":86400},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '53' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/live/list?livescan_id=34849444833418665&community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +- request: + body: '{"rule_id":"4466967201833338"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '30' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: DELETE + uri: http://ai:9696/v3/hunt/rule/live + response: + body: + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:53.570180+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '412' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Fri, 21 Aug 2026 14:29:53 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +- request: + body: '{"rule_id":"4466967201833338","community":"gamma"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '50' content-type: - application/json host: @@ -331,7 +666,7 @@ interactions: uri: http://ai:9696/v3/hunt/historical response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -343,11 +678,11 @@ interactions: connection: - keep-alive content-length: - - '578' + - '577' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:53 GMT server: - gunicorn x-billing-id: @@ -371,10 +706,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=69323308443642315&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=4466967201833338&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:21.835873+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:53.570180+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -386,11 +721,11 @@ interactions: connection: - keep-alive content-length: - - '413' + - '412' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:53 GMT server: - gunicorn x-billing-id: @@ -414,10 +749,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=95693942031500728&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=41876045317487902&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -429,11 +764,11 @@ interactions: connection: - keep-alive content-length: - - '579' + - '578' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:53 GMT server: - gunicorn x-billing-id: @@ -462,10 +797,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule?id=69323308443642315 + uri: http://ai:9696/v3/hunt/rule?id=4466967201833338 response: body: - string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:22.863472+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:54.082225+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }\n// edited"},"status":"OK"} @@ -478,11 +813,11 @@ interactions: connection: - keep-alive content-length: - - '427' + - '426' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:54 GMT server: - gunicorn x-billing-id: @@ -506,10 +841,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=95693942031500728&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=41876045317487902&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -521,11 +856,11 @@ interactions: connection: - keep-alive content-length: - - '578' + - '577' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:22 GMT + - Fri, 21 Aug 2026 14:29:54 GMT server: - gunicorn x-billing-id: @@ -553,10 +888,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/historical?id=95693942031500728 + uri: http://ai:9696/v3/hunt/historical?id=41876045317487902 response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:22.516466+00:00","failed_max_retries":0,"failed_other":0,"id":"95693942031500728","progress":null,"results_csv_uri":null,"rule_id":"69323308443642315","rule_modified":"2026-08-21T13:59:21.835873+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -568,11 +903,11 @@ interactions: connection: - keep-alive content-length: - - '579' + - '578' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:23 GMT + - Fri, 21 Aug 2026 14:29:54 GMT server: - gunicorn x-billing-id: @@ -600,10 +935,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/rule?id=69323308443642315 + uri: http://ai:9696/v3/hunt/rule?id=4466967201833338 response: body: - string: '{"result":{"created":"2026-08-21T13:59:21.835873+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"69323308443642315","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:23.191803+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:54.434684+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }\n// edited"},"status":"OK"} @@ -616,11 +951,11 @@ interactions: connection: - keep-alive content-length: - - '426' + - '425' content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:23 GMT + - Fri, 21 Aug 2026 14:29:54 GMT server: - gunicorn x-billing-id: @@ -658,7 +993,7 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 13:59:23 GMT + - Fri, 21 Aug 2026 14:29:54 GMT server: - gunicorn status: diff --git a/test/vcr/test_rules.vcr b/test/vcr/test_rules.vcr index eb759388..9c9b6dc2 100644 --- a/test/vcr/test_rules.vcr +++ b/test/vcr/test_rules.vcr @@ -23,7 +23,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule response: body: - string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -39,7 +39,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:17 GMT + - Fri, 21 Aug 2026 14:29:48 GMT server: - gunicorn x-billing-id: @@ -66,7 +66,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -81,7 +81,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:18 GMT + - Fri, 21 Aug 2026 14:29:48 GMT server: - gunicorn x-billing-id: @@ -108,7 +108,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?name=test_rules&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -123,7 +123,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:18 GMT + - Fri, 21 Aug 2026 14:29:48 GMT server: - gunicorn x-billing-id: @@ -147,10 +147,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=14693852690318397&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=71359438369584055&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -166,7 +166,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:18 GMT + - Fri, 21 Aug 2026 14:29:48 GMT server: - gunicorn x-billing-id: @@ -175,7 +175,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"14693852690318397","favorite":1,"community":"gamma"}' + body: '{"id":"71359438369584055","favorite":1,"community":"gamma"}' headers: accept: - '*/*' @@ -197,7 +197,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/favorite response: body: - string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T13:59:18.816554+00:00","favorites_limit":5,"favorites_used":1,"id":"14693852690318397"},"status":"OK"} + string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T14:29:49.029459+00:00","favorites_limit":5,"favorites_used":1,"id":"71359438369584055"},"status":"OK"} ' headers: @@ -212,7 +212,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:18 GMT + - Fri, 21 Aug 2026 14:29:49 GMT server: - gunicorn x-billing-id: @@ -239,7 +239,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?favorites_only=1&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T13:59:18.816554+00:00","historical_hunt_count":0,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T14:29:49.029459+00:00","historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -254,7 +254,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:18 GMT + - Fri, 21 Aug 2026 14:29:49 GMT server: - gunicorn x-billing-id: @@ -263,7 +263,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"14693852690318397","favorite":0,"community":"gamma"}' + body: '{"id":"71359438369584055","favorite":0,"community":"gamma"}' headers: accept: - '*/*' @@ -285,7 +285,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/favorite response: body: - string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"14693852690318397"},"status":"OK"} + string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"71359438369584055"},"status":"OK"} ' headers: @@ -300,7 +300,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:18 GMT + - Fri, 21 Aug 2026 14:29:49 GMT server: - gunicorn x-billing-id: @@ -309,7 +309,342 @@ interactions: code: 200 message: OK - request: - body: '{"rule_id":"14693852690318397","community":"gamma"}' + body: '{"rule_id":"71359438369584055"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '31' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: POST + uri: http://ai:9696/v3/hunt/rule/live + response: + body: + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '440' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule?id=71359438369584055&community=gamma + response: + body: + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '440' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '431' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?include_counts=1&community=gamma + response: + body: + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","new_results_count":0,"rule_count":1,"yara":null}],"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '428' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/live/results/count?since=86400&community=gamma + response: + body: + string: '{"result":{"counts":[],"since":86400},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '53' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/live/list?livescan_id=11956831134597871&community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +- request: + body: '{"rule_id":"71359438369584055"}' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + content-length: + - '31' + content-type: + - application/json + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: DELETE + uri: http://ai:9696/v3/hunt/rule/live + response: + body: + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:49.650762+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} + + ' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-length: + - '395' + content-type: + - application/json + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + x-billing-id: + - '111' + status: + code: 200 + message: OK +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Fri, 21 Aug 2026 14:29:49 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +- request: + body: '{"rule_id":"71359438369584055","community":"gamma"}' headers: accept: - '*/*' @@ -331,7 +666,7 @@ interactions: uri: http://ai:9696/v3/hunt/historical response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -347,7 +682,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -371,10 +706,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=14693852690318397&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=71359438369584055&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:17.871893+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:49.650762+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -390,7 +725,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -414,10 +749,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=21276230498013503&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=90800113038824882&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -433,7 +768,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -457,10 +792,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=21276230498013503&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=90800113038824882&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -476,7 +811,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -505,10 +840,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule?id=14693852690318397 + uri: http://ai:9696/v3/hunt/rule?id=71359438369584055 response: body: - string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:19.602433+00:00","name":"test_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:50.635991+00:00","name":"test_rules2","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }\n// edited"},"status":"OK"} ' @@ -524,7 +859,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -548,10 +883,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=21276230498013503&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=90800113038824882&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -567,7 +902,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -595,10 +930,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/historical?id=21276230498013503 + uri: http://ai:9696/v3/hunt/historical?id=90800113038824882 response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T13:59:19.202596+00:00","failed_max_retries":0,"failed_other":0,"id":"21276230498013503","progress":null,"results_csv_uri":null,"rule_id":"14693852690318397","rule_modified":"2026-08-21T13:59:17.871893+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -614,7 +949,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:19 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -642,10 +977,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/rule?id=14693852690318397 + uri: http://ai:9696/v3/hunt/rule?id=71359438369584055 response: body: - string: '{"result":{"created":"2026-08-21T13:59:17.871893+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"14693852690318397","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T13:59:20.153029+00:00","name":"test_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:50.839329+00:00","name":"test_rules2","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }\n// edited"},"status":"OK"} ' @@ -661,7 +996,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 13:59:20 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn x-billing-id: @@ -699,7 +1034,7 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 13:59:20 GMT + - Fri, 21 Aug 2026 14:29:50 GMT server: - gunicorn status: From b80f8256dd418279d57f9c90592e8f037f0fc4e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Fri, 21 Aug 2026 10:42:33 -0400 Subject: [PATCH 09/36] docs+test: classification fix, parse pins, honest scoping notes (review 2) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit All five follow-ups: - live_results_count moved to the _single Live-hunts table in specs/03 — it returns one resource, and _single-vs-_paginate is that document's organizing invariant. - specs/04's fixture inventory drops the retired test/eicar.yara and names the new pure-unit module. - Parse-side pins for the counts resource: the cassettes only carry EMPTY counts (fresh zero-result hunt), so the {livescan_id, count} entry shape, the digit-string join key and the null-counts coalesce now have canned-payload tests. - The livescan_id feed assertions no longer read as if they verify the scoping: with a zero-result hunt they pin the wire shape and the empty pass-through only, and the comments now say so (the scoping semantics are pinned by the server's own HTTP suite). - FAVORITE_LIMIT's machine-readable contract is now documented (specs/05: no typed exception by design; the path is exc.request.errors with the code plus the same counters a successful toggle returns) and pinned by a respx refusal test — mocked because a genuinely full budget on the shared stack would race every other run. --- specs/03-endpoints.md | 2 +- specs/04-testing.md | 3 ++- specs/05-downstream-contract.md | 2 ++ test/async_client_test.py | 4 ++++ test/client_scan_test.py | 30 ++++++++++++++++++++++++++++++ test/hunt_tracking_builder_test.py | 24 ++++++++++++++++++++++++ 6 files changed, 63 insertions(+), 2 deletions(-) diff --git a/specs/03-endpoints.md b/specs/03-endpoints.md index b33e2bbe..7f1e2e93 100644 --- a/specs/03-endpoints.md +++ b/specs/03-endpoints.md @@ -66,6 +66,7 @@ Internal-only CRUD for the `/known-good` binary resource (distinct from the IOC | `live_stop(rule_id)` | `LiveYaraRuleset.delete` | | `live_feed_delete(result_ids)` | `LiveHuntResultList.delete` (catches `NoResultsException`) | | `live_result(result_id)` | `LiveHuntResult.get` | +| `live_results_count(since=None)` | `LiveHuntResultCounts.get` — per-live-hunt result counts in a window, grouped by `livescan_id` (digit strings, the same join key `YaraRuleset.livescan_id` carries); a hunt absent from `counts` collected 0 | ### Historical hunts @@ -188,7 +189,6 @@ refusal. | `search_by_ioc(ip=None, domain=None, ttp=None, imphash=None)` | `IOC.ioc_search` | | `check_known_hosts(ips=[], domains=[])` | `IOC.check_known_hosts` | | `live_feed(since=None, …, livescan_id=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed) | -| `live_results_count(since=None)` | `LiveHuntResultCounts.get` — per-live-hunt result counts in a window, grouped by `livescan_id` (digit strings, the same join key `YaraRuleset.livescan_id` carries); a hunt absent from `counts` collected 0 | | `historical_list(since=None)` | `HistoricalHunt.list` | | `historical_results(hunt=None, …)` | `HistoricalHuntResultList.get` | | `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None, since=None, include_counts=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract | diff --git a/specs/04-testing.md b/specs/04-testing.md index b81e5855..bb60d552 100644 --- a/specs/04-testing.md +++ b/specs/04-testing.md @@ -26,7 +26,8 @@ How the test suite is organised. Three layers: pure unit tests (no HTTP at all - `test/async_client_test.py` — async, VCR-backed integration tests (not yet on the parametrised harness — follow-up work). - `test/jmespath_test.py` — unit tests for `BaseJsonResource.jmespath`. - `test/vcr/*.vcr` — recorded cassettes. -- `test/eicar.yara`, `test/malicious` — fixture files for upload tests. +- `test/malicious` — fixture file for upload tests (`test/eicar.yara` was retired when the rules tests moved to per-test `uid_yara` bodies). +- `test/hunt_tracking_builder_test.py` — pure-unit request-shape and parse tests for the hunt-page tracking builders/resources. ## Three test layers diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 555754a8..eb476820 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -180,6 +180,8 @@ class TimeoutException(PolyswarmException): ... `KnownGoodWithheldException` is the 404 raised when a download is refused because the artifact is a known-good binary — the platform never stores or serves those bytes. It **subclasses `NotFoundException`** precisely so invariant 3 holds for existing consumers: code that already does `except NotFoundException:` keeps catching the refusal with no change, and only callers that want to distinguish "withheld by design" from a plain miss catch the subclass. It adds one attribute, `.sources` — the known-good feeds that flagged the hash (e.g. `['nsrl']`), `[]` when the server named none. The contract is only this: **always a list of strings**, whatever the envelope carried, so `for feed in exc.sources` needs no shape check. Which wire shapes are coerced, and which are dropped and logged, is `exceptions._normalise_sources`' business rather than a promise to consumers — the server sends a list of strings today. Note it is **not** normalised the same way as `ArtifactInstance.known_good_sources`, which is the same concept reached from the instance response: that one is sorted and de-duplicated, while `.sources` preserves the order the envelope carried and can repeat a feed. Don't assume parity between the two. The raw envelope stays reachable at `exc.request.errors` (`{'code': 'KNOWN_GOOD', 'known_good': True, 'sources': [...]}`). The artifact's metadata — the flagging feeds plus any scan data already collected — remains readable through the search / instance endpoints; only the bytes are withheld, and the instance's `KNOWN_GOOD` state/status is the signal for the typed refusal (there is no separate "withheld" field; a `NOT_STORED` instance has no bytes either, but 404s plainly — see below). +`FAVORITE_LIMIT` (a refused ruleset star: the team's favorite budget is spent) has **no typed exception** — deliberately, since no pre-existing consumer needs re-routing the way `NotFoundException` did. It surfaces as the generic 400 `RequestException`, and the machine-readable path is the raw envelope: `exc.request.errors == {'code': 'FAVORITE_LIMIT', 'favorites_used': N, 'favorites_limit': M}`. The counters are the same pair a successful toggle returns, so a caller can render the "budget full" state from either outcome. Pinned by the respx refusal test in `client_scan_test.py`. + **What "known-good" means on the server, as of artifact-index's two-predicate model** (its `specs/05`): the refusal fires on the server's *current understanding* — a catalogue entry exists for the sha256 **and** that entry's extension passes an executable allow-list — evaluated live on every request. Two consequences worth knowing as a consumer: the same download can start working again with no action on your part (the entry is deleted, or the policy narrows), and `ArtifactInstance.state` can report the new value **`NOT_STORED`** — a submission the server declined as known-good at the time whose hash is no longer currently known-good, so nothing was ever stored for it and a fresh submit of the same file works. `state` is a plain string here; the SDK does not enumerate it, so a new member needs no SDK release. Each `RequestException` subclass carries a `.request` attribute holding the originating `PolyswarmRequest` (set by `RequestException.__init__`). Callers can read `exc.request.status_code`, `exc.request.json` (the parsed response body after execution), `exc.request.input_json` (the body that was sent), `exc.request.request_parameters` (the request kwargs that built the call), etc. `InvalidValueException` and `TimeoutException` are client-side errors and don't carry a request descriptor. diff --git a/test/async_client_test.py b/test/async_client_test.py index 22531ba3..a7e82507 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -671,6 +671,10 @@ async def test_async_rules(self, uid): # zero results -> our hunt is ABSENT (absence means 0) assert livescan_id not in {entry['livescan_id'] for entry in counts.counts} + # NOTE: zero-result hunt — pins the wire shape and the + # empty pass-through only; the scoping semantics are + # pinned by the server's own HTTP suite (same for + # has_new_results) try: feed = [r async for r in api.live_feed(livescan_id=livescan_id)] assert feed == [] diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 00f4c6e2..fb9a2366 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -357,6 +357,31 @@ def test_metadata_search(self): lambda: api.search_by_metadata(f'artifact.sha256:{sha}'), tries=90) assert result and result[0].sha256 == sha + def test_favorite_limit_refusal_is_machine_readable(self): + # The FAVORITE_LIMIT refusal path (respx-mocked: producing a genuinely + # full budget on the SHARED e2e stack would require holding all five + # team slots, racing every other run). There is deliberately no typed + # exception (specs/05): the machine-readable contract is the raw + # envelope at exc.request.errors — the code plus the same counters a + # successful toggle returns. + with respx.mock(assert_all_called=True) as router: + envelope = { + 'status': 'error', + 'result': 'Favorite limit reached (5 of 5 used).', + 'errors': {'code': 'FAVORITE_LIMIT', + 'favorites_used': 5, 'favorites_limit': 5}, + } + router.put('http://localhost:3000/api/v1/hunt/rule/favorite').mock( + return_value=httpx.Response(400, json=envelope)) + api = PolyswarmAPI(self.test_api_key, uri='http://localhost:3000/api/v1', + community='gamma') + with pytest.raises(exceptions.RequestException) as excinfo: + api.ruleset_favorite(5, True) + errors = excinfo.value.request.errors + assert errors['code'] == 'FAVORITE_LIMIT' + assert errors['favorites_used'] == 5 + assert errors['favorites_limit'] == 5 + def test_resolve_engine_name(self): with respx.mock(assert_all_called=False) as router: ok_payload = {'results': [ @@ -630,6 +655,11 @@ def test_rules(self): # keys are the same digit strings ruleset_get renders assert livescan_id not in {entry['livescan_id'] for entry in counts.counts} + # NOTE: with a zero-result hunt this pins only the wire shape + # and the empty pass-through — it cannot tell a working filter + # from an ignored param (that would need a second hunt WITH + # results). The scoping semantics themselves are pinned by the + # server's own HTTP suite; same for has_new_results. try: assert list(api.live_feed(livescan_id=livescan_id)) == [] except exceptions.NoResultsException: diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index 464d6b7a..653a88dc 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -97,3 +97,27 @@ def test_list_routes_livescan_id_to_the_query_as_digit_string(self): assert req.url == 'https://api.example.test/hunt/live/list' assert req.params == {'since': 60, 'livescan_id': '45392847561029383', 'community': 'gamma'} + + +class TestLiveHuntResultCountsParse: + """Parse-side pins for the counts resource — the recorded cassettes carry + only EMPTY counts (the live tests use a fresh zero-result hunt), so the + entry shape and the digit-string join key documented in three places are + otherwise asserted nowhere.""" + + def test_counts_entries_parse_with_digit_string_join_keys(self): + payload = {'since': 86400, + 'counts': [{'livescan_id': '45392847561029383', 'count': 3}, + {'livescan_id': '71359438369584055', 'count': 1}]} + counts = resources.LiveHuntResultCounts(payload, api=None) + assert counts.since == 86400 + assert counts.counts == payload['counts'] + # the join key is the same digit string YaraRuleset.livescan_id + # carries — a bare int would round in a JS consumer + assert all(isinstance(entry['livescan_id'], str) for entry in counts.counts) + by_id = {entry['livescan_id']: entry['count'] for entry in counts.counts} + assert by_id['45392847561029383'] == 3 + + def test_null_counts_coalesces_to_an_empty_list(self): + counts = resources.LiveHuntResultCounts({'since': 86400, 'counts': None}, api=None) + assert counts.counts == [] From cc9ed02f763d79a3352cd8986f44295336c670b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Fri, 21 Aug 2026 10:44:22 -0400 Subject: [PATCH 10/36] =?UTF-8?q?ci:=20retry=20=E2=80=94=20runner=20failed?= =?UTF-8?q?=20at=20git=20fetch=20(transient=20403),=20commit=20never=20che?= =?UTF-8?q?cked=20out?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From 4738e1e9ca109e7f6c9b431c236bce8310728c59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Fri, 21 Aug 2026 10:56:23 -0400 Subject: [PATCH 11/36] ci: retry after GitLab runner fetch 403s (infrastructure, both attempts died at get_sources) From a896210926d349ff18460f5965255e501da1c307 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Mon, 24 Aug 2026 12:46:22 -0400 Subject: [PATCH 12/36] ci: retry after the runner-fetch 403 window cleared From e5dbe0305813c0ea904133e5496be95e96c9307e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Tue, 25 Aug 2026 18:49:06 -0400 Subject: [PATCH 13/36] test: re-record the rules lifecycle cassettes against the stored-counter server --- specs/02-resources.md | 6 +- specs/03-endpoints.md | 7 +- specs/04-testing.md | 3 +- specs/05-downstream-contract.md | 17 +++- src/polyswarm_api/aio/api.py | 35 +++---- src/polyswarm_api/api.py | 43 +++------ src/polyswarm_api/resources.py | 36 +++----- test/_e2e_helpers.py | 15 ++- test/async_client_test.py | 113 +++++++++++++++-------- test/client_scan_test.py | 138 ++++++++++++++-------------- test/conftest.py | 1 + test/hunt_tracking_builder_test.py | 121 ++++++++++++------------ test/ruleset_favorite_respx_test.py | 59 ++++++++++++ 13 files changed, 339 insertions(+), 255 deletions(-) create mode 100644 test/ruleset_favorite_respx_test.py diff --git a/specs/02-resources.md b/specs/02-resources.md index fb626629..c812f878 100644 --- a/specs/02-resources.md +++ b/specs/02-resources.md @@ -36,7 +36,6 @@ BaseResource # holds .api, ._content, .parse_result cla ├── HistoricalHunt # /hunt/historical ├── HistoricalHuntResult / List # /hunt/historical/results (+ /results/list) ├── LiveHuntResult / List # /hunt/live (+ /hunt/live/list) - ├── LiveHuntResultCounts # /hunt/live/results/count ├── YaraRuleset # /hunt/rule ├── YaraRulesetFavorite # /hunt/rule/favorite ├── Tag, MalwareFamily, TagLink # /tags/tag, /tags/family, /tags/link @@ -345,9 +344,8 @@ Holds `handle`, `artifact_name`, `artifact_type`, `sha256`, `sha1`, `md5`. Also Several resources add domain-specific classmethods on top of the standard CRUD set: - `IOC` — `iocs_by_hash`, `ioc_search`, `check_known_hosts`, `create_known_good`, `create_known_bad`, `update_known_good`, `delete_known_good`. -- `LiveYaraRuleset` / `HistoricalHunt` / `YaraRuleset` — standard CRUD plus list/delete-batch variants. `YaraRuleset` also parses the hunt-page tracking fields (`favorite`, `favorited_at`, `rule_count` — `None` means the server had no answer, distinct from 0 — `historical_hunt_count`, `new_results_count`), and `HistoricalHunt` the source-rule provenance (`rule_id`, `rule_modified`, and the tri-state `source_rule_changed` — `None` is "unknown", never "unchanged"). All additive `.get()` parses; an older server leaves them `None`. -- `YaraRulesetFavorite` — `RESOURCE_ENDPOINT = '/hunt/rule/favorite'`, **`RESOURCE_ID_KEYS = []`**: a deliberate deviation from the default `['id']`, because the server reads the toggle exclusively from the PUT **body** — emptying the key list is the only thing routing `id` (plus `favorite`/`community`) into `json` instead of the query string. `favorite` serialises as `1`/`0` (the `_params` bool→int coercion), which the server's boolean parser accepts. Response carries the star state plus the team's `favorites_used`/`favorites_limit`. Pinned by `test/hunt_tracking_builder_test.py`. -- `LiveHuntResultCounts` — `RESOURCE_ENDPOINT = '/hunt/live/results/count'`, GET-only; `since` (seconds) rides the query and is omitted when unset (server default window). `counts` is a list of `{livescan_id, count}` with `livescan_id` as a digit string — the same join key `YaraRuleset.livescan_id` carries; a hunt absent from `counts` collected 0. +- `LiveYaraRuleset` / `HistoricalHunt` / `YaraRuleset` — standard CRUD plus list/delete-batch variants. `YaraRuleset` also parses the hunt-page tracking fields (`favorite`, `favorited_at`, `rule_count` — `None` means the server had no answer, distinct from 0 — `historical_hunt_count`, and the stored `new_results_count` with its staleness marker `new_results_counted_at`: the server refreshes the counter on a schedule and the marker says when, so `None` means "not yet refreshed / no live hunt", never 0), and `HistoricalHunt` the source-rule provenance (`rule_id`, `rule_modified`, and the tri-state `source_rule_changed` — `None` is "unknown", never "unchanged"). All additive `.get()` parses; an older server leaves them `None`. +- `YaraRulesetFavorite` — `RESOURCE_ENDPOINT = '/hunt/rule/favorite'`, **`RESOURCE_ID_KEYS = ['community']`**: a deliberate deviation from the default `['id']`, splitting the request the way the server reads it — the toggle reads BOTH `id` and `favorite` from the PUT **body** (the default would move `id` into the query string and the server would 400 with "A valid rule id must be provided"), while `community` rides the **query string** to match where the ruleset GET/list calls send it. (The server's community middleware accepts the value from either the query or the body — but never both at once — so the placement here is about consistency and the id-400, not about a silently-ignored body value.) `favorite` serialises as `1`/`0` (the `_params` bool→int coercion), which the server's boolean parser accepts. Response carries the star state plus the team's `favorites_used`/`favorites_limit`. Pinned by `test/hunt_tracking_builder_test.py` and both transports of `test/ruleset_favorite_respx_test.py`. - `SandboxTask` — `create_file`, `update_file`, `latest`, `my_tasks` for the various sandbox-submission shapes. **No `upload_file` instance method** in 4.0. - `Sample` — `create` with `endpoint_fmt={'sha256': sha256}` for the URL-parametrised path. - `Webhook` — `test(api, webhook_id)` for the test-payload endpoint. diff --git a/specs/03-endpoints.md b/specs/03-endpoints.md index 7f1e2e93..ec4837d7 100644 --- a/specs/03-endpoints.md +++ b/specs/03-endpoints.md @@ -66,7 +66,6 @@ Internal-only CRUD for the `/known-good` binary resource (distinct from the IOC | `live_stop(rule_id)` | `LiveYaraRuleset.delete` | | `live_feed_delete(result_ids)` | `LiveHuntResultList.delete` (catches `NoResultsException`) | | `live_result(result_id)` | `LiveHuntResult.get` | -| `live_results_count(since=None)` | `LiveHuntResultCounts.get` — per-live-hunt result counts in a window, grouped by `livescan_id` (digit strings, the same join key `YaraRuleset.livescan_id` carries); a hunt absent from `counts` collected 0 | ### Historical hunts @@ -87,7 +86,7 @@ Internal-only CRUD for the `/known-good` binary resource (distinct from the IOC | `ruleset_create(name, rules, description=None)` | `YaraRuleset.create` | | `ruleset_get(ruleset_id=None)` | `YaraRuleset.get` | | `ruleset_update(ruleset_id, name=None, rules=None, description=None)` | `YaraRuleset.update` | -| `ruleset_favorite(ruleset_id, favorite=True)` | `YaraRulesetFavorite.update` — idempotent star/unstar; the response carries the team's `favorites_used`/`favorites_limit`, and an over-budget star is refused with a machine-readable `FAVORITE_LIMIT` error. The id rides the PUT **body**, not the query (see the `RESOURCE_ID_KEYS = []` note in specs/02) | +| `ruleset_favorite(ruleset_id, favorite=True)` | `YaraRulesetFavorite.update` — idempotent star/unstar; the response carries the team's `favorites_used`/`favorites_limit`, and an over-budget star is refused with a machine-readable `FAVORITE_LIMIT` error. The id and favorite ride the PUT **body**; `community` rides the query (see the `RESOURCE_ID_KEYS = ['community']` note in specs/02) | | `ruleset_delete(ruleset_id)` | `YaraRuleset.delete` | | `tag_link_get(sha256)` | `TagLink.get` | | `tag_link_update(sha256, tags=None, families=None, emerging=None, remove=False)` | `TagLink.update` | @@ -188,10 +187,10 @@ refusal. | `iocs_by_hash(hash_type, hash_value, hide_known_good=False, beta=False)` | `IOC.iocs_by_hash` | | `search_by_ioc(ip=None, domain=None, ttp=None, imphash=None)` | `IOC.ioc_search` | | `check_known_hosts(ips=[], domains=[])` | `IOC.check_known_hosts` | -| `live_feed(since=None, …, livescan_id=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed) | +| `live_feed(since=None, …, livescan_id=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in SECONDS (the server converts with `timedelta(seconds=since)`) | | `historical_list(since=None)` | `HistoricalHunt.list` | | `historical_results(hunt=None, …)` | `HistoricalHuntResultList.get` | -| `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None, since=None, include_counts=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract | +| `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract. `has_new_results` selects on the server's STORED counter (no window parameter — the window belongs to the server's scheduled refresh; rows carry `new_results_count` + `new_results_counted_at`) | | `tag_list()` | `Tag.list` | | `family_list()` | `MalwareFamily.list` | | `assertions_list(engine_id)` | `AssertionsJob.list` | diff --git a/specs/04-testing.md b/specs/04-testing.md index bb60d552..3596dc60 100644 --- a/specs/04-testing.md +++ b/specs/04-testing.md @@ -28,6 +28,7 @@ How the test suite is organised. Three layers: pure unit tests (no HTTP at all - `test/vcr/*.vcr` — recorded cassettes. - `test/malicious` — fixture file for upload tests (`test/eicar.yara` was retired when the rules tests moved to per-test `uid_yara` bodies). - `test/hunt_tracking_builder_test.py` — pure-unit request-shape and parse tests for the hunt-page tracking builders/resources. +- `test/ruleset_favorite_respx_test.py` — dual-transport (`ClientTestCase`) respx suite for the favorite toggle: the `FAVORITE_LIMIT` refusal envelope and the query/body split. ## Three test layers @@ -56,7 +57,7 @@ A respx body for that same arm was written first and deleted once the live cover ## The parametrised `ClientTestCase` harness -Implemented in `test/_client_harness.py`, importable by any `respx` module that wants one body over both transports; `metadata_field_properties_test.py` is the canonical user, joined by `exists_probe_mapping_test.py` (the `exists()` `404`→`False` arm, which was async-only until the harness existed — the mapping is transport-independent, so one body covers both). The remaining `respx` bodies are the single-transport cases invariant 5 exempts. The shape: +Implemented in `test/_client_harness.py`, importable by any `respx` module that wants one body over both transports; `metadata_field_properties_test.py` is the canonical user, joined by `exists_probe_mapping_test.py` (the `exists()` `404`→`False` arm, which was async-only until the harness existed — the mapping is transport-independent, so one body covers both) and `ruleset_favorite_respx_test.py` (the favorite toggle's refusal envelope + query/body split). The remaining `respx` bodies are the single-transport cases invariant 5 exempts. The shape: ```python # test/_client_harness.py diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index eb476820..48856dfb 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -147,7 +147,7 @@ ArtifactInstance, LocalArtifact, Hash Engine Metadata, MetadataMapping, MetadataFieldProperties IOC -LiveYaraRuleset, LiveHuntResult, LiveHuntResultList, LiveHuntResultCounts +LiveYaraRuleset, LiveHuntResult, LiveHuntResultList HistoricalHunt, HistoricalHuntResult, HistoricalHuntResultList, HistoricalHuntList YaraRuleset, YaraRulesetFavorite Tag, MalwareFamily, TagLink @@ -180,7 +180,7 @@ class TimeoutException(PolyswarmException): ... `KnownGoodWithheldException` is the 404 raised when a download is refused because the artifact is a known-good binary — the platform never stores or serves those bytes. It **subclasses `NotFoundException`** precisely so invariant 3 holds for existing consumers: code that already does `except NotFoundException:` keeps catching the refusal with no change, and only callers that want to distinguish "withheld by design" from a plain miss catch the subclass. It adds one attribute, `.sources` — the known-good feeds that flagged the hash (e.g. `['nsrl']`), `[]` when the server named none. The contract is only this: **always a list of strings**, whatever the envelope carried, so `for feed in exc.sources` needs no shape check. Which wire shapes are coerced, and which are dropped and logged, is `exceptions._normalise_sources`' business rather than a promise to consumers — the server sends a list of strings today. Note it is **not** normalised the same way as `ArtifactInstance.known_good_sources`, which is the same concept reached from the instance response: that one is sorted and de-duplicated, while `.sources` preserves the order the envelope carried and can repeat a feed. Don't assume parity between the two. The raw envelope stays reachable at `exc.request.errors` (`{'code': 'KNOWN_GOOD', 'known_good': True, 'sources': [...]}`). The artifact's metadata — the flagging feeds plus any scan data already collected — remains readable through the search / instance endpoints; only the bytes are withheld, and the instance's `KNOWN_GOOD` state/status is the signal for the typed refusal (there is no separate "withheld" field; a `NOT_STORED` instance has no bytes either, but 404s plainly — see below). -`FAVORITE_LIMIT` (a refused ruleset star: the team's favorite budget is spent) has **no typed exception** — deliberately, since no pre-existing consumer needs re-routing the way `NotFoundException` did. It surfaces as the generic 400 `RequestException`, and the machine-readable path is the raw envelope: `exc.request.errors == {'code': 'FAVORITE_LIMIT', 'favorites_used': N, 'favorites_limit': M}`. The counters are the same pair a successful toggle returns, so a caller can render the "budget full" state from either outcome. Pinned by the respx refusal test in `client_scan_test.py`. +`FAVORITE_LIMIT` (a refused ruleset star: the team's favorite budget is spent) has **no typed exception** — deliberately, since no pre-existing consumer needs re-routing the way `NotFoundException` did. It surfaces as the generic 400 `RequestException`, and the machine-readable path is the raw envelope: `exc.request.errors == {'code': 'FAVORITE_LIMIT', 'favorites_used': N, 'favorites_limit': M}`. The counters are the same pair a successful toggle returns, so a caller can render the "budget full" state from either outcome. Pinned by the dual-transport respx suite `test/ruleset_favorite_respx_test.py`. **What "known-good" means on the server, as of artifact-index's two-predicate model** (its `specs/05`): the refusal fires on the server's *current understanding* — a catalogue entry exists for the sha256 **and** that entry's extension passes an executable allow-list — evaluated live on every request. Two consequences worth knowing as a consumer: the same download can start working again with no action on your part (the entry is deleted, or the policy narrows), and `ArtifactInstance.state` can report the new value **`NOT_STORED`** — a submission the server declined as known-good at the time whose hash is no longer currently known-good, so nothing was ever stored for it and a fresh submit of the same file works. `state` is a plain string here; the SDK does not enumerate it, so a new member needs no SDK release. @@ -301,6 +301,19 @@ Migrating from 3.x to 4.0, callers retain: ## Backward compatibility — what changes +### Documentation corrections that read like behaviour changes + +- **`live_feed(since=)` was always SECONDS.** The 3.x/4.x docstring said + "minutes", but the server has always converted the parameter with + `timedelta(seconds=since)` — the docstring was corrected, not the wire. A + caller who read the old docstring and passed `60` meaning an hour was + already getting a minute; nothing changed underneath them. Relatedly, the + server is tightening the parameter from a truthiness test to `is not None`, + so `since=0` moves from "all time" to "an empty window" — that one IS a + server-side behaviour change, noted here so the `develop → master` bump + decision sees it (the SDK is a passthrough; no major bump forced from this + side). + ### Required code changes - **File-upload module-level callables removed.** `polyswarm_api.aio.upload.async_upload_file` / `async_upload_logo` (and the bare-module aliases) are gone. The 3.x monkey-patch pattern doesn't carry forward. Customization is via subclassing `AsyncPolyswarmSession` and overriding `upload_file`. diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index ec286cb3..ed06f815 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -507,7 +507,11 @@ async def live_feed(self, since=None, rule_name=None, family=None, """ Get live hunts feed - :param since: Fetch results from the last "since" minutes + :param since: Window in SECONDS (the server converts it with + timedelta(seconds=since); it previously documented minutes here, + but the server never read minutes). The server is also tightening + the parameter from a truthiness test to `is not None`, so since=0 + means an empty window, not "all time". :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). :param polyscore_lower: Polyscore lower bound for the hunt results. @@ -523,19 +527,6 @@ async def live_feed(self, since=None, rule_name=None, family=None, community=community or self.community)): yield item - async def live_results_count(self, since=None): - """ - Per-live-hunt result counts for the current account, grouped by - livescan_id. One request answers every "new results in the window" - badge; a hunt absent from counts collected 0. - - :param since: Window in seconds (server default: 86400 — 24 hours) - :return: A LiveHuntResultCounts resource - """ - logger.info('Live results count since %s', since) - return await self._single( - resources.LiveHuntResultCounts.get(self, since=since, community=self.community)) - async def live_feed_delete(self, result_ids): """ Delete live feed results @@ -701,7 +692,7 @@ async def ruleset_delete(self, ruleset_id): return await self._single(resources.YaraRuleset.delete(self, id=ruleset_id, community=self.community)) async def ruleset_list(self, name=None, status=None, favorites_only=None, - has_new_results=None, since=None, include_counts=None): + has_new_results=None): """ List all YaraRulesets for the current account. @@ -710,19 +701,17 @@ async def ruleset_list(self, name=None, status=None, favorites_only=None, :param status: 'active' returns only rulesets whose live hunt is currently running. :param favorites_only: True returns only favorited rulesets. - :param has_new_results: True returns only rulesets whose live hunt - collected results inside the window. - :param since: Window in seconds for has_new_results/include_counts - (server default: 86400). - :param include_counts: True attaches new_results_count to each - ruleset that has a live hunt. + :param has_new_results: True returns only rulesets whose stored + new-results counter is positive. The counter (and its window) is + maintained server-side by a scheduled refresh; rows carry it as + ``new_results_count`` with ``new_results_counted_at`` marking when + it was last refreshed. There is no per-request window parameter. :return: A generator of YaraRuleset resources """ logger.info('List rulesets') async for item in self._paginate(resources.YaraRuleset.list( self, name=name, status=status, favorites_only=favorites_only, - has_new_results=has_new_results, since=since, - include_counts=include_counts, community=self.community)): + has_new_results=has_new_results, community=self.community)): yield item async def ruleset_favorite(self, ruleset_id, favorite=True): diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 62b27d70..a085b43e 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -573,7 +573,11 @@ def live_feed( """ Get live hunts feed - :param since: Fetch results from the last "since" minutes + :param since: Window in SECONDS (the server converts it with + timedelta(seconds=since); it previously documented minutes here, + but the server never read minutes). The server is also tightening + the parameter from a truthiness test to `is not None`, so since=0 + means an empty window, not "all time". :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). :param polyscore_lower: Polyscore lower bound for the hunt results. @@ -596,22 +600,6 @@ def live_feed( ): yield item - def live_results_count(self, since=None): - """ - Per-live-hunt result counts for the current account, grouped by - livescan_id. One request answers every "new results in the window" - badge; a hunt absent from counts collected 0. - - :param since: Window in seconds (server default: 86400 — 24 hours) - :return: A LiveHuntResultCounts resource - """ - logger.info("Live results count since %s", since) - return self._single( - resources.LiveHuntResultCounts.get( - self, since=since, community=self.community - ) - ) - def live_feed_delete(self, result_ids): """ Delete live feed results @@ -843,13 +831,7 @@ def ruleset_delete(self, ruleset_id): ) def ruleset_list( - self, - name=None, - status=None, - favorites_only=None, - has_new_results=None, - since=None, - include_counts=None, + self, name=None, status=None, favorites_only=None, has_new_results=None ): """ List all YaraRulesets for the current account. @@ -859,12 +841,11 @@ def ruleset_list( :param status: 'active' returns only rulesets whose live hunt is currently running. :param favorites_only: True returns only favorited rulesets. - :param has_new_results: True returns only rulesets whose live hunt - collected results inside the window. - :param since: Window in seconds for has_new_results/include_counts - (server default: 86400). - :param include_counts: True attaches new_results_count to each - ruleset that has a live hunt. + :param has_new_results: True returns only rulesets whose stored + new-results counter is positive. The counter (and its window) is + maintained server-side by a scheduled refresh; rows carry it as + ``new_results_count`` with ``new_results_counted_at`` marking when + it was last refreshed. There is no per-request window parameter. :return: A generator of YaraRuleset resources """ logger.info("List rulesets") @@ -875,8 +856,6 @@ def ruleset_list( status=status, favorites_only=favorites_only, has_new_results=has_new_results, - since=since, - include_counts=include_counts, community=self.community, ) ): diff --git a/src/polyswarm_api/resources.py b/src/polyswarm_api/resources.py index 10b909b0..b898ac8f 100644 --- a/src/polyswarm_api/resources.py +++ b/src/polyswarm_api/resources.py @@ -754,10 +754,15 @@ def __init__(self, content, api=None): # server could not or has not counted), which is different from 0. self.rule_count = content.get('rule_count') self.historical_hunt_count = content.get('historical_hunt_count') - # Live results collected in the requested window; only present when - # the list was asked to include counts, and only for rulesets with a - # live hunt — None otherwise. + # Live results collected in the product window — a STORED counter the + # server refreshes on a schedule, always present on list rows with a + # running live hunt. None means "not yet refreshed / no live hunt", + # which is different from 0 ("refreshed, nothing new"). self.new_results_count = content.get('new_results_count') + # When the server last refreshed the counter — the staleness marker + # that makes a stored count trustworthy (None iff the count is None). + self.new_results_counted_at = core.parse_isoformat( + content.get('new_results_counted_at')) class LiveYaraRuleset(YaraRuleset): @@ -769,8 +774,13 @@ class YaraRulesetFavorite(core.BaseJsonResource): team's budget usage, so callers can render "N of M used" without counting client-side.""" RESOURCE_ENDPOINT = '/hunt/rule/favorite' - # No query-string keys: the toggle takes {id, favorite} in the JSON body. - RESOURCE_ID_KEYS = [] + # The toggle's payload ({id, favorite}) rides the JSON body — the server + # reads BOTH from the body — so the default RESOURCE_ID_KEYS (['id']) + # would move `id` into the query string and the server would 400 with + # "A valid rule id must be provided". `community` stays a query-string + # key to match where every ruleset GET/list sends it (the server accepts + # it from either the query or the body, but never from both at once). + RESOURCE_ID_KEYS = ['community'] def __init__(self, content, api=None): super().__init__(content, api=api) @@ -807,22 +817,6 @@ class LiveHuntResultList(LiveHuntResult): RESOURCE_ENDPOINT = '/hunt/live/list' -class LiveHuntResultCounts(core.BaseJsonResource): - """Per-live-hunt result counts inside a window: ``since`` (seconds) plus - ``counts``, a list of ``{livescan_id, count}`` — one aggregate request for - every "new results" badge. ``livescan_id`` is a digit string, the same - value ``YaraRuleset.livescan_id`` carries (the join key; ids exceed - JavaScript's safe-integer range, so they are never bare JSON ints). A hunt - with no results in the window is simply absent from ``counts``; absence - means 0.""" - RESOURCE_ENDPOINT = '/hunt/live/results/count' - - def __init__(self, content, api=None): - super().__init__(content, api=api) - self.since = content.get('since') - self.counts = content.get('counts') or [] - - class HistoricalHunt(core.BaseJsonResource): RESOURCE_ENDPOINT = '/hunt/historical' diff --git a/test/_e2e_helpers.py b/test/_e2e_helpers.py index d4f14ca6..88884220 100644 --- a/test/_e2e_helpers.py +++ b/test/_e2e_helpers.py @@ -143,8 +143,14 @@ def poll_equals(read, want, tries=30, delay=1.0): real-replica stack lags — without the poll those assertions are lag-flaky, and the changed-since-freeze one flakes in the silent direction (stale source body reads as "unchanged"). Not-found during the - lag window counts as "not yet". Sleeps are free on VCR replay - (``_skip_poll_sleep_on_replay``).""" + lag window counts as "not yet" — which is exactly why ``want`` must never + be None: a 404 would compare equal to it and turn a vanished resource + into a passing assertion (poll a boolean instead — ``read`` returning + ``value is None``, want=True). Enforced below. Sleeps are free on VCR + replay (``_skip_poll_sleep_on_replay``).""" + if want is None: + raise ValueError('poll_equals(want=None) would treat a 404 as a match; ' + 'poll a boolean instead (read: value is None, want=True).') from polyswarm_api import exceptions as _exceptions value = None for _ in range(tries): @@ -160,7 +166,10 @@ def poll_equals(read, want, tries=30, delay=1.0): async def poll_equals_async(read, want, tries=30, delay=1.0): """The asyncio twin of ``poll_equals`` (``read`` is a zero-arg coroutine - function).""" + function), including the want-is-None refusal.""" + if want is None: + raise ValueError('poll_equals_async(want=None) would treat a 404 as a ' + 'match; poll a boolean instead.') from polyswarm_api import exceptions as _exceptions value = None for _ in range(tries): diff --git a/test/async_client_test.py b/test/async_client_test.py index a7e82507..479102e4 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -650,31 +650,41 @@ async def test_async_rules(self, uid): assert unfav.favorite is False assert unfav.favorited_at is None - # live-hunt scope: counts, include_counts and the livescan_id - # feed all need a running hunt; the fresh ruleset matches - # nothing, so every count is a computed ZERO (distinct from - # null = no live hunt to count against) + # live-hunt scope: the stored new-results counter and the + # livescan_id feed both need a running hunt. The badge is + # written ONLY by the server's scheduled refresh job (never on + # a request), and that job does not run on the e2e stack — so + # the row reads null ("never refreshed"): never 0, with the + # staleness marker riding along. Counting semantics are pinned + # by the server's own HTTP + CLI suites. await api.live_start(int(rule.id)) try: + # the enable lands asynchronously and the GET reads the + # replica — poll rather than read-one-line-later + async def _has_livescan(): + return (await api.ruleset_get(rule.id)).livescan_id is not None + assert await poll_equals_async(_has_livescan, True) livescan_id = (await api.ruleset_get(rule.id)).livescan_id - assert livescan_id is not None # a digit string active = {r.id async for r in api.ruleset_list(status='active')} assert rule.id in active - with_counts = None - async for r in api.ruleset_list(include_counts=True): + row = None + async for r in api.ruleset_list(): if r.id == rule.id: - with_counts = r - assert with_counts is not None - assert with_counts.new_results_count == 0 - counts = await api.live_results_count(since=86400) - assert counts.since == 86400 - # zero results -> our hunt is ABSENT (absence means 0) - assert livescan_id not in {entry['livescan_id'] - for entry in counts.counts} - # NOTE: zero-result hunt — pins the wire shape and the - # empty pass-through only; the scoping semantics are - # pinned by the server's own HTTP suite (same for - # has_new_results) + row = r + assert row is not None + assert row.new_results_count is None + assert row.new_results_counted_at is None + # has_new_results reads the stored counter (> 0): a never- + # refreshed hunt must NOT match + try: + hot_ids = {r.id async for r in + api.ruleset_list(has_new_results=True)} + except exceptions.NoResultsException: + hot_ids = set() + assert rule.id not in hot_ids + # NOTE: zero-result hunt — the feed check pins the wire + # shape and the empty pass-through only; the scoping + # semantics are pinned by the server's own HTTP suite try: feed = [r async for r in api.live_feed(livescan_id=livescan_id)] assert feed == [] @@ -684,23 +694,33 @@ async def test_async_rules(self, uid): # MUST stop before the outer finally's ruleset_delete — a # running live hunt blocks deletion server-side await api.live_stop(int(rule.id)) - try: - still_active = {r.id async for r in api.ruleset_list(status='active')} - except exceptions.NoResultsException: - still_active = set() # nothing live anywhere: also a pass - assert rule.id not in still_active + + async def _rule_is_inactive(): + try: + active_now = {r.id async for r in + api.ruleset_list(status='active')} + except exceptions.NoResultsException: + return True # nothing live anywhere: also a pass + return rule.id not in active_now + # the stop's detach reads back off the replica too — poll + assert await poll_equals_async(_rule_is_inactive, True) # a hunt triggered FROM the ruleset carries provenance and - # bumps the counter; the create response's comparison is - # unknown (None) and a read resolves it + # bumps the counter; the create response answers + # source_rule_changed=False directly — the freeze stamped the + # anchor from the very row it froze, so the answer is knowable + # without a re-read hunt = await api.historical_create(int(rule.id)) assert hunt.rule_id == rule.id assert hunt.rule_modified is not None - assert hunt.source_rule_changed is None + assert hunt.source_rule_changed is False # replica-backed GETs: poll so a lagging replica (real - # stacks, not e2e) can't flake these — the changed-since- - # freeze flip's stale read is a silent False + # stacks, not e2e — a fresh hunt can even 404 for a beat) + # can't flake these. The False poll below cannot defend + # against a stale False (it returns on the first False); + # its poll exists for the 404-window, while the later TRUE + # poll genuinely rides out a stale read. async def _hunt_count(): return (await api.ruleset_get(rule.id)).historical_hunt_count @@ -717,15 +737,22 @@ async def _changed(): assert updated.description == 'test' assert await poll_equals_async(_changed, True) is True finally: - if hunt is not None: - await api.historical_delete(hunt.id) - await api.ruleset_delete(rule.id) - remaining_ids = [] - try: - remaining_ids = [r.id async for r in api.ruleset_list()] - except exceptions.NoResultsException: - pass - assert rule.id not in remaining_ids + # The ruleset delete is the slot-hygiene guarantee — keep it + # reachable even when the hunt delete fails (see sync twin). + try: + if hunt is not None: + await api.historical_delete(hunt.id) + finally: + await api.ruleset_delete(rule.id) + async def _rule_is_unlisted(): + try: + listed = {r.id async for r in api.ruleset_list()} + except exceptions.NoResultsException: + return True + return rule.id not in listed + # the delete reads back off the replica — poll like the other + # read-after-writes in this test + assert await poll_equals_async(_rule_is_unlisted, True) # ── Historical Hunting ──────────────────────────────────────────────────── @@ -824,8 +851,14 @@ async def test_async_live(self, uid): await api.live_result(result_id) await api.live_stop(rule_id=rule_id) - stopped = await api.ruleset_get(rule_id) - assert stopped.livescan_id is None + + # the stop's detach reads back off the replica — poll instead + # of reading one line later. Poll a BOOLEAN, never want=None: + # the helper maps a 404 during the lag window to None, so + # want=None would let a vanished ruleset pass silently. + async def _stopped_livescan_cleared(): + return (await api.ruleset_get(rule_id)).livescan_id is None + assert await poll_equals_async(_stopped_livescan_cleared, True) finally: # Always tear the hunt down (see sync test_live): a leftover # active hunt captures every later EICAR submit and is what diff --git a/test/client_scan_test.py b/test/client_scan_test.py index fb9a2366..6111070a 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -357,31 +357,6 @@ def test_metadata_search(self): lambda: api.search_by_metadata(f'artifact.sha256:{sha}'), tries=90) assert result and result[0].sha256 == sha - def test_favorite_limit_refusal_is_machine_readable(self): - # The FAVORITE_LIMIT refusal path (respx-mocked: producing a genuinely - # full budget on the SHARED e2e stack would require holding all five - # team slots, racing every other run). There is deliberately no typed - # exception (specs/05): the machine-readable contract is the raw - # envelope at exc.request.errors — the code plus the same counters a - # successful toggle returns. - with respx.mock(assert_all_called=True) as router: - envelope = { - 'status': 'error', - 'result': 'Favorite limit reached (5 of 5 used).', - 'errors': {'code': 'FAVORITE_LIMIT', - 'favorites_used': 5, 'favorites_limit': 5}, - } - router.put('http://localhost:3000/api/v1/hunt/rule/favorite').mock( - return_value=httpx.Response(400, json=envelope)) - api = PolyswarmAPI(self.test_api_key, uri='http://localhost:3000/api/v1', - community='gamma') - with pytest.raises(exceptions.RequestException) as excinfo: - api.ruleset_favorite(5, True) - errors = excinfo.value.request.errors - assert errors['code'] == 'FAVORITE_LIMIT' - assert errors['favorites_used'] == 5 - assert errors['favorites_limit'] == 5 - def test_resolve_engine_name(self): with respx.mock(assert_all_called=False) as router: ok_payload = {'results': [ @@ -531,10 +506,14 @@ def test_live(self): api.live_result(result_id) # Stop returns the just-stopped livescan_id; the ruleset's stored - # livescan_id flips back to None on the next read. + # livescan_id flips back to None on a subsequent read — which hits + # the replica, so poll instead of reading one line later. Poll a + # BOOLEAN, never want=None: the helper maps a 404 during the lag + # window to None, so want=None would let a vanished ruleset pass + # the assertion the old direct read would have raised on. api.live_stop(rule_id=rule_id) - stopped = api.ruleset_get(rule_id) - assert stopped.livescan_id is None + assert poll_equals( + lambda: api.ruleset_get(rule_id).livescan_id is None, True) finally: # Always tear the hunt down, even on a mid-test failure: a left- # over active live hunt captures every later EICAR submission in @@ -637,29 +616,38 @@ def test_rules(self): unfav = api.ruleset_favorite(rule.id, False) assert unfav.favorite is False assert unfav.favorited_at is None - # live-hunt scope: the counts endpoint, include_counts and the - # livescan_id feed all need a running hunt. The fresh ruleset - # matches nothing, so every count is a computed ZERO — still - # distinct from null (= no live hunt to count against). + # live-hunt scope: the stored new-results counter and the + # livescan_id feed both need a running hunt. The badge is written + # ONLY by the server's scheduled refresh job (never on a request), + # and that job does not run on the e2e stack — so the row reads + # null ("never refreshed"), which is exactly the additive-field + # contract this SDK pins: never 0, and the staleness marker rides + # with it. The counting semantics themselves are pinned by the + # server's own HTTP + CLI suites. api.live_start(int(rule.id)) try: + # the enable lands asynchronously and the GET reads the + # replica — poll rather than read-one-line-later + assert poll_equals( + lambda: api.ruleset_get(rule.id).livescan_id is not None, + True) livescan_id = api.ruleset_get(rule.id).livescan_id - assert livescan_id is not None # a digit string assert rule.id in {r.id for r in api.ruleset_list(status='active')} - with_counts = next(r for r in api.ruleset_list(include_counts=True) - if r.id == rule.id) - assert with_counts.new_results_count == 0 - counts = api.live_results_count(since=86400) - assert counts.since == 86400 - # zero results -> our hunt is ABSENT (absence means 0); the - # keys are the same digit strings ruleset_get renders - assert livescan_id not in {entry['livescan_id'] - for entry in counts.counts} - # NOTE: with a zero-result hunt this pins only the wire shape - # and the empty pass-through — it cannot tell a working filter - # from an ignored param (that would need a second hunt WITH - # results). The scoping semantics themselves are pinned by the - # server's own HTTP suite; same for has_new_results. + row = next(r for r in api.ruleset_list() if r.id == rule.id) + assert row.new_results_count is None + assert row.new_results_counted_at is None + # has_new_results reads the stored counter (> 0): a never- + # refreshed hunt must NOT match + try: + hot_ids = {r.id for r in api.ruleset_list(has_new_results=True)} + except exceptions.NoResultsException: + hot_ids = set() + assert rule.id not in hot_ids + # NOTE: with a zero-result hunt the feed check pins only the + # wire shape and the empty pass-through — it cannot tell a + # working filter from an ignored param (that would need a + # second hunt WITH results). The scoping semantics are pinned + # by the server's own HTTP suite. try: assert list(api.live_feed(livescan_id=livescan_id)) == [] except exceptions.NoResultsException: @@ -668,21 +656,29 @@ def test_rules(self): # MUST stop before the outer finally's ruleset_delete — a # running live hunt blocks deletion server-side api.live_stop(int(rule.id)) - try: - still_active = {r.id for r in api.ruleset_list(status='active')} - except exceptions.NoResultsException: - still_active = set() # nothing live anywhere: also a pass - assert rule.id not in still_active + + def _active_ids(): + try: + return {r.id for r in api.ruleset_list(status='active')} + except exceptions.NoResultsException: + return set() # nothing live anywhere: also a pass + # the stop's detach reads back off the replica too — poll + assert poll_equals(lambda: rule.id not in _active_ids(), True) # a historical hunt triggered FROM the ruleset carries the - # provenance and bumps the ruleset's counter; the create response's - # source_rule_changed is None (unknown until a read re-resolves it) + # provenance and bumps the ruleset's counter; the create response + # answers source_rule_changed=False directly — the freeze stamped + # the anchor from the very row it froze, so the answer is knowable + # without a re-read hunt = api.historical_create(int(rule.id)) assert hunt.rule_id == rule.id assert hunt.rule_modified is not None - assert hunt.source_rule_changed is None + assert hunt.source_rule_changed is False # the GETs below read the replica; poll so a lagging replica - # (real stacks, not e2e) can't flake these — especially the - # changed-since-freeze flip, whose stale read is a silent False + # (real stacks, not e2e — a fresh hunt can even 404 there for a + # beat) can't flake these. Note the False poll below cannot defend + # against a stale False (it returns on the first False, stale or + # not); its poll exists for the 404-window, while the later TRUE + # poll is the one that genuinely rides out a stale read. assert poll_equals( lambda: api.ruleset_get(rule.id).historical_hunt_count, 1) == 1 # a read of the fresh hunt resolves the comparison: unchanged body @@ -698,16 +694,24 @@ def test_rules(self): assert poll_equals( lambda: api.historical_get(hunt.id).source_rule_changed, True) is True finally: - if hunt is not None: - api.historical_delete(hunt.id) - # deleting — the created rule disappears from the list. - api.ruleset_delete(rule.id) - remaining_ids = [] - try: - remaining_ids = [r.id for r in api.ruleset_list()] - except exceptions.NoResultsException: - pass - assert rule.id not in remaining_ids + # The ruleset delete is the slot-hygiene guarantee other comments + # lean on, so it must not sit behind the hunt delete (a transient + # 5xx, or a hunt already DELETING, would otherwise leak a ruleset + # on the shared stack). + try: + if hunt is not None: + api.historical_delete(hunt.id) + finally: + # deleting — the created rule disappears from the list. + api.ruleset_delete(rule.id) + def _listed_ids(): + try: + return {r.id for r in api.ruleset_list()} + except exceptions.NoResultsException: + return set() + # the delete reads back off the replica — poll like the other + # read-after-writes in this test + assert poll_equals(lambda: rule.id not in _listed_ids(), True) @vcr.use_cassette() def test_tool_metadata(self): diff --git a/test/conftest.py b/test/conftest.py index c9eecb40..041c6165 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -121,6 +121,7 @@ async def _noop_async_sleep(*_a, **_k): "sample", # sandbox completion + metadata "stream", # global archiver batching "rescan", # rescan retry loop + settle + "rules", # test_rules / test_async_rules — live enable/stop + ~6 poll loops "hash_search", # search-index lag "existence_probe", # submit + settle + search-index lag (the HEAD probe tests) "sandboxtask", # sandbox completion + index lag diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index 653a88dc..4d892782 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -5,10 +5,11 @@ that are entirely consequences of ``core._params`` plumbing rather than anything visible at the call site: -* ``YaraRulesetFavorite`` empties ``RESOURCE_ID_KEYS``, which is the ONLY - thing routing ``id`` (and ``favorite``/``community``) into the PUT's JSON - body instead of the query string — the server reads the toggle exclusively - from the body; and +* ``YaraRulesetFavorite`` narrows ``RESOURCE_ID_KEYS`` to ``['community']``, + which is what splits the request: the server reads BOTH ``id`` and + ``favorite`` from the JSON body (the default ``['id']`` would move ``id`` + into the query string and the server would 400), while ``community`` rides + the query string to match where the ruleset GET/list calls send it; and * booleans serialise as ``1``/``0`` ints, not JSON ``true``/``false`` (``core._params`` coerces before body/query routing) — the server's boolean parser accepts exactly that, so the int-vs-bool body contract is @@ -26,17 +27,20 @@ class _FakeApi: class TestYaraRulesetFavoriteBuilder: - def test_update_routes_everything_to_the_put_body(self): + def test_update_splits_community_to_query_and_toggle_to_body(self): api = _FakeApi() req = resources.YaraRulesetFavorite.update( api, id=5, favorite=True, community=api.community) assert req.method == 'PUT' assert req.url == f'{api.uri}/hunt/rule/favorite' - # RESOURCE_ID_KEYS = [] is load-bearing: with the base ['id'] the id - # would ride the query string on a PUT, and the server only reads the - # body. favorite serialises as int 1, not JSON true. - assert req.params is None - assert req.input_json == {'id': '5', 'favorite': 1, 'community': 'gamma'} + # RESOURCE_ID_KEYS = ['community'] is load-bearing: with the base + # ['id'] the id would ride the query string on a PUT, and the server + # reads the toggle's id exclusively from the body — a 400. community + # goes to the query to match the ruleset GET/list placement (the + # server accepts it from either side, never both at once). favorite + # serialises as int 1, not JSON true. + assert req.params == {'community': 'gamma'} + assert req.input_json == {'id': '5', 'favorite': 1} assert req.result_parser is resources.YaraRulesetFavorite def test_unfavorite_serialises_false_as_zero(self): @@ -45,48 +49,73 @@ def test_unfavorite_serialises_false_as_zero(self): assert req.input_json['favorite'] == 0 -class TestLiveHuntResultCountsBuilder: - def test_get_routes_since_and_community_to_the_query(self): - api = _FakeApi() - req = resources.LiveHuntResultCounts.get( - api, since=86400, community=api.community) - assert req.method == 'GET' - assert req.url == f'{api.uri}/hunt/live/results/count' - assert req.params == {'since': 86400, 'community': 'gamma'} - assert req.input_json is None - assert req.result_parser is resources.LiveHuntResultCounts - - def test_get_omits_unset_since(self): - # None is dropped, so the server applies its own default window. - req = resources.LiveHuntResultCounts.get( - _FakeApi(), since=None, community='gamma') - assert req.params == {'community': 'gamma'} - - class TestRulesetListFilterBuilder: def test_list_routes_filters_to_the_query_with_int_bools(self): api = _FakeApi() req = resources.YaraRuleset.list( api, name='alpha', status='active', favorites_only=True, - has_new_results=True, since=86400, include_counts=True, - community=api.community) + has_new_results=True, community=api.community) assert req.method == 'GET' assert req.url == f'{api.uri}/hunt/rule/list' assert req.params == { 'name': 'alpha', 'status': 'active', 'favorites_only': 1, - 'has_new_results': 1, 'since': 86400, 'include_counts': 1, - 'community': 'gamma'} + 'has_new_results': 1, 'community': 'gamma'} def test_list_omits_every_unset_filter(self): # The no-filter request is byte-compatible with the pre-filter # contract: nothing but community rides the query string. req = resources.YaraRuleset.list( _FakeApi(), name=None, status=None, favorites_only=None, - has_new_results=None, since=None, include_counts=None, - community='gamma') + has_new_results=None, community='gamma') assert req.params == {'community': 'gamma'} +class TestYaraRulesetStoredCounterParse: + """Parse-side pins for the stored counter — the recorded cassettes carry + only null counters (the refresh job does not run on the e2e stack), so + the populated shape is otherwise asserted nowhere.""" + + def test_counter_and_staleness_marker_parse(self): + row = resources.YaraRuleset( + {'id': '5', 'new_results_count': 3, + 'new_results_counted_at': '2026-08-25T12:00:00+00:00'}, api=None) + assert row.new_results_count == 3 + assert row.new_results_counted_at is not None + assert row.new_results_counted_at.isoformat() == '2026-08-25T12:00:00+00:00' + + def test_absent_counter_is_none_never_zero(self): + # An older server (or a never-refreshed row) leaves both None — + # "no answer", distinct from a refreshed 0. + row = resources.YaraRuleset({'id': '5'}, api=None) + assert row.new_results_count is None + assert row.new_results_counted_at is None + + +class TestProvenanceAndCounterAbsentArms: + """The None arms the cassettes cannot carry: every recorded hunt resolves + its provenance (true/false) and every recorded ruleset has answers, so + the "None is unknown / no answer — NEVER a value" halves of the tri-state + and counter contracts are pinned here, purely on the parse.""" + + def test_hunt_without_provenance_parses_all_three_none(self): + # A pre-migration or raw-yara hunt: no rule_id, no anchor. None means + # UNKNOWN — a consumer rendering it as "unchanged" is the exact bug + # the tri-state exists to prevent. + hunt = resources.HistoricalHunt( + {'id': '9', 'created': '2026-08-25T12:00:00+00:00', + 'status': 'PENDING', 'progress': 0.0, 'results_csv_uri': None}, + api=None) + assert hunt.rule_id is None + assert hunt.rule_modified is None + assert hunt.source_rule_changed is None + + def test_ruleset_counters_absent_is_none_never_zero(self): + # rule_count / historical_hunt_count: "no answer" must not read as 0. + row = resources.YaraRuleset({'id': '5'}, api=None) + assert row.rule_count is None + assert row.historical_hunt_count is None + + class TestLiveFeedScopeBuilder: def test_list_routes_livescan_id_to_the_query_as_digit_string(self): # *_id kwargs stringify (core._params); the server casts back to int. @@ -97,27 +126,3 @@ def test_list_routes_livescan_id_to_the_query_as_digit_string(self): assert req.url == 'https://api.example.test/hunt/live/list' assert req.params == {'since': 60, 'livescan_id': '45392847561029383', 'community': 'gamma'} - - -class TestLiveHuntResultCountsParse: - """Parse-side pins for the counts resource — the recorded cassettes carry - only EMPTY counts (the live tests use a fresh zero-result hunt), so the - entry shape and the digit-string join key documented in three places are - otherwise asserted nowhere.""" - - def test_counts_entries_parse_with_digit_string_join_keys(self): - payload = {'since': 86400, - 'counts': [{'livescan_id': '45392847561029383', 'count': 3}, - {'livescan_id': '71359438369584055', 'count': 1}]} - counts = resources.LiveHuntResultCounts(payload, api=None) - assert counts.since == 86400 - assert counts.counts == payload['counts'] - # the join key is the same digit string YaraRuleset.livescan_id - # carries — a bare int would round in a JS consumer - assert all(isinstance(entry['livescan_id'], str) for entry in counts.counts) - by_id = {entry['livescan_id']: entry['count'] for entry in counts.counts} - assert by_id['45392847561029383'] == 3 - - def test_null_counts_coalesces_to_an_empty_list(self): - counts = resources.LiveHuntResultCounts({'since': 86400, 'counts': None}, api=None) - assert counts.counts == [] diff --git a/test/ruleset_favorite_respx_test.py b/test/ruleset_favorite_respx_test.py new file mode 100644 index 00000000..cdfb3eca --- /dev/null +++ b/test/ruleset_favorite_respx_test.py @@ -0,0 +1,59 @@ +"""The favorite toggle's transport contract, respx-mocked on BOTH clients +(``ClientTestCase`` — specs/04-testing.md invariant 5). + +Two things live here because the shared e2e stack cannot pin either: + +* the ``FAVORITE_LIMIT`` refusal — producing a genuinely full budget on the + shared stack would mean holding all five team slots, racing every other + run; and +* the query/body split — the toggle's payload (``id``, ``favorite``) must + ride the JSON body (the server reads both from it; an ``id`` moved into + the query string by the default ``RESOURCE_ID_KEYS`` is a 400), while + ``community`` rides the query string to match the ruleset GET/list + placement. The e2e stack is single-community and its ids always exist, so + neither mis-split shows up there. +""" +import pytest + +from polyswarm_api import exceptions + +from test._client_harness import BASE_URL, COMMUNITY, ClientTestCase + +_FAVORITE_URL = f'{BASE_URL}/hunt/rule/favorite' + + +class RulesetFavoriteTestCase(ClientTestCase): + def test_favorite_limit_refusal_is_machine_readable(self): + # There is deliberately no typed exception (specs/05): the + # machine-readable contract is the raw envelope at + # ``exc.request.errors`` — the code plus the same counters a + # successful toggle returns. + envelope = { + 'status': 'error', + 'result': 'Favorite limit reached (5 of 5 used).', + 'errors': {'code': 'FAVORITE_LIMIT', + 'favorites_used': 5, 'favorites_limit': 5}, + } + self.mock.add('PUT', f'{_FAVORITE_URL}?community={COMMUNITY}', + json=envelope, status=400) + with pytest.raises(exceptions.RequestException) as excinfo: + self.api.ruleset_favorite(5, True) + errors = excinfo.value.request.errors + assert errors['code'] == 'FAVORITE_LIMIT' + assert errors['favorites_used'] == 5 + assert errors['favorites_limit'] == 5 + + def test_community_rides_the_query_and_the_toggle_rides_the_body(self): + ok = {'status': 'OK', + 'result': {'id': '5', 'favorite': True, 'favorited_at': None, + 'favorites_used': 1, 'favorites_limit': 5}} + self.mock.add('PUT', f'{_FAVORITE_URL}?community={COMMUNITY}', json=ok) + result = self.api.ruleset_favorite(5, True) + assert result.favorite is True + assert f'community={COMMUNITY}' in self.mock.last_request_url + body = self.mock.last_request_body + # The client's wire coercions apply to the body: ids stringify and + # bools ride as 1/0 (the server's cast=bool accepts both) — pinned so + # a coercion change is a deliberate one. + assert body == {'id': '5', 'favorite': 1} + assert 'community' not in body From 68ec25c934291111ed59871a750c4168f6c72623 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Tue, 25 Aug 2026 18:49:06 -0400 Subject: [PATCH 14/36] test: re-record the rules lifecycle cassettes against the stored-counter server --- test/vcr/test_async_rules.vcr | 207 ++++++++++++++++++++-------------- test/vcr/test_rules.vcr | 185 ++++++++++++++++++------------ 2 files changed, 233 insertions(+), 159 deletions(-) diff --git a/test/vcr/test_async_rules.vcr b/test/vcr/test_async_rules.vcr index 1b4cb8d6..175ad61d 100644 --- a/test/vcr/test_async_rules.vcr +++ b/test/vcr/test_async_rules.vcr @@ -23,7 +23,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:13.239703+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -35,11 +35,11 @@ interactions: connection: - keep-alive content-length: - - '412' + - '413' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -66,7 +66,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:13.239703+00:00","name":"test_async_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -77,11 +77,11 @@ interactions: connection: - keep-alive content-length: - - '391' + - '422' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -108,7 +108,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?name=test_async_rules&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:13.239703+00:00","name":"test_async_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -119,11 +119,11 @@ interactions: connection: - keep-alive content-length: - - '391' + - '422' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -147,10 +147,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=4466967201833338&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=89620634730010513&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:13.239703+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -162,11 +162,11 @@ interactions: connection: - keep-alive content-length: - - '412' + - '413' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -175,7 +175,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"4466967201833338","favorite":1,"community":"gamma"}' + body: '{"id":"89620634730010513","favorite":1}' headers: accept: - '*/*' @@ -186,7 +186,7 @@ interactions: connection: - keep-alive content-length: - - '58' + - '39' content-type: - application/json host: @@ -194,10 +194,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule/favorite + uri: http://ai:9696/v3/hunt/rule/favorite?community=gamma response: body: - string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T14:29:52.846750+00:00","favorites_limit":5,"favorites_used":1,"id":"4466967201833338"},"status":"OK"} + string: '{"result":{"favorite":true,"favorited_at":"2026-08-25T18:24:13.531691+00:00","favorites_limit":5,"favorites_used":1,"id":"89620634730010513"},"status":"OK"} ' headers: @@ -208,11 +208,11 @@ interactions: connection: - keep-alive content-length: - - '156' + - '157' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -239,7 +239,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?favorites_only=1&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T14:29:52.846750+00:00","historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:52.300732+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-25T18:24:13.531691+00:00","historical_hunt_count":0,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:13.239703+00:00","name":"test_async_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -250,11 +250,11 @@ interactions: connection: - keep-alive content-length: - - '420' + - '451' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -263,7 +263,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"4466967201833338","favorite":0,"community":"gamma"}' + body: '{"id":"89620634730010513","favorite":0}' headers: accept: - '*/*' @@ -274,7 +274,7 @@ interactions: connection: - keep-alive content-length: - - '58' + - '39' content-type: - application/json host: @@ -282,10 +282,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule/favorite + uri: http://ai:9696/v3/hunt/rule/favorite?community=gamma response: body: - string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"4466967201833338"},"status":"OK"} + string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"89620634730010513"},"status":"OK"} ' headers: @@ -296,11 +296,11 @@ interactions: connection: - keep-alive content-length: - - '127' + - '128' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:52 GMT + - Tue, 25 Aug 2026 18:24:13 GMT server: - gunicorn x-billing-id: @@ -309,7 +309,7 @@ interactions: code: 200 message: OK - request: - body: '{"rule_id":"4466967201833338"}' + body: '{"rule_id":"89620634730010513"}' headers: accept: - '*/*' @@ -320,7 +320,7 @@ interactions: connection: - keep-alive content-length: - - '30' + - '31' content-type: - application/json host: @@ -331,7 +331,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/live response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":"2026-08-25T18:24:17.121237+00:00","livescan_id":"7969689239265785","modified":"2026-08-25T18:24:17.108313+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -347,7 +347,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn x-billing-id: @@ -371,10 +371,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=4466967201833338&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=89620634730010513&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":"2026-08-25T18:24:17.121237+00:00","livescan_id":"7969689239265785","modified":"2026-08-25T18:24:17.108313+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -390,7 +390,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn x-billing-id: @@ -414,10 +414,11 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=89620634730010513&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":"2026-08-25T18:24:17.121237+00:00","livescan_id":"7969689239265785","modified":"2026-08-25T18:24:17.108313+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' headers: @@ -428,11 +429,11 @@ interactions: connection: - keep-alive content-length: - - '436' + - '457' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn x-billing-id: @@ -456,10 +457,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule/list?include_counts=1&community=gamma + uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":"2026-08-21T14:29:53.201880+00:00","livescan_id":"34849444833418665","modified":"2026-08-21T14:29:53.197377+00:00","name":"test_async_rules","new_results_count":0,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":"2026-08-25T18:24:17.121237+00:00","livescan_id":"7969689239265785","modified":"2026-08-25T18:24:17.108313+00:00","name":"test_async_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -470,11 +471,11 @@ interactions: connection: - keep-alive content-length: - - '433' + - '466' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn x-billing-id: @@ -498,10 +499,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/live/results/count?since=86400&community=gamma + uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: - string: '{"result":{"counts":[],"since":86400},"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":"2026-08-25T18:24:17.121237+00:00","livescan_id":"7969689239265785","modified":"2026-08-25T18:24:17.108313+00:00","name":"test_async_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -512,11 +513,11 @@ interactions: connection: - keep-alive content-length: - - '53' + - '466' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn x-billing-id: @@ -540,7 +541,43 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/live/list?livescan_id=34849444833418665&community=gamma + uri: http://ai:9696/v3/hunt/rule/list?has_new_results=1&community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Tue, 25 Aug 2026 18:24:17 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +- request: + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/live/list?livescan_id=7969689239265785&community=gamma response: body: string: '' @@ -554,14 +591,14 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn status: code: 204 message: NO CONTENT - request: - body: '{"rule_id":"4466967201833338"}' + body: '{"rule_id":"89620634730010513"}' headers: accept: - '*/*' @@ -572,7 +609,7 @@ interactions: connection: - keep-alive content-length: - - '30' + - '31' content-type: - application/json host: @@ -583,7 +620,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/live response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:53.570180+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:17.862491+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -595,11 +632,11 @@ interactions: connection: - keep-alive content-length: - - '412' + - '413' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:17 GMT server: - gunicorn x-billing-id: @@ -637,14 +674,14 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:18 GMT server: - gunicorn status: code: 204 message: NO CONTENT - request: - body: '{"rule_id":"4466967201833338","community":"gamma"}' + body: '{"rule_id":"89620634730010513","community":"gamma"}' headers: accept: - '*/*' @@ -655,7 +692,7 @@ interactions: connection: - keep-alive content-length: - - '50' + - '51' content-type: - application/json host: @@ -666,7 +703,7 @@ interactions: uri: http://ai:9696/v3/hunt/historical response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:18.313049+00:00","failed_max_retries":0,"failed_other":0,"id":"90911086658025862","progress":null,"results_csv_uri":null,"rule_id":"89620634730010513","rule_modified":"2026-08-25T18:24:17.862491+00:00","ruleset_name":"test_async_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -678,11 +715,11 @@ interactions: connection: - keep-alive content-length: - - '577' + - '579' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:18 GMT server: - gunicorn x-billing-id: @@ -706,10 +743,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=4466967201833338&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=89620634730010513&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:53.570180+00:00","name":"test_async_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:17.862491+00:00","name":"test_async_rules","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -721,11 +758,11 @@ interactions: connection: - keep-alive content-length: - - '412' + - '413' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:18 GMT server: - gunicorn x-billing-id: @@ -749,10 +786,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=41876045317487902&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=90911086658025862&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:18.313049+00:00","failed_max_retries":0,"failed_other":0,"id":"90911086658025862","progress":null,"results_csv_uri":null,"rule_id":"89620634730010513","rule_modified":"2026-08-25T18:24:17.862491+00:00","ruleset_name":"test_async_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -764,11 +801,11 @@ interactions: connection: - keep-alive content-length: - - '578' + - '579' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:53 GMT + - Tue, 25 Aug 2026 18:24:18 GMT server: - gunicorn x-billing-id: @@ -797,10 +834,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule?id=4466967201833338 + uri: http://ai:9696/v3/hunt/rule?id=89620634730010513 response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:54.082225+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:19.124101+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }\n// edited"},"status":"OK"} @@ -813,11 +850,11 @@ interactions: connection: - keep-alive content-length: - - '426' + - '427' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:54 GMT + - Tue, 25 Aug 2026 18:24:19 GMT server: - gunicorn x-billing-id: @@ -841,10 +878,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=41876045317487902&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=90911086658025862&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:18.313049+00:00","failed_max_retries":0,"failed_other":0,"id":"90911086658025862","progress":null,"results_csv_uri":null,"rule_id":"89620634730010513","rule_modified":"2026-08-25T18:24:17.862491+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -856,11 +893,11 @@ interactions: connection: - keep-alive content-length: - - '577' + - '578' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:54 GMT + - Tue, 25 Aug 2026 18:24:19 GMT server: - gunicorn x-billing-id: @@ -888,10 +925,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/historical?id=41876045317487902 + uri: http://ai:9696/v3/hunt/historical?id=90911086658025862 response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:53.760803+00:00","failed_max_retries":0,"failed_other":0,"id":"41876045317487902","progress":null,"results_csv_uri":null,"rule_id":"4466967201833338","rule_modified":"2026-08-21T14:29:53.570180+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:18.313049+00:00","failed_max_retries":0,"failed_other":0,"id":"90911086658025862","progress":null,"results_csv_uri":null,"rule_id":"89620634730010513","rule_modified":"2026-08-25T18:24:17.862491+00:00","ruleset_name":"test_async_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }"},"status":"OK"} ' @@ -903,11 +940,11 @@ interactions: connection: - keep-alive content-length: - - '578' + - '579' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:54 GMT + - Tue, 25 Aug 2026 18:24:19 GMT server: - gunicorn x-billing-id: @@ -935,10 +972,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/rule?id=4466967201833338 + uri: http://ai:9696/v3/hunt/rule?id=89620634730010513 response: body: - string: '{"result":{"created":"2026-08-21T14:29:52.300732+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"4466967201833338","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:54.434684+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:24:13.239703+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"89620634730010513","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:19.351670+00:00","name":"test_async_rules2","rule_count":1,"yara":"rule sdk_test_async_rules { strings: $u = \"test_async_rules\" condition: $u }\n// edited"},"status":"OK"} @@ -951,11 +988,11 @@ interactions: connection: - keep-alive content-length: - - '425' + - '426' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:54 GMT + - Tue, 25 Aug 2026 18:24:19 GMT server: - gunicorn x-billing-id: @@ -993,7 +1030,7 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 14:29:54 GMT + - Tue, 25 Aug 2026 18:24:19 GMT server: - gunicorn status: diff --git a/test/vcr/test_rules.vcr b/test/vcr/test_rules.vcr index 9c9b6dc2..1eb018a1 100644 --- a/test/vcr/test_rules.vcr +++ b/test/vcr/test_rules.vcr @@ -23,7 +23,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:23:50.641609+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -39,7 +39,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:48 GMT + - Tue, 25 Aug 2026 18:23:50 GMT server: - gunicorn x-billing-id: @@ -66,7 +66,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:23:50.641609+00:00","name":"test_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -77,11 +77,11 @@ interactions: connection: - keep-alive content-length: - - '386' + - '416' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:48 GMT + - Tue, 25 Aug 2026 18:23:56 GMT server: - gunicorn x-billing-id: @@ -108,7 +108,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?name=test_rules&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:23:50.641609+00:00","name":"test_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -119,11 +119,11 @@ interactions: connection: - keep-alive content-length: - - '386' + - '416' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:48 GMT + - Tue, 25 Aug 2026 18:23:56 GMT server: - gunicorn x-billing-id: @@ -147,10 +147,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=71359438369584055&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=46961337172843885&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:23:50.641609+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -166,7 +166,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:48 GMT + - Tue, 25 Aug 2026 18:23:56 GMT server: - gunicorn x-billing-id: @@ -175,7 +175,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"71359438369584055","favorite":1,"community":"gamma"}' + body: '{"id":"46961337172843885","favorite":1}' headers: accept: - '*/*' @@ -186,7 +186,7 @@ interactions: connection: - keep-alive content-length: - - '59' + - '39' content-type: - application/json host: @@ -194,10 +194,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule/favorite + uri: http://ai:9696/v3/hunt/rule/favorite?community=gamma response: body: - string: '{"result":{"favorite":true,"favorited_at":"2026-08-21T14:29:49.029459+00:00","favorites_limit":5,"favorites_used":1,"id":"71359438369584055"},"status":"OK"} + string: '{"result":{"favorite":true,"favorited_at":"2026-08-25T18:23:56.845109+00:00","favorites_limit":5,"favorites_used":1,"id":"46961337172843885"},"status":"OK"} ' headers: @@ -212,7 +212,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:23:56 GMT server: - gunicorn x-billing-id: @@ -239,7 +239,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/list?favorites_only=1&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-21T14:29:49.029459+00:00","historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:48.738607+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":true,"favorited_at":"2026-08-25T18:23:56.845109+00:00","historical_hunt_count":0,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:23:50.641609+00:00","name":"test_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -250,11 +250,11 @@ interactions: connection: - keep-alive content-length: - - '415' + - '445' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:23:57 GMT server: - gunicorn x-billing-id: @@ -263,7 +263,7 @@ interactions: code: 200 message: OK - request: - body: '{"id":"71359438369584055","favorite":0,"community":"gamma"}' + body: '{"id":"46961337172843885","favorite":0}' headers: accept: - '*/*' @@ -274,7 +274,7 @@ interactions: connection: - keep-alive content-length: - - '59' + - '39' content-type: - application/json host: @@ -282,10 +282,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule/favorite + uri: http://ai:9696/v3/hunt/rule/favorite?community=gamma response: body: - string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"71359438369584055"},"status":"OK"} + string: '{"result":{"favorite":false,"favorited_at":null,"favorites_limit":5,"favorites_used":0,"id":"46961337172843885"},"status":"OK"} ' headers: @@ -300,7 +300,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:23:57 GMT server: - gunicorn x-billing-id: @@ -309,7 +309,7 @@ interactions: code: 200 message: OK - request: - body: '{"rule_id":"71359438369584055"}' + body: '{"rule_id":"46961337172843885"}' headers: accept: - '*/*' @@ -331,7 +331,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/live response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":"2026-08-25T18:23:58.370832+00:00","livescan_id":"72927285313305230","modified":"2026-08-25T18:23:58.358140+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -347,7 +347,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:23:58 GMT server: - gunicorn x-billing-id: @@ -371,10 +371,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=71359438369584055&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=46961337172843885&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":"2026-08-25T18:23:58.370832+00:00","livescan_id":"72927285313305230","modified":"2026-08-25T18:23:58.358140+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -390,7 +390,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:23:59 GMT server: - gunicorn x-billing-id: @@ -414,10 +414,11 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=46961337172843885&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","new_results_count":null,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":"2026-08-25T18:23:58.370832+00:00","livescan_id":"72927285313305230","modified":"2026-08-25T18:23:58.358140+00:00","name":"test_rules","rule_count":1,"yara":"rule + sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' headers: @@ -428,11 +429,11 @@ interactions: connection: - keep-alive content-length: - - '431' + - '440' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:23:59 GMT server: - gunicorn x-billing-id: @@ -456,10 +457,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule/list?include_counts=1&community=gamma + uri: http://ai:9696/v3/hunt/rule/list?status=active&community=gamma response: body: - string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":"2026-08-21T14:29:49.287201+00:00","livescan_id":"11956831134597871","modified":"2026-08-21T14:29:49.282670+00:00","name":"test_rules","new_results_count":0,"rule_count":1,"yara":null}],"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":"2026-08-25T18:23:58.370832+00:00","livescan_id":"72927285313305230","modified":"2026-08-25T18:23:58.358140+00:00","name":"test_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -470,11 +471,11 @@ interactions: connection: - keep-alive content-length: - - '428' + - '461' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:24:00 GMT server: - gunicorn x-billing-id: @@ -498,10 +499,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/live/results/count?since=86400&community=gamma + uri: http://ai:9696/v3/hunt/rule/list?community=gamma response: body: - string: '{"result":{"counts":[],"since":86400},"status":"OK"} + string: '{"has_more":false,"limit":50,"result":[{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":"2026-08-25T18:23:58.370832+00:00","livescan_id":"72927285313305230","modified":"2026-08-25T18:23:58.358140+00:00","name":"test_rules","new_results_count":null,"new_results_counted_at":null,"rule_count":1,"yara":null}],"status":"OK"} ' headers: @@ -512,11 +513,11 @@ interactions: connection: - keep-alive content-length: - - '53' + - '461' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:24:00 GMT server: - gunicorn x-billing-id: @@ -540,7 +541,7 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/live/list?livescan_id=11956831134597871&community=gamma + uri: http://ai:9696/v3/hunt/rule/list?has_new_results=1&community=gamma response: body: string: '' @@ -554,14 +555,50 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:24:00 GMT server: - gunicorn status: code: 204 message: NO CONTENT - request: - body: '{"rule_id":"71359438369584055"}' + body: '' + headers: + accept: + - '*/*' + accept-encoding: + - gzip, deflate + authorization: + - '11111111111111111111111111111111' + connection: + - keep-alive + host: + - ai:9696 + user-agent: + - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) + method: GET + uri: http://ai:9696/v3/hunt/live/list?livescan_id=72927285313305230&community=gamma + response: + body: + string: '' + headers: + access-control-allow-origin: + - '*' + access-control-expose-headers: + - Authorization + connection: + - keep-alive + content-type: + - text/html; charset=utf-8 + date: + - Tue, 25 Aug 2026 18:24:00 GMT + server: + - gunicorn + status: + code: 204 + message: NO CONTENT +- request: + body: '{"rule_id":"46961337172843885"}' headers: accept: - '*/*' @@ -583,7 +620,7 @@ interactions: uri: http://ai:9696/v3/hunt/rule/live response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:49.650762+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":0,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:00.810701+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -599,7 +636,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:24:00 GMT server: - gunicorn x-billing-id: @@ -637,14 +674,14 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 14:29:49 GMT + - Tue, 25 Aug 2026 18:24:01 GMT server: - gunicorn status: code: 204 message: NO CONTENT - request: - body: '{"rule_id":"71359438369584055","community":"gamma"}' + body: '{"rule_id":"46961337172843885","community":"gamma"}' headers: accept: - '*/*' @@ -666,7 +703,7 @@ interactions: uri: http://ai:9696/v3/hunt/historical response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":null,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:01.406656+00:00","failed_max_retries":0,"failed_other":0,"id":"64777357306306635","progress":null,"results_csv_uri":null,"rule_id":"46961337172843885","rule_modified":"2026-08-25T18:24:00.810701+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -678,11 +715,11 @@ interactions: connection: - keep-alive content-length: - - '560' + - '561' content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:01 GMT server: - gunicorn x-billing-id: @@ -706,10 +743,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/rule?id=71359438369584055&community=gamma + uri: http://ai:9696/v3/hunt/rule?id=46961337172843885&community=gamma response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:49.650762+00:00","name":"test_rules","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":null,"favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:00.810701+00:00","name":"test_rules","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -725,7 +762,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:01 GMT server: - gunicorn x-billing-id: @@ -749,10 +786,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=90800113038824882&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=64777357306306635&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:01.406656+00:00","failed_max_retries":0,"failed_other":0,"id":"64777357306306635","progress":null,"results_csv_uri":null,"rule_id":"46961337172843885","rule_modified":"2026-08-25T18:24:00.810701+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -768,7 +805,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:02 GMT server: - gunicorn x-billing-id: @@ -792,10 +829,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=90800113038824882&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=64777357306306635&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:01.406656+00:00","failed_max_retries":0,"failed_other":0,"id":"64777357306306635","progress":null,"results_csv_uri":null,"rule_id":"46961337172843885","rule_modified":"2026-08-25T18:24:00.810701+00:00","ruleset_name":"test_rules","source_rule_changed":false,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -811,7 +848,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:02 GMT server: - gunicorn x-billing-id: @@ -840,10 +877,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: PUT - uri: http://ai:9696/v3/hunt/rule?id=71359438369584055 + uri: http://ai:9696/v3/hunt/rule?id=46961337172843885 response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:50.635991+00:00","name":"test_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":false,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:02.939069+00:00","name":"test_rules2","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }\n// edited"},"status":"OK"} ' @@ -859,7 +896,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:03 GMT server: - gunicorn x-billing-id: @@ -883,10 +920,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: GET - uri: http://ai:9696/v3/hunt/historical?id=90800113038824882&community=gamma + uri: http://ai:9696/v3/hunt/historical?id=64777357306306635&community=gamma response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:01.406656+00:00","failed_max_retries":0,"failed_other":0,"id":"64777357306306635","progress":null,"results_csv_uri":null,"rule_id":"46961337172843885","rule_modified":"2026-08-25T18:24:00.810701+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"PENDING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -902,7 +939,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:03 GMT server: - gunicorn x-billing-id: @@ -930,10 +967,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/historical?id=90800113038824882 + uri: http://ai:9696/v3/hunt/historical?id=64777357306306635 response: body: - string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-21T14:29:50.251832+00:00","failed_max_retries":0,"failed_other":0,"id":"90800113038824882","progress":null,"results_csv_uri":null,"rule_id":"71359438369584055","rule_modified":"2026-08-21T14:29:49.650762+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule + string: '{"result":{"account_number":"111","archives_in_flight":0,"archives_scanned":0,"archives_total":0,"communities":["gamma"],"created":"2026-08-25T18:24:01.406656+00:00","failed_max_retries":0,"failed_other":0,"id":"64777357306306635","progress":null,"results_csv_uri":null,"rule_id":"46961337172843885","rule_modified":"2026-08-25T18:24:00.810701+00:00","ruleset_name":"test_rules","source_rule_changed":true,"status":"DELETING","summary":null,"user_account_number":"111","yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }"},"status":"OK"} ' @@ -949,7 +986,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:03 GMT server: - gunicorn x-billing-id: @@ -977,10 +1014,10 @@ interactions: user-agent: - polyswarm_api/4.3.0 (x86_64-Darwin-CPython-3.11.3) method: DELETE - uri: http://ai:9696/v3/hunt/rule?id=71359438369584055 + uri: http://ai:9696/v3/hunt/rule?id=46961337172843885 response: body: - string: '{"result":{"created":"2026-08-21T14:29:48.738607+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"71359438369584055","livescan_created":null,"livescan_id":null,"modified":"2026-08-21T14:29:50.839329+00:00","name":"test_rules2","rule_count":1,"yara":"rule + string: '{"result":{"created":"2026-08-25T18:23:50.641609+00:00","deleted":true,"description":"test","favorite":false,"favorited_at":null,"historical_hunt_count":1,"id":"46961337172843885","livescan_created":null,"livescan_id":null,"modified":"2026-08-25T18:24:03.962187+00:00","name":"test_rules2","rule_count":1,"yara":"rule sdk_test_rules { strings: $u = \"test_rules\" condition: $u }\n// edited"},"status":"OK"} ' @@ -996,7 +1033,7 @@ interactions: content-type: - application/json date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:04 GMT server: - gunicorn x-billing-id: @@ -1034,7 +1071,7 @@ interactions: content-type: - text/html; charset=utf-8 date: - - Fri, 21 Aug 2026 14:29:50 GMT + - Tue, 25 Aug 2026 18:24:04 GMT server: - gunicorn status: From 2cc5e80c681e780c26cffc9bf9f6c612ac4d8f1d Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:30:38 -0300 Subject: [PATCH 15/36] fix(live-feed): since is minutes, and add an optional max_results MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The docstring said SECONDS and claimed the server was tightening the parameter to `is not None` so that since=0 would mean an empty window. No such change was ever made, and the opposite is the contract: the server applies the filter on a truthiness test, so absent-or-0 means no time filter at all and the feed pages over everything. The unit is now minutes on the wire, which is a break worth naming — a caller passing an explicit since in seconds gets a 60x wider window, silently — so specs/05 records it as a behaviour change rather than a documentation correction, for the develop -> master bump decision. max_results is additive and defaults to None, the historical behaviour: every page, up to the client's page cap. It bounds the yielded count and sizes the page request via core.page_size_for, so a small ask does not fetch a full default page. The bound is client-side by nature — the server has never served an unbounded query, it caps every page; this client is what follows cursors until has_more clears. page_size_for lives in core.py: pure, shared by both transports, and not unasync-processed, so there is exactly one copy. Sync mirror regenerated. --- specs/05-downstream-contract.md | 39 +++++++++++++++++++++++---------- src/polyswarm_api/aio/api.py | 22 ++++++++++++------- src/polyswarm_api/api.py | 20 ++++++++++++----- src/polyswarm_api/core.py | 18 +++++++++++++++ 4 files changed, 73 insertions(+), 26 deletions(-) diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 48856dfb..9d5d10fe 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -301,18 +301,33 @@ Migrating from 3.x to 4.0, callers retain: ## Backward compatibility — what changes -### Documentation corrections that read like behaviour changes - -- **`live_feed(since=)` was always SECONDS.** The 3.x/4.x docstring said - "minutes", but the server has always converted the parameter with - `timedelta(seconds=since)` — the docstring was corrected, not the wire. A - caller who read the old docstring and passed `60` meaning an hour was - already getting a minute; nothing changed underneath them. Relatedly, the - server is tightening the parameter from a truthiness test to `is not None`, - so `since=0` moves from "all time" to "an empty window" — that one IS a - server-side behaviour change, noted here so the `develop → master` bump - decision sees it (the SDK is a passthrough; no major bump forced from this - side). +### Behaviour changes + +- **`live_feed(since=)` is now MINUTES, and it is a wire fix, not a doc fix.** + The 3.x/4.x docstring said "minutes" while the server converted with + `timedelta(seconds=since)`, so a caller who read the docstring and passed + `60` meaning an hour got a minute. Every surface around the parameter was + written for minutes — the CLI's `1440` default is `24 * 60` — so the server + was corrected to read minutes rather than the callers being corrected to + send seconds. **This is a break**: a caller passing an explicit `since` in + seconds now gets a 60x wider window, silently. Nobody loses data — they get + more — but it is a behaviour change the `develop → master` bump decision + should see, not a documentation correction. + + **`since` absent or `0` means no time filter at all** — the feed pages over + everything. That is the server's contract (it applies the filter on a + truthiness test), and it is what a caller wanting the full history relies + on. An earlier revision of this document claimed the server was tightening + this to `is not None` so that `since=0` would mean an empty window: no such + change was ever made, and the opposite is the intended semantics. + +- **`live_feed(max_results=)` is new and additive.** It defaults to `None`, + which is the historical behaviour — every page, up to the client's page cap. + Set it to bound a read; it also sizes the page request (`core.page_size_for`), + so a small ask does not fetch a full default page. Worth knowing that the + server has never served an unbounded query — it caps every page — while this + client follows cursors until `has_more` clears, so the bound this offers is + a client-side one. ### Required code changes diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index ed06f815..665d0e54 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -18,7 +18,7 @@ import time from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest +from polyswarm_api.core import PolyswarmRequest, page_size_for from .session import AsyncPolyswarmSession @@ -503,29 +503,35 @@ async def live_stop(self, rule_id): async def live_feed(self, since=None, rule_name=None, family=None, polyscore_lower=None, polyscore_upper=None, community=None, - livescan_id=None): + livescan_id=None, max_results=None): """ Get live hunts feed - :param since: Window in SECONDS (the server converts it with - timedelta(seconds=since); it previously documented minutes here, - but the server never read minutes). The server is also tightening - the parameter from a truthiness test to `is not None`, so since=0 - means an empty window, not "all time". + :param since: Window in MINUTES. Absent or 0 means NO time filter at + all — the feed pages over everything, which is what a caller + wanting the full history asks for. :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). :param polyscore_lower: Polyscore lower bound for the hunt results. :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. + :param max_results: Stop after this many results. Default None keeps the + previous behaviour — every page, up to the client's page cap. Set it + when you want a bounded read; it also sizes the page request, so a + small ask fetches a small page. :return: Generator of HuntResult resources """ + yielded = 0 async for item in self._paginate(resources.LiveHuntResult.list( self, since=since, rule_name=rule_name, family=family, polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, - livescan_id=livescan_id, + livescan_id=livescan_id, limit=page_size_for(max_results), community=community or self.community)): yield item + yielded += 1 + if max_results is not None and yielded >= max_results: + return async def live_feed_delete(self, result_ids): """ diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index a085b43e..baecd6f9 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -20,7 +20,7 @@ import logging from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest +from polyswarm_api.core import PolyswarmRequest, page_size_for from .session import PolyswarmSession @@ -569,23 +569,27 @@ def live_feed( polyscore_upper=None, community=None, livescan_id=None, + max_results=None, ): """ Get live hunts feed - :param since: Window in SECONDS (the server converts it with - timedelta(seconds=since); it previously documented minutes here, - but the server never read minutes). The server is also tightening - the parameter from a truthiness test to `is not None`, so since=0 - means an empty window, not "all time". + :param since: Window in MINUTES. Absent or 0 means NO time filter at + all — the feed pages over everything, which is what a caller + wanting the full history asks for. :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). :param polyscore_lower: Polyscore lower bound for the hunt results. :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. + :param max_results: Stop after this many results. Default None keeps the + previous behaviour — every page, up to the client's page cap. Set it + when you want a bounded read; it also sizes the page request, so a + small ask fetches a small page. :return: Generator of HuntResult resources """ + yielded = 0 for item in self._paginate( resources.LiveHuntResult.list( self, @@ -595,10 +599,14 @@ def live_feed( polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, livescan_id=livescan_id, + limit=page_size_for(max_results), community=community or self.community, ) ): yield item + yielded += 1 + if max_results is not None and yielded >= max_results: + return def live_feed_delete(self, result_ids): """ diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index f6e43f44..465a4d93 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -668,6 +668,24 @@ def list(cls, api, **kwargs): ) +# The server caps a page at AI_MAX_QUERY_RESULTS and defaults to +# AI_DEFAULT_PAGE_SIZE; it has never served an unbounded query. What is +# unbounded is the client, which follows cursors until has_more clears. A +# caller asking for N results therefore only needs a page big enough to hold +# them, and never more than the server would grant anyway. +MAX_PAGE_SIZE = 1000 + + +def page_size_for(max_results): + """Page size to request for a bounded read, or None to take the default. + + ``None`` means "no bound" — the historical behaviour, every page. + """ + if not max_results: + return None + return min(max_results, MAX_PAGE_SIZE) + + # ── Hash helpers ─────────────────────────────────────────────────── From d150860db32fa72dfc85091c50ca9a0536476bdf Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:30:39 -0300 Subject: [PATCH 16/36] docs(specs): narrow the stale live-hunt open question MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It said live_start never gets a livescan_id on the local e2e stack. The rules tests now assert the opposite as a hard contract and test/vcr/test_rules.vcr records a real one. What is still true is that no microengines process submissions, so the feed stays empty — which is what the zero-result feed check in those tests rests on. --- specs/99-open-questions.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/specs/99-open-questions.md b/specs/99-open-questions.md index 5e1fb91c..6655405a 100644 --- a/specs/99-open-questions.md +++ b/specs/99-open-questions.md @@ -150,7 +150,9 @@ This is environment, not bug — but it does mean the test can't be hermetic wit ### 2. `live` (sync + async) — requires the bounty / microengine pipeline -`live_start` returns a `LiveYaraRuleset` with `livescan_id=None` because the local e2e has no microengines processing submissions. The lifecycle calls (`ruleset_create`, `live_start`, `live_stop`) all return 200, but the feed never receives results and `livescan_id` doesn't get assigned. Same shape as #1 — environment, not bug. +The local e2e has no microengines processing submissions, so a live hunt never receives results and its feed stays empty — which is why the rules tests assert a zero-result `livescan_id` feed rather than a populated one. Same shape as #1 — environment, not bug. + +(This previously said `livescan_id` itself is never assigned. That is no longer true and may never have been: `live_start` does get a `livescan_id`, the rules tests now assert it as a hard contract, and `test/vcr/test_rules.vcr` records a real one. Only the *results* are missing on this stack.) ## What works (the other 42 cassettes) From 8f8e4d3cf6c336a8857cfb1463e95e11df83e79d Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:30:40 -0300 Subject: [PATCH 17/36] test(rules): assert the list filters universally, not by presence MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `rule.id in by_name` and `any(... and r.favorite ...)` both hold if the server ignored the query param and returned the unfiltered list — which is the regression an SDK-side filter test exists to catch, and the one most likely when the paired server change lands. Both arms now assert over every row. No re-record: the recorded responses already satisfy the stronger form. --- test/async_client_test.py | 10 +++++++--- test/client_scan_test.py | 12 +++++++++--- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/test/async_client_test.py b/test/async_client_test.py index 479102e4..0ae87b45 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -627,8 +627,11 @@ async def test_async_rules(self, uid): # a presence assertion instead of an exact count. rules = [r async for r in api.ruleset_list()] assert any(r.id == rule.id for r in rules) - by_name = [r.id async for r in api.ruleset_list(name=uid)] - assert rule.id in by_name + # Universal arms, not presence-only — an ignored param would + # pass the membership check alone (F9). + by_name = [r async for r in api.ruleset_list(name=uid)] + assert rule.id in {r.id for r in by_name} + assert all(uid.lower() in (r.name or '').lower() for r in by_name) got = await api.ruleset_get(rule.id) assert got.name == uid @@ -642,7 +645,8 @@ async def test_async_rules(self, uid): assert fav.favorites_limit == 5 assert 1 <= fav.favorites_used <= fav.favorites_limit favorites = [r async for r in api.ruleset_list(favorites_only=True)] - assert any(r.id == rule.id and r.favorite for r in favorites) + assert any(r.id == rule.id for r in favorites) + assert all(r.favorite for r in favorites) # unstarring here is the CONTRACT assertion; slot hygiene does # not depend on reaching it — the finally's ruleset_delete # soft-deletes and the budget counts only deleted=false rows diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 6111070a..084f42b3 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -594,8 +594,13 @@ def test_rules(self): rules = list(api.ruleset_list()) assert any(r.id == rule.id for r in rules) # the name filter narrows to this test's own rule - by_name = [r.id for r in api.ruleset_list(name=uid)] - assert rule.id in by_name + # Both arms are UNIVERSAL, not presence-only: `rule.id in by_name` + # holds identically if the server ignored the param and returned + # the unfiltered list, which is exactly the regression a filter + # test exists to catch (F9). + by_name = list(api.ruleset_list(name=uid)) + assert rule.id in {r.id for r in by_name} + assert all(uid.lower() in (r.name or '').lower() for r in by_name) # getting got = api.ruleset_get(rule.id) assert got.name == uid @@ -608,7 +613,8 @@ def test_rules(self): assert fav.favorites_limit == 5 assert 1 <= fav.favorites_used <= fav.favorites_limit favorites = list(api.ruleset_list(favorites_only=True)) - assert any(r.id == rule.id and r.favorite for r in favorites) + assert any(r.id == rule.id for r in favorites) + assert all(r.favorite for r in favorites) # unstarring here is the CONTRACT assertion; slot hygiene does not # depend on reaching it — the finally's ruleset_delete soft-deletes # and the server's budget counts only deleted=false rows, so a From fd0afc3b1a2f4ca8b71b716c01b661d6db9f5894 Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:33:29 -0300 Subject: [PATCH 18/36] test(live-feed): pin the max_results bound and its page sizing Truncation and page-size selection are both decisions the code now makes and neither had a test. Pinned in the pure-unit tier: producing more feed rows than a page holds on the shared e2e stack would mean generating real live-hunt volume, and _paginate is the seam that would otherwise keep following cursors. --- test/hunt_tracking_builder_test.py | 49 +++++++++++++++++++++++++++++- 1 file changed, 48 insertions(+), 1 deletion(-) diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index 4d892782..db64cdd1 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -18,7 +18,8 @@ Endpoint *behaviour* is covered by the live-e2e VCR lifecycle tests (``test_rules`` / ``test_async_rules``). """ -from polyswarm_api import resources +from polyswarm_api import core, resources +from polyswarm_api.api import PolyswarmAPI class _FakeApi: @@ -126,3 +127,49 @@ def test_list_routes_livescan_id_to_the_query_as_digit_string(self): assert req.url == 'https://api.example.test/hunt/live/list' assert req.params == {'since': 60, 'livescan_id': '45392847561029383', 'community': 'gamma'} + +class TestPageSizeForBound: + """``core.page_size_for`` — the page a bounded read should ask for. + + The server caps a page itself and has never served an unbounded query; what + is unbounded is this client, which follows cursors until ``has_more`` + clears. So a caller asking for N needs a page big enough to hold N, and + never more than the server would grant anyway.""" + + def test_no_bound_takes_the_server_default(self): + # None is the historical behaviour — every page, server-sized. + assert core.page_size_for(None) is None + # 0 is not a bound either; it would otherwise ask for a zero-row page. + assert core.page_size_for(0) is None + + def test_a_small_bound_asks_for_a_small_page(self): + assert core.page_size_for(5) == 5 + + def test_a_large_bound_is_clamped_to_what_the_server_grants(self): + assert core.page_size_for(10_000) == core.MAX_PAGE_SIZE + + +class TestLiveFeedMaxResults: + """``live_feed(max_results=)`` stops the generator at the bound. + + Pinned here rather than against the stack: producing more feed rows than a + page holds on the shared e2e stack would mean generating real live-hunt + volume. ``_paginate`` is the seam — it is what would otherwise keep + following cursors — so it is what this stands in for.""" + + @staticmethod + def _api_yielding(count): + api = PolyswarmAPI.__new__(PolyswarmAPI) + api.uri = _FakeApi.uri + api.community = _FakeApi.community + api._paginate = lambda *a, **kw: iter(range(count)) + return api + + def test_unbounded_by_default_yields_everything(self): + assert list(self._api_yielding(7).live_feed()) == list(range(7)) + + def test_the_bound_truncates(self): + assert list(self._api_yielding(7).live_feed(max_results=3)) == [0, 1, 2] + + def test_a_bound_larger_than_the_feed_is_not_padding(self): + assert list(self._api_yielding(2).live_feed(max_results=9)) == [0, 1] From 477f56b82c8a91d55c04a8ad7c1c786adad3f04a Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:37:29 -0300 Subject: [PATCH 19/36] fix(live-feed): max_results=0 means no bound, not a bound of one The truncation tested `is not None` while page_size_for treats 0 as no bound, so max_results=0 asked for a server-default page and then stopped after the first result. 0 now means no bound on both halves, which is also what `since` means by 0 on the same call. --- src/polyswarm_api/aio/api.py | 15 ++++++++++----- src/polyswarm_api/api.py | 15 ++++++++++----- test/hunt_tracking_builder_test.py | 7 +++++++ 3 files changed, 27 insertions(+), 10 deletions(-) diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index 665d0e54..2a096446 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -516,10 +516,10 @@ async def live_feed(self, since=None, rule_name=None, family=None, :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. - :param max_results: Stop after this many results. Default None keeps the - previous behaviour — every page, up to the client's page cap. Set it - when you want a bounded read; it also sizes the page request, so a - small ask fetches a small page. + :param max_results: Stop after this many results. None or 0 means no + bound — the previous behaviour, every page up to the client's page + cap. Set it for a bounded read; it also sizes the page request, so + a small ask fetches a small page. :return: Generator of HuntResult resources """ yielded = 0 @@ -530,7 +530,12 @@ async def live_feed(self, since=None, rule_name=None, family=None, community=community or self.community)): yield item yielded += 1 - if max_results is not None and yielded >= max_results: + # Truthiness, NOT `is not None`: 0 means no bound, the same + # answer page_size_for gives it and the same convention `since` + # uses on this call. `is not None` here would make + # max_results=0 yield exactly one result — the two halves of + # the bound disagreeing. + if max_results and yielded >= max_results: return async def live_feed_delete(self, result_ids): diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index baecd6f9..09594c26 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -583,10 +583,10 @@ def live_feed( :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. - :param max_results: Stop after this many results. Default None keeps the - previous behaviour — every page, up to the client's page cap. Set it - when you want a bounded read; it also sizes the page request, so a - small ask fetches a small page. + :param max_results: Stop after this many results. None or 0 means no + bound — the previous behaviour, every page up to the client's page + cap. Set it for a bounded read; it also sizes the page request, so + a small ask fetches a small page. :return: Generator of HuntResult resources """ yielded = 0 @@ -605,7 +605,12 @@ def live_feed( ): yield item yielded += 1 - if max_results is not None and yielded >= max_results: + # Truthiness, NOT `is not None`: 0 means no bound, the same + # answer page_size_for gives it and the same convention `since` + # uses on this call. `is not None` here would make + # max_results=0 yield exactly one result — the two halves of + # the bound disagreeing. + if max_results and yielded >= max_results: return def live_feed_delete(self, result_ids): diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index db64cdd1..c972b81e 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -173,3 +173,10 @@ def test_the_bound_truncates(self): def test_a_bound_larger_than_the_feed_is_not_padding(self): assert list(self._api_yielding(2).live_feed(max_results=9)) == [0, 1] + + def test_zero_is_no_bound_not_a_bound_of_one(self): + # 0 has to mean the same thing here as it does in page_size_for and in + # `since` on this same call: no bound. Testing `is not None` instead of + # truthiness makes max_results=0 yield exactly one result, which is the + # two halves of the bound disagreeing. + assert list(self._api_yielding(7).live_feed(max_results=0)) == list(range(7)) From 041b2c51dd5b261a544b8e21145e51135b71f976 Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:47:53 -0300 Subject: [PATCH 20/36] fix(live-feed): one definition of a result bound, and pin it to the wire MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit max_results read 0 two contradictory ways: page_size_for treated falsy as unbounded while the generator tested `is not None`, so max_results=0 asked for a full server-default page and then stopped after one row. Negatives were worse — page_size_for returned -1, which would have put limit=-1 on the wire and the server answers that with nothing. as_result_bound is now the single definition (None/0/negative -> no bound) and both halves read it, so they cannot disagree again. The bound and the page it implies stay separate numbers on purpose: a caller asking for 5000 gets 1000-row pages and still stops at 5000. Also pins the wiring itself. The truncation tests replace _paginate wholesale, so the descriptor was never built and dropping `limit=page_size_for(...)` entirely kept every test green; TestLiveFeedLimitOnTheWire fails without it (verified), and asserts the unbounded case sends no limit at all, which is what keeps the default request byte-compatible with the recorded cassettes. specs/01, specs/03 and specs/05 pick up the new core symbols, the MINUTES unit and the absent-or-0 contract — specs/03 still documented SECONDS, contradicting the docstrings and specs/05 inside the same change. --- specs/01-architecture.md | 2 +- specs/03-endpoints.md | 2 +- specs/05-downstream-contract.md | 4 ++ src/polyswarm_api/aio/api.py | 23 +++++----- src/polyswarm_api/api.py | 23 +++++----- src/polyswarm_api/core.py | 24 +++++++++-- test/hunt_tracking_builder_test.py | 67 ++++++++++++++++++++++++++++++ 7 files changed, 115 insertions(+), 30 deletions(-) diff --git a/specs/01-architecture.md b/specs/01-architecture.md index 8005ba7c..868d7ad8 100644 --- a/specs/01-architecture.md +++ b/specs/01-architecture.md @@ -42,7 +42,7 @@ Hand-written. No I/O. Three sub-concerns: **Resource bases**: `BaseResource`, `BaseJsonResource`. The latter has classmethod builders (`create` / `get` / `head` / `update` / `delete` / `list`) that each return a `PolyswarmRequest` descriptor. Per-domain resources in `resources.py` inherit from `BaseJsonResource` and may add custom classmethods (`ArtifactInstance.search_hash`, `IOC.iocs_by_hash`, etc.) — all returning descriptors. -**Helpers**: `Hashable` + `Hash` + `is_valid_sha1/sha256/md5`, `parse_isoformat`, `_normalise_bool_params`, `RequestParamsEncoder`, `_raise_for_status` (the shared non-2xx → typed-exception mapper, used by both `parse_response` and the session's streaming-download path). Downloads stream straight to their destination from the session — there is no response adapter; see [`99-open-questions.md`](./99-open-questions.md) §"Streaming downloads". +**Helpers**: `Hashable` + `Hash` + `is_valid_sha1/sha256/md5`, `parse_isoformat`, `_normalise_bool_params`, `RequestParamsEncoder`, `as_result_bound` + `page_size_for` + `MAX_PAGE_SIZE` (the one definition of a caller's result bound and the page it implies, shared by both transports), `_raise_for_status` (the shared non-2xx → typed-exception mapper, used by both `parse_response` and the session's streaming-download path). Downloads stream straight to their destination from the session — there is no response adapter; see [`99-open-questions.md`](./99-open-questions.md) §"Streaming downloads". ### Layer 2 — transport (`session.py` / `aio/session.py`) diff --git a/specs/03-endpoints.md b/specs/03-endpoints.md index ec4837d7..5c7fdee9 100644 --- a/specs/03-endpoints.md +++ b/specs/03-endpoints.md @@ -187,7 +187,7 @@ refusal. | `iocs_by_hash(hash_type, hash_value, hide_known_good=False, beta=False)` | `IOC.iocs_by_hash` | | `search_by_ioc(ip=None, domain=None, ttp=None, imphash=None)` | `IOC.ioc_search` | | `check_known_hosts(ips=[], domains=[])` | `IOC.check_known_hosts` | -| `live_feed(since=None, …, livescan_id=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in SECONDS (the server converts with `timedelta(seconds=since)`) | +| `live_feed(since=None, …, livescan_id=None, max_results=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in **MINUTES**, and absent-or-`0` means no time filter at all (the server applies it on a truthiness test); `max_results` bounds the read — `None`/`0`/negative means no bound, and it also sizes the page request via `core.page_size_for`. The `since` unit is a **behaviour change**, not a doc correction — see [05-downstream-contract.md](./05-downstream-contract.md) §Behaviour changes | | `historical_list(since=None)` | `HistoricalHunt.list` | | `historical_results(hunt=None, …)` | `HistoricalHuntResultList.get` | | `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract. `has_new_results` selects on the server's STORED counter (no window parameter — the window belongs to the server's scheduled refresh; rows carry `new_results_count` + `new_results_counted_at`) | diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 9d5d10fe..365113e1 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -134,6 +134,10 @@ class Hashable: ... class Hash(Hashable): ... def is_valid_sha1 / _sha256 / _md5(value) -> bool def parse_isoformat(date_string) + +MAX_PAGE_SIZE: int # the largest page the server will grant +def as_result_bound(max_results) # None / 0 / negative -> None (no bound) +def page_size_for(max_results) # the page a bounded read should request ``` These are stable but less curated than the top-level exports. Downstream callers that subclass `BaseJsonResource` to add custom resource types are supported. Downstream callers that construct `PolyswarmRequest` manually and hand it to `session.execute` are supported. diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index 2a096446..3943c91f 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -18,7 +18,7 @@ import time from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest, page_size_for +from polyswarm_api.core import PolyswarmRequest, as_result_bound, page_size_for from .session import AsyncPolyswarmSession @@ -516,26 +516,25 @@ async def live_feed(self, since=None, rule_name=None, family=None, :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. - :param max_results: Stop after this many results. None or 0 means no - bound — the previous behaviour, every page up to the client's page - cap. Set it for a bounded read; it also sizes the page request, so - a small ask fetches a small page. + :param max_results: Stop after this many results. None, 0 or a negative + means no bound — the previous behaviour, every page up to the + client's page cap. Set it for a bounded read; it also sizes the + page request, so a small ask fetches a small page. :return: Generator of HuntResult resources """ + # One normalised bound drives both halves — the page we ask for and + # the point we stop — so they cannot disagree about whether there is + # a bound at all (0 and negatives mean there is not). + bound = as_result_bound(max_results) yielded = 0 async for item in self._paginate(resources.LiveHuntResult.list( self, since=since, rule_name=rule_name, family=family, polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, - livescan_id=livescan_id, limit=page_size_for(max_results), + livescan_id=livescan_id, limit=page_size_for(bound), community=community or self.community)): yield item yielded += 1 - # Truthiness, NOT `is not None`: 0 means no bound, the same - # answer page_size_for gives it and the same convention `since` - # uses on this call. `is not None` here would make - # max_results=0 yield exactly one result — the two halves of - # the bound disagreeing. - if max_results and yielded >= max_results: + if bound is not None and yielded >= bound: return async def live_feed_delete(self, result_ids): diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 09594c26..690f43fd 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -20,7 +20,7 @@ import logging from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest, page_size_for +from polyswarm_api.core import PolyswarmRequest, as_result_bound, page_size_for from .session import PolyswarmSession @@ -583,12 +583,16 @@ def live_feed( :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. - :param max_results: Stop after this many results. None or 0 means no - bound — the previous behaviour, every page up to the client's page - cap. Set it for a bounded read; it also sizes the page request, so - a small ask fetches a small page. + :param max_results: Stop after this many results. None, 0 or a negative + means no bound — the previous behaviour, every page up to the + client's page cap. Set it for a bounded read; it also sizes the + page request, so a small ask fetches a small page. :return: Generator of HuntResult resources """ + # One normalised bound drives both halves — the page we ask for and + # the point we stop — so they cannot disagree about whether there is + # a bound at all (0 and negatives mean there is not). + bound = as_result_bound(max_results) yielded = 0 for item in self._paginate( resources.LiveHuntResult.list( @@ -599,18 +603,13 @@ def live_feed( polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, livescan_id=livescan_id, - limit=page_size_for(max_results), + limit=page_size_for(bound), community=community or self.community, ) ): yield item yielded += 1 - # Truthiness, NOT `is not None`: 0 means no bound, the same - # answer page_size_for gives it and the same convention `since` - # uses on this call. `is not None` here would make - # max_results=0 yield exactly one result — the two halves of - # the bound disagreeing. - if max_results and yielded >= max_results: + if bound is not None and yielded >= bound: return def live_feed_delete(self, result_ids): diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index 465a4d93..4760af0b 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -676,14 +676,30 @@ def list(cls, api, **kwargs): MAX_PAGE_SIZE = 1000 +def as_result_bound(max_results): + """The caller's result bound, or None when there isn't one. + + ``None``, ``0`` and negatives all mean "no bound" — the historical + behaviour, every page. Stated ONCE so the page size and the generator's + stop condition cannot disagree about what counts as a bound. They did + once: ``0`` asked for a full server-default page and then stopped after + a single row, because one half tested truthiness and the other tested + ``is not None``.""" + if not max_results or max_results < 0: + return None + return max_results + + def page_size_for(max_results): """Page size to request for a bounded read, or None to take the default. - ``None`` means "no bound" — the historical behaviour, every page. - """ - if not max_results: + Clamped to what the server would grant anyway. Note this is NOT the bound + itself — a caller asking for 5000 gets 1000-row pages and still stops at + 5000 — so the two are computed separately from one normalised value.""" + bound = as_result_bound(max_results) + if bound is None: return None - return min(max_results, MAX_PAGE_SIZE) + return min(bound, MAX_PAGE_SIZE) # ── Hash helpers ─────────────────────────────────────────────────── diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index c972b81e..41d13075 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -141,6 +141,20 @@ def test_no_bound_takes_the_server_default(self): assert core.page_size_for(None) is None # 0 is not a bound either; it would otherwise ask for a zero-row page. assert core.page_size_for(0) is None + # nor is a negative, which would otherwise put limit=-1 on the wire + # and the server would answer with nothing. + assert core.page_size_for(-1) is None + + def test_the_bound_and_the_page_are_normalised_the_same_way(self): + # The two used to disagree about what counts as a bound at all, which + # is how max_results=0 asked for a full page and then stopped after + # one row. One definition now answers both. + for no_bound in (None, 0, -1): + assert core.as_result_bound(no_bound) is None + assert core.page_size_for(no_bound) is None + # a real bound is NOT clamped away — only the page it implies is + assert core.as_result_bound(10_000) == 10_000 + assert core.page_size_for(10_000) == core.MAX_PAGE_SIZE def test_a_small_bound_asks_for_a_small_page(self): assert core.page_size_for(5) == 5 @@ -174,9 +188,62 @@ def test_the_bound_truncates(self): def test_a_bound_larger_than_the_feed_is_not_padding(self): assert list(self._api_yielding(2).live_feed(max_results=9)) == [0, 1] + def test_a_negative_bound_is_no_bound(self): + assert list(self._api_yielding(4).live_feed(max_results=-1)) == list(range(4)) + def test_zero_is_no_bound_not_a_bound_of_one(self): # 0 has to mean the same thing here as it does in page_size_for and in # `since` on this same call: no bound. Testing `is not None` instead of # truthiness makes max_results=0 yield exactly one result, which is the # two halves of the bound disagreeing. assert list(self._api_yielding(7).live_feed(max_results=0)) == list(range(7)) + +class TestLiveFeedLimitOnTheWire: + """``max_results`` must actually SIZE the request, not just truncate. + + The truncation tests replace ``_paginate`` wholesale, so the descriptor is + never built and dropping the ``limit`` argument entirely would keep them all + green. This is the assertion that fails if the wiring goes away — and the + unbounded case pins that no ``limit`` is sent at all, which is what keeps the + default request byte-compatible with every recorded cassette.""" + + @staticmethod + def _params(**kwargs): + api = PolyswarmAPI.__new__(PolyswarmAPI) + api.uri = _FakeApi.uri + api.community = _FakeApi.community + captured = {} + + def capture(request, *a, **kw): + captured.update(request.params) + return iter(()) + + api._paginate = capture + list(api.live_feed(**kwargs)) + return captured + + def test_a_bound_sizes_the_page(self): + assert self._params(max_results=5)['limit'] == 5 + + def test_a_large_bound_asks_only_for_what_the_server_grants(self): + assert self._params(max_results=10_000)['limit'] == core.MAX_PAGE_SIZE + + def test_no_bound_sends_no_limit_at_all(self): + for no_bound in ({}, {'max_results': 0}, {'max_results': -1}): + assert 'limit' not in self._params(**no_bound) + + +class TestLiveFeedSinceOnTheWire: + """``since=0`` has to REACH the server to mean what it means. + + The contract is that absent-or-0 applies no time filter, and the server + implements it with a truthiness test. That only holds because ``_params`` + drops ``None`` and not ``0``: were falsy values dropped, ``since=0`` and + ``since=5`` would build the same request and the parameter would be + unusable for anything but its default.""" + + def test_zero_is_sent_and_absent_is_omitted(self): + sent = resources.LiveHuntResult.list(_FakeApi(), since=0, community='gamma') + assert sent.params['since'] == 0 + omitted = resources.LiveHuntResult.list(_FakeApi(), since=None, community='gamma') + assert 'since' not in omitted.params From 989ab1480e96970e10427bfb2d684a03731c91c8 Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 21:59:45 -0300 Subject: [PATCH 21/36] fix(test): scope the long-pole hint, and pin the explicit-False filter arm MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 'rules' is a prefix of 'ruleset', so the long-pole fragment also matched the instant ruleset_favorite respx suite and scheduled it ahead of real long poles. 'test_rules' matches only the two intended nodeids. Nothing covered an explicit favorites_only=False / has_new_results=False: they serialise to query 0 (core._params coerces bools before routing), and an inverted filter is the one failure mode that silently returns the wrong rows. Also records where MAX_PAGE_SIZE comes from — the server's AI_MAX_QUERY_RESULTS — and why it sits in core.py rather than settings.py. --- src/polyswarm_api/core.py | 4 ++++ test/conftest.py | 4 +++- test/hunt_tracking_builder_test.py | 18 ++++++++++++++++++ 3 files changed, 25 insertions(+), 1 deletion(-) diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index 4760af0b..62b5904a 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -673,6 +673,10 @@ def list(cls, api, **kwargs): # unbounded is the client, which follows cursors until has_more clears. A # caller asking for N results therefore only needs a page big enough to hold # them, and never more than the server would grant anyway. +# Mirrors the server's AI_MAX_QUERY_RESULTS (1000). Asking above it is a 400, +# not a silent truncation, so the clamp is what keeps a large bound usable. +# It lives here rather than in settings.py because it is a fact about the +# protocol that a pure helper needs, not a knob a caller tunes. MAX_PAGE_SIZE = 1000 diff --git a/test/conftest.py b/test/conftest.py index 041c6165..8868e403 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -121,7 +121,9 @@ async def _noop_async_sleep(*_a, **_k): "sample", # sandbox completion + metadata "stream", # global archiver batching "rescan", # rescan retry loop + settle - "rules", # test_rules / test_async_rules — live enable/stop + ~6 poll loops + "test_rules", # test_rules / test_async_rules — ruleset lifecycle polling + # (NOT "rules": that is a prefix of "ruleset" and would + # also match the instant ruleset_favorite respx suite) # test_rules / test_async_rules — live enable/stop + ~6 poll loops "hash_search", # search-index lag "existence_probe", # submit + settle + search-index lag (the HEAD probe tests) "sandboxtask", # sandbox completion + index lag diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index 41d13075..e1eac1fe 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -117,6 +117,24 @@ def test_ruleset_counters_absent_is_none_never_zero(self): assert row.historical_hunt_count is None +class TestRulesetListExplicitFalseFilters: + """An explicit ``False`` filter serialises to ``0`` on the query string. + + ``core._params`` coerces bools to ints before routing, so these land as + ``0`` rather than ``False``. The server's boolean argument parser accepts + exactly ``0``/``1``/``false``/``true`` and maps ``0`` to false, so an + explicit False really does mean unfiltered — but only the ``True`` and + omitted arms were covered, and an inverted filter is the one failure mode + that silently returns the wrong rows.""" + + def test_explicit_false_serialises_to_zero(self): + request = resources.YaraRuleset.list( + _FakeApi(), favorites_only=False, has_new_results=False, + community='gamma') + assert request.params['favorites_only'] == 0 + assert request.params['has_new_results'] == 0 + + class TestLiveFeedScopeBuilder: def test_list_routes_livescan_id_to_the_query_as_digit_string(self): # *_id kwargs stringify (core._params); the server casts back to int. From 2350cf880f4c6446ee0b2a671cc193c69e33476a Mon Sep 17 00:00:00 2001 From: Samuel Date: Thu, 27 Aug 2026 22:09:52 -0300 Subject: [PATCH 22/36] fix(test): match test_async_rules too, and pin the canonical async bound MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The long-pole fragment went from 'rules' to 'test_rules' to fix a false positive and introduced a false negative: 'test_async_rules' is test_ + async_rules, so the heaviest new test in the suite fell to the backfill tail. '_rules' matches both nodeids and still misses the respx suite, where the character before 'rules' is a slash. The replaced line also left its old trailing comment behind. Every max_results test drove the GENERATED sync mirror. The async for + yielded/return shape is the part unasync rewrites rather than copies, so the canonical loop had no coverage at all — verified the new tests fail when the canonical bound check alone is broken. --- test/conftest.py | 8 +++-- test/hunt_tracking_builder_test.py | 52 ++++++++++++++++++++++++++++++ 2 files changed, 57 insertions(+), 3 deletions(-) diff --git a/test/conftest.py b/test/conftest.py index 8868e403..22114ff3 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -121,9 +121,11 @@ async def _noop_async_sleep(*_a, **_k): "sample", # sandbox completion + metadata "stream", # global archiver batching "rescan", # rescan retry loop + settle - "test_rules", # test_rules / test_async_rules — ruleset lifecycle polling - # (NOT "rules": that is a prefix of "ruleset" and would - # also match the instant ruleset_favorite respx suite) # test_rules / test_async_rules — live enable/stop + ~6 poll loops + "_rules", # test_rules / test_async_rules — live enable/stop + + # ~6 poll loops. NOT "rules" (a prefix of "ruleset", so it + # also matches the instant ruleset_favorite respx suite) + # and NOT "test_rules" (which misses test_async_rules + # entirely — it is test_ + async_rules). "hash_search", # search-index lag "existence_probe", # submit + settle + search-index lag (the HEAD probe tests) "sandboxtask", # sandbox completion + index lag diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index e1eac1fe..743b4a28 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -18,7 +18,10 @@ Endpoint *behaviour* is covered by the live-e2e VCR lifecycle tests (``test_rules`` / ``test_async_rules``). """ +import asyncio + from polyswarm_api import core, resources +from polyswarm_api.aio import PolySwarmAsyncAPI from polyswarm_api.api import PolyswarmAPI @@ -265,3 +268,52 @@ def test_zero_is_sent_and_absent_is_omitted(self): assert sent.params['since'] == 0 omitted = resources.LiveHuntResult.list(_FakeApi(), since=None, community='gamma') assert 'since' not in omitted.params + +class TestAsyncLiveFeedMaxResults: + """The CANONICAL async bound loop, not the generated mirror. + + Every other max_results test drives ``PolyswarmAPI`` — the unasync output. + The ``async for`` + ``yielded``/``return`` shape is precisely the part + unasync REWRITES rather than copies, so a mirror-only test would keep + passing if the canonical source's loop were wrong.""" + + @staticmethod + def _api_yielding(count): + api = PolySwarmAsyncAPI.__new__(PolySwarmAsyncAPI) + api.uri = _FakeApi.uri + api.community = _FakeApi.community + captured = {} + + async def paginate(request, *a, **kw): + captured.update(request.params) + for item in range(count): + yield item + + api._paginate = paginate + return api, captured + + @staticmethod + def _collect(agen): + async def run(): + return [item async for item in agen] + + return asyncio.run(run()) + + def test_the_bound_truncates(self): + api, _ = self._api_yielding(7) + assert self._collect(api.live_feed(max_results=3)) == [0, 1, 2] + + def test_no_bound_yields_everything(self): + for no_bound in (None, 0, -1): + api, _ = self._api_yielding(4) + assert self._collect(api.live_feed(max_results=no_bound)) == list(range(4)) + + def test_the_bound_sizes_the_page(self): + api, captured = self._api_yielding(0) + self._collect(api.live_feed(max_results=5)) + assert captured['limit'] == 5 + + def test_no_bound_sends_no_limit(self): + api, captured = self._api_yielding(0) + self._collect(api.live_feed()) + assert 'limit' not in captured From 1104ec791a003065b3b9b3ba22e3daf71e7ea095 Mon Sep 17 00:00:00 2001 From: Samuel Date: Fri, 28 Aug 2026 01:34:26 -0300 Subject: [PATCH 23/36] docs(live-feed): since stays seconds; trim the surrounding comments MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The wire is not moving to minutes (prod traffic makes it a silent 60x widening for clients we don't control), so this is a documentation correction again rather than a behaviour change — which also removes it from the develop -> master bump decision. max_results and the absent-or-0 contract are unaffected. Also shortens the core helper comments: the argument belongs in specs/05, not beside every line that touches it. --- specs/03-endpoints.md | 2 +- specs/05-downstream-contract.md | 32 ++++++++++++++++++-------------- src/polyswarm_api/aio/api.py | 9 +++------ src/polyswarm_api/api.py | 9 +++------ src/polyswarm_api/core.py | 26 +++++++------------------- 5 files changed, 32 insertions(+), 46 deletions(-) diff --git a/specs/03-endpoints.md b/specs/03-endpoints.md index 5c7fdee9..7515f436 100644 --- a/specs/03-endpoints.md +++ b/specs/03-endpoints.md @@ -187,7 +187,7 @@ refusal. | `iocs_by_hash(hash_type, hash_value, hide_known_good=False, beta=False)` | `IOC.iocs_by_hash` | | `search_by_ioc(ip=None, domain=None, ttp=None, imphash=None)` | `IOC.ioc_search` | | `check_known_hosts(ips=[], domains=[])` | `IOC.check_known_hosts` | -| `live_feed(since=None, …, livescan_id=None, max_results=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in **MINUTES**, and absent-or-`0` means no time filter at all (the server applies it on a truthiness test); `max_results` bounds the read — `None`/`0`/negative means no bound, and it also sizes the page request via `core.page_size_for`. The `since` unit is a **behaviour change**, not a doc correction — see [05-downstream-contract.md](./05-downstream-contract.md) §Behaviour changes | +| `live_feed(since=None, …, livescan_id=None, max_results=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in **SECONDS** (the server converts with `timedelta(seconds=since)`; the 3.x/4.x docstring said minutes and was wrong), and absent-or-`0` means no time filter at all — the server applies it on a truthiness test; `max_results` bounds the read — `None`/`0`/negative means no bound, and it also sizes the page request via `core.page_size_for` | | `historical_list(since=None)` | `HistoricalHunt.list` | | `historical_results(hunt=None, …)` | `HistoricalHuntResultList.get` | | `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract. `has_new_results` selects on the server's STORED counter (no window parameter — the window belongs to the server's scheduled refresh; rows carry `new_results_count` + `new_results_counted_at`) | diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 365113e1..86b39b3d 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -305,20 +305,24 @@ Migrating from 3.x to 4.0, callers retain: ## Backward compatibility — what changes -### Behaviour changes - -- **`live_feed(since=)` is now MINUTES, and it is a wire fix, not a doc fix.** - The 3.x/4.x docstring said "minutes" while the server converted with - `timedelta(seconds=since)`, so a caller who read the docstring and passed - `60` meaning an hour got a minute. Every surface around the parameter was - written for minutes — the CLI's `1440` default is `24 * 60` — so the server - was corrected to read minutes rather than the callers being corrected to - send seconds. **This is a break**: a caller passing an explicit `since` in - seconds now gets a 60x wider window, silently. Nobody loses data — they get - more — but it is a behaviour change the `develop → master` bump decision - should see, not a documentation correction. - - **`since` absent or `0` means no time filter at all** — the feed pages over +### Documentation corrections that read like behaviour changes + +- **`live_feed(since=)` was always SECONDS.** The 3.x/4.x docstring said + "minutes", but the server has always converted the parameter with + `timedelta(seconds=since)` — the docstring was corrected, not the wire. A + caller who read the old docstring and passed `60` meaning an hour was + already getting a minute; nothing changed underneath them. + + Moving the *wire* to minutes was considered and rejected. Every surface + around the parameter was written for minutes (the CLI's `1440` default is + `24 * 60`), so re-basing the server looked like the fix that made all three + agree — but the endpoint takes ~197k requests carrying `since` per 30 days + from 10 distinct API keys and 12 user agents, all SDK or script clients, + with values from `2100` to `2592000`. Re-reading those as minutes widens + every one 60x and returns more data with no error. The wire stays seconds; + the one caller in our control (the CLI's default) was corrected instead. + +- **`since` absent or `0` means no time filter at all** — the feed pages over everything. That is the server's contract (it applies the filter on a truthiness test), and it is what a caller wanting the full history relies on. An earlier revision of this document claimed the server was tightening diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index 3943c91f..a331745c 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -507,9 +507,8 @@ async def live_feed(self, since=None, rule_name=None, family=None, """ Get live hunts feed - :param since: Window in MINUTES. Absent or 0 means NO time filter at - all — the feed pages over everything, which is what a caller - wanting the full history asks for. + :param since: Window in SECONDS (this said "minutes" before 4.4 and was + wrong). Absent or 0 means no time filter at all. :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). :param polyscore_lower: Polyscore lower bound for the hunt results. @@ -522,9 +521,7 @@ async def live_feed(self, since=None, rule_name=None, family=None, page request, so a small ask fetches a small page. :return: Generator of HuntResult resources """ - # One normalised bound drives both halves — the page we ask for and - # the point we stop — so they cannot disagree about whether there is - # a bound at all (0 and negatives mean there is not). + # One normalised bound drives the page size and the stop condition. bound = as_result_bound(max_results) yielded = 0 async for item in self._paginate(resources.LiveHuntResult.list( diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 690f43fd..e36b93d4 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -574,9 +574,8 @@ def live_feed( """ Get live hunts feed - :param since: Window in MINUTES. Absent or 0 means NO time filter at - all — the feed pages over everything, which is what a caller - wanting the full history asks for. + :param since: Window in SECONDS (this said "minutes" before 4.4 and was + wrong). Absent or 0 means no time filter at all. :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). :param polyscore_lower: Polyscore lower bound for the hunt results. @@ -589,9 +588,7 @@ def live_feed( page request, so a small ask fetches a small page. :return: Generator of HuntResult resources """ - # One normalised bound drives both halves — the page we ask for and - # the point we stop — so they cannot disagree about whether there is - # a bound at all (0 and negatives mean there is not). + # One normalised bound drives the page size and the stop condition. bound = as_result_bound(max_results) yielded = 0 for item in self._paginate( diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index 62b5904a..20217ea0 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -668,38 +668,26 @@ def list(cls, api, **kwargs): ) -# The server caps a page at AI_MAX_QUERY_RESULTS and defaults to -# AI_DEFAULT_PAGE_SIZE; it has never served an unbounded query. What is -# unbounded is the client, which follows cursors until has_more clears. A -# caller asking for N results therefore only needs a page big enough to hold -# them, and never more than the server would grant anyway. -# Mirrors the server's AI_MAX_QUERY_RESULTS (1000). Asking above it is a 400, -# not a silent truncation, so the clamp is what keeps a large bound usable. -# It lives here rather than in settings.py because it is a fact about the -# protocol that a pure helper needs, not a knob a caller tunes. +# Mirrors the server's AI_MAX_QUERY_RESULTS; asking above it is a 400. MAX_PAGE_SIZE = 1000 def as_result_bound(max_results): """The caller's result bound, or None when there isn't one. - ``None``, ``0`` and negatives all mean "no bound" — the historical - behaviour, every page. Stated ONCE so the page size and the generator's - stop condition cannot disagree about what counts as a bound. They did - once: ``0`` asked for a full server-default page and then stopped after - a single row, because one half tested truthiness and the other tested - ``is not None``.""" + None, 0 and negatives all mean "no bound". Stated once so the page size and + the stop condition can't disagree about whether a bound exists. + """ if not max_results or max_results < 0: return None return max_results def page_size_for(max_results): - """Page size to request for a bounded read, or None to take the default. + """Page size for a bounded read, or None for the server default. - Clamped to what the server would grant anyway. Note this is NOT the bound - itself — a caller asking for 5000 gets 1000-row pages and still stops at - 5000 — so the two are computed separately from one normalised value.""" + Not the bound itself: a 5000 ask gets 1000-row pages and still stops at 5000. + """ bound = as_result_bound(max_results) if bound is None: return None From a3eb7cb2afd97ea0d60f102ed71ec7f6a2914788 Mon Sep 17 00:00:00 2001 From: Samuel Date: Fri, 28 Aug 2026 01:47:04 -0300 Subject: [PATCH 24/36] fix(live-feed): stop sizing the page from max_results MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit MAX_PAGE_SIZE mirrored the server's AI_MAX_QUERY_RESULTS code default of 1000, but the chart sets 300 in every environment — so live_feed(max_results=500) would have sent limit=500 and got a 400. The cap is an env var the deployment chooses, so the SDK cannot know it: max_results now bounds only how many results the generator yields, and the request is unchanged (which also keeps the default call byte-compatible with every cassette). Also polls the favorite read-after-write — the star is written on the line above, and it was the one such assertion here that neither polled nor guarded 204. One read per attempt, so the recorded interactions are unchanged. --- specs/01-architecture.md | 2 +- specs/03-endpoints.md | 2 +- specs/05-downstream-contract.md | 18 ++++--- src/polyswarm_api/aio/api.py | 9 ++-- src/polyswarm_api/api.py | 8 +-- src/polyswarm_api/core.py | 18 +------ test/async_client_test.py | 18 +++++-- test/client_scan_test.py | 21 ++++++-- test/hunt_tracking_builder_test.py | 82 +++++++++--------------------- 9 files changed, 75 insertions(+), 103 deletions(-) diff --git a/specs/01-architecture.md b/specs/01-architecture.md index 868d7ad8..86202de6 100644 --- a/specs/01-architecture.md +++ b/specs/01-architecture.md @@ -42,7 +42,7 @@ Hand-written. No I/O. Three sub-concerns: **Resource bases**: `BaseResource`, `BaseJsonResource`. The latter has classmethod builders (`create` / `get` / `head` / `update` / `delete` / `list`) that each return a `PolyswarmRequest` descriptor. Per-domain resources in `resources.py` inherit from `BaseJsonResource` and may add custom classmethods (`ArtifactInstance.search_hash`, `IOC.iocs_by_hash`, etc.) — all returning descriptors. -**Helpers**: `Hashable` + `Hash` + `is_valid_sha1/sha256/md5`, `parse_isoformat`, `_normalise_bool_params`, `RequestParamsEncoder`, `as_result_bound` + `page_size_for` + `MAX_PAGE_SIZE` (the one definition of a caller's result bound and the page it implies, shared by both transports), `_raise_for_status` (the shared non-2xx → typed-exception mapper, used by both `parse_response` and the session's streaming-download path). Downloads stream straight to their destination from the session — there is no response adapter; see [`99-open-questions.md`](./99-open-questions.md) §"Streaming downloads". +**Helpers**: `Hashable` + `Hash` + `is_valid_sha1/sha256/md5`, `parse_isoformat`, `_normalise_bool_params`, `RequestParamsEncoder`, `as_result_bound` (the one definition of a caller's result bound), `_raise_for_status` (the shared non-2xx → typed-exception mapper, used by both `parse_response` and the session's streaming-download path). Downloads stream straight to their destination from the session — there is no response adapter; see [`99-open-questions.md`](./99-open-questions.md) §"Streaming downloads". ### Layer 2 — transport (`session.py` / `aio/session.py`) diff --git a/specs/03-endpoints.md b/specs/03-endpoints.md index 7515f436..c7762522 100644 --- a/specs/03-endpoints.md +++ b/specs/03-endpoints.md @@ -187,7 +187,7 @@ refusal. | `iocs_by_hash(hash_type, hash_value, hide_known_good=False, beta=False)` | `IOC.iocs_by_hash` | | `search_by_ioc(ip=None, domain=None, ttp=None, imphash=None)` | `IOC.ioc_search` | | `check_known_hosts(ips=[], domains=[])` | `IOC.check_known_hosts` | -| `live_feed(since=None, …, livescan_id=None, max_results=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in **SECONDS** (the server converts with `timedelta(seconds=since)`; the 3.x/4.x docstring said minutes and was wrong), and absent-or-`0` means no time filter at all — the server applies it on a truthiness test; `max_results` bounds the read — `None`/`0`/negative means no bound, and it also sizes the page request via `core.page_size_for` | +| `live_feed(since=None, …, livescan_id=None, max_results=None)` | `LiveHuntResult.list` — `livescan_id` scopes the feed to one live hunt (the hunt-page per-ruleset feed); `since` is in **SECONDS** (the server converts with `timedelta(seconds=since)`; the 3.x/4.x docstring said minutes and was wrong), and absent-or-`0` means no time filter at all — the server applies it on a truthiness test; `max_results` bounds how many results the generator yields — `None`/`0`/negative means no bound; it does not alter the request | | `historical_list(since=None)` | `HistoricalHunt.list` | | `historical_results(hunt=None, …)` | `HistoricalHuntResultList.get` | | `ruleset_list(name=None, status=None, favorites_only=None, has_new_results=None)` | `YaraRuleset.list` — the hunt-page filters, conjunctive and optional; unset filters are omitted from the query so the no-filter request is byte-compatible with the old contract. `has_new_results` selects on the server's STORED counter (no window parameter — the window belongs to the server's scheduled refresh; rows carry `new_results_count` + `new_results_counted_at`) | diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 86b39b3d..ac480036 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -135,9 +135,7 @@ class Hash(Hashable): ... def is_valid_sha1 / _sha256 / _md5(value) -> bool def parse_isoformat(date_string) -MAX_PAGE_SIZE: int # the largest page the server will grant def as_result_bound(max_results) # None / 0 / negative -> None (no bound) -def page_size_for(max_results) # the page a bounded read should request ``` These are stable but less curated than the top-level exports. Downstream callers that subclass `BaseJsonResource` to add custom resource types are supported. Downstream callers that construct `PolyswarmRequest` manually and hand it to `session.execute` are supported. @@ -330,12 +328,16 @@ Migrating from 3.x to 4.0, callers retain: change was ever made, and the opposite is the intended semantics. - **`live_feed(max_results=)` is new and additive.** It defaults to `None`, - which is the historical behaviour — every page, up to the client's page cap. - Set it to bound a read; it also sizes the page request (`core.page_size_for`), - so a small ask does not fetch a full default page. Worth knowing that the - server has never served an unbounded query — it caps every page — while this - client follows cursors until `has_more` clears, so the bound this offers is - a client-side one. + which is the historical behaviour — every page. It bounds how many results + the generator yields and nothing else: the request is unchanged, so the + default call stays byte-compatible with every recorded cassette. + + It deliberately does **not** size the page. Sending `limit` looked like a + free optimisation — a small ask need not fetch a full page — but the server's + cap is `AI_MAX_QUERY_RESULTS`, an env var set per deployment (300 in the + chart, 1000 in the code default), and asking above it is a **400**. The SDK + cannot know a value the deployment chooses, so it does not guess: the server + picks the page, the client stops at the bound. ### Required code changes diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index a331745c..b903e3ac 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -18,7 +18,7 @@ import time from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest, as_result_bound, page_size_for +from polyswarm_api.core import PolyswarmRequest, as_result_bound from .session import AsyncPolyswarmSession @@ -516,18 +516,15 @@ async def live_feed(self, since=None, rule_name=None, family=None, :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. :param max_results: Stop after this many results. None, 0 or a negative - means no bound — the previous behaviour, every page up to the - client's page cap. Set it for a bounded read; it also sizes the - page request, so a small ask fetches a small page. + means no bound — the previous behaviour, every page. :return: Generator of HuntResult resources """ - # One normalised bound drives the page size and the stop condition. bound = as_result_bound(max_results) yielded = 0 async for item in self._paginate(resources.LiveHuntResult.list( self, since=since, rule_name=rule_name, family=family, polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, - livescan_id=livescan_id, limit=page_size_for(bound), + livescan_id=livescan_id, community=community or self.community)): yield item yielded += 1 diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index e36b93d4..e3375666 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -20,7 +20,7 @@ import logging from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest, as_result_bound, page_size_for +from polyswarm_api.core import PolyswarmRequest, as_result_bound from .session import PolyswarmSession @@ -583,12 +583,9 @@ def live_feed( :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. :param max_results: Stop after this many results. None, 0 or a negative - means no bound — the previous behaviour, every page up to the - client's page cap. Set it for a bounded read; it also sizes the - page request, so a small ask fetches a small page. + means no bound — the previous behaviour, every page. :return: Generator of HuntResult resources """ - # One normalised bound drives the page size and the stop condition. bound = as_result_bound(max_results) yielded = 0 for item in self._paginate( @@ -600,7 +597,6 @@ def live_feed( polyscore_lower=polyscore_lower, polyscore_upper=polyscore_upper, livescan_id=livescan_id, - limit=page_size_for(bound), community=community or self.community, ) ): diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index 20217ea0..2946e25c 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -668,32 +668,16 @@ def list(cls, api, **kwargs): ) -# Mirrors the server's AI_MAX_QUERY_RESULTS; asking above it is a 400. -MAX_PAGE_SIZE = 1000 - - def as_result_bound(max_results): """The caller's result bound, or None when there isn't one. - None, 0 and negatives all mean "no bound". Stated once so the page size and - the stop condition can't disagree about whether a bound exists. + None, 0 and negatives all mean "no bound". """ if not max_results or max_results < 0: return None return max_results -def page_size_for(max_results): - """Page size for a bounded read, or None for the server default. - - Not the bound itself: a 5000 ask gets 1000-row pages and still stops at 5000. - """ - bound = as_result_bound(max_results) - if bound is None: - return None - return min(bound, MAX_PAGE_SIZE) - - # ── Hash helpers ─────────────────────────────────────────────────── diff --git a/test/async_client_test.py b/test/async_client_test.py index 0ae87b45..bd163c43 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -644,9 +644,21 @@ async def test_async_rules(self, uid): # stack budget is shared across runs) assert fav.favorites_limit == 5 assert 1 <= fav.favorites_used <= fav.favorites_limit - favorites = [r async for r in api.ruleset_list(favorites_only=True)] - assert any(r.id == rule.id for r in favorites) - assert all(r.favorite for r in favorites) + # The star was written on the line above — the sharpest + # read-after-write here, so it polls like the rest (specs/04). + # The star was written on the line above — the sharpest + # read-after-write here, so it polls like the rest (specs/04). + # One read per attempt: the rows are kept for the arm below. + starred = [] + async def _is_starred(): + try: + starred[:] = [r async for r in + api.ruleset_list(favorites_only=True)] + except exceptions.NoResultsException: + starred[:] = [] + return rule.id in {r.id for r in starred} + assert await poll_equals_async(_is_starred, True) + assert all(r.favorite for r in starred) # unstarring here is the CONTRACT assertion; slot hygiene does # not depend on reaching it — the finally's ruleset_delete # soft-deletes and the budget counts only deleted=false rows diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 084f42b3..46a02646 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -224,6 +224,13 @@ def test_json_get(self): assert obj._get('path1.path3.path5') is None +def _favorites_or_empty(api): + """The starred rulesets, or [] when the server answers 204.""" + try: + return list(api.ruleset_list(favorites_only=True)) + except exceptions.NoResultsException: + return [] + class ScanTestCaseV2(TestCase): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) @@ -612,9 +619,17 @@ def test_rules(self): # used is a BOUND because the stack budget is shared across runs assert fav.favorites_limit == 5 assert 1 <= fav.favorites_used <= fav.favorites_limit - favorites = list(api.ruleset_list(favorites_only=True)) - assert any(r.id == rule.id for r in favorites) - assert all(r.favorite for r in favorites) + # The star was written on the line above — the sharpest + # read-after-write here, so it polls like the rest (specs/04). + # The star was written on the line above — the sharpest + # read-after-write here, so it polls like the rest (specs/04). + # One read per attempt: the rows are kept for the arm below. + starred = [] + def _is_starred(): + starred[:] = _favorites_or_empty(api) + return rule.id in {r.id for r in starred} + assert poll_equals(_is_starred, True) + assert all(r.favorite for r in starred) # unstarring here is the CONTRACT assertion; slot hygiene does not # depend on reaching it — the finally's ruleset_delete soft-deletes # and the server's budget counts only deleted=false rows, so a diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index 743b4a28..c5fd1d11 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -149,39 +149,16 @@ def test_list_routes_livescan_id_to_the_query_as_digit_string(self): assert req.params == {'since': 60, 'livescan_id': '45392847561029383', 'community': 'gamma'} -class TestPageSizeForBound: - """``core.page_size_for`` — the page a bounded read should ask for. - - The server caps a page itself and has never served an unbounded query; what - is unbounded is this client, which follows cursors until ``has_more`` - clears. So a caller asking for N needs a page big enough to hold N, and - never more than the server would grant anyway.""" - - def test_no_bound_takes_the_server_default(self): - # None is the historical behaviour — every page, server-sized. - assert core.page_size_for(None) is None - # 0 is not a bound either; it would otherwise ask for a zero-row page. - assert core.page_size_for(0) is None - # nor is a negative, which would otherwise put limit=-1 on the wire - # and the server would answer with nothing. - assert core.page_size_for(-1) is None - - def test_the_bound_and_the_page_are_normalised_the_same_way(self): - # The two used to disagree about what counts as a bound at all, which - # is how max_results=0 asked for a full page and then stopped after - # one row. One definition now answers both. +class TestResultBound: + """``core.as_result_bound`` — one definition of "is there a bound".""" + + def test_no_bound_forms(self): for no_bound in (None, 0, -1): assert core.as_result_bound(no_bound) is None - assert core.page_size_for(no_bound) is None - # a real bound is NOT clamped away — only the page it implies is - assert core.as_result_bound(10_000) == 10_000 - assert core.page_size_for(10_000) == core.MAX_PAGE_SIZE - def test_a_small_bound_asks_for_a_small_page(self): - assert core.page_size_for(5) == 5 - - def test_a_large_bound_is_clamped_to_what_the_server_grants(self): - assert core.page_size_for(10_000) == core.MAX_PAGE_SIZE + def test_a_real_bound_passes_through_unclamped(self): + assert core.as_result_bound(5) == 5 + assert core.as_result_bound(10_000) == 10_000 class TestLiveFeedMaxResults: @@ -213,20 +190,18 @@ def test_a_negative_bound_is_no_bound(self): assert list(self._api_yielding(4).live_feed(max_results=-1)) == list(range(4)) def test_zero_is_no_bound_not_a_bound_of_one(self): - # 0 has to mean the same thing here as it does in page_size_for and in - # `since` on this same call: no bound. Testing `is not None` instead of - # truthiness makes max_results=0 yield exactly one result, which is the - # two halves of the bound disagreeing. + # 0 means no bound, as it does for `since` on the same call. Testing + # `is not None` instead makes max_results=0 yield exactly one result. assert list(self._api_yielding(7).live_feed(max_results=0)) == list(range(7)) class TestLiveFeedLimitOnTheWire: - """``max_results`` must actually SIZE the request, not just truncate. + """``max_results`` must NOT put ``limit`` on the wire. - The truncation tests replace ``_paginate`` wholesale, so the descriptor is - never built and dropping the ``limit`` argument entirely would keep them all - green. This is the assertion that fails if the wiring goes away — and the - unbounded case pins that no ``limit`` is sent at all, which is what keeps the - default request byte-compatible with every recorded cassette.""" + Sizing the page looked free, but the server's cap is AI_MAX_QUERY_RESULTS — + an env var set per deployment (300 in the chart) — and asking above it is a + 400. Keeping ``limit`` off the request also keeps the default call + byte-compatible with every recorded cassette. + """ @staticmethod def _params(**kwargs): @@ -243,15 +218,10 @@ def capture(request, *a, **kw): list(api.live_feed(**kwargs)) return captured - def test_a_bound_sizes_the_page(self): - assert self._params(max_results=5)['limit'] == 5 - - def test_a_large_bound_asks_only_for_what_the_server_grants(self): - assert self._params(max_results=10_000)['limit'] == core.MAX_PAGE_SIZE - - def test_no_bound_sends_no_limit_at_all(self): - for no_bound in ({}, {'max_results': 0}, {'max_results': -1}): - assert 'limit' not in self._params(**no_bound) + def test_no_limit_is_ever_sent(self): + for kwargs in ({}, {'max_results': 5}, {'max_results': 10_000}, + {'max_results': 0}, {'max_results': -1}): + assert 'limit' not in self._params(**kwargs) class TestLiveFeedSinceOnTheWire: @@ -308,12 +278,8 @@ def test_no_bound_yields_everything(self): api, _ = self._api_yielding(4) assert self._collect(api.live_feed(max_results=no_bound)) == list(range(4)) - def test_the_bound_sizes_the_page(self): - api, captured = self._api_yielding(0) - self._collect(api.live_feed(max_results=5)) - assert captured['limit'] == 5 - - def test_no_bound_sends_no_limit(self): - api, captured = self._api_yielding(0) - self._collect(api.live_feed()) - assert 'limit' not in captured + def test_no_limit_is_ever_sent(self): + for kwargs in ({}, {'max_results': 5}, {'max_results': 0}): + api, captured = self._api_yielding(0) + self._collect(api.live_feed(**kwargs)) + assert 'limit' not in captured From ff3b4241636fe506bcbd98d6a1b1871521069b3e Mon Sep 17 00:00:00 2001 From: Samuel Date: Fri, 28 Aug 2026 01:55:53 -0300 Subject: [PATCH 25/36] docs(live-feed): max_results is a total, not a page size MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The two are independent: the page stays the server's to choose (50 for web, capped by AI_MAX_QUERY_RESULTS) and _next_page echoes it, so a bounded read keeps paginating in those same small chunks and stops once it has enough. Sending limit=max_results conflated them — the 400 above the deployment's cap was a symptom of that, not the reason. --- specs/05-downstream-contract.md | 14 ++++++++------ src/polyswarm_api/aio/api.py | 5 +++-- src/polyswarm_api/api.py | 5 +++-- test/hunt_tracking_builder_test.py | 9 ++++----- 4 files changed, 18 insertions(+), 15 deletions(-) diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index ac480036..0c50a94b 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -332,12 +332,14 @@ Migrating from 3.x to 4.0, callers retain: the generator yields and nothing else: the request is unchanged, so the default call stays byte-compatible with every recorded cassette. - It deliberately does **not** size the page. Sending `limit` looked like a - free optimisation — a small ask need not fetch a full page — but the server's - cap is `AI_MAX_QUERY_RESULTS`, an env var set per deployment (300 in the - chart, 1000 in the code default), and asking above it is a **400**. The SDK - cannot know a value the deployment chooses, so it does not guess: the server - picks the page, the client stops at the bound. + **`max_results` is a total, not a page size — the two are independent.** The + page is the server's to choose (50 for the web service, capped by + `AI_MAX_QUERY_RESULTS`), and `_next_page` echoes the size it reports back on + each subsequent request; a bounded read keeps paginating in those same small, + API-friendly chunks and simply stops once it has enough. An earlier revision + sent `limit=max_results`, which conflated the two — and, since the cap is an + env var each deployment sets (300 in the chart), would have turned a large + bound into a 400. ### Required code changes diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index b903e3ac..6deba52b 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -515,8 +515,9 @@ async def live_feed(self, since=None, rule_name=None, family=None, :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. - :param max_results: Stop after this many results. None, 0 or a negative - means no bound — the previous behaviour, every page. + :param max_results: Total results to yield, not a page size — paging + continues in the server's own chunks until the total is reached. + None, 0 or a negative means no bound: every page, as before. :return: Generator of HuntResult resources """ bound = as_result_bound(max_results) diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index e3375666..1baf363c 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -582,8 +582,9 @@ def live_feed( :param polyscore_upper: Polyscore upper bound for the hunt results. :param community: Community to retrieve live results from, or public/private. :param livescan_id: Scope the feed to one live hunt's results. - :param max_results: Stop after this many results. None, 0 or a negative - means no bound — the previous behaviour, every page. + :param max_results: Total results to yield, not a page size — paging + continues in the server's own chunks until the total is reached. + None, 0 or a negative means no bound: every page, as before. :return: Generator of HuntResult resources """ bound = as_result_bound(max_results) diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index c5fd1d11..6de5e4fb 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -195,12 +195,11 @@ def test_zero_is_no_bound_not_a_bound_of_one(self): assert list(self._api_yielding(7).live_feed(max_results=0)) == list(range(7)) class TestLiveFeedLimitOnTheWire: - """``max_results`` must NOT put ``limit`` on the wire. + """``max_results`` is a total, so it must not reach the wire as ``limit``. - Sizing the page looked free, but the server's cap is AI_MAX_QUERY_RESULTS — - an env var set per deployment (300 in the chart) — and asking above it is a - 400. Keeping ``limit`` off the request also keeps the default call - byte-compatible with every recorded cassette. + The page stays the server's to choose and the read keeps paginating in those + chunks; sending the total as a page size also 400s above the deployment's + AI_MAX_QUERY_RESULTS (300 in the chart). """ @staticmethod From d0c7f3431034ef8acca17532983912fbb08b9ba7 Mon Sep 17 00:00:00 2001 From: Samuel Date: Fri, 28 Aug 2026 12:08:28 -0300 Subject: [PATCH 26/36] fix(tests): drop a duplicated comment in the live favorite tests The two-line read-after-write note was pasted twice in a row, in both the sync and async live tests. --- test/async_client_test.py | 2 -- test/client_scan_test.py | 2 -- 2 files changed, 4 deletions(-) diff --git a/test/async_client_test.py b/test/async_client_test.py index bd163c43..8cd86c81 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -646,8 +646,6 @@ async def test_async_rules(self, uid): assert 1 <= fav.favorites_used <= fav.favorites_limit # The star was written on the line above — the sharpest # read-after-write here, so it polls like the rest (specs/04). - # The star was written on the line above — the sharpest - # read-after-write here, so it polls like the rest (specs/04). # One read per attempt: the rows are kept for the arm below. starred = [] async def _is_starred(): diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 46a02646..ee74c8bf 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -621,8 +621,6 @@ def test_rules(self): assert 1 <= fav.favorites_used <= fav.favorites_limit # The star was written on the line above — the sharpest # read-after-write here, so it polls like the rest (specs/04). - # The star was written on the line above — the sharpest - # read-after-write here, so it polls like the rest (specs/04). # One read per attempt: the rows are kept for the arm below. starred = [] def _is_starred(): From 29f704c606238788a844b96264f65582745387c7 Mon Sep 17 00:00:00 2001 From: Samuel Date: Fri, 28 Aug 2026 12:08:59 -0300 Subject: [PATCH 27/36] docs(specs): score an added optional keyword as a minor bump MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Versioning table had no row for adding an optional keyword to an existing public method, so the nearest match was `Signature change on a public method | major` — which scores this change major even though every existing call site keeps working untouched. The table already carves out the additive exception cases on exactly that reasoning ("no consumer has to change"); this applies the same rule to keyword arguments, and narrows the signature row to the changes a caller must actually react to. --- specs/05-downstream-contract.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 0c50a94b..7f776fa1 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -438,7 +438,8 @@ result = req._result # the parsed resource (or list); | **New exception class that subclasses an existing one** | **minor** — additive: every `except ` keeps catching it (invariant 3), so no consumer has to change. Raising the *base* class where a narrower one used to be raised is the major-bump direction | | **Narrowing which exception a status maps to** (same status code, more specific class) | **minor**, on the same reasoning — but only while the new class is a subclass of the old one. A sibling class is a behaviour change on a documented contract, i.e. major | | Bug fix in request/response handling | patch | -| Signature change on a public method | major | +| **New optional keyword argument on an existing method**, with a default that preserves the current behaviour | **minor** — additive on the same reasoning as the exception rows above: every existing call site keeps working untouched, so no consumer has to react | +| Signature change on a public method **that an existing caller must react to** — a parameter removed, reordered, renamed, or made required | major | | Rename / removal of a public symbol | major | | Behaviour change on a documented contract | major | | Internal refactor (private symbols, helper rewrites) | patch | From 02464c9b0d20e02df37f273b1b87eacc50709aa6 Mon Sep 17 00:00:00 2001 From: Samuel Date: Fri, 28 Aug 2026 12:17:25 -0300 Subject: [PATCH 28/36] docs: stop naming a version this PR does not set Three accuracy fixes from an audit of the revert commits: - The `since` docstring said the parameter "said minutes before 4.4". The version is chosen at the `develop -> master` step, not here, so if that release cuts as anything else the shipped docstring is wrong and nothing would catch it. "in earlier releases" carries the same meaning with no forward reference. - `specs/05` described the CLI's `1440` default in the present tense inside a paragraph that is otherwise entirely historical. That default was retired in this same change set. - `core.py`'s module docstring lists the pure helpers; `as_result_bound` was added to `specs/01` but never to the list beside the code. --- specs/05-downstream-contract.md | 2 +- src/polyswarm_api/aio/api.py | 2 +- src/polyswarm_api/api.py | 2 +- src/polyswarm_api/core.py | 3 ++- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 7f776fa1..6c4d2d56 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -312,7 +312,7 @@ Migrating from 3.x to 4.0, callers retain: already getting a minute; nothing changed underneath them. Moving the *wire* to minutes was considered and rejected. Every surface - around the parameter was written for minutes (the CLI's `1440` default is + around the parameter was written for minutes (the CLI's old `1440` default was `24 * 60`), so re-basing the server looked like the fix that made all three agree — but the endpoint takes ~197k requests carrying `since` per 30 days from 10 distinct API keys and 12 user agents, all SDK or script clients, diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index 6deba52b..4f3e5741 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -507,7 +507,7 @@ async def live_feed(self, since=None, rule_name=None, family=None, """ Get live hunts feed - :param since: Window in SECONDS (this said "minutes" before 4.4 and was + :param since: Window in SECONDS (this said "minutes" in earlier releases and was wrong). Absent or 0 means no time filter at all. :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 1baf363c..92d78562 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -574,7 +574,7 @@ def live_feed( """ Get live hunts feed - :param since: Window in SECONDS (this said "minutes" before 4.4 and was + :param since: Window in SECONDS (this said "minutes" in earlier releases and was wrong). Absent or 0 means no time filter at all. :param rule_name: Filter hunt results on the provided rule name (exact match). :param family: Filter hunt results based on the family name (exact match). diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index 2946e25c..500d6801 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -16,7 +16,8 @@ builders (``create``, ``get``, ``head``, ``update``, ``delete``, ``list``) construct ``PolyswarmRequest`` descriptors. - ``Hashable`` + ``is_valid_*`` validators, ``parse_isoformat``, - ``_normalise_bool_params``, ``RequestParamsEncoder``. + ``_normalise_bool_params``, ``RequestParamsEncoder``, + ``as_result_bound``. Both transports import from here. """ From 633370131055277d61a76eaf41e536849c866204 Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 13:18:07 -0300 Subject: [PATCH 29/36] feat: release 4.4.0, the floor the CLI now pins MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The CLI expresses its need for this change set's surfaces as a version requirement — `polyswarm_api>=4.4.0` — rather than probing the installed SDK at runtime. A pin is checkable by pip at install time, before any code runs, and it cannot name a version this repo has not declared. So the bump lands here, in the feature PR, instead of at the release step. Minor, not major: every addition is additive — new methods, a new resource, new optional keywords, new parsed fields — so no existing call site changes. Bumped with bump-my-version and verified the emitted string is a clean `4.4.0`: the serialize config can produce `4.4.0.devN+sha`, and PEP 440 orders that BELOW 4.4.0, which would silently fail the CLI's floor and send its CI to PyPI for a version that does not exist yet. AGENTS.md and specs/05 record the exception and the ordering it forces: this repo must release before the CLI can, since the CLI's floor is unsatisfiable from PyPI until then. Consumer CI is unaffected — it installs this repo from git by branch name. --- AGENTS.md | 1 + pyproject.toml | 4 ++-- specs/05-downstream-contract.md | 13 +++++++++++++ src/polyswarm_api/__init__.py | 2 +- 4 files changed, 17 insertions(+), 3 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index e4c2c055..e2376e8e 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -40,6 +40,7 @@ feature/* ─┐ - **`develop → master` PRs are how `master` advances.** They're opened by a maintainer when a release-worthy batch of work is on `develop`. Most contributors never open one of these. - **Direct PRs to `master`** are wrong. If you opened one, close it, branch off `develop` instead, and re-open against `develop`. - **PyPI release happens automatically** when `pyproject.toml`'s `version` changes on `master`. Don't bump the version inside a feature PR unless the maintainer specifically asks — version bumps belong to the `develop → master` step. +- **The standing exception: a downstream floor that must point at this change.** When a sibling repo needs a surface this PR adds, that repo raises its `polyswarm_api>=` floor to the version introducing it — and the floor cannot name a version this repo has not declared yet. So the bump lands **here, in the feature PR**, not at the release step. Bump with `bump-my-version` and **check the emitted string is a clean `X.Y.0`**: the config can serialize a `.devN+sha` form, and PEP 440 orders `4.4.0.dev0 < 4.4.0`, so a dev suffix silently fails the sibling's floor and sends its CI to PyPI for a version that does not exist yet. **Why this matters:** `master` is the published surface of the SDK. PyPI consumers see whatever shows up there. Skipping `develop` skips the integration soak that protects against accidentally shipping a half-baked change. diff --git a/pyproject.toml b/pyproject.toml index e1294158..2af7a2d0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "polyswarm_api" -version = "4.3.0" +version = "4.4.0" description = "Client library to simplify interacting with the PolySwarm consumer API" readme = "README.md" requires-python = ">=3.10,<4" @@ -55,7 +55,7 @@ package-dir = { "" = "src" } where = ["src"] [tool.bumpversion] -current_version = "4.3.0" +current_version = "4.4.0" commit = true tag = false sign_tags = true diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 6c4d2d56..11b78639 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -455,6 +455,19 @@ result = req._result # the parsed resource (or list); No feature PR should touch `pyproject.toml`'s `version` unless the maintainer asks. See `AGENTS.md` §Gitflow. +**One case always asks: a consumer pinning a floor at this change.** A sibling repo that needs a +surface added here expresses that as a version requirement — `polyswarm_api>=X.Y.0` — because a +version pin is checkable by `pip` at install time, before any code runs. That floor cannot name a +version this repo has not declared, so the bump belongs in the feature PR and step 3's "bump at the +release step" does not apply. Consequences worth stating plainly: + +- **Order is forced.** This repo's `develop → master` must merge and release before the consumer can + be released, because the consumer's floor is unsatisfiable from PyPI until then. Consumer CI is + unaffected — it installs this repo straight from git by branch name. +- **The version string must be clean.** `4.4.0.dev0` does not satisfy `>=4.4.0` (PEP 440 orders + pre-releases below the release). Verify what `bump-my-version` emitted before pushing; the + serialize config here can produce a dev form. + ## Companion repos - **polyswarm-cli** — wraps these methods in CLI subcommands. CLI changes that need an SDK surface ship as a pair: SDK PR opens first, CLI PR depends on it via `## Requires` in the description. diff --git a/src/polyswarm_api/__init__.py b/src/polyswarm_api/__init__.py index 64f6de30..dadcc971 100644 --- a/src/polyswarm_api/__init__.py +++ b/src/polyswarm_api/__init__.py @@ -1,5 +1,5 @@ # https://www.python.org/dev/peps/pep-0008/#module-level-dunder-names -__version__ = '4.3.0' +__version__ = '4.4.0' __release_url__ = 'https://api.github.com/repos/polyswarm/polyswarm-api/releases/latest' from . import api From a6b6c398cec9be00c9b45e486d48bee532e32e40 Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 13:35:07 -0300 Subject: [PATCH 30/36] docs: RESOURCE_ID_KEYS is a routing list, not an identity declaration Both AGENTS.md and the specs/02 inline comment framed the attribute as "set this when the identifier isn't `id`". `YaraRulesetFavorite` is the first resource where the key is not the identifier at all: it names `community` so that `id` stays in the PUT body, because the default would move `id` to the query string and the server 400s. specs/02's prose and its per-resource entry already describe it correctly; the orientation doc and the code comment were the two places still under-describing the mechanism. --- AGENTS.md | 2 +- specs/02-resources.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index e2376e8e..fa86bf5d 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -88,7 +88,7 @@ No per-symbol codegen carve-outs: every method — including `engines`, a cached Mirror the existing patterns (`LLMPromptConfig`, `MetadataFieldProperties`, `YaraRuleset`): -1. `class FooBar(BaseJsonResource): RESOURCE_ENDPOINT = '/…'` in [`resources.py`](./src/polyswarm_api/resources.py). If the resource's identifier isn't `id`, set `RESOURCE_ID_KEYS = ['your_key']` so the base class routes it into the query string for `GET` / `DELETE` / `PUT`. Resources are transport-agnostic — only edit `resources.py`. +1. `class FooBar(BaseJsonResource): RESOURCE_ENDPOINT = '/…'` in [`resources.py`](./src/polyswarm_api/resources.py). `RESOURCE_ID_KEYS` (default `['id']`) names the keys the base class routes into the **query string** for `GET` / `DELETE` / `PUT` — everything else rides the body. Usually that is the identifier, when it isn't called `id`; but it is a routing list, not an identity declaration, so a resource may name a non-identifier key to keep `id` in the body (`YaraRulesetFavorite` does — see [`specs/02-resources.md`](./specs/02-resources.md)). Resources are transport-agnostic — only edit `resources.py`. 2. Add convenience methods on **[`PolySwarmAsyncAPI`](./src/polyswarm_api/aio/api.py)** (the canonical async source). For a single resource: `return await self._single(resources.FooBar.(self, …))`. For paginated: `async for item in self._paginate(...): yield item`. 3. Run `python scripts/regenerate_sync.py` (or rely on the pre-commit hook) to regenerate the sync mirror at `polyswarm_api/api.py`. 4. Add tests **e2e-first** (see [`specs/04-testing.md`](./specs/04-testing.md)): a live-e2e **VCR lifecycle test** against the real endpoint (sync body in `client_scan_test.py`, async in `async_client_test.py`; record the cassettes against a fresh e2e stack and commit them) plus **pure-unit builder tests** (assert the resulting `PolyswarmRequest`'s shape — body-vs-query routing, None-omission; no httpx fixtures needed). Reach for the respx `ClientTestCase` harness only when the scenario can't reasonably run on the e2e stack. diff --git a/specs/02-resources.md b/specs/02-resources.md index c812f878..9f1e6499 100644 --- a/specs/02-resources.md +++ b/specs/02-resources.md @@ -241,7 +241,7 @@ from .core import BaseJsonResource, Hashable, PolyswarmRequest class FooBar(BaseJsonResource): RESOURCE_ENDPOINT = '/foobar' - RESOURCE_ID_KEYS = ['foo_id'] # only needed if the identifier isn't 'id' + RESOURCE_ID_KEYS = ['foo_id'] # keys routed to the query string, not the body # Optional: parametrised path # RESOURCE_ENDPOINT = '/foobar/{foo_id}' From b9401883c801156361768dad6d330ce9f0e073f4 Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 13:45:55 -0300 Subject: [PATCH 31/36] test: pin the favorite cap as a relation, not the number MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `favorites_limit == 5` mirrors a code default the deployment can override — `AI_FAVORITE_RULESETS_LIMIT` is read from the environment — which is the same mistake as the MAX_PAGE_SIZE constant this branch already removed: the client asserting a server-owned number it cannot see. Against a live stack with VCR off and a different cap configured, the exact pin fails on a correct server. Assert the relation instead; the used-vs-limit check beside it still carries the meaning. --- test/async_client_test.py | 6 +++++- test/client_scan_test.py | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/test/async_client_test.py b/test/async_client_test.py index 8cd86c81..1a4357ae 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -642,7 +642,11 @@ async def test_async_rules(self, uid): assert fav.favorited_at is not None # limit is a PIN (fixed product cap); used is a BOUND (the # stack budget is shared across runs) - assert fav.favorites_limit == 5 + # The cap is a per-deployment setting (AI_FAVORITE_RULESETS_LIMIT), + # so pin the RELATION, not the number: an exact pin is the + # MAX_PAGE_SIZE mistake again — mirroring a code default the + # deployment overrides, which fails a live run with VCR off. + assert fav.favorites_limit >= 1 assert 1 <= fav.favorites_used <= fav.favorites_limit # The star was written on the line above — the sharpest # read-after-write here, so it polls like the rest (specs/04). diff --git a/test/client_scan_test.py b/test/client_scan_test.py index ee74c8bf..4fa23772 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -617,7 +617,11 @@ def test_rules(self): assert fav.favorited_at is not None # the limit is a PIN (the fixed product cap, no plan scaling); # used is a BOUND because the stack budget is shared across runs - assert fav.favorites_limit == 5 + # The cap is a per-deployment setting (AI_FAVORITE_RULESETS_LIMIT), + # so pin the RELATION, not the number: an exact pin is the + # MAX_PAGE_SIZE mistake again — mirroring a code default the + # deployment overrides, which fails a live run with VCR off. + assert fav.favorites_limit >= 1 assert 1 <= fav.favorites_used <= fav.favorites_limit # The star was written on the line above — the sharpest # read-after-write here, so it polls like the rest (specs/04). From 153812b8fd1e51d99bee5d67817c5da1ce37e73c Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 13:55:25 -0300 Subject: [PATCH 32/36] test: close the ruleset leak window, and document poll_equals MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Six create-response assertions sat above the `try:` whose `finally:` deletes the ruleset, so any of them failing leaks one on the shared e2e stack. Two of them predate this branch; the four tracking-field assertions widened it. The cost is not abstract: a leaked STARRED ruleset holds one of the team's five favorite slots, and the favorite tests need a free one. `try` now opens immediately after `ruleset_create`, in both transports. specs/04 gains the `poll_equals` / `poll_equals_async` entry it was missing while documenting its sibling `run_concurrently`. It carries a non-obvious invariant worth writing down: `want` must never be None, because not-found during the lag window also reads as None and would turn a vanished resource into a passing assertion — poll a boolean instead. Also records the mirror-image limit, that a False poll cannot ride out a stale False. AGENTS.md now names where the bump exception comes from: it is this repo's instance of a workspace-level standard, not a rule the repo grants itself. --- AGENTS.md | 2 +- specs/04-testing.md | 4 ++++ test/async_client_test.py | 16 +++++++++------- test/client_scan_test.py | 19 +++++++++++-------- 4 files changed, 25 insertions(+), 16 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index fa86bf5d..dcf3a5e4 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -40,7 +40,7 @@ feature/* ─┐ - **`develop → master` PRs are how `master` advances.** They're opened by a maintainer when a release-worthy batch of work is on `develop`. Most contributors never open one of these. - **Direct PRs to `master`** are wrong. If you opened one, close it, branch off `develop` instead, and re-open against `develop`. - **PyPI release happens automatically** when `pyproject.toml`'s `version` changes on `master`. Don't bump the version inside a feature PR unless the maintainer specifically asks — version bumps belong to the `develop → master` step. -- **The standing exception: a downstream floor that must point at this change.** When a sibling repo needs a surface this PR adds, that repo raises its `polyswarm_api>=` floor to the version introducing it — and the floor cannot name a version this repo has not declared yet. So the bump lands **here, in the feature PR**, not at the release step. Bump with `bump-my-version` and **check the emitted string is a clean `X.Y.0`**: the config can serialize a `.devN+sha` form, and PEP 440 orders `4.4.0.dev0 < 4.4.0`, so a dev suffix silently fails the sibling's floor and sends its CI to PyPI for a version that does not exist yet. +- **The standing exception: a downstream floor that must point at this change.** (This is the SDK-side instance of a workspace-level standard — *cross-repo dependencies are a version pin, not a runtime probe* — not a rule this repo grants itself.) When a sibling repo needs a surface this PR adds, that repo raises its `polyswarm_api>=` floor to the version introducing it — and the floor cannot name a version this repo has not declared yet. So the bump lands **here, in the feature PR**, not at the release step. Bump with `bump-my-version` and **check the emitted string is a clean `X.Y.0`**: the config can serialize a `.devN+sha` form, and PEP 440 orders `4.4.0.dev0 < 4.4.0`, so a dev suffix silently fails the sibling's floor and sends its CI to PyPI for a version that does not exist yet. **Why this matters:** `master` is the published surface of the SDK. PyPI consumers see whatever shows up there. Skipping `develop` skips the integration soak that protects against accidentally shipping a half-baked change. diff --git a/specs/04-testing.md b/specs/04-testing.md index 3596dc60..8228c689 100644 --- a/specs/04-testing.md +++ b/specs/04-testing.md @@ -265,6 +265,10 @@ An earlier plan hedged that `-n 8` might need (a) poll windows scaled by `PYTEST The runner uses `--dist worksteal` (idle workers steal queued tests from busy ones — ≥ static `load` for tail balance; `loadscope` is avoided because it groups by module and would *concentrate* the heavy live tests on fewer workers). `conftest.py`'s `pytest_collection_modifyitems` then front-loads the long-pole live tests so they start at t=0 and the ~100 unit/respx tests backfill the tail. Both are deterministic (keyed on `nodeid`) so every xdist worker collects the same order. +`poll_equals` / `poll_equals_async` (in `_e2e_helpers.py`) is the read-after-write helper: poll a zero-arg `read` until it returns `want`. Use it for any assertion that reads back what the test just wrote through a replica-backed GET — on the e2e stack the replica *is* the primary so the first read usually wins, but a real-replica stack lags and the assertion flakes. The changed-since-freeze one flakes **silently** (a stale source body reads as "unchanged"), which is why it polls rather than sleeps. + +**`want` must never be `None`, and the helper refuses it.** Not-found during the lag window is treated as "not yet" and yields `None`, so `want=None` would compare equal and turn a *vanished* resource into a passing assertion. Poll a boolean instead — `read` returning `value is None`, `want=True`. Note the mirror-image limit: a `False` poll cannot ride out a stale `False`, so it only proves the value settled, not that it ever changed. + A few tests submit/dispatch several artifacts in one body; `run_concurrently` / `run_concurrently_async` (in `_e2e_helpers.py`) fan those out **only on the live run** and stay serial on replay — vcrpy patches the transport via `mock.patch`, which isn't thread-safe, and replay no-ops the sleeps anyway, so serial replay is both deterministic and instant (no cassette re-record needed). **These are correctness/scheduling/cleanup wins, not the wall-clock lever.** The suite's floor is the per-scan settle (`window_closed`), which every settle-bound test on a worker's serial chain pays in full. That floor is **not** the xdist scheduling or the job-phase cadence (lowering the e2e periodicity 10→3 provably didn't move it — a single-scan settle stayed ~32s). It is set deterministically at bounty creation by **`bounty_duration`** (the assertion-window length, ~25s of the ~32s) **+ `ARBITER_VOTE_DELAY`** (~1s). `bounty_duration` is an **artifact-index `ScanConfig` field** — the `default` config the suite submits with — so the lever lives in the e2e/artifact-index config, not in this repo. The full bounty lifecycle and these knobs are documented authoritatively in artifact-index `specs/02-bounty-scan-lifecycle.md`. diff --git a/test/async_client_test.py b/test/async_client_test.py index 1a4357ae..657b52f6 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -614,15 +614,17 @@ async def test_async_rules(self, uid): # stack, deterministic rule_count of 1. contents = uid_yara(uid) rule = await api.ruleset_create(uid, contents) - assert rule.name == uid - assert rule.yara == contents - # Tracking fields are live from creation. - assert rule.rule_count == 1 - assert rule.favorite is False - assert rule.favorited_at is None - assert rule.historical_hunt_count == 0 hunt = None + # try opens IMMEDIATELY — see the sync twin: a failed assertion + # must still reach the finally's ruleset_delete. try: + assert rule.name == uid + assert rule.yara == contents + # Tracking fields are live from creation. + assert rule.rule_count == 1 + assert rule.favorite is False + assert rule.favorited_at is None + assert rule.historical_hunt_count == 0 # The e2e may carry leftover rulesets from prior runs; use # a presence assertion instead of an exact count. rules = [r async for r in api.ruleset_list()] diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 4fa23772..8d6e5562 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -585,16 +585,19 @@ def test_rules(self): uid = self._testMethodName contents = uid_yara(uid) rule = api.ruleset_create(uid, contents) - assert rule.name == uid - assert rule.yara == contents - # The tracking fields are live from creation: the body was counted on - # the way in, nothing is starred yet, no hunts have been triggered. - assert rule.rule_count == 1 - assert rule.favorite is False - assert rule.favorited_at is None - assert rule.historical_hunt_count == 0 hunt = None + # try opens IMMEDIATELY: every assertion below is inside it, so a + # failure still reaches the finally's ruleset_delete. A leaked ruleset + # on the shared stack is not free — a starred one holds a favorite slot. try: + assert rule.name == uid + assert rule.yara == contents + # The tracking fields are live from creation: the body was counted + # on the way in, nothing is starred yet, no hunts triggered. + assert rule.rule_count == 1 + assert rule.favorite is False + assert rule.favorited_at is None + assert rule.historical_hunt_count == 0 # listing — the created rule must be in the list; the e2e may carry # other rulesets from earlier runs, so use a presence assertion # rather than an exact count. From 2e0f08a0b21aab0b0a7405f6e7b22c81ff3e8f2f Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 14:06:29 -0300 Subject: [PATCH 33/36] docs(test): drop opaque internal finding codes from public source Two comments carried an "(F9)" review token. AGENTS.md keeps internal references out of published artefacts; the rule names commits and PR text, but a committed source comment outlives both. The sentences read the same without it. --- test/async_client_test.py | 2 +- test/client_scan_test.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/async_client_test.py b/test/async_client_test.py index 657b52f6..125a2d84 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -630,7 +630,7 @@ async def test_async_rules(self, uid): rules = [r async for r in api.ruleset_list()] assert any(r.id == rule.id for r in rules) # Universal arms, not presence-only — an ignored param would - # pass the membership check alone (F9). + # pass the membership check alone. by_name = [r async for r in api.ruleset_list(name=uid)] assert rule.id in {r.id for r in by_name} assert all(uid.lower() in (r.name or '').lower() for r in by_name) diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 8d6e5562..663bd31d 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -607,7 +607,7 @@ def test_rules(self): # Both arms are UNIVERSAL, not presence-only: `rule.id in by_name` # holds identically if the server ignored the param and returned # the unfiltered list, which is exactly the regression a filter - # test exists to catch (F9). + # test exists to catch. by_name = list(api.ruleset_list(name=uid)) assert rule.id in {r.id for r in by_name} assert all(uid.lower() in (r.name or '').lower() for r in by_name) From 3103c969baf4dc6c519ba6e8c1611e90533a87ec Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 14:17:23 -0300 Subject: [PATCH 34/36] test: match the long-pole hint on an exact nodeid, not a substring MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The rules fragment has now been wrong three times — "rules" caught "ruleset", "test_rules" missed "test_async_rules", and "_rules" is itself a prefix of "_ruleset" so it front-loaded the instant unit tests. Every substring of those two test names is a prefix of test_ruleset_*, so no fourth fragment fixes it. Give the matcher a way to say "exactly this test" instead: a fragment starting with "::" is matched as a nodeid SUFFIX. The two long poles now name themselves exactly; every other fragment keeps substring matching, which is right for the ones that legitimately span several tests. Verified: test_rules and test_async_rules rank as long poles, the unit test backfills to the tail. --- test/conftest.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/test/conftest.py b/test/conftest.py index 22114ff3..921a7738 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -121,11 +121,13 @@ async def _noop_async_sleep(*_a, **_k): "sample", # sandbox completion + metadata "stream", # global archiver batching "rescan", # rescan retry loop + settle - "_rules", # test_rules / test_async_rules — live enable/stop + - # ~6 poll loops. NOT "rules" (a prefix of "ruleset", so it - # also matches the instant ruleset_favorite respx suite) - # and NOT "test_rules" (which misses test_async_rules - # entirely — it is test_ + async_rules). + # Exact, because every substring of these two is also a prefix of + # test_ruleset_* — "rules", "test_rules" and "_rules" each caught the + # instant unit tests as well. A "::" fragment is matched as a nodeid + # SUFFIX (see _long_pole_rank), which is the only form that can name a + # test whose name is a prefix of another's. + "::test_rules", # live enable/stop + ~6 poll loops + "::test_async_rules", # the async twin "hash_search", # search-index lag "existence_probe", # submit + settle + search-index lag (the HEAD probe tests) "sandboxtask", # sandbox completion + index lag @@ -135,7 +137,9 @@ async def _noop_async_sleep(*_a, **_k): def _long_pole_rank(item): name = item.nodeid for rank, frag in enumerate(_LONG_POLE_FRAGMENTS): - if frag in name: + # A "::" fragment names one test exactly; anything else is a substring + # hint that may legitimately span several. + if name.endswith(frag) if frag.startswith('::') else frag in name: return rank return len(_LONG_POLE_FRAGMENTS) # unit/respx tests backfill the tail From 9dec6122168e22c6670ac67341ebd8b14901d3e0 Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 14:29:55 -0300 Subject: [PATCH 35/36] refactor: make the result-bound helper private, and stop publishing internals MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `as_result_bound` was listed on the documented public surface, which put a four-line internal helper under "rename or removal of a public symbol = major". Nothing outside this package calls it — not the paired CLI — and every sibling helper in core.py is already underscore-private. Renamed to `_as_result_bound` and dropped from the specs/05 surface listing; specs/01 still records it among the helpers, where it belongs. This repo is public, so two other things should not have been in it: - Production telemetry. specs/05 published request volumes, distinct API-key and user-agent counts, and the observed value range for a parameter. The decision it supports — the wire stays seconds, because re-reading live traffic as minutes widens every window 60x silently — needs none of it. - A deployment's configured page cap. The mechanism (a per-deployment env var, set well below a large bound) is what explains the 400; the number is not. Also stops the spec arguing with its own drafts. "An earlier revision of this document claimed…" and "the MAX_PAGE_SIZE mistake again" describe review history, which git already holds; a spec should read as the current state so a reader does not have to work out which claim is live. --- specs/01-architecture.md | 2 +- specs/05-downstream-contract.md | 23 +++++++++++------------ src/polyswarm_api/aio/api.py | 4 ++-- src/polyswarm_api/api.py | 4 ++-- src/polyswarm_api/core.py | 4 ++-- test/async_client_test.py | 7 +++---- test/client_scan_test.py | 7 +++---- test/hunt_tracking_builder_test.py | 14 +++++++------- 8 files changed, 31 insertions(+), 34 deletions(-) diff --git a/specs/01-architecture.md b/specs/01-architecture.md index 86202de6..d9bea7a4 100644 --- a/specs/01-architecture.md +++ b/specs/01-architecture.md @@ -42,7 +42,7 @@ Hand-written. No I/O. Three sub-concerns: **Resource bases**: `BaseResource`, `BaseJsonResource`. The latter has classmethod builders (`create` / `get` / `head` / `update` / `delete` / `list`) that each return a `PolyswarmRequest` descriptor. Per-domain resources in `resources.py` inherit from `BaseJsonResource` and may add custom classmethods (`ArtifactInstance.search_hash`, `IOC.iocs_by_hash`, etc.) — all returning descriptors. -**Helpers**: `Hashable` + `Hash` + `is_valid_sha1/sha256/md5`, `parse_isoformat`, `_normalise_bool_params`, `RequestParamsEncoder`, `as_result_bound` (the one definition of a caller's result bound), `_raise_for_status` (the shared non-2xx → typed-exception mapper, used by both `parse_response` and the session's streaming-download path). Downloads stream straight to their destination from the session — there is no response adapter; see [`99-open-questions.md`](./99-open-questions.md) §"Streaming downloads". +**Helpers**: `Hashable` + `Hash` + `is_valid_sha1/sha256/md5`, `parse_isoformat`, `_normalise_bool_params`, `RequestParamsEncoder`, `_as_result_bound` (the one definition of a caller's result bound — private, like its sibling helpers: nothing outside this package calls it), `_raise_for_status` (the shared non-2xx → typed-exception mapper, used by both `parse_response` and the session's streaming-download path). Downloads stream straight to their destination from the session — there is no response adapter; see [`99-open-questions.md`](./99-open-questions.md) §"Streaming downloads". ### Layer 2 — transport (`session.py` / `aio/session.py`) diff --git a/specs/05-downstream-contract.md b/specs/05-downstream-contract.md index 11b78639..77d0be8c 100644 --- a/specs/05-downstream-contract.md +++ b/specs/05-downstream-contract.md @@ -135,7 +135,6 @@ class Hash(Hashable): ... def is_valid_sha1 / _sha256 / _md5(value) -> bool def parse_isoformat(date_string) -def as_result_bound(max_results) # None / 0 / negative -> None (no bound) ``` These are stable but less curated than the top-level exports. Downstream callers that subclass `BaseJsonResource` to add custom resource types are supported. Downstream callers that construct `PolyswarmRequest` manually and hand it to `session.execute` are supported. @@ -314,18 +313,18 @@ Migrating from 3.x to 4.0, callers retain: Moving the *wire* to minutes was considered and rejected. Every surface around the parameter was written for minutes (the CLI's old `1440` default was `24 * 60`), so re-basing the server looked like the fix that made all three - agree — but the endpoint takes ~197k requests carrying `since` per 30 days - from 10 distinct API keys and 12 user agents, all SDK or script clients, - with values from `2100` to `2592000`. Re-reading those as minutes widens - every one 60x and returns more data with no error. The wire stays seconds; + agree — but the endpoint carries substantial live traffic passing `since`, from + SDK and script clients outside our control, across a wide range of values. + Re-reading every one of those as minutes widens each window 60x and returns + more data with no error, silently. The wire stays seconds; the one caller in our control (the CLI's default) was corrected instead. - **`since` absent or `0` means no time filter at all** — the feed pages over everything. That is the server's contract (it applies the filter on a truthiness test), and it is what a caller wanting the full history relies - on. An earlier revision of this document claimed the server was tightening - this to `is not None` so that `since=0` would mean an empty window: no such - change was ever made, and the opposite is the intended semantics. + on. Note the shape of the server-side test: it is truthiness, not + `is not None`, and tightening it would turn `since=0` into an empty window + rather than no filter. - **`live_feed(max_results=)` is new and additive.** It defaults to `None`, which is the historical behaviour — every page. It bounds how many results @@ -336,10 +335,10 @@ Migrating from 3.x to 4.0, callers retain: page is the server's to choose (50 for the web service, capped by `AI_MAX_QUERY_RESULTS`), and `_next_page` echoes the size it reports back on each subsequent request; a bounded read keeps paginating in those same small, - API-friendly chunks and simply stops once it has enough. An earlier revision - sent `limit=max_results`, which conflated the two — and, since the cap is an - env var each deployment sets (300 in the chart), would have turned a large - bound into a 400. + API-friendly chunks and simply stops once it has enough. Sending + `limit=max_results` would conflate the two — and, since the cap is an + env var each deployment sets — and set well below a large bound — would have + turned that bound into a 400. ### Required code changes diff --git a/src/polyswarm_api/aio/api.py b/src/polyswarm_api/aio/api.py index 4f3e5741..22a3ad0a 100644 --- a/src/polyswarm_api/aio/api.py +++ b/src/polyswarm_api/aio/api.py @@ -18,7 +18,7 @@ import time from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest, as_result_bound +from polyswarm_api.core import PolyswarmRequest, _as_result_bound from .session import AsyncPolyswarmSession @@ -520,7 +520,7 @@ async def live_feed(self, since=None, rule_name=None, family=None, None, 0 or a negative means no bound: every page, as before. :return: Generator of HuntResult resources """ - bound = as_result_bound(max_results) + bound = _as_result_bound(max_results) yielded = 0 async for item in self._paginate(resources.LiveHuntResult.list( self, since=since, rule_name=rule_name, family=family, diff --git a/src/polyswarm_api/api.py b/src/polyswarm_api/api.py index 92d78562..3e67d983 100644 --- a/src/polyswarm_api/api.py +++ b/src/polyswarm_api/api.py @@ -20,7 +20,7 @@ import logging from polyswarm_api import exceptions, resources, settings -from polyswarm_api.core import PolyswarmRequest, as_result_bound +from polyswarm_api.core import PolyswarmRequest, _as_result_bound from .session import PolyswarmSession @@ -587,7 +587,7 @@ def live_feed( None, 0 or a negative means no bound: every page, as before. :return: Generator of HuntResult resources """ - bound = as_result_bound(max_results) + bound = _as_result_bound(max_results) yielded = 0 for item in self._paginate( resources.LiveHuntResult.list( diff --git a/src/polyswarm_api/core.py b/src/polyswarm_api/core.py index 500d6801..cbf0ffeb 100644 --- a/src/polyswarm_api/core.py +++ b/src/polyswarm_api/core.py @@ -17,7 +17,7 @@ ``list``) construct ``PolyswarmRequest`` descriptors. - ``Hashable`` + ``is_valid_*`` validators, ``parse_isoformat``, ``_normalise_bool_params``, ``RequestParamsEncoder``, - ``as_result_bound``. + ``_as_result_bound``. Both transports import from here. """ @@ -669,7 +669,7 @@ def list(cls, api, **kwargs): ) -def as_result_bound(max_results): +def _as_result_bound(max_results): """The caller's result bound, or None when there isn't one. None, 0 and negatives all mean "no bound". diff --git a/test/async_client_test.py b/test/async_client_test.py index 125a2d84..8d7bf462 100644 --- a/test/async_client_test.py +++ b/test/async_client_test.py @@ -644,10 +644,9 @@ async def test_async_rules(self, uid): assert fav.favorited_at is not None # limit is a PIN (fixed product cap); used is a BOUND (the # stack budget is shared across runs) - # The cap is a per-deployment setting (AI_FAVORITE_RULESETS_LIMIT), - # so pin the RELATION, not the number: an exact pin is the - # MAX_PAGE_SIZE mistake again — mirroring a code default the - # deployment overrides, which fails a live run with VCR off. + # The cap is a per-deployment setting, so pin the RELATION rather + # than the number: an exact pin mirrors a code default the + # deployment can override, and fails a live run with VCR off. assert fav.favorites_limit >= 1 assert 1 <= fav.favorites_used <= fav.favorites_limit # The star was written on the line above — the sharpest diff --git a/test/client_scan_test.py b/test/client_scan_test.py index 663bd31d..912bed55 100644 --- a/test/client_scan_test.py +++ b/test/client_scan_test.py @@ -620,10 +620,9 @@ def test_rules(self): assert fav.favorited_at is not None # the limit is a PIN (the fixed product cap, no plan scaling); # used is a BOUND because the stack budget is shared across runs - # The cap is a per-deployment setting (AI_FAVORITE_RULESETS_LIMIT), - # so pin the RELATION, not the number: an exact pin is the - # MAX_PAGE_SIZE mistake again — mirroring a code default the - # deployment overrides, which fails a live run with VCR off. + # The cap is a per-deployment setting, so pin the RELATION rather + # than the number: an exact pin mirrors a code default the + # deployment can override, and fails a live run with VCR off. assert fav.favorites_limit >= 1 assert 1 <= fav.favorites_used <= fav.favorites_limit # The star was written on the line above — the sharpest diff --git a/test/hunt_tracking_builder_test.py b/test/hunt_tracking_builder_test.py index 6de5e4fb..1aefe79d 100644 --- a/test/hunt_tracking_builder_test.py +++ b/test/hunt_tracking_builder_test.py @@ -150,15 +150,15 @@ def test_list_routes_livescan_id_to_the_query_as_digit_string(self): 'community': 'gamma'} class TestResultBound: - """``core.as_result_bound`` — one definition of "is there a bound".""" + """``core._as_result_bound`` — one definition of "is there a bound".""" def test_no_bound_forms(self): for no_bound in (None, 0, -1): - assert core.as_result_bound(no_bound) is None + assert core._as_result_bound(no_bound) is None def test_a_real_bound_passes_through_unclamped(self): - assert core.as_result_bound(5) == 5 - assert core.as_result_bound(10_000) == 10_000 + assert core._as_result_bound(5) == 5 + assert core._as_result_bound(10_000) == 10_000 class TestLiveFeedMaxResults: @@ -197,9 +197,9 @@ def test_zero_is_no_bound_not_a_bound_of_one(self): class TestLiveFeedLimitOnTheWire: """``max_results`` is a total, so it must not reach the wire as ``limit``. - The page stays the server's to choose and the read keeps paginating in those - chunks; sending the total as a page size also 400s above the deployment's - AI_MAX_QUERY_RESULTS (300 in the chart). + The page stays the server's to choose and the read keeps paginating in + those chunks; sending the total as a page size also 400s above whatever + per-page cap the deployment configures. """ @staticmethod From 0d6c5e4a5af1b9bccf3be7004027d4bfdaee5a9e Mon Sep 17 00:00:00 2001 From: Samuel Date: Mon, 31 Aug 2026 15:09:56 -0300 Subject: [PATCH 36/36] docs: the bump exception rests on the consumer resolving this repo from source MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The bullet read as if any sibling needing a new surface justifies bumping the version in a feature PR. It does not. The exception exists because a floor cannot name a version this repo has not declared — which is only a problem for a consumer whose CI installs this repo from source by branch and can therefore adopt before publication. A consumer that installs published artifacts has no such need: it adopts after the release, and this repo bumps at its own release step as usual. Stating the condition keeps the exception from being applied where it does not hold. --- AGENTS.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/AGENTS.md b/AGENTS.md index dcf3a5e4..29637b27 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -40,7 +40,7 @@ feature/* ─┐ - **`develop → master` PRs are how `master` advances.** They're opened by a maintainer when a release-worthy batch of work is on `develop`. Most contributors never open one of these. - **Direct PRs to `master`** are wrong. If you opened one, close it, branch off `develop` instead, and re-open against `develop`. - **PyPI release happens automatically** when `pyproject.toml`'s `version` changes on `master`. Don't bump the version inside a feature PR unless the maintainer specifically asks — version bumps belong to the `develop → master` step. -- **The standing exception: a downstream floor that must point at this change.** (This is the SDK-side instance of a workspace-level standard — *cross-repo dependencies are a version pin, not a runtime probe* — not a rule this repo grants itself.) When a sibling repo needs a surface this PR adds, that repo raises its `polyswarm_api>=` floor to the version introducing it — and the floor cannot name a version this repo has not declared yet. So the bump lands **here, in the feature PR**, not at the release step. Bump with `bump-my-version` and **check the emitted string is a clean `X.Y.0`**: the config can serialize a `.devN+sha` form, and PEP 440 orders `4.4.0.dev0 < 4.4.0`, so a dev suffix silently fails the sibling's floor and sends its CI to PyPI for a version that does not exist yet. +- **The standing exception: a downstream floor that must point at this change.** (This is the SDK-side instance of a workspace-level standard — *cross-repo dependencies are a version pin, not a runtime probe* — not a rule this repo grants itself.) It applies on one condition: the sibling's CI resolves this repo **from source** by branch name, so it can test against an unpublished version. When that holds, the sibling raises its `polyswarm_api>=` floor to the version introducing the surface — and that floor cannot name a version this repo has not declared yet, so the bump lands **here, in the feature PR**, not at the release step. A consumer that installs only published artifacts has no such need: it adopts after the release, and this repo bumps at its own release step as usual. Bump with `bump-my-version` and **check the emitted string is a clean `X.Y.0`**: the config can serialize a `.devN+sha` form, and PEP 440 orders `4.4.0.dev0 < 4.4.0`, so a dev suffix silently fails the sibling's floor and sends its CI to PyPI for a version that does not exist yet. **Why this matters:** `master` is the published surface of the SDK. PyPI consumers see whatever shows up there. Skipping `develop` skips the integration soak that protects against accidentally shipping a half-baked change.