我在 WIKI 和 代码项目;我理解 ISO 8583 消息基本上可以分为 3 个部分:
- MTI(消息类型指示符)
1.1。 版
1.2 。消息类别
1.3。 消息功能
1.4. 消息源位
- 图
指示存在哪些数据元素。
- DataElement
整个 ISO 消息的本质,包含有关交易的信息,例如:
-
交易类型、
-
金额、
-
customerid 等。 p>
因此,在阅读这两个 Web 参考资料后,我想将 ISO 消息日志划分为 MTI、位图和数据元素。
例如:
(0800 2020000000800000 000000 000001 3239313130303031)
MTI: 0800 (1987 version, Network Management Message, Request, Acquirer)
Bitmap: 20 20 00 00 00 80 00 00 (eg. 20 = 0010 0000 ,so position 3 is on)
DataElement:(by seeing Bitmap , we can defined data element as follow)
field 03:000000 (Processing Code)
field 11:000001 (Systems trace audit number)
field 41:3239313130303031 (Card acceptor terminal idenfication)
但我的挑战是我的 ATM 机上已经有 ISO 8583 消息日志。
这个实际输出的消息日志并不像上面代码片段中的那样非常清晰。
所以我不能像上例那样将此消息分为 MTI、位图和数据元素。
00000:00 5B 30 31 31 30 30 30 30 30 30 30 30 38 32 30 80 38 00 00 [.[01100000000820.8..]
00020:00 81 00 00 04 00 00 00 00 00 00 00 33 36 32 39 31 30 31 30 [............36291010]
00040:32 39 35 37 31 30 33 31 31 30 30 30 30 30 30 35 30 33 31 53 [2957103110000005031S]
00060:55 32 30 31 31 31 30 33 31 31 30 32 39 35 37 32 30 31 31 31 [U2011103110295720111]
00080:30 33 31 31 30 32 39 35 37 33 30 30 31 [0311029573001 ]
我之前没有ISO 8583留言经验,欢迎提出建议。
I read about ISO 8583 messaging at WIKI and Code Project; I understood ISO 8583 messages can basically be divided in 3 parts:
- MTI (Message Type Indicator)
1.1. Version
1.2. Message Class
1.3. Message Function
1.4. Message Origin
- Bitmap
Indicate which data elements are present.
- DataElement
The essence of the whole ISO message, contain information about the transaction such as:
-
transaction type,
-
amount,
-
customerid, etc.
So, after reading these two web references, I want to make divide my ISO messaging log as MTI, bitmap, and Data Element.
For example:
(0800 2020000000800000 000000 000001 3239313130303031)
MTI: 0800 (1987 version, Network Management Message, Request, Acquirer)
Bitmap: 20 20 00 00 00 80 00 00 (eg. 20 = 0010 0000 ,so position 3 is on)
DataElement:(by seeing Bitmap , we can defined data element as follow)
field 03:000000 (Processing Code)
field 11:000001 (Systems trace audit number)
field 41:3239313130303031 (Card acceptor terminal idenfication)
But my challenge is that I already have ISO 8583 messaging log from my ATM Machine.
This actual output messaging log is not very clear like the one in the snippet above.
So I cannot divide this message to MTI, Bitmap and Data element like upper example.
00000:00 5B 30 31 31 30 30 30 30 30 30 30 30 38 32 30 80 38 00 00 [.[01100000000820.8..]
00020:00 81 00 00 04 00 00 00 00 00 00 00 33 36 32 39 31 30 31 30 [............36291010]
00040:32 39 35 37 31 30 33 31 31 30 30 30 30 30 30 35 30 33 31 53 [2957103110000005031S]
00060:55 32 30 31 31 31 30 33 31 31 30 32 39 35 37 32 30 31 31 31 [U2011103110295720111]
00080:30 33 31 31 30 32 39 35 37 33 30 30 31 [0311029573001 ]
I have no previous experience in ISO 8583 message and welcome suggestions.
发布评论
评论(3)
知道了,
该消息分为如下:
前2个字节是消息长度00 5B = 91
后跟 14 个字节的标头 = 01100000000820
后跟 BMP,如下所示:
字段 1 表示辅助 BMP 存在
我不确定 MTI 在哪里,会是标头尾部的 0820 ?因为它是 ASCII 格式的,通常它的数值为 08 20,但这可能是规范的一部分。 无论如何, 0820 表示网络管理建议
,解码后的 BMP 中的字段如下:
系统跟踪审核编号
本地交易时间 hh(24)mmss
本地交易日期 MMDD
终端 ID
请注意该字段中剩余数据之前的 3 位长度字段。这是一个通用(未来/私人使用)字段
网络管理信息代码<001 = 登录>
从 DE 70 值 001 开始,这是一条登录消息,必须是 0800 MTI。
要获取有关 MTI 位置和 DE 48 含义的更多信息,您应该阅读该设备的手册(技术规格)以获取更多信息。
Got it,
This message is divided as follows:
First 2 bytes are the message length 00 5B = 91
Followed by 14 bytes of header = 01100000000820
Followed somehow by BMP as follows:
Field 1 means secondary BMP exist
I am not sure where is MTI, will it be the 0820 at the trailer of the header? since it is in ASCII and usually it comes in numeric value of 08 20 but this might be part of the specs. 0820 means network management advice
anyways, the fields from the decoded BMP as follows:
System Trace Audit Number
Local transaction time hh(24)mmss
Local transaction date MMDD
terminal ID
notice the 3 digits length field preceding the remaining data in this field. which is a generic (future/private use) field
network management information code <001 = sign on>
From DE 70 value 001 this is a sign on message, which must be a 0800 MTI.
To get more information about the location of the MTI and the meaning of DE 48, you should read the manual (technical specs) of this device to get more information.
在发送 ISO 8583 消息时,我们将其转换为 BCD/HEX 形式,使用 Wireshark 工具
跟踪 IP 和端口之间的通信。
while sending ISO 8583 message we are converting it in BCD/HEX form ,use Wireshark tool to
track communication between IP and Ports.
一个好的在线位图分析工具是 https://neapay.com/online-tools /bitmap-fields-decoder.html。
有时,https://codebeautify.org/hex-string-converter 工具会有所帮助。
为了更好地理解 ISO 8583 消息格式,手动分析每个字段很有用。但是,每个字段可以具有不同格式(BCD、EBCDIC、ASCII ...)的长度和值子字段。并且某些字段可能具有内部字段,例如 BMP 48 或 60 经常用作嵌套字段树的容器。这些内部字段可以具有标签、长度和值。并且这些字段的嵌套字段可能又具有不同的格式:)。例如 https://github.com/credibledoc/credible-doc/blob/master/iso-8583-packer/doc/ebcdic/ebcdic-decimal-tag-packer.md页面描述了带有 EBCDIC 的字段标签和 BCD 值。
您可以使用 https://github.com/credibledoc/ credible-doc/tree/master/iso-8583-packer 用于构建 ISO 8583 消息的 Java 库(我是作者)。上面的 ISO 消息示例可以使用 iso-8583-packer 库进行解包和打包。
消息数据:
消息结构:
上面的示例可以在 GitHub 上找到 https://github.com/credibledoc/credible-doc/blob/master/iso-8583-packer/src/test/java/com/credibledoc/iso8583packer/examples/UnderstandingIso8583MessageLogTest.java
BMP 55通常包含 TLV EMV 数据。 https:// paymentcardtools.com/emv-tlv-parser 工具在这种情况下很有用。
A good online bitmap analysis tool is https://neapay.com/online-tools/bitmap-fields-decoder.html.
Sometime helps the https://codebeautify.org/hex-string-converter tool.
For a better understanding of the ISO 8583 message format, it is useful to analyse each field manually. However, each field can have length and value subfields in different formats (BCD, EBCDIC, ASCII ...). And some fields may have inner fields, for example BMP 48 or 60 often used as containers for nested field trees. These inner fields may have tag, length and value. And nested fields of these fields may have different formats again :). For example the https://github.com/credibledoc/credible-doc/blob/master/iso-8583-packer/doc/ebcdic/ebcdic-decimal-tag-packer.md page describes a field with EBCDIC tag and BCD value.
You can use the https://github.com/credibledoc/credible-doc/tree/master/iso-8583-packer Java library (I am the author) for building ISO 8583 messages. The example of ISO message above can be unpacked and packed with the iso-8583-packer library.
Message data:
Message Structure:
The example above can be found on GitHub https://github.com/credibledoc/credible-doc/blob/master/iso-8583-packer/src/test/java/com/credibledoc/iso8583packer/examples/UnderstandingIso8583MessageLogTest.java
BMP 55 often contains TLV EMV data. The https://paymentcardtools.com/emv-tlv-parser tool is useful in the case.