All Projects → kpavlov → Jreactive 8583

kpavlov / Jreactive 8583

Licence: apache-2.0
Java Client & Server for ISO8583 & Netty

Programming Languages

java
68154 projects - #9 most used programming language
kotlin
9241 projects

Projects that are alternatives of or similar to Jreactive 8583

Ts3admin.class
The ts3admin.class is a powerful api for communication with Teamspeak 3 Servers from your website! Your creativity knows no bounds!
Stars: ✭ 103 (-58.47%)
Mutual labels:  library, server
Ruffles
Lightweight and fully managed reliable UDP library.
Stars: ✭ 131 (-47.18%)
Mutual labels:  library, protocol
Mmo Server
Distributed Java game server, including login, gateway, game demo
Stars: ✭ 114 (-54.03%)
Mutual labels:  server, netty
Webdriver Rust
Library implementing the wire protocol for the W3C WebDriver standard.
Stars: ✭ 56 (-77.42%)
Mutual labels:  library, protocol
Quarry
Python library that implements the Minecraft network protocol and data types
Stars: ✭ 182 (-26.61%)
Mutual labels:  server, protocol
Async Gamequery Lib
A high-performance java game query library designed for steam/source based games and others
Stars: ✭ 88 (-64.52%)
Mutual labels:  library, netty
Javaosc
OSC content format/"protocol" library for JVM languages
Stars: ✭ 116 (-53.23%)
Mutual labels:  library, protocol
Awareness
The new architecture of co-computation for data processing and machine learning.
Stars: ✭ 11 (-95.56%)
Mutual labels:  library, protocol
Gophertunnel
Toolbox for Minecraft software written in Go
Stars: ✭ 156 (-37.1%)
Mutual labels:  server, protocol
Carmelo
Carmelo is a fast, scalable Java server framework designed for online games. It uses Netty and Fastjson for highly efficient network transmission and supports both TCP/HTTP protocols.
Stars: ✭ 148 (-40.32%)
Mutual labels:  server, netty
Whatpulse
WhatPulse reverse engineered
Stars: ✭ 30 (-87.9%)
Mutual labels:  library, protocol
Simple Web Server
A very simple, fast, multithreaded, platform independent HTTP and HTTPS server and client library implemented using C++11 and Boost.Asio. Created to be an easy way to make REST resources available from C++ applications.
Stars: ✭ 2,261 (+811.69%)
Mutual labels:  library, server
Openps3ftp
An open source FTP server for the PlayStation 3.
Stars: ✭ 29 (-88.31%)
Mutual labels:  library, server
Cocsharp
Clash of Clans library, proxy and server written in .NET [Unmaintained]
Stars: ✭ 94 (-62.1%)
Mutual labels:  library, server
Python Opcua
LGPL Pure Python OPC-UA Client and Server
Stars: ✭ 863 (+247.98%)
Mutual labels:  library, protocol
Laravel Parse
A Parse SDK bridge for Laravel 5
Stars: ✭ 116 (-53.23%)
Mutual labels:  library, server
Game Server
Distributed Java game server, including cluster management server, gateway server, hall server, game logic server, background monitoring server and a running web version of fishing. State machine, behavior tree, A* pathfinding, navigation mesh and other AI tools
Stars: ✭ 916 (+269.35%)
Mutual labels:  server, netty
M2x Python
AT&T M2X Python Library
Stars: ✭ 25 (-89.92%)
Mutual labels:  client-library, library
Jstp
Fast RPC for browser and Node.js based on TCP, WebSocket, and MDSF
Stars: ✭ 132 (-46.77%)
Mutual labels:  server, protocol
Autoserver
Create a full-featured REST/GraphQL API from a configuration file
Stars: ✭ 188 (-24.19%)
Mutual labels:  library, server

JReactive-8583

Free ISO8583 Connector for JDK (Netty)

Maven Central Travis Libraries.io for GitHub Codacy Badge Maintainability Test Coverage

Motivation

  1. jPOS library is not free for commercial use.
  2. j8583 is free but does not offer network client

Solution: "J-Reactive-8583" ISO8583 Client and Server built on top of excellent Netty asynchronous messaging framework with the help of j8583 for encoding/decoding. It is distributed under Apache License 2.0.

Supported Features

  • Client and Server endpoints.
  • Java 11+
  • Support ISO8583 messages using j8583 library.
  • Customizable ISO MessageFactory.
  • Automatic responding to Echo messages.
  • Automatic client reconnection.
  • Secure message logger: mask PAN and track data or any other field (customizable). Optionally prints field descriptions.
  • Configurable netty Bootstrap and ChannelPipeline

ISO8583 TCP/IP Transport

For data transmission TCP/IP uses sessions. Each session is a bi-directional data stream. The protocol uses a single TCP/IP session to transfer data between hosts in both directions.

