Fast and URL-Safe Base64 Encoder and Decoder

In contrast to RFC3548, the 62nd character ("+") is replaced with "-", the 63rd character ("/") is replaced with "_". Furthermore, the encoder does not fill the string with trailing "=". The resulting encoded strings comply to the regular expression pattern "[A-Za-z0-9_-]" and thus are safe to use in URLs or for file names. The package also comes with a simple base32 encoder/decoder suited for case insensitive file systems.


CRAN_Status_Badge Build Status Build status Coverage Status

In contrast to base64 RFC3548, the 62nd character ('+') is replaced with '-', the 63rd character ('/') is replaced with '_'. Furthermore, the encoder does not fill the string with trailing '='. The resulting encoded strings comply to the regular expression pattern '[A-Za-z0-9_-]' and thus are safe to use in URLs or for file names.

For a small benchmark, see the vignette.

As of version 1.1, this package also ships with a simple base32 encoder/decoder suited to mangle file names on case insensitive file systems.

Installation

For the stable release, just install the latest version from CRAN:

install.packages("base64url")

For the development version, use devtools:

devtools::install_github("mllg/base64url")

News

base64url 1.2

  • Native routines are now registered.
  • Vignette builds without microbenchmark installed.
  • Update to new backports.

base64url 1.1

  • Added base32_encode() and base32_decode().
  • Changed license to GPL-3.
  • Fixed vignette title.

base64url 1.0

  • Initial release.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("base64url")

1.4 by Michel Lang, a month ago


https://github.com/mllg/base64url


Report a bug at https://github.com/mllg/base64url/issues


Browse source code at https://github.com/cran/base64url


Authors: Michel Lang [cre, aut] (<https://orcid.org/0000-0001-9754-0393>), Apache Foundation [ctb, cph], Free Software Foundation [ctb, cph]


Documentation:   PDF Manual  


GPL-3 license


Imports backports

Suggests base64enc, checkmate, knitr, microbenchmark, openssl, rmarkdown, testthat


Imported by batchtools, txtq.


See at CRAN