ber-tlv 1.0-11

BER-TLV reader and writer

License

License

Categories

Categories

Net
GroupId

GroupId

com.payneteasy
ArtifactId

ArtifactId

ber-tlv
Last Version

Last Version

1.0-11
Release Date

Release Date

Type

Type

jar
Description

Description

ber-tlv 1.0-11
BER-TLV reader and writer
Project URL

Project URL

https://github.com/evsinev/ber-tlv
Source Code Management

Source Code Management

https://github.com/evsinev/ber-tlv

Download ber-tlv

How to add to project

<!-- https://jarcasting.com/artifacts/com.payneteasy/ber-tlv/ -->
<dependency>
    <groupId>com.payneteasy</groupId>
    <artifactId>ber-tlv</artifactId>
    <version>1.0-11</version>
</dependency>
// https://jarcasting.com/artifacts/com.payneteasy/ber-tlv/
implementation 'com.payneteasy:ber-tlv:1.0-11'
// https://jarcasting.com/artifacts/com.payneteasy/ber-tlv/
implementation ("com.payneteasy:ber-tlv:1.0-11")
'com.payneteasy:ber-tlv:jar:1.0-11'
<dependency org="com.payneteasy" name="ber-tlv" rev="1.0-11">
  <artifact name="ber-tlv" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.payneteasy', module='ber-tlv', version='1.0-11')
)
libraryDependencies += "com.payneteasy" % "ber-tlv" % "1.0-11"
[com.payneteasy/ber-tlv "1.0-11"]

Dependencies

test (3)

Group / Artifact Type Version
junit : junit jar 4.12
org.slf4j : slf4j-api jar 1.7.25
org.slf4j : slf4j-log4j12 jar 1.7.25

Project Modules

There are no modules declared in this project.

maven Build Status CircleCI

BER-TLV parser and builder

BerTlv is a java library for parsing and building BER TLV encoded data.

Features

  • supported types: amount, date, time, text, BCD, bytes
  • thread safe (provides immutable container BerTlv)
  • production ready (uses in several projects)
  • lightweight (no external dependencies)

Setup with dependency managers

Maven

<dependency>
  <groupId>com.payneteasy</groupId>
  <artifactId>ber-tlv</artifactId>
  <version>1.0-11</version>
</dependency>

Gradle

implementation 'com.payneteasy:ber-tlv:1.0-11'

How to parse

byte[] bytes = HexUtil.parseHex("50045649534157131000023100000033D44122011003400000481F");

BerTlvParser parser = new BerTlvParser(LOG);
BerTlvs tlvs = parser.parse(bytes, 0, bytes.length);
  
BerTlvLogger.log("    ", tlvs, LOG);

How to build

byte[] bytes =  new BerTlvBuilder()
                .addHex(new BerTag(0x50), "56495341")
                .addHex(new BerTag(0x57), "1000023100000033D44122011003400000481F")
                .buildArray();

License

The BerTlv framework is licensed under the Apache License 2.0

Versions

Version
1.0-11
1.0-10
1.0-9
1.0-8
1.0-7
1.0-6
1.0-5
1.0-4
1.0-3