Ah, I understand you now.

Can I make my own specific handler to deliver_sm PDU's (or reroute to my 
handler), that have reserved esm_class? For example send the decode deliver_sm 
PDU with esm_class = 0x1c to php script ?


>Понедельник, 26 марта 2018, 16:52 +05:00 от [email protected]:
>
>This is the same as I answered to you.
>
>bit 2 and bit 3 are set (this indicates delivery report) and even worse bits 4 
>and 3 and 2 are set (that means reserved!).
>Reserved doesn’t mean reserved for _buggy_ smsc but means reserved for any 
>usage not specified in the spec.
>
>Thanks,
>Alex
>
>
>>Am 26.03.2018 um 12:15 schrieb Сергей Сергеевич Батманов < 
>>[email protected] >:
>>thank you for your answer.
>>
>>But esm_class in the first example is esm_class= 0x1c, or in binary (00 0111 
>>00). 
>>
>>the deliver_sm PDU is sent by SMSC to ESME and the esm_class parameter is 
>>encoded as follows in a deliver_sm (see attachment).
>>
>>I undestand that the esm_class=0x1c means:
>>
>>x x 0 1 1 1 x x reserved
>>
>>Am I right?
>>
>>
>><image.png>
>>
>>
>>>Понедельник, 26 марта 2018, 14:57 +05:00 от  [email protected] :
>>>
>>>Hi,
>>>
>>>you provider sent wrong esm_class in the first example. His esm_class = 0x1c 
>>>, bits 1 and 2 set and this means 
>>> -  Short Message contains MC Delivery Receipt 
>>>-  Short Message contains Delivery Acknowledgement 
>>>
>>>But none of this is true, because this is regular MO and not delivery 
>>>receipt for any MT message sent.
>>>
>>>See attachment for the esm_class bits.
>>>
>>>Kannel can do nothing in this situation. Please contact your _buggy_ smsc 
>>>provider and let them fix it.
>>>
>>>Thanks,
>>>Alex
>>><Bildschirmfoto 2018-03-26 um 11.52.15.png>
>>>
>>>>Am 26.03.2018 um 07:15 schrieb Сергей Сергеевич Батманов < 
>>>>[email protected] >:
>>>>Hi, there.
>>>>
>>>>I have a problem with incoming deliver_sm.
>>>>
>>>>Kannel can't parse DLR and gives error. The problem is that i don't send 
>>>>submit_sm, this pdu deliver_sm is special notification from provider with 
>>>>next short_message:
>>>>20180325102847+PayDay+0+20180326103303+2.5+28766
>>>>
>>>>Deliver_sm is not a delivery report and doesn't have message_id.
>>>>
>>>>1. What I can do with this erorr and how can i save this deliver_sm to db?
>>>>
>>>>2. I have another deliver_sm, that doesn't give same error, but kannel 
>>>>can't decode short_message.
>>>>
>>>>I try change msg-id-type, alt-charset and it doesn't work.
>>>>
>>>>Any ideas?
>>>>
>>>>
>>>>It's the first deliver_sm.
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP[smstele2]: Got PDU:
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP PDU 0x7f23c80025b0 dump:
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: type_name: deliver_sm
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: command_id: 5 = 0x00000005
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: command_status: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: sequence_number: 1435116073 = 
>>>>0x558a2229
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: service_type: NULL
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: source_addr_ton: 1 = 0x00000001
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: source_addr_npi: 1 = 0x00000001
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: source_addr: "79519881890"
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: dest_addr_ton: 1 = 0x00000001
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: dest_addr_npi: 1 = 0x00000001
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: destination_addr: "683"
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: esm_class: 28 = 0x0000001c
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: protocol_id: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: priority_flag: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: schedule_delivery_time: NULL
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: validity_period: NULL
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: registered_delivery: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: replace_if_present_flag: 0 = 
>>>>0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: data_coding: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: sm_default_msg_id: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: sm_length: 51 = 0x00000033
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: short_message:
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: Octet string at 0x7f23c8000b60:
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: len: 51
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: size: 52
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: immutable: 0
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: data: 32 30 31 38 30 33 32 35 31 30 
>>>>32 38 34 37 2b 50 20180325102847+P
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: data: 61 79 44 61 79 2b 30 2b 32 30 
>>>>31 38 30 33 32 36 ayDay+0 +20180326
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: data: 31 30 33 33 30 33 2b 32 2e 35 
>>>>2b 32 38 37 36 36 103303+2.5+28766
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: data: 31 33 32 132
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: Octet string dump ends.
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP PDU dump ends.
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP[smstele2] handle_pdu, got DLR
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP[smstele2]: Couldnot parse DLR 
>>>>string sscanf way,fallback to old way. Please report!
>>>>2018-03-25 15:02:26 [2579] [6] ERROR: SMPP[smstele2]: got DLR but could not 
>>>>find message or was not interested in it id<> dst<79519881890>, type<2>
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP[smstele2]: Sending PDU:
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP PDU 0x7f23c8006890 dump:
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: type_name: deliver_sm_resp
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: command_id: 2147483653 = 0x80000005
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: command_status: 0 = 0x00000000
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: sequence_number: 1435116073 = 
>>>>0x558a2229
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: message_id: NULL
>>>>2018-03-25 15:02:26 [2579] [6] DEBUG: SMPP PDU dump ends.
>>>>____________________________________________________
>>>>
>>>>And it's the second deliver_sm:
>>>>
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Optional parameter tag (0x0202)
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Optional parameter length read as 12
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Optional parameter tag (0x0204)
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Optional parameter length read as 2
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: SMPP[smstele2]: Got PDU:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: SMPP PDU 0x7f103c000a60 dump:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: type_name: deliver_sm
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: command_id: 5 = 0x00000005
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: command_status: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: sequence_number: 1232498810 = 
>>>>0x4976707a
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: service_type: NULL
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: source_addr_ton: 1 = 0x00000001
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: source_addr_npi: 1 = 0x00000001
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: source_addr: "79524022709"
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: dest_addr_ton: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: dest_addr_npi: 1 = 0x00000001
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: destination_addr: "683#6920813"
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: esm_class: 3 = 0x00000003
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: protocol_id: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: priority_flag: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: schedule_delivery_time: NULL
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: validity_period: NULL
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: registered_delivery: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: replace_if_present_flag: 0 = 
>>>>0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: data_coding: 8 = 0x00000008
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: sm_default_msg_id: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: sm_length: 6 = 0x00000006
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: short_message:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Octet string at 0x7f103c006680:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: len: 6
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: size: 7
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: immutable: 0
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: data: 04 35 04 49 04 35 .5.I.5
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Octet string dump ends.
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: user_message_reference: 84 = 
>>>>0x00000054
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: source_subaddress:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Octet string at 0x7f103c0066d0:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: len: 12
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: size: 13
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: immutable: 0
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: data: a0 37 39 30 34 33 34 39 30 30 
>>>>30 30 .79043490000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: Octet string dump ends.
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: SMPP PDU dump ends.
>>>>2018-03-25 05:35:04 [9914] [6] WARNING: smsbox_list empty!
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: SMPP[smstele2]: Sending PDU:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: SMPP PDU 0x7f103c006850 dump:
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: type_name: deliver_sm_resp
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: command_id: 2147483653 = 0x80000005
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: command_status: 0 = 0x00000000
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: sequence_number: 1232498810 = 
>>>>0x4976707a
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: message_id: NULL
>>>>2018-03-25 05:35:04 [9914] [6] DEBUG: SMPP PDU dump ends.
>>>>
>>>>________________________
>>>>
>>>>My config:
>>>>group = core
>>>>admin-port = 13000
>>>>smsbox-port = 13001
>>>>admin-password = pass
>>>>admin-deny-ip = "*.*.*.*"
>>>>admin-allow-ip = "127.0.0.1;192.168.*.*"
>>>>log-file = "/var/log/kannel/bearerbox.log"
>>>>log-level = 0
>>>>access-log = "/var/log/kannel/access.log"
>>>>box-allow-ip = "127.0.0.1;*.*.*.*"
>>>>dlr-storage = mysql
>>>>group = smsc
>>>>smsc = smpp
>>>>smsc-id = smstele2
>>>>system-type = VMA
>>>>host = <ip>
>>>>port = <port>
>>>>transceiver-mode = true
>>>>#interface-version = 34
>>>>smsc-username = <id>
>>>>smsc-password = <pass>
>>>>enquire-link-interval = 270
>>>>alt-charset = UTF-8
>>>>log-file = "/var/log/kannel/smstele2.log"
>>>>log-level = 0
>>>># ------ SQLBOX GROUP ------
>>>>group = sqlbox
>>>>id = sqlbox-db
>>>>smsbox-id = sqlbox
>>>>bearerbox-port = 13001
>>>>smsbox-port = 13005
>>>>smsbox-port-ssl = false
>>>>sql-log-table = sent_sms
>>>>sql-insert-table = send_sms
>>>>log-file = "/var/log/kannel/sqlbox.log"
>>>>log-level = 0
>>>># ------ MYSQL CONNECTION ------
>>>>group = mysql-connection
>>>>id = "sqlbox-db"
>>>>host = localhost
>>>>username = <name>
>>>>password = <pass>
>>>>database = smssqlbox
>>>>max-connections = 25
>>>># ------ SMSBOX GROUP ------
>>>>group = smsbox
>>>>smsbox-id = sqlbox-db
>>>>bearerbox-host = 127.0.0.1
>>>>bearerbox-port = 13005
>>>>sendsms-port = 13013
>>>>log-file = "/var/log/kannel/smsbox.log"
>>>>log-level = 0
>>>>access-log = "/var/log/kannel/sms-access.log"
>>>># ------ MYSQL CONNECTION ------
>>>>group = mysql-connection
>>>>id = bearerbox-dlr
>>>>host = localhost
>>>>username = <name>
>>>>password = <pass>
>>>>database = smsbearerbox
>>>>max-connections = 10
>>>># ------ DLR STORAGE CONFIGURATION ------
>>>>group = dlr-db
>>>>id = bearerbox-dlr
>>>>table = dlr_sms_kannel
>>>>field-smsc = smsc
>>>>field-timestamp = ts
>>>>field-destination = destination
>>>>field-source = source
>>>>field-service = service
>>>>field-url = url
>>>>field-mask = mask
>>>>field-status = status
>>>>field-boxc-id = boxc
>>>>Regards,
>>>>-- 
>>>>Sergey Batmanov
>>
>>
>>--  
>>Сергей Сергеевич Батманов


-- 
Сергей Сергеевич Батманов

Reply via email to