Changeset 1820882
- Timestamp:
- 02/12/2018 10:18:53 PM (8 years ago)
- Location:
- lw-mwp-tools
- Files:
-
- 1 deleted
- 8 edited
- 1 copied
-
tags/0.3 (deleted)
-
tags/0.3.1 (copied) (copied from lw-mwp-tools/trunk)
-
tags/0.3.1/lw-mwp-tools.php (modified) (1 diff)
-
tags/0.3.1/monitor.php (modified) (2 diffs)
-
tags/0.3.1/monitor_json.php (modified) (1 diff)
-
tags/0.3.1/readme.txt (modified) (2 diffs)
-
trunk/lw-mwp-tools.php (modified) (1 diff)
-
trunk/monitor.php (modified) (2 diffs)
-
trunk/monitor_json.php (modified) (1 diff)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lw-mwp-tools/tags/0.3.1/lw-mwp-tools.php
r1819502 r1820882 5 5 Description: Easy access to system logs and resource usage on the Liquid Web Managed WordPress Hosting Platform. 6 6 Author: Francis Smith 7 Version: 0.3 7 Version: 0.3.1 8 8 Author URI: https://github.com/fs1995 9 9 License: GPL2 -
lw-mwp-tools/tags/0.3.1/monitor.php
r1819502 r1820882 1 1 <?php defined('ABSPATH') or die('No!'); 2 $jsonpath = plugins_url( 'monitor_json.php', __FILE__ ) ;?>2 $jsonpath = plugins_url( 'monitor_json.php', __FILE__ ) . "?lw-mwp-tools=" . gethostname() . get_current_user();?> 3 3 4 4 <h2>Server Resource Monitor</h2> … … 58 58 function updateChart(){ 59 59 var xhr = new XMLHttpRequest(); //ie7+ 60 xhr.open("GET", <?php echo "\"" . $jsonpath . "\""; ?>, true, "", <?php echo "\"" . gethostname() . get_current_user() . "\""; ?>); //little bit of mixing php here to get the path of monitor_json.php to get the json with all the system resource info60 xhr.open("GET", <?php echo "\"" . $jsonpath . "\""; ?>, true, ); //little bit of mixing php here to get the path of monitor_json.php to get the json with all the system resource info 61 61 xhr.onload = function (e) { 62 62 if (xhr.readyState === 4){ -
lw-mwp-tools/tags/0.3.1/monitor_json.php
r1819503 r1820882 1 1 <?php 2 $json_password = gethostname() . get_current_user(); //not super secure, but this isint terribly sensitive info we are protecting...3 2 4 if (!isset($_SERVER['PHP_AUTH_PW'])) { //no password provided, need to authenticate 5 header('WWW-Authenticate: Basic realm="lw-mwp-tools"'); //the http authentication form. page will reload on submit. 6 header('HTTP/1.0 401 Unauthorized'); //user clicked cancel or somehow didnt get password 7 echo 'didnt authenticate'; 3 if (!isset( $_GET['lw-mwp-tools'] )) { //to protect access to this file 4 header('HTTP/1.0 401 Unauthorized'); 8 5 exit; 9 } else { 10 if($_SERVER['PHP_AUTH_PW'] !== $json_password){ //got password but its not right 11 echo "invalid"; 12 exit; 13 } 6 }else if( $_GET['lw-mwp-tools'] !== gethostname() . get_current_user() ){ //so the GET parameter is set, now to check what it's set to... not super secure, but this isint terribly sensitive info we are protecting... 7 header('HTTP/1.0 401 Unauthorized'); 8 exit; 14 9 } 15 10 -
lw-mwp-tools/tags/0.3.1/readme.txt
r1819502 r1820882 41 41 == Changelog == 42 42 43 = 0.3.1 = 44 * Bug fix on Resource Monitor page. 45 43 46 = 0.3 = 44 47 * Rewrite of the system monitor page, resource usage is now updated automatically. … … 54 57 == Upgrade Notice == 55 58 56 = 0.3 =57 * Resource Monitor now updates automatically!59 = 0.3.1 = 60 * Bug causing a password popup on Resource Monitor page is fixed. -
lw-mwp-tools/trunk/lw-mwp-tools.php
r1819502 r1820882 5 5 Description: Easy access to system logs and resource usage on the Liquid Web Managed WordPress Hosting Platform. 6 6 Author: Francis Smith 7 Version: 0.3 7 Version: 0.3.1 8 8 Author URI: https://github.com/fs1995 9 9 License: GPL2 -
lw-mwp-tools/trunk/monitor.php
r1819502 r1820882 1 1 <?php defined('ABSPATH') or die('No!'); 2 $jsonpath = plugins_url( 'monitor_json.php', __FILE__ ) ;?>2 $jsonpath = plugins_url( 'monitor_json.php', __FILE__ ) . "?lw-mwp-tools=" . gethostname() . get_current_user();?> 3 3 4 4 <h2>Server Resource Monitor</h2> … … 58 58 function updateChart(){ 59 59 var xhr = new XMLHttpRequest(); //ie7+ 60 xhr.open("GET", <?php echo "\"" . $jsonpath . "\""; ?>, true, "", <?php echo "\"" . gethostname() . get_current_user() . "\""; ?>); //little bit of mixing php here to get the path of monitor_json.php to get the json with all the system resource info60 xhr.open("GET", <?php echo "\"" . $jsonpath . "\""; ?>, true, ); //little bit of mixing php here to get the path of monitor_json.php to get the json with all the system resource info 61 61 xhr.onload = function (e) { 62 62 if (xhr.readyState === 4){ -
lw-mwp-tools/trunk/monitor_json.php
r1819503 r1820882 1 1 <?php 2 $json_password = gethostname() . get_current_user(); //not super secure, but this isint terribly sensitive info we are protecting...3 2 4 if (!isset($_SERVER['PHP_AUTH_PW'])) { //no password provided, need to authenticate 5 header('WWW-Authenticate: Basic realm="lw-mwp-tools"'); //the http authentication form. page will reload on submit. 6 header('HTTP/1.0 401 Unauthorized'); //user clicked cancel or somehow didnt get password 7 echo 'didnt authenticate'; 3 if (!isset( $_GET['lw-mwp-tools'] )) { //to protect access to this file 4 header('HTTP/1.0 401 Unauthorized'); 8 5 exit; 9 } else { 10 if($_SERVER['PHP_AUTH_PW'] !== $json_password){ //got password but its not right 11 echo "invalid"; 12 exit; 13 } 6 }else if( $_GET['lw-mwp-tools'] !== gethostname() . get_current_user() ){ //so the GET parameter is set, now to check what it's set to... not super secure, but this isint terribly sensitive info we are protecting... 7 header('HTTP/1.0 401 Unauthorized'); 8 exit; 14 9 } 15 10 -
lw-mwp-tools/trunk/readme.txt
r1819502 r1820882 41 41 == Changelog == 42 42 43 = 0.3.1 = 44 * Bug fix on Resource Monitor page. 45 43 46 = 0.3 = 44 47 * Rewrite of the system monitor page, resource usage is now updated automatically. … … 54 57 == Upgrade Notice == 55 58 56 = 0.3 =57 * Resource Monitor now updates automatically!59 = 0.3.1 = 60 * Bug causing a password popup on Resource Monitor page is fixed.
Note: See TracChangeset
for help on using the changeset viewer.