PluginProbe
The WP Remote WordPress Plugin / 4.74
The WP Remote WordPress Plugin v4.74
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 | wp_admin.php +20 -59 4.974.74 View file →
@@ -37,9 +37,9 @@
37 37
38 38 if (array_key_exists('bvnonce', $_REQUEST) &&
39 39 wp_verify_nonce($_REQUEST['bvnonce'], "bvnonce") &&
40 40 array_key_exists('blogvaultkey', $_REQUEST) &&
41 - (strlen(WPRAccount::sanitizeKey($_REQUEST['blogvaultkey'])) == 64) &&
41 + (strlen($_REQUEST['blogvaultkey']) == 64) &&
42 42 (array_key_exists('page', $_REQUEST) &&
43 43 $_REQUEST['page'] == $this->bvinfo->plugname)) {
44 44 $keys = str_split($_REQUEST['blogvaultkey'], 32);
45 45 WPRAccount::addAccount($this->settings, $keys[0], $keys[1]);
@@ -57,8 +57,9 @@
57 57 }
58 58
59 59 public function wprsecAdminMenu($hook) {
60 60 if ($hook === 'toplevel_page_wpremote' || preg_match("/wpr_add_account$/", $hook) || preg_match("/wpr_account_details$/", $hook)) {
61 + wp_enqueue_style( 'bvsurface', plugins_url('css/bvmui.min.css', __FILE__));
61 62 wp_enqueue_style( 'bootstrap', plugins_url('css/bootstrap.min.css', __FILE__));
62 63 wp_enqueue_style( 'bvplugin', plugins_url('css/bvplugin.min.css', __FILE__));
63 64 }
64 65 }
@@ -64,9 +65,9 @@
64 65 }
65 66
66 67 public function menu() {
67 68 $brand = $this->bvinfo->getBrandInfo();
68 - if (!is_array($brand) || (!array_key_exists('hide', $brand) && !array_key_exists('hide_from_menu', $brand))) {
69 + if (!$brand || (!array_key_exists('hide', $brand) && !array_key_exists('hide_from_menu', $brand))) {
69 70 $bname = $this->bvinfo->getBrandName();
70 71 $icon = $this->bvinfo->getBrandIcon();
71 72 add_menu_page($bname, $bname, 'manage_options', $this->bvinfo->plugname,
72 73 array($this, 'adminPage'), plugins_url($icon, __FILE__ ));
@@ -72,24 +73,13 @@
72 73 array($this, 'adminPage'), plugins_url($icon, __FILE__ ));
73 74 }
74 75 }
75 76
76 - public function hidePluginUpdate($plugins) {
77 - $brand = $this->bvinfo->getBrandInfo();
78 - $bvslug = $this->bvinfo->slug;
79 - if (isset($plugins->response[$bvslug]) && is_array($brand)) {
80 - if (array_key_exists('hide_from_menu', $brand) || array_key_exists('hide', $brand)) {
81 - unset($plugins->response[$bvslug]);
82 - }
83 - }
84 - return $plugins;
85 - }
86 -
87 77 public function hidePluginDetails($plugin_metas, $slug) {
88 78 $brand = $this->bvinfo->getBrandInfo();
89 79 $bvslug = $this->bvinfo->slug;
90 80
91 - if ($slug === $bvslug && is_array($brand) && array_key_exists('hide_plugin_details', $brand)){
81 + if ($slug === $bvslug && $brand && array_key_exists('hide_plugin_details', $brand)){
92 82 foreach ($plugin_metas as $pluginKey => $pluginValue) {
93 83 if (strpos($pluginValue, sprintf('>%s<', translate('View details')))) {
94 84 unset($plugin_metas[$pluginKey]);
95 85 break;
@@ -98,37 +88,8 @@
98 88 }
99 89 return $plugin_metas;
100 90 }
101 91
102 - public function handlePluginHealthInfo($plugins) {
103 - $brand = $this->bvinfo->getBrandInfo();
104 - $title = $this->bvinfo->title;
105 - if (!isset($plugins["wp-plugins-active"]) ||
106 - !isset($plugins["wp-plugins-active"]["fields"]) ||
107 - !isset($plugins["wp-plugins-active"]["fields"][$title])) {
108 - return $plugins;
109 - }
110 - if (is_array($brand)) {
111 - if (array_key_exists('hide', $brand)) {
112 - unset($plugins["wp-plugins-active"]["fields"][$title]);
113 - } else {
114 - $plugin = $plugins["wp-plugins-active"]["fields"][$title];
115 - $author = $this->bvinfo->author;
116 - if (array_key_exists('name', $brand)) {
117 - $plugin["label"] = $brand['name'];
118 - }
119 - if (array_key_exists('author', $brand)) {
120 - $plugin["value"] = str_replace($author, $brand['author'], $plugin["value"]);
121 - }
122 - if (array_key_exists('description', $brand)) {
123 - $plugin["debug"] = str_replace($author, $brand['author'], $plugin["debug"]);
124 - }
125 - $plugins["wp-plugins-active"]["fields"][$title] = $plugin;
126 - }
127 - }
128 - return $plugins;
129 - }
130 -
131 92 public function settingsLink($links, $file) {
132 93 #XNOTE: Fix this
133 94 if ( $file == plugin_basename( dirname(__FILE__).'/blogvault.php' ) ) {
134 95 $brand = $this->bvinfo->getBrandInfo();
@@ -140,9 +101,9 @@
140 101 }
141 102
142 103 public function getPluginLogo() {
143 104 $brand = $this->bvinfo->getBrandInfo();
144 - if (is_array($brand) && array_key_exists('logo', $brand)) {
105 + if ($brand && array_key_exists('logo', $brand)) {
145 106 return $brand['logo'];
146 107 }
147 108 return $this->bvinfo->logo;
148 109 }
@@ -148,9 +109,9 @@
148 109 }
149 110
150 111 public function getWebPage() {
151 112 $brand = $this->bvinfo->getBrandInfo();
152 - if (is_array($brand) && array_key_exists('webpage', $brand)) {
113 + if ($brand && array_key_exists('webpage', $brand)) {
153 114 return $brand['webpage'];
154 115 }
155 116 return $this->bvinfo->webpage;
156 117 }
@@ -159,20 +120,20 @@
159 120 require_once dirname( __FILE__ ) . '/recover.php';
160 121 $bvnonce = wp_create_nonce("bvnonce");
161 122 $public = WPRAccount::getApiPublicKey($this->settings);
162 123 $secret = WPRRecover::defaultSecret($this->settings);
163 - $tags = "<input type='hidden' name='url' value='".esc_attr($this->siteinfo->wpurl())."'/>\n".
164 - "<input type='hidden' name='homeurl' value='".esc_attr($this->siteinfo->homeurl())."'/>\n".
165 - "<input type='hidden' name='siteurl' value='".esc_attr($this->siteinfo->siteurl())."'/>\n".
166 - "<input type='hidden' name='dbsig' value='".esc_attr($this->siteinfo->dbsig(false))."'/>\n".
167 - "<input type='hidden' name='plug' value='".esc_attr($this->bvinfo->plugname)."'/>\n".
168 - "<input type='hidden' name='adminurl' value='".esc_attr($this->mainUrl())."'/>\n".
169 - "<input type='hidden' name='bvversion' value='".esc_attr($this->bvinfo->version)."'/>\n".
170 - "<input type='hidden' name='serverip' value='".esc_attr($_SERVER["SERVER_ADDR"])."'/>\n".
171 - "<input type='hidden' name='abspath' value='".esc_attr(ABSPATH)."'/>\n".
172 - "<input type='hidden' name='secret' value='".esc_attr($secret)."'/>\n".
173 - "<input type='hidden' name='public' value='".esc_attr($public)."'/>\n".
174 - "<input type='hidden' name='bvnonce' value='".esc_attr($bvnonce)."'/>\n";
124 + $tags = "<input type='hidden' name='url' value='".$this->siteinfo->wpurl()."'/>\n".
125 + "<input type='hidden' name='homeurl' value='".$this->siteinfo->homeurl()."'/>\n".
126 + "<input type='hidden' name='siteurl' value='".$this->siteinfo->siteurl()."'/>\n".
127 + "<input type='hidden' name='dbsig' value='".$this->siteinfo->dbsig(false)."'/>\n".
128 + "<input type='hidden' name='plug' value='".$this->bvinfo->plugname."'/>\n".
129 + "<input type='hidden' name='adminurl' value='".$this->mainUrl()."'/>\n".
130 + "<input type='hidden' name='bvversion' value='".$this->bvinfo->version."'/>\n".
131 + "<input type='hidden' name='serverip' value='".$_SERVER["SERVER_ADDR"]."'/>\n".
132 + "<input type='hidden' name='abspath' value='".ABSPATH."'/>\n".
133 + "<input type='hidden' name='secret' value='".$secret."'/>\n".
134 + "<input type='hidden' name='public' value='".$public."'/>\n".
135 + "<input type='hidden' name='bvnonce' value='".$bvnonce."'/>\n";
175 136 return $tags;
176 137 }
177 138
178 139 public function activateWarning() {
@@ -179,9 +140,9 @@
179 140 global $hook_suffix;
180 141 if (!WPRAccount::isConfigured($this->settings) && $hook_suffix == 'index.php' ) {
181 142 ?>
182 143 <div id="message" class="updated" style="padding: 8px; font-size: 16px; background-color: #dff0d8">
183 - <a class="button-primary" href="<?php echo esc_url($this->mainUrl()); ?>">Activate WPRemote</a>
144 + <a class="button-primary" href="<?php echo $this->mainUrl(); ?>">Activate WPRemote</a>
184 145 &nbsp;&nbsp;&nbsp;<b>Almost Done:</b> Activate your WPRemote account to backup & secure your site.
185 146 </div>
186 147 <?php
187 148 }
@@ -220,9 +181,9 @@
220 181 return $plugins;
221 182 }
222 183
223 184 $brand = $this->bvinfo->getBrandInfo();
224 - if (is_array($brand)) {
185 + if ($brand) {
225 186 if (array_key_exists('hide', $brand)) {
226 187 unset($plugins[$slug]);
227 188 } else {
228 189 if (array_key_exists('name', $brand)) {