[2.0.17] Live Email Validate (LEV)

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.

Rating:

Excellent!
21
66%
Very Good
6
19%
Good
2
6%
Fair
0
No votes
Poor
3
9%
 
Total votes: 32

User avatar
Taomyn
Registered User
Posts: 28
Joined: Thu Nov 04, 2004 7:43 am
Location: Luxembourg

Re: [2.0.17] Live Email Validate (LEV)

Post by Taomyn » Thu Oct 25, 2007 10:39 am

I've made modifications to this mod for those out there running under Windows IIS - the use of "nslookup" is a *big* security risk and gets worse to implement under IIS-6 and probably harder under IIS-7 (no idea as I do not have any experience with it). Yes, Windows itself is regarded as a big security risk in some circles, but why make is worse by using "nslookup"! It's bad enough when people try using "cmd.exe" instead of proper calls to the operating system. Anywho.....

I've replaced it with code to use the PEAR NET_DNS class which is installable with PEAR that should come with most builds of PHP (in the PHP folder type the command "pear install net_dns" to get the package as it's not there by default).

Here's the new function in functions_validate.php:

Code: Select all

function check_smtp_addr_win($email)
{
  require_once 'Net/DNS.php';
  
  list($username, $domain) = explode('@', $email);
  $resolver = new Net_DNS_Resolver();
  // $resolver->debug = 1; // Turn on debugging output to show the query
  // $resolver->usevc = 1; // Force the use of TCP instead of UDP
  $resolver->nameservers = array('127.0.0.1');
  $response = $resolver->query($domain, 'MX');

  if ($response) {
    foreach ($response->answer as $rr)
    {
	
      $result =  probe_smtp_mailbox($email, $rr->exchange);

      if ($result['error'] == false)
      {
      	return $result;
      }
    }
  }

  if (isset($result))
  {
  	return $result;
  }
  else
  {
  	return (probe_smtp_mailbox($email, $domain));
  }
}
Note, my version uses the local DNS server, i.e. 127.0.0.1, but this can be changed. I also left a couple of commented lines that may help under other circumstances if you have problems.

By the way, what are the supposed issues with this mod and the signatures control mod? It's probably buried in this large thread somewhere, but I didn't see it.

User avatar
ashras99
Registered User
Posts: 441
Joined: Mon Dec 19, 2005 9:09 pm

Re: [2.0.17] Live Email Validate (LEV)

Post by ashras99 » Thu Oct 25, 2007 10:52 am

is this change applied to only windows servers or linux servers too.

User avatar
Taomyn
Registered User
Posts: 28
Joined: Thu Nov 04, 2004 7:43 am
Location: Luxembourg

Re: [2.0.17] Live Email Validate (LEV)

Post by Taomyn » Thu Oct 25, 2007 12:40 pm

ashras99 wrote:is this change applied to only windows servers or linux servers too.
I only did it for Windows, but there's no reason it wouldn't work for Linux as long as PEAR is available - I don't have a Linux server so could not test it.

rhythm
Registered User
Posts: 83
Joined: Fri Dec 14, 2007 1:17 pm

Re: [2.0.17] Live Email Validate (LEV)

Post by rhythm » Sun Dec 16, 2007 1:29 pm

Fantastico. Great MOD :mrgreen:

rhythm
Registered User
Posts: 83
Joined: Fri Dec 14, 2007 1:17 pm

Re: [2.0.17] Live Email Validate (LEV)

Post by rhythm » Sun Dec 16, 2007 1:31 pm

Correction..
fantastico. BEST MOD SO FAR. :D

joe_postscript
Registered User
Posts: 109
Joined: Sun May 25, 2003 3:32 am
Location: Columbus Ohio USA
Contact:

Re: Live Email Validate (LEV) for phpBB 3.0 Prepress Forums?

Post by joe_postscript » Sun Dec 16, 2007 6:20 pm

Hello All,

I am wanting to know about this mod and its development to port it to phpBB 3.0 I see there are improvements in phpBB 3 and its spam prevention controls. But, I need to know whether what is built into 3 is going to be as robust and complete a solution as this has been. Also, if not, who is going to port this over or continue it's support into phpBB 3.0x Please advise as I think this is one of the most important and well designed mods that I have used in phpBB 2.0x
See My Home Wind Turbine Videos!
Prepress Forums - Graphic Design & Prepress Forum for Printing Industry
Corvette Forums - Corvette Owners, Mechanics, & Enthusiasts Community

Wulf_9
Registered User
Posts: 130
Joined: Sun Mar 20, 2005 8:13 pm
Location: Norwich, UK

Re: [2.0.17] Live Email Validate (LEV)

Post by Wulf_9 » Tue Jan 01, 2008 2:41 pm

Wow, praise indeed, thanks mucho! 8-)

I've been out of the loop for a while, haven't checked out phpBB3 and consequently have no immediate plans to port LEV over to it (if indeed it needs to be).

