Validate final PNG workloads and retain applicable evidence

This commit is contained in:
Artyom
2026-11-06 22:21:55 +03:00
parent 5e49502ae7
commit 4ed889c1e4
77 changed files with 7407 additions and 51 deletions
@@ -0,0 +1,126 @@
{
"commit": "5e49502ae78fa48b992c97418e490666c699726d",
"negative": [
{
"case": "broken-idat",
"bytes": 74,
"sha256": "f69b6f437e8069914e8e13a761e9c668fcf45aa93f9dbf4e4da109dc49ffbf43",
"status": 415,
"headers": {
"content-length": "175",
"content-type": "application/json",
"x-request-id": "247a44e0-0ede-4825-8112-cefd8ba457a6",
"x-instance-id": "b853647278e7"
},
"response": {
"error": {
"code": "unsupported_media_type",
"message": "изображение повреждено или обрезано",
"request_id": "247a44e0-0ede-4825-8112-cefd8ba457a6"
}
}
},
{
"case": "duplicate-ihdr",
"bytes": 94,
"sha256": "ca1c6483affee11cde4a5f91fdc6f09558951fb2108f044acd4c1eb5b85423fc",
"status": 415,
"headers": {
"content-length": "191",
"content-type": "application/json",
"x-request-id": "a303ea2f-27f8-4112-b28a-e0390820f7d4",
"x-instance-id": "be7bd4c0acb6"
},
"response": {
"error": {
"code": "unsupported_media_type",
"message": "содержимое не является изображением PNG или JPEG",
"request_id": "a303ea2f-27f8-4112-b28a-e0390820f7d4"
}
}
}
],
"before": {
"objects": 7,
"rows": 7,
"counts": {
"orphan_stale": 0,
"orphan_fresh": 0,
"missing_referenced": 0,
"missing_unreferenced": 0,
"size_mismatch": 0,
"sha_mismatch": 0,
"pending_stale_with_object": 0,
"pending_stale_without_object": 0,
"pending_fresh": 0,
"quarantined": 0,
"incomplete_stale": 0,
"incomplete_fresh": 0,
"lost_ready": 0
}
},
"after": {
"objects": 7,
"rows": 7,
"counts": {
"orphan_stale": 0,
"orphan_fresh": 0,
"missing_referenced": 0,
"missing_unreferenced": 0,
"size_mismatch": 0,
"sha_mismatch": 0,
"pending_stale_with_object": 0,
"pending_stale_without_object": 0,
"pending_fresh": 0,
"quarantined": 0,
"incomplete_stale": 0,
"incomplete_fresh": 0,
"lost_ready": 0
}
},
"positive": [
{
"kind": "image/png",
"status": 201,
"response": {
"id": "01a1b244-0816-736e-8dc4-658722701245",
"chat_id": "01a1b244-0178-7406-bb1b-a932400b65f3",
"owner_id": "01a1b244-012f-77e8-a9bf-26d2790431bd",
"filename": "valid-image",
"content_type": "image/png",
"size_bytes": 111817,
"sha256": "99ea7533c441f79cd630d15ce4d58d1ec4e06f6f0efb3b77a5c088305cd1bd75",
"status": "ready",
"variants": [],
"error_code": null,
"created_at": "2026-11-06T19:09:25.398541Z",
"updated_at": "2026-11-06T19:09:25.404178Z"
},
"download_status": 200,
"content_type": "image/png",
"bytes_match": true
},
{
"kind": "image/jpeg",
"status": 201,
"response": {
"id": "01a1b244-0827-732c-8ef5-3224f274bc8e",
"chat_id": "01a1b244-0178-7406-bb1b-a932400b65f3",
"owner_id": "01a1b244-012f-77e8-a9bf-26d2790431bd",
"filename": "valid-image",
"content_type": "image/jpeg",
"size_bytes": 160987,
"sha256": "556c8acc96f68d4f6442f87e5e09300221b4830e9f44ffe694094761a6b74c28",
"status": "ready",
"variants": [],
"error_code": null,
"created_at": "2026-11-06T19:09:25.415344Z",
"updated_at": "2026-11-06T19:09:25.419901Z"
},
"download_status": 200,
"content_type": "image/jpeg",
"bytes_match": true
}
],
"ok": true
}