Build a Push Proxy Gateway on Linux
By Manas Ranjan Behera
2005-06-15
Configuring the gateway for PPG
In the previous article in this series, you downloaded and installed the gateway; if you haven't already done this, refer back to that article for instructions. In this section, I describe how to start configuring the gateway for PPG. I use two components: the PPG core group and the PPG user group. The PPG core group is used to configure the PI interface. Configuring the PPG core group (PI interface) In the main Kannel configuration file (kannel.conf), you must add one more group (like wapbox and bearerbox) with the name ppg and set up the corresponding values. My sample configuration file for this group is shown in Listing 3. Listing 3. Sample configuration file for ppg group
group = ppg
ppg-url = /wappush
ppg-port = 8080
concurrent-pushes = 50
users = 52
ppg-allow-ip = 192.168.1.35;127.0.0.1
trusted-pi = false
|
However, you can add your own fields and configure the settings to your own needs. Table 1 defines some of the variables that can be set. (To familiarize yourself with setting and using these variables, see the first article of this series.) Note that Tables 1 and 2 include information about ways to route push messages through a SMS gateway, but those features are beyond the scope of this article. Table 1. PPG core group configuration variables
| Variable | Value | Description | group | ppg | Mandatory value. Indicates that you are configuring the PPG group. | ppg-port | number | The port at which PPG is listening. The default is 8080. | ppg-ssl-port(o) | number | Mandatory value for PPG HTTPS support. The port at which PPG listens for HTTPS requests. There are no defaults; you must set the value separately. | ssl-server-cert-file | string | Mandatory value for PPG HTTPS support. This file contains the server's SSL certificate. | ssl-server-key-file | string | Mandatory value for PPG HTTPS support. This file contains the server's SSL private key. | ppg-url | URL | Location of PPG services. The default is /wappush. | global-sender | string | The sender phone number. This is required by some protocols. | concurrent-pushes | number | The number of concurrent pushes expected. Note that PPG works even if the value is too low; it will only be slower. The default is 100. | users | number | Number of actually configured user accounts. Note that PPG works even value is too low; it will only be slower. The default is 1,024. | trusted-pi | boolean | If true, PI does authentication for PPG. Obviously, both must reside inside the same firewall. The default is true. If this variable is true, all security variables are ignored (even though they might be present). | ppg-deny-ip | ip-list | PPG does not accept pushes from these IP addresses. Wildcards are allowed. If this attribute is missing, no IP address is denied by this list. | ppg-allow-ip | ip-list | PPG accepts pushes from these, and only these, IP addresses. Wildcards are allowed. If you add this list, IP addresses not mentioned are denied. | default-smsc | string | If no SMSC ID is given with the wappush HTTP request (see below), this one is used as the default route for all push messages. | default-dlr | string | If no DLR-URL is given with the wappush HTTP request (see below), this one is used as the default route for all push messages. | ppg-smsbox-id | string | All PPG delivery reports are handled by this smsbox. This routes all DLR messages inside bearerbox to the specified smsbox for processing the HTTP requests to the DLR-URL. | service-name | string | This is the SMS service name used by smsbox for WAP push. | default-dlr | string | If no DLR-URL is given with the wappush HTTP request (see below), this one is used as the default route for all push messages. | ppg-smsbox-id | string | All PPG delivery reports are handled by this smsbox. | service-name | string | This is the SMS service name used by smsbox for WAP push. The default is on. You normally do not need to set this value. | max-messages | integer | Maximum number of SMS messages generated. The default is 10. You only need to set this variable when your push documents are very long. |
Configuring the PPG user group You also need to configure the PPG user group values in the configuration file. Table 2 describes the details of the variables and values. Table 2. PPG User group configuration variables
| Variable | Value | Description | wap-push-user | string | (More) human readable name of a user. | ppg-username | string | Username for this user. | ppg-password | string | Password for this user. | allowed-prefix | number-list | Phone number prefixes allowed in pushes coming from this PI. These prefixes must conform to the standard international phone number format. | denied-prefix | number-list | Phone number prefixes denied in pushes coming from this PI. These prefixes must conform to the international phone number format. | white-list | url | Defines a URL from which the whitelist can be fetched. The whitelist itself contains list of phone numbers accepting pushes from this PI. | black-list | url | Defines a URL from which the blacklist can be fetched. The blacklist itself contains list of phone number not accepting pushes from this PI. | allow-ip | ip-list | Defines IP addresses from which this PI can do pushes. Adding this list means that addresses not mentioned are denied. | deny-ip | ip-list | Defines IP addresses from which this PI cannot do pushes. Addresses not mentioned in either list are denied, too. | default-smsc | string | If no SMSC ID is given with the wappush HTTP request (see below), this one is used as the default route for this specific push user. The forced-smsc string allows only routing to a defined SMSC ID for this specific push user. | dlr-url | string | If no dlr is given with the wappush HTTP request (see below), this one is used as default route for this specific push user. | smsbox-id | string | smsbox handles delivery reports from this user. | forced-smsc | string | Allows only routing to a defined SMSC ID for this specific push user. | white-list-regex | POSIX regular expression | Defines the set of phone numbers accepting pushes from this PI. | black-list-regex | POSIX regular expression | Defines the set of phone-numbers rejecting pushes from this PI. |
Tutorial Pages:
»
Introduction
»
Basic overview of push
» Configuring the gateway for PPG
»
Testing with a handset simulator
»
Resources
First published by IBM DeveloperWorks
|

|