Sorry if some people think I've not supported this well, but life has a habit of getting in the way of projects and pastimes like phpBB tweaking. However I'm getting back into the swing a bit more now so I'll watch this topic more closely. Besides, it's down to individual users to try it out and report problems, I can't possibly test every server out there so feedback is essential for a MOD's continued development. Naturally I'd like to see LEV persist and be useful for as long as possible.

Taomyn your solution is elegant and simple, however I could not assume PEAR and/or net_dns is installed on any given server, or that a user can install it if not, user accounts on hosting sites don't have that kind of access. nslookup IS a blunt instrument but IMO if you run a phpBB board on a Windoze box you're asking for it :)

I guess the best way forward is to recode the function check_smtp_addr_win() so that a 'test call' can be made to establish whether the net_dns package is available, if yes, use your code, if not, use the original.

Something like this might work :-

Code: Select all

if ( preg_match('/pear/', ini_get('include_path')) )
{
  if ( @file_exists('Net/DNS.php') )
  {
    require_once 'Net/DNS.php';
    // now use your code
  }
  else
  {
    // use original code
  }
}
else
{
  // use original code
}
All of this is irrelevant on a unix/linux box as the resolving code is different (checkdnsrr and getmxrr). No worries there. :P
Last edited by Wulf_9 on Tue Jan 01, 2008 4:55 pm, edited 5 times in total.
`
"It's not the things you do right that matter, it's the things you don't do wrong"

Wulf_9
Registered User
Posts: 130
Joined: Sun Mar 20, 2005 8:13 pm
Location: Norwich, UK

Re: [2.0.17] Live Email Validate (LEV)

Post by Wulf_9 » Tue Jan 01, 2008 4:41 pm

Bah. Double post :roll:
`
"It's not the things you do right that matter, it's the things you don't do wrong"

wolfguard
Registered User
Posts: 5
Joined: Thu Dec 21, 2006 5:26 pm

Re: [2.0.17] Live Email Validate (LEV)

Post by wolfguard » Wed Aug 27, 2008 9:13 pm

i know this is a dumb question, but i can't figure out how to install this mod. usually you have to edit different files, but there are only 2 in the zip, a .php one and a .mod one.

Also, is this compatable with 2.0.23?

Thanks

FuNEnD3R
Registered User
Posts: 267
Joined: Sun Aug 03, 2003 6:57 pm
Contact:

Re: [2.0.17] Live Email Validate (LEV)

Post by FuNEnD3R » Tue Oct 14, 2008 7:33 am

I noticed that this mod no longer works and blocks all registrations. Just wanted to let others know since I am getting a lot of emails from people saying that they cannot register to my forum. It may be just a problem on my server but I haven't made any changes recently and this problem has occured out of the blue but has been working for over a year.

Wulf_9
Registered User
Posts: 130
Joined: Sun Mar 20, 2005 8:13 pm
Location: Norwich, UK

Re: [2.0.17] Live Email Validate (LEV)

Post by Wulf_9 » Wed Nov 12, 2008 1:10 am

Hi,

Been a while since I was here! :shock:

@wolfguard,

You follow the instructions in the .mod file (it's text) and when you've edited all the files, include that db_update.php file in the upload, MAKE SURE it goes to your forum root. Run it once by accessing it with your browser and it will create the necessary database entries. Once that's done you should delete it. From there all you have to do is go to the ACP and under 'General Admin -> Configuration' set 'Use Live Email Validation' to Yes and submit. When LEV is active there are two extra topics in the FAQ under 'Registration' also.

@FuNEnD3R,

As far as I can tell, there is an ever-increasing tendency for service providers to block port 25 to non-authorised input, this is to prevent spam from being directly injected into people's mailboxes. Both the hosting providers where my boards run have disabled port 25 to all except verified mailservers so in the end I had to turn it off. This is NOT about simply 'dumping' an email to the user's provided address, that's still 'blind sending' with no guarantee of delivery. The whole point of LEV was to VERIFY a mailbox in real-time.

The MOD itself is robust and reliable but there are less and less instances where it will actually work as intended, mainly due to the spam issue but also because it seems that many mailservers actually flout RFC822 with respect to implemented commands and responses (which LEV looks for).

Blame the spammers for getting half of the world's email admins in a lather and those admins who don't configure their software correctly.

I'm extremely gratified at the responses and popularity of this MOD, as far as I'm concerned it will continue to be available so long as there are phpbb 2.0.x versions still running and their admins want to try/use this.

I'm still completely in the dark as regards the 3.0.x code and features - does anyone here know what they've done about this email validation issue, or do they simply go with the long-held assumption that if somone provides a bum email address they'll never get the confirmation email... where does that leave a board with several thousand users which has self-activation enabled? Would you want to trawl the entire user-base testing addresses at random? I think not! Live real-time validation is the way to go... so let me see if I can get real sneaky and work out a way of circumventing the port 25 issue... 8-)
`
"It's not the things you do right that matter, it's the things you don't do wrong"

Post Reply

Return to “[2.0.x] MOD Database Releases”