]> Cypherpunks.ru repositories - pyderasn.git/commitdiff
Also print full TLVlen 7.5
authorSergey Matveev <stargrave@stargrave.org>
Mon, 23 Mar 2020 07:41:18 +0000 (10:41 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Tue, 24 Mar 2020 15:50:07 +0000 (18:50 +0300)
VERSION
doc/install.rst
doc/news.rst
pyderasn.py

diff --git a/VERSION b/VERSION
index 37722ebbc756a3160e7f4aeb04d4c8f69e5fa8a3..c382960e38796254910dcdfb506d19fcf1685cf4 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-7.4
+7.5
index 8aa3bd0fe4ac0028e6cd36c2fed4005647fc0fd4..7e56b39722f932b6538433f6a91f1798a382e908 100644 (file)
@@ -4,11 +4,11 @@ Install
 Preferable way is to :ref:`download <download>` tarball with the
 signature from `official website <http://pyderasn.cypherpunks.ru/>`__::
 
-    $ [fetch|wget] http://pyderasn.cypherpunks.ru/pyderasn-7.4.tar.xz
-    $ [fetch|wget] http://pyderasn.cypherpunks.ru/pyderasn-7.4.tar.xz.sig
-    $ gpg --verify pyderasn-7.4.tar.xz.sig pyderasn-7.4.tar.xz
-    $ xz --decompress --stdout pyderasn-7.4.tar.xz | tar xf -
-    $ cd pyderasn-7.4
+    $ [fetch|wget] http://pyderasn.cypherpunks.ru/pyderasn-7.5.tar.xz
+    $ [fetch|wget] http://pyderasn.cypherpunks.ru/pyderasn-7.5.tar.xz.sig
+    $ gpg --verify pyderasn-7.5.tar.xz.sig pyderasn-7.5.tar.xz
+    $ xz --decompress --stdout pyderasn-7.5.tar.xz | tar xf -
+    $ cd pyderasn-7.5
     $ python setup.py install
     # or copy pyderasn.py (+six.py, possibly termcolor.py) to your PYTHONPATH
 
@@ -21,7 +21,7 @@ You can also find it mirrored on :ref:`download <download>` page.
 You could use pip (**no** OpenPGP authentication is performed!) with PyPI::
 
     $ cat > requirements.txt <<EOF
-    pyderasn==7.4 --hash=sha256:TO-BE-FILLED
+    pyderasn==7.5 --hash=sha256:TO-BE-FILLED
     six==1.14.0 --hash=sha256:236bdbdce46e6e6a3d61a337c0f8b763ca1e8717c03b369e87a7ec7ce1319c0a
     EOF
     $ pip install --requirement requirements.txt
index 10befb1cfa787c5d9f9d491500ce241f41704fa0..01607814338ec392a6cccf21bd3c36fe17ad70ea 100644 (file)
@@ -1,6 +1,12 @@
 News
 ====
 
+.. _release7.5:
+
+7.5
+---
+* Also print full TLVlen in ASN.1 browser
+
 .. _release7.4:
 
 7.4
index a4b7deb7e3b6e86983fa0695cb2d6a356db10d7e..f611efa195369727b2a2a20455a8c5b796431389 100755 (executable)
@@ -1193,7 +1193,7 @@ except ImportError:  # pragma: no cover
     def colored(what, *args, **kwargs):
         return what
 
-__version__ = "7.4"
+__version__ = "7.5"
 
 __all__ = (
     "agg_octet_string",
@@ -7539,6 +7539,9 @@ def browse(raw, obj, oid_maps=()):
                 [("header", "[TLV]len: "), "%d/%d/%d" % (
                     pp.tlen, pp.llen, pp.vlen,
                 )],
+                [("header", "TLVlen: "), "%d" % sum((
+                    pp.tlen, pp.llen, pp.vlen,
+                ))],
                 [("header", "Slice: "), "[%d:%d]" % (
                     pp.offset, pp.offset + pp.tlen + pp.llen + pp.vlen,
                 )],
@@ -7558,6 +7561,9 @@ def browse(raw, obj, oid_maps=()):
                     lines.append(["  [TLV]len: %d/%d/%d" % (
                         pp.expl_tlen, pp.expl_llen, pp.expl_vlen,
                     )])
+                    lines.append(["  TLVlen: %d" % sum((
+                        pp.expl_tlen, pp.expl_llen, pp.expl_vlen,
+                    ))])
                     lines.append(["  Slice: [%d:%d]" % (
                         pp.expl_offset,
                         pp.expl_offset + pp.expl_tlen + pp.expl_llen + pp.expl_vlen,