[wp-trac] [WordPress Trac] #37719: Pre/Post Unzip Hooks
WordPress Trac
noreply at wordpress.org
Thu Aug 18 15:57:28 UTC 2016
#37719: Pre/Post Unzip Hooks
-----------------------------+-----------------------------
Reporter: dfavor | Owner:
Type: feature request | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Filesystem API | Version: trunk
Severity: normal | Keywords:
Focuses: |
-----------------------------+-----------------------------
Add Pre/Post hooks to unzip logic, providing groundwork for advanced
Malware scanning + advanced role management by interacting with OS using
chattr facility to enforce super admin capabilities, requiring OS level
authentication prior to taking action on any zipfile contents.
Logic...
1) Refactor _unzip_file_pclzip() + _unzip_file_ziparchive() merge into
single function + merge common code.
2) Hooks...
required_disk_space - notify how much additional disk space required
required_directories - notify list of missing directories, which will be
created
pre_unzip - return zipfile path + archive component name if applicable
post_unzip - return zipfile path + unzip directory + archive component
name if applicable
3) Additionally, zipfile source propagation could be highly useful.
Either local filesystem reference or download URL.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/37719>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list