PluginProbe
The WP Remote WordPress Plugin / trunk
The WP Remote WordPress Plugin vtrunk
6.72 6.69 6.65 6.62 6.48 6.47 4.87 4.97 5.05 5.09 5.16 5.22 5.24 5.25 5.38 5.41 5.42 5.45 5.47 5.53 5.56 5.65 5.68 5.72 5.73 All 53 releases
← All changes | callback/request.php +14 -7 6.62trunk View file →
@@ -6,8 +6,10 @@
6 6 public $params;
7 7 public $method;
8 8 public $wing;
9 9 public $is_afterload;
10 + public $is_aftershutdown;
11 + public $keep_page_output;
10 12 public $is_admin_ajax;
11 13 public $is_debug;
12 14 public $account;
13 15 public $settings;
@@ -35,8 +37,11 @@
35 37 $this->settings = $settings;
36 38 $this->wing = $in_params['wing'];
37 39 $this->method = $in_params['bvMethod'];
38 40 $this->is_afterload = array_key_exists('afterload', $in_params);
41 + $this->is_aftershutdown = array_key_exists('aftershutdown', $in_params);
42 + $this->keep_page_output = $this->is_aftershutdown &&
43 + array_key_exists('keeppageoutput', $in_params);
39 44 $this->is_admin_ajax = array_key_exists('adajx', $in_params);
40 45 $this->is_debug = array_key_exists('bvdbg', $in_params);
41 46 $this->sig = $in_params['sig'];
42 47 $this->sighshalgo = !empty($in_params['sighshalgo']) ? $in_params['sighshalgo'] : '1';
@@ -43,9 +48,9 @@
43 48 $this->time = intval($in_params['bvTime']);
44 49 $this->version = $in_params['bvVersion'];
45 50 $this->is_sha1 = array_key_exists('sha1', $in_params);
46 51 $this->bvb64stream = isset($in_params['bvb64stream']);
47 - $this->bvb64cksize = array_key_exists('bvb64cksize', $in_params) ? intval($in_params['bvb64cksize']) : false;
52 + $this->bvb64cksize = array_key_exists('bvb64cksize', $in_params) ? intval($in_params['bvb64cksize']) : 0;
48 53 $this->checksum = array_key_exists('checksum', $in_params) ? $in_params['checksum'] : false;
49 54 $this->pubkey_name = !empty($in_params['pubkeyname']) ?
50 55 WPRAccount::sanitizeKey($in_params['pubkeyname']) : 'm_public';
51 56 $this->bvprmsmac = !empty($in_params['bvprmsmac']) ? WPRAccount::sanitizeKey($in_params['bvprmsmac']) : "";
@@ -98,8 +103,14 @@
98 103 }
99 104 if ($this->is_afterload) {
100 105 $info["afterload"] = true;
101 106 }
107 + if ($this->is_aftershutdown) {
108 + $info["aftershutdown"] = true;
109 + }
110 + if ($this->keep_page_output) {
111 + $info["keeppageoutput"] = true;
112 + }
102 113 return $info;
103 114 }
104 115
105 116 public function processParams($in_params) {
@@ -284,9 +295,8 @@
284 295 }
285 296
286 297 public function authFailedResp() {
287 298 $api_public_key = WPRAccount::getApiPublicKey($this->settings);
288 - $default_secret = WPRRecover::getDefaultSecret($this->settings);
289 299 $default_account_pubkey = WPRAccount::getDefaultPublicKey();
290 300 $bvinfo = new WPRInfo($this->settings);
291 301 $resp = array(
292 302 "request_info" => $this->info(),
@@ -291,11 +301,9 @@
291 301 $resp = array(
292 302 "request_info" => $this->info(),
293 303 "bvinfo" => $bvinfo->info(),
294 304 "statusmsg" => "FAILED_AUTH",
295 - "api_pubkey" => substr($api_public_key, 0, 8),
296 - "def_key_status" => WPRRecover::getSecretStatus($this->settings),
297 - "def_sigmatch" => substr(hash('sha1', $this->method.$default_secret.$this->time.$this->version), 0, 8)
305 + "api_pubkey" => substr($api_public_key, 0, 8)
298 306 );
299 307
300 308 if (is_string($default_account_pubkey) && strlen($default_account_pubkey) >= 32) {
301 309 $resp["default_account_pubkey"] = substr($default_account_pubkey, 0, 8);
@@ -302,9 +310,8 @@
302 310 }
303 311
304 312 if ($this->account) {
305 313 $resp["account_info"] = $this->account->info();
306 - $resp["sigmatch"] = substr(hash('sha1', $this->method.$this->account->secret.$this->time.$this->version), 0, 6);
307 314 } else {
308 315 $resp["account_info"] = array("error" => "ACCOUNT_NOT_FOUND");
309 316 }
310 317
@@ -310,5 +317,5 @@
310 317
311 318 return $resp;
312 319 }
313 320 }
314 -endif;
321 +endif;