WS_OK_7.4.33 HEX
HEX
Server: nginx/1.21.4
System: Linux v12674 6.8.0-85-generic #85-Ubuntu SMP PREEMPT_DYNAMIC Thu Sep 18 15:26:59 UTC 2025 x86_64
User: endtheignorance (1014)
PHP: 7.4.33
Disabled: exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source
Upload Files
File: /storage/v12674/lcalosangeles/public_html/wp-content/plugins/autoupdater/lib/Task/ChildUpdate.php
<?php
defined('AUTOUPDATER_LIB') or die;

class AutoUpdater_Task_ChildUpdate extends AutoUpdater_Task_Base
{
    protected $encrypt = false;

    /** @var AutoUpdater_Request */
    protected $request;

    /**
     * @return array
     */
    public function doTask()
    {
        $query = array(
            'provider' => $this->input('provider', 'wpengine')
        );
        $site_id = $this->input('site_id');

        $this->request = AutoUpdater_Request::api('GET', 'sites/download/worker.zip', $query, '', $site_id);
        add_filter('http_request_args', array($this, 'addDownloadRequestHeaders'), 10, 2);

        $this->setInput('type', 'plugin');
        $this->setInput('slug', AUTOUPDATER_WP_PLUGIN_SLUG);
        $this->setInput('path', $this->request->getUrl());

        /** @see AutoUpdater_Task_ExtensionUpdate::doTask() */
        return AutoUpdater_Task::getInstance('ExtensionUpdate', $this->payload)
            ->doTask();
    }

    /**
     * @param array  $parsed_args An array of HTTP request arguments.
     * @param string $url         The request URL.
     *
     * @return array $parsed_args
     */
    public function addDownloadRequestHeaders($parsed_args = array(), $url = '')
    {
        if (strpos($url, $this->request->url) === 0 && isset($parsed_args['headers']) && is_array($parsed_args['headers'])) {
            $parsed_args['headers'] = array_merge($parsed_args['headers'], $this->request->headers);
        }

        return $parsed_args;
    }
}