Giter Site home page Giter Site logo

tochemey / netcore8583 Goto Github PK

View Code? Open in Web Editor NEW
31.0 31.0 20.0 174 KB

NetCore8583 is a library that helps parse/read and generate ISO 8583 messages for .NET Core

License: MIT License

C# 100.00%
banking csharp dotnet-core financial-data iso8583 netcore

netcore8583's People

Contributors

amammes avatar tochemey avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

netcore8583's Issues

Fields with decimals throws an error

If we have decimals in the field num's then we get an exception. This is a 'valid' ISO message scenario, for example in Postilion Payment Switch interface they do have this a lot and we need to cater for this.

To Reproduce
Use below config file

<?xml version="1.0" encoding="UTF-8"?>

<n8583-config>

    <header type="0100">0100</header>

  <template type="0100">        
        <!-- Original Card Acceptor ID Code -->
        <field num="127.48" type="LLLVAR" />
        <!-- Dynamic Currency Conversion (DCC) status code -->
        <field num="127.49" type="LLLVAR" />
        <!-- Card Acceptor Additional Data -->
        <field num="127.59" type="LLLVAR" />
        <!-- Payment Token Identifier -->

    </template>

</n8583-config>

Expected Result
Works the same as if it was an integer

Observed Result
Logger.Error($"ISO8583 Cannot parse XML configuration {e}");

image

Get in touch

I would like to get in touch with you urgently 0244937428

User guide to use NetCore8583

Hello there. What's up?

May you share a user guide to use NetCore8583 ?

Or maybe you cloud explain how I can to use it

I can't find out how I can use it.

Add coverage report

Is your feature request related to a problem? Please describe.
This will show the code coverage level of the project and set a benchmark for any PR request.

Describe the solution you'd like
Add the coverlet dependency and enable codecov on the repo to display coverage report

Dictionary error

Hi,

I'm trying to use your library and it seems I'm getting errors.

The given key '-16' was not present in the dictionary.

License?

Could please you add license statement for this library?

Is it MIT?

Can't parse message if the field 125 is in parsing template while it's not in the message

Hi @Tochemey !

Trying to use your lib with the UK FasterPayments (FPS) integration and there's might be an issue:

Message: 9804000001020000000089118000000000000000007 (Type 9804, ASCII, BCD bitmap)

FPS has their own implemetation of the ISO8583 and fields of the message above are:

  • 24, Numeric, Lenght 3 (n 3)
  • 31, LLVAR (ans..18)
  • 125, LLVAR (ans..60)

The problem with the 125 field that is conditional and it might be in the message (with the secondary bitmap) but might be not (therefore secondary bitmap is also absent). So the description of the lib says:

A message does not need to contain all the fields specified in a parsing template, but a parsing template must contain all the fields specified in the bitmap of a message, or the MessageFactory won't be able to parse it because it has no way of knowing how it should parse that field (and also all subsequent fields).

And it works perfectly with fields up to 64 even though they are not presented in the message. But once I have field 125 in my parsing template and it is not presented in the message AND secondary bitmap is not presented as well the parsing crashes with the message in my case:

System.ArgumentOutOfRangeException: 'Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index') Actual value was 124.'

If I remove 125 from parsing template, then it works.

What I want is be able to put any conditional fields in the parsing template regardless of bitmap they are belong and get correct message with posibility to check whether conditional fields parsed or not. Looks like the lib relies on the bitmaps presented, so If there are no field AND no bitmap it crashes.

Seems like it's MessageFactory.cs, Line 588:
if (bs.Get(i - 1))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.