Plugin Directory

Changeset 2810503


Ignore:
Timestamp:
11/03/2022 12:00:34 AM (3 years ago)
Author:
mgibbs189
Message:

Tagged 1.4

Location:
log-http-requests/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • log-http-requests/trunk/log-http-requests.php

    r2770821 r2810503  
    33Plugin Name: Log HTTP Requests
    44Description: Log all those pesky WP HTTP requests
    5 Version: 1.3.2
     5Version: 1.4
    66Author: FacetWP, LLC
    77Author URI: https://facetwp.com/
     
    3535
    3636        // setup variables
    37         define( 'LHR_VERSION', '1.3.2' );
     37        define( 'LHR_VERSION', '1.4' );
    3838        define( 'LHR_DIR', dirname( __FILE__ ) );
    3939        define( 'LHR_URL', plugins_url( '', __FILE__ ) );
     
    101101
    102102
     103    function validate() {
     104        if ( ! current_user_can( 'manage_options' ) ) {
     105            wp_die();
     106        }
     107
     108        check_ajax_referer( 'lhr_nonce' );
     109    }
     110
     111
    103112    function lhr_query() {
    104         check_ajax_referer( 'lhr_nonce' );
    105 
    106         $args = $_POST['data'];
     113        $this->validate();
    107114
    108115        $output = [
    109             'rows'  => LHR()->query->get_results( $args ),
     116            'rows'  => LHR()->query->get_results( $_POST['data'] ),
    110117            'pager' => LHR()->query->paginate()
    111118        ];
     
    116123
    117124    function lhr_clear() {
    118         check_ajax_referer( 'lhr_nonce' );
     125        $this->validate();
    119126
    120127        LHR()->query->truncate_table();
  • log-http-requests/trunk/readme.txt

    r2770821 r2810503  
    33Tags: log, wp_http, requests, update checks, api
    44Requires at least: 5.0
    5 Tested up to: 6.0.1
     5Tested up to: 6.1
    66Stable tag: trunk
    77License: GPLv2
     
    4949== Changelog ==
    5050
     51= 1.4 =
     52* Added extra ajax role validation (props pluginvulnerabilities.com)
     53
    5154= 1.3.2 =
    5255* Escaped URL field to prevent possible XSS (props Bishop Fox)
Note: See TracChangeset for help on using the changeset viewer.