beautypg.com

Appendix b. using the fake sms center, Setting up fakesmsc, Compiling fakesmsc – Nokia WAP and SMS gateway User Manual

Page 102: Configuring kannel, Running kannel with fakesmsc connections, Starting fake sms center, B. using the fake sms center, 94 configuring kannel

background image

Appendix B. Using the fake SMS center

Fakesmsc is a simple testing tool to test out Kannel and its SMS services. It cannot be used to send
messages to mobile terminals, it is just a simulated SMS center with no connection to real terminals.

Setting up fakesmsc

This section sums up needed steps to set up system for fakesmsc use.

Compiling fakesmsc

The fake SMS center should compile at the same time as main Kannel compiles. The outcoming binary,

fakesmsc

, is in

test

directory. The source code is quite simple and trivial, and is easily edited.

Configuring Kannel

To use

fakesmsc

to test out Kannel, you have to add it to main configuration file (see above). The

simplest form for this configuration group is like this:

group = smsc

smsc = fake

port = 10000

The fakesmsc configuration group accepts all common ’smsc’ configuration group variables, like

smsc-id

,

preferred-smsc-id

or

denied-smsc-id

, which can be used to test out routing systems

and diverted services, before setting up real SMS center connections. If you include a fakesmsc group
when bearerbox is connected to real SMS centers, you should add the

connect-allow-ip

variable to

prevent unauthorized use.

To set up multiple fakesmsc’es, just add new groups. Remember to put a different port number to each
one.

Running Kannel with fakesmsc connections

After configuring Kannel, you can start testing it. The bearerbox will listen for fakesmsc client
connections to the port(s) specified in the configuration file.

Starting fake SMS center

Each fakesmsc is started from command line, with all sent messages after command name. If any options
are used (see below), they are put between the command and the messages. The usage is as follows:

test/fakesmsc [options]

[message2 ...]

95