Plugin Directory

Changeset 3232575


Ignore:
Timestamp:
01/31/2025 11:41:30 AM (14 months ago)
Author:
LeadBoxer
Message:

updated security

Location:
leadboxer
Files:
4 edited
3 copied

Legend:

Unmodified
Added
Removed
  • leadboxer/tags/1.4/leadboxer.class.php

    r1838239 r3232575  
    1414        public static function register_plugin_scripts() {
    1515
    16                 $dataset = get_option('leadboxer_dataset');
     16                $dataset = sanitize_text_field(get_option('leadboxer_dataset'));
    1717                if(!$dataset) $dataset = 'test.com';
    1818
    1919                if ( !is_admin() ) {
    20                     wp_enqueue_script( 'leadboxerscript', '//script.leadboxer.com/?dataset=' . $dataset, array(), null, true );
     20                     wp_enqueue_script('leadboxerscript', esc_url('//script.leadboxer.com/?dataset=' . $dataset), array(), null, true);
    2121                }
    2222        }
     
    3232
    3333                $option = 'leadboxer_dataset';
    34                 $save = isset($_GET['save']) ?  $_GET['save'] : '';
    35                 $name = isset($_GET['dataset']) ?  $_GET['dataset'] : get_option($option);
     34                $save = isset($_GET['save']) ? sanitize_text_field($_GET['save']) : '';
     35                $name = isset($_GET['dataset']) ? sanitize_text_field($_GET['dataset']) : get_option($option);
    3636
    3737                if($save) update_option($option, $name);
     
    5151                <div class="fieldwrap">
    5252                <label class="" for="dataset">' . __( "Enter your dataset ID here",'leadboxer') . '</label><br />
    53                 <input type="text" name="dataset" size="80" value="' . $name . '" id="dataset" spellcheck="false" autocomplete="off" />
     53                <input type="text" name="dataset" size="80" value="' . esc_attr($name) . '" id="dataset" spellcheck="false" autocomplete="off"/>
    5454                </div>
    5555
  • leadboxer/tags/1.4/leadboxer.php

    r3217546 r3232575  
    44 * Plugin URI: https://wordpress.org/plugins/leadboxer/
    55 * Description: LeadBoxer Plugin
    6  * Version: 1.3
     6 * Version: 1.4
    77 * Author: LeadBoxer
    88 * Author URI:  https://wordpress.org/plugins/leadboxer/
     
    6767function leadboxer_settings_link($links) {
    6868
    69 $settings_link = '<a href=' . admin_url("admin.php?page=leadboxer>Settings") . '</a>';
     69$settings_link = '<a href="' . esc_url(admin_url('admin.php?page=leadboxer')) . '">Settings</a>';
    7070  array_unshift($links, $settings_link);
    7171  return $links;
  • leadboxer/tags/1.4/readme.txt

    r3209823 r3232575  
    44Requires at least: 3.0.1
    55Tested up to: 6.7
    6 Stable tag: 1.3
     6Stable tag: 1.4
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3939== Changelog ==
    4040
     41= 1.4 =
     42* Updated code to latest security standards
     43
    4144= 1.3 =
    4245* Updated to latest Wordpress version
  • leadboxer/trunk/leadboxer.class.php

    r1838239 r3232575  
    1414        public static function register_plugin_scripts() {
    1515
    16                 $dataset = get_option('leadboxer_dataset');
     16                $dataset = sanitize_text_field(get_option('leadboxer_dataset'));
    1717                if(!$dataset) $dataset = 'test.com';
    1818
    1919                if ( !is_admin() ) {
    20                     wp_enqueue_script( 'leadboxerscript', '//script.leadboxer.com/?dataset=' . $dataset, array(), null, true );
     20                     wp_enqueue_script('leadboxerscript', esc_url('//script.leadboxer.com/?dataset=' . $dataset), array(), null, true);
    2121                }
    2222        }
     
    3232
    3333                $option = 'leadboxer_dataset';
    34                 $save = isset($_GET['save']) ?  $_GET['save'] : '';
    35                 $name = isset($_GET['dataset']) ?  $_GET['dataset'] : get_option($option);
     34                $save = isset($_GET['save']) ? sanitize_text_field($_GET['save']) : '';
     35                $name = isset($_GET['dataset']) ? sanitize_text_field($_GET['dataset']) : get_option($option);
    3636
    3737                if($save) update_option($option, $name);
     
    5151                <div class="fieldwrap">
    5252                <label class="" for="dataset">' . __( "Enter your dataset ID here",'leadboxer') . '</label><br />
    53                 <input type="text" name="dataset" size="80" value="' . $name . '" id="dataset" spellcheck="false" autocomplete="off" />
     53                <input type="text" name="dataset" size="80" value="' . esc_attr($name) . '" id="dataset" spellcheck="false" autocomplete="off"/>
    5454                </div>
    5555
  • leadboxer/trunk/leadboxer.php

    r3217546 r3232575  
    44 * Plugin URI: https://wordpress.org/plugins/leadboxer/
    55 * Description: LeadBoxer Plugin
    6  * Version: 1.3
     6 * Version: 1.4
    77 * Author: LeadBoxer
    88 * Author URI:  https://wordpress.org/plugins/leadboxer/
     
    6767function leadboxer_settings_link($links) {
    6868
    69 $settings_link = '<a href=' . admin_url("admin.php?page=leadboxer>Settings") . '</a>';
     69$settings_link = '<a href="' . esc_url(admin_url('admin.php?page=leadboxer')) . '">Settings</a>';
    7070  array_unshift($links, $settings_link);
    7171  return $links;
  • leadboxer/trunk/readme.txt

    r3209823 r3232575  
    44Requires at least: 3.0.1
    55Tested up to: 6.7
    6 Stable tag: 1.3
     6Stable tag: 1.4
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3939== Changelog ==
    4040
     41= 1.4 =
     42* Updated code to latest security standards
     43
    4144= 1.3 =
    4245* Updated to latest Wordpress version
Note: See TracChangeset for help on using the changeset viewer.