]> Cypherpunks.ru repositories - pyderasn.git/blob - doc/news.rst
Fix double encoded values decoding in SET
[pyderasn.git] / doc / news.rst
1 News
2 ====
3
4 .. _release7.0:
5
6 7.0
7 ---
8 * Fixed invalid behaviour where SET OF allowed multiple objects with the
9   same tag to be successfully decoded
10
11 .. _release6.3:
12
13 6.3
14 ---
15 * Fixed workability under Python 3.5. Previously only 2.7 and 3.6
16   versions were tested
17
18 .. _release6.2:
19
20 6.2
21 ---
22 * Python ``int()``'s accepts even more various non-decimal characters
23   than expected. Make validation fully strict in UTCTime and
24   GeneralizedTime, without relying on ``int()``
25
26 .. _release6.1:
27
28 6.1
29 ---
30 * UTCTime and GeneralizedTime allowed values to have plus sign in them,
31   passing int() check successfully. Prohibit that incorrect behaviour
32 * UTCTime and GeneralizedTime BER decoding support
33 * Faster UTCTime and GeneralizedTime decoding, and slightly better
34   overall performance
35 * Workability under Cython
36 * Explicitly Check that all ObjectIdentifier arcs are non-negative
37
38 .. _release6.0:
39
40 6.0
41 ---
42 * ``.copy()`` method removed: ``copy.copy()`` is preferred way to copy
43   objects now
44 * Copies made previously with ``.copy()`` lacked ``.defined`` field,
45   now they are not
46 * All objects are friendly to ``pickle`` libraries
47 * PrintableString has ``allow_asterisk`` and ``allow_ampersand``
48   properties
49 * ``.hexencode()``, ``.hexdecode()`` and ``.hexdecod()`` methods
50   appeared, working with hexadecimal encoded data
51
52 .. _release5.6:
53
54 5.6
55 ---
56 * Convenient ``.decod()`` method, that raises if tail is not empty
57 * Control characters (like newlines) of text fields in pprinted output
58   are escaped
59 * Ability to allow asterisk and ampersand characters
60   (``allow_asterisk``, ``allow_ampersand`` kwargs) in PrintableString,
61   that unfortunately could be met in X.509 certificates
62
63 .. _release5.5:
64
65 5.5
66 ---
67 * PEP-396 compatible module's ``__version__``
68
69 .. _release5.4:
70
71 5.4
72 ---
73 * Do not shadow underlying DecodeError during decoding of optional
74   sequence's field
75
76 .. _release5.3:
77
78 5.3
79 ---
80 * Forbid any later GNU GPL version autousage (project's licence now is
81   GNU LGPLv3 only)
82 * Fix ``defines_by_path`` context option usage example
83
84 .. _release5.2:
85
86 5.2
87 ---
88 * Fix fallbacked ``colored()`` function workability,
89   if no ``termcolor`` is installed
90
91 .. _release5.1:
92
93 5.1
94 ---
95 * Fix empty ``--oids`` workability
96
97 .. _release5.0:
98
99 5.0
100 ---
101 * Ability to specify multiple OID mappings for pprinted output
102   (``oids`` keyword argument is renamed to ``oid_maps``)
103
104 .. _release4.9:
105
106 4.9
107 ---
108 * Minor decode speed improvements
109 * Much faster UTCTime/GeneralizedTime decoders
110 * Stricter UTCTime/GeneralizedTime DER encoding check: trailing zeroes
111   are forbidden
112 * Valid DER encoding of GeneralizedTime with microseconds: no trailing
113   zeroes appended
114
115 .. _release4.7:
116
117 4.7
118 ---
119 * ObjectIdentifier has ``ber_encoded`` set to True, if non-normalized
120   arc encoding is met
121 * Preserve BER-related attributes during ``copy()``
122
123 .. _release4.6:
124
125 4.6
126 ---
127 * Added `COMPLI <https://github.com/YuryStrozhevsky/asn1-test-suite>`__
128   ASN.1:2008 test suite. PyDERASN passes it (except for REAL values),
129   but it is more strict sometimes and aimed to be compliant with X.690-201508
130 * Check for arc values normalization in ObjectIdentifier.
131   Forbid non-normalized in DER encoding
132
133 .. _release4.5:
134
135 4.5
136 ---
137 * ``ctx`` parameter can be safely used in .decode() and won't be muted
138 * PP nametuple contains reference to the ASN1Obj itself
139 * ``colonize_hex`` function useful for pretty printing
140 * Integer values are also pretty printed in hexadecimal form
141
142 .. _release4.4:
143
144 4.4
145 ---
146 * All errors are inherited from ASN1Error class
147 * NumericString/PrintableString has ``allowable_chars`` property holding
148   all allowed characters
149
150 .. _release4.3:
151
152 4.3
153 ---
154 * Fix NumericString: space is allowed character
155 * Strict PrintableString sanitizing
156
157 .. _release4.2:
158
159 4.2
160 ---
161 * Removed ``lenindef``, ``ber_encoded`` attributes from the Choice --
162   they must be taken from underlying value, as Choice does not have its
163   own encoding
164 * Do not yield extra EOC PP for Any, having indefinite length encoding
165   and containing autodecoded DEFINED BY value
166
167 .. _release4.1:
168
169 4.1
170 ---
171 * ``bered`` attribute, meaning if object has BER-specific encoding, is
172   renamed to ``ber_encoded``
173 * ``bered`` attribute is replace with property showing if any of
174   underlying values are BER-encoded. If value has length indefinite
175   encoded explicit tag, value, if value contains BER-related encoding,
176   or if it contains other objects that are ``bered``, then it is ``bered``
177
178 .. _release4.0:
179
180 4.0
181 ---
182 * Default value is checked also for Sets, not for Sequences only
183 * **Incompatible** change: defaulted values in Sequence/Set are always
184   strictly checked, unless ``allow_default_values`` context option is
185   set. ``strict_default_existence`` option disappeared
186 * Strict Set/Set Of's values ordering check
187
188 .. _release3.14:
189
190 3.14
191 ----
192 * Additional encoding validness check: explicit tag must contain exactly
193   one object inside. Throw DecodeError otherwise
194 * ``allow_expl_oob`` context and command-line options allow skipping of
195   that check
196
197 .. _release3.13:
198
199 3.13
200 ----
201 * DecodeError's decode paths are separated with ``:``, instead of ``.``,
202   because of colliding with dots in OIDs
203 * Ability to print element decode paths with ``--print-decode-path``
204   command line option (and corresponding keyword argument)
205 * Ability to print tree's branch specified with ``--decode-path-only``
206
207 .. _release3.12:
208
209 3.12
210 ----
211 * Fix possible uncaught TypeError in Py2 with zero bytes inside the value
212 * Fix SequenceOf/SetOf raising BoundsError instead of DecodeError
213
214 .. _release3.11:
215
216 3.11
217 ----
218 * Fix uncaught UTCTime/GeneralizedTime decode error when dealing with
219   non ASCII-encoded values
220
221 .. _release3.10:
222
223 3.10
224 ----
225 * Fix long-standing bug with explicitly tagged objects inside the
226   Choice. If Choice had explicitly tagged value, then its ``.tlvlen``
227   reports the size without taking value's explicit tag in advance
228 * Add ``.fulllen`` and ``.fulloffset`` properties for all objects
229
230 .. _release3.9:
231
232 3.9
233 ---
234 * SEQUENCE's values are printed with field's name. Previously there was
235   the following output::
236
237     AlgorithmIdentifier SEQUENCE[OBJECT IDENTIFIER 1.3.14.3.2.26, [UNIV 5] ANY 0500 OPTIONAL]
238
239   now it is::
240
241     AlgorithmIdentifier SEQUENCE[algorithm: OBJECT IDENTIFIER 1.3.14.3.2.26; parameters: [UNIV 5] ANY 0500 OPTIONAL]
242 * Fixed EOC (Unicode character) repr printing issues under Python2
243
244 .. _release3.8:
245
246 3.8
247 ---
248 BER's EOC is explicitly shown during pprinting. Following notation::
249
250       15-2 [0,0,1576]-4  . content: [0] EXPLICIT [UNIV 16] ANY
251
252 is replaced with::
253
254       15-2∞ [0,0,1576]∞  . content: [0] EXPLICIT [UNIV 16] ANY
255     [...]
256     1587    [1,1,   0]   . content:  BER EOC
257     1589    [1,1,   0]   . content: EXPLICIT BER EOC
258
259 .. _release3.7:
260
261 3.7
262 ---
263 * BER decoding support
264 * BitString's ''H notation support
265 * ``termcolor`` package is included in the tarball
266
267 .. _release3.6:
268
269 3.6
270 ---
271 * Ability to set values during Sequence initialization
272
273 .. _release3.5:
274
275 3.5
276 ---
277 * Fix TagMismatch exception completeness during Choice and Set decoding.
278   Previously we will loose offset and decode_path information about
279   concrete TagMismatched entity
280
281 .. _release3.4:
282
283 3.4
284 ---
285 * Strict NumericString's value sanitation
286 * Invalid encoding in string types will raise ``DecodeError`` exception,
287   instead of ``Unicode*Error``
288 * Fixed DecodePathDefBy workability with Python 2.x
289
290 .. _release3.3:
291
292 3.3
293 ---
294 * Fix nasty BitString decoding bug: it could fail when data follows
295   encoded BitString value. There weren't any problems when BitString is
296   at the end of Sequence
297
298 .. _release3.2:
299
300 3.2
301 ---
302 * Slightly corrected colours, now visible on white background
303
304 .. _release3.1:
305
306 3.1
307 ---
308 * Fix bug related to DecodeError showing with DecodePathDefBy entities
309 * Respect ``NO_COLOR`` environment variable
310
311 .. _release3.0:
312
313 3.0
314 ---
315 * :py:func:`pyderasn.decode_path_defby` is replaced with
316   :py:class:`pyderasn.DecodePathDefBy`
317 * Ability to turn colourized terminal output by calling
318   ``pprint(..., with_colours=True)``. You will need
319   `termcolor package <https://pypi.org/project/termcolor/>`__
320
321 .. _release2.1:
322
323 2.1
324 ---
325 * Fixed invalid offset calculation when dealing with DEFINED BY objects
326   having explicit tags
327
328 .. _release2.0:
329
330 2.0
331 ---
332 * BIT STRINGs can also be :ref:`DEFINED BY <definedby>`
333 * Decoding process can be governed with optional :ref:`ctx <ctx>`
334   keyword argument to ``decode()`` method
335 * :ref:`defines_by_path <defines_by_path_ctx>` option is now
336   :ref:`decode context <ctx>` option, not a keyword argument
337 * Ability to do ``strict validation``
338   of defaulted values met in sequence, raising an exception
339
340 .. _release1.6:
341
342 1.6
343 ---
344 Ability to skip specified number of bytes (``--skip``) in command line
345 utility.
346
347 .. _release1.5:
348
349 1.5
350 ---
351 * Generic decoder's schema and pretty printer
352   (:py:func:`pyderasn.generic_decoder`) can be used in libraries
353 * Ability to specify :ref:`defines_by_path <defines_by_path_ctx>`
354   during command line invocation
355
356 .. _release1.4:
357
358 1.4
359 ---
360 Ability to automatically decode :ref:`DEFINED BY <definedby>` fields
361 inside SEQUENCEs.
362
363 .. _release1.3:
364
365 1.3
366 ---
367 Removed ``__lt__``/``__eq__`` from base class, as pylint likes it.
368
369 .. _release1.2:
370
371 1.2
372 ---
373 Full rich comparison operators added.
374
375
376 .. _release1.1:
377
378 1.1
379 ---
380 Trivial README addition.
381
382 .. _release1.0:
383
384 1.0
385 ---
386 Initial release.