About ISO8583
ISO 8583 is a "must-understand" item to handle card-oriented transaction system. Good understanding of ISO 8583 will help you to achieve the project's goal easily. In this article, the basic concept about ISO8583 and some details are mentioned and I wish that is helpful to you.

On the other hand, to deal with daily activities associated with ISO 8583, like debugging, analysis of specific ISO 8583 transactions, a set of basic tools will help you to save your time. Some of them can save you up to 15 or 20 minutes per each. For example our ISO 8583 Message Dumper.

By Quentin Sherman Xue - CEO


What is it and what consist of?

To understand what ISO8583 is in a practical and simple way: an ISO8583 message is a string and consists of three parts.

  1. MTI - Message Type Indicator: This field is a 4-digit numeric field indicating the type of message.
  2. BITMAP - This is a field of 16 or 32 hexadecimal digits. When the length of the bitmap is 16, it means the only primary bitmap is consisted and when the length is 32, the primary and secondary bitmap are consisted of.
  3. Data - data fields defined by the bitmap.


Example of an ISO8583 message

    02004200040000000002161234567890123456060
    9173030123456789ABC1000123456789012345678
    90123456789012345678901234567890123456789
    0123456789012345678901234567890123456789
Where:
    0200 - MTI (Message Type Indicator),
    4200040000000002 - primary bitmap,
    161234567890123456 - field 2, the first 2 digits: 16, is length indicator
    0609173030 - field 7,
    123456789ABC - field 22,
    012345678901234567890123456789012345678901234567890\
    1234567890123456789012345678901234567890123456789 - field 63.

For what is it used for?

ISO8583 message is used in bank or financial institutes card-originated transactions. But sometime, those not card-originated transactions also use ISO8583.


ISO8583 Definition

For each field (also called bit), there is a unique and specific definition for its use. Some fields are fixed in length and some are variable in length with an length indicator. The set of definitions for those 128 fields is called an ISO8583 Definition.

It is important to realize that an ISO8583 message can only work properly against its own definition. There are several standards ISO8583 definitions which are defined for years 1987, 1993 and 2003, but in real-life usage, many companies modify and create their own ISO8583 Definition. Therefore, an ISO8583 message may be valid for a definition, but invalid for another definition.


What tools should have to work with ISO8583?

In terms of implementation of ISO8583, the followings are must-have tools:

  1. Parser (also called unpacker) of ISO8583: the role of the parser is to validate and convert an ISO8583 message to a set of fields values that can be used for application program. Validation and conversion are made against a specific definition of ISO8583.
  2. Packer of ISO8583: Packer's role is to build and ISO8583 message from the separate fields values. Also, the construction of an ISO8583 message is make against a specific definition of ISO8583.
  3. An ISO8583 bitmap dumper: Tool to show which field are in a bitmap.
  4. An ISO8583 dumper: which is a tool to display an ISO8583 message's fields. It will make it easier to analyze which fields are included of an ISO8583 message. A handmade analysis required 3 to 20 minutes depending on size of message, with the help of this tool will be made instantly.
  5. An ISO8583 Definition Customizer: A tool that lets you create a new ISO8583 definition for your own use.



Typical Fields an ISO8583 message

A typical message might include such fields:

  1. MTI - Message Type Indicator.
  2. Bit 2 - Primary Account Number (PAN)
  3. Bit 3 - Processing Code
  4. Bit 7 - Date and Time of transmission
  5. Bit 11 - Audit Code
  6. Bit 12 - Local time transaction
  7. Bit 13 - Local transaction date
  8. Bit 32 - Identification code of the institution of acquisition
  9. Bit 38 - The authorization code in response
  10. Bit 39 - Response Code
  11. Bit 49 - Currency code of transaction

Different format of ISO8583 Message

For a switch system which routes transactions from POS/ATM or WEB to different banks and / or financial institutions should be able to different types of ISO8583. There are several types of exchanging formats of ISO8583, but can be classified into two groups: ASCII or Binary.

For an ISO8583 like this

[000] [0200]
[002] [1234567890123456]
[007] [20100609173030]
[022] [ABC123]
[063] [012345678901234567890123456789012345678901234567890\
1234567890123456789012345678901234567890123456789]
  1. ASCII

    ASCII format, this ISO8583 message looks like:

    00000000H 30 32 30 30 34 32 30 30 30 34 30 30 30 30 30 30 0200420004000000
    00000010H 30 30 30 32 31 36 31 32 33 34 35 36 37 38 39 30 0002161234567890
    00000020H 31 32 33 34 35 36 30 36 30 39 31 37 33 30 33 30 1234560609173030
    00000030H 41 42 43 31 32 33 20 20 20 20 20 20 31 30 30 30 ABC123......1000
    00000040H 31 32 33 34 35 36 37 38 39 30 31 32 33 34 35 36 1234567890123456
    00000050H 37 38 39 30 31 32 33 34 35 36 37 38 39 30 31 32 7890123456789012
    00000060H 33 34 35 36 37 38 39 30 31 32 33 34 35 36 37 38 3456789012345678
    00000070H 39 30 31 32 33 34 35 36 37 38 39 30 31 32 33 34 9012345678901234
    00000080H 35 36 37 38 39 30 31 32 33 34 35 36 37 38 39 30 5678901234567890
    00000090H 31 32 33 34 35 36 37 38 39 30 31 32 33 34 35 36 1234567890123456
    000000a0H 37 38 39                                        789
    

    This type of ISO8583 message is easier to be transported from one environment to another (the environment also called zone). Not as binary type of ISO8583, often must be encoded to be transported to another zone. The disadvantage on the ASCII format is the total length of message is longer than the binary.

  2. Binary

    For the same ISO8583 message, the binary format is looks like:

    00000000H 02 00 42 00 04 00 00 00 00 02 16 12 34 56 78 90 ..B.........4Vx.
    00000010H 12 34 56 06 09 17 30 30 41 42 43 31 32 33 20 20 .4V...00ABC123..
    00000020H 20 20 20 20 01 00 30 31 32 33 34 35 36 37 38 39 ......0123456789
    00000030H 30 31 32 33 34 35 36 37 38 39 30 31 32 33 34 35 0123456789012345
    00000040H 36 37 38 39 30 31 32 33 34 35 36 37 38 39 30 31 6789012345678901
    00000050H 32 33 34 35 36 37 38 39 30 31 32 33 34 35 36 37 2345678901234567
    00000060H 38 39 30 31 32 33 34 35 36 37 38 39 30 31 32 33 8901234567890123
    00000070H 34 35 36 37 38 39 30 31 32 33 34 35 36 37 38 39 4567890123456789
    00000080H 30 31 32 33 34 35 36 37 38 39                   0123456789
    

    Clearly, the length over the same binary format ISO8583 is shorter than in ASCII format. To use binary format, there is an obligation for "padding". In this example, the field type LLLVAR of field 63 is therefore in ASCII format begins with 1000123456... But in binary format, the type LLLVAR became something like "0100" which takes a zero padded on the left of field's length, so it becomes field LLLLVAR.




Questions, feedback, suggestions? We would love to hear from you!