In brief
zipfile can list ZIP members and read individual files. This allows expected names and sizes to be inspected before extracting everything.
Useful to know
zipfile can list ZIP members and read individual files. This allows expected names and sizes to be inspected before extracting everything. [1]
Untrusted archives need scope and resource limits. Compressed size alone does not show how much space the expanded data will occupy. Extraction cannot replace a policy defining which files are acceptable.
Sources
For further detail and to check the information: