Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

2010-10-06 Stipe Tolj <stolj at kannel.org>

    * */*: changing the add-on module name to OpenSMPPBox, along with all 
      references in the output and the configuration file aspects.


git-svn-id: https://svn.kannel.org/opensmppbox/trunk@54 0b225a68-5fa7-45c5-9c9e-d7f6881f360f
  • Loading branch information...
commit 977e422cca2d76ee97aa9659759dbddd35580f7b 1 parent a98abfe
stolj authored
View
2  COPYING
@@ -1,2 +1,2 @@
-See file KannelLICENSE for details about the license agreement for using,
+See Kannel LICENSE file for details about the license agreement for using,
modifying, copying or deriving work from this software.
View
4 ChangeLog
@@ -1,3 +1,7 @@
+2010-10-06 Stipe Tolj <stolj at kannel.org>
+ * */*: changing the add-on module name to OpenSMPPBox, along with all
+ references in the output and the configuration file aspects.
+
2010/09/15
Sending negative ack upon receiving invalid MO/DLR so messages won't stay in bearerbox store.
Patch by Victor Luchitz.
View
9 INSTALL
@@ -1,12 +1,3 @@
-Installation Instructions
-*************************
-
-Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free
-Software Foundation, Inc.
-
-This file is free documentation; the Free Software Foundation gives
-unlimited permission to copy, distribute and modify it.
-
Basic Installation
==================
View
8 Makefile.am
@@ -1,11 +1,11 @@
-man1pages = gw/smppbox.1
-man5pages = gw/smppbox.5
+man1pages = gw/opensmppbox.1
+man5pages = gw/opensmppbox.5
docsrcs = $(wildcard grep -l '<!DOCTYPE ' doc/*.xml)
docs = $(docsrcs:.xml=.html) $(docsrcs:.xml=.rtf) $(docsrcs:.xml=.ps) $(docsrcs:.xml=.pdf)
-rpmtemp = /tmp/smppbox-rpm
+rpmtemp = /tmp/opensmppbox-rpm
DOCSTARGET=@DOCSTARGET@
DOCDRAFTS=@DOCDRAFTS@
-RPMPKG=smppbox-@PACKAGE_VERSION@
+RPMPKG=opensmppbox-@PACKAGE_VERSION@
pssrcs = $(wildcard doc/*.png)
ps = $(pssrcs:.png=.ps)
View
2  NEWS
@@ -1,3 +1,3 @@
-SmppBox Stand Alone Module
+OpenSMPPBox Stand Alone Module
Please read the ChangeLog file to see the latest changes.
View
8 README
@@ -1,13 +1,13 @@
OVERVIEW
========
-Smppbox is a special Kannel box that listens for smpp connections and accepts
+OpenSMPPBox is a special Kannel box that listens for smpp connections and accepts
and sends sms messages from and to smpp clients.
-Smppbox behaves similar to other Kannel boxes and share a compatible
+OpenSMPPBox behaves similar to other Kannel boxes and share a compatible
configuration file format and command line options.
-After starting smppbox, a new connection to bearerbox is made for each
+After starting opensmppbox, a new connection to bearerbox is made for each
smpp client that is connecting. This (new) connection with it's own
'smsbox-id' is dedicated to sending and receiving messages for this particular
smpp client.
@@ -26,7 +26,7 @@ And finally, as root:
make install
You need to have a development version of Kannel installed in order to compile
-smppbox.
+opensmppbox.
The Userguide has also valuable information about the install and configuration
steps. To create the userguide, run ./configure with --enable-docs and then
View
2  UPGRADE
@@ -1,4 +1,4 @@
2010/08/01
- From now on, open smppbox needs to be compiled with Kannel sources
+ From now on, opensmppbox needs to be compiled with Kannel sources
later than 2010/07/28 because the dlr_find function prototype
has been changed.
View
12 configure.in
@@ -54,7 +54,7 @@ dnl * Portions of this software are based upon software originally written at
dnl * WapIT Ltd., Helsinki, Finland for the Kannel project.
dnl */
-dnl Smppbox - Open Source Kannel Extension for store messages
+dnl OpenSMPPBox - Open Source Kannel Extension for store messages
dnl
dnl Rene Kluwen <rene dot kluwen at chimit dot nl>
dnl
@@ -67,8 +67,8 @@ dnl
AC_PREREQ(2.5)
dnl Initialization
-AC_INIT([smppbox],[svn],[devel@kannel.org])
-AC_CONFIG_SRCDIR([gw/smppbox.c])
+AC_INIT([opensmppbox],[svn],[devel@kannel.org])
+AC_CONFIG_SRCDIR([gw/opensmppbox.c])
AC_CONFIG_AUX_DIR(autotools)
AC_SUBST(SHELL)
@@ -85,12 +85,12 @@ if test "x$VERSION" = "xsvn"; then
AC_MSG_RESULT([$SVN_REVISION])
VERSION="$VERSION-r$SVN_REVISION"
fi
-AC_DEFINE_UNQUOTED(GW_NAME, "Smppbox", [ GW_NAME ])
+AC_DEFINE_UNQUOTED(GW_NAME, "OpenSMPPBox", [ GW_NAME ])
AC_DEFINE_UNQUOTED(GW_VERSION, "$VERSION", [ GW_VERSION ])
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [ VERSION ])
AC_SUBST(GW_VERSION)
AC_SUBST(VERSION)
-AC_CONFIG_SECTION([Configuring for smppbox version $VERSION])
+AC_CONFIG_SECTION([Configuring for opensmppbox version $VERSION])
dnl Checks for programs.
dnl AC_PROG_CC
@@ -587,6 +587,6 @@ AC_SUBST(rpm_suffix, "sdb", [RPM Suffix])
AC_SUBST(rpm_requires, "libsdb-devel >= 0.5", [RPM Requires])
])
-AC_CONFIG_FILES([Makefile gw/Makefile rpm/smppbox.spec])
+AC_CONFIG_FILES([Makefile gw/Makefile rpm/opensmppbox.spec])
AC_OUTPUT
View
144 doc/userguide.xml
@@ -14,7 +14,7 @@
<book>
<bookinfo>
- <title>Open smppbox &version; User's Guide</title>
+ <title>OpenSMPPBox &version; User's Guide</title>
<subtitle>Open Source SMPP proxy</subtitle>
<authorgroup>
@@ -22,7 +22,7 @@
<firstname>Rene</firstname>
<surname>Kluwen</surname>
<affiliation>
- <jobtitle>Open smppbox author</jobtitle>
+ <jobtitle>OpenSMPPBox author</jobtitle>
<orgname>Chimit Ltd.</orgname>
<address> <email>rene.kluwen@chimit.nl</email>
</address>
@@ -54,7 +54,7 @@
<abstract>
<title>Abstract</title>
<para>
- This document describes how to install and use SMPPBox, the Open
+ This document describes how to install and use OpenSMPPBox, the Open
Source SMPP proxy originally developed by Chimit Ltd. and now
being developed further by the open source community, namely the
Kannel Group.
@@ -74,7 +74,7 @@
<title>Introduction</title>
<para>This chapter introduces SMPP in general terms, and
- explains the role of SMPPBox in SMS flow, outlining its duties
+ explains the role of OpenSMPPBox in SMS flow, outlining its duties
and features.
</para>
@@ -175,10 +175,10 @@
</sect1>
<sect1>
- <title>SMPPBox overview</title>
+ <title>OpenSMPPBox overview</title>
<para>
- SMPPBox is an opensource SMPP proxy, which forwards GSM SMPP PDUs.
+ OpenSMPPBox is an opensource SMPP proxy, which forwards GSM SMPP PDUs.
It is not a pure proxy in the clear sense of the word, since it
is not limited to the SMPP protocol. It features an SMPP server port
for incoming ESME connections, but the client side uses the more
@@ -188,25 +188,25 @@
used for both MT &amp; MO SMS traffic.
</para>
<figure>
- <title>SMPPBox Layout </title>
+ <title>OpenSMPPBox Layout </title>
<graphic fileref="SMPPBox&figtype;"></graphic>
</figure>
<para>
- The ESME connects over SMPP to SMPPBox, thinking that it is an SMSc.
- Accounts are configured in SMPPBox to allow connections only from
+ The ESME connects over SMPP to OpenSMPPBox, thinking that it is an SMSc.
+ Accounts are configured in OpenSMPPBox to allow connections only from
specific clients. The SMS is forwarded to Bearerbox, which routes it
to the best available SMSc over a variety of protocols.
</para>
<para>
Meanwhile the SMSc will generate both final and intermediate delivery reports.
- These are routed back from Bearerbox to SMPPbox, which are then
- rewritten, as to appear that they originated from SMPPBox. These
+ These are routed back from Bearerbox to OpenSMPPbox, which are then
+ rewritten, as to appear that they originated from OpenSMPPBox. These
are finally routed back to the requesting ESME.
</para>
<para>
- SMPPbox presents a layer of abstraction to the ESME. The ESME
+ OpenSMPPBox presents a layer of abstraction to the ESME. The ESME
doesn't know the real SMScs used for SMS delivery. As far as it
- is concerned, it is dealing only with a single SMSc, SMPPBox. SMPPbox
+ is concerned, it is dealing only with a single SMSc, OpenSMPPBox. OpenSMPPBox
works like a black box in between your subscribers and Kannel.
</para>
</sect1>
@@ -214,7 +214,7 @@
<sect1>
<title>Features</title>
<para>
- SMPPBox provides for compliance to SMPP v3.3, SMPP v3.4 &amp; SMPPv5.0 for
+ OpenSMPPBox provides for compliance to SMPP v3.3, SMPP v3.4 &amp; SMPPv5.0 for
MT SMS routing over GSM. Options are limited by the features
provided by Bearerbox.
</para>
@@ -222,24 +222,24 @@
<para>
SMPP Users are defined in a flat text file, which is parsed at client
connection (binding) time. This means that users can be added, changed or
- removed without restarting open smppbox. The file can be edited by any plain-text
- file editor. Also it is possible to compile open smppbox with Unix PAM support
+ removed without restarting opensmppbox. The file can be edited by any plain-text
+ file editor. Also it is possible to compile opensmppbox with Unix PAM support
(pluggable authentication modules). See the corresponding options in the configuration
file.
</para>
<para>
It is possible to restrict ip addresses from which can be bound (connected)
- per user. See the section on configuring open smppbox below.
+ per user. See the section on configuring opensmppbox below.
</para>
<para>
- Special efforts have been made to make open smppbox v3.4 compatible by means of TLV
+ Special efforts have been made to make opensmppbox v3.4 compatible by means of TLV
(tagged length value) parameters. These parameters can be addressed via the meta-data
construction in Kannel. A special example of this: One can conditionally enable transmission
of short messages as a whole with length exceeding 140 octets, based on a meta-tag
"use_message_payload" in "smpp" group. In case this tag has been set and its value is not zero,
- open smppbox will attempt to use the "message_payload" TLV instead of splitting the message
+ opensmppbox will attempt to use the "message_payload" TLV instead of splitting the message
into multiple shorter ones with UDH-concatenation bit set. Note that this mechanism only
works for ESME's that declare support for SMPP versions 3.4 or greater. A simple usage example:
<ulink url="">http://localhost:13013/cgi-bin/sendsms?...&amp;meta-data=%3Fsmpp%3Fuse_message_payload%3D1</ulink>.
@@ -304,7 +304,7 @@
The source code is available from Kannel's site, through svn:
</para>
<para>
- <emphasis>svn co https://svn.kannel.org/smppbox/trunk</emphasis>
+ <emphasis>svn co https://svn.kannel.org/opensmppbox/trunk</emphasis>
</para>
<para>
Authentication is not needed.
@@ -314,7 +314,7 @@
<sect1>
<title>Finding the documentation</title>
- <para>SMPPBox documentation consists of two parts:
+ <para>OpenSMPPBox documentation consists of two parts:
<orderedlist>
<listitem><para><citetitle>User's Guide</citetitle>, namely the one
you're reading at the moment.</para></listitem>
@@ -330,7 +330,7 @@
</para>
<para>
- Everything you need to install and use SMPPBox is in <citetitle>User's Guide.</citetitle>
+ Everything you need to install and use OpenSMPPBox is in <citetitle>User's Guide.</citetitle>
The guide is still incomplete in this respect. The <filename>README</filename> is not
supposed to be very important, nor contain much information. Instead,
it will just point to the other documentation.
@@ -341,8 +341,8 @@
<sect1>
<title>Compiling the proxy</title>
- <para>If you are using SMPPBox on a supported platform, or one
- that is similar enough to one, compiling Smppbox should be trivial.
+ <para>If you are using OpenSMPPBox on a supported platform, or one
+ that is similar enough to one, compiling opensmppbox should be trivial.
After you have unpacked the source package of your choice,
or after you have checked out the source code from SVN, enter
the following commands:
@@ -354,7 +354,7 @@
The <filename>configure</filename> script investigates various
things on your computer compilation needs, and writes out the
- <filename>Makefile</filename> used to compile SMPPBox.
+ <filename>Makefile</filename> used to compile OpenSMPPBox.
<command>make</command> then runs the commands to actually
compile it. It generates the <filename>configure.log</filename>,
of all actions taken, usually the first step in debugging in case
@@ -396,7 +396,7 @@
<title>Installing the proxy</title>
<para>
- After you have compiled SMPPBox, you need to install
+ After you have compiled OpenSMPPBox, you need to install
certain programs in a suitable place. This is most easily
done by using <command>make</command> again:
@@ -407,7 +407,7 @@
Replace <replaceable>/path/to/directory</replaceable> with the
pathname of the actual directory where the programs should be
installed.
- Actually only a single program is installed <filename>smppbox</filename>.
+ Actually only a single program is installed <filename>opensmppbox</filename>.
The user that runs make install needs to have write permissions
do the bindir directory. It defaults to <filename>/usr/local/sbin</filename>.
@@ -420,8 +420,8 @@
<para>
After installation, you should now be able to run the Kannel init.d
script that will start the proxy. Run the script as root.
- For open smppbox we don't have a seperate init script, but versions of the
- Kannel init script are available that include starting open smppbox.
+ For opensmppbox we don't have a seperate init script, but versions of the
+ Kannel init script are available that include starting opensmppbox.
</para>
<screen><userinput>
@@ -438,7 +438,7 @@
</userinput></screen>
<para>
- If SMPPBox is already running and you just want to quickly
+ If OpenSMPPBox is already running and you just want to quickly
stop and start the gateway,e.g.to set a new configuration option,
run the script with the restart parameter.
</para>
@@ -450,21 +450,21 @@
</chapter>
<chapter>
- <title>Using SMPPBox</title>
+ <title>Using OpenSMPPBox</title>
<para>
- This chapter explains how the proxy, SMPPBox, is configured and used.
+ This chapter explains how the proxy, OpenSMPPBox, is configured and used.
It covers the configuration file and proxy administration during runtime.
</para>
<para>
- There is only one configuration file for all parts of SMPPBox. If
+ There is only one configuration file for all parts of OpenSMPPBox. If
several proxy instances are distributed among different hosts, each one
needs to have its own configuration file, with its own options.
</para>
<para>
- In bearerbox's status page you can see all connected open smppbox clients as different smsboxes.
- Note that the ip address that is listed on the status page of bearerbox is the one of open smppbox;
- not the client ip address of the open smppbox user.
+ In bearerbox's status page you can see all connected opensmppbox clients as different smsboxes.
+ Note that the ip address that is listed on the status page of bearerbox is the one of opensmppbox;
+ not the client ip address of the opensmppbox user.
</para>
<sect1>
@@ -497,17 +497,17 @@
<programlisting>
1 # Proxy configuration
-2 group = smppbox
+2 group = opensmppbox
3 bearerbox-host = 127.0.0.1
4 bearerbox-port = 13000
-6 smppbox-id = smppbox1
-7 smppbox-port = 13001
-8 log-file = /var/log/kannel/smppbox.log
+6 opensmppbox-id = smppbox1
+7 opensmppbox-port = 13001
+8 log-file = /var/log/kannel/opensmppbox.log
9 log-level = 0
10 our-system-id = Inaccess
11 route-to-smsc = fast_smsc
12 # New accounts
-13 smpp-logins = /etc/smppbox/clients
+13 smpp-logins = /etc/opensmppbox/clients
</programlisting>
</para>
@@ -571,30 +571,30 @@
statement :
<programlisting>
-# SMPPBox configuration
+# OpenSMPPBox configuration
-include = "/etc/smppbox/conf/smppbox1.conf"
+include = "/etc/opensmppbox/conf/opensmppbox1.conf"
</programlisting>
- Above is the main <literal>smppbox.conf</literal> configuration
- file that includes the following <literal>smppbox1.conf</literal>
+ Above is the main <literal>opensmppbox.conf</literal> configuration
+ file that includes the following <literal>opensmppbox1.conf</literal>
file with all required directives for the specific box, and a
<literal>configurations</literal> directory which may include
more files to include.
<programlisting>
-# smppbox1.conf
+# opensmppbox1.conf
-group = smppbox
+group = opensmppbox
bearerbox-host = 127.0.0.1
bearerbox-port = 13002
-smppbox-id = Dutch
-smppbox-port = 13003
-log-file = "/var/log/kannel/smppbox.log"
+opensmppbox-id = Dutch
+opensmppbox-port = 13003
+log-file = "/var/log/kannel/opensmppbox.log"
log-level = 1
our-system-id = Inaccess
route-to-smsc = cardboard
-smpp-logins = /etc/smppbox/clients
+smpp-logins = /etc/opensmppbox/clients
</programlisting>
@@ -615,21 +615,21 @@ smpp-logins = /etc/smppbox/clients
</sect2>
<sect2>
- <title>SMPPBox configuration</title>
+ <title>OpenSMPPBox configuration</title>
<para>
- SMPPBox configuration <emphasis>MUST</emphasis> always
+ OpenSMPPBox configuration <emphasis>MUST</emphasis> always
include a group for general proxy configuration. This group is
- named as 'smppbox' in configuration file. It doesn't matter if
+ named as 'opensmppbox' in configuration file. It doesn't matter if
this is the first or a later group in the configuration file.
</para>
- <para>In it's simplest form, 'smppbox' group looks like this:
+ <para>In it's simplest form, 'opensmppbox' group looks like this:
<programlisting>
-group = smppbox
+group = opensmppbox
our-system-id = Inaccess
-smpp-logins = /etc/smppbox/clients
+smpp-logins = /etc/opensmppbox/clients
</programlisting>
Naturally this is not sufficient for any real use. Thus, one or
@@ -641,7 +641,7 @@ smpp-logins = /etc/smppbox/clients
</para>
<table frame="none">
- <title>open smppbox Group Variables</title>
+ <title>opensmppbox Group Variables</title>
<tgroup cols="3">
<thead>
<row>
@@ -656,7 +656,7 @@ smpp-logins = /etc/smppbox/clients
<literal>group (m)</literal>
</entry>
<entry>
- <literal>smppbox</literal>
+ <literal>opensmppbox</literal>
</entry>
<entry valign="bottom">This is a mandatory variable</entry>
</row>
@@ -681,32 +681,32 @@ smpp-logins = /etc/smppbox/clients
</entry>
<entry valign="bottom">
TCP port that bearerbox is listening for incoming
- open smppbox connections. Should be the same as smsbox-port
+ opensmppbox connections. Should be the same as smsbox-port
configured in bearerbox. Defaults to 13001.
</entry>
</row>
<row>
<entry>
- <literal>smppbox-id (o)</literal>
+ <literal>opensmppbox-id (o)</literal>
</entry>
<entry>
<literal>string</literal>
</entry>
<entry valign="bottom">
- Optional open smppbox instance identifier. This is used for logging identification.
+ Optional opensmppbox instance identifier. This is used for logging identification.
</entry>
</row>
<row>
<entry>
- <literal>smppbox-port (o)</literal>
+ <literal>opensmppbox-port (o)</literal>
</entry>
<entry>
<literal>port number</literal>
</entry>
<entry valign="bottom">
- TCP port that open smppbox is listening for incoming ESME
+ TCP port that opensmppbox is listening for incoming ESME
connections. Defaults to 2345. If you want a different port
- number for each client, you will need to run a separate smppbox
+ number for each client, you will need to run a separate opensmppbox
instance for each port you are listening on.
</entry>
</row>
@@ -718,7 +718,7 @@ smpp-logins = /etc/smppbox/clients
<literal>filename</literal>
</entry>
<entry valign="bottom">
- Filename that open smppbox will log messages. If missing,
+ Filename that opensmppbox will log messages. If missing,
logging is disabled.
</entry>
</row>
@@ -768,7 +768,7 @@ smpp-logins = /etc/smppbox/clients
</entry>
<entry valign="bottom">
File that contains authentication credentials for clients
- connecting to open smppbox. This should be a file with a single
+ connecting to opensmppbox. This should be a file with a single
line per client, with username, password and system-type,
seperated by spaces. System-type is a special value. In
practice, you should have a different system-type for each
@@ -783,7 +783,7 @@ smpp-logins = /etc/smppbox/clients
<literal>boolean</literal>
</entry>
<entry valign="bottom">
- If set to true, this smppbox user is authenticating as smsbox
+ If set to true, this opensmppbox user is authenticating as smsbox
to bearerbox as the system-id value (first parameter in
smpplogins.txt). If set to false (which is the default) then
the smsbox-id is the same as system-type (third parameter in
@@ -802,9 +802,9 @@ smpp-logins = /etc/smppbox/clients
If set to true, then open smpp will use PAM authentication
besides the usual smpplogins.txt file. The smpplogins.txt
file takes precedence here. If there the user cannot be
- found there, open smppbox will try to use PAM authentication.
+ found there, opensmppbox will try to use PAM authentication.
use-systemid-as-smsboxid must be set to true if enable-pam
- is also true. For this to work, open smppbox must be compiled
+ is also true. For this to work, opensmppbox must be compiled
with pam-support (configure --enable-pam).
</entry>
</row>
@@ -860,7 +860,7 @@ smpp-logins = /etc/smppbox/clients
<row><entry><literal>timeout (o)</literal></entry>
<entry><literal>number</literal></entry>
<entry valign="bottom">
- The smpp connection gets dropped if open smppbox does not
+ The smpp connection gets dropped if opensmppbox does not
receive a valid pdu in this number of seconds.
(Defaults to 300).
</entry></row>
@@ -873,7 +873,7 @@ smpp-logins = /etc/smppbox/clients
<para>
The smpplogins.txt file, as set by the smpp-logins configuration
- variable defines all users that are able to bind as ESME to open smppbox.
+ variable defines all users that are able to bind as ESME to opensmppbox.
The first three tokens of this file are the username, password and
foreign system-type that form the credentials on which the bind-
method of the ESME are being matched with. The last token and defines a
View
14 example/smppbox.conf.example → example/opensmppbox.conf.example
@@ -1,23 +1,23 @@
-# sample smppbox.conf
+# sample opensmppbox.conf
group = core
dlr-storage = mysql
-# this group defines your smppbox
-group = smppbox
+# this group defines your opensmppbox
+group = opensmppbox
# our boxc type
-smppbox-id = abcd
+opensmppbox-id = abcd
# the port to listen on for smpp connections
-smppbox-port = 2346
+opensmppbox-port = 2346
# we connect to the following host as a box
bearerbox-host = localhost
bearerbox-port = 14009
log-level = 0
-log-file = smppbox.log
+log-file = opensmppbox.log
our-system-id = chim1
route-to-smsc = my-default-smsc
# see sample smpplogins.txt
-smpp-logins = "/home/smppbox/etc/smpplogins.txt"
+smpp-logins = "/home/opensmppbox/etc/smpplogins.txt"
# the following is just standard dlr configuration
View
4 gw/Makefile.am
@@ -1,4 +1,4 @@
-sbin_PROGRAMS = smppbox
-smppbox_SOURCES = smppbox.c
+sbin_PROGRAMS = opensmppbox
+opensmppbox_SOURCES = opensmppbox.c
EXTRA_DIST =
View
10 gw/smppbox-cfg.def → gw/opensmppbox-cfg.def
@@ -1,7 +1,7 @@
/* ====================================================================
* The Kannel Software License, Version 1.0
*
- * Copyright (c) 2001-2004 Kannel Group
+ * Copyright (c) 2001-2010 Kannel Group
* Copyright (c) 1998-2001 WapIT Ltd.
* All rights reserved.
*
@@ -55,17 +55,17 @@
*/
/* ==================================================================
- * Sqlbox-cfg.def - Definition of configuration groups and variables
+ * opensmppbox-cfg.def - Definition of configuration groups and variables
*
* Rene Kluwen rene.kluwen@chimit.nl
*
*/
-SINGLE_GROUP(smppbox,
+SINGLE_GROUP(opensmppbox,
OCTSTR(bearerbox-host)
OCTSTR(bearerbox-port)
- OCTSTR(smppbox-id)
- OCTSTR(smppbox-port)
+ OCTSTR(opensmppbox-id)
+ OCTSTR(opensmppbox-port)
OCTSTR(log-file)
OCTSTR(log-level)
OCTSTR(our-system-id)
View
68 gw/smppbox.c → gw/opensmppbox.c
@@ -1,7 +1,7 @@
/* ====================================================================
* The Kannel Software License, Version 1.0
*
- * Copyright (c) 2001-2004 Kannel Group
+ * Copyright (c) 2001-2010 Kannel Group
* Copyright (c) 1998-2001 WapIT Ltd.
* All rights reserved.
*
@@ -60,7 +60,7 @@
*/
/*
- * smppbox.c - main program of the smppbox
+ * opensmppbox.c - main program of the opensmppbox
*/
#include <errno.h>
@@ -148,7 +148,7 @@ typedef struct _boxc {
Dict *sent;
Semaphore *pending;
volatile sig_atomic_t alive;
- Octstr *boxc_id; /* identifies the connected smppbox instance */
+ Octstr *boxc_id; /* identifies the connected opensmppbox instance */
Octstr *sms_service;
Octstr *route_to_smsc;
Dict *msg_acks;
@@ -257,7 +257,7 @@ static int authenticate(const char *acl, const char *login, const char *passwd)
return 0;
}
pam_end(pamh, PAM_SUCCESS);
- info(0, "smppbox login by <%s>", login);
+ info(0, "opensmppbox login by <%s>", login);
return 1;
}
@@ -309,7 +309,7 @@ int check_login(Boxc *boxc, Octstr *system_id, Octstr *password, Octstr *system_
for (box = 0; box < gwlist_len(all_boxes); box++) {
thisbox = (Boxc *)gwlist_get(all_boxes, box);
if (octstr_compare(system_type, thisbox->boxc_id) == 0 && (thisbox->login_type == SMPP_LOGIN_TRANSCEIVER || (thisbox->login_type == login_type))) {
- debug("bb.sms.smpp", 0, "smppbox[%s]: Multiple login: disconnect.",
+ debug("bb.sms.smpp", 0, "opensmppbox[%s]: Multiple login: disconnect.",
octstr_get_cstr(thisbox->boxc_id));
thisbox->alive = 0;
#ifdef HAVE_SHUTDOWN_CONNECTION
@@ -335,7 +335,7 @@ int check_login(Boxc *boxc, Octstr *system_id, Octstr *password, Octstr *system_
/** This version does dump. */
#define dump_pdu(msg, id, pdu) \
do { \
- debug("smppbox", 0, "SMPP[%s]: %s", \
+ debug("opensmppbox", 0, "SMPP[%s]: %s", \
octstr_get_cstr(id), msg); \
smpp_pdu_dump(pdu); \
} while(0)
@@ -376,8 +376,8 @@ static long outstanding_requests(void)
}
/*
- * Identify ourself to bearerbox for smppbox-specific routing inside bearerbox.
- * Do this even while no smppbox-id is given to unlock the sender thread in
+ * Identify ourself to bearerbox for opensmppbox-specific routing inside bearerbox.
+ * Do this even while no opensmppbox-id is given to unlock the sender thread in
* bearerbox.
*/
static void identify_to_bearerbox(Boxc *conn)
@@ -446,7 +446,7 @@ Msg *catenate_msg(List *list, int total)
max++;
}
/* fail */
- debug("smppbox", 0, "re-assembling message failed.");
+ debug("opensmppbox", 0, "re-assembling message failed.");
msg_destroy(ret);
return NULL;
}
@@ -558,7 +558,7 @@ static int read_pdu(Boxc *box, Connection *conn, long *len, SMPP_PDU **pdu)
if (*len == 0) {
*len = smpp_pdu_read_len(conn);
if (*len == -1) {
- error(0, "smppbox[%s]: Server sent garbage, ignored.",
+ error(0, "opensmppbox[%s]: Server sent garbage, ignored.",
octstr_get_cstr(box->boxc_id));
return -1;
} else if (*len == 0) {
@@ -578,9 +578,9 @@ static int read_pdu(Boxc *box, Connection *conn, long *len, SMPP_PDU **pdu)
*pdu = smpp_pdu_unpack(box->boxc_id, os);
if (*pdu == NULL) {
- error(0, "smppbox[%s]: PDU unpacking failed.",
+ error(0, "opensmppbox[%s]: PDU unpacking failed.",
octstr_get_cstr(box->boxc_id));
- debug("bb.sms.smpp", 0, "smppbox[%s]: Failed PDU omitted.",
+ debug("bb.sms.smpp", 0, "opensmppbox[%s]: Failed PDU omitted.",
octstr_get_cstr(box->boxc_id));
/* octstr_dump(os, 0); */
octstr_destroy(os);
@@ -791,7 +791,7 @@ static List *msg_to_pdu(Boxc *box, Msg *msg)
octstr_destroy(gwlist_extract_first(parts));
if (gwlist_len(parts) > 0) {
while ((msgid2 = gwlist_extract_first(parts)) != NULL) {
- debug("smppbox", 0, "DLR for multipart message: sending %s.", octstr_get_cstr(msgid2));
+ debug("opensmppbox", 0, "DLR for multipart message: sending %s.", octstr_get_cstr(msgid2));
pdu2 = smpp_pdu_create(deliver_sm, counter_increase(box->smpp_pdu_counter));
pdu2->u.deliver_sm.esm_class = pdu->u.deliver_sm.esm_class;
pdu2->u.deliver_sm.source_addr_ton = pdu->u.deliver_sm.source_addr_ton;
@@ -1346,7 +1346,7 @@ void check_multipart(Boxc *box, Msg *msg, int *msg_to_send, Msg **msg2, List **p
/* We collect long messages as one and send them to bearerbox as a whole, so they can be sent
from the same smsc. */
(*msg_to_send) = 0;
- debug("smppbox", 0, "assemble multi-part message.");
+ debug("opensmppbox", 0, "assemble multi-part message.");
reference = octstr_get_char(msg->sms.udhdata, 3);
total = octstr_get_char(msg->sms.udhdata, 4);
key = octstr_format("%S-%i", msg->sms.receiver, reference);
@@ -1355,9 +1355,9 @@ void check_multipart(Boxc *box, Msg *msg, int *msg_to_send, Msg **msg2, List **p
(*parts_list) = gwlist_create();
dict_put(list_dict, key, (*parts_list));
}
- debug("smppbox", 0, "received %d of %d.", gwlist_len((*parts_list)) + 1, total);
+ debug("opensmppbox", 0, "received %d of %d.", gwlist_len((*parts_list)) + 1, total);
if ((gwlist_len((*parts_list)) + 1) == total) {
- debug("smppbox", 0, "received all parts of multi-part message.");
+ debug("opensmppbox", 0, "received all parts of multi-part message.");
gwlist_append((*parts_list), msg);
/* assemble message */
(*msg2) = catenate_msg((*parts_list), total);
@@ -1365,13 +1365,13 @@ void check_multipart(Boxc *box, Msg *msg, int *msg_to_send, Msg **msg2, List **p
octstr_destroy(key);
if (NULL == (*msg2)) {
/* we could not assemble an appropiate message */
- debug("smppbox", 0, "Invalid multi-part message.");
+ debug("opensmppbox", 0, "Invalid multi-part message.");
}
else {
(*msg2)->sms.smsc_id = box->route_to_smsc ? octstr_duplicate(box->route_to_smsc) : NULL;
(*msg2)->sms.boxc_id = octstr_duplicate(box->boxc_id);
- debug("smppbox", 0, "multi-part message, length: %d.", octstr_len((*msg2)->sms.msgdata));
+ debug("opensmppbox", 0, "multi-part message, length: %d.", octstr_len((*msg2)->sms.msgdata));
(*msg_to_send) = 1;
}
}
@@ -1763,7 +1763,7 @@ static void bearerbox_to_smpp(void *arg)
msg = read_from_box(box->bearerbox_connection, box);
if (msg == NULL) {
if ((!box->alive) || conn_eof(box->bearerbox_connection)) {
- /* tell smppbox to die */
+ /* tell opensmppbox to die */
/* the client closes the connection, after that die in receiver */
box->alive = 0;
}
@@ -1781,7 +1781,7 @@ static void bearerbox_to_smpp(void *arg)
}
if (msg_type(msg) == heartbeat) {
// todo
- debug("smppbox", 0, "bearerbox_to_smpp: catch an heartbeat - we are alive");
+ debug("opensmppbox", 0, "bearerbox_to_smpp: catch an heartbeat - we are alive");
msg_destroy(msg);
continue;
}
@@ -1812,19 +1812,19 @@ static void bearerbox_to_smpp(void *arg)
pdu->u.data_sm_resp.command_status = errcode;
break;
default:
- debug("smppbox", 0, "Getting failure ack on unexpected pdu: %i.", pdu->type);
+ debug("opensmppbox", 0, "Getting failure ack on unexpected pdu: %i.", pdu->type);
break;
}
break;
default:
- debug("smppbox", 0, "Unknown ack.nack type: %i.", msg->ack.nack);
+ debug("opensmppbox", 0, "Unknown ack.nack type: %i.", msg->ack.nack);
break;
}
send_pdu(box->smpp_connection, box->boxc_id, pdu);
dict_put(box->msg_acks, msgid, NULL); /* also destroys item */
}
else {
- debug("smppbox", 0, "Ack to unknown message: %s.", id);
+ debug("opensmppbox", 0, "Ack to unknown message: %s.", id);
}
octstr_destroy(msgid);
}
@@ -1949,7 +1949,7 @@ static void run_smppbox(void *arg)
newconn->bearerbox_connection = connect_to_bearerbox_real(bearerbox_host, bearerbox_port, bearerbox_port_ssl, NULL /* bb_our_host */);
/* XXX add our_host if required */
if (newconn->bearerbox_connection == NULL) {
- error(0, "smppbox: Failed to connect to bearerbox." );
+ error(0, "opensmppbox: Failed to connect to bearerbox." );
boxc_destroy(newconn);
return;
}
@@ -1960,7 +1960,7 @@ static void run_smppbox(void *arg)
/* we dont do heartbeats for now */
if (0 > heartbeat_start(write_to_bearerboxes, DEFAULT_HEARTBEAT,
outstanding_requests)) {
- info(0, "SMPPBox: Could not start heartbeat.");
+ info(0, "OpenSMPPBox: Could not start heartbeat.");
}
#endif
@@ -2017,7 +2017,7 @@ static void smppboxc_run(void *arg)
/* XXX add interface_name if required */
if (fd < 0) {
- panic(0, "Could not open smppbox port %d", port);
+ panic(0, "Could not open opensmppbox port %d", port);
}
/*
@@ -2125,12 +2125,12 @@ static void init_smppbox(Cfg *cfg)
/*
* first we take the port number in bearerbox and other values from the
- * smppbox group in configuration file
+ * opensmppbox group in configuration file
*/
- grp = cfg_get_single_group(cfg, octstr_imm("smppbox"));
+ grp = cfg_get_single_group(cfg, octstr_imm("opensmppbox"));
if (grp == NULL)
- panic(0, "No 'smppbox' group in configuration");
+ panic(0, "No 'opensmppbox' group in configuration");
bearerbox_host = cfg_get(grp, octstr_imm("bearerbox-host"));
if (!bearerbox_host) {
@@ -2145,7 +2145,7 @@ static void init_smppbox(Cfg *cfg)
#endif
#endif
- smppbox_id = cfg_get(grp, octstr_imm("smppbox-id"));
+ smppbox_id = cfg_get(grp, octstr_imm("opensmppbox-id"));
our_system_id = cfg_get(grp, octstr_imm("our-system-id"));
route_to_smsc = cfg_get(grp, octstr_imm("route-to-smsc"));
if (our_system_id == NULL) {
@@ -2157,7 +2157,7 @@ static void init_smppbox(Cfg *cfg)
cfg_get_integer(&lvl, grp, octstr_imm("log-level"));
- if (cfg_get_integer(&smppbox_port, grp, octstr_imm("smppbox-port")) == -1)
+ if (cfg_get_integer(&smppbox_port, grp, octstr_imm("opensmppbox-port")) == -1)
smppbox_port = 2345;
smpp_logins = cfg_get(grp, octstr_imm("smpp-logins"));
@@ -2249,7 +2249,7 @@ static int smppbox_is_allowed_in_group(Octstr *group, Octstr *variable)
fields \
return 0; \
}
- #include "smppbox-cfg.def"
+ #include "opensmppbox-cfg.def"
return 0;
}
@@ -2267,7 +2267,7 @@ static int smppbox_is_single_group(Octstr *query)
#define MULTI_GROUP(name, fields) \
if (octstr_compare(octstr_imm(#name), query) == 0) \
return 0;
- #include "smppbox-cfg.def"
+ #include "opensmppbox-cfg.def"
return 0;
}
@@ -2299,7 +2299,7 @@ int main(int argc, char **argv)
octstr_destroy(filename);
- version = octstr_format("smppbox version %s gwlib", GW_VERSION);
+ version = octstr_format("opensmppbox version %s gwlib", GW_VERSION);
report_versions(octstr_get_cstr(version));
octstr_destroy(version);
View
10 rpm/smppbox.spec.in → rpm/opensmppbox.spec.in
@@ -8,7 +8,7 @@ Release: %{release}
License: Kannel
Group: System Environment/Daemons
URL: http://www.kannel.org/~aguerrieri/
-Source0: smppbox-%{version}.tar.gz
+Source0: opensmppbox-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
BuildRequires: bison, byacc, flex
BuildRequires: kannel-devel, openssl-devel, zlib-devel
@@ -40,9 +40,9 @@ rm -rf %{buildroot}
%{__mkdir_p} %{buildroot}%{_var}/log/kannel/
%{__mkdir_p} %{buildroot}%{_var}/spool/kannel/
-%{__install} -D -m 0640 example/smppbox.conf.example %{buildroot}%{_sysconfdir}/kannel/smppbox.conf
+%{__install} -D -m 0640 example/opensmppbox.conf.example %{buildroot}%{_sysconfdir}/kannel/opensmppbox.conf
-strip %{buildroot}%{_sbindir}/smppbox
+strip %{buildroot}%{_sbindir}/opensmppbox
%clean
%{__rm} -rf %{buildroot}
@@ -59,7 +59,7 @@ strip %{buildroot}%{_sbindir}/smppbox
%files
%defattr(-, root, root, 0755)
%doc AUTHORS COPYING ChangeLog NEWS README UPGRADE
-%attr(0640, kannel, kannel) %config(noreplace) %{_sysconfdir}/kannel/smppbox.conf
+%attr(0640, kannel, kannel) %config(noreplace) %{_sysconfdir}/kannel/opensmppbox.conf
%{_sbindir}/*
%attr(0750, kannel, kannel) %dir %{_var}/log/kannel/
%attr(0750, kannel, kannel) %dir %{_sysconfdir}/kannel/
@@ -67,4 +67,4 @@ strip %{buildroot}%{_sbindir}/smppbox
%changelog
* Mon Jun 07 2010 Rene Kluwen <rene.kluwen@chimit.nl>
-- First RPM version for Smppbox
+- First RPM version for OpenSMPPBox
Please sign in to comment.
Something went wrong with that request. Please try again.