Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mrsarm committed Aug 6, 2024
1 parent b171e88 commit 3c64434
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 17 deletions.
10 changes: 6 additions & 4 deletions test/vcr/test_sandboxtask_latest.vcr
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,16 @@ interactions:
uri: http://localhost:9696/v3/sandbox/sandboxtask/latest?community=gamma&sha256=a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427&sandbox=triage
response:
body:
string: '{"result":{"account_number":null,"community":"gamma","created":"2023-06-15T21:45:28.101404","expiration":"2023-06-15T22:15:28.103952","id":79194629748428026,"instance_id":29206071649051056,"report":{"analysis":{"score":1},"extracted":null,"extracted_c2_ip_port":[],"extracted_c2_ips":[],"malware_family":[],"sample_id":"230615-1l936aghce","targets":[{"md5":"ecbcbde87b9837f89600f8f14f6a4914","score":1,"sha1":"c2aa803de3ab0b05ce91b75ebb417a8036baf845","sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","sha512":"acd689f74db9b9fded23052d67005c804f4512cc2df1d5211363ab563ec3ca223afed18bddbd04349e1f832327a65bd25053d0cf5ab92534e96b1c88dad7467f","signatures":[],"size":29696,"ssdeep":"384:mRrObUH/O49wvPabV2CIbbMhXSEH8fYqmpli8GsXZHM6KHhowhjllWAwsuEJgc94:+SbUfOLabiQhClQqmpH7Xshowlagg3","target":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","tasks":["behavioral1"]}],"ttp":[],"version":"0.2.3"},"sandbox":"triage","sandbox_artifacts":[{"created":"2023-06-15T21:47:32.002352","extended_type":"","id":21755372058606205,"instance_id":31497826053491540,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"raw_report"},{"created":"2023-06-15T21:47:32.122171","extended_type":"","id":12449312837755461,"instance_id":35484512444472164,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"report"},{"created":"2023-06-15T21:47:32.235794","extended_type":"","id":19341855132421787,"instance_id":7453203384960244,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"dropped_file"},{"created":"2023-06-15T21:47:32.342544","extended_type":"","id":44791142811316959,"instance_id":76628996374670532,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"dropped_file"}],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"SUCCEEDED","team_account_number":null,"upload_url":null},"status":"OK"}

