Changeset 3167874
- Timestamp:
- 10/13/2024 07:19:47 AM (18 months ago)
- Location:
- kama-spamblock
- Files:
-
- 8 edited
- 1 copied
-
tags/1.8.3 (copied) (copied from kama-spamblock/trunk)
-
tags/1.8.3/Kama_Spamblock.php (modified) (11 diffs)
-
tags/1.8.3/Kama_Spamblock_Options.php (modified) (5 diffs)
-
tags/1.8.3/kama-spamblock.php (modified) (2 diffs)
-
tags/1.8.3/readme.txt (modified) (5 diffs)
-
trunk/Kama_Spamblock.php (modified) (11 diffs)
-
trunk/Kama_Spamblock_Options.php (modified) (5 diffs)
-
trunk/kama-spamblock.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
kama-spamblock/tags/1.8.3/Kama_Spamblock.php
r3000349 r3167874 22 22 private $process_comment_types = [ '', 'comment' ]; 23 23 24 /** 25 * @param string $plug_file 26 */ 27 public function __construct( $plug_file ) { 28 29 $this->opt = new Kama_Spamblock_Options(); 24 public function __construct( string $plug_file, Kama_Spamblock_Options $opt ) { 25 $this->opt = $opt; 30 26 31 27 $this->plug_file = $plug_file; 32 $this->plug_dir = dirname( $plug_file );28 $this->plug_dir = dirname( $plug_file ); 33 29 34 30 $this->process_comment_types = apply_filters( 'kama_spamblock__process_comment_types', $this->process_comment_types ); … … 36 32 37 33 public function init_plugin() { 38 39 34 if( ! defined( 'DOING_AJAX' ) ){ 40 35 load_plugin_textdomain( 'kama-spamblock', false, basename( $this->plug_dir ) . '/languages' ); … … 57 52 58 53 if( ! wp_doing_ajax() && ! is_admin() ){ 59 add_action( 'wp_footer', [ $this, 'main_js' ], 99);54 add_action( 'wp_footer', [ $this, 'main_js' ], 0 ); 60 55 } 61 56 62 $this->nonce = self::make_ nonce( date( 'jn' ) . $this->opt->unique_code );57 $this->nonce = self::make_hash( date( 'jn' ) . $this->opt->unique_code ); 63 58 64 59 add_filter( 'preprocess_comment', [ $this, 'block_spam' ], 0 ); … … 67 62 /** 68 63 * Check and block comment if needed. 69 *70 * @param array $commentdata71 *72 * @return array73 64 */ 74 public function block_spam( $commentdata ){65 public function block_spam( array $commentdata ): array { 75 66 76 67 $this->block_pings_trackbacks( $commentdata ); … … 102 93 } 103 94 104 $ksbn_code = isset( $_POST['ksbn_code'] ) ? trim( $_POST['ksbn_code'] ) : '';95 $ksbn_code = trim( $_POST['ksbn_code'] ?? '' ); 105 96 106 if( self::make_ nonce( $ksbn_code ) !== $this->nonce ){97 if( self::make_hash( $ksbn_code ) !== $this->nonce ){ 107 98 /** @noinspection ForgottenDebugOutputInspection */ 108 99 wp_die( $this->block_form() ); … … 111 102 112 103 /** 113 * @param string $key 114 * 115 * @return string 104 * Creates hash from specified key if it's not hashed yet. 116 105 */ 117 private static function make_nonce( $key ) { 118 // maybe already md5 106 private static function make_hash( string $key ): string { 119 107 return preg_match( '/^[a-f0-9]{32}$/', $key ) ? $key : md5( $key ); 120 108 } … … 127 115 128 116 // note: is_singular() may work incorrectly 129 if( ! empty( $post )&& ( 'open' !== $post->comment_status ) && is_singular() ){117 if( $post && ( 'open' !== $post->comment_status ) && is_singular() ){ 130 118 return; 131 119 } 132 120 ?> 133 121 <script id="kama_spamblock"> 134 (function(){ 122 window.addEventListener( 'DOMContentLoaded', function() { 123 document.addEventListener( 'mousedown', handleSubmit ); 124 document.addEventListener( 'touchstart', handleSubmit ); 125 document.addEventListener( 'keypress', handleSubmit ); 135 126 136 const catch_submit = function( ev ){ 137 138 let sbmt = ev.target.closest( '#<?= esc_html( $this->opt->sibmit_button_id ) ?>' ); 139 127 function handleSubmit( ev ){ 128 let sbmt = ev.target.closest( '#<?= esc_html( sanitize_html_class( $this->opt->sibmit_button_id ) ) ?>' ); 140 129 if( ! sbmt ){ 141 130 return; … … 145 134 let date = new Date(); 146 135 147 input.value = ''+ date.getUTCDate() + (date.getUTCMonth() + 1) + '<?= esc_html( $this->opt->unique_code) ?>';136 input.value = ''+ date.getUTCDate() + (date.getUTCMonth() + 1) + '<?= esc_html( Kama_Spamblock_Options::sanitize_uniue_code( $this->opt->unique_code ) ) ?>'; 148 137 input.name = 'ksbn_code'; 149 138 input.type = 'hidden'; … … 151 140 sbmt.parentNode.insertBefore( input, sbmt ); 152 141 } 153 154 document.addEventListener( 'mousedown', catch_submit ); 155 document.addEventListener( 'keypress', catch_submit ); 156 })() 142 } ); 157 143 </script> 158 144 <?php … … 160 146 161 147 /** 162 * Output form when comment has been blocked. 163 * 164 * @return string 148 * Gets Form HTML for blocked comment. 165 149 */ 166 private function block_form() {150 private function block_form(): string { 167 151 ob_start(); 168 152 ?> 169 153 <h1><?= __( 'Antispam block your comment!', 'kama-spamblock' ) ?></h1> 170 154 171 <form method=" post" action="<?= site_url( '/wp-comments-post.php' ) ?>">155 <form method="POST" action="<?= site_url( '/wp-comments-post.php' ) ?>"> 172 156 <p> 173 157 <?= sprintf( 174 158 __( 'Copy %1$s to the field %2$s and press button', 'kama-spamblock' ), 175 '<code style="background:rgba(255,255,255,.2);">' . $this->nonce. '</code>',159 '<code style="background:rgba(255,255,255,.2);">' . esc_html( $this->nonce ) . '</code>', 176 160 '<input type="text" name="ksbn_code" value="" style="width:150px; border:1px solid #ccc; border-radius:3px; padding:.3em;" />' 177 161 ) ?> … … 181 165 182 166 <?php 183 unset( $_POST['ksbn_code'] ); 167 foreach( $_POST as $key => $val ){ 168 if( $key === 'ksbn_code' ){ 169 continue; 170 } 184 171 185 foreach( $_POST as $key => $val ){ 186 echo sprintf( '<textarea style="display:none;" name="%s">%s</textarea>', $key, esc_textarea( stripslashes( $val ) ) ); 172 echo sprintf( '<textarea style="display:none;" name="%s">%s</textarea>', 173 esc_attr( $key ), 174 esc_textarea( stripslashes( $val ) ) 175 ); 187 176 } 188 177 ?> -
kama-spamblock/tags/1.8.3/Kama_Spamblock_Options.php
r3000349 r3167874 13 13 public function __construct() { 14 14 $opt = array_merge( $this->default_options(), get_option( self::OPT_NAME, [] ) ); 15 $this->check_empty_unique_code( $opt['unique_code'] ); 16 15 17 $opt = apply_filters( 'kama_spamblock__options', $opt ); 16 $opt = (object) $opt;17 18 18 $this->unique_code = $opt->unique_code;19 $this->sibmit_button_id = $opt ->sibmit_button_id;19 $this->unique_code = $opt['unique_code']; 20 $this->sibmit_button_id = $opt['sibmit_button_id']; 20 21 } 21 22 22 23 /** 23 * @return string[]24 * @return void 24 25 */ 25 public function default_options(){ 26 private function check_empty_unique_code( string $code ) { 27 if( ! $code ){ 28 $opt = get_option( self::OPT_NAME, [] ); 29 $opt['unique_code'] = wp_generate_password( 10, false ); 30 update_option( self::OPT_NAME, $opt ); 31 } 32 } 26 33 34 public function default_options(): array { 27 35 return [ 28 36 'sibmit_button_id' => 'submit', 29 'unique_code' => ' uniq9065',37 'unique_code' => '', // default value will be auto-generated 30 38 ]; 31 39 } … … 37 45 self::OPT_NAME . '_field', 38 46 __( 'Kama Spamblock settings', 'kama-spamblock' ), 39 [ $this, 'options_field ', ],47 [ $this, 'options_fields', ], 40 48 'discussion', 41 49 'kama_spamblock' … … 52 60 } 53 61 elseif( 'unique_code' === $key ){ 54 $val = preg_replace( '~[^A-Za-z0-9*%$#@!_-]~', '', $val ); 62 $val = self::sanitize_uniue_code( $val ); 63 $val || $val = wp_generate_password( 10, false ); 55 64 } 56 65 else{ … … 62 71 } 63 72 64 public function options_field() { 73 public static function sanitize_uniue_code( string $code ) { 74 return preg_replace( '~[^A-Za-z0-9*%$#@!_-]~', '', $code ); 75 } 76 77 public function options_fields() { 65 78 ?> 66 79 <p> … … 76 89 77 90 public static function settings_link( $links ) { 78 79 91 $links[] = sprintf( '<a href="%s">%s</a>', admin_url( '/options-discussion.php#wpfooter' ), __( 'Settings', 'kama-spamblock' ) ); 80 92 -
kama-spamblock/tags/1.8.3/kama-spamblock.php
r3000349 r3167874 12 12 * Plugin URI: https://wp-kama.ru/95 13 13 * 14 * Requires PHP: 5.615 * Requires at least: 2.714 * Requires PHP: 7.0 15 * Requires at least: 5.7 16 16 * 17 * Version: 1.8. 217 * Version: 1.8.3 18 18 */ 19 19 … … 23 23 add_action( 'init', 'kama_spamblock_init', 11 ); 24 24 25 26 25 function kama_spamblock_init() { 27 26 return kama_spamblock()->init_plugin(); 28 27 } 29 28 30 /** 31 * @return Kama_Spamblock 32 */ 33 function kama_spamblock() { 29 function kama_spamblock(): Kama_Spamblock { 34 30 static $inst; 35 31 36 $inst || $inst = new Kama_Spamblock( __FILE__ );32 $inst || $inst = new Kama_Spamblock( __FILE__, new Kama_Spamblock_Options() ); 37 33 38 34 return $inst; -
kama-spamblock/tags/1.8.3/readme.txt
r3001786 r3167874 2 2 Stable tag: trunk 3 3 Contributors: Tkama 4 Tested up to: 6. 4.14 Tested up to: 6.6.2 5 5 License: GPLv2 or later 6 6 License URI: http://www.gnu.org/licenses/gpl-2.0.html 7 7 Tags: spam, spammer, autospam, spamblock, antispam, anti-spam, protect, comments, ping, trackback, bot, robot, human, captcha, invisible 8 8 9 A lightweight and discreet solution to prevent automatic spam when a spam comment is posted. Additionally, it conducts checks on pings and trackbacks to verify genuinebacklinks.9 Light and invisible method to block auto-spam when a spam comment is posted. Pings and trackbacks check for real backlinks. 10 10 11 11 … … 21 21 == Screenshots == 22 22 23 1. Plugin settings on standar tWordPress <code>Settings > Discussion</code> page.23 1. Plugin settings on standard WordPress <code>Settings > Discussion</code> page. 24 24 25 2. Spam alert, when spam comment detected or if user have javascript disabled in his browser. This alert allows send comment once again,when it was blocked in any nonstandard cases.25 2. Spam alert, when spam comment is detected or if the user has JavaScript disabled in their browser. This alert allows sending the comment once again when it was blocked in any nonstandard cases. 26 26 27 27 … … 35 35 36 36 37 == Changelog == 37 38 38 == Changelog == 39 = 1.8.3 = 40 * FIX: XSS vulnerability fixed. Thanks to [Wordfence](https://www.wordfence.com/) for the report. 41 * IMP: Other minor improvements. 39 42 40 43 = 1.8.2 = … … 49 52 50 53 = 1.7.5 = 51 * FIX: bug with uniq code comparation 52 * minor code fixes 53 54 * FIX: bug with unique code comparison. 55 * Minor code fixes. 54 56 55 57 = 1.7.4 = 56 * CHG: change sanitize-options-on-save function - sanitize_key() to sanitize_html_class() - it's not so hard but hard enough...57 * CHG: 'sanitize_setting' function call. Seems it hasn't have back-compat for wordpress versions less then 4.758 * CHG: changed sanitize-options-on-save function - sanitize_key() to sanitize_html_class() - it's not so hard but hard enough... 59 * CHG: 'sanitize_setting' function call. Seems it doesn't have back-compat for WordPress versions less than 4.7. 58 60 59 61 = 1.7.3 = 60 * FIX: options fix of 1.7.2 62 * FIX: options fix of 1.7.2. 61 63 62 64 = 1.7.2 = 63 * CHG: move translation to translation.wordpress.org65 * CHG: moved translation to translation.wordpress.org. 64 66 * ADD: new 'unique code' option. 65 67 * IMP: some code improvements. … … 69 71 70 72 = 1.6.0 = 71 * CHG: check logic is little change in order to correctly work with page cache plugins73 * CHG: check logic is slightly changed in order to work correctly with page cache plugins. 72 74 73 75 = 1.5.2 = 74 * ADD: delete is_singular check for themes where this check work wrong. Now plugin JS showen in all pages76 * ADD: deleted is_singular check for themes where this check works incorrectly. Now plugin JS is shown on all pages. 75 77 76 78 = 1.5.1 = 77 * ADD: js include from numbers of hooks. If there is no "wp_footer" hook in theme79 * ADD: JS included from a number of hooks if there is no "wp_footer" hook in the theme. 78 80 79 81 = 1.5.0 = 80 * ADD: Russian localization 81 82 * ADD: Russian localization. -
kama-spamblock/trunk/Kama_Spamblock.php
r3000349 r3167874 22 22 private $process_comment_types = [ '', 'comment' ]; 23 23 24 /** 25 * @param string $plug_file 26 */ 27 public function __construct( $plug_file ) { 28 29 $this->opt = new Kama_Spamblock_Options(); 24 public function __construct( string $plug_file, Kama_Spamblock_Options $opt ) { 25 $this->opt = $opt; 30 26 31 27 $this->plug_file = $plug_file; 32 $this->plug_dir = dirname( $plug_file );28 $this->plug_dir = dirname( $plug_file ); 33 29 34 30 $this->process_comment_types = apply_filters( 'kama_spamblock__process_comment_types', $this->process_comment_types ); … … 36 32 37 33 public function init_plugin() { 38 39 34 if( ! defined( 'DOING_AJAX' ) ){ 40 35 load_plugin_textdomain( 'kama-spamblock', false, basename( $this->plug_dir ) . '/languages' ); … … 57 52 58 53 if( ! wp_doing_ajax() && ! is_admin() ){ 59 add_action( 'wp_footer', [ $this, 'main_js' ], 99);54 add_action( 'wp_footer', [ $this, 'main_js' ], 0 ); 60 55 } 61 56 62 $this->nonce = self::make_ nonce( date( 'jn' ) . $this->opt->unique_code );57 $this->nonce = self::make_hash( date( 'jn' ) . $this->opt->unique_code ); 63 58 64 59 add_filter( 'preprocess_comment', [ $this, 'block_spam' ], 0 ); … … 67 62 /** 68 63 * Check and block comment if needed. 69 *70 * @param array $commentdata71 *72 * @return array73 64 */ 74 public function block_spam( $commentdata ){65 public function block_spam( array $commentdata ): array { 75 66 76 67 $this->block_pings_trackbacks( $commentdata ); … … 102 93 } 103 94 104 $ksbn_code = isset( $_POST['ksbn_code'] ) ? trim( $_POST['ksbn_code'] ) : '';95 $ksbn_code = trim( $_POST['ksbn_code'] ?? '' ); 105 96 106 if( self::make_ nonce( $ksbn_code ) !== $this->nonce ){97 if( self::make_hash( $ksbn_code ) !== $this->nonce ){ 107 98 /** @noinspection ForgottenDebugOutputInspection */ 108 99 wp_die( $this->block_form() ); … … 111 102 112 103 /** 113 * @param string $key 114 * 115 * @return string 104 * Creates hash from specified key if it's not hashed yet. 116 105 */ 117 private static function make_nonce( $key ) { 118 // maybe already md5 106 private static function make_hash( string $key ): string { 119 107 return preg_match( '/^[a-f0-9]{32}$/', $key ) ? $key : md5( $key ); 120 108 } … … 127 115 128 116 // note: is_singular() may work incorrectly 129 if( ! empty( $post )&& ( 'open' !== $post->comment_status ) && is_singular() ){117 if( $post && ( 'open' !== $post->comment_status ) && is_singular() ){ 130 118 return; 131 119 } 132 120 ?> 133 121 <script id="kama_spamblock"> 134 (function(){ 122 window.addEventListener( 'DOMContentLoaded', function() { 123 document.addEventListener( 'mousedown', handleSubmit ); 124 document.addEventListener( 'touchstart', handleSubmit ); 125 document.addEventListener( 'keypress', handleSubmit ); 135 126 136 const catch_submit = function( ev ){ 137 138 let sbmt = ev.target.closest( '#<?= esc_html( $this->opt->sibmit_button_id ) ?>' ); 139 127 function handleSubmit( ev ){ 128 let sbmt = ev.target.closest( '#<?= esc_html( sanitize_html_class( $this->opt->sibmit_button_id ) ) ?>' ); 140 129 if( ! sbmt ){ 141 130 return; … … 145 134 let date = new Date(); 146 135 147 input.value = ''+ date.getUTCDate() + (date.getUTCMonth() + 1) + '<?= esc_html( $this->opt->unique_code) ?>';136 input.value = ''+ date.getUTCDate() + (date.getUTCMonth() + 1) + '<?= esc_html( Kama_Spamblock_Options::sanitize_uniue_code( $this->opt->unique_code ) ) ?>'; 148 137 input.name = 'ksbn_code'; 149 138 input.type = 'hidden'; … … 151 140 sbmt.parentNode.insertBefore( input, sbmt ); 152 141 } 153 154 document.addEventListener( 'mousedown', catch_submit ); 155 document.addEventListener( 'keypress', catch_submit ); 156 })() 142 } ); 157 143 </script> 158 144 <?php … … 160 146 161 147 /** 162 * Output form when comment has been blocked. 163 * 164 * @return string 148 * Gets Form HTML for blocked comment. 165 149 */ 166 private function block_form() {150 private function block_form(): string { 167 151 ob_start(); 168 152 ?> 169 153 <h1><?= __( 'Antispam block your comment!', 'kama-spamblock' ) ?></h1> 170 154 171 <form method=" post" action="<?= site_url( '/wp-comments-post.php' ) ?>">155 <form method="POST" action="<?= site_url( '/wp-comments-post.php' ) ?>"> 172 156 <p> 173 157 <?= sprintf( 174 158 __( 'Copy %1$s to the field %2$s and press button', 'kama-spamblock' ), 175 '<code style="background:rgba(255,255,255,.2);">' . $this->nonce. '</code>',159 '<code style="background:rgba(255,255,255,.2);">' . esc_html( $this->nonce ) . '</code>', 176 160 '<input type="text" name="ksbn_code" value="" style="width:150px; border:1px solid #ccc; border-radius:3px; padding:.3em;" />' 177 161 ) ?> … … 181 165 182 166 <?php 183 unset( $_POST['ksbn_code'] ); 167 foreach( $_POST as $key => $val ){ 168 if( $key === 'ksbn_code' ){ 169 continue; 170 } 184 171 185 foreach( $_POST as $key => $val ){ 186 echo sprintf( '<textarea style="display:none;" name="%s">%s</textarea>', $key, esc_textarea( stripslashes( $val ) ) ); 172 echo sprintf( '<textarea style="display:none;" name="%s">%s</textarea>', 173 esc_attr( $key ), 174 esc_textarea( stripslashes( $val ) ) 175 ); 187 176 } 188 177 ?> -
kama-spamblock/trunk/Kama_Spamblock_Options.php
r3000349 r3167874 13 13 public function __construct() { 14 14 $opt = array_merge( $this->default_options(), get_option( self::OPT_NAME, [] ) ); 15 $this->check_empty_unique_code( $opt['unique_code'] ); 16 15 17 $opt = apply_filters( 'kama_spamblock__options', $opt ); 16 $opt = (object) $opt;17 18 18 $this->unique_code = $opt->unique_code;19 $this->sibmit_button_id = $opt ->sibmit_button_id;19 $this->unique_code = $opt['unique_code']; 20 $this->sibmit_button_id = $opt['sibmit_button_id']; 20 21 } 21 22 22 23 /** 23 * @return string[]24 * @return void 24 25 */ 25 public function default_options(){ 26 private function check_empty_unique_code( string $code ) { 27 if( ! $code ){ 28 $opt = get_option( self::OPT_NAME, [] ); 29 $opt['unique_code'] = wp_generate_password( 10, false ); 30 update_option( self::OPT_NAME, $opt ); 31 } 32 } 26 33 34 public function default_options(): array { 27 35 return [ 28 36 'sibmit_button_id' => 'submit', 29 'unique_code' => ' uniq9065',37 'unique_code' => '', // default value will be auto-generated 30 38 ]; 31 39 } … … 37 45 self::OPT_NAME . '_field', 38 46 __( 'Kama Spamblock settings', 'kama-spamblock' ), 39 [ $this, 'options_field ', ],47 [ $this, 'options_fields', ], 40 48 'discussion', 41 49 'kama_spamblock' … … 52 60 } 53 61 elseif( 'unique_code' === $key ){ 54 $val = preg_replace( '~[^A-Za-z0-9*%$#@!_-]~', '', $val ); 62 $val = self::sanitize_uniue_code( $val ); 63 $val || $val = wp_generate_password( 10, false ); 55 64 } 56 65 else{ … … 62 71 } 63 72 64 public function options_field() { 73 public static function sanitize_uniue_code( string $code ) { 74 return preg_replace( '~[^A-Za-z0-9*%$#@!_-]~', '', $code ); 75 } 76 77 public function options_fields() { 65 78 ?> 66 79 <p> … … 76 89 77 90 public static function settings_link( $links ) { 78 79 91 $links[] = sprintf( '<a href="%s">%s</a>', admin_url( '/options-discussion.php#wpfooter' ), __( 'Settings', 'kama-spamblock' ) ); 80 92 -
kama-spamblock/trunk/kama-spamblock.php
r3000349 r3167874 12 12 * Plugin URI: https://wp-kama.ru/95 13 13 * 14 * Requires PHP: 5.615 * Requires at least: 2.714 * Requires PHP: 7.0 15 * Requires at least: 5.7 16 16 * 17 * Version: 1.8. 217 * Version: 1.8.3 18 18 */ 19 19 … … 23 23 add_action( 'init', 'kama_spamblock_init', 11 ); 24 24 25 26 25 function kama_spamblock_init() { 27 26 return kama_spamblock()->init_plugin(); 28 27 } 29 28 30 /** 31 * @return Kama_Spamblock 32 */ 33 function kama_spamblock() { 29 function kama_spamblock(): Kama_Spamblock { 34 30 static $inst; 35 31 36 $inst || $inst = new Kama_Spamblock( __FILE__ );32 $inst || $inst = new Kama_Spamblock( __FILE__, new Kama_Spamblock_Options() ); 37 33 38 34 return $inst; -
kama-spamblock/trunk/readme.txt
r3001786 r3167874 2 2 Stable tag: trunk 3 3 Contributors: Tkama 4 Tested up to: 6. 4.14 Tested up to: 6.6.2 5 5 License: GPLv2 or later 6 6 License URI: http://www.gnu.org/licenses/gpl-2.0.html 7 7 Tags: spam, spammer, autospam, spamblock, antispam, anti-spam, protect, comments, ping, trackback, bot, robot, human, captcha, invisible 8 8 9 A lightweight and discreet solution to prevent automatic spam when a spam comment is posted. Additionally, it conducts checks on pings and trackbacks to verify genuinebacklinks.9 Light and invisible method to block auto-spam when a spam comment is posted. Pings and trackbacks check for real backlinks. 10 10 11 11 … … 21 21 == Screenshots == 22 22 23 1. Plugin settings on standar tWordPress <code>Settings > Discussion</code> page.23 1. Plugin settings on standard WordPress <code>Settings > Discussion</code> page. 24 24 25 2. Spam alert, when spam comment detected or if user have javascript disabled in his browser. This alert allows send comment once again,when it was blocked in any nonstandard cases.25 2. Spam alert, when spam comment is detected or if the user has JavaScript disabled in their browser. This alert allows sending the comment once again when it was blocked in any nonstandard cases. 26 26 27 27 … … 35 35 36 36 37 == Changelog == 37 38 38 == Changelog == 39 = 1.8.3 = 40 * FIX: XSS vulnerability fixed. Thanks to [Wordfence](https://www.wordfence.com/) for the report. 41 * IMP: Other minor improvements. 39 42 40 43 = 1.8.2 = … … 49 52 50 53 = 1.7.5 = 51 * FIX: bug with uniq code comparation 52 * minor code fixes 53 54 * FIX: bug with unique code comparison. 55 * Minor code fixes. 54 56 55 57 = 1.7.4 = 56 * CHG: change sanitize-options-on-save function - sanitize_key() to sanitize_html_class() - it's not so hard but hard enough...57 * CHG: 'sanitize_setting' function call. Seems it hasn't have back-compat for wordpress versions less then 4.758 * CHG: changed sanitize-options-on-save function - sanitize_key() to sanitize_html_class() - it's not so hard but hard enough... 59 * CHG: 'sanitize_setting' function call. Seems it doesn't have back-compat for WordPress versions less than 4.7. 58 60 59 61 = 1.7.3 = 60 * FIX: options fix of 1.7.2 62 * FIX: options fix of 1.7.2. 61 63 62 64 = 1.7.2 = 63 * CHG: move translation to translation.wordpress.org65 * CHG: moved translation to translation.wordpress.org. 64 66 * ADD: new 'unique code' option. 65 67 * IMP: some code improvements. … … 69 71 70 72 = 1.6.0 = 71 * CHG: check logic is little change in order to correctly work with page cache plugins73 * CHG: check logic is slightly changed in order to work correctly with page cache plugins. 72 74 73 75 = 1.5.2 = 74 * ADD: delete is_singular check for themes where this check work wrong. Now plugin JS showen in all pages76 * ADD: deleted is_singular check for themes where this check works incorrectly. Now plugin JS is shown on all pages. 75 77 76 78 = 1.5.1 = 77 * ADD: js include from numbers of hooks. If there is no "wp_footer" hook in theme79 * ADD: JS included from a number of hooks if there is no "wp_footer" hook in the theme. 78 80 79 81 = 1.5.0 = 80 * ADD: Russian localization 81 82 * ADD: Russian localization.
Note: See TracChangeset
for help on using the changeset viewer.