spacer
isapilabs
OverviewspacerDownloadsspacerFAQspacerDocumentationisapilabs
banner
spacer
spacerAffiliateMask Documentation
Table of Contents

Introduction to AffiliateMask
Getting Started - (Installation Procedures)
       Running the Setup Wizard
       Configuring IIS Using AffiliateMask
       Configuring IIS Manually
       Files to be Installed
Feature List
Configuration
       User Interface
              QuickStart
              Mask
              Domain Rules
              Advanced
              License
       Manual Configuration via Config File
       Retrieving HTTP Headers via Scripting Languages
       Retrieving Cookies Via Scripting Languages
Frequently Asked Questions
Uninstalling
System Requirements
Release Notes
Licensing/Purchasing
Technical Support
Contact Information


Introduction to AffiliateMask

You Have a Problem...
Your Affiliate Program Has You In Hot Water You've set up shop on the Internet and you're ready to sell your products. There's just one catch-you need to get people to visit your web site so they can buy your products! So, you start an affiliate program that helps get the word out about your site by giving web masters an incentive for driving hits to your site. But, now your affiliate program is creating another problem-your affiliate is spamming people, you're taking the heat for the spam, and your affiliate is getting undeserved credit for the hits.

AffiliateMask Can Cool Things Down!AffiliateMask helps you set up an affiliate program that is safer and more secure than ever before. Most affiliate programs use an affiliate ID, which is added to the end of a URL and might look something like this: http://www.sample.com/item/indes.php?affiliateid=123456. When a customer visits that page by clicking on a link supplied by your affiliate, credit is stored for your affiliate. But, if your affiliates have access to the ID number, they can use it to create spam e-mails that will give them undue credit.

AffiliateMask is Your Solution!
Here's where AffiliateMask comes in. You see, AffiliateMask hides the affiliate ID making it impossible for affiliates to get credit for hits to your site gained through e-mail. Instead, your affiliate gets credit only for legitimate hits made by referring visitors through the affiliate's web site.

In addition to protecting your reputation, AffiliateMask gives your affiliates who make legitimate referrals some protection. In some cases, users who see an affiliate ID in their web browser URL may remove it, which prevents your affiliate from getting credit for purchases made through the affiliate's link. With AffiliateMask, users don't see the ID, so they can't remove it.

Here's How AffiliateMask Works
AffiliateMask is an Internet Server Application Programming Interface (ISAPI) filter for Internet Information Server (IIS) that tracks affiliate referrals to your web site. AffiliateMask hides the affiliate ID from users and does away with affiliate IDs appended to URLs.

AffiliateMask masks or hides the affiliate ID by setting a cookie in the browser of a web visitor referred by an affiliate's web site. This set up makes both parties of the affiliate program happy; the affiliate gets credit for the traffic his or her site drove to your web site and you have an affiliate program that is more secure and is transparent to web visitors. And the best part is that you get visitors to your web site where they can buy your products and put money in your pocket!



Getting Started - (Installation Procedures)

AffiliateMask uses a setup wizard to make the installation process as easy as possible. The next four sections will help you run the setup wizard, configure IIS to use AffiliateMask, and provide you a list of files that are installed.

