It appears that you're running an Ad-Blocker. This site is monetized by Advertising and by User Donations; we ask that if you find this site helpful that you whitelist us in your Ad-Blocker, or make a Donation to help aid in operating costs.

UBB.threads Bounced EMail Processor

What Is Covered

Summary
About the Modification
Additional Files
Demonstration
How Does it Work?
Install Instructions
Usage Instructions
Settings
Changelog
Frequently Asked Questions
     • What does purchasing a license entitle me to?
     • I'm getting an IMAP error!
     • I'm having issues with the firewall on my system.
     • I'm getting a security error while connecting to GMail or Google Apps.
     • I'm having issues with connecting on an Apache Server on Windows
     • I cannot connect to my local mail server using 127.0.0.1
     • Things seem slow


 

Summary


This page represents the full documentation for the UBB.threads Bounced EMail Processor Premium Script by VNC Web Services.


 

About the Modification


Requirements: UBB.threads 7.x
Current Version: v0.1
License Information: This script is not freeware, it requires a license; by purchasing a license you're granted usage on 1 (one) UBB.threads installation. Any additional installations require an additional license. Updates are available for 1 year after initial purchase; after this time-frame, to aid in development costs, you must renew your access to updates (see the purchase link below for further information). You cannot freely provide this script to others without written permission from the author.
Pricing: $100 (Purchase Here)
Support: Support is available on the UBB.Dev thread UBB.threads Bounced EMail Processor.

This script will connect to your mail server (over an IMAP connection; POP3 SHOULD work, but is untested and is unsupported) and gather any bounced email messages and will either build a list of addresses needing attention (utilizing the Bounce Handler Class (v7.4.1 VNC)), or will disable the notifications for the user. If selected it will also add the user to a specified group so that you can manage all of the users through the UBB.threads Member Management system.


 

Additional Files


Your install archive will contain several files, namely:
• library/ - The PHP Bounce Handler class library files (v7.4.1 VNC; rewritten to fix several issues that would fill your error logs).
• readme.txt - A brief readme which gives basic tips on getting started, and a link here to the full documentation.
• ubb.bounce.php - The UBB.threads Bounced EMail Processor script itself.


 

Demonstration


Browser View


Browser View - Add to Group


Command Line View



 

How Does it Work?


Here we will run down how the script works and show the process that we process your mail server, messages, and user data.

Items integrating into your database are prefixed (Integration); integrating into UBB.threads gives you the option of displaying the username/pdn/id of the user that the email address belongs to. You can also assign users to a group or disable their email settings if you integrate into your UBB.threads install.