The continuous TCP/IP data stream is split into frames. Each ISO8583 message is sent in a separate frame.

A Frame consists of an N-byte length header and message body. Usually, N==2. The header contains the length of the following message. The high byte of value is transmitted first, and the low byte of value is transmitted second.

N bytes M bytes
Message Length = M ISO–8583 Message

Getting Started

Add dependency to your project:

<dependencies>
    <dependency>
        <groupId>com.github.kpavlov.jreactive8583</groupId>
        <artifactId>netty-iso8583</artifactId>
        <version>${VERSION}</version>
    </dependency>
</dependencies>

Now you may use ISO8583 client or server in your code.

Creating and Using ISO-8583 Client

The minimal client workflow includes:

var messageFactory = new J8583MessageFactory<>();// [1]
Iso8583Client<IsoMessage> client = new Iso8583Client<>(messageFactory);// [2]

client.addMessageListener(new IsoMessageListener<IsoMessage>() { // [3]
    ...
});
client.getConfiguration().replyOnError(true);// [4]
client.init();// [5]

client.connect(host, port);// [6]
if (client.isConnected()) { // [7]

    IsoMessage message = messageFactory.newMessage(...);
    ...
    client.sendAsync(message);// [8]
    // or
    client.send(message);// [9]
    // or
    client.send(message, 1, TimeUnit.SECONDS);// [10]
}

...
client.shutdown();// [11]
  1. First you need to create a MessageFactory
  2. Then you create a Iso8583Client providing MessageFactory and, optionally, SocketAddress
  3. Add one or more custom IsoMessageListeners to handle IsoMessages.
  4. Configure the client. You may omit this step if you're fine with default configuration.
  5. Initialize a client. Now it is ready to connect.
  6. Establish a connection. By default, if connection will is lost, it reconnects automatically. You may disable this behaviour or change reconnectInterval.
  7. Verify that connection is established
  8. Send IsoMessage asynchronously
  9. Send IsoMessage synchronously
  10. Send IsoMessage synchronously with timeout support
  11. Disconnect when you're done.

Creating and Using ISO-8583 Server

Typical server workflow includes:

var messageFactory = new J8583MessageFactory<>(ConfigParser.createDefault(), ISO8583Version.V1987);// [1]
Iso8583Server<IsoMessage> server = new Iso8583Server<>(port, messageFactory);// [2]

server.addMessageListener(new IsoMessageListener<IsoMessage>() { // [3]
    ...
});
server.getConfiguration().replyOnError(true);// [4]
server.init();// [5]

server.start();// [6]
if (server.isStarted()) { // [7]
    ...
}

...
server.shutdown();// [8]
  1. First you need to create a MessageFactory
  2. Then you create a Iso8583Server providing MessageFactory and port to bind to
  3. Add one or more custom IsoMessageListeners to handle IsoMessages.
  4. Configure the server. You may omit this step if you're fine with default configuration.
  5. Initialize a server. Now it is ready to start.
  6. Start server. Now it is ready to accept client connections.
  7. Verify that the server is started
  8. Shutdown server when you're done.

Logging

Default IsoMessageLoggingHandler may produce output like:

312 [nioEventLoopGroup-5-1] DEBUG IsoMessageLoggingHandler - [id: 0xa72cc005, /127.0.0.1:50853 => /127.0.0.1:9876] MTI: 0x0200
  2: [Primary account number (PAN):NUMERIC(19)] = '000400*********0002'
  3: [Processing code:NUMERIC(6)] = '650000'
  7: [Transmission date & time:DATE10(10)] = '0720233443'
  11: [System trace audit number:NUMERIC(6)] = '483248'
  32: [Acquiring institution identification code:LLVAR(3)] = '456'
  35: [Track 2 data:LLVAR(17)] = '***'
  43: [Card acceptor name/location (1-23 address 24-36 city 37-38 state 39-40 country):ALPHA(40)] = 'SOLABTEST TEST-3 DF MX                  '
  49: [Currency code, transaction:ALPHA(3)] = '484'
  60: [Reserved national:LLLVAR(3)] = 'foo'
  61: [Reserved private:LLLVAR(5)] = '1234P'
  100: [Receiving institution identification code:LLVAR(3)] = '999'
  102: [Account identification 1:LLVAR(4)] = 'ABCD'

Using client or server configuration

You may:

  • enable message logging. As of 0.2.2 logging is disabled by default (#50).
  • enable and disable printing of sensitive information, like PAN
  • customize which fields should be masked in logs
  • enable and disable printing field descriptions
  • customize tcp frame length field length
  • customize ISO 8583 version

See ConnectorConfiguration, ServerConfiguration and ClientConfiguration.


For frequently asked questions check the FAQ page.

ISO 8583 Links

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].