Cormack, Ken wrote:

Something like the following would probably serve as a basis for inspecting
"the magic" of a zip archive, regardless of filename extension.  This
particular example looks to see if the first 2 bytes are "MZ", but this
could be changed to look for "PK", instead...

You might want to be careful doing this for zip files. Java .jar files and OpenOffice documents both use the zip format as a container and have "PK" as their "magic".


Cheers,
Dave
--
Dave O'Neill <[EMAIL PROTECTED]>    Roaring Penguin Software Inc.
+1 (613) 231-6599 ext. 104               http://www.roaringpenguin.com/
_______________________________________________
Visit http://www.mimedefang.org and http://www.canit.ca
MIMEDefang mailing list
[EMAIL PROTECTED]
http://lists.roaringpenguin.com/mailman/listinfo/mimedefang

Reply via email to