Closed walter-weinmann closed 6 years ago
@walter-weinmann
Its looks like the test case has some issues:
{"submit_multi_resp_issue_63", "00 00 00 A6 80 00 00 21 00 00 00 00 00 00 00 01 74 68 69 73 5F 63 6F 75 6C " "64 5F 62 65 5F 61 5F 6D 65 73 73 61 67 65 5F 69 64 00 06 01 01 08 31 36 38 " "2E 31 32 33 2E 32 33 34 2E 33 32 31 00 00 00 00 FF 01 04 00 31 32 37 2E 30 " "2E 30 2E 31 00 00 00 00 0F 01 02 06 31 36 38 2E 31 32 33 2E 32 33 34 2E 33 " "32 31 00 00 00 04 00 01 01 01 31 39 32 2E 31 2E 31 2E 31 30 00 00 00 04 FF " "01 00 00 31 36 38 2E 31 32 33 2E 32 33 34 2E 33 32 31 00 00 00 00 0F 01 02 " "0A 31 39 32 2E 31 2E 31 2E 31 30 00 00 00 01 12"}
I tried to analying your test PDU manually and this is so far I have got with it:
00 00 00 A6 % command_length (166)
80 00 00 21 % command_id (submit_multi_resp)
00 00 00 00 % command_status (ESME_ROK)
00 00 00 01 % sequence_number (1)
% message_id ("this_could_be_a_message_id\0")
74 68 69 73 5F 63 6F 75 6C 64 5F 62 65 5F 61 5F 6D 65 73 73 61 67 65 5F 69 64 00
06 % no_unsuccess (6)
% #1 dest_addr_ton 1(International), dest_addr_npi 1 (ISDN), destination_addr (??)
% error_status_code ESME_RUNKNOWNERR (0xFF)
01 01 08 31 36 38 2E 31 32 33 2E 32 33 34 2E 33 32 31 00 00 00 00 FF
% #2 dest_addr_ton 1(International), dest_addr_npi 4 (Telex), destination_addr (??)
% error_status_code ESME_RINVSYSID (0x0F)
01 04 00 31 32 37 2E 30 2E 30 2E 31 00 00 00 00 0F
% #3 dest_addr_ton 1(International), dest_addr_npi 2 (?), destination_addr (??)
% error_status_code ESME_RINVBNDSTS (0x04)
01 02 06 31 36 38 2E 31 32 33 2E 32 33 34 2E 33 32 31 00 00 00 04
% #4 dest_addr_ton 1(International), dest_addr_npi 2 (?), destination_addr (??)
% error_status_code ESME_RINVBNDSTS (0x04)
00 01 01 01 31 39 32 2E 31 2E 31 2E 31 30 00 00 00 04
% #5 dest_addr_ton ?, dest_addr_npi ?, destination_addr ?
% error_status_codeESME_RINVSYSID (0x0F)
FF 01 00 00 31 36 38 2E 31 32 33 2E 32 33 34 2E 33 32 31 00 00 00 00 0F
% #6 dest_addr_ton ?, dest_addr_npi ?, destination_addr ?
% error_status_code ?
01 02 0A 31 39 32 2E 31 2E 31 2E 31 30 00 00 00 01 12
Can you please verify / confirm if the above is correct and help me fix the ? parts?
Test data generated in the wrong format.
@walter-weinmann Shouldn't this be removed too? https://github.com/K2InformaticsGmbH/smpp_parser/blob/79493e8e7129cadc6d9ee7e08850effdd2fb5147/src/smpp.erl#L1044-L1052
See PR #66.
Example: