summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorFilipe LaĆ­ns <lains@archlinux.org>2020-08-10 14:48:20 (GMT)
committerGitHub <noreply@github.com>2020-08-10 14:48:20 (GMT)
commit4ce6faa6c9591de6079347eccc9e61ae4e8d9e31 (patch)
tree72e6015f5de2f32e283864275cc48b72de8bb969 /Doc
parent39042e00ab01d6521548c1b7cc6554c09f4389ff (diff)
downloadcpython-4ce6faa6c9591de6079347eccc9e61ae4e8d9e31.zip
cpython-4ce6faa6c9591de6079347eccc9e61ae4e8d9e31.tar.gz
cpython-4ce6faa6c9591de6079347eccc9e61ae4e8d9e31.tar.bz2
bpo-16995: add support for base32 extended hex (base32hex) (GH-20441)
cc @pganssle Automerge-Triggered-By: @pganssle
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/base64.rst23
-rw-r--r--Doc/whatsnew/3.10.rst6
2 files changed, 28 insertions, 1 deletions
diff --git a/Doc/library/base64.rst b/Doc/library/base64.rst
index 1ff22a0..2f24bb6 100644
--- a/Doc/library/base64.rst
+++ b/Doc/library/base64.rst
@@ -124,7 +124,7 @@ The modern interface provides:
whether a lowercase alphabet is acceptable as input. For security purposes,
the default is ``False``.
- :rfc:`3548` allows for optional mapping of the digit 0 (zero) to the letter O
+ :rfc:`4648` allows for optional mapping of the digit 0 (zero) to the letter O
(oh), and for optional mapping of the digit 1 (one) to either the letter I (eye)
or letter L (el). The optional argument *map01* when not ``None``, specifies
which letter the digit 1 should be mapped to (when *map01* is not ``None``, the
@@ -136,6 +136,27 @@ The modern interface provides:
input.
+.. function:: b32hexencode(s)
+
+ Similar to :func:`b32encode` but uses the Extended Hex Alphabet, as defined in
+ :rfc:`4648`.
+
+ .. versionadded:: 3.10
+
+
+.. function:: b32hexdecode(s, casefold=False)
+
+ Similar to :func:`b32decode` but uses the Extended Hex Alphabet, as defined in
+ :rfc:`4648`.
+
+ This version does not allow the digit 0 (zero) to the letter O (oh) and digit
+ 1 (one) to either the letter I (eye) or letter L (el) mappings, all these
+ characters are included in the Extended Hex Alphabet and are not
+ interchangable.
+
+ .. versionadded:: 3.10
+
+
.. function:: b16encode(s)
Encode the :term:`bytes-like object` *s* using Base16 and return the
diff --git a/Doc/whatsnew/3.10.rst b/Doc/whatsnew/3.10.rst
index 2af0ea3..eb5ae01 100644
--- a/Doc/whatsnew/3.10.rst
+++ b/Doc/whatsnew/3.10.rst
@@ -103,6 +103,12 @@ New Modules
Improved Modules
================
+base64
+------
+
+Add :func:`base64.b32hexencode` and :func:`base64.b32hexdecode` to support the
+Base32 Encoding with Extended Hex Alphabet.
+
curses
------