• Check if being loaded from the Command Line (generally through Cron or SSH).
• Check if integration are enabled
• Fetch all messages in mailbox.
• Process messages through the Bounce Handler class (which checks what the body of the messages contain, and if the message is a bounce then it'll add the associated EMail address to an array. Additionally the message ID is added to a separate array which is used to purge the messages from the folder on the mail server (if enabled).
• Display the header; start building the top portion of the page, before running through the data.
• Processes data - we start to sort through the data supplied from the mail server.
      • If you've selected a minimum amount of messages the ones which are under that total are dropped here (well, really the ones at or above the amount are processed here).
• (Integration) We lookup the user information.
• (Integration) We check if you're using SE friendly or SEO URLs
• (Integration) We disable some settings for the user:
User Settings
      • Accept Admin EMails
      • EMail Watched Lists
      • Notify on PM
Admin/Moderator Settings
      • Unapproved Post Notifications
      • Report Post Notifications
      • New User Notifications
      • Multiple Login Notifications
• (Integration) Validate that their settings have been disabled.
• (Integration) If we've chosen to assign all bounced users to a group, we process them here.
      • Check if the user already exists in the group.
      • If they exist, display so.
      • If they don't exist, add them to the group.
      • Validate that they've been added.
Note
If you've opted to not integrate into your UBB.threads install the only processing that's done with the message is this next step; if you've chosen to integrate and just chose to generate a listing this step is done here.

• If we've indicated that we want to prune messages from the server, it's done now.
• We now close the IMAP server connection and process any cleanup tasks.
• Display the footer and close the script.


 

Install Instructions


Simply set the connection information (# Define Variables) and any configuration information (# Configuration) and upload to your web root (Example: http://www.example.com/ubb.bounce.php). The PHP Bounce Handler class will need to be uploaded to a "library/bounce/" directory, as indicated in the included archive.


 

Usage Instructions


From your Browser: Load the file in your web browser and it will connect to the specified mail server and process the data as you've configured.

From the Command Line: You can execute the UBB.threads Bounced EMail Processor from the Command Line by calling the PHP binary (the command "which php" will tell you the location of the PHP binary on your server):
Code
/usr/bin/php /home/example/public_html/ubb.bounce.php



 

Settings


$conf["username"] - The login name that you use to login to your email address.
$conf["password"] - The password that you use to login to your email address.
$conf["server"] - The hostname of your mail server (such as "imap.gmail.com").

$conf["action"] - The action variable tells the script what we should do with any bounced users (Default: 1); the settings are:
      0/Nothing will just generate a listing of users for you to process manually as you see fit.
      1/Disable will disable various notification settings in UBB.threads.

$conf["delete"] - The delete variable indicates whether we should delete the emails from your mailbox once we've processed them. (0/No, 1/Yes; Default: 0)

$conf["failures"] - The failures variable is a method for you to select users with a minimum amount of bounced messages. To select all users with any bounces you would set this to "1"; to select users who've returned 4 bounced messages you would set this to "4". (Default: 1)

$conf["folder"] - The folder variable indicates a folder on the mail server that you would like to process. The default, blank, setting looks in the INBOX folder.
Note
Basic folders on an IMAP Account are: INBOX, SENT, SPAM, TRASH

Subfolders (a folder within a folder) must be appended with a period (Example: "INBOX.subfolder").


$conf["group"] - The group variable indicates if you'd like to add any bounced users to a specified group on your UBB.threads instance. Simply create a custom group within UBB.threads and set that Group ID as this variable. A setting of "0" will disable this function.

$conf["integrate"] The integrate variable indicates if you would like to integrate into your UBB.threads install; this will allow you to show details about the user (User ID, Login Name, and Public Name +Plus a link to their profile (all HTML is stripped from the Command Line). You will need to set the below '$conf["path"]' variable to the correct directory of your UBB.threads install. (0/No, 1/Yes; Default: 1)

$conf["path"] - The path variable is the path from your web root to your UBB.threads install, without a trailing slash (Example: "/forum").

$conf["ssl"] - The ssl variable indicates if we should we send login information to your mail server over SSL. If your mail server accepts SSL we would highly advise for this to be enabled (0/No, 1/Yes; Default: 1)

$conf["suppress"] - The suppress variable indicates whether we should suppress information other than the EMail address; this information would generally only show if you've integrated into your UBB.threads database with the '$conf["integrate"]' and '$conf["path"]' variables above. (0/No, 1/Yes; Default: 0)

$conf["type"] - The type variable indicates how we should connect to the mail server. (0/POP3, 1/IMAP; Default: 1)


 

Changelog


 v0.1 (November 3rd, 2015)
• Initial version released to the public.


 

Frequently Asked Questions


 

What does purchasing a license entitle me to?


By purchasing a license to the UBB.threads Bounced EMail Processor script you're entitled to lifetime support of the script for the lifetime period of the script. You also receive access to a year of updates for free. After the year period; updates are purchased in blocks of 1 year for $50/yr to cover development costs. Please note that you are entitled to install this script on ONE domain per license; additional domains will require additional licenses.

 

I'm getting an IMAP error!


There are multiple errors which can be returned from the IMAP functions; examples of what we've been able to trigger through testing are:

• "IMAP Authentication cancelled" - This seems to be a generic error when a connection cannot be attempted; check the make sure that your account isn't locked (GMail users login to your GMail account and click here).
• "No such host as [hostname]" - Your hostname could not be connected to.
• "Can not authenticate to IMAP server: [CLOSED] IMAP connection broken (authenticate)" - There is a problem authenticating to your account (wrong user account in test).
• "Can not authenticate to IMAP server: [AUTHENTICATIONFAILED] Invalid credentials (Failure)" - There is a problem authenticating to your account (wrong password in test).

Note
A listing of the errors from the "imap_last_error()" function are:
• "Scan not valid on this IMAP server"
• "Unable to negotiate TLS with this server"
• "IMAP Authentication cancelled"
• "Can't do secure authentication with this server"
• "Server disables LOGIN, no recognized SASL authenticator"
• "Can't do /authuser with this server"
• "Too many login failures"
• "Login aborted"
• "[NOTUIDPLUS] Can't do UID EXPUNGE with this server"
• "Excessively complex sequence"
• "Can't access server for append"
• "ACL not available on this IMAP server"
• "Quota not available on this IMAP server"


Note
Possible notations in your error log would be similar to:
[Date] [warn] [client IP] mod_fcgid: stderr: PHP Warning: imap_open(): Couldn't open stream {imap.example.com:993/imap/ssl/novalidate-cert} in /home/user/public_html/ubb.bounce.php on line 85
[Date] [warn] [client IP] mod_fcgid: stderr: PHP Notice: Unknown: IMAP protocol error: Client aborted AUTHENTICATE command. q69mb588127036itc (errflg=2) in Unknown on line 0
[Date] [warn] [client IP] mod_fcgid: stderr: PHP Notice: Unknown: IMAP Authentication cancelled (errflg=2) in Unknown on line 0


 

I'm having issues with the firewall on my system


If you're having issues connecting to your remote mailbox and you're positive that the information that you've provided is correct, you are likely having issues with the connection being dropped due to your firewall settings on the system (basically, you need to make sure that the mail ports are not blocked on the server); if your host has blocked them they will need to be allowed through the system firewall.

The ports that need to be allowed through the system firewall are:
IMAP/SSL: 993
IMAP/NoSSL: 143
POP3/SSL: 995
POP3/NoSSL: 110

 

I'm getting a security error while connecting to GMail or Google Apps.


You'll need to lower the security level on your account; you can do this from here.

 

I'm having issues with connecting on an Apache Server on Windows


There has in the past been a bug within the Apache system on Windows that SSL appears to be compiled but in actuality is not; you'll need to ensure it is compiled in the system, or don't access the remote mailbox over SSL.

 

I cannot connect to my local mail server using 127.0.0.1


Use "localhost" instead.

 

Things seem really slow


There are several items that can slow down a connection to a remote server, several of which we thought of when writing this script (always specifying a port for example). One tip that was suggested via the PHP.net discussion was to utilize an IP address versus a HostName; where this may not work on some servers, it will connect faster if they do support it.
Posted on November 3rd, 2015 - Updated on November 10th, 2015
▼ Sponsored Links ▼
▲ Sponsored Links ▲

Comments

( Posted)

Related Products

▼ Sponsored Links ▼
▲ Sponsored Links ▲
For the best viewing experience please update your browser to Chrome, Firefox, or Opera