[ base16, base32, base64, bsd3, library, rfc4648, unclassified ] [ Propose Tags ]

Base-N ByteStrings for base{16,32,58,64}

[Skip to Readme]
Versions [faq],
Change log
Dependencies base (>=4.7 && <5), bytestring [details]
License BSD-3-Clause
Copyright 2018 William Fisher
Author William Fisher
Home page
Bug tracker
Source repo head: git clone
Uploaded by filwisher at Thu Mar 29 12:27:56 UTC 2018
Distributions NixOS:
Downloads 179 total (20 in the last 30 days)
Rating (no votes yet) [estimated by rule of succession]
Your Rating
  • λ
  • λ
  • λ
Status Hackage Matrix CI
Docs available [build log]
Last success reported on 2018-03-29 [all 1 reports]




Maintainer's Corner

For package maintainers and hackage trustees

Readme for basen-bytestring-

[back to package description]


RFC-4648 compliant base-n ByteStrings for the common cases:


All with the same API:

module Data.ByteString.BaseN where

import qualified Data.ByteString.Char8 as B8

encode         :: B8.ByteString -> B8.ByteString
decode         :: B8.ByteString -> B8.ByteString

encodeAlphabet :: Enc -> B8.ByteString -> B8.ByteString
decodeAlphabet :: Enc -> B8.ByteString -> B8.ByteString

Currently Data.ByteString.Base58 is not implemented although it is on the roadmap.

The core Data.ByteString.BaseN contains all the common utilities for packing bytes, processing ByteStrings, creating encodings, and encoding/decoding single bytes.