convertlib
Fast and error resilient codecs. Supports Base2, Base8, Base16, Base32, Base64, BigInt, UTF-8, and the PHC/crypt string format.
3.6.1
60K downloads/mo
#1370 most downloaded on pub.dev
bitanon/convertlib
What this package is like to depend on
Last release 1 months ago
22 Jul 2026
Too new to tell
only 2 release windows
Nearly every release is documented
notes for 5 of 5 stable releases
Nothing withdrawn
no release was ever pulled
1 months old
5 releases · first in 2026
5 releases in the last 12 months
see the full history below
Release timeline
5 releases · Jul 2026 to Jul 2026Releases
latest 5-
3.6.122 Jul 2026Release notes
Open source →- Update
README.mdfor the 3.6.0 API: theto<Name>Bytesbyte encoders, the
non-throwingtryFrom<Name>decoders,constantTimeEquals, the exported
converter base classes, and the case-insensitive Crockford decoding.
Full Changelog: v3.6.0...v3.6.1
Release notes
Open source →- Update
README.mdfor the 3.6.0 API: theto<Name>Bytesbyte encoders, the non-throwingtryFrom<Name>decoders,constantTimeEquals, the exported converter base classes, and the case-insensitive Crockford decoding.
- Update
-
3.6.022 Jul 2026Release notes
Open source →- [Breaking Changes]
CipherlibConverter->BitConverter(the exported bit-converter base class).BigIntDecodernarrows fromConverter<BigInt, Iterable<int>>to
Converter<BigInt, Uint8List>;BigIntCodecdecoders now return aUint8List.
- Export the
ByteEncoder,ByteDecoder,AlphabetEncoder, andAlphabetDecoder
base classes, previously part of the API surface but not reachable through
package:convertlib/convertlib.dart. - Add
constantTimeEquals, a top-level constant-time byte comparison for
verifying MACs and digests without wrapping them in aByteCollector. - Add
toHexBytes,toBinaryBytes,toOctalBytes,toBase32Bytes, and
toBase64Bytes, returning the encoded ASCII output as aUint8Listwithout
the intermediateString. - Add non-throwing decoders
tryFromHex,tryFromBinary,tryFromOctal,
tryFromBase32,tryFromBase64,tryFromUtf8, andtryFromBigInt, which
returnnullinstead of throwing aFormatExceptionon invalid input. - Fix the UTF-8 encoder emitting invalid bytes for scalar code points in
U+10000..U+10FFFF;UTF8Encoder.convertnow uses the 4-byte form (the public
toUtf8was unaffected). Verified againstdart:convert. - Make the Crockford Base-32 decoder case-insensitive and decode the ambiguous
lettersI/i/L/las1andO/oas0. Encoding output is unchanged. - Fix
ByteCollector.numbertruncating values wider than 32 bits on the web; it
now accumulates with multiplication and is exact up to2^53(VM unchanged). ByteCollector.isEqualreturnsfalsefor a [String] that is not valid
hexadecimal instead of throwing aFormatException, matching its contract.- Add value-based
==andhashCodetoCryptData; a null and an empty
paramsmap now compare equal (both encode to the same string). - PHC/crypt: allow empty parameter values (e.g.
$id$data=), and fix the decoder
mis-classifying a comma-containingv=...segment as the version. - Speed up
fromBase32/fromBase64decoding and the genericAlphabetEncoderby
removing extra allocations and passes; output is byte-identical. - Clarify the
FormatExceptionmessage for non-canonical encoded input:
'Invalid length'is now'Invalid length or non-zero trailing bits'.
Full Changelog: v3.5.1...v3.6.0
Release notes
Open source →- [Breaking Changes]
CipherlibConverter->BitConverter(the exported bit-converter base class).BigIntDecodernarrows fromConverter<BigInt, Iterable<int>>toConverter<BigInt, Uint8List>;BigIntCodecdecoders now return aUint8List.
- Export the
ByteEncoder,ByteDecoder,AlphabetEncoder, andAlphabetDecoderbase classes, previously part of the API surface but not reachable throughpackage:convertlib/convertlib.dart. - Add
constantTimeEquals, a top-level constant-time byte comparison for verifying MACs and digests without wrapping them in aByteCollector. - Add
toHexBytes,toBinaryBytes,toOctalBytes,toBase32Bytes, andtoBase64Bytes, returning the encoded ASCII output as aUint8Listwithout the intermediateString. - Add non-throwing decoders
tryFromHex,tryFromBinary,tryFromOctal,tryFromBase32,tryFromBase64,tryFromUtf8, andtryFromBigInt, which returnnullinstead of throwing aFormatExceptionon invalid input. - Fix the UTF-8 encoder emitting invalid bytes for scalar code points in
U+10000..U+10FFFF;UTF8Encoder.convertnow uses the 4-byte form (the publictoUtf8was unaffected). Verified againstdart:convert. - Make the Crockford Base-32 decoder case-insensitive and decode the ambiguous
letters
I/i/L/las1andO/oas0. Encoding output is unchanged. - Fix
ByteCollector.numbertruncating values wider than 32 bits on the web; it now accumulates with multiplication and is exact up to2^53(VM unchanged). ByteCollector.isEqualreturnsfalsefor a [String] that is not valid hexadecimal instead of throwing aFormatException, matching its contract.- Add value-based
==andhashCodetoCryptData; a null and an emptyparamsmap now compare equal (both encode to the same string). - PHC/crypt: allow empty parameter values (e.g.
$id$data=), and fix the decoder mis-classifying a comma-containingv=...segment as the version. - Speed up
fromBase32/fromBase64decoding and the genericAlphabetEncoderby removing extra allocations and passes; output is byte-identical. - Clarify the
FormatExceptionmessage for non-canonical encoded input:'Invalid length'is now'Invalid length or non-zero trailing bits'.
- [Breaking Changes]
-
3.5.108 Jul 2026Release notes
Open source →- Widen
fromUtf8to accept anyList<int>input instead of requiring a
Uint8List. Non-Uint8Listinputs are copied to aUint8Listbefore
decoding.
Full Changelog: v3.5.0...v3.5.1
Release notes
Open source →- Widen
fromUtf8to accept anyList<int>input instead of requiring aUint8List. Non-Uint8Listinputs are copied to aUint8Listbefore decoding.
- Widen
-
3.5.008 Jul 2026Release notes
Open source →- [Breaking Changes]
- Renames internal abstract class
HashlibConvertertoCipherlibConverter. - Removes
encodeString,decodeStringfromIterableCodec.
- Renames internal abstract class
- Fix
CryptDataBuilder.paramto throw anArgumentErrorwhen the value is
null, instead of a rawTypeError. - Speed up Base-64 and Base-32 encoding with specialized single-pass encoders.
Base-64 encoding now outperformsdart:convert. - Speed up Base-64 and Base-32 decoding with specialized single-pass decoders.
Base-64 decoding now outperformsdart:convert. - Speed up
toUtf8usingUint8Listbuffer instead of plainList<int>.
UTF-8 encoding now outperformsdart:convert. - Speed up
fromUtf8with a dedicated byte-to-string decoder.
UTF-8 decoding now matches closely withdart:convert. - Refactor existing benchmarks and add missing ones. Dropping
benchmark_harness
dependency in favor of custom benchmarking class with better flexibility.
Full Changelog: v3.4.0...v3.5.0
Release notes
Open source →- [Breaking Changes]
- Removes
encodeString,decodeStringfromIterableCodec.
- Removes
- Renames internal abstract class
HashlibConvertertoCipherlibConverter. - Fix
CryptDataBuilder.paramto throw anArgumentErrorwhen the value isnull, instead of a rawTypeError. - Speed up Base-64 and Base-32 encoding with specialized single-pass encoders.
Base-64 encoding now outperforms
dart:convert. - Speed up Base-64 and Base-32 decoding with specialized single-pass decoders.
Base-64 decoding now outperforms
dart:convert. - Speed up
toUtf8usingUint8Listbuffer instead of plainList<int>. UTF-8 encoding now outperformsdart:convert. - Speed up
fromUtf8with a dedicated byte-to-string decoder. UTF-8 decoding now matches closely withdart:convert. - Refactor existing benchmarks and add missing ones. Dropping
benchmark_harnessdependency in favor of custom benchmarking class with better flexibility.
- [Breaking Changes]
-
3.4.007 Jul 2026Release notes
Open source →- Rename the package from
hashlib_codecstoconvertlib. The public API is
unchanged: update the dependency toconvertliband imports to
package:convertlib/convertlib.dart. - The
hashlib_codecspackage continues to be published as a thin re-export of
convertlibfor backward compatibility, and will be discontinued after a
migration period.
Full Changelog: v3.3.1...v3.4.0
Release notes
Open source →- Rename the package from
hashlib_codecstoconvertlib. The public API is unchanged: update the dependency toconvertliband imports topackage:convertlib/convertlib.dart. - The
hashlib_codecspackage continues to be published as a thin re-export ofconvertlibfor backward compatibility, and will be discontinued after a migration period.
- Rename the package from