string: '{"result":{"account_number":null,"community":"gamma","created":"2023-06-15T21:45:28.101404","expiration":"2023-06-15T22:15:28.103952","id":79194629748428026,"instance_id":29206071649051056,"report":{"analysis":{"score":1},"extracted":null,"extracted_c2_ip_port":[],"extracted_c2_ips":[],"malware_family":[],"sample_id":"230615-1l936aghce",
"targets":[{"md5":"ecbcbde87b9837f89600f8f14f6a4914","score":1,"sha1":"c2aa803de3ab0b05ce91b75ebb417a8036baf845","sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","sha512":"acd689f74db9b9fded23052d67005c804f4512cc2df1d5211363ab563ec3ca223afed18bddbd04349e1f832327a65bd25053d0cf5ab92534e96b1c88dad7467f","signatures":[],"size":29696,"ssdeep":"384:mRrObUH/O49wvPabV2CIbbMhXSEH8fYqmpli8GsXZHM6KHhowhjllWAwsuEJgc94:+SbUfOLabiQhClQqmpH7Xshowlagg3","target":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","tasks":["behavioral1"]}],"ttp":[],"version":"0.2.3"},"sandbox":"triage","sandbox_artifacts":[{"created":"2023-06-15T21:47:32.002352","extended_type":"","id":21755372058606205,"instance_id":31497826053491540,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"raw_report"},{"created":"2023-06-15T21:47:32.122171","extended_type":"","id":12449312837755461,"instance_id":35484512444472164,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"report"},{"created":"2023-06-15T21:47:32.235794","extended_type":"","id":19341855132421787,"instance_id":7453203384960244,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"dropped_file"},{"created":"2023-06-15T21:47:32.342544","extended_type":"","id":44791142811316959,"instance_id":76628996374670532,"mimetype":"","name":"","sandbox_task_id":79194629748428026,"type":"dropped_file"}],
"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"SUCCEEDED","team_account_number":null,"upload_url":null,
"config":{"network_enabled":false,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"vm":{}},
"artifact": {"extended_type":null,"filename":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","mimetype":"text/plain","size":68}
},"status":"OK"}
'
headers:
Connection:
- close
Content-Length:
- '1916'
Content-Type:
- application/json
Date:
Expand Down
21 changes: 12 additions & 9 deletions test/vcr/test_sandboxtask_list.vcr
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ interactions:
uri: http://localhost:9696/v3/sandbox/sandboxtask/list?sha256=a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427&sandbox=cape
response:
body:
string: '{"has_more":false,"limit":2,"result":[{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:10.888312","expiration":"2023-06-15T22:18:10.912402","id":18386687899234139,"instance_id":86147028965243383,"report":{},"sandbox":"cape","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"PENDING","team_account_number":null,"upload_url":null,"config":{"artifact_type":"FILE","browser":null,"network_enabled":true,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"target":"malicious-enc.zip","vm":{}},"artifact":{"extended_type":null,"filename":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","mimetype":"text/plain","size":68}}],"status":"OK"}'
string: '{"has_more":false,"limit":2,"result":[
{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:10.888312","expiration":"2023-06-15T22:18:10.912402","id":18386687899234139,"instance_id":86147028965243383,"report":{},"sandbox":"cape","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"PENDING","team_account_number":null,"upload_url":null,"config":{"artifact_type":"FILE","browser":null,"network_enabled":true,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"target":"malicious-enc.zip","vm":{}},"artifact":{"extended_type":null,"filename":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","mimetype":"text/plain","size":68}}
],"status":"OK"}'
headers:
Connection:
- close
Expand Down Expand Up @@ -50,14 +52,13 @@ interactions:
uri: http://localhost:9696/v3/sandbox/sandboxtask/list?sha256=a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427&sandbox=triage
response:
body:
string: '{"has_more":false,"limit":2,"result":[{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:11.039633","expiration":"2023-06-15T22:18:11.058878","id":24074805227357027,"instance_id":86147028965243383,"report":{},"sandbox":"triage","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"SUCCEEDED","team_account_number":null,"upload_url":null}],"status":"OK"}

string: '{"has_more":false,"limit":2,"result":[
{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:11.039633","expiration":"2023-06-15T22:18:11.058878","id":24074805227357027,"instance_id":86147028965243383,"report":{},"sandbox":"triage","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"SUCCEEDED","team_account_number":null,"upload_url":null,
"config":{"artifact_type":"FILE","browser":null,"network_enabled":true,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"target":"malicious-enc.zip","vm":{}},
"artifact": {"extended_type":null,"filename":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","mimetype":"text/plain","size":68}}
],"status":"OK"}
'
headers:
Connection:
- close
Content-Length:
- '430'
Content-Type:
- application/json
Date:
Expand Down Expand Up @@ -86,8 +87,10 @@ interactions:
uri: http://localhost:9696/v3/sandbox/sandboxtask/list?sha256=a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427
response:
body:
string: '{"has_more":false,"limit":2,"result":[{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:11.039633","expiration":"2023-06-15T22:18:11.058878","id":24074805227357027,"instance_id":86147028965243383,"report":{},"sandbox":"triage","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"SUCCEEDED","team_account_number":null,"upload_url":null},{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:10.888312","expiration":"2023-06-15T22:18:10.912402","id":18386687899234139,"instance_id":86147028965243383,"report":{},"sandbox":"cape","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"PENDING","team_account_number":null,"upload_url":null}],"status":"OK"}

string: '{"has_more":false,"limit":2,"result":[
{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:11.039633","expiration":"2023-06-15T22:18:11.058878","id":24074805227357027,"instance_id":86147028965243383,"report":{},"sandbox":"triage","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"SUCCEEDED","team_account_number":null,"upload_url":null,"config":{"artifact_type":"FILE","browser":null,"network_enabled":true,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"target":"malicious-enc.zip","vm":{}},"artifact":{"extended_type":null,"filename":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","mimetype":"text/plain","size":68}},
{"account_number":null,"community":"gamma","created":"2023-06-15T21:48:10.888312","expiration":"2023-06-15T22:18:10.912402","id":18386687899234139,"instance_id":86147028965243383,"report":{},"sandbox":"cape","sandbox_artifacts":[],"sha256":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","status":"PENDING","team_account_number":null,"upload_url":null,"config":{"artifact_type":"FILE","browser":null,"network_enabled":true,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"target":"malicious-enc.zip","vm":{}},"artifact":{"extended_type":null,"filename":"a709f37b3a50608f2e9830f92ea25da04bfa4f34d2efecfd061de9f29af02427","mimetype":"text/plain","size":68}}
],"status":"OK"}
'
headers:
Connection:
Expand Down
7 changes: 3 additions & 4 deletions test/vcr/test_sandboxtask_submit.vcr
Original file line number Diff line number Diff line change
Expand Up @@ -64,14 +64,13 @@ interactions:
body:
string: '{"result":{"account_number":null,"community":"gamma","config":{"network_enabled":false,"provider":{"id":"2","name":"triage","slug":"triage","tool":"triage_sandbox_v0"},"vm":{"Architecture":"x64","id":"200","language":"English
(United States)","name":"windows10-1703-x64","os_name":"Windows 10 1703 x64","os_version":"10.0.15063
Build 15063","profile":"poly","slug":"win10-build-15063"}},"created":"2023-10-19T23:01:58.738858","expiration":"2023-10-19T23:31:58.753992","id":"68144286666617241","instance_id":"24135952517649903","report":{},"sandbox":"triage","sandbox_artifacts":[],"sha256":"275a021bbfb6489e54d471899f7db9d1663fc695ec2fe2a2c4538aabf651fd0f","status":"PENDING","team_account_number":null,"upload_url":null},"status":"OK"}

Build 15063","profile":"poly","slug":"win10-build-15063"}},"created":"2023-10-19T23:01:58.738858","expiration":"2023-10-19T23:31:58.753992","id":"68144286666617241","instance_id":"24135952517649903","report":{},"sandbox":"triage","sandbox_artifacts":[],"sha256":"275a021bbfb6489e54d471899f7db9d1663fc695ec2fe2a2c4538aabf651fd0f","status":"PENDING","team_account_number":null,"upload_url":null,
"artifact": {"extended_type":null,"filename":"275a021bbfb6489e54d471899f7db9d1663fc695ec2fe2a2c4538aabf651fd0f","mimetype":"text/plain","size":68}
},"status":"OK"}
'
headers:
Connection:
- keep-alive
Content-Length:
- '737'
Content-Type:
- application/json
Date:
Expand Down

0 comments on commit 3c64434

Please # to comment.