in reply to Re: prevent arbitrary code execution in images
in thread prevent arbitrary code execution in images
2) Prevent them from being executed by the client. Enforce the extention as mentioned above. Try loading the upload in an image info package. (Perhaps ImageMagick or Image-Info?) If the package doesn't recognize the upload as an image, and if it's not a JPEG, GIF or PNG, reject the upload.
I could be mistaken, but I think the OP's concerned about the JPEG of Death. I don't know enough about the hole to be certain, but I don't think that just checking headers is going to be enough.
--
F
o
x
t
r
o
t
U
n
i
f
o
r
m
Found a typo in this node? /msg me
% man 3 strfry
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: prevent arbitrary code execution in images
by ikegami (Patriarch) on Sep 15, 2004 at 23:26 UTC | |
by FoxtrotUniform (Prior) on Sep 15, 2004 at 23:33 UTC | |
by pingo (Hermit) on Sep 16, 2004 at 10:09 UTC | |
by paulbort (Hermit) on Sep 16, 2004 at 23:48 UTC | |
by PodMaster (Abbot) on Sep 16, 2004 at 02:30 UTC | |
by graff (Chancellor) on Sep 16, 2004 at 03:19 UTC |