Opened 17 years ago
Closed 17 years ago
#10650 closed defect (bug) (fixed)
eval() in wp-admin/includes/class-pclzip.php should be replaced
| Reported by: | Hans Spath | Owned by: | westi |
|---|---|---|---|
| Priority: | normal | Milestone: | 2.9 |
| Component: | Administration | Version: | |
| Severity: | normal | Keywords: | |
| Cc: | Focuses: |
Description
On some systems eval() is disabled due to security reasons.
In wp-admin/includes/class-pclzip.php eval() is used several times like this:
// ----- Call the callback
// Here I do not use call_user_func() because I need to send a reference to the
// header.
eval('$v_result = '.$p_options[PCLZIP_CB_PRE_ADD].'(PCLZIP_CB_PRE_ADD, $v_local_header);');
It's true that passing references with call_user_func() is a problem, but you can use either
$v_result = $p_options[PCLZIP_CB_PRE_ADD] (PCLZIP_CB_PRE_ADD, $v_local_header);
or
$v_result = call_user_func_array($p_options[PCLZIP_CB_PRE_ADD], array(PCLZIP_CB_PRE_ADD, &$v_local_header));
instead.
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Looking into the best solution for this.
Trying to work with the upstream developer to get this changed.