Hi Alex, first of all: SMPP in kannel is _not_ broken. It's a smsc, you connected to, is broken!
On Thursday 16 October 2003 23:36, Alex Kinch wrote: > Just rebuilt our test box to use cvs-20031016 (previously was running > 1.3.1-devel). I'm now experiencing problems with incoming SMPP. The message > comes in, and shows up the bearerbox debug log - but nothing happens. It > doesn't go anywhere! > > Basically the SMPP sender does a deliver_sm, which Kannel acknowledges with > a deliver_sm_resp. Then nothing. Plus according to the status, no messages > have been delivered on that particular SMPP connection. have you notice a command status in deliver_sm_resp? it's 0x0a == Invalid source address. And see source address in deliver_sm: '+' in front which is not allowed. So you should try to contact telco and tell them that smsc is broken. And second: please try attached patch that just implements a workaround for this mess ;) Good luck and please tell if attached patch works for you... > > Here's a dump of the log: > > 2003-10-16 22:22:05 [16] DEBUG: SMPP[XXXX]: Got PDU: > 2003-10-16 22:22:05 [16] DEBUG: SMPP PDU 0x81c2e40 dump: > 2003-10-16 22:22:05 [16] DEBUG: type_name: deliver_sm > 2003-10-16 22:22:05 [16] DEBUG: command_id: 5 = 0x00000005 > 2003-10-16 22:22:05 [16] DEBUG: command_status: 0 = 0x00000000 > 2003-10-16 22:22:05 [16] DEBUG: sequence_number: 4 = 0x00000004 > 2003-10-16 22:22:05 [16] DEBUG: service_type: "23410" > 2003-10-16 22:22:05 [16] DEBUG: source_addr_ton: 1 = 0x00000001 > 2003-10-16 22:22:05 [16] DEBUG: source_addr_npi: 1 = 0x00000001 > 2003-10-16 22:22:05 [16] DEBUG: source_addr: "+44XXXXXXXXXX" > 2003-10-16 22:22:05 [16] DEBUG: dest_addr_ton: 1 = 0x00000001 > 2003-10-16 22:22:05 [16] DEBUG: dest_addr_npi: 1 = 0x00000001 > 2003-10-16 22:22:05 [16] DEBUG: destination_addr: "8XXXX" > 2003-10-16 22:22:05 [16] DEBUG: esm_class: 0 = 0x00000000 > 2003-10-16 22:22:05 [16] DEBUG: protocol_id: 0 = 0x00000000 > 2003-10-16 22:22:05 [16] DEBUG: priority_flag: 1 = 0x00000001 > 2003-10-16 22:22:05 [16] DEBUG: schedule_delivery_time: NULL > 2003-10-16 22:22:05 [16] DEBUG: validity_period: NULL > 2003-10-16 22:22:05 [16] DEBUG: registered_delivery: 0 = 0x00000000 > 2003-10-16 22:22:05 [16] DEBUG: replace_if_present_flag: 0 = 0x00000000 > 2003-10-16 22:22:05 [16] DEBUG: data_coding: 242 = 0x000000f2 > 2003-10-16 22:22:05 [16] DEBUG: sm_default_msg_id: 0 = 0x00000000 > 2003-10-16 22:22:05 [16] DEBUG: sm_length: 4 = 0x00000004 > 2003-10-16 22:22:05 [16] DEBUG: short_message: "test" > 2003-10-16 22:22:05 [16] DEBUG: SMPP PDU dump ends. > 2003-10-16 22:22:05 [16] DEBUG: SMPP[XXXX]: Sending PDU: > 2003-10-16 22:22:05 [16] DEBUG: SMPP PDU 0x81c3498 dump: > 2003-10-16 22:22:05 [16] DEBUG: type_name: deliver_sm_resp > 2003-10-16 22:22:05 [16] DEBUG: command_id: 2147483653 = 0x80000005 > 2003-10-16 22:22:05 [16] DEBUG: command_status: 10 = 0x0000000a > 2003-10-16 22:22:05 [16] DEBUG: sequence_number: 4 = 0x00000004 > 2003-10-16 22:22:05 [16] DEBUG: message_id: NULL > 2003-10-16 22:22:05 [16] DEBUG: SMPP PDU dump ends. > > > Any ideas? > > Alex -- Best regards / Mit besten Grüßen aus Düsseldorf Dipl.-Ing. Alexander Malysh ___________________________________________ Centrium GmbH Vogelsanger Weg 80 40470 Düsseldorf Fon: +49 (0211) 74 84 51 80 Fax: +49 (0211) 277 49 109 email: a.malysh at centrium.de web: www.centrium.de msn: olek2002 at hotmail.com icq: 98063111 ___________________________________________ Please avoid sending me Word or PowerPoint attachments. See http://www.fsf.org/philosophy/no-word-attachments.html
Index: gw/smsc/smsc_smpp.c =================================================================== RCS file: /home/cvs/gateway/gw/smsc/smsc_smpp.c,v retrieving revision 1.52 diff -a -u -r1.52 smsc_smpp.c --- gw/smsc/smsc_smpp.c 16 Oct 2003 16:00:44 -0000 1.52 +++ gw/smsc/smsc_smpp.c 16 Oct 2003 22:24:05 -0000 @@ -298,7 +298,9 @@ /* check if intl. and digit only; assume number is larger then 7 chars */ if (ton == GSM_ADDR_TON_INTERNATIONAL && octstr_len(pdu->u.deliver_sm.source_addr) >= 7 && - octstr_check_range(pdu->u.deliver_sm.source_addr, 0, 256, gw_isdigit)) { + ((octstr_get_char(pdu->u.deliver_sm.source_addr, 0) == '+' && + octstr_check_range(pdu->u.deliver_sm.source_addr, 1, 256, gw_isdigit)) || + octstr_check_range(pdu->u.deliver_sm.source_addr, 0, 256, gw_isdigit))) { /* check if we received leading '00', then remove it*/ if (octstr_search(pdu->u.deliver_sm.source_addr, octstr_imm("00"), 0) == 0)
pgp00000.pgp
Description: signature