A missing Kick emote is logged as an out-of-root media request #240

Closed
opened 2026-10-01 23:59:57 -04:00 by Salastil · 1 comment
Owner

[media] refused out-of-root request: ~/.cache/nobilis/kick-emotes/5273243.gif - the path is inside the allowed root; the file simply does not exist. isAllowed treats a failed realpath as a refusal, so a missing file and an attack on the media boundary log the same line.

Two things:

  • Log a missing file as missing, and answer it as a 404, not a refusal.
  • Find why an emote is referenced before (or without) its file being on disk: the emote draws as a broken image. Seen twice in the current log.
`[media] refused out-of-root request: ~/.cache/nobilis/kick-emotes/5273243.gif` - the path is inside the allowed root; the file simply does not exist. `isAllowed` treats a failed realpath as a refusal, so a missing file and an attack on the media boundary log the same line. Two things: - Log a missing file as missing, and answer it as a 404, not a refusal. - Find why an emote is referenced before (or without) its file being on disk: the emote draws as a broken image. Seen twice in the current log.
Salastil added this to the v1.0 milestone 2026-10-01 23:59:57 -04:00
Salastil added the bug label 2026-10-01 23:59:57 -04:00
Author
Owner
Finished https://git.salastil.com/Salastil/moho/commit/70cd8d707f72f8fc6dec7c15a31089cd9c0144da https://git.salastil.com/Salastil/moho/commit/0a6b566b7e81b83419503ba627e7e985a7229c91
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Salastil/moho#240