Running the Setup Wizard
To run the setup wizard for AffiliateMask:

  1. Double click on the setup file to display the setup program. A screen titled "Welcome to AffiliateMask Setup Wizard" will appear and ask you to verify that you want to install AffiliateMask.


  2. Click "Next" to continue the setup.


  3. You will be asked to select a destination or installation directory. Click "Next" to continue setup. (Note: AffiliateMask's default installation destination is "C:\Program Files\AffiliateMask\". However, you can install it in any directory you specify.)


  4. Click "Install" to confirm that AffiliateMask is to be installed on the computer and finalize the customization of the AffiliateMask installation.


  5. When the installation is complete, a screen titled "Completing the AffiliateMask Setup Wizard" will appear. The screen includes two checkboxes: "Auto-configure IIS to work with AffiliateMask" and "Launch AffiliateMask." Selecting the Auto-configure box will allow the setup program to prepare IIS to immediately begin working with AffiliateMask. (Note: It is best to restart after the setup is complete.) However, if you choose to leave the Auto-configure box unchecked, you may use the configuration tool later to manually configure or auto-configure AffiliateMask to work with IIS.


  6. Click "Finish" to close the setup program.
Configuring IIS Using AffiliateMask
To set up IIS to work with AffiliateMask:

  1. Open the AffiliateMask configuration tool.


  2. Click on the QuickStart tab near the top of the window.


  3. Click the "Add to Webserver" button. (Note: If this button is disabled, it means that IIS is already configured to work with AffiliateMask. To remove the AffiliateMask configuration in IIS click on the "Remove from Webserver" button. This will stop IIS from running AffiliateMask.
Configuring IIS Manually
IIS can be configured manually to work with AffiliateMask using the following steps:

  1. Open the Internet Information Services configuration utility. (You can access this utility by opening Control Panel, double-clicking on Administrative Tool, and clicking on Internet Services Manager icon).


  2. Right-click on the server that AffiliateMask will be installed on and select Properties.


  3. Under the Internet Information Services tab is a group of options called Master Properties. Click on the "Edit" button and select the ISAPI Filters tab.


  4. Click on the "Add" button to add AffiliateMask to the list of filters IIS uses.


  5. In the Filter Properties dialog enter the following information:

    • Under Filter Name, enter "AffiliateMask."
    • Enter the location of the AffiliateMask DLL file. (Note: The DLL file is is always located in the directory where AffiliateMask was installed "C:\Program Files\AffiliateMask\." To locate the file in Windows Explorer, click "Browse".)

  6. Click "OK" until you return to the Internet Information Services configuration utility.


  7. Right-click on the server and select Restart IIS. When the restart is complete, IIS is ready to work with AffiliateMask.
For further step-by-step instructions, visit our Quick Help support area, which shows screenshots of how to install and uninstall an ISAPI plugin with IIS.

Files To Be Installed
The following files are installed during setup and are required to allow AffiliateMask to run properly:

File NameDescription
amask.exeAffiliateMask Application
amask.cfgAffiliateMask Configuration File
amask.dllAffiliateMask DLL
amask.htmAffiliateMask Help Documentation
elmsg.dllAffiliateMask Event Log DLL




Configuration

User Interface
All the settings for AffiliateMask can be configured using the AffiliateMask configuration tool. The configuration tool has several tabs: QuickStart, Mask, Domain Rules, Advanced, and License. These tabs provide access to all of AffiliateMask's settings, which make it possible for you to configure AffiliateMask to meet the needs of any web server application.

The "Load" button (located at the bottom of the AffiliateMask application) allows you to load new configuration settings from a configuration file. You can save the configured settings to a configuration file using the "Save" and "Save As" buttons. Use the "Reset" button to reset the current configuration to the AffiliateMask default values. No changes will take effect until they are saved. AffiliateMask periodically checks to see if a new configuration file is available. If the configuration file currently available is newer than the one AffiliateMask has loaded, it will load the new one into memory. one into memory.

When AffiliateMask is started, by default the configuration file that is located in the directory where AffiliateMask was installed (usually "C:\Program Files\AffiliateMask\") is started up as well.

QuickStart
QuickStart is a fast and easy way to configure AffiliateMask. With QuickStart, you can integrate AffiliateMask into IIS with the click of a button.

Enable Masking
Masking can be globally turned on and off for debugging purposes. When you turn off masking it also disables HTTP headers. Cookies that have already been created by your browser can be accessed by the HTTP header: HTTP_COOKIE.

Auto-Configuring IIS to Work with AffiliateMask
Unlike other ISAPI filters for IIS, you can start or stop AffiliateMask from being loaded by IIS using AffiliateMask's configuration tool. AffiliateMask allows for maximum control within IIS without having to adjust the Internet Services Manager settings or manually configure AffiliateMask to work on IIS. Instead, AffiliateMask can configure itself into or out of IIS with minimal effort on your part. To allow the AffiliateMask filter to be loaded by IIS, click on the "Add to Webserver" button. IIS will start using AffiliateMask the next time IIS is restarted or the next time the computer is restarted. To stop the AffiliateMask filter from being loaded by IIS, click on the "Remove from Webserver" button. AffiliateMask will then be removed from use by IIS the next time IIS is restarted or the computer is restarted.



Mask
Masks are an important feature in AffiliateMask that can maximize the potential of your affiliate program. Most affiliate programs display the affiliate ID in the URL, so we call these Masks because they hide the ID or user name in a cookie that is located on the web visitor's computer. Each time the visitor returns to your web site, they carry the referrer information with them via the cookie.

AffiliateMask will match the masks you create to the nearest match so that only one cookie is created at a time. If you set the mask to *microsoft.com/products/ and also set a mask for *microsoft.com/, it will match the referer of *microsoft.com/products/windowsxp/ with the mask *microsoft.com/products.

The Masks section contains all of the active masks currently being applied. The "Add," "Edit," "Remove," and "Reset" buttons allow existing masks to be modified and new ones to be created.

Adding a Mask
To create a new filter item, click on the "Add" button located at the bottom of the screen. The Properties dialog will appear; this is where you will enter all properties of the new filter you want to create. Each filter you create will determine under what circumstances AffiliateMask should operate.

Referer
The referrer is the web site of your affiliate. If your affiliate's web site is http://www.sample.com/~nathan/, enter that address in the referrer filter property. Wildcards are accepted at the beginning and end of the referrer string. Therefore, *sample.com/~nathan/* would produce the same results.

There is no need to use http:// in the referer string, but if you do, AffiliateMask will remove it. Also when using the string "*" for the referer it should be noted that when browsing through your web site the referer will be the last page you visited on your web site. For example, the referer for images on your web site are actually the page where the image is displayed. It is not recommended that you use "*" as a referer unless you use the skip cookie name (if it already exists) property. This way the cookie will not be recreated as the user browses through your web site.

Cookie Name
This filter property specifies the name of the cookie to create when the web visitor comes from your affiliate's web site to yours. This is the name of the cookie that will be accessed using web-scripting.

Cookie Value
The cookie value should contain the value of the cookie. For instance in the example below, the cookie might be used to store a unquie id or username of the affiliate who runs the web site that you entered in for the Referer. To set this value to the referer url you can enter in {Current.Referer} and the value will be set to the web page that the user is coming from.

Examples
To create an affiliate mask for your affiliate at http://www.sample.com/~eddie/, enter the following:
Referer: *www.geocities.com/~eddie/*
Cookie Name: AffiliateID
Cookie Value: 8795411
Therefore, the cookie that is created will be AffiliateID=8795411.

Another way to do this might be:
Referer: *www.geocities.com/~eddie/*
Cookie Name: 8795411
Cookie Value: {Current.Referer}
And the cookie that is created will be 8795411=http://www.geocities.com/~eddie/index.html. And in this instance you will always know the exact page where affiliate traffic is getting redirected to you from.

Editing Masks
To edit an item that has already been added, select the item in the list and click the "Edit" button, or just double click on the item. The Properties dialog will appear with the item's information already entered. Change the information that needs changing and click "OK" to modify the item, or click Cancel to discard any changes.

Removing Masks
To remove an item from the list of active filters, select the filter and click the "Remove" button. To clear all of the filters from the list, use the "Reset" button.



Domain Rules
Using the domain settings, you can configure AffiliateMask for each domain or web site that is a part of your affiliate program. If you have an affiliate that has a web site http://www.samplesite.com/~sarah/, you can set specific AffiliateMask settings for all affiliates that come from samplesite, or just for Sarah's web site at samplesite.com.

The domain section contains all the per-domain settings that apply to the operations of AffiliateMask. The "Add," "Edit," "Remove," and "Reset" buttons allow the modification of existing domains or the creation of new ones.

Adding a Domain
To create a new filter item, click on the "Add" button located at the bottom of the screen. The Properties dialog will appear; this is where you will enter all properties of the new filter you want to create. Each filter you create will determine under what circumstances AffiliateMask should operate.

Domain
The domain is the web site where the settings will apply. You should not use "http://" when you enter the domain.

Cookie Expiration Time (Minutes)
Specifies the amount of time in minutes that the cookie will remain active on web visitor's browsers.

Skip Cookie Name (if already exists)
This feature gives you the option to skip the creation of specific cookies by name if they already exist in the user's browser. So, if they happen to be redirect from a web page twice in one day, the cookie would not be recreated the second time in the user's browser. This option effects all cookies that are created.

Examples
Domain: *geocities.com*
Expire: 100
Skip Cookie Name: AffiliateID

Editing Domains
To edit an item that has already been added, select the item in the list and click the "Edit" button, or just double click on the item. The Properties dialog will appear with the item's information already entered. Change the information that needs changing and click "OK" to modify the item, or click Cancel to discard any changes.

Removing Domains
To remove an item from the list of active filters, select the filter and click the "Remove" button. To clear all of the filters from the list, use the "Reset" button.



Advanced
Start/Stop Notification
With the Start/Stop Notification feature you can have AffiliateMask put a notification in the Windows Event Log each time AffiliateMask starts or stops.

HTTP Headers
HTTP headers are another way to access the affiliate information that is generated by cookies each time visitors come to your web site from your affiliate's web site. The name of the HTTP header that is used can be changed. The HTTP header name that you enter should not contain "HTTP_" because the server adds "HTTP_" to the name already. If you don't enter in anything, the default value for the HTTP header name is "X-Affiliate." All dashes are translated to underscores. The value of the HTTP header is in the following format: CookieName=CookieValue.

Global Cookie Expiration Time
Global Cookie Expiration time is the amount of time in minutes before the cookies that are set by AffiliateMask expire on web visitor's computers. Each time a user comes to your web site from your affiliate's web site AffiliateMask sets a cookie in the web visitor's computer. The cookie expiration time is simply the amount of time the cookie should stay active after it has been created. Setting longer expiration times ensures that affiliates get credit for web visitors' purchases even when the user takes a long time to look around. Use domain settings to control the cookie expiration time for each domain and override the global cookie expiration time setting.

Skip Cookie Name (if already exists)
You can specify a cookie name which will not be recreated in the user's browser if a cookie by the same name already exists there.

Mask/Domain Rules
With the Mask/Domain Rules option you can select a new configuration file to save the mask and domain rules into. You can enter in a new file name or select an already existing file. Any file you select will be overwritten with the rules and your current configuration file will link to the new rules file.

Logging
This feature allows the generation of log files in the supplied log file directory. The log files contain information on all the operations that AffiliateMask performs. By default, this feature is turned off.

Log File Format
Each time a log file is generated, it is generated in a particular format. This format always begins with the date and time the event occurred, followed by the description of the event. For example:

12/14/2003 17:34:52 New configuration applied

This states that a new configuration was applied on 12/14/2003 at 17:34:52. The most important event that is displayed in the log is:

01/02/2004 19:35:39 Server:mechwarrior IP:192.168.0.105 From:http://mechwarrior/ Set:CookieName=CookieValue

The description for this event shows your server's hostname followed by the IP address and URL of the referer and then followed by the information that is used to set the cookie.

A log file record is also kept each time AffiliateMask starts up or shuts down. The format for such an event looks like:

12/12/2003 19:08:30 AffiliateMask v0.8 (Beta) started
12/12/2003 19:08:31 AffiliateMask v0.8 (Beta) shutdown


The description of this event displays the date and time of the event, the name of the ISAPI plugin, the version number, and whether or not a start up or shutdown event occurred.



License
The License tab provides information about the current copy of AffiliateMask, including the version number, the number of AffiliateMask copies that have been used, and the number of copies that can still be used with the current serial number.

Manual Configuration Via Configuration File
It is possible to configure AffiliateMask manually by editing the configuration (.cfg) file for AffiliateMask, which is located in the directory where AffiliateMask was installed. This is recommended for advanced users only. The configuration file can be edited by loading it into notepad. The format is similar to the format for Windows INI files. After changes have been made to the file and the amask.cfg file is saved, AffiliateMask will automatically reload the configuration file and use its new settings. Entries that take integers look like this: MinFileSize:1000. Entries that take strings look like this: LogDirectory:"logs" or SupportProxyIP:"TRUE".

Logging
LogEnabled:[TRUE/FALSE] default: FALSE
LogDirectory:[string] default: log-amask\


Event Log Notification
NotifyStartStop:[TRUE/FALSE] default: FALSE

Masking
MaskEnabled:[TRUE/FALSE] default: TRUE

HTTP Headers
HeaderTag:[string] default: X_Affiliate
AddHeader:[TRUE/FALSE] default: FALSE


Cookies
CookieExpireMinutes:[integer, minutes] def: 1440
SkipCookieName:[string] ie. "CookieName"


Referers
Referer:[string] ie. "http://*.cat.com/*==CookieName=CookieValue"

Domains
DomainName:[string]
DomainCookieExpireMinutes:[integer]
DomainSkipCookieName:[string] ie. "CookieName"
DynamicDataFilename:[string] ie. "rules.cfg"
Monitor:[string] ie. "rules.cfg" (Reloads config when rules.cfg changes)




Retrieving HTTP Headers via Scripting Languages
HTTP headers can be used as an alternative to cookies. This ensures that a cookie is not stored on the web visitor's computer. HTTP headers can be enabled in the Advanced tab of the AffiliateMask configuration tool. The default header name is HTTP_X_AFFILIATE. The value of the HTTP header is in the format CookieName=CookieValue, where CookieName and CookieValue are the values of the cookie that would have been created if HTTP headers were turned off.

PHP: if (isset($_SERVER['HTTP_X_AFFILIATE'])) return $_SERVER['HTTP_X_AFFILIATE'];
ASP: Request.ServerVariables("HTTP_X_AFFILIATE")
CGI: print $ENV{'HTTP_X_AFFILIATE'};


Retrieving Cookies via Scripting Languages
Cookies can be retrieved in most web-scripting languages. You want to retrieve the cookie that AffiliateMask sets and use that cookie to credit your affiliate. Using cookies is simple because it can be easily integrated into any already existing affiliate program. Below are some examples of how to retrieve cookies in various languages:

JavaScript:

    var ID = GetCookie(AffiliateID);
        

    function GetCookie(name) {
      var dc = document.cookie;
      var prefix = name + "=";
      var begin = dc.indexOf("; " + prefix);
      if (begin == -1) {
        begin = dc.indexOf(prefix);
        if (begin != 0) return null;
      } else
        begin += 2;
      var end = document.cookie.indexOf(";", begin);
      if (end == -1)
        end = dc.length;
      return unescape(dc.substring(begin + prefix.length, end));
    }
        

PHP:

    $ID = GetCookie("AffiliateID");
        

    function GetCookie($name)
    {
    if (isset($_COOKIE[$name]))
        return $_COOKIE[$name];
    return FALSE;
    }
        

ASP:

    Dim Id
    Id = GetCookie("AffiliateID")
        

    Function GetCookie(Name)
       GetCookie = Request.Cookies(Name)
    End Function
        




Uninstalling

To Uninstall AffiliateMask, click on the Uninstall icon that is located in the Program Folder for AffiliateMask in the Start menu. This will run through the uninstall program and uninstall AffiliateMask. If the AffiliateMask filter is currently in use by IIS, the AffiliateMask DLL file that IIS uses will be deleted the next time the system is restarted.

For further step-by-step instructions, visit our Quick Help support area, which shows screenshots of how to install and uninstall an ISAPI plugin with IIS.

System Requirements

AffiliateMask requires Windows NT/2000/XP Professional/2003 .NET with Microsoft Internet Information Services (IIS) 5.x or 6 and at least 128 MB of RAM.

Release Notes

Version 1.01 - Added file tracking for config updates
Version 1.00 - First release of AffiliateMask

Licensing/Purchasing

For important information on purchasing a copy of AffiliateMask, please contact ISAPILabs at http://www.isapilabs.com/.

Technical Support

All technical support is available via our support page located on the World Wide Web at http://www.isapilabs.com/.

Contact Information

To contact us, please visit our contact page.



spacer
     Copyright ©2004 ISAPILabs. All rights reserved. | Sitemap
spacer