How to Block One or More Countries From Posting to Your Ping Tree
We decided to post these instructions because of all of the recent news about nation-state hacking. TSL has had this capability since we added the IpInfo modifier. There are many strategies for doing this and this article will describe a few of them but you can probably find other ways to set up country blocking.
What IS the Country Code?
You can determine the country code for a country by looking at this web page (you must be logged into the TSL Ping Tree portal to access this list). That list shows the official names of the countries and sometimes it may not be easy to figure out, for example, which country is South Korea and which one is North Korea. If you run into that issue, go to this this Wikipedia page.
The country list on our portal is automatically updated every month when we update the IP to Country list. It lists the countries sorted by country and also by country code. You can see the country code for every country, for example China:
and the Koreas:
By Offer or Globally?
If you want to apply the filter to ALL of your posts, regardless of promotion, ping tree, or lead point, you can create a global filter. Do this by selecting "Global" for "Filter Type" on the "Settings" tab of the filter configuration page. Once you have done this, you do not have to attach this filter because it will apply to all posts into your TSL Ping Tree customer.
To Block or Allow
If your offer is only allowed in one country, it is much easier to just set up an allow filter. For example, if you are in the US, you can set up a filter to allow the country codes "US" and "-". The "-" (dash) country code is the country code returned when the IP address is not included in the IP to Country database. Note that we update the IP to Country database around the 5th of every month, but there could be a window of time where newly assigned IP addresses return a dash. Set up this type of filter like this:
Just Block One Country
If you just want to block one country, you can set up a filter like this example which blocks posts from the United States:
Just Block a Couple of Countries
If you want to block a few countries, you can set up a filter like this example which blocks posts from China and North Korea:
Block or Allow a Large List of Countries
If you want to block (or allow) a large list of countries, you can use a string list to do this. First, set up a string list and upload the list of blocked or allowed country codes. Then set up the filter like this example: