» Goto page 1, 2, 3 ... 66, 67, 68  Next
» View previous topic :: View next topic  
http://www.cemetech.net/forum/viewtopic.php?p=135662#135662

http://www.cemetech.net/forum/viewtopic.php?p=135661#135661

http://www.cemetech.net/forum/viewtopic.php?p=135660#135660

Just a place holder so I know to delete the bot's posts and the bot itself once I get back..

edit by comic 3/29/12: Properized the topic title. Made sticky.
Don't forget http://www.cemetech.net/forum/viewtopic.php?p=135664#135664


:B
Alright, I believe I got them all.
Hey! Why did you delete those.Sad
TIFreak8x, what was the bot's name so I can suspend the account? Or did you already do that?
I banned it, it was Fan something, I can look at the IRC logs when I get home to tell you for sure.
tifreak8x wrote:
I banned it, it was Fan something, I can look at the IRC logs when I get home to tell you for sure.
Cheers, thanks. Since you banned it, I would just want to check if it had anything advertisery in its profile that I needed to delete.
I just looked it up in the ban control box, it is fanlynne
tifreak8x wrote:
I just looked it up in the ban control box, it is fanlynne
Thanks tifreak. Smile I have removed the user's signature and deactivated its account.
Was the IP address ---.---.---.--- and the e-mail address ---@---.com by the way? We just got hit by spam too and it was an actual forum member (who had 1000+ posts, but a long past history of spam and warnings)

EDIT: Disregard this, his account was actually hacked. (although he still does have an history of warnings)
I wanna see the spam. Anyone got a picture you can pm me or something? Razz
Here's a class I bodged together a few years ago to communicate with the Stop Forum Spam API:


Code:
<?php

class stop_forum_spam {
   
   # Internal: Used to turn an XML response into a PHP array.
   function process_response($response) {
      $tags = array('appears', 'lastseen', 'frequency');
      $parser = xml_parser_create();
      xml_parser_set_option($parser, XML_OPTION_CASE_FOLDING, false);
      xml_parse_into_struct($parser, $response, $vals, $index);
      xml_parser_free($parser);
      $result = array();
      $type = 'unknown';
      foreach ($vals as $val) {
         if ($val['tag'] == 'type') {
            $type = $val['value'];
         } else {
            if (in_array($val['tag'], $tags)) {
               if (!isset($result[$type])) {
                  $result[$type] = array();
               }
               $result[$type][$val['tag']] = $val['value'];
            }
         }
      }
      return $result;
   }

   # Checks an IP address.
   function check_ip($ip) { return stop_forum_spam::check(array('ip'=>$ip)); }
   
   # Checks an email address.
   function check_email($email) { return stop_forum_spam::check(array('email'=>$email)); }
   
   # Checks a username.
   function check_username($username) { return stop_forum_spam::check(array('username'=>$username)); }
   
   # Checks multiple fields.
   function check($fields) {
      $url_components = array();
      foreach ($fields as $k=>$v) {
         $url_components[] = urlencode($k) . '=' . urlencode($v);
      }
      return stop_forum_spam::process_response(file_get_contents('http://www.stopforumspam.com/api?' . implode('&', $url_components)));
   }
   
   # Determines whether someone is a probable spammer or not.
   function is_probable_spammer($fields) {
      $is_passing_preprocessed_results = true;
      foreach ($fields as $v) {
         if (!is_array($v) || !isset($v['appears'])) {
            $is_passing_preprocessed_results = false;
         }
      }
      if (!$is_passing_preprocessed_results) $fields = stop_forum_spam::check($fields);
      foreach ($fields as $v) {
         if (is_array($v) && isset($v['appears']) && $v['appears'] == 'yes') return true;
      }
      return false;
   }

}

?>


This is now used on the MaxCoderz forum. My inbox used to be flooded with activation requests from spammers attempting to use the forum; since I integrated this with the registration page I've only had one. Smile

To integrate into phpBB 3, open includes/ucp/ucp_register.php and look for


Code:
         if (!check_form_key('ucp_register'))
         {
            $error[] = $user->lang['FORM_INVALID'];
         }


Add the following code underneath:


Code:
         ### STOP FORUM SPAM BEGIN ###
         require_once("{$phpbb_root_path}include/stop_forum_spam.$phpEx");
         if (stop_forum_spam::is_probable_spammer(array(
            'username'=>$data['username'],
            'email'=>$data['email'],
            'ip'=>$_SERVER['REMOTE_ADDR'],
         ))) {
            $error[] = 'You appear to be a spammer.';
         }
         ### STOP FORUM SPAM END ###

That's it. Smile Try to register an account for fanlynne for a demo.
Heresy.
I do of course realise that my post looks like spam itself. Razz
benryves wrote:
I do of course realise that my post looks like spam itself. Razz
Looks pretty good to me, especially with that nice prettified syntax coloring! Wink I'm flattered that you think we're running phpBB3 here, by the way. My main concern with that code is depending on an external API for verification and therefore being dependent on their up (or down)-edness.
KermMartian wrote:
I'm flattered that you think we're running phpBB3 here, by the way.
I know you're not, but thought I would mention how I integrated it. Smile
Quote:
My main concern with that code is depending on an external API for verification and therefore being dependent on their up (or down)-edness.
True. However, as I used to have to manually spam-filter several registrations every day I was frequently using the Stop Forum Spam website and never had a problem with it going down.

An alternative would be to maintain your own spammer database. You could write a script to download a new copy from their download page every 24 hours to keep your version up to date.
Sadly, it's only in the last couple of days that spammers have started showing up again. I can only assume that there are people being paid pennies to manually register, since they're using gmail addresses and passing the one-of-a-kind captcha system.
Bot?
http://www.cemetech.net/forum/viewtopic.php?p=137667#137667
_player1537 wrote:


Very much sir. (Check his sig Very Happy) now to go suspend that account Razz (or get the people with that happy power)
Suspended. Thanks for that.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
» Goto page 1, 2, 3 ... 66, 67, 68  Next
» View previous topic :: View next topic  
Page 1 of 68
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement