From fa3a309924a739638d1dcfb93343d891a922136a Mon Sep 17 00:00:00 2001 From: discomrade Date: Fri, 25 Jun 2021 00:46:46 -0200 Subject: [PATCH] Extend filter charset --- inc/instance-config.php | 64 ++++++++++++++++++++--------------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/inc/instance-config.php b/inc/instance-config.php index 32532ea0..e43235da 100644 --- a/inc/instance-config.php +++ b/inc/instance-config.php @@ -457,16 +457,16 @@ $config['markup'][] = array("/~~(.+?)~~/", "\$1 array( - 'subject' => '/anorectal/i', // Typical thread subject used - ), - 'action' => 'reject', - 'message' => "$fakereason_ano" + 'condition' => array( + 'subject' => '/anorectal/i', // Typical thread subject used + ), + 'action' => 'reject', + 'message' => "$fakereason_ano" ); $config['filters'][] = array( - 'condition' => array( - 'filename' => '/(TAKE ACTION v|trends.*associations|anusporn|anal insanity|anorectal risks|TAv[0-9]+|arisks)/', // Typical opening filename format. Their usual evasion strategy is to post only the image. - ), - 'action' => 'reject', - 'message' => "$fakereason_ano" + 'condition' => array( + 'filename' => '/(TAKE ACTION v|trends.*associations|anusporn|anal insanity|anorectal risks|TAv[0-9]+|arisks)/', // Typical opening filename format. Their usual evasion strategy is to post only the image. + ), + 'action' => 'reject', + 'message' => "$fakereason_ano" ); // Favorite names and buzzterms $config['filters'][] = array( - 'condition' => array( - 'body' => '/(Rocco Siff|Evil Angel|Xavier Becerra|AdultDVDTalk|painal|Roughanal|anoreceptive|ltimately this is not about me|Logically-fallacious diversionary tactics)/', - ), - 'action' => 'reject', - 'message' => "$fakereason_ano" + 'condition' => array( + 'body' => '/(Rocco Siff|Evil Angel|Xavier Becerra|AdultDVDTalk|painal|Roughanal|anoreceptive|ltimately this is not about me|Logically-fallacious diversionary tactics)/', + ), + 'action' => 'reject', + 'message' => "$fakereason_ano" ); /* @@ -505,19 +505,19 @@ $config['filters'][] = array( event_handler('post', function($post, $tor) { if($post->board == 'leftypol'){ // note: just posting nazi flag with name doesn't trigger, on purpose - $n = 0; - // body is just a twitter account - if(preg_match('/^https:\/\/twitter\.com\/[a-zA-Z0-9_-]+\/?(]*>[^<]*<\/tinyboard>|<[^>]*>|\s)*$/', - $post->body_nomarkup)){$n+=2;} - if($post->has_file && $post->files[0]->filename == 'Untitled.png'){$n+=2;} - if($post->name != 'Anonymous'){$n++;} - if(strpos($post->body_nomarkup,'nazi')){$n++;} - - if($n > 2){ - if($tor){return 'Your IP address is posting too quickly.';} - return 'Your IP address is listed in multirbl.efnetrbl.org.'; - } - } + $n = 0; + // body is just a twitter account + if(preg_match('/^https:\/\/twitter\.com\/[a-zA-Z0-9_-]+\/?(]*>[^<]*<\/tinyboard>|<[^>]*>|\s)*$/', + $post->body_nomarkup)){$n+=2;} + if($post->has_file && $post->files[0]->filename == 'Untitled.png'){$n+=2;} + if($post->name != 'Anonymous'){$n++;} + if(strpos($post->body_nomarkup,'nazi')){$n++;} + + if($n > 2){ + if($tor){return 'Your IP address is posting too quickly.';} + return 'Your IP address is listed in multirbl.efnetrbl.org.'; + } + } });