[img] hardening

This commit is contained in:
Devin Zuczek
2026-10-22 12:21:21 -04:00
parent 3cf4b4029e
commit 605a35c36b
7 changed files with 94 additions and 34 deletions
@@ -189,7 +189,7 @@ it('POST /upload refuses an Image (FileType 3) whose bytes are not an image', as
body: form,
})
expect(res.status).toBe(400)
expect(await res.json()).toEqual({ error: 'file is not a PNG, JPEG, GIF, WebP or BMP image' })
expect(await res.json()).toEqual({ error: 'file is not a PNG or JPEG image' })
})
it('POST /upload stores an Image (FileType 3) under the type its bytes say, not the claim', async () => {