Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 885aaaada7
8667 lines (5529 sloc) 289.128 kb
2000-12-13 Richard Braakman <>
* Making release 0.13.1.
2000-12-13 Richard Braakman <>
* Updated NEWS file. Compare 0.13 with 0.12 series instead of
with 0.11 series, on the assumption that people who use development
versions will still read the release notes for stable versions.
* Documented --with-malloc=slow.
2000-12-11 Aarno Syvänen <>
* wap/wsp_unit.c: Added handling of S_Unit_Push.req
2000-12-11 Richard Braakman <>
* gw/smsc_smpp.c: Made smpp_reopen() work, and not crash.
Made it not destroy the smsc structure when it fails, because
that's not part of the interface.
* gw/smsc.c: Made smsc_reopen() also lock the smsc structure.
* gwlib/socket.c: In read_available(), pass the actual value of
the largest fd used to select, rather than FD_SETSIZE.
* gw/urltrans.c: encode_for_url returns an Octstr, but callers
treated it as char *. Fixed that.
Free URLTranslation->keyword with octstr_destroy, not gw_free.
* gw/smsc_smpp.c: Removed unused lists sent_mt and delivered_mt.
2000-12-11 Lars Wirzenius <>
* gwlib/octstr.c: octstr_format(): Implement %% in format strings.
2000-12-08 Aarno Syväen <>
* wap/wsp_push_client.c, wap/wap_events.def: Really resolve
a conflict.
2000-12-09 Lars Wirzenius <>
* wap/wsp_push_client.c, wap/wsp_push_client_states.def,
wap/wsp_server_push_states.def, wap/wsp_session.c: Commented
things out so that things will at least compile and pass "make
check". I assume Aarno forgot to add one or two files or other
changes when he committed and that things do compile in *his*
work directory.
2000-12-08 Aarno Syvänen <>
* wap/server_push_machine.def, wsp_server_push_states.def: Two new
modules to handle wsp push.
* gw/wap_push_ota.c|h: These files are used, for now, only for
* wap/wap_events.def: For TR-Abort.ind, added the field ir_flag. This
tells are the indicator responder or initiator and TR-Invoke.cnf,
added field addr_tuple, which tells the session to which the event
should be sent.
* wap/wtp.h: More readable strings instead of magic numbers.
* wap/wsp_push_client.c: Added calls to disconnect and suspend a
session. Combined indications and dispatching. Separate abort
functions for the initiator and the responder.
* wap/wsp.h: Added definition of server push machine.
* wap/wsp_server_session_machine.def: Added list for push machines.
* wap/wsp_session.c: Added statics to handle wsp push. In function
find_session_machine, added handling of push events. Destroying both
method and push machines.
* wap/wtp_init.c, wap/wtp_resp.c: Assign values of new flags.
* wap/wap.h: Added a new interface function wap_push_ota_dispatch_
* wap/wsp_push_client_machine.def: Added session_id.
2000-12-08 Richard Braakman <>
* gw/bb_smsc.c, function sms_receiver: Made the increase in sleep
times much slower (multiply by 2 instead of by 100). This avoids
having the bearerbox sleep a whole second just because the SMSC
took longer than 0.01 seconds. This scenario is pretty common
on dialup links.
2000-12-07 Lars Wirzenius <>
* contrib/{fortune.cgi,ping.cgi,sendsms,smstomail.cgi}: Added
some sample services that can be used with Kannel. They're
unlikely to be useful in real life, but might be amusing to test.
2000-12-07 Lars Wirzenius <>
* gw/smskannel.conf: Removed the "www" example service, since
people seem not to remove it from production installations.
They should, since it's potentially a security problem.
2000-12-06 Richard Braakman <>
* gw/wapbox.c: Memory cleanup: Call close_connection_to_bearerbox()
when exiting, and destroy the bearerbox_host string.
2000-12-06 Lars Wirzenius <>
* gw/smsbox.c: Removed compilation warning about `catref' being
possibly used without initialization in send_message. While doing
this, fixed some formatting (long lines, comment style), frivolous
argument order changes, and renamed catref to msg_sequence,
so as to use the same name everywhere.
Also removed the commented-out part that disabled catenation
on messages with UDH. It was enabled since the code before the
rewrite didn't seem to deal with this case properly, and I hadn't
time to find out the correct way to handle this.
2000-12-06 Richard Braakman <>
* Not Finnish and not independent. (Ruled by a queen)
* Applied Mikael Gueck's cleanup patch for SMPP.
* gw/smsc_smpp.c: Fixed memory leak in data_receive(), spotted
by Milko Videv.
* gw/smsc_smpp.c: Fixed minor compiler warnings, deleted unused
functions charset_smpp_to_iso(), charset_iso_to_smpp(), and
* gw/smsc_smpp.h: Deleted declarations of unused functions.
Deleted translation_table (no longer used)
2000-12-06 Yann Muller <>
* gw/smsbox.c: Corrected reference number for concatenation UDH,
recalculate UDH length after adding concatenation info and adjust
if UDH was empty. Commented out reset of 'catenate' if UDH is
already present.
* gw/smsc_at.c: fixed the length of the user data in pdu_encode().
2000-12-05 Lars Wirzenius <>
* gw/wapbox.c: Converted to use bearerbox communication stuff
from gw/shared.c (and therefore Connection) instead of using
old plain socket stuff. Among other things, this kills one thread
* gw/shared.c: Check for write errors and don't report messages
that were sent.
* checks/ Set log level to 0 and shorten sleeps
between box startups.
* gw/smsbox.c: Don't use \0 in format string, use %c and argument
0 instead. \0 has a tendency to cut C strings short...
2000-12-05 Lars Wirzenius <>
* gw/shared.[ch]: Moved bearerbox communication stuff from
smsbox.c to shared.c, so that it can easily be used by wapbox
as well.
* gw/smsbox.c: Related changes.
* gw/wapbox.c: Renamed "running" to "running_ok", until the
wapbox will use program_status from shared.c.
2000-12-05 Lars Wirzenius <>
* gw/smsc.c: Removed calls to str_find_substr.
* gwlib/utils.[ch]: Removed now-unused str_find_substr function.
2000-12-05 Lars Wirzenius <>
* gw/urltrans.[ch]: Removed urltrans_accepted_smsc(), since
it wasn't being used. Made the accepted SMSC list in an
URLTranslation be a List. This allows us to kill one more call
to str_find_substr.
* gwlib/octstr.[ch]: Wrote octstr_item_match.
2000-12-05 Lars Wirzenius <>
* gwlib/octstr.[ch]: Wrote octstr_split.
* gw/urltrans.c: Use a Dict to look up the URLTranslation,
instead of a linear search from the whole list. This is somewhat
faster and results in cleaner code.
2000-12-05 Lars Wirzenius <>
* gwlib/gwstr.[ch], gwlib/conffile.c: Moved trim_ends to
conffile.c, and the other functions were no longer used, so
removed the gwstr module.
* gwlib/gwlib.h, gwlib/socket.h: Removed include for gwstr.h.
2000-12-04 Lars Wirzenius <>
* gw/urltrans.c: Made urltrans_get_pattern return an Octstr, instead
of a C string.
* gw/smsbox.c: Related changes.
2000-12-04 Lars Wirzenius <>
* gw/urltrans.[ch]: Change function call interfaces to use Octstr
instead of C strings.
* gw/smsbox.c: Related changes.
* gw/smsbox.c: When checking whether sendsms is allowed, call
is_allowed_ip properly, with deny_ip, not instead of allow_ip.
2000-12-04 Lars Wirzenius <>
* gw/urltrans.[ch]: Reformatted for new coding style.
2000-12-04 Lars Wirzenius <>
* gw/smsbox.c: Fixed the PAM code to use warning and error,
instead of printf.
2000-12-04 Lars Wirzenius <>
* gw/smsbox.c: Reformatted the PAM code. Hopefully it still works.
2000-12-04 Lars Wirzenius <>
* gw/smsbox.c: Rearranged code for clarity, plugged a memory leak
and fixed a memory freeing bug (memory was being freed twice).
2000-12-04 Lars Wirzenius <>
* gw/smsbox.c: Merged smsbox_req.c into smsbox.c, because they
called each other backwards and forwards and the merged file is
small enough to be manageable, so there's no point in keeping
them separate.
* gw/smsbox.h, gw/smsbox_req.[ch]: Removed.
2000-12-04 Lars Wirzenius <>
* gw/smsbox_req.c: Rearranged code to be somewhat clearer.
* gw/smsbox.c: Removed ancient file comment.
2000-12-04 Lars Wirzenius <>
* gw/smsbox_req.c: Rewrote SMS splitting so that it is hopefully
now somewhat more understandable.
2000-12-04 Lars Wirzenius <>
* gw/smsc_emi.c: Avoid NULL pointer dereference if sender has
not been set. Thanks to Armin Hurm for finding this.
2000-12-04 Lars Wirzenius <>
* doc/userguide/userguide.xml: Explain the syslog-level variable
for wabpox.
2000-12-04 Lars Wirzenius <>
* README: Moved information from doc/platforms/FAQ.solaris to
README, because the goal is to reduce the number of places one
has to look for documentation, not increase it. Whoever put the
file in CVS didn't even document it in the ChangeLog.
* doc/platforms/FAQ.solaris: Removed.
2000-12-01 Richard Braakman <>
* gw/heartbeat.c: Fix busy-loop in heartbeat thread.
2000-12-01 Lars Wirzenius <>
* contrib/php-admin/*: Added PHP administration stuff and
sendota/sendvcard/etc stuff from Bjarne Saltbaek.
2000-12-01 Lars Wirzenius <>
* Accept libxml 2.2.10. (Untested, since I don't
have 2.2.10 yet.)
2000-11-29 Richard Braakman <>
* wap/wap_events.*: Gave events pretty names, for logging.
("TR-Invoke.cnf" instead of "TR_Invoke_Cnf").
2000-11-29 Richard Braakman <>
* wap/wap_events.def, wap/wsp_push_client.c,
wap/wsp_push_client_states.def: Brought Push-related events in
line with the scheme used by other WSP events.
2000-11-29 Richard Braakman <>
* gwlib/gwpoll.h, gwlib/gwthread-pthread.h: FreeBSD compatibility
fix. Specify "no timeout" on poll by using INFTIM, if it's
available, rather than using a random negative value.
2000-11-29 Aarno Syvänen <>
*wap/wsp_push_client_states.def: Changed names of dispatching
functions to locally used ones.
2000-11-29 Yann Muller <>
* gw/smsc_at.c: removed the UDHL from the encoding of the PDU.
The length should already be in the UDH.
2000-11-28 Richard Braakman <>
* wap/wsp_session.c, wap/wsp_server_session_states.def,
wap/wsp_server_method_states.def: Renamed static functions
so that they do not start with "wsp_", to avoid confusion.
(In the future the client side will have its own versions
of these, and names with wsp_ look like they are global.)
2000-11-28 Richard Braakman <>
* wap/wap_events.def: Added WSP client-side events (not used yet).
* Renamed "session_id" to "session_handle" for WSP session events
that are used by both client and server side. The client side does
not know the session id until after it is connected, so it can not
use that as a handle.
* Made "method" an OCTSTR field instead of INTEGER. Now the
application layer need no longer worry about method encoding
values. This is a first step toward supporting extended methods,
which have no fixed number.
* Renamed S_MethodInvoke_Ind fields to be closer to the spec.
* Introduced OPTIONAL_OCTSTR, and require that OCTSTR and
ADDRTUPLE fields never be NULL. wap_event_assert now checks this.
All uses have been checked to see if they can deal with this,
and some have been adjusted.
* wap/wap_events.def: Formalized distinction between fields in
the spec and fields added by Kannel.
* wap/wsp_push_client.c: In push_client_machine_find_or_create,
add default case to handle unexpected event types, and always
destroy "pdu" variable (to avoid gcc warnings).
* wap/wsp_push_client.h: Define INTEGER fields as long, just like
everywhere else.
2000-11-28 Lars Wirzenius <>
* gw/smsbox.[ch], gw/smsbox_req.[ch]: Call function to write
message to bearerbox directly, instead of via function pointer.
2000-11-28 Kalle Marjola <>
* gw/smsbox_req.c: fixed that sendsms user is again shown (it
disappeared during some authorization work, I guess)
* gw/urltrans.c|h: added function urltrans_username
2000-11-28 Aarno Syvänen <>
* gw/wapbox.c: Initialize and shutdown the push client.
2000-11-28 Aarno Syvänen <>
* wap/wsp_push_client*: Added client push machine. Wtp responder
will send class 1 transaction messages to this as long as wsp client
session machine is not implemented.
* wap/wap_events.def: Added some push events
* wap/wap.h, wtp_resp.c, wtp_resp_states.def: Sending events from
wtp responder to push client implemented.
2000-11-28 Lars Wirzenius <>
* gwlib/log.[ch]: Added a log_ prefix to functions, except for
the actual message printing ones. Those are used in too many
places to warrant a change.
* checks/check_*.c, gw/bearerbox.c, gw/smsbox.c, gw/wapbox.c,
gwlib/utils.c, test/drive_wapbox.c, test/test_http.c,
test/test_http_server.c, test/wml_tester.c: Related changes.
2000-11-28 Lars Wirzenius <>
* gw/smsbox_req.c: Deal with failed requests in the proper manner,
which does not include segfaulting.
2000-11-28 Lars Wirzenius <>
* checks/ Wait a couple of seconds before making
http requests so that the smsbox has time to start up properly.
* gw/html.c: Moved the html prefix and suffix stripping function
into smsbox_req.c, since it doesn't really do anything with html,
just octstrs. Cleaned up url_result_thread slightly.
2000-11-28 Lars Wirzenius <>
* gw/smsbox_req.c: Accept WML responses as well as plain text
and HTML responses.
2000-11-28 Paul Keogh <>
* gwlib/gwmem-check.c: Removed compiler warning of
"gwmem-check.c(370) : unary minus operator applied to unsigned type,
result still unsigned."
2000-11-27 Lars Wirzenius <>
* gw/smsbox_req.c: Made obey_request return an Octstr, instead
of a C string.
2000-11-27 Lars Wirzenius <>
* gw/smsbox_req.c: Formatted to follow coding style.
2000-11-27 Lars Wirzenius <>
* gw/smsbox.c, gw/smsbox_req.c: Changed the thread structure for
smsbox so that threads are not created dynamically for each new
message, but instead threads are created at startup and messages
are passed around between then via queues.
* gw/urltrans.c: Fixed memory leak by remembering to destroy
the deny_ip string as well.
2000-11-27 Kalle Marjola <>
* doc/userguide/userguide.xml: corrected explanation of smsc-id
in sendsms interface chapter
2000-11-24 Richard Braakman <>
* Added Suspend/Resume support. (Not well tested yet)
* wap/wsp_pdu.def: Note that the capabilities field in a Resume
PDU is reserved.
* wap/wsp_server_method_states.def: Explain why we don't
decrement N_Methods.
2000-11-24 Kalle Marjola <>
* gw/smsc.c: oops, did fix to wrong place, silly me
2000-11-24 Lars Wirzenius <>
* gwlib/gwmem-check.c: Add casts to avoid comparing pointers
and integers.
2000-11-24 Richard Braakman <>
* gw/heartbeat.[ch]: New files, contain heartbeat code shared
between wapbox and smsbox.
* gw/wapbox.c, gw/smsbox.c: Use shared heartbeat code.
* gw/smsbox.c: Use Connection for the link with the bearer box.
Made bb_host an Octstr.
* gw/smsbox_req.c: write_msg() cannot fail, so don't check
return codes.
* gwlib/conn.c: Memory leak debugging: all callers of unlocked_get
claim the result as theirs.
* gwlib/http.c: Fix memory leak in read_chunked_body_crlf().
*, Added --with-malloc=slow, which does
a more careful (but much slower) check in find_area(). This can
sometimes report problems that would otherwise cause a segfault.
* gwlib/gwmem.h, gwlib/gwmem-check.c: Implement --with-malloc=slow.
Also do the careful check if the pointer looks like one of our
standard fill patterns.
* gwlib/octstr.c: Added seems_valid() call in octstr_dump().
* gwlib/http.c: Get rid of clients_in_fdset list. This removes
a race condition that would cause occasional segmentation faults,
but leaves us with some "memory leaks". (They aren't really,
but are reported as such.)
* gw/smsc_emi.c: Converted previous patch to our coding style
wrt parenthesis usage. emi_open_session: Added missing final
return. emi_fill_ucp60_login: Made ia5passwd dynamically
allocated, since variable-length arrays are not standard C.
2000-11-24 Kalle Marjola <>
* gw/smsc.c, gw/smsc_emi.c: applied authentication patch by Joerg
2000-11-23 Richard Braakman <>
* wap/wsp.h, wsp/wsp_headers.c, wap/wsp_session.c:
Changed some "XXX" comments.
* wap/wsp_pdu.h, wap/wsp_server_method_states.def, wap/wsp_unit.c:
Introduced GET_METHODS and POST_METHODS identifiers to avoid using
0x40 and 0x60 as magic numbers.
2000-11-23 Yann Muller <>
* gw/smsc_at.c: reverted default GSM alphabet patch and added
call to charset_latin1_to_gsm().
2000-11-23 Richard Braakman <>
* gw/smsbox.c: Moved http_proxy_ variables into init_smsbox, since
they are used only there. Made http_proxy_host an Octstr.
* gw/smsbox.c: Wait for http_request_thread to terminate, when
shutting down the box.
* gw/smsbox_req.[ch], gw/smsbox.c: Added smsbox_req_shutdown(),
so that it can clean up its copy of global_sender.
2000-11-23 Lars Wirzenius <>
* gwlib/http.c: Deal with HTTP version numbers above 1.1 also
on the server side. Use a single function for the checking that
is used by both the client and server.
2000-11-23 Richard Braakman <>
* wap/wtp_init.c, wap/wtp_init_states.def, wap/wtp_resp.c,
wap/wtp_resp_states.def: Added static send_abort() and
send_ack() functions, to simplify the state machine
2000-11-23 Kalle Marjola <>
* doc/userguide/userguide.xml: some corrections to just written
2000-11-23 Richard Braakman <>
* gw/smsc_at.c, gw/smsbox_req.c: Replaced some strcpys with
pointer assignments.
* doc/userguide/userguide.xml: Replaced an & with &amp; so that
it compiles.
* checks/ Reduced sleep after starting bearerbox,
because it starts up faster now. Added "sleep 5" before killing
bearerbox, because smsbox segfaults if it's still busy when the
bearerbox goes away.
2000-11-23 Yann Muller <>
* doc/userguide/userguide.xml: Added Stipe Tolj's explanations
for multiple OTA configs.
2000-11-23 Kalle Marjola <>
* doc/userguide/userguide.xml: Added some explanation of SMS and
what is an SMS gateway - might need editing, but neverthless there
is some text
* doc/userguide/sms-gateway.fig: New picture to support that
2000-11-22 Richard Braakman <>
* gw/smsc.c, gw/smsc_cimd.c: Reformatted.
2000-11-22 Lars Wirzenius <>
* test/drive_wapbox.c: Killed a memory leak by destroying a
temporary octet string.
* gwlib/gwmem-check.c: When dumping allocated areas, dump the
first few bytes of the area.
* gwlib/http.c: Destroy HTTPClients before destroying the fdset.
2000-11-22 Kalle Marjola <>
* doc/userguide/userguide.xml: Moved some explanations to correct
places, to avoid mixed up context
2000-11-22 Richard Braakman <>
* gwlib/fdset.c: When destroying an fdset with active fd's,
close them first and signal that event.
2000-11-22 Lars Wirzenius <>
* doc/userguide/userguide.xml: Add notes about HTTP proxy username
and password.
2000-11-21 Richard Braakman <>
* wmlscript/wserror.c, wmlscript/wslexer.c:
Fixed some assertions with side effects.
2000-11-21 Richard Braakman <>
* gw/html.c, convert_html_entity(): Made conversion of entities
like &#1234; work.
2000-11-21 Richard Braakman <>
* gw/html.c, gw/msg.c: Reformatted.
2000-11-21 Richard Braakman <>
* gw/cgi.[ch]: Removed, they are no longer used.
* gw/smsbox.c, gw/smsbox_req.[ch]: Removed inclusion of cgi.h.
2000-11-21 Richard Braakman <>
* gwlib/gwthread-pthread.c, gwlib/conn.c, gwlib/list.c,
gwlib/utils.c (roundup_div): Formatted according to our coding style.
All of gwlib/ is now converted.
2000-11-21 Lars Wirzenius <>
* gwlib/http.c: Made persistent connection detection work with
HTTP/1.0 responses and responses with the "Connection: close"
header. Also removed an extra "Using proxy" report.
* ChangeLog: Indented the first line of the previous log entry
properly. (8, not 4)
2000-11-21 Yann Muller <>
* gwlib/utils.[ch], gw/smsbox_req.c: moved roundup_div() from
smsbox_req.c to utils.c so it can be used from other files.
* gw/smsc_at.c: fix for 7 bit encoded PDU's with a UDH.
* gw/smsbox_req.c: maxdatalength fix in do_split_send().
2000-11-21 Lars Wirzenius <>
* checsk/ Sleep before starting background
processes, so that the previous ones have time to start up
* ChangeLog: Indented the previous log entry properly. (8, not 4)
2000-11-21 Yann Muller <>
* gw/smsbox_req.c: sendota patched (Stipe Tolj) to accept more
that one OTA configuration.
2000-11-20 Richard Braakman <>
* Turned WTP and WSP protocol stacks into a library. Source
files moved to a directory called "wap", which generates libwap.a.
The interface to this library is specified in wap/wap.h.
The application layer remains in gw/.
* In WAPAddrTuple, rename "client" and "server" to "remote"
and "local", to prevent confusion in client-side code.
* While moving files to wap/, renamed declaration files to
".def", and made filenames use _ instead of - as separator.
Also put "server" in the name of some WSP files, to make
room for future "client" files.
* Sanitized header files that include other header files.
Now each header only includes what it needs.
* Layers can be started independently, and use configurable
dispatch functions.
* wap/timers.c, wap/wsp_strings.c: Allow nested initializations
and shutdowns, because layers that use them can be started
* WTP layer now uses datagram events instead of Msg structures
for its lower level.
* wtp_send.c converted to wtp_pack.c, because it no longer
does its own sending.
* wtp_tid.c uses WAPAddrTuple instead of its own structure.
* gw/wap-appl.c, gw/wapbox.c: Use the new interface.
2000-11-20 Lars Wirzenius <>
* gwlib/dict.c: Avoid an extra list_search if we know the
list was empty.
2000-11-20 Richard Braakman <>
* Making release 0.13.
2000-11-20 Richard Braakman <>
* gwlib/dict.c: Made it initialize empty table entries with
NULL instead of empty lists, to save memory.
* gwlib/http.c: Fix memory leak in send_request() when retrying
a request.
* gwlib/http.c: Make sure that a retried request really gets
a _new_ connection. Otherwise it could be rejected just because
two connections have timed out.
2000-11-19 Derry Hamilton <>
* solaris/prototype: Updated the prototype to reflect the newer
install style.
2000-11-17 Kalle Marjola <>
* gw/bb_smsc.c (sms_receiver): usleep limit to avoid portability
problems, patch by Jarkko Oikarinen
2000-11-16 Richard Braakman <>
* gwlib/http.c: Responses with status 1xx, 204, or 304 are
defined as having no message body, so don't expect one.
2000-11-16 Richard Braakman <>
* gwlib/http.c: Removed calls to conn_unregister that were followed
by calls to conn_destroy. It's redundant, and in one case the
connection might be NULL.
* gwlib/conn.c: Add some conn != NULL assertions.
2000-11-16 Yann Muller <>
* gw/smsc_at.c: In function at_open_connection() added parity
line for this modem type. In function at_open() adding sleep
period only for this modem type, may be expanded. In function
pdu_extract() changed skipping of 00 sequence for the specific
modem types. (patch by Stipe Tolj)
2000-11-15 Richard Braakman <>
* gw/wsp-session.c: Address tuples are now included in events
sent from WTP to WSP, so the code for looking up tuples based
on WTP handles is no longer needed.
* gw/wtp_resp.[ch]: Removed now-unused functions
wtp_resp_get_address_tuple, find_resp_machine_using_mid,
and resp_machine_has_mid.
2000-11-15 Kalle Marjola <>
* gw/bb_boxc.c: added wapbox load based balancing, based on
ofiginal patch by Rishi Lal and Priya Patil
2000-11-15 Kalle Marjola <>
* gw/smsc_wrapper.c, gw/smscconn_p.h: Added.
* gw/smscconn.c: moved wrapping stuff into smsc_wrapper.c, and
private structure data into private header smscconn_p.h so that
caller (main bearerbox) does not need to worry about that
2000-11-14 Richard Braakman <>
* doc/CodingStyle: Document our practice of having include files
include other files.
2000-11-14 Lars Wirzenius <>
* gwlib/http.c: Simplified code a bit by combining the two
different states (reading_body and reading various parts of a
chunked body) into one.
2000-11-14 Lars Wirzenius <>
* gwlib/http.c: Implemented, I hope, proxy_add_authentication(),
but I can't test it, since I don't have a proxy that requires
authentication. If it doesn't work, hopefully people will tell me.
2000-11-14 Lars Wirzenius <>
* gwlib/http.[ch]: Wrote function http_add_basic_auth.
* test/test_http.c: Added code to optionally use Basic Auth
with requests.
2000-11-14 Lars Wirzenius <>
* gwlib/http.c: Report when connections to servers are opened
and when a proxy is being used (via debug).
* test/test_http.c: More informative output with -h.
2000-11-14 Yann Muller <>
* gw/smsc_at.c: phone numbers starting with '+' or '00' are
coded as international numbers, others are left with the
default (Unknown).
2000-11-13 Lars Wirzenius <>
* gw/smsbox.c, gw/wapbox.c, gwlib/http.[ch], test/test_http.c:
Changed the HTTP proxy configuration interface so that the access
to the proxy can be authenticated. The actual implementation
is still lacking, but the interface changed to http_use_proxy()
is done.
2000-11-13 Lars Wirzenius <>
* Use $(DESTDIR) in the install targets.
2000-11-13 Richard Braakman <>
*, config.h, gwlib/gwassert.h: Use NO_GWASSERT
instead of NDEBUG. Have gwassert.h define NO_GWASSERT if
NDEBUG is defined.
* gw/smsc_cimd2.c, gwlib/conn.c, gwlib/gwlib.h, gwlib/octstr.c:
Use NO_GWASSERT instead of NDEBUG.
2000-11-10 Lars Wirzenius <>
* gwlib/http.c: Implemented persistent connections on the
client end.
2000-11-10 Richard Braakman <>
* gwlib/gwlib.c: Call gwlib_protected_shutdown() last, because
the protected functions are used by other shutdown functions.
Thanks to Paul Keogh for pointing this out.
* gwlib/gwmem.h, gwlib/gwmem-check.c, gwlib/gwlib.c:
Added gwmem_shutdown() function, to be called after
gw_check_leaks(). This makes it possible to check for
leaks without shutting down.
* doc/userguide/userguide.xml: Document the configure options
added below.
2000-11-10 Lars Wirzenius <>
* gwlib/http.c: Implemented persistent connections on the
server end.
2000-11-10 Richard Braakman <>
* Added --with-defaults to make it possible to
configure for speed or for debugging, with one option.
Added --disable-assertions to set NDEBUG. Made --with-malloc
and --disable-assertions use the default set by --with-defaults.
Changed some whitespace to make ./configure --help align nicely.
* Added NDEBUG option
* gwlib/gwthread-pthread.c: Include "gwlib/gwlib.h", not
<gwlib/gwlib.h>. The latter made "make depend" skip the
inclusion. This fixes the problem of needing to run
"make clean" after switching malloc wrappers.
* gwlib/thread.[ch]: Remove mutex_try_lock(). It's not longer
used, and it had portability issues.
* gwlib/conn.c: If conn_set_output_buffering is called, react
to the new buffer size immediately.
* gwlib/conn.[ch]: Remove conn_wait_multi(). It's not used
and will not be needed by the new HTTP design.
* gwlib/conn.c: Fix conn_flush to conform to its description
and to manage its lock right.
* gwlib/conn.c: Make unbuffered connections the default.
2000-11-10 Kalle Marjola <>
* gw/smscconn.h|c: Added. New SMSC connection interface with stub
of upcoming connection module (and wrapper for old system)
2000-11-10 Lars Wirzenius <>
* gwlib/http.[ch]: Killed http_get and http_post, since they're
now obsolete and unused. http_get_real remains until numhash.c
and smsbox_req.c are converted.
2000-11-10 Lars Wirzenius <>
* gw/wap-appl.c: Reformatted.
2000-11-10 Lars Wirzenius <>
* gw/wap-appl.c: Changed thread structure so that there is a
static number of thread regardless of how many requests are
made. This should make things a bit faster when the load is heavy.
* gwlib/http.[ch]: Wrote function http_client_signal_shutdown,
to allow the wapbox to shutdown.
2000-11-10 Lars Wirzenius <>
* gw/wap-appl.c: Rearranged code in preparation for changing
the thread structure so that a new thread is not started for
each request.
2000-11-10 Lars Wirzenius <>
* gwlib/http.[ch]: Updated documentation, moved HTTP_PORT to .c,
since no-one else needs to know it.
2000-11-09 Yann Muller <>
* gw/smsc_at.c: encode 7 bit messages in the default GSM alphabet
(thanks to Mike Gaertner).
2000-11-08 Richard Braakman <>
* gw/wap-appl.c: Deal with client_SDU_size being 0, which means
there is no limit. Thanks to Ruud Schramp for pointing this out.
Also made connectionless mode set it to 0 instead of an arbitrary
2000-11-08 Lars Wirzenius <>
*, Made "make install" work in a more
sensible way, at least as far as the Filesystem Hierarchy Standard
(pretty much all Linux systems, and mostly BSD systems as well)
is concerned. /usr/bin and /usr/sbin are now used properly,
and manual pages are installed as well. Also, the User Guide is
installed in a more sensible way.
* debian/rules: Updated accordingly.
2000-11-08 Lars Wirzenius <>
* checks/ Remove log files if check was
2000-11-08 Kalle Marjola <>
* gw/bb_boxc.c: fixed error that caused bearerbox to possibly
segfault when connection from illegal IP was tried
* gw/smsbox_req.c: make sure that UDH length is set properly
2000-11-07 Lars Wirzenius <>
* gwlib/http.c: Bugfix. Destroy the new_server_sockets list.
2000-11-07 Lars Wirzenius <>
* gwlib/http.c: Massive rearranging and some renaming, but no real
changes. The code is now much cleaner and easier to understand.
2000-11-07 Tuomas Luttinen <>
* gwlib/octstr.c: Added some protection against endless loops in
strip-functions for special cases.
* gw/wml_compiler.c: Memory leak with malformed variable fixed.
Also fixed the bug that reserved words cannot be variable names,
eg $(password).
2000-11-07 Lars Wirzenius <>
* gwlib/http.[ch]: Removed old server API.
2000-11-07 Lars Wirzenius <>
* test/drive_wapbox.c: Converted to use new HTTP server API.
2000-11-07 Richard Braakman <>
* gwlib/http.c: Fix memory leak in client_read_body.
Make server_thread not warn if gwthread_poll fails with EINTR.
* gwlib/conn.[ch]: Added conn_read_error(), and a read_error
field to the Connection structure.
Added conn_read_everything().
* gwlib/http.c: In client_read_body, use conn_read_everything
instead of conn_inbuf_length and conn_read_fixed. This way
it will detect end-of-file.
* gw/wapbox.c: Make send_heartbeat_thread() not send more
heartbeats than twice the usual frequency. (We can live with
sleep() not being exact, but when the wapbox is run inside a
debugger it tends to go wild.)
2000-11-07 Lars Wirzenius <>
* checks/ Sleep for five seconds before starting
smsbox; this prevents the smsbox from crashing before the
bearerbox is ready to accept its connection.
* gw/smsbox.c: Adapted to new HTTP server API.
* gwlib/http.c: Bugfix. If we fail to re-use a connection, and
re-open it, we must then quit the handler for the old connection.
2000-11-07 Lars Wirzenius <>
* checks/ Wrote.
2000-11-07 Lars Wirzenius <>
* checks/ Wrote.
2000-11-06 Tuomas Luttinen <>
* gw/wml_compiler.c: Variables with syntax errors are now discarded
with warning instead giving up with the hole WML source. Some memory
leak still exists. Also an unknown tag produces a warning in the log.
2000-11-06 Lars Wirzenius <>
* gw/smsc_at.c: Applied fix from Paul Keogh to hex number
2000-11-06 Lars Wirzenius <>
* utils/kannel-redhat.init.d: New file from Fabrice Gatille.
2000-11-06 Lars Wirzenius <>
* configure{,.in}, Add support for PAM enable and
* gw/smsbox_req.c: Fixed the PAM stuff so that it will compile
with the new gwmem.h protectors against malloc and friends.
2000-11-06 Lars Wirzenius <>
* README, doc/userguide/userguide.xml: Moved information on how
to use configure from README to User Guide.
2000-11-06 Lars Wirzenius <>
* Bearerbox converted to use with ne HTTP server API, with help
from Kalle Marjola.
* gw/bb_http.c: Only use one thread to handle HTTP requests.
Added function httpadmin_stop to help with shutdown
synchronization issues.
* gw/bearerbox.[ch]: In signal handler, call bb_shutdown, instead
of set_shutdown_status. This point may need to be implemented
better later. Call httpadmin_stop in main.
* gwlib/http.c: Have http_close_all_server kill the server threads
as well, including killing the FDSet poller thread.
2000-11-06 Kalle Marjola <>
* gw/smsc_emi.c (emi_open_ip): check if allow_ip set. Thanks for
Juho-Pekka Virolainen for noticing this.
2000-11-06 Yann Muller <>
* gw/smsc_at.c: fixed Premicell bug. Added sleep(1) for nokiaphone.
2000-11-05 Richard Braakman <>
* gwlib/http.c: Make the interface of client_read_body() match the
rest of the design. This makes the http module work with HTTP/1.1
servers again.
2000-11-03 Tuomas Luttinen <>
* gw/wml_compiler.c: A conformance patch: card and template elements
cannot have 2 or more do elements of the same name, PI are ignored,
unknown tags and CDATA are now processed. Also some code was cleaned
into the new coding standard.
2000-11-03 Richard Braakman <>
* gw/wsp_headers.c: If an Expires header has an invalid date, then
encode it as a date far in the past. We can't just skip the header
because RFC2068 says such a response should be treated as already
expired, and we have to tell the client to do that.
* gw/wsp_headers.c: Make sure that a Multi-octet-integer is always
at least one octet long, even if its value is 0.
2000-11-03 Kalle Marjola <>
* gw/smsbox.c: changed 'sent..' log event to clearly state that it
only means that the message was sent to bearerbox, not further
2000-11-03 Lars Wirzenius <>
* checks/check_list.c: Fixed synchronization problems that
occasionally caused it to randomly fail. The list code itself
was OK, but the checking code did not synchronize thread startups
2000-11-03 Lars Wirzenius <>
* test/test_http.c: Change the error message when there are
no command line arguments from "Floating point exception (core
dumped)" to the standard help text.
2000-11-03 Lars Wirzenius <>
* test/test_http_server.c: Converted to use the new HTTP server
interface. This displayed bugs in shutdown situations for the
new HTTP code.
* gwlib/http.c: Fixed bugs in shutting down.
2000-11-03 Lars Wirzenius <>
* test/test_http_server.c: Reformatted to coding style.
2000-11-03 Lars Wirzenius <>
* gwlib/http.[ch]: First cut at changing the HTTP server side
interface to be more sensible about the number of threads. Doesn't
work quite well yet (i.e., if I change test/test_http_server.c,
make check fails), but I want it committed for now. Shouldn't
harm anyone, as long as they don't use it.
2000-11-02 Paul Keogh <>
* gw/cookies.c: Fix for some cookie management bugs.
2000-11-01 Richard Braakman <>
* gwlib/gwthread-pthread.c: Fix memory leak if poll() was
2000-11-01 Richard Braakman <>
* gw/smsc_emi.c: Cleaned up a bit, made thread-safe.
* gw/smsc_p.h, gw/smsc.c: Declare and initialize new EMI fields.
2000-11-01 Richard Braakman <>
* gwlib/octstr.c: Make octstr_read_file use a smaller buffer,
to reduce stack usage.
2000-11-01 Lars Wirzenius <>
* gw/wap-appl.c: Implement magic URL kannel:alive, based on
patch from Neil Hunter.
2000-11-01 Lars Wirzenius <>
* gwlib/gwlib.h, gwlib/list.c: Move around include for gwmem.h
so it comes after thread.h, because thread.h includes pthread.h,
and Cygwin's pthread.h includes malloc.h, which gets annoyed by
the macros gwmem.h defines.
2000-11-01 Kalle Marjola <>
* gwlib/conffile.c (config_sanity_check): fixed that 'otaconfig'
is accepted, too, thanks to Philip Psiloinis for pointing this out
* gw/bb_smsc.c: make sure that lists are emptied
2000-11-01 Yann Muller <>
* gw/smsc_at.c: handles message lengths of 8*n+1 properly.
Added comments to encode7bituncompressed().
2000-10-31 Richard Braakman <>
* gwlib/fdset.c: Handle EINTR.
2000-10-31 Richard Braakman <>
* Moved wap_addr functions from wapbox.c to new file wap_addr.c,
and created wap_addr.h for it.
2000-10-31 Richard Braakman <>
* gwlib/conn.[ch]: Make it possible to change the callback info
efficiently, by calling conn_register again with the same fdset.
* gwlib/fdset.c: Fiddled with poller loop to deal with callback
functions doing strange things to the poll array while it's being
2000-10-31 Lars Wirzenius <>
* gwlib/http.c: Now uses FDSet, instead of explicit waits,
and now again does concurrent transactions as a side effect,
but only does one transaction per HTTP connection. The code is
in need of cleaning up quite a bit, but should work, except for
not destroying the FDSet at shutdown.
2000-10-31 Richard Braakman <>
* gwlib/conn.c: Implement conn_unregister() too.
2000-10-31 Lars Wirzenius <>
* gwlib/http.c: Converted HTTP transaction handling into a state
machine, so that FDSets can be easily be used with HTTP.
2000-10-30 Lars Wirzenius <>
* gwlib/gwstr.[ch]: Removed unused functions strndup and
str_reverse_case_seek. The rest of this module will go away once
smsbox is re-written to use Octstr.
2000-10-30 Richard Braakman <>
* gw/wap-appl.c: Support for X-WAP.TOD header, needed for WAP 1.1
conformance. (requirement UACache-0010)
* gw/wsp_headers.c: Special encoding for X-WAP.TOD, which is
an application-specific header with a field encoding that does
not match the application-specific-value rule. (This is a
contradiction in the spec).
* gwlib/http.[ch]: Make http_header_remove_all report how many
headers it removed.
2000-10-30 Aarno Syvänen <>
* gw/wtp_resp_state-decl.h: Added timeout to state RESULT_WAIT: Now
we wait for result only for AEC_MAX timer periods.
* gw/wtp.c, gw/wtp_resp.c, gw/wtp_resp_state-decl.h: Added class
transaction handling. Not much tested, yet.
2000-10-27 Lars Wirzenius <>
* README.*: Moved information into README. There's no point in
having lots of small files.
2000-10-27 Lars Wirzenius <>
* gw/bb_http.c: Add Content-Type header to bearerbox admin
interface replies.
2000-10-27 Kalle Marjola <>
* gw/smsbox_req.c: fixed bug created by applying a few day old fix...
2000-10-26 Richard Braakman <>
* test/test_headers: Fix memory leaks introduced by
http_header_combine test.
2000-10-26 Richard Braakman <>
* gwlib/fdset.[ch]: New module for polling large sets of file
descriptors efficiently. Not used yet, intended for HTTP module.
* gwlib/gwlib.h: include fdset.h
* gwlib/conn.[ch]: Added conn_register and conn_unregister,
to use Connections with FDSets.
* gwlib/list.[ch]: Wrap list_create just like octstr_create,
so that the memory leak listing shows who called list_create.
2000-10-26 Lars Wirzenius <>
* gwlib/dict.c: Initialize hash table elements to be Lists, instead
of garbage.
* test/test_dict.c: Wrote.
* gwlib/http.c: Cleanups: Wait for read_response_thread to
terminate at http_shutdown and destroy the started_requests_queue.
Also re-implemented the HTTPSocket pool with dict, so that it
no longer does linear searches; the code is a bit simpler now
as well.
* test/test_http.c: Use http_destroy_headers instead of
list_destroy. This also fixes a memory leak of one header.
2000-10-26 Lars Wirzenius <>
* gwlib/octstr.c: Give unsigned int as the type to expect to
va_arg when converting %u and %hu and similar cases.
2000-10-26 Richard Braakman <>
* gw/wap-appl.c: Use http_header_combine instead of
http_append_headers to combine session and request headers,
to get the semantics right according to WAE section 8.
* gwlib/http.c: Implemented http_header_combine.
* test/test_headers.c: Added a test of http_header_combine.
2000-10-26 Lars Wirzenius <>
* gwlib/dict.[ch]: Wrote.
* gwlib/gwlib.h: Include dict.h.
2000-10-26 Kalle Marjola <>
* gwlib/conffile.c (config_sanity_check): make sure that there are
smsc group(s) and sms-service group(s) if there is smsbox set.
2000-10-26 Lars Wirzenius <>
* gwlib/http.c: Converted to use conn.c. This is a minimal change,
and does not yet do multiple transactions in parallel.
2000-10-26 Lars Wirzenius <>
* gw/smsbox.c: Get client IP using http_socket_ip, instead of
http_socket_fd. http_socket_fd will be reserved for getting the
file descriptor for the HTTP server port only, and may ultimately
go away completely.
* gw/smsbox_req.c: Bugfix. We gave the allow list as the deny
list when checking for sendsms client authorization.
2000-10-26 Kalle Marjola <>
* doc/userguide/userguide.xml: added (m) 'mandatory' and (c)
'conditionally mandatory) markings to all configuration file
2000-10-26 Kalle Marjola <>
* gw/smsbox_req.c: fixed that messages with no translation are
handled correctly
2000-10-25 Lars Wirzenius <>
* gw/wml_definitions.h: Commented out OPAQUE, since Cygwin
(via some Windows header) defines it, and it isn't being used,
anyway. This is an intermin solution, a better one would be to
add something like a WML_ or WBXML_ prefix to all those tokens.
* gw/wtp_resp_state-decl.h: Renamed WAIT_TIMEOUT to
WAIT_TIMEOUT_STATE to get rid of name conflicts with Cygwin
* gwlib/socket.c, test/fakewap.c: Removed an include for
netinet/tcp.h, which seems to a) not be needed under Linux and b)
be unknown to Richard Stevens, so presumably it is non-portable.
If it proves to be necessary, we'll add it to configure and
include it conditionally.
* Thanks to Stipe Tolj for pointing these out.
2000-10-25 Lars Wirzenius <>
* configure{,.in}: Check for pthread_exit instead of
pthread_create, when looking for a Posix thread implementation.
HP-UX has trouble finding pthread_create, because it is an
inline function.
2000-10-25 Richard Braakman <>
* wmlscript/wsstree.[ch], wmlscript/wslexer.c: Fix parsing of
integer literal -2147483648. This was done by storing numbers
as unsigned longs and introducing an explicit sign field.
2000-10-24 Richard Braakman <>
* gwlib/octstr.c: Add support for formats u, o, x, and X.
(test_cimd2 needs X.)
* test/test_cimd2.c: Fix errors in octstr_format calls.
2000-10-24 Richard Braakman <>
* wmlscript/wsstdlib.c: Corrected "Phonebook" to "PhoneBook".
2000-10-24 Kalle Marjola <>
* doc/userguide/userguide.xml: filled SMPP smsc group fields,
thanks for Mikael Gueck for patch.
2000-10-24 Lars Wirzenius <>
* Finished first phase of reducing the number of threads
doing HTTP requests. This phase implements a new interface
(http_start_request and http_receive_response, with the http_get
and http_post functions being wrappers around these). The
goal is to have a static number of threads, internal to the
HTTP implementation, doing all HTTP requests at once, instead
of having a new thread for each HTTP request. This phase makes
that happen, but is implemented so that HTTP requests are done
serially, not in parallel. The next phase is to re-write the I/O
parts of the HTTP implementation so that HTTP requests are done
in parallel once again, using the conn.c module.
* gwlib/http.[ch]: Many internal changes.
* test/test_http.c: Use the new interface, instead of the
http_get wrapper.
2000-10-24 Kalle Marjola <>
* gw/urltrans.c: oops, forgot to switch reservations
2000-10-24 Kalle Marjola <>
* gw/urltrans.c: added missing (disappeared?) room reservation for
%q and %Q in get_pattern, and added note why sender and receiver
is switched. Thanks for Juho-Pekka Virolainen for noticing this.
2000-10-24 Yann Muller <>
* gw/smsc_at.c: Added support for Falcom A2D modem, thanks to
Mike Gaertner. Also changed the default protocol identifier
and coding scheme. Preliminary support for Nokia 7110 as SMSC.
2000-10-23 Lars Wirzenius <>
* gwlib/gwmem.h, gwlib/protected.h: Wrote macros to make it
harder to call the wrapped functions directly.
* gwlib/gwmem-check.c, gwlib/gwmem-native.c, gwlib/protected.c:
Call the wrapped functions anyway. :)
* gw/bb_smsc.c, test/fakesmsc.c, test/fakewap.c,
test/test_cimd2.c, test/wml_tester.c: Use wrappers instead of
direct calls to the wrapped functions.
* wmlscript/wmlsc.c: Undefine the accident protectors and call
the wrapped functions directly. This needs to be fixed later.
2000-10-23 Lars Wirzenius <>
* gwlib/utils.[ch]: Wrote gw_isdigit and gw_isxdigit as wrappers
around isdigit and isxdigit, to compensate for broken platforms
where they are not available as functions.
* gw/smsc_cimd2.c, gw/wsp_headers.c, gwlib/octstr.[ch]: Use
gw_isdigit and gw_isxdigit instead of isdigit and isxdigit
together with octstr_check_range.
2000-10-23 Lars Wirzenius <>
* configure{.in,}: Don't compile start-stop-daemon, unless the
--enable-start-stop-daemon option is used.
* gw/smsc_at.c, gw/smsc_emi.c, gw/smsc_sema.c: Define CRTSCTS as
zero if it is not defined.
* gwlib/socket.c: Allocate the 64 kilobyte buffer dynamically,
instead of from the stack.
* These changes were prompted by a report of HP/UX compilation
changes by Timo Siirainen.
2000-10-23 Lars Wirzenius <>
* ChangeLog: Formatted long lines.
2000-10-23 Kalle Marjola <>
* doc/userguide/userguide.xml: added missing EMI variable
2000-10-23 Aarno Syvänen <>
* gw/wtp_resp_state-decl.h: Spec does not say what to do when state is
RESULT_RESP_WAIT and event receiving an invoke. Yet 0.12 logs already
have these events. Handled event same way when state is RESULT_WAIT.
2000-10-23 Richard Braakman <>
* Made gwthread_poll() actually return the results.
2000-10-23 Richard Braakman <>
* Bugfix: HTTP POST requests have a Content-Length again.
Thanks to Stipe Tolj for spotting the problem.
2000-10-20 Kalle Marjola <>
* doc/userguide/userguide.xml: wrote appendix B, using fake SMS
2000-10-19 Kalle Marjola <>
* doc/userguide/userguide.xml: added notes on 'required
components' for SMS gateways
2000-10-19 Kalle Marjola <>
* gw/wapbox.c: send that wakeup when bearerbox exits, too.
2000-10-19 Kalle Marjola <>
* gw/wapbox.c: modified send_heartbeat to use gwthread_sleep
instead of ordinary sleep, so we can use gwthread_wakeup to wake
it up when wapbox is killed - now wapbox dies when it catches
kill, not after 0-30 seconds.
2000-10-18 Tuomas Luttinen <>
* gw/wml_compiler.c: Now checks also attributes for texts that could
be placed in the string table. Also removes non alphanumerical
characters from the start and the end of the strings.
* gwlib/octstr.[ch]: octstr_strip_nonalphanums added.
2000-10-18 Richard Braakman <>
* gwlib/conn.[ch]: Added conn_wait_multi(). Untested.
Fine-tuned the locking in conn_wait.
* gwlib/gwthread-pthread.c, gwlib/gwthread.h:
Added gwthread_poll(). Untested.
2000-10-18 Richard Braakman <>
* gwlib/charset.c, gwlib/conffile.c, gwlib/counter.c,
gwlib/counter.c, gwlib/gwmem-check.c, gwlib/gwmem-native.c,
gwlib/gwstr.c, gwlib/parse.c, gwlib/protected.c, gwlib/socket.c,
gwlib/thread.c: Reformatted.
2000-10-18 Richard Braakman <>
*, New test for HAVE_SYS_POLL_H.
* gwlib/gwpoll.h, gwlib/gwpoll.c: Files that either include
sys/poll.h or define poll() themselves.
* gwlib/gwlib.h: Include gwpoll.h.
* gwlib/conn.c, gwlib/gwthread-pthread.h: Do not include
sys/poll.h directly, let gwlib/gwlib.h do it.
2000-10-18 Richard Braakman <>
* gw/bb_udp.c, gwlib/http.c: Corrected some stray free() calls
to gw_free().
2000-10-18 Kalle Marjola <>
* gw/bearerbox.c: Use new report_version in HTTP admin status, too.
2000-10-18 Lars Wirzenius <>
* gw/shared.[ch]: Added function version_report_string so that the
report_version() info can be reported via HTTP as well.
2000-10-18 Kalle Marjola <>
* gw/smsc_fake.c: fixed that message sending is not tried with
closed socket, but error is returned instead
* gw/bb_*.c: added missing queueing information to status: now all
lists are added together before reporting queue lengths
2000-10-18 Aarno Syvänen <>
* gw/wtp_init_state-decl.h, wtp_resp_state-decl.h: Add a comment tell-
ing which CR is implemented. Now all deviations from June 2000 con-
formance release are explained.
2000-10-18 Kalle Marjola <>
* gw/bearerbox.c: updated 'status' to tell number of messages
still queued in main queues (internal specific queues are not yet
* gw/bb_*.c: Did initial code changes for 'xmlstatus' query,
although it does not return anything yet.
2000-10-18 Lars Wirzenius <>
* gw/urltrans.c: Fix off-by-one error in is_safe array size
in encode_for_url().
2000-10-18 Lars Wirzenius <>
* gw/bearerbox.c, gw/smsbox.c, gw/wapbox.c: Added missing #include
2000-10-17 Lars Wirzenius <>
* gwlib/gwlib.c: Reformatted to new coding style.
* gw/shared.[ch]: New files to hold the function report_versions
(and other functions in the future). This function reports the
version of Kannel that starts up, and the host it runs on, and
the version of libxml.
* gw/bearerbox.c, gw/smsbox.c, gw/wapbox.c: Call report_versions.
2000-10-17 Tuomas Luttinen <>
* gw/urltrans.c: Changed the logic in the encode_for_url so that the
safe ones are listed and the save characters being alphanums and marks
"-", "_", ".", "!", "~", "*", "'", "(", ")". Also UTF-8 with full
spectrum of Unicode should work now.
2000-10-17 Kalle Marjola <>
* gw/smsbox.c: Added requested event of sent message
2000-10-16 Lars Wirzenius <>
* gwlib/log.c: Reformatted. Also made kannel_syslog's mapping of
Kannel's log level to syslog log levels actually work.
2000-10-16 Lars Wirzenius <>
* checks/check_counter.c, checks/check_date.c,
checks/check_list.c, checks/check_octstr.c, gwlib/log.c,
gwlib/log.h, gwlib/utils.c: Renamed the log level enums to have
a GW_ prefix, to avoid problems with broken compilers that define
ERROR themselves or in some header.
2000-10-16 Lars Wirzenius <>
*, configure{,.in}: Check for the magic compiler
(not preprocessor) symbols __func__ (standard in the 1999 version
of the standard) and __FUNCTION__ (popular extension to the 1989
version of the standard). Define __func__ as __FUNCTION__ or
"unknown" depending on what is available.
* gwlib/gwassert.h, gwlib/gwmem.h, gwlib/octstr.c: Use __func__
instead of __FUNCTION__.
2000-10-16 Lars Wirzenius <>
*, configure{,.in}, gwlib/gw-getopt.h: Check for a
prototype for getopt in stdio.h and unistd.h as well, and only
use our own one if we fail to find anything. This should make
Kannel compile on Solaris again.
2000-10-16 Aarno Syvänen <>
* gw/wtp_resp_state-decl.h: Removed CR inside a string.
2000-10-13 Tuomas Luttinen <>
* gw/wml_compiler.c: parse_entities added as a fast patch to fullfill
WAP 1.1 conformance with WML entities.
2000-10-13 Lars Wirzenius <>
* gwlib/gw-getopt.h: Wrote. This header makes sure getopt()
and the corresponding variables are declared properly so that
any program that includes gwlib/gwlib.h can use getopt without
worrying. This should make it unnecessary to clutter all programs
with #if HAVE_GETOPT_H stuff.
* gwlib/gwlib.h: Include gw-getopt.h.
* wmlscript/wmlsc.c, wmlscript/wmlsdasm.c: Make sure gwlib.h is
2000-10-13 Lars Wirzenius <>
* gwlib/http.c: Disable the start_request_thread as well. It
caused "make check" to fail (I ran it in the wrong directory
* test/test_http.c: Use http_get until http_start_get and
http_receive_result work properly.
2000-10-13 Lars Wirzenius <>
* gwlib/http.c: Disable the kludge_do_one_request thread, since
it isn't killed (or joined) properly.
2000-10-12 Kalle Marjola <>
* doc/userguide/userguide.xml: added new example: multi-operator
SMS Kannel.
2000-10-12 Lars Wirzenius <>
* gwlib/http.[ch]: Added a prototype implementation for the new
start/receive-result interface to HTTP requests (see functions
http_start_get and http_receive_result). Don't use this yet,
it needs to be implemented properly.
* test/test_http.c: Modified to use the new interface.
2000-10-12 Richard Braakman <>
* gwlib/gwassert.h: Added parentheses around the panic(...), 0
expressions in the assert macros, to get the originally intended
2000-10-12 Richard Braakman <>
* wmlscript/wserror.c: Corrected a stray va_arg(ap, char).
(va_arg should always get the type as it is after promotion, and
char is promoted to int.)
2000-10-12 Lars Wirzenius <>
* gwlib/http.c: When we are the server side, and the client uses
HTTP 1.0, we will close the connection. If the client uses HTTP
1.1, we keep it open.
* gw/smsbox.c: Remove the workaround for the missing feature
now implemented.
2000-10-12 Kalle Marjola <>
* gw/bearerbox.c, gw/bb_boxc.c, gw/bb_udp.c, gw/bb_smsc.c: Startup
improved; not based on 'hopefully they will get up by that time'
system but intra-thread wakeup call. Now the bearerbox starts up
very quickly.
2000-10-11 Tuomas Luttinen <>
* gw/urltrans.c: Fixed the bug 111 by adding the unwise characters
and special characters like delete (0x7f) and other between 0x00
and 0x1f into the unsafe ones.
* gw/wml_compiler.c (string_table_apply): Fixed a bug where an extra
string end was added in a case that two (or more) substrings are
replaced with the 2nd (3rd...) being the first to be replaced.
2000-10-11 Lars Wirzenius <>
* gw/wapbox.c: Formatted to follow coding style.
2000-10-11 Lars Wirzenius <>
* gw/wapbox.c: Simplified the main loop. Also removed the
initialization of ret (which was done at the definition
of the variable, tens of lines above, which is bad style).
Removed comments at end of braces, which is also bad style
(if it is not obvious what the braces end, the loop or whatever
construct is too long or indentation is broken).
2000-10-11 Aarno Syvänen <>
* gw/wapbox.c: Separate conditions event == NULL and event_is_for_
responder in code selecting to which wtp process an incoming
event belongs.
2000-10-11 Peter Gronholm <>
* gw/control.html: Updated the example file to reflect the new
http interface administration commands.
2000-10-11 Kalle Marjola <>
* gw/bb_http.c: fixed that query parsing value '0' is not
accepted, only '1'
* doc/userguide/userguide.xml: added notes about sms-service
2000-10-10 Richard Braakman <>
* wmlscript/{ws.c, wsgram.y, wsstree.[ch]}: Remove WsPair and
replace it with more specific types WsVarDec and WsFormalParm.
This gets rid of an assumption that a long will fit in a (void *)
field, which tends not to be true on 64-bit platforms.
2000-10-10 Richard Braakman <>
* wmlscript/wsencode.c: Fix va_arg type bug for all platforms,
not just sparc. Removed SPARC_ABI conditionals.
2000-10-10 Lars Wirzenius <>
* debian/postinst: Don't use /var/log/kannel as home directory
for user kannel.
2000-10-10 Lars Wirzenius <>
* debian/postinst: Now updates rc.d links and starts Kannel.
* debian/postrm: Wrote. Removes rc.d links.
2000-10-10 Richard Braakman <>
* gw/wsp-method-state.h: Fixed state transition for TR-Abort.Ind,
in state REPLYING. Thanks to Aymerick Jéhann for noticing.
2000-10-10 Lars Wirzenius <>
* gw/wtp_init_state-decl.h: Fixed misspelled INITIATOR_RESULT_WAIT.
2000-10-10 Lars Wirzenius <>
* debian/rules: "clean" doesn't run "make clean" unless Makefile
2000-10-10 Lars Wirzenius <>
* debian/init: start kannel boxes as user "kannel" instead of
root. run_kannel_box needs to run as root to create the pid file.
* debian/postinst: Wrote. Creates user kannel and make
/var/log/kannel be owned by kannel.
* utils/run_kannel_box.c: Added --no-extra-args option, so that
we can run other programs than Kannel boxes (su, in this case,
to switch users).
2000-10-10 Aarno Syvanen <>
* gw/wtp_init_state-decl.h: Prevent RCR growing greater than its
maximum allowed value.
2000-10-10 Kalle Marjola <>
* gwlib/octstr.c: fixed bug in octstr_str_compare
2000-10-10 Kalle Marjola <>
* gwlib/socket.c: moved 'errno' from second call to first one in
connect_to_server to avoid tempering with it before we report the
2000-10-10 Lars Wirzenius <>
* gwlib/gwthread.h: Removed unnecessary and bad ## operator
from gwthread_create wrapper macro. It pasted together two
string literals, creating an invalid pre-processing token, thus
causing small red daemons to fly out of my nose, flapping their
wings furiously, and thus causing a small wind to blow in Rio
de Janeiro, turning the page of the book being read by a local
critic and causing him to complain in his article about the book
that it was repetitive. Be careful with those undefined behaviors,
folks, you never know what will happen.
* gw/wap-appl.c, gw/wsp.h: Added function wsp_http_map_destroy,
from Paul Keogh.
* gw/wapbox.c: Call wsp_http_map_destroy at shutdown.
2000-10-09 Richard Braakman <>
* wmlscript/wsopt.c: Add an optimization to remove useless tobool
2000-10-09 Richard Braakman <>
* wmlscript/wsstree.c: Always convert the result of an && or ||
operator to boolean, because the spec requires it for typeof().
2000-10-09 Aarno Syvänen <>
* gw/wtp_init.c, wtp_resp.c: When the state machines cannot handle
an event, we ignore it and log an error message. Timer will abort
this tranaction.
2000-10-09 Richard Braakman <>
* gw/smsc_cimd2.c: Converted to new formatting style.
2000-10-09 Aarno Syvänen <>
* gw/wtp_state-decl.h: Incorporated CR-Nokia-WTP-20-March-2000/2.
In plain words, when load is heavy, Ack(TidOK) may be delayed so
much that initiator will retransmit it and the responder will re-
ceive the original when its state is RESULT_WAIT. This Ack must
be ignored. This corrects bug reported by David.
2000-10-09 Richard Braakman <>
* wmlscript/wsgram.y: Compile unary + such that it performs the
required type conversions.
2000-10-09 Richard Braakman <>
* wmlscript/wsasm.c: Fixed error in jump distance calculation when
jumping backward over a forward jump. This messed up "continue"
statements among other things.
2000-10-09 Richard Braakman <>
* Renamed Msg type smart_sms to sms.
2000-10-09 Richard Braakman <>
* gwlib/octstr.c: Rearranged immutable octstrs so that seems_valid()
correctly flags freed octstrs again. Added !immutable assertions
to octstr_grow and octstr_set_char.
Reformatted octstr_append_from_hex.
* test/test_http.c: Fixed memory leak in case of server not
2000-10-09 Aarno Syvänen <>
* gw/wtp_init.c: Remove an unused variable.
2000-10-06 Richard Braakman <>
* gwlib/utils.c: Changed kannel_cfmakeraw() comments to match
2000-10-06 Aarno Syvänen <>
* gw/wtp*: Reformat (except wtp_pdu.*).
* gw/wtp_resp_state-decl.h: More comments.
* gw/wtp_init.c, gw/wtp_init_state-decl.h: wtp had a tid of its own,
so no mutexes are needed here.
2000-10-06 Richard Braakman <>
* gw/smsc.c: Reactivate the code that sets the timestamp on an
sms message, if the SMSC didn't set it. Thanks to Jarkko Kovala
for noticing.
2000-10-06 Richard Braakman <>
* Making release 0.11.3
2000-10-06 Richard Braakman <>
* doc/userguide/userguide.xml: Terminate OTA CGI table so that
it compiles.
* gw/smsbox.c, gw_smsbox_req.[ch]: Give smsbox_req_sendota() a
"client_ip" parameter so that it can call authorise_user correctly.
* gw/smsbox_req.c: smsbox_req_sendota(): Remove unused variables.
Use octstr_create("") instead of the no longer existing
* gw/bb_boxc.c: Fix memory leak in route_msg() when routing
WAP packet but no wapboxes are connected.
* gwlib/http.c: Fixed silly bug in http_remove_hop_headers that
would make the wapbox panic if a server used the Connection: header.
Fixed memory leak in same function.
2000-10-05 Yann Muller <>
* gw/smsbox_req.c/h: added smsbox_req_sendota() to send OTA config
* smsbox.c: calls smsbox_req_sendota() if cgi address matches
* doc/userguide/userguide.xml: added info about config and usage
of OTA.
* gwlib/octstr.c/h: added octstr_append_from_hex().
2000-10-05 Kalle Marjola <>
* doc/userguide/userguide.xml: language corrected.
2000-10-05 Richard Braakman <>
* Added seems_valid assertion to end of octstr_format().
* gw/wap-appl.c: Fixed silly mistake that caused random panics.
2000-10-05 Richard Braakman <>
* gw/wap-appl.c: Bugfix, don't panic if resp_headers is NULL
(i.e. the HTTP request failed).
* gw/fakewap.c: Correctly encode requests with urls longer than
128 bytes.
2000-10-05 Kalle Marjola <>
* test/fakesmsc.c: use info level to inform that all messages have
been sent.
2000-10-05 Richard Braakman <>
* wmlscript/*: Reformatted.
2000-10-05 Kalle Marjola <>
* gw/smsbox_req.c: made sure that when max_msgs == 0 then no
messages are sent.
2000-10-05 Richard Braakman <>
* gw/wsp_headers.c: Bugfix in pack_integer_string, use ULONG_MAX
instead of UINT_MAX and include the right header file.
2000-10-04 Richard Braakman <>
* gw/wap-appl.c: Pass the status code we really got from
the server to the client, instead of only accepting code
200 (HTTP_OK). Use 502 (Bad Gateway) if the actual lookup
failed. Use http_get and http_post instead of http_get_real
and http_post_real. Together with the header encoding patch
earlier today, these changes allow HTTP redirection to work.
* gw/wap-appl.c, gwlib/http.h: Use symbolic names for HTTP status
* gw/wsp_headers.c: Correct small bug that made wsp_headers_pack
encode the content-type twice if separate_content_type was on.
2000-10-04 Richard Braakman <>
* gwlib/gwmem.h, gwlib/gwmem-check.c: Let gw_claim_area return
the pointer it gets, and let it accept NULL pointers. This
makes it easier to use in wrapper macros.
* gwlib/octstr.[ch]: Wrap octstr_create, octstr_create_from_data,
octstr_copy, and octstr_duplicate so that they "claim" the Octstr
they return for their caller. This information will show up in
the gw_check_leaks() output, making memory leaks much easier to
* gw/wsp_headers.c, gwlib/http.c: Fix memory leaks found this way.
2000-10-04 Richard Braakman <>
* Encode response headers and send them to the client:
* gw/wsp_headers.[ch]: Added wsp_headers_pack. Fixed some bugs in
wsp_headers_unpack. Replaced a few magic numbers with names.
* checks/, test/test_headers.c, test/header_test:
New files. Exercise header code by packing and unpacking a set
of headers that try to cover all possibilities.
* test/fakewap.c: Be less strict in checking Reply packet, because
it can no longer assume the response headers are empty. (Implementing
full parsing wouldn't be worth the effort.)
* gw/wap-appl.c: Added http_remove_hop_headers and used it to
delete hop-by-hop headers when forwarding HTTP headers to
client or server. (The hop-by-hop headers are for one connection
only, for example Transfer-Encoding.)
* gw/wap-appl.c: When applying a content converter to the
response body, update the response headers to reflect this.
* gw/wap-appl.c: Fill in the response_headers field of
S_MethodResult_Req and S_Unit_MethodResult_Req events, now
that they're used.
* gw/wap-events-def: In the S_MethodResult_Req, response_headers
Removed response_type field from the MethodResult events, it's
not used and the information is present in response_headers.
* gw/wsp-method-state.h, gw/wsp-session-state.h, gw/wsp-unit.c:
Renamed unpack_headers to wsp_headers_unpack to match function naming
convention. Use wsp_headers_pack instead of wsp_encode_http_headers.
* gw/wsp-strings.def: Introduce some new tables used for
header encoding.
* gw/wsp.c, gw/wsp.h: Deleted wsp_encode_http_headers, it's
obsoleted by wsp_headers_pack.
* gw/wsp.c: Changed wsp_convert_http_status_to_wsp_status to
handle all defined status values.
* gwlib/http.[ch]: Added several utility functions used by
header packing. Minor formatting corrections.
* gwlib/octstr.c: Added assertions to octstr_append* functions
to prevent segfault.
2000-10-04 Kalle Marjola <>
* gwlib/conffile.c|h: added new function 'config_sanity_check' to
check configuration files for basic errors (like empty lines in
the middle of groups).
* gw/*box.c: modified to use that new function
2000-10-04 Kalle Marjola <>
* gw/smsc.c, gw/smsc_p.h, gw/smsc_emi.c: added configuration
variable 'connect-allow-ip' currently used by emi_ip in certain
situations - banned connect from other IPs, so you have to set
this variable if you still want to use emi_ip with receive port.
* gwlib/socket.c: removed loist of 'errno' from error, to minimize
double system error outputs.
2000-10-03 Kalle Marjola <>
* gw/smsbox.c: Fixed that we tried to close non-opened
http-server-socket, which caused PANIC.
2000-10-03 Kalle Marjola <>
* gw/bb_smsc.c: Fixed a nice bug that appeared only with severe
2000-10-03 Kalle Marjola <>
* gw/bb-smsc.c: added SMS multi-send. This is achieved via
multiple phone numbers at 'to' field in send-SMS request, each
separated with space (currently, possibly changed later). This is
not a complete multi-send at SMSC protocol level - the message is
splitted into several ones in bearerbox before sending it to
SMSC. Note that 'preferred-prefix' and 'denied-prefix' only care
about the FIRST phone number in such a message (anyway, use smsc
ID instead)
* doc/userguide/userguide.xml: added notes on multi-send
2000-10-03 Lars Wirzenius <>
* debian/changelog: Added new entry for newer upstream version
* debian/copyright: fixed spelling of Wapit (used to be WapIT).
* debian/conffiles: New file, lists the files in the Debian
package that are marked as configuration files.
* debian/init: No longer automatically copied from
utils/kannel-init.d, since we can't guarantee that would be the
right thing to do for a Debian package. Updated to work on Debian
(box path was wrong).
* debian/kannel.conf: Re-wrote to work with newer config file
* debian/kannel.wapconf: Removed, no longer needed.
* debian/rules: fixed so it works with current Kannel. Also added
manual page installation, etc.
* gw/kannel.8, utils/run_kannel_box.8, utils/seewbmp.1,
wmlscript/wmlsc.1, wmlscript/wmlsdasm.1: Wrote skeletal manual
pages for various parts of Kannel that are installed by the
Debian package.
2000-10-03 Richard Braakman <>
* gw/wsp_headers.c: Bugfix in multi_octet_integer for integers
exactly as large as a long.
* gwlib/date.c: Bugfixes for parsing non-recommended (but still
standard) date formats.
* gwlib/parse.c: Bugfixes in parse_peek_char and parse_get_uintvar.
* utils/run-checks: Don't report success if a test failed silently.
Add the name of the failing check to check.log.
2000-10-03 Tuomas Luttinen <>
* gw/wml_definitions.h: some data types unified.
* gw/wml_compiler.c: Code updated to the new coding style.
Old character set conversion code mostly removed, some skeletons
still in the closet. Hash table code added, wml_init and
wml_shutdown written, but not yet used or tested.
* gwlib/octstr.[ch]: octstr_hash_key-function added.
2000-10-03 Kalle Marjola <>
* test/fakesmsc.c: Updated to use general Kannel command line
interface - now use options -p, -i and -m to set various fakesmsc
settings. Also changed messages to 'debug' level so that there is
some use for -v argument.
2000-10-03 Richard Braakman <>
* gw/wsp-strings.c: Correct silly mistake in string_to_number.
2000-10-03 Kalle Marjola <>
* gw/smsbox.c, gw/smsbox_req.c|h: added new smsbox configuration
variable 'sendsms-chars' which is used to prevent garbage
requests. NOTE: if you are running SMS services, you should check
this out! (see user guide)
* gw/smsbox_req.c: allowed 'user' and 'password' in place of
'username' and 'password' in sendsms request.
* doc/userguide/userguide.xml: userguide upgraded to reflect
2000-10-02 Paul Keogh <>
* gw/cookies.c: Updated comment and fixed bug in get_cookies()
2000-10-02 Kalle Marjola <>
* gw/smsbox_req.c: fixed possible crash (panic) with malformed
http request
2000-10-02 Kalle Marjola <>
* doc/userguide/userguide.xml: added 'pin' to GSM Phone smsc, did
some output formatting.
2000-10-02 Richard Braakman <>
* doc/userguide/userguide.xml: Explained CIMD2 keepalive option.
2000-10-02 Kalle Marjola <>
* README: updated. Removed old references to test_wml, ooutdated
libxml version etc.
* doc/userguide/userguide.xml: some fix
2000-09-30 Kalle Marjola <>
* doc/userguide/userguide.xml: some update
2000-09-30 Kalle Marjola <>
* doc/userguide/userguide.xml: little update for SMS center
groups. Still missing values and meanings for some attributes.
2000-09-29 Richard Braakman <>
* gw/wtp_init.c, gw/wtp_resp.c: Fixed some compiler warnings.
2000-09-29 Kalle Marjola <>
* doc/userguide/userguide.xml: It has been done. Now (practically)
all data is rendered into XML and there is list of examples and
other things. However, we are missing settings for some SMS
centers and their exact names and things like that, help needed.
2000-09-29 Kalle Marjola <>
* doc/userguide/userguide.xml: rest of the newconf.txt moved into
this, and some of it edited to XML
* doc/userguide/newconf.txt: removed
2000-09-29 Kalle Marjola <>
* doc/userguide/userguide.xml: moved rest of the newconf.txt main
things into it, but not yet formatted.
2000-09-29 Richard Braakman <>
* doc/*: Ran spelling checker over most documents.
2000-09-29 Kalle Marjola <>
* doc/userguide/userguide.xml: updating, moved all data from
newbb.txt into this and did some reorganisating. Started to insert
entire newconf.txt into this.
* doc/userguide/newconf.txt: some data already moved to User Guide
* doc/userguide/newbb.txt: removed
* gw/*kannel.conf, README: updated file references
2000-09-28 Kalle Marjola <>
* doc/userguide/userguide.xml: fixed mismatch and put some extra
words about 'my_conf.conf'. More update coming tomorrow...
2000-09-28 Aarno Syvänen <>
* gw/wsp-session.c: Calling wtp_resp_dispatch event and wtp_resp_get_
* gw/wsp-session|method-state.h : Calling wtp_resp_dispatch_event
* gw/wap-events-def.h: Added event TR-Invoke.cnf
* gw/wtp.c|h: Added new external function wtp_event_id_for_responder.
This checks first bit of tid. Added helper functions unpack_invoke,
unpack_ack and unpack_abort.
* gw/wtp_resp.c|h, gw/wtp.c|h: Transferring responder machine code
to a separate module (we have an iniator, too).
* gw/wtp_resp.c: Most error checking transferred to the function
rep_machine_find_or_create. Refer to WTP, 10.2, table 33 when comment-
* gw/wtp_init.c|h, gw/init_state-decl.h, gw/init_machine-decl.h:
Wrote code for wtp iniator (for classes 0 and 1).
* gw/wapbox.c: Sending incoming message to the iniator or the
responder, depending on the first bit of the tid. Shutting down
and iniating the iniator and responder, too.
* gw/wtp_send.c|h: New functions add_responder_address and add_
iniator_address (to avoid void pointer). In functions, use field of
a machine type instead of the machine itself, if possible. Added
function wtp_send_invoke to the interface, removed do_not_start
* gw/wtp_resp_state-decl.h: Renamed wtp_state-decl.h. Reformatted
comments. Use variable name resp_machine instead of machine every-
where. Make use of the new wtp_send interface. Do not turn u_ack flag,
but ack_pdu_sent (this bug is pointed out out by Huang Li), when ack
pdu was send. Used constant ACKNOWLEDGEMENT everywhere in
wtp_send_calls. Noticed invalid use of 'resent' in the specs. Rid-flag
is not turned when ack is sent, because the iniator does not use
this flag (only rid of result message is used by it. This is pointed
out by Huang Li, too).
* gw/wtp_tid.c|h: Used variable resp_machine (and corresponding type)
2000-09-29 Richard Braakman <>
* checks/check_date.c: Wrote.
* checks/test_dates: Test material for testing dates.
* gwlib/date.[ch]: Added date_parse_http(). Fixed some bugs
in date_format_http() uncovered by check_date.
2000-09-28 Lars Wirzenius <>
* gwlib/socket.c: udp_bind: Recognize interf "*" as an alias for
INADDR_ANY, so that Kannel again follows documentation.
2000-09-27 Richard Braakman <>
* gw/wsp-strings.c: Changed everything in order to get
case-insensitive string lookup working right. Converted
to new formatting rules.
* gw/wsp-strings.h, gw/wsp-strings.def: Improved comments.
2000-09-27 Lars Wirzenius <>
* gw/wtp_state-decl.h: Removed handling of event RcvInvoke in
state RESULT_RESP_WAIT, since that was neither in the spec and
seems to do nothing useful.
2000-09-27 Lars Wirzenius <>
* gw/smsbox.c, gw/wapbox.c, doc/userguide/newconf.txt: Added
configuration variable http-proxy-exceptions.
2000-09-27 Tuomas Luttinen <>
* configure[.in]: Support for libxml1 removed, only 2.2.0 and
up now.
2000-09-27 Richard Braakman <>
* gw/smsc_emi.c: Correct calculation of message length for
UDH messages.
2000-09-27 Lars Wirzenius <>
* gw/wapbox.c: moved http-proxy-host and http-proxy-port into
"core" from "wapbox" section. (That's where they were for the
smsbox as well.) Also added the code that actually makes use
of the proxy support, by calling http_use_proxy.
* gwlib/http.c: Allow the list of exceptions to be NULL, to
simplify the case when no exceptions are wanted. Also report
when a proxy is being used.
2000-09-27 Richard Braakman <>
* gw/wsp.c: Encode all known content types, not just the
most common ones.
* gw/wsp-strings.def: s/applicatoin/application in one of
the content types.
2000-09-26 Lars Wirzenius <>
* gw/wap-appl.c: Added Via header to HTTP requests.
* gwlib/socket.[ch]: Wrote function get_official_name.
* gwlib/octstr.c: Don't call gwlib_assert_init, instead assert
that octstr itself has been initialized. This is necessary because
socket.c now needs to use octet strings before gwlib has been
fully initialized.
2000-09-26 Richard Braakman <>
* Making release 0.11.2.
2000-09-26 Lars Wirzenius <>
* gw/smsbox_req.c: smsbox used to dump core if the sendsms
username was incorrect, now it correctly returned authorization
failure. Fixes bug report 105 from Paul Keogh.
2000-09-26 Lars Wirzenius <>
* test/fakesmsc.c: Initialize the third parameter to accept
correctly. I wonder why this has ever worked.
2000-09-26 Kalle Marjola <>
* gw/smsbox_req.c, gw/urltrans.c: set so that message without any
content is passed to default service group, not ignored. Fixed
request count, too.
2000-09-25 Richard Braakman <>
* gwlib/conn.c: Make conn_read_line() work more than once.
Thanks to for reporting this.
* gw/wtp_send.[ch], gw/wtp_state-decl.h: Removed "event"
parameter from wtp_send_abort and wtp_send_ack. There were
assertions for this (otherwise unused) parameter which caused
the function to fail if the event was for example a timeout.
2000-09-25 Lars Wirzenius <>
* checks/ Check for "ERROR:" in log file.
* gw/html.h: Include gwlib/gwlib.h, not octstr.h.
* test/test_http.c: Add -q option.
* gwlib/http.c: Bugfix. Format string said %s when it should
have said %S.
2000-09-25 Kalle Marjola <>
* gw/smsbox*.*: activated sendsms-user allow/deny-ip strings
* gw/urltrans.c|h: appropriate modifications to that file
* doc/userguide/userguide.xml: started to write a new chapter
about SMS Kannel setup
2000-09-25 Kalle Marjola <>
* gw/bb_udp.c, gwlib/socket.c|h, test/test_udp.c: inserted
interface-name patch by Andreas Fink.
2000-09-25 Lars Wirzenius <>
* doc/userguide/newconf.txt: Added slightly better descriptions
from Paul Keogh for SMS2000 config variables.
2000-09-25 Kalle Marjola <>
* doc/userguide/userguide.xml, doc/userguide/newconf.txt: updated
to include notes about SMSC ID use.
* gw/bb_smsc.c, gw/smsc.c|h, gw/smsc_p.h: added preferred-id and
denied-id configuration variable for SMS routing
2000-09-25 Kalle Marjola <>
* gwlib/utils.c: added str_find_substr
* gw/urltrans.c|h: added 'smsc' to find_translations, and
forced-smsc, default-smsc and accepted-smsc for translation
groups. Accepted-smsc is now in full use, so if you need
sms-services linked to used SMSC, use it (and smsc-id for
corresponding SMSC)
* gw/smsbox_req.c: set smsc_id for send-sms requests
* doc/userguide/newconf.txt: added new attributes here
2000-09-25 Kalle Marjola <>
* gwlib/utils.c (get_and_set_debugs): fixed '--' parsing
2000-09-22 Kalle Marjola <>
* gwlib/utils.c: set that command line option '--' ends option
parsing. Thanks to Kari Lempiainen for finding this, although I
added one 'break' to it, too.
2000-09-22 Richard Braakman <>
* gw/timers.c: Correctly record elapse-event in gwtimer_start. Oops.
This also fixes a memory leak.
2000-09-22 Richard Braakman <>
* gwlib/protected.[ch]: Removed gw_getlocale(). Despite
protection, toggling locale settings is inherently not
* gwlib/date.[ch]: Started file for date handling functions.
Contains date_format_http(). It is a reimplementation of
rfc2068_date_format() but does not use setlocale trickery.
* Removed rfc2068_date_format() from gwlib/utils.[ch] and
made gw/wsp_headers.c call the new function.
2000-09-22 Richard Braakman <>
* gw/wsp-session.c: Corrected capabilities negotiation. This
is not the promised rewrite, and its replies are still longer
than they need to be, but it follows the standard now.
* gw/wsp_caps.[ch]: Added helper function wsp_cap_get_server_sdu.
2000-09-22 Kalle Marjola <>
* gw/smsbox_req.c: edited access log entries, now the HTTP request
status is logged etc.
2000-09-22 Kalle Marjola <>
* gw/smsbox.c: added opening/closing of access log
* gw/smsbox_req.c: added access log entries for requests (send-sms
and MO), and modified the entire MO SMS lifetime so that 'request
failed' replies to max-messages = 0 translations still get that
* gw/smsc.c|h: changed so that smsc_send_message does not destroy
the msg
* gw/bb_smsc.c: updated access log entry
* doc/userguide/newconf.txt: added access-log into
variables. Still missing smsc-id, as the implementation is not
2000-09-21 Kalle Marjola <>
* gwlib/accesslog.c|h: added first version of access log system
* smsc.c|h: added SMSC Id (a bit like name but user defined)
* gw/msg-decl.h: added SMSC Id to SMS messages
* gw/bb_smsc.c, gw/bearerbox.c: added access log entries for
incoming/outgoing SMS messages
* gw/smsbox_req.c: added 'smsc' entry for send-sms interface, but
not yet supported.
2000-09-21 Lars Wirzenius <>
* gwlib/http.c: Use octstr_case_search instead of
octstr_convert_range and octstr_search to check whether a URL
begins with "http://".
2000-09-21 Lars Wirzenius <>
* checks/check_octstr.c: Wrote.
* gwlib/octstr.[ch]: Wrote new function octstr_case_search.
2000-09-21 Lars Wirzenius <>
* gwlib/octstr.c: octstr_compare: Fixed behavior when either argument
was a zero length octet string. It used to always return zero,
now it returns -1 or 1 if the other argument is not a zero length
octet string.
* gwlib/octstr.[ch]: Wrote octstr_case_compare.
2000-09-21 Lars Wirzenius <>
* gwlib/octstr.c: Reformatted to new code layout.
2000-09-21 Lars Wirzenius <>
* gw/wapbox.c: Start the WAP application layer before the
heartbeat thread. This prevents a race condition at startup.
2000-09-21 Richard Braakman <>
* gw/timers.c: In TimerHeap struct, rename "heap" field to "tab".
There's something confusing about heap->heap[index].
* gw/timers.c: Simplified main loop in the timer thread.
Made it process all elapsed timers before releasing its lock
-- should be faster if a bunch of timers elapse at once.
2000-09-20 Richard Braakman <>
* gw/wsp_headers.c: Try to skip over unknown code pages more
2000-09-20 Richard Braakman <>
* gw/timers.[ch], gw/wtp.c: Renamed timer_* to gwtimer_* to
avoid name conflict with system functions. Sigh.
2000-09-20 Richard Braakman <>
* gw/timers.c: Reformatted according to new layout standard.
2000-09-20 Richard Braakman <>
* gw/timers.c: Implement the heap structure using a C array,
instead of using List. This has less overhead and removes the
need for list_swap.
* gw/list.[ch]: Remove list_swap.
2000-09-20 Richard Braakman <>
* gw/timers.[ch]: Removed timersets from the interface. The choice
of what timers should be handled by a single thread is a performance
issue, not an interface issue. All timers are now handled by a
single timer thread. The choice of output list is now specified
per timer, instead of per timer set.
Added timer_init and timer_shutdown functions that should be
called before creating any timers.
* gw/wapbox.c, gw/wtp.c: Adjust to new timers interface.
2000-09-19 Richard Braakman <>
* gw/timers.c, gw/timers.h: New timers. Faster, better, and
they actually time out.
* gw/wtp_timer.c, gw/wtp_timer.h: Removed. (Remnants of old
timer code).
* gw/wapbox.c: Removed references to old timer code. It's now
completely hidden in the wtp layer. Other layers can get their
own timers.
* gw/wtp.c: Use new timers. Added some convenience functions
(start_timer_A and start_timer_R). Handle TimerTO_* events.
There's no start_timer_W yet because we don't use it yet.
* gw/wtp.h: Use new timers.
* gw/wap-events-def.h: TimerTO_* events get a machine handle
instead of a dummy field, so that the WTP layer knows which
machine timed out.
* gw/wtp_state-decl.h: Use new timers, by calling the
convenience functions. There's no real timer code left in
the state machines.
* gw/list.c, gw/list.h: Made list_delete_matching and
list_delete_equal return the count of items deleted.
Getting that info from an atomic operation is useful
for the timer code. Also added list_swap function.
2000-09-19 Richard Braakman <>
* gw/wtp.[ch], gw/wtp_machine_decl.h: Removed unused field
type LIST from state machines.
2000-09-19 Lars Wirzenius <>
* gwlib/list.[ch]: Removed list_cat function, as it is now unused.
2000-09-19 Tuomas Luttinen <>
* gw/wml_compiler.c: Added wml_init and wml_shutdown that do nothing
yet, removed call to list_cat.
* gw/wml_compiler.h: Added prototypes for wml_init and wml_shutdown.
2000-09-18 Richard Braakman <>
* gw/smsc_smpp.c: Make charset_iso_to_smpp and charset_smpp_to_iso
work with character values > 128. Bugfix suggested by
Philip Chr. Psiloinis.
2000-09-18 Lars Wirzenius <>
* doc/CodingStyle: Added example of coding style.
2000-09-18 Lars Wirzenius <>
* ChangeLog, debian/init, gw/bb_boxc.c, gw/bb_http.c, gw/html.h,
gw/msg.c, gw/urltrans.c, gwlib/conffile.c, gwlib/conffile.h,
gwlib/gwassert.h, gwlib/gwstr.h, gwlib/gwthread-pthread.c,
gwlib/http.c, gwlib/http.h, gwlib/list.c, gwlib/list.h,
gwlib/log.h, gwlib/octstr.c, gwlib/octstr.h, gwlib/socket.c,
gwlib/thread.c, gwlib/thread.h, gwlib/utils.c: Folded some long
lines (see utils/find-long-lines).
2000-09-18 Lars Wirzenius <>
* gwlib/octstr.c: Shut up char/unsigned char implicit conversion
warning by adding a cast.
2000-09-18 Derry Hamilton <>
* gwlib/thread.h: changed the call to mutex_init_static_real
to actually pass the mutex when MUTEX_STATS are required.
2000-09-18 Kalle Marjola <>
* gwlib/utils.c (get_and_set_debugs): PANIC if unknown option is
encountered, to avoid misuse of options.
2000-09-18 Kalle Marjola <>
* gw/bb_http.c (httpd_serve): when receiving an unknown command,
tells the received url back to caller
2000-09-18 Kalle Marjola <>
* gw/smsbox.c (init_smsbox): fixed bug reported by Paul Keogh.
* gw/bearerbox.c: some fix to shutdown order
2000-09-14 Lars Wirzenius <>
* utils/source-stats: Wrote.
2000-09-14 Lars Wirzenius <>
*,, configure, gwlib/socket.[ch],
gwlib/getnameinfo.h: Killed the getnameinfo implementation. Yet
another non-standard function that we don't even refer to anymore.
2000-09-14 Lars Wirzenius <>
* gwlib/log.[ch]: Removed the `forced' log level, since it is
pointless and unused.
2000-09-14 Lars Wirzenius <>
*, configure,, gwlib/utils.[ch]: Always
use kannel_cfmakeraw, instead of the libc one. This simplifies
configuration, and lets us not have to worry about having another
cfmakeraw in a non-glibc library that does something else than
the glibc one. Or about the glibc one changing behavior sometime
in the future. (Oh the joys of using extensions to the standard
2000-09-14 Lars Wirzenius <>
* gw/wap-appl.c, gw/wsp.h: Added function wap_appl_get_load,
which gives a current load average for the application layer
(which is essentially the only sensible place to look for load
averages), defined as the sum of the length of request queue
and number of HTTP fetches that are currently happening. The
old getloadavg method is deleted, but if this one proves to be
completely unworkable, we can always salvage the code from CVS. On
the other hand, this method actually works on systems that don't
have a getloadavg, and works even on systems where getloadavg
is defined differently (imagine running two different wapboxes).
* gw/wapbox.c: Use wap_appl_get_load instead of getloadavg.
* configure{,.in}: Removed checks for getloadavg.
2000-09-14 Lars Wirzenius <>
* gwlib/http.c: Ran through astyle to get formatting right.
2000-09-14 Lars Wirzenius <>
* gwlib/http.c: Removed internal function octstr_str_ncompare,
replacing it with calls to octstr_search and
octstr_create_immutable. Die *_cstr, die!
2000-09-14 Lars Wirzenius <>
* gwlib/octstr.[ch]: Added `pos' argument to octstr_search to
let caller specify from where the search in the haystack starts.
Also, octstr_format now understands %c.
* gw/html.c, gw/smsc_at.c, gw/wap-appl.c, gw/wsp_headers.c,
gwlib/http.c, gwlib/octstr.c, test/drive_wapbox.c,
test/test_cimd2.c: Use octstr_search instead of octstr_search_cstr
and various functions instead of octstr_append_cstr.
* gw/wml_compiler.c: Fix call to octstr_search.
2000-09-14 Lars Wirzenius <>
* gwlib/octstr.[ch]: Removed the octstr_create_limited, because
it had so limited use.
2000-09-14 Lars Wirzenius <>
* test/test_http_server.c: Catch SIGTERM and die immediately.
* checks/ Wrote.
2000-09-14 Lars Wirzenius <>
* gw/smsbox.c, gw/wapbox.c, doc/userguide/newconf.txt: Added
HTTP proxy support to configuration files. No way to test it,
right now, but will eagerly await bug reports.
2000-09-14 Lars Wirzenius <>
* gwlib/list.c: Don't do the atomic operation locks for list_lock
and list_unlock: they're unnecessary for atomicity and cause
deadlocks. Thanks to Kalle Sandström for noting this.
* gwlib/octstr.c: Silence compiler warning regarding using a plain
char as an index to an array (in reality, argument to isdigit),
by typecasting a pointer. If we used fewer C strings, this would
be less of a problem...
2000-09-11 Lars Wirzenius <>
* README: Fixed download URL, re-formatted and removed the
outdated claim that it is a very raw draft.
* doc/CodingStyle: Added note about the official formatting style,
as discussed on Also added a note about memory
allocation policy as far as function interfaces are concerned,
a note to avoid #if, and something about abstract data types
and naming conventions related to that.
* doc/dialup.txt,,,
doc/arch/arch-bearerbox.xml, doc/arch/arch-bib.xml,
doc/arch/arch.xml: Shortened long lines.
* gwlib/list.[ch]: Changed the interface of the list_destroy
function by adding a second argument, which is a pointer to an
item destroying function.
* checks/check_list.c, gw/cookies.c, gw/bb_boxc.c, gw/bb_smsc.c,
gw/bearerbox.c, gw/numhash.c, gw/smsbox.c, gw/smsbox_req.c,
gw/smsc.c, gw/smsc_cimd2.c, gw/urltrans.c, gw/wap-appl.c,
gw/wapbox.c, gw/wml_compiler.c, gw/wsp-session.c, gw/wsp-unit.c,
gw/wsp_caps.c, gw/wtp.c, gw/wtp_pdu.c, gw/wtp_tid.c,
gw/wtp_timer.c, gwlib/http.c, gwlib/parse.c, test/drive_wapbox.c,
test/test_cimd2.c, test/test_http.c, test/test_http_server.c:
Updated calls to list_destroy to work with its new interface.
* gw/msg.[ch], gw/wap-events.[ch]: Added functions *_destroy_item,
for use with new list_destroy.
* gw/wap-appl.c: Add X-WAP-Client-SDU-Size header.
* gwlib/octstr.[ch]: Added functions octstr_format and
octstr_format_append. Also added "immutable octet strings",
for wrapping around C string literals, which required adding
octstr_init and octstr_shutdown. See the header for more info.
Also added some consts here and there.
* gwlib/gwlib.c: Call octstr_init and octstr_shutdown.
* test/test_octstr_format.c, test/test_octstr_immutables.c: New
test programs.
2000-09-04 Richard Braakman <>
* gw/wapbox.c, gw/smsbox.c, gw/bearerbox.c: Handle only signals
for the main thread, so that each signal is received exactly once.
2000-09-04 Richard Braakman <>
* Changes prompted by code review:
* gwlib/gwthread.h, gwlib/gwthread-pthread.h: Rename Threadfunc
to gwthread_func_t.
* gwlib/parse.h, gwlib/parse.c, gw/wsp_headers.c: Rename Context
to ParseContext.
* gwlib/gwmem-check.c: Give symbolic names to the memory-filling
patterns it uses.
* gwlib/conn.h: Improve comments.
2000-09-04 Richard Braakman <>
* Making release 0.11.1.
2000-09-04 Derry Hamilton <>
* gw/wml_compiler.c: reformatted my earlier patch.
2000-09-03 Lars Wirzenius <>
* gw/wml_compiler.c: Removed unnecessary call to gw_assert:
list_create is defined as always returning non-NULL, so it's not
necessary to check it. (Or if we do, we should check it everywhere.)
* gwlib/list.c: Removed unused variable from lock(). Also
re-did the change to list_len in my own coding style, just to
be pedantic.
* I assume these were leftovers from Derry's debugging.
2000-09-01 Derry Hamilton <>
* gwlib/list.c: Added a test for NULL list to list_len since some
things want the length of NULL lists.
* gw/wml_compiler.c: string_table_build no longer tries to add
strings to the stringtable if the list is NULL.
2000-08-31 Lars Wirzenius <>
* wmlscript/wsencode.c: Added a typecast to convert a va_arg call
that fetches an int to convert the value to an unsigned char *.
2000-08-31 Lars Wirzenius <>
* gwlib/http.c: Improved (but still did not write properly) HTTP
Content-Type header parsing. Fix suggested by Joerg Pommnitz,
though re-did the patch to add some error checking.
* test/test_http.c: Parse and report Content-Type. Also, http_get_real
now wants a non-NULL request header list. Give it that.
* test/test_http_server.c: Report a character set (UTF-8, though
it doesn't really matter) so that the parsing can be tested.
2000-08-31 Lars Wirzenius <>
* Tweaked the libxml checking. It should now be
slightly cleaner and should work with upcoming 2.2.x versions
of the library without changing Thanks to Geir
Johannessen, whose mail prompted me to look at this, even though
I didn't use his patch directly.
2000-08-31 Lars Wirzenius <>
* gw/wsp.[ch]: Minor cleanups: Removed unused constants, added
a comment for assertions, etc.
2000-08-31 Lars Wirzenius <>
defines from .h to .c, since they're only used inside .c.
* gw/wsp-method-state.h: Formatting change (comments should be
indented similarly to the code they describe). Also, bug fixes:
several comparisons had a single equals (i.e., assignment)
instead of two (i.e., comparison).
2000-08-31 Lars Wirzenius <>
* gw/wapbox.c, gw/log.c: Moved syslog opening internals to log.c,
where it belongs. Introduced new function set_syslog to do this.
* gw/log.c: Cleaned up formatting, etc, a bit. syslog support
(internals of kannel_syslog (now static, btw)) is compiled on
all platforms, not just SunOS.
* gw/log.h: Added note that opening and closing of log files is
not thread safe.
2000-08-31 Lars Wirzenius <>
* gwlib/list.[ch]: Some further cleanups:
- list_delete_all and list_extract_all were named in a
misleading way; renamed to *_matching instead, and all
calls fixed as well; argument `cmp' renamed to `matches'
for clarity's sake
- some assertions uncommented and fixed to compare a
pointer explicity to NULL, instead of implicitly
- code changed to call delete_items_from_list, instead of
doing the same thing manually
- list_lock and list_unlock use the single-operation lock
* checks/check_list.c, gwlib/http.c: Related changes.
2000-08-31 Lars Wirzenius <>
* gwlib/list.c: list_len is now protected by locks.
2000-08-31 Lars Wirzenius <>
* test/test_list.c: Removed.
* checks/check_list.c: Wrote.
2000-08-30 Lars Wirzenius <>
* gw/bb_udp.c, gw/cookies.c, gw/html.c, gw/msg.c,
gw/smsbox_req.c, gw/smsc_at.c, gw/smsc_cimd2.c, gw/smsc_ois.c,
gw/smsc_sema.c, gw/smsc_smpp.c, gw/wap-appl.c, gw/wml_compiler.c,
gw/wsp-session.c, gw/wsp-unit.c, gw/wsp.c, gw/wsp_caps.c,
gw/wsp_headers.c, gw/wsp_pdu.c, gw/wtp_pdu.c, gwlib/conn.c,
gwlib/http.c, gwlib/http.h, gwlib/octstr.c, gwlib/octstr.h,
gwlib/parse.c, gwlib/socket.c, test/fakewap.c, test/test_cimd2.c:
Cleanups based on a (brief) code review. Lots of small changes
pretty much everywhere, but nothing really big.
* Renamed octstr_search_*_from to octstr_search_*, because there's
no point in having two almost equivalent functions.
* Renamed octstr_*_blank to octstr_*_blanks, to be grammattically
* Killed octstr_create_empty, replaced it with octstr_create("").
* Other minor differences, see the diff if you're interested.
2000-08-30 Tuomas Luttinen <>
* gw/wml_compiler.c: The octet string memory leaks in the string table
code plugged.
2000-08-29 Tuomas Luttinen <>
* gw/wml_compiler.c: Plugging the huge memory leaks of the string
table code started. No more leaks due lists or mutexes. Some leaks
with octstr:s also plugged, some still remain.
2000-08-28 Tuomas Luttinen <>
* gw/wml_compiler.c: The patch by Aarno was removed because it caused
problems like "WARNING: WSP: All converters for `text/vnd.wap.wml'
failed.", segmentation fault on variables and maybe others.
2000-08-26 Derry Hamilton <>
* solaris/ Now compiles for a bare
Solaris 7 box, doesn't assume LD_LIBRARY_PATH
2000-08-24 Kalle Marjola <>
* gw/bb_udp.c (udp_receiver): trap ECONNREFUSED too (hey it was
missing from Man page) and just continue
* gw/bb_boxc.c: extend wapbox_list lock to prevent packet routing
to exiting wapboxes
2000-08-23 Richard Braakman <>
* gw/wap-appl.c: Make sure content.url and content.body have valid
values even if request method is not supported.
* gw/wsp_pdu.c, gw/wtp_pdu.c: Make sure REST fields are always
filled, even if packet contains bad length info. This fixes a
crashing bug discovered by OUSPG.
* test/fakewap.c: Fix small memory leak.
* test/udpfeed.c: New test program, reads a bunch of files and
sends each in a single UDP packet. Useful for feeding OUSPG's
test set to Kannel.
* gw/wapbox.c: Catch SIGQUIT and use it to report memory usage.
Useful for detecting memory leaks.
* gw/gwmem-check.c: Bugfix to allow gw_check_leaks() to be called
multiple times in one run.
* gw/wsp-unit.c: Fix memory leaks.
2000-08-22 Aarno Syvänen <>
* gw/wml_compiler.c: Fixed some memory leaks
2000-08-22 Derry Hamilton <>
* solaris/etc/kannel.conf: By default do not permit admin connections
Mon Aug 21 18:39:30 2000 Lars Wirzenius <>
* test/test_counter.c: Removed, as this is now replaced by
Mon Aug 21 18:32:04 2000 Lars Wirzenius <>
* README, Added some automatic checking as "make
check". See the README for more info.
* utils/run-checks, checks/*: New files.
2000-08-21 Paul Keogh <>
* gwlib/counter.[ch]: Added counter_set method.
2000-08-18 Richard Braakman <>
* gwlib/gwthread-pthread.c: In gwthread_shutdown, don't delete
the tsd_key. It's still needed by gwthread_self(), which can
still be called. This might fix the problem of wapboxes that
refuse to die.
* gw/wsp-strings.c: Make wsp_##name##_to_string not crash if
the string was not found.
* gw/wsp_headers.c: Have unpack_all_parameters() stop at
the end of its string, rather than reporting a bogus error.
Also fixed a memory leak in header unpacking.
2000-08-18 Derry Hamilton <>
* solaris/ Changed default optimisation level.
* solaris/etc/kannel.conf: Kannel needs an admin port to start
2000-08-16 Derry Hamilton <>
* solaris/*: Added packaging information for Solaris
2000-08-14 Peter Grönholm
* gw/wml-definitions.h: A typo corrected in URL value code table.
Now URLs ending with .net/ work, too. Two other typos: Content-
Type and Expires use capital letters.
2000-08-10 Tuomas Luttinen <>
* gw/wml_compiler.c (check_variable_syntax): Escaping now possible
with one letter acronyms 'e', 'u' and 'n'.
2000-08-07 Tuomas Luttinen <>
* gw/wml_compiler.c: A little bit of code cleaning, changing return
types to null where a status is not needed.
2000-08-06 Derry Hamilton <>
*, wmlscript/wsencode.c: Fixed the WMLScript compiler
errors under Solaris SPARC. The SPARC ABI requires that function
parameters be int aligned.
2000-08-04 Tuomas Luttinen <>
* test/decompile.[ch]: A patch by Chris Wulff applied.
* gw/wml_definitions.h: STRING_TABLE_MIN defined
* gw/wml_compiler.c: The first attemp to use string table more
efficiently. For a reason or another hangs up when compiled with
checking-malloc on the check phase into a allocation lock.
* gw/wml_compiler.c: The patch to fix a bug in the libxml-1.8.6 is
* configure[.in]: The flag HAVE_LIBXML_1_8_6 is removed, now takes
only 1.8.7 and up.
2000-08-04 Richard Braakman <>
* gw/wap-appl.c: In X-WAP-Gateway header, use "Kannel/0.11"
instead of "Kannel 0.11", to comply with HTTP/1.1 recommendations
for version strings.
2000-08-02 Richard Braakman <>
* Making development release 0.11.
2000-08-02 Richard Braakman <>
* Applied Joerg Pommnitz's patch for Crypto library support in
the WMLScript compiler.
2000-08-02 Richard Braakman <>
* Folded in POST_SUPPORT. Duplication of code is Bad.
2000-08-01 Richard Braakman <>
* gw/smsc_cimd2.c: Be forgiving of cimd2 calls while the
socket is not open. This is necessary because of the
changed thread structure in the new bearerbox.
2000-08-01 Richard Braakman <>
* gw/smsbox_req.c: When logging "message sent", use errno 0
instead of 1. (?)
* doc/userguide/newconf.txt: Change recommended unified-prefix
string for Finland, because smscenters no longer accept "00"
prefix as of today.
2000-08-01 Richard Braakman <>
* gw/smsc_cimd2.c: When complaining about format of sender number,
actually log the sender number rather than the receiver number.
2000-07-27 Richard Braakman <>
* gw/smsc_cimd2.c: When pending_smsmessage receives an unexpected
response packet, report it instead of crashing.
2000-07-24 Richard Braakman <>
* gw/wsp_headers.c: Mostly rewritten. Now decodes all header
types defined by WSP 1.1. This means that the headers sent
by the phone are all passed to the HTTP server. Previously,
only a few commonly-appearing ones were (partially) decoded.
Uses wsp-strings.def instead of inlined string tables.
Uses new gwlib parse module to scan octstr contents.
"Works for me" status. Will be more thoroughly tested after
the decoding code is complete.
* gw/wsp_headers.h: Changed interface of unpack_headers.
It now takes a content_type_present flag parameter, instead
of having a separate unpack_post_headers function.
* gw/wsp-strings.c: Support for NUMBERED tables, which assign
non-sequential numbers to the strings in a table.
* gw/wsp-strings.h: Support for NAMED tables, which assign an
enum value to each entry in a string table.
* gw/wsp-strings.def: Define lots of new string tables, for use
by the wsp_header module.
* gw/wapbox.c: Init and shutdown newly used wsp-strings module.
* gw/wsp-method-state.h, gw/wsp-session-state.h, gw/wsp-unit.c:
Use new unpack_headers interface.
* gwlib/octstr.c: In octstr_insert, assert that ostr2 is not
inserted past the end of ostr1. (This assumption was already
there; it's just made explicit now.)
Removed unused octstr_get_digit_from function. octstr_parse_long
does the same thing.
New octstr_append_decimal function.
* gwlib/protected.c, gwlib/protected.h: Added gw_getlocale,
for use by rfc2068_date_format function.
* gwlib/utils.c, gwlib/utils.c: New rfc2068_date_format function,
to convert a unix timeval to a common textual format. (The RFC2068
format also fits the RFC822 format).
* gwlib/parse.c, gwlib/parse.h: New module to make it easier to
parse octstrs without passing lots of length and offset variables
* gwlib/gwlib.h: Include new parse.h. Move inclusion of protected.h
to end, so that it can use Octstr in its function prototypes.
2000-07-24 Tuomas Luttinen <>
* gw/smsbox_req.c: Removed function smsbox_req_sendota that used
nonexistent octstr-function so that the CVS version didn't compile.
2000-07-23 Tuomas Luttinen <>
* configure.[in]: libxml 2.2.1 added.
2000-07-21 Paul Keogh <>
* gw/bb_udp.c: Added check for NULL ptr return from udpc_create()
in function add_service() to prevent subsequent NULL dereference
and crash.
2000-07-21 Yann Muller <>
* gw/smsbox_req.c, smsbox_req.h: messages with or without UDH are
now handled in the same way, they can all be sent as multiple
messages or concatenated messages if too long.
* gw/smsc_at.c: Receiver address fix by Paul Keogh and Marcus
Shawcroft. Better support for UDH.
* gw/urltrans.c, urltrans.h: Added the concatenation option for
SMS messages.
* doc/userguide/newconf.txt, userguide.xml: Added a note about the
concatenation and removed the limitation about UDH.
2000-07-20 Richard Braakman <>
* gw/wtp.c: Fixed memory leak in wtp_unpack_wdp_datagram.
Simplified the code a bit.
* gw/wtp.c: Made wtp_unpack_wdp_datagram_real not crash when
receiving an invalid PDU.
* gw/wtp_pdu.c: In wtp_pdu_unpack, simply free a PDU with
unknown type instead of trying to destroy it. None of its
fields were set anyway.
* test/fakewap.c: Actually test separation when -s flag is given.
The test is wrong, though, it sends bad packets. Not going to
fix that now.
2000-07-19 Tuomas Luttinen <>
* configure[.in]: libxml 1.8.9 and 2.2.0 added. Fixes bug #97.
2000-07-18 Richard Braakman <>
* gw/html.c: Fix skipping of quoted strings (bug #89, reported
by Paul Keogh).
* gw/smsbox.c: Avoid memory leak in http_request_thread().
Fixes bug#101, reported by Paul Keogh.
2000-07-18 Richard Braakman <>
* gw/smsc_ois.c: Fixed some warnings.
2000-07-18 Kalle Marjola <>
* gwlib/gwthread-pthread.c, gwlib/http.c: Fized bugs #98 and #100
reported by Paul Keogh.
2000-07-18 Paul Keogh <>
* gw/urltrans.c: Fixed memory leak in destroy_onetrans().
2000-07-17 Paul Keogh <>
* gwlib/counter.[ch]: Added counter_decrease() function.
2000-07-15 Derry Hamilton <>
*,configure, Removed checks for integer
lengths as it broke more than it might have fixed.
2000-07-14 Paul Keogh <>
* gwlib/http.c: Fixed a bug in the HTTP POST which prevented interop
with some versions of Apache and ultimately crashed.
2000-07-13 Derry Hamilton <>
* gw/wapbox.c,gw/wapkannel.conf,gwlib/log.c: first implementation of
syslog support under Solaris.
2000-07-13 Kalle Marjola <>
* */*: Making out release 0.10.2
2000-07-13 Tuomas Luttinen <>
* gw/wml_compiler.c (wml_compile): Compiler now checks that the
output from libxml is not a NULL pointer.
2000-07-13 Derry Hamilton <>
*,configure, configure now checks for the
32-bit type and defines kint32 and kuint32 as appropriate in
preparation for 64-bit kannel on Alpha and UltraSPARC since the
compiler types int32 and uint32 are not supported everywhere.
* gwlib/http.h: Added the function definition for
http_charset_accepted rather than leaving it to be implicitly
2000-07-13 Yann Muller <>
* gw/smsc_at.c: removed two unused variables.
2000-07-12 Tuomas Luttinen <>
* gw/wml_compiler.c: Little bug fixes with variables:
- no more empty string before variable reference to string table
- double $ won't eat a character after them, fixes #94
- a little memory leak mentioned below corrected
2000-07-12 Kalle Marjola <>
* gw/bb_http.c: oops, return value for HTTP admin was not checked,
now fixed
* gw/bearerbox.c: added compiler options KANNEL_NO_SMS and
2000-07-11 Tuomas Luttinen <>
* gw/wml_compiler.c: Bug #86 fixed. A memory leak with $ characters
fixed. Another one still remains with mix of $ characters and
2000-07-11 Yann Muller <>
* doc/userguide/newconf.txt: Added configuration information to use
a GSM modem as an SMSC.
2000-07-10 Yann Muller <>
* gw/smsc_at.c: now removes SMSC address at beginning of PDU sent
by the Wavecom. Better handling of messages with UDH (no 7bit encoding
of UDH yet).
2000-07-10 Kalle Marjola <>
* gw/urltrans.c (find_translation): fixed string matching of
2000-07-07 Tuomas Luttinen <>
* configure: Now support for libxml 1.8.8 and 2.1.1.
* gw/wml_compiler.c: Support for libxml version 2 and above
now ready.
* gw/wml_compiler.c (parse_attribute): Patch by Holger Casties
applied to eliminate a segmentation fault with NULL pointer
passed as a second argument to strcmp.
2000-07-07 Kalle Marjola <>
* doc/dialup.txt: updated to reflect current configuration, and
added data on how to get it work with Siemens S25i from Matthias Wutke
2000-07-07 Aarno Syvänen <>
* gw/wtp.c: Bugfixes in the separation code
* test/fakewap.c: Added sending of a concatenated message, for testing
2000-07-07 Kalle Marjola <>
* gw/bb_boxc.c: hopefully fixed a little bug/feature in connection
2000-07-06 Richard Braakman <>
* Making release 0.10.1.
* Extended NEWS. Removed NEWS.devel, we won't need it until
we start on 0.11.
2000-07-06 Kalle Marjola <>
* gw/smsc_ois.c: (hopefully) fixed warnings from FreeBSD
2000-07-06 Kalle Marjola <>
* gw/bearerbox.c: added --suspended and --isolated command-line
option names (same as -S and -I)
* gw/smsbox.c: fix in command line parsing
* doc/userguide/newbb.conf: added data on those new options
2000-07-06 Kalle Marjola <>
* gw/smsbox.c: modified so that if the HTTP-sendsms interface is
defined, the smsbox won't start if it fails to init it. Use new
command line option -H or --tryhttp to override this feature
2000-07-05 Kalle Marjola <>
* doc/userguide/newconf.txt: oops, forgot admin-username. And
returned sample smsc-groups
* gw/smsc.c, gw/smsc_p.h, gw/smsc_ois.c: Added support for SEMA
SMS2000 (G6.0) OIS 5.0 over X.25, under name OIS, by Jouko Koski.
2000-07-03 Richard Braakman <>
* gw/wml_definitions.h: Applied patch by brennon loh york hong
to fix compilation of pages with multiselect.
2000-07-03 Paul Keogh <>
* gwlib/http.c,gwlib/http.h,gw/wsp_headers.h,gw/wsp_headers.c,
gw/wap-appl.c: Added support for HTTP POST under #ifdef POST_SUPPORT.
Also enabled runtime cookies under #ifdef COOKIE_SUPPORT.
2000-06-30 Aarno Syvänen <>
* wsp-unit.c: Fixed some memory leaks
2000-06-30 Aarno Syvänen <>
* wtp_tid.c|h, wtp_state-decl.h: Tid was not cached when tid
verification was invoked because of a failed tid validation test.
So after every validation all following tids were verified. Added
to the the module wtp_tid an external function wtp_tid_set_by
machine, which stored tid after validation.
2000-06-30 Richard Braakman <>
* gw/wml_compiler.c: In parse_octet_string, one extra byte was
skipped after a variable reference, including the special "$$"
sequence. Fixed.
2000-06-30 Richard Braakman <>
* gwlib/http.c: Change some of the locking according to Joerg
Pommnitz's suggestions, to deal more smoothly with slow connects.
2000-06-30 Derry Hamilton <>
* made .depend depend on config.h. This should
allow changing between checked and unchecked malloc without manual
2000-06-30 Richard Braakman <>
* gwlib/gwmem-check.c: Fix call to free() in drop_from_free_ring().
This fixes a memory leak.
2000-06-29 Paul Keogh <>
* gwlib/list.c: Removed unnecessary calls to lock() and unlock()
in the list_cat() function as the called functions do the
required locking. Locking the same lock twice causes a panic().
2000-06-29 Richard Braakman <>
* gw/wsp-session.c: Fixed memory leak in new capability code.
2000-06-29 Richard Braakman <>
* gw/wap-appl.c: Applied fix suggested by Lim YoungLan, to make
sure S-MethodInvoke.res is sent before any S-MethodResult, even
if fetch_thread() is very fast.
2000-06-28 Richard Braakman <>
* wmlscript/wsstdlib.c: Applied Joerg Pommnitz's patch to support
WTAI standard library function calls, after converting it to the
local indentation style.
2000-06-27 Kalle Marjola <>
* doc/userguide/userguide.xml: did some updating, still needs to
integrate newconf.txt and newbb.txt into it, but that some other
2000-06-27 Paul Keogh <>
* gw/cookies.c: Added a check for valid WSP session machine to prevent
possible crash.
2000-06-26 Derry Hamilton <>
* gw/cookies.c: casted char to int for several isspace() etc. calls.
Stops the compiler complaining under Solaris.
2000-06-26 Kalle Marjola <>
* Making out stable release 0.10, branched as 'release_0_10'
2000-06-26 Kalle Marjola <>
* gw/smsc_smpp.c: small fix by Mikael Gueck
2000-06-21 Kalle Marjola <>
* gw/bb_boxc.c: added on-line information about connected boxes in
status query
2000-06-20 Kalle Marjola <>
* README: added notes of what need to be done if Kannel version is
upgraded from some old version
2000-06-20 Kalle Marjola <>
* Making out development release 0.9.3, canditate as production
release 0.10
2000-06-20 Kalle Marjola <>
* gwlib/utils.c, gwlib/utils.h: moved #ifdef of cfmakeraw into
header file so that it will compile in (my) system with cfmakeraw
* gw/bb_boxc.c: updated output information of bocx_status
* gw/bb_smsc.c: fixed compiler warning
2000-06-19 Kalle Marjola <>
* gw/bb_boxc.c: fixed one very-infrequently striking lockout
during shutdown
* README.docbook: user --disable-docs, not --without-docs
2000-06-19 Derry Hamilton <>
* gw/wsp-session.c: included limits.h to get LONG_MAX
* gwlib/utils.c,gwlib/utils.h: created kannel_cfmakeraw()
* gw/smsc_emi.c: removed cfmakeraw stub
* gw/smsc_emi.c,gw/smsc_at.c,gw/smsc_sema.c: converted calls to
cfmakeraw to kannel_cfmakeraw.
2000-06-19 Kalle Marjola <>
* gw/wsp-session.c, gw/wsp_pdu.c: inserted patch from Joerg
Pommnitz, now Kannel hopefully works better with Motorola
2000-06-19 Kalle Marjola <>
* gwlib/http.c: parse_url() modified to change start of the url
tolower() so that comprasion to http:// succeeds even with
2000-06-19 Kalle Marjola <>
* gw/bb_smsc.c: added suspend-mode to sms_router to synchronize
2000-06-19 Yann Muller <>
* gw/smsc.c, gw/smsc_p.h, gw/smsc_at.c: Applied Denis Hennessy's
patch to support Siemens M20: connect at 19200 baud, added a
'pin = xxxx' entry to the conf file, fixed missing trailing
null char in encode_pdu, added a dummy receiver address since
smsbox requires one, added the dummy "00" SC prefix for the M20
(like the wavecom).
2000-06-17 Richard Braakman <>
* Replaced capabilities parsing. New file gw/wsp_caps.[ch] defines
a structure to represent capabilities, and some operations on it.
WSP layer passes capability requests up to the Application layer,
which can respond to some and ignore others. WSP layer then completes
the capabilities reply when it generates the ConnectReply PDU.
See negotiate_capabilities() function in wap-appl.c for more info.
* Added CAPABILITIES type to wap-events and wsp-session-machine.
* Added request_caps and reply_caps fields to WSP session machine,
removed most of the other capability-related fields except
client_SDU_size and MOR_push (which are the only ones we support
and need to remember).
* gwlib/octstr.[ch]: New function octstr_extract_uintvar.
* gw/wsp-session.c: unpack_caps, unpack_uint8, and unpack_uintvar
* Removed unused SESSION_MACHINE type from wap-events.
* test/drive_wapbox: Supply the same capability values as the
Motorola Timeport does, for testing.
* Corrected:
gw/cookies.c:88: warning: char format, Octstr arg (arg 3)
2000-06-17 Richard Braakman <>
* test/drive_wapbox.c: Defined wtp_types enum, because we can
no longer steal the values we need from wtp.h.
2000-06-16 Aarno Syvänen <>
* wtp.c: Fixed bug pointed out by Joerg Pommnitz
* removed debug functions
* wtp.c | wapbox.c: Code for separation added. Must test it ...
2000-06-16 Kalle Marjola <>
* gw/cookies.c: changed strnicmp to strcasecmp, as nicmp is not
supported in standard C libraries
* gw/urltrans.c: fixed find-operations
* gw/bb_smsc.c: added smsc_status
2000-06-16 Yann Muller <>
* gw/smsc.c, gw/smsc_p.h: Added modemtype configuration parameter
for the AT SMSC.
* gw/smsc_at.c: Added support for Nokia PremiCell GSM modem.
The parameter modemtype in kannel.conf can be set to 'wavecom'
or 'premicell'.
2000-06-16 Paul Keogh <>
* gw/cookies.c: updates after review by Richard Braakman. Also some
additional includes.
* gw/cookies.h: As for cookies.c
* gw/wsp-session-machine.h: Added COOKIES field to session MACHINE
* gw/wsp-session.c: Added cookie support to machine_create(),
machine_destroy (). Also added id_belongs_to_session() function
for use by cookie functions.
* gw/wsp.h: Added cookie support to struct WSPMachine.
2000-06-15 Kalle Marjola <>
* gw/smsbox_req.c: fixed bug in http2-conversion, and set that
'request failed' is send back to the phone (no more 'nothing')
2000-06-15 Richard Braakman <>
* gw/wsp-strings.*: Interface for tables of constant strings defined
in WSP. Not used yet.
* gw/wsp-session.c: Got rid of append_uint8 and append_octstr; use
basic octstr functions instead.
2000-06-15 Richard Braakman <>
* gw/wap-appl.c: In fetch_thread(), explicitly set content.charset
to an empty octstr if the http fetch failed, otherwise it remains
uninitialized and causes a crash when octstr_destroy is called on it.
Thanks to Paul Keogh for finding this.
* gw/wsp-session.c: In wsp_disconnect_other_sessions(), use
"Disconnect_Event" instead of "Disconnect". The latter is a PDU
type, not an event type. Thanks to Paul Keogh for finding this.
2000-06-15 Aarno Syvänen <>
* wtp.c: Bugfixes in error handlin
* wtp_pdu.c: wtp_pdu_unpack must return NULL when header is not valid
2000-06-14 Richard Braakman <>
* Filled in WSP state tables. Defined lots of new events.
Sanitized event routing: WTP to WSP events get an addr_tuple.
WSP to WTP events get a "handle" (as defined in the spec) which
happens to be equal to the mid. WSP to APPL events contain the
session id, and possibly a transaction id (as defined in the spec),
which can be returned in the APPL to WSP events. No more mid
or msmid fields. The transaction id is set equal to the handle
gotten from the WTP layer, because that one's already unique.
* Still missing: Push and Suspend/Resume.
* gw/wap-appl.c: Handle all the new S- events and send back
the proper replies.
* gw/wsp-session.c: Moved method machines into the session machines.
They can only be addressed via a session id and transaction id.
The session machine can send events to all its method machines.
Also added support functions for the WSP state tables.
Implemented pre- and post- state machine checks, for more accurate
handling of events without sessions, etc.
* gw/wsp.h: Defined an enum for all the possible abort values.
* test/drive_wapbox.c: Really disconnect clients after the right
number of page fetches. (Used to do this only once per client.)
2000-06-14 Yann Muller <>
* smsc_at.c: Fixed a memory leak in pdu_extract. Removed unused
2000-06-14 Kalle Marjola <>
* gw/html.c: fixed parsing bug in html_to_sms
* utils/kannel-init.d: made to worship new configuration files
2000-06-14 Aarno Syvänen <>
* wtp_send.c|h: wtp_do_not_send uses WAPAddrTuple type, too
* wtp.c: Reimplement error handling
2000-06-14 Kalle Marjola <>
* gw/smsbox_req.c: fixed split-send Octstr-wise, now it should
work with CIMD2, too (and other new SMSC protocols?)
2000-06-14 Kalle Marjola <>
* gw/bb_smsc.c: modified sleep in smsc receive to variable length,
to increase performance
2000-06-14 Yann Muller <>
* smsc_at.c: New SMSC for wireless modems (AT commands).
* smsc.c, smsc_p.h: Added support for new AT SMSC.
2000-06-13 Kalle Marjola <>
* gw/bb_boxc.c: (somehow) fixed pointer error pointed out by Paul
2000-06-13 Richard Braakman <>
* gw/wap-appl.c: Query list of charsets from the WML compiler,
and use that instead of accessing the table as an extern.
* gw/wml_compiler.[ch]: Added wml_charsets function.
* gw/wap-appl.c: Continued simplifying fetch_thread, broke out
a number of smaller functions. Made converters table only
list actual converters, eliminated convert_to_self.
* gw/wap-events-def.h: Made response_type an octstr. Convert
it to the WSP encoding in the WSP layer, not the application layer.
Moved encode_content_type function to wml.c.
* gwlib/http.c: Reindented http_something_accepted and istrdup
to fit with the rest of the code.
* gwlib/http.h: Added prototype for http_charset_accepted.
* gw/wap-appl.c: Created "content" struct to describe content
body and meta-info. Made convert functions use it. Split off
content conversion into a separate function that uses the table.
2000-06-12 Richard Braakman <>
* Started simplifying fetch_thread function.
* Add "X-WAP-Gateway: Kannel XXX" to requests, where XXX is the
version number.
2000-06-12 Richard Braakman <>
* Renamed http2 to http everywhere, because the old http code
is completely gone. Removed --with-http2 configuration option.
2000-06-12 Tuomas Luttinen <>
* gw/wml_compiler.c: Character set and string table length changed
from chars to uintvars. Now WML compiler can handle string table
length greater than 127.
2000-06-12 Richard Braakman <>
* Making development release 0.9.2.
* Commented-out some excessive logging.
2000-06-12 Aarno Syvänen <>
* wtp_state-decl.h: TR-Abort.ind when timer counter has expired
2000-06-10 Richard Braakman <>
* gwlib/gwmem-check.c: New implementation. This fixes the speed
bottleneck that the old gwmem-check was, and it provides better
checking and some extra features.
* gwlib/gwmem.h: Slight changes for the new gwmem-check. New
functions gw_check_area_size and gw_check_claim_area, which do
not have macro wrappers yet.
* gwlib/thread.[ch]: Add support for statically allocated Mutex
structures. They are needed to break some dependency loops
between the various wrappers (log.c needed protected.c,
protected.c needed Mutex, Mutex needed gwmem, gwmem needed log.c)
which made it impossible to shut them down correctly.
* gwlib/protected.c, gwlib/gwmem-check.c: Use the new static mutexes.
2000-06-09 Tuomas Luttinen <>
* gwlib/http2.c: A http request headers patch applied.
* gw/wap-appl.c: A http request headers patch applied.
* gw/wml_definitions.c: Character set conversion pathes added, see
* gw/utf8map_iso8859-7.h: A conversion table for greek character set.
* gw/utf8map_win1253.h: A character set added.
* gw/utf8map_win1251.h: A russian character set added.
* gw/utf8map_koi8r.h: A russian character set added.
* gw/wml_compiler.c: A memory allocation loop removed from
2000-06-09 Richard Braakman <>
* gw/wap-appl.c: In fetch_thread, also clean up "url" octstr.
This fixes the last big memory leak. I now get only a handful
of leaked areas after 100 requests.
2000-06-09 Richard Braakman <>
* gw/wsp-session.c: Fixed two of the memory leaks, still hunting
for others.
2000-06-09 Richard Braakman <>
* gwlib/http2.c: Fixed header_is_called() to return 0 for no match
and 1 for match; simplified it in the process. I think this was
the original intent, and it matches the function name.
By a roundabout path this fixes the lack of "Accept: text/vnd.wap.wml"
and such in the HTTP request headers Kannel generates.
Adapted http2_header_find_first() to the new interface of
2000-06-09 Richard Braakman <>
* gw/wsp_pdu.c: Allow REST fields to be NULL when packing (treat
them as length 0 strings). This was already done for OCTSTR fields.
Thanks to Paul Keogh for fixing this.
* gw/wtp_pdu.c: Make the same change for REST and OCTSTR fields as
above. It's going to be difficult to keep this code in sync.
2000-06-09 Richard Braakman <>
* gwlib/socket.c: Make read_available assert that fd >= 0, because
otherwise it just segfaults.
* gwlib/http2.c: Make pool_socket_is_alive return "not alive" for
sockets < 0. This does not fix the whole problem but it keeps the
wapbox from crashing here.
* gwlib/list.c: Fix bug in delete_items_from_list which would
corrupt the list in some cases.
2000-06-09 Kalle Marjola <Kalle Marjola <>>
* gw/bb_*.c: removed START and EXIT debug info as they are in new
thread wrapper, too
* gw/bb_boxc.c: fixed bugs in wdp-router and wapbox quit, and
re-synchronized shutdown
* gw/bearerbox.c, gw/bb_http.c: removed core_threads as new thread
wrapper can be used to handle that.
Fri Jun 9 08:31:18 2000 Lars Wirzenius <>
* Separated the method state machine from the session state machine,
to keep state tables in the source closer to the spec and to allow
multiple fetches per client.
* gw/wsp-method-machine.h, gw/wsp-session-machine.h: Split out from
gw/wsp_machine-decl.h, now removed.
* gw/wsp-method-state.h, gw/wsp-session-state.h: Split out from
gw/wsp_state-decl.h, now removed.
* gw/wsp-session.c: Added handling of WSPMethodMachines and
correct routing of WAPEvents between the session and method
state machines. This is a bit ugly, though.
* gw/wap-appl.c, gw/wap-events-def.h, gw/wsp.h, gw/wtp.c:
Related changes.
Fri Jun 9 06:20:12 2000 Lars Wirzenius <>
* gw/wtp.c: Combined wtp_machine_create and wtp_machine_create_empty.
Fri Jun 9 05:39:06 2000 Lars Wirzenius <>
* gw/wsp-session.c, gw/wsp_machine-decl.h, gw/wsp_state-decl.h:
Removed `unused' field from WSPMachine, using state == NULL_STATE
Fri Jun 9 05:32:38 2000 Lars Wirzenius <>
* gw/wap-events-def.h, gw/wtp.c, gw/wsp_state-decl.h: Removed
unused exit_info and exit_info_present fields from WAPEvents.
Fri Jun 9 05:28:12 2000 Lars Wirzenius <>
* gw/wtp_state-decl.h: Enabled sending of TR-Abort.ind events
to WSP.
* gw/wtp.c: Removed (now unused) variable current_primitive.
Fri Jun 9 05:18:07 2000 Lars Wirzenius <>
* gw/wap-events-def.h: Finished breaking up pack_wsp_event into
smaller functions.
Fri Jun 9 05:10:20 2000 Lars Wirzenius <>
* gw/wtp.c, gw/wap-events-def.h: Removed event TR_Invoke_Cnf since
it wasn't used and is only generated on the client side.
Fri Jun 9 04:58:02 2000 Lars Wirzenius <>
* gw/wap-events-def.h, gw/wtp.c: Removed unused fields wsp_pdu
and wsp_tid from various events. Then removed code that set
and copied them between events.
Fri Jun 9 07:44:25 2000 Lars Wirzenius <>
* gw/wtp.c, gw/wtp_state-decl.h: Beginning the breaking up of
pack_wsp_event function into smaller, more well defined ones.
Fri Jun 9 06:48:42 2000 Lars Wirzenius <>
* gw/wap-appl.c: Combine headers for HTTP request after the
actual list of headers has been collected.
Fri Jun 9 02:58:00 2000 Lars Wirzenius <>
* Implemented WSP connectionless service. This meant moving
things around a bit. The basic approach is to treat connectionless
mode as a level in the protocol stack that is parallel to WTP and
session oriented WSP. That is, connectionless mode gets events
directly from wapbox.c and feeds them to wap-appl.c, and vice
versa for replies.
* gw/bb_udp.c: Read from port 9200 as well.
* gw/wap-events-def.h: Added events S_Unit_MethodInvoke_Ind and
* gw/wapbox.c: Deal with connectionless packets as well. Feed them
to wsp-unit.c. Also: trace packets received and sent, except for
heartbeat packets.
* wsp-session.c: The session oriented mode of WSP. I just moved
relevants parts of wsp.c here and renamed them to use the
wsp_session prefix.
* gw/wsp-unit.c: The connectionless mode of WSP.
* gw/wsp.c: Kept only stuff shared by wsp-session and wsp-unit.
* gw/wap-appl.c: Deal with both S-MethodInvoke.ind and
S-Unit-MethodInvoke.ind events.
Fri Jun 9 02:46:53 2000 Lars Wirzenius <>
* gw/wap-events.[ch]: Changed the WAPEvent sub-structures to be
held inside a union, to reduce amount of space used. Related
changes everywhere WAPEvents are used.
2000-06-08 Richard Braakman <>
* test/drive_wapbox.c: Added option -g N to try more than one
page fetch per WSP session. Improved tid checking so that it
will catch the tid inversion bug (fixed below) in the future.
* gw/wapbox.c: Make wap_addr_tuple_duplicate handle a NULL
argument by returning NULL, like most other _duplicate functions.
* gwlib/http2.c: Make http2_append_headers copy the headers it
appends, so that http2_destroy_headers can safely be called on
the result.
2000-08-07 Aarno Syvänen <>
* wtp_state-decl.h: Removed machine_mark_unused calls
2000-06-07 Richard Braakman <>
* gw/wtp_send.c: Invert the MSB of the received tid when sending,
to comply with WTP 8.8.1. This fixes a bug introduced two days ago.
2000-06-07 Richard Braakman <>
* gw/wtp.c: Also destroy the event queue at shutdown.
2000-06-07 Richard Braakman <>
* gwlib/gwthread-pthread.c: Fixed silly bug in yesterday's patch.
2000-06-07 Derry Hamilton <>
* test/fakewap.c: Running fakewap too quickly messes up
thread-control signal handling under Solaris. Ignore SIGALRMs,
they are not meant for us.
2000-06-06 Richard Braakman <>
* gwlib/gwthread-pthread.c: Information for main thread is now
allocated statically, so that we don't have to deallocate it
at shutdown. This way we can keep it around so that gwthread_self
continues to work as expected even during shutdown.
2000-06-06 Richard Braakman <>
* Making development release 0.9.1.
2000-06-06 Richard Braakman <>
* gwlib/gwlib.c: Patch gwlib_assert_init so that it works if
NDEBUG is on.
* gwlib/octstr.c: Patch seems_valid macro so that it does nothing
if NDEBUG is on.
2000-06-06 Tuomas Luttinen <>
* gw/wsp.c: append_uintvar removed, calls to it were changed to
* gw/utf8map_win1257.h: A new file from the Latvian localisation
* utils/win1257unicode.txt: A new file from the Latvian localisation
* utils/ A new file from the Latvian localisation patch.
* gw/wml_definitions.h: Latvian localisation patch applied.
* gw/wml_compiler.c: Latvian localisation patch applied.
Tue Jun 6 15:43:31 2000 Lars Wirzenius <>
* gw/wsp_state-decl.h: Bugfix. The mid for a S_MethodInvoke_Ind
was copied from a tid. Oops.
Tue Jun 6 15:11:14 2000 Lars Wirzenius <>
* wap-events-def.h, gw/wsp.c, gw/wtp.c: Some events are generated
by WTP immediately before it kills the WTPMachine. We used to
fetch the address information for those WTP transactions from the
WTPMachine after the machine had been killed. This was a bug. I
changed the relevant events to supply the necessary information
in the event, so that the WTPMachine is no longer needed.
Tue Jun 6 12:28:48 2000 Lars Wirzenius <>
* gw/wap-appl.c, gw/wap-events-def.h, gw/wap-events.c,
gw/wap-events.h, gw/wapbox.c, gw/wapbox.h, gw/wsp.h,
gw/wsp_machine-decl.h, gw/wtp.c, gw/wtp.h, gw/wtp_machine-decl.h,
gw/wtp_send.c, gw/wtp_tid.c: Made more use of WAPAddrTuple.
Tue Jun 6 11:37:22 2000 Lars Wirzenius <>
* gw/wap-appl.c, gw/wap-events-def.h, gw/wap-events.[ch]: Replaced
member `machine' (a pointer to a WTPMachine) to `mid' and `tid'
(integers), so as to remove direct references to WTPMachines
from outside the WTP layer.
* gw/wtp.[ch]: Added function wtp_get_address_of for finding the
address of a machine given its id (mid).
* gw/wapbox.[ch]: Added data types WAPAddr and WAPAddrTuple,
for holding addresses of phone and gateway, and functions for
creating and destroying them.
* gw/wsp_state-decl.h: Made use of mid instead of machine.
* gw/wsp.c: Made light use of WAPAddrTuple. Made use of mid
everywhere, instead of pointers to WTPMachines.
Tue Jun 6 08:44:13 2000 Lars Wirzenius <>
* test/decompile.c: Added return type (void) to function
2000-06-05 Richard Braakman <>
* gw/wsp_pdu.[ch]: Added wtp_pdu_append_tpi function.
* gw/wtp_send.c: Continued conversion to use of wtp_pdu.
Next step is to handle resends better, but that requires
changes to the state machines.
2000-06-05 Richard Braakman <>
* gwlib/conn.[ch]: Change conn_flush interface so that it can
block, and tries to send all queued output. This makes it more
useful for threads that only want to do output and do not want
to wake up for input.
* gwlib/gwthread-pthread.c: Make gwthread_pollfd return -1 when
poll() fails with EINTR, instead of 0, so that 0 can be relied
on to mean timeout.
2000-06-05 Richard Braakman <>
* gwlib/conn.c: Implemented conn_open_tcp().
Fixed conn_read_withlen, which I broke a few days ago.
* gwlib/conn.c: Split the single Connection lock into two locks,
one for reading and one for writing. This allows reader and
writer threads to work without fighting over one lock. Only
conn_wait needs both locks.
* test/drive_wapbox.c: Take advantage of some new octstr functions.
2000-06-05 Richard Braakman <>
* gwlib/gwthread.h, gwlib/gwthread-pthread.c: Renamed
gwthread_join_all to gwthread_join_every, and added a
gwthread_join_all that joins ALL threads. Added gwthread_wakeup_all
to match.
* gwlib/gwthread-pthread.c: Fix use of pipe(); reading and
writing fd's were reversed.
2000-06-05 Richard Braakman <>
* gw/wsp.c: Installed Joerg Pommnitz's patch for correct parsing
of WSP capabilities.
2000-06-05 Tuomas Luttinen <>
* test/decompile.[ch]: A WML decompiler by Chris Wulff, Vanteon.
* test/wml_tester.c: A patch by Chris Wulff, Vanteon added to produce
pure binary files. A little cleanup.
2000-06-05 <Kalle Marjola <>>
* gw/bb_smsc.c: changed sleep(1) to usleep. A bit more busier
loop, that new interface is really needed
* gw/numhash.c: removed some warnings
Mon Jun 5 10:32:41 2000 Lars Wirzenius <>
* gw/wtp.c: Fixed bug that was caused by not duplicating an
octet string while copying it. Also fixed a memory leak.
* gw/wtp_pdu.[ch]: Added function wtp_pdu_create. Also added
wrappers around wtp_pdu.h to prevent problems when including
many times, and added an include for gwlib/gwlib.h, so that
the caller does not have to deal with that.
* gw/wtp_send.c: Started conversion to using wtp_pdu.c instead
of packing everything by hand. The basic PDUs are now converted.
The negative ACK and some other ones are not, because I wasn't
certain how they work, right now, and am too tired to understand
the spec (probably too tired to hack, but I ran a fakewap test
after each change to make sure I didn't break things too badly).
Sun Jun 4 07:32:59 2000 Lars Wirzenius <>
* Re-vamped the WTP layer to use a thread structure similar to WSP.
All code referring to segmentation and re-assembly has been deleted
(this was simpler for me - it wasn't used anyway, and we can dig it
out of CVS if we want it later). Error handling also suffered, but
on the other hand, the current structure should be easier to make
* gw/wap-events-def.h: Events generated from PDUs now have the
address of the client and the gateway included in the event.
This means we can use a trivial wtp_dispatch_event function
interface, without having to carry around the addressing information
Other events that the WTP layer may receive include a `mid'
(machine id) field for finding the correct WTPMachine. The ultimate
goal it so make the WTPMachine data type hidden within WTP, so
that there are no direct pointers to the machines.
* gw/wapbox.c, gw/wsp.c, gw/wsp_state-decl.h: Use
wtp_dispatch_event to send an event.
* gwlib/gwthread-pthread.c: Commented out call to pthread_setspecific
that was hanging shutdown. The real reason is probably somewhere
else, but I didn't find it, so this workaround is used to make
things at least seemingly work.
Sun Jun 4 04:38:02 2000 Lars Wirzenius <>
* gw/wsp.c, gw/wsp_state-decl.h: Use WSP_PDU's, instead of
packing things ourselves, as far is possible. Some fields have
special packing encodings, those we do partly ourselves still.
* gw/wsp_pdu.c: Don't crash if OCTSTR field is NULL, just ignore
Sun Jun 4 03:45:45 2000 Lars Wirzenius <>
* gw/wap-events.c: wap_event_dump now reports name of Octstr
* gw/wsp_pdu.c: bit position is advanced correctly when unpacking
a Uintvar. Also, dump tells when the dump ends.
* gw/wsp_state-decl.h: Duplicate the URL octet string.
Sun Jun 4 02:36:10 2000 Lars Wirzenius <>
* gw/wsp_pdu.[ch]: Added function wsp_pdu_create, which creates
an (empty) PDU of the desired type. Made the warning about an
unknown PDU type in wsp_pdu_destroy be a panic instead.
* gw/wsp.c, gw/wsp_state-decl.h: Converted to use wsp_pdu.[ch]
for unpacking. We have issues with packing: at least some fields
need to be packed in a special way, and this needs to be handled
in a clean way.
Sun Jun 4 01:03:55 2000 Lars Wirzenius <>
* gwlib/protected.[ch]: Added wrapper for gethostbyname.
* gwlib/socket.c: Made use of wrapper.
Sun Jun 4 00:52:22 2000 Lars Wirzenius <>
* gwlib/protected.[ch]: Wrote thread-safe wrappers around
standard library functions gmtime, localtime, and rand. Note
that this is just a beginning, we should wrap many more functions.
* gw/urltrans.c, gwlib/gwlib.[ch], gwlib/log.c: Made use of the
Sun Jun 4 00:20:19 2000 Lars Wirzenius <>
* gw/numhash.c: Added typecasts to silence compiler warnings. Kalle,
please fix it properly so it uses unsigned chars.
Sun Jun 4 00:06:23 2000 Lars Wirzenius <>
* gw/wap-events.c: Added assertions to wap_event_name. Added
calls to wap_event_assert. Event duplication now also works for
NULL arguments. Fixed wap_event_assert (i.e., reduced the number
of checks it makes - it was overly aggressive).
* gw/wsp.c: Added calls to wap_event_assert.
2000-06-03 Richard Braakman <>
* gwlib/octstr.[ch]: Added octstr_append_uintvar.
* gw/wsp_pdu.[ch], gw/wsp_pdu.def: Do the same for WSP PDU's.
* gw/wtp_pdu.c: Bugfixes.
* test/test_pdu.c: Test WSP data too.
2000-05-31 Richard Braakman <>
* gwlib/octstr.[ch]: Added octstr_get_bits and octstr_set_bits.
* gw/wtp_pdu.[ch], gw/wtp_pdu.def: Deliberate preprocessor abuse
to automate PDU packing and unpacking. First draft; works for
simple test cases, needs more documentation. Not used by anything
else yet.
* test/test_pdu.c: Test program for above.
2000-05-31 Tuomas Luttinen <>
* gw/wml_compiler.c (string_table_add): A bug fixed. The string
didn't match any in the table, since it didn't have a termination
character at the end of it as those in the table. Also string has
to be destroyed if it has already a duplicate in the table.
2000-05-30 Kalle Marjola <>
* gw/bb_smsc.c: added white and black lists.
* doc/userguide/newconf.txt: added 'documentation' about white and
black lists
2000-05-30 Kalle Marjola <>
* gw/numhash.h|c: exported numhash from old smsgateway and edited
it to work with new http2 and Octstrings, plus removed some
functions. Next: implement white/black-list
2000-05-29 Richard Braakman <>
* gw/smsbox_req.c: Fixed silly mistake.
2000-05-29 Richard Braakman <>
* gwlib/conn.c: Implemented conn_read_packet().
2000-05-29 Richard Braakman <>
* gw/bb_boxc.c: If listening socket cannot be opened, handle it
by panicking rather than segfaulting.
2000-05-29 Tuomas Luttinen <>
* gw/wml_compiler.c: #ifdefs added to supprt libxml2. Does compile,
but does not work with it, yet. WapIT -> Wapit
* gw/wml_definitions.h: WapIT -> Wapit
* gw/wml_compiler.h: WapIT -> Wapit
* libxml2 added.
2000-05-29 Richard Braakman <>
* gw/smsc.c: Made bearerbox not crash if "smsc" field is missing
from smsc config.
* gwlib/gwthread-pthread.c: Comment around previous change was
inaccurate; it was an fd leak on Linux too.
2000-05-29 Derry Hamilton <>
* gwlib/gwthread-pthread.c: Added some system cleanups to
delete_threadinfo. Threads are not always processes!
2000-05-29 Kalle Marjola <>
* gw/bb_boxc.c: fixed possible problem in box shutdown and added
multiple wapbox routing. It is, however, not done according to
load levels, just random distribution. Load balancing later.
2000-05-29 Richard Braakman <>
* test/fakewap.c: Use gwthread_join_all to wait for client threads
to terminate.
2000-05-29 Richard Braakman <>
* gwlib/gwthread-pthread.c: In new_thread, free its argument a bit
earlier, to avoid a race with gw_check_leaks. (This caused seemingly
random memory leak reports).
* gwlib/conn.c: Use gwthread_pollfd instead of calling poll directly.
2000-05-29 Richard Braakman <>
* gwlib/gwthread-pthread.c: Made gwthread_create fail gracefully
if there are more active threads than the module can handle, rather
than panicking.
Sat May 27 06:39:51 2000 Lars Wirzenius <>
* gw/wap-events.[ch]: Added wap_event_assert function.
Sat May 27 02:50:09 2000 Lars Wirzenius <>
* gwlib/gwthread.[ch]: Added function gwthread_join_all, which
joins all threads running a specific function.
* gw/wap-appl.c, gw/wapbox.c, gw/wsp.c: Use gwthread_join_all to
synchronize shutdown properly.
Sat May 27 02:05:41 2000 Lars Wirzenius <>
* gw/wap-events.c: Only the fields for the correct event type
are dumped by wap_event_dump.
* gw/wapbox.c: Uncommented code to get heartbeat-freq setting
from config. Added some shutdown code.
NOTE: The wapbox does not currently shutdown correctly. Thread
termination synchronization is not done and this causes a
segfault at the end. Will hack that next.
* gw/wap-appl.c: Event queue is emptied and destroyed at shutdown.
* gw/wsp.c, gw/wsp_state-decl.h, gw/wtp_state-decl.h:
Work started on making a global event queue for all
WSPMachines. wsp_dispatch_event now the only external method
for sending events to WSP. Its interface has been changed so
that it only gets the event and will look inside the event to
find addressing info - the WTPMachine is no longer needed to be
given as the argument for this. A number of previously available
functions are now static and must only be used from within the
WSP layer.
Sat May 27 02:02:33 2000 Lars Wirzenius <>
* gwlib/gwthread.h, gwlib/gwthread-pthread.c: Name of function
made as the name of the thread.
Fri May 26 21:05:29 2000 Lars Wirzenius <>
* utils/start-stop-daemon.c: Added pid_is_cmd for FreeBSD.
Fri May 26 21:01:41 2000 Lars Wirzenius <>
* gwlib/http2.c: Compare header names case-insensitively.
Fri May 26 20:47:06 2000 Lars Wirzenius <>
* gw/wap-appl.h: Moved to gw/wsp.h. Don't want a zillion small
.h files, after all.
* gw/wsp.h: Added prototypes for the application layer.
2000-05-26 Richard Braakman <>
* gwlib/conn.c: Converted conn_claim() stuff to use new thread
* gwlib/gwthread-pthread.c: Bugfix, make sure the main thread
can still safely call gwthread_self after shutdown, so that gwmem
layer can log stuff.
* gwlib/thread.c: Converted mutex->owner to use new thread
Fri May 26 20:34:01 2000 Lars Wirzenius <>
* gw/wap-appl.[ch]: Wrote. This is the new application layer.
This version is ugly - essentially I just moved code in here
from the old wsp_http.c - but I want to clean it up before I
break it further.
* gw/wsp_state-decl.h: Use S_MethodInvoke_Ind instead of
S_MethodInvoke_Res and wap_appl_dispatch instead of
* gw/wap-events-def.h: Added S_MethodInvoke_Ind, removed most
fields from S_MethodInvoke_Res, since they're now unnecessary.
* gw/wapbox.c: Starts the application layer.
* gw/wsp.c: Added #include for wap-appl.h.
* gw/wsp.h: Removed prototype for wsp_http_thread.
* gw/wsp_http.c: Removed.
Fri May 26 19:05:09 2000 Lars Wirzenius <>
* gw/wap-events.[ch], gw/wap-events-def.h: Combined WTPEvent and
WSPEvent into a unified WAPEvent. This makes it slightly easier
to find the events (no need to wonder whether a TR-Invoke.ind is
a WTP or WSP event, for example), and reduces code duplication
a bit.
* gw/wsp_events-decl.h, gw/wtp_events-decl.h: Removed.
* Lots of files: WTPEvent and WSPEvent and related function calls
changed to WAPEvent and its functions.
* gwlib/http2.c: http2_header_dump works now even with a NULL
2000-05-26 Richard Braakman <>
* gwlib/gwthread.h: New thread interface. Encapsulates thread
creation, and provides features for interruptible sleeping and
blocking. Can eventually be extended to wrap all of pthreads,
if desired.
* gwlib/gwthread-pthread.c: Implementation of thread interface
with pthreads.
* gwlib/gwlib.h: Include gwthread.h too.
* gwlib/gwlib.c: Initialize and shut down gwthread module along
with the rest.
* gw/bb_boxc.c, gw/bb_http.c, gw/bb_smsc.c, gw/bb_udp.c,
gw/bearerbox.c, gw/smsbox.c, gw/smsbox_req.[ch], gw/wapbox.c,
gw/wsp.h, gw/wsp_http.c, gw/wsp_state-decl.h,
test/drive_wapbox.c, test/fakewap.c, test/test_counter.c,
test/test_http2.c, test/test_http2_server.c, test/test_list.c:
Use gwthread_create instead of start_thread.
Thread functions are now void functions instead of (void *)
functions, so removed all the "return NULL" and changed the
Use long instead of pthread_t as the thread identifier.
Use gwthread_join instead of pthread_join.
* gwlib/log.c: Use gwthread_self() instead of pthread_self()
to get the thread number to log.
* gwlib/thread.[ch]: Removed start_thread function.
Fri May 26 17:14:18 2000 Lars Wirzenius <>
* doc/arch/wapbox-arch.fig: New figure showing the planned
wapbox architecture. (Not visible in the actual documentation
yet, though.)
Fri May 26 16:59:03 2000 Lars Wirzenius <>
* gwlib/http2.c: Destroy temporary header list in
Thu May 25 21:46:04 2000 Lars Wirzenius <>
* gwlib/http.[ch], test/test_http.c: Removed.
* gwlib/http2.[ch]: Added a number of header handling functions.
Also added many assertions.
* gw/wsp.[ch], gw/wsp_headers.[ch], gw/wsp_http.c,
gw/wsp_state-decl.h: Converted to use http2 instead of http for
header handling.
2000-05-25 Kalle Marjola <>
* gw/bb_smsc.c: fixed some lock-ups during violent shutdown
2000-05-25 Richard Braakman <>
* test/fakewap.c: Sanitized tid handling. It's now local to the
client thread, rather than global. Each client should have its
own tid space anyway.
Thu May 25 18:45:15 2000 Lars Wirzenius <>
* gwlib/gwlib.[ch]: gwlib_shutdown now always calls gw_check_leaks,
to check for memory leaks. Added function gwlib_assert_init, to
allow gwlib code to verify that gwlib has been initialized.
* gw/bearerbox.c, gw/smsbox.c, gw/wapbox.c, test/drive_wapbox.c,
test/fakesmsc.c, test/fakewap.c, test/test_cimd2.c,
test/test_counter.c, test/test_http.c, test/test_http2.c,
test/test_http2_server.c, test/test_list.c, test/test_mem.c,
test/test_msg.c, test/test_udp.c, test/test_urltrans.c,
test/wml_tester.c: Fixed to call gwlib_init and gwlib_shutdown
instead of gw_init_mem and gw_check_leaks.
* gwlib/octstr.c: Call gwlib_assert_init in seems_valid.
Thu May 25 16:52:22 2000 Lars Wirzenius <>
* gw/bb_smsc.c: Removed unused variable `ret'.
2000-05-25 Kalle Marjola <>
* gw/smsc.c, gw/smsc.h, gw/smsc_p.h, gw/bb_smsc.c: removed old
dial-prefix (use global unified-prefix) and route-prefix, and
added new denied-prefix and preferred-prefix, see details from
* doc/userguide/newconf.txt: added notes of preferred-preix and
2000-05-25 Kalle Marjola <>
* gw/smsc.h|c: got rid of bb_msg
* gw/bb_smsc.c: modified to use just plain Msg
* gw/bb_msg.*, gw/boxc.*, gw/wdp_udp.*: removed, not used anymore
2000-05-25 Kalle Marjola <>
* gw/bb_smsc.c: added number normalization/unifying, via
configuration variable unified-prefix.
* doc/userguide/newconf.txt: added explanation of unified-prefix
2000-05-25 <Kalle Marjola <>>
* gw/*box.c: changed default configuration file to be
kannel.conf. Please note that there is NO such file, but two
sample files, smskannel.conf and wapkannel.conf
2000-05-24 <Kalle Marjola <>>
* doc/userguide/userguide.xml: Removed old configuration file
things, read the newconf.txt file. Did same to HTTP adminstration
notes, read file newbb.txt
* doc/arch/arch-bearerbox.xml: Rewrote to reflect the new
bearerbox. Have to do it a bit more deeply someday, however. And
pictures, too.
* gw/wsp.c: Applied a short WSP header patch by Joerg Pommnitz to
handle broken headers from Timeport
* test/simple.smsconf: removed
2000-05-24 Richard Braakman <>
* gw/wsp_http.c: Fixed Accept header scanning in wsp_http_thread.
2000-05-24 <Kalle Marjola <>>
* doc/userguide/newconf.txt: added documentation about new
configuration file
* doc/userguide/newbb.txt: added documentation about new
* gw/bearerbox.c: moved new bearerbox into final name, old
bearerbox removed from the project
* gw/smskannel.conf, gw/wapkannel.conf: added new sample
* gw/kannel.*conf: removed old configuration defination files
* test/sample.*conf: removed old sample configurations
* gw/smsbox.c, gw/urltrans.c, gw/wapbox.c: edited to use new
configuration file
* README: updated
2000-05-24 Richard Braakman <>
* test/test_cimd2.c: Written a while ago, added to CVS today.
Might be useful for people doing speed tests of sms handling.
2000-05-23 <Kalle Marjola <>>
* gwlib/http2.c|h: moved destroying functions here, and changed so
that http2_socket_host does not duplicate the octstr but returns
* gw/bb_http.c: check for password of the admin
* gw/smsbox*.c moved cgi and destroy functions to http2
2000-05-23 <Kalle Marjola <>>
* gw/bb_http.c: check for allow/deny IP for http admin
2000-05-23 <Kalle Marjola <>>
* gwlib/socket.h|c: added host_ip to get, well, host IP. That
needed mutex because ntoa operation is not thread-safe, so added
socket_init and shutdown, too
* gwlib/gwlib.c: calls to socket_init and shutdown
* gwlib/http2.c: get client host IP
* gwlib/utils.c|h: added is_allowed_ip function
* gw/bb_core.c: options -S and -I to start new bearerbox in
suspended or isolated state
* gw/bb_boxc.c: check for client allowed/denied IP
2000-05-23 Richard Braakman <>
* test/drive_wapbox.c: Fix free-port-hunting code for fake httpd.
2000-05-23 Richard Braakman <>
* gw/smsc_cimd2.c: The maximum message length was always set to 140.
It should be 160 for normal (non-UDH, non-8bit) messages. Fixed.
2000-05-22 <Kalle Marjola <>>
* gwlib/utils.c|h, gw/bearerbox.c: moved normalize_number to
utils module from old bearerbox
* gwlib/http2.h|c: first version of http2_socket_ip, although
not yet working with servers, beware
2000-05-22 Richard Braakman <>
* gwlib/conn.h, gwlib/conn.c: Made output buffering explicit instead
of hidden in the interface. (We can't hide it with 100% correctness
if there are multiple threads using the Connection, not all of which
are in a conn_wait loop).
Added conn_output_buffering and conn_flush functions.
* test/drive_wapbox.c: Made the fake httpd return a real wml page,
for better testing. (This exercises the WML compiler).
Cleaned up some memory leaks.
2000-05-22 Richard Braakman <>
* gwlib/conn.h, gwlib/conn.c: Extended to handle end-of-file better.
Added conn_eof function.
* test/drive_wapbox.c: Use conn_eof.
2000-05-22 Richard Braakman <>
* test/drive_wapbox.c: Make setting the U/P flag optional, with
the -U flag, because Kannel no longer (erroneously) requires it.
Also have its internal httpd supply a Content-Type header.
2000-05-22 <Kalle Marjola <>>
* gwlib/http2.c|h: implemented function http2_destroy_headers
* gw/bb_core.c: some update to status information
* gw/bb_http.c: fixed last memory leaks, now the new system should
not leak memory at all. Still misses cgibin arguments because of
the lack of operations in http2.
2000-05-18 Richard Braakman <>
* wmlscript/wsfalloc.c: Make ws_f_malloc return blocks aligned
to sizeof(long), to prevent unaligned accesses. This should fix
the bug reported by Lim YoungLan, but I can't test that here.
2000-05-17 <Kalle Marjola <>>
* gwlib/counter.c|h: renamed counter_get as counter_increase and
added function counter_value.
* test/test_*.c, gw/wsp.c: changed counter functions
* gw/smsc.c, gw/smsc_fake.c: started a project that smsc_close
will eventually free all memory it has reserved. Fake does this
already, rest do not, and close is a bit weird for those right
* gw/bb_*.c: added counters for messages, fixed some timing
2000-05-17 Tuomas Luttinen <>
* gw/wml_compiler.c: Now variables use the string table. Some fixing
for reducing numbers of the memory allocations and reallocations is
2000-05-17 <Kalle Marjola <>>
* gw/bb_*.c: Some final cleanup added
* gw/smsc_fake.c: smsc_close now destroyes eveyrhing. Should add
this functionality to other SMSCes, too, and rename it as _destroy
2000-05-17 Richard Braakman <>
* test/drive_wapbox.c: Memory leak now fixed. Added includes
needed by accept().
2000-05-17 Aarno Syvänen <>
* wtp_state-decl.h: Two bugfixes: rid to 0, when the result is
sent first time (thanks to Oliver Lau), conditions checking
whether u/p-flag is up corrected.
2000-05-16 <Kalle Marjola <>>
* gwlib/list.c|h: added function list_producer_count
* gw/bb_*.c: smsc thingies are now somehow working. Does not work
very well with multiple smsces, however.
2000-05-16 Tuomas Luttinen <>
* gw/wml_compiler.c: Memory leaks with variables removed.
String table code mostly done, nrext thing is to start to use it.
* gwlib/octstr.[ch]: octstr_create_tolower removed as unnecessary.
2000-05-15 Richard Braakman <>
* gwlib/conn.[ch]: Found some more things to fix while writing
drive_wapbox. Interface is almost stable now.
* gwlib/thread.c: Added some assertions for mutex not being NULL.
2000-05-15 Richard Braakman <>
* test/drive_wapbox.c: A tool to run the wapbox in isolation,
for easy profiling.
2000-05-15 <Kalle Marjola <>>
* gw/bb_*.c: Now most memory leaks are fixed, the new bearerbox
dies quite nicely and can handle exiting wapboxes and new
connections. Still needs much testing and there is some mysterios
things not freed at the end, so back to work.
Mon May 15 16:07:00 2000 Lars Wirzenius <>
* gw/wsp_http.c: Report character set when fetch is successful.
* gwlib/http2.c: Fix parsing of character set from Content-Type.
* test/test_http2.c: Report reply headers.
Mon May 15 15:59:32 2000 Lars Wirzenius <>
* gw/wsp_http.c: Do not require resp_headers to be non-NULL.
Instead, only destroy it if it is non-NULL. Fixes bug #69
by Kalle Marjola.
Mon May 15 15:06:16 2000 Lars Wirzenius <>
* gw/wsp_http.c: Undid broken changes to how HTTP headers are
* gwlib/http2.c: Dump to log file the headers used in the request.
2000-05-15 Richard Braakman <>
* wsp_http.c: octstr_destroy(key_os) and (value_os) moved into the
loop, so that it's not a memory leak.
2000-05-11 Aarno Syvänen <>
* wsp_http.c: Using octstr_compare instead of strstr in conditional
header addition. There was some curious problem with strstrs.
* wsp.c: Changed Can't handle event error code to 0xEO. This is user
Fri May 12 Derry Hamilton <>
* fakewap.c: Added -F switch which enables continue on fail
rather than exit on fail. (Stress testing)
2000-05-11 <Kalle Marjola <>>
* gw/bb_*.c: suspend and isolate status now in work. System still
leaks memory somewhere and some things are missing, but WAP
browsing works fine with new bearerbox.
2000-05-11 Richard Braakman <>
*, configure: Made it not look for getloadavg.c
on systems that have no getloadavg().
2000-05-11 <Kalle Marjola <>>
* gw/bb_http.c: Oooops, added
* gw/bb_*.c: added signal trapping and (shutdown) flow-control.
Still need some new List operations to free all memory while
2000-05-10 <Kalle Marjola <>>
* gw/bb_*.c: and more, now some HTTP adminstration 'works'
(implementation partial in other modules)
Tue May 9 Derry Hamilton <>
* gw/wapbox.c,,configure: Updated getloadavg bits to
search for getloadavg, rather than just assume that it exists
on Solaris.
* utils/start-stop-daemon.c: Fixed typo.
Tue May 9 23:03:26 2000 Lars Wirzenius <>
* gwlib/gwmem-check.c: Fixed so that fill doesn't have a pointer
alignment bug.
Tue May 9 22:53:22 2000 Lars Wirzenius <>
* gwlib/http2.c: Bugfix. Host header should include port number
if the URL had a non-default one.
Tue May 9 20:53:25 2000 Lars Wirzenius <>
* gw/wsp_http.c: Report status code returned by http2_get_real
if it fails.
* gwlib/http2.c: Added includes for sys/types.h and sys/socket.h.
This should silence warnings about accept being undeclared.
Tue May 9 20:01:45 2000 Lars Wirzenius <>
* Make it allow random junk before the version
number in the output of xml-config. Based on patch from
Gus <>.
000-05-09 Derry Hamilton <>
* gwlib/socket.c: Changed the calls to info to calls to error
when something has gone wrong.
* gwlib/list.c: Added gw_asserts to some of the list functions.
The problem is higher up, though.
* gw/wsp_http.c: Added gw_asserts to some of the URL handling
a call to an invalid protocol causes problems.
Tue May 9 19:31:44 2000 Lars Wirzenius <>
* utils/start-stop-daemon.c: Hand-applied patch from David
Reid for FreeBSD support. No way to test if I did it correctly,
hopefully kannel-nag or a FreeBSD user will complain.
2000-05-09 Richard Braakman <>
* gw/smsc.c: system-type and address-range are also required
for SMPP configurations.
2000-05-09 <Kalle Marjola <>>
* gw/bb_*.c: something new, many things still missing
2000-05-09 Richard Braakman <>
* gwlib/conn.c, gwlib/conn.h: Added octstr_read_withlen and
octstr_write_withlen. Also fixed errors in unlocked_get().
2000-05-09 Derry Hamilton <>
* gw/wapbox.c,, configure, utils/start-stop-daemon.c:
Cleaned up SunOS definition
2000-05-08 Derry Hamilton <>
* gw/wapbox.c: Implemented load reporting for Solaris
2000-05-08 Richard Braakman <>
* Made all sig_atomic_t variables volatile, because there is no
reason to use sig_atomic_t otherwise.
2000-05-08 Richard Braakman <>
* gwlib/conn.c: Commented static functions.
Added unlocked_outbuf_len and unlocked_inbuf_len helper functions.
Added unlocked_try_write helper function, to implement output
buffering. Implemented conn_wait.
2000-05-08 Richard Braakman <>
* test/fakewap.c: Fixed -n flag.
2000-05-07 Derry Hamilton <>
* gwlib/socket.c: Fixed tv_usec > 1000000 handling.
2000-05-05 <Kalle Marjola <>>
* gw/bb_smsc.c: Now it is half done. However, the old
smsc_interface should be redone, now idea to use old rq-items
anymore in new design. Back to work on Monday
* gw/bb_*.c: fixed some places causing warnings
2000-05-05 Aarno Syvänen <>
* wtp_tid.c|h: Module now uses list standard functions
* wtp_state-decl.h: Commented
2000-05-04 <Kalle Marjola <>>
* gw/bb_core.c: logfiles
* gw/bb_boxc.c: added basic routing thingies, now it only needs
some load balancing to wap side, otherwise this module is about
complete.. oh I forgot the dynamic configuration, but that later -
the old one does not have it either
* gw/bb_udp.c: added routing, now this function is about ready,
except dynamic configuration and some testing etc.
2000-05-04 Richard Braakman <>
* gwlib/conn.c, gwlib/conn.h: Got rid of network_long functions.
The interface is so awkward that it's just as easy for the caller
to fill a 4-octet buffer and provide that.
* gwlib/octstr.h, gwlib/octstr.c: Added functions octstr_write_data
and octstr_append, used by the new Connection code.
* gwlib/http2.c: Removed static octstr_append, superseded by the one
in the octstr module.
* gwlib/conn.c, gwlib/conn.h: conn_read interface was not useful.
Renamed to conn_read_fixed(), made it return exactly the number
of bytes specified.
* gwlib/conn.c code fleshed out some more, but several functions
still not implemented.
2000-05-04 Richard Braakman <>
* gw/wsp_http.c: In wsp_http_thread(), do not destroy charset
until after it is used by the converters.
Thu May 4 18:35:24 2000 Lars Wirzenius <>
* Making *DEVELOPMENT* release 0.9. This is not stable, don't use
it in production use.
2000-05-04 Kalle Marjola <>
* gw/bb_core.c, gw/bb_boxc.c, gw/bb_udp.c, gw/bb_smsc.c,
gw/new_bb.h: added first version of the new bearerbox.
WAP-browsing works, but bearerbox is missing signal handling,
HTTP adminstration, log files, SMSC support, wapbox routing
and many, many more things.
* gw/new_kannel.conf: new configuration file type used by the new
bearerbox. Documentation later.
* added target for bb_core, the new bearerbox proto
2000-05-04 <Kalle Marjola <>>
* gwlib/conffile.c|h: more changes so that all functions needing
ConfigGroup work with NULL argument, returning just NULL
2000-05-03 Steffen Weinreich <>
* smsc_emi.c: Fixed the EMI code for UDH and added an initialisation
for the TRN counter. This fixes the error with negative TRN if there
wasnt a message received before the first send
2000-05-03 Tuomas Luttinen <>
* gw/wsp_http.c: Added the charset support here too. Now it's still
needed in html2.
* test/wml_tester.c: Rewrote most of the main-function, started
using getopt for options. The charset stuff was added too.
* gw/wml_definitions.h: The pile of definitions and static arrays
just grew too huge. Added an own file for them.
* gw/wml_compiler.[ch] : The WML compiler now recognises the
most common character sets from ISO-8859-series(1-9) and UTF-8.
It is now easy to add new 8-bit character sets into it.