Skip to content
Permalink
Branch: master
Commits on Dec 22, 2019
  1. Implement getting manifest with a command line

    KonstantinShemyak committed Dec 22, 2019
Commits on Oct 14, 2018
  1. Indicated binary string as required for Python 3

    KonstantinShemyak committed Oct 14, 2018
Commits on Oct 13, 2018
  1. Fixed resource leak (not closed file descriptor)

    KonstantinShemyak committed Oct 13, 2018
Commits on Oct 12, 2018
  1. Added test for inspecting class members of array type

    KonstantinShemyak committed Oct 2, 2018
  2. Syntactic and linguistic cleanup; no logic change

    KonstantinShemyak committed Oct 3, 2018
    Fixed loose language uses, mostly pointed by automatic tools.
  3. Declared support for Python 3

    KonstantinShemyak committed Oct 12, 2018
    - Travis CI tests for Python 3 added
    - Trove classifier in setup.py updated
    - README.md indicates support for Python 2.7, 3,5 and 3.6
  4. Manifest content is encoded in UTF-8 before serializing

    KonstantinShemyak committed Oct 12, 2018
    This makes all test pass in Python 3.
  5. Text (non-binary) report output handled in Py3-compatible way

    KonstantinShemyak committed Oct 12, 2018
    This makes classdiff, distdiff and jardiff tests pass under Python 3.
  6. Ordering comparison for manifest sections implemented

    KonstantinShemyak committed Sep 20, 2018
    To sort manifest entries (which are entries of OrderedDict), an explicit
    ordering must be defined in Python 3.
    See https://docs.python.org/3/whatsnew/3.0.html#ordering-comparisons
  7. Manifest stored internally as Unicode, as it should be

    KonstantinShemyak committed Oct 11, 2018
    Manifest is loaded from text file only with parse_file(), not with open().
    Added test for modified lines, which were previously not covered.
    Py3-specific code is not added yet, this is a Py2-only internal improvement.
  8. Loading manifest from JAR factored into own function

    KonstantinShemyak committed Oct 11, 2018
    When JAR manifest is read from JAR file, that file is zip. The returned data
    is 'str' in Python 2 and 'bytes' in Python 3; by its nature, the manifest
    content is UTF-8 encoded text. This requires different processing in Py2/Py3.
    
    This processing is factored in own function. Loading manifest from JAR file
    is done only with this new function. It also makes redundant
    Jarinfo:get_manifest() (which was not covered by tests anyway).
Commits on Oct 11, 2018
  1. Leftover assertEquals() renamed to assertEqual() in tests

    KonstantinShemyak committed Oct 11, 2018
    The former is deprecated in Python 3.
  2. tests/pack.py: Py3-compatible input data

    KonstantinShemyak committed Oct 11, 2018
    After this commit, the following tests pass under Python 3.6.5:
    
    __init__, classinfo, crypto, distinfo, jarinfo, pack
  3. tests/__init__.py: used Py3-suggested test methods

    KonstantinShemyak committed Oct 11, 2018
    The old methods still work, but are marked as deprecated.
  4. Python 3 compatible syntax in __init__.py

    KonstantinShemyak committed Oct 11, 2018
    In Python 3, buffer (i.e. memoryview) does not have a constructor
    with offset, on which code of _next_argsig() relies.
    Change _next_argsig() to work on strings instead.
    This does not impact performance as this function is used on Java
    identifiers, which are small in size.
    
    No external interfaces are changed.
  5. Correcting not Py3-compatible syntax

    KonstantinShemyak committed Oct 11, 2018
    In Python 3:
    * 'dict_values' object has no attribute 'sort'
    * 'generator' object has no attribute 'next'
     --> Corresponding method calls replaced with cross-version builtins.
    * data read from class files is 'bytes'
     --> 'str' changed to 'bytes', as the latter is present in Py2 as well
    * xrange() is not present
     --> replaced with range() (as done everywhere else in 4a6cd21)
    * iterkeys(), iteritems() are not present
     --> replaced with keys(), items()
Commits on Oct 10, 2018
  1. Towards Py3: use cross-version-compatible b64encode

    KonstantinShemyak committed Oct 10, 2018
    b64encode() returns different types in Py3 and Py2. A compatible wrapper
    used.
    
    Eliminated usage of bare b64encode() in favor of the "higher level"
    b64_encoded_digest() where possible.
Commits on Sep 27, 2018
  1. Issue-86: implemented check for text file change

    KonstantinShemyak committed Sep 27, 2018
    Also added corresponding test.
Commits on Sep 15, 2018
Commits on Jul 23, 2018
Commits on Apr 29, 2018
  1. Replaced expired certificates

    KonstantinShemyak committed Apr 29, 2018
    Certificates used for tests were made with too short lifetime and already
    expired. Replaced with lifetime 100 years.
Commits on Mar 24, 2018
  1. Code cleanup, no logic changes

    KonstantinShemyak committed Aug 6, 2017
    - Catch specific exceptions
    - Remove non-existing names from __all__
    - Shorten some >79 character long lines
    - Whitespace cleanup
Commits on Mar 23, 2018
  1. Digest for signature in 'jarutil s' can be specified

    KonstantinShemyak committed Nov 24, 2016
    Option '-d' for 'jarutil s' is handled, i.e. digest algorithm in the
    JAR signature block file can be specified. Example:
    jarutil s -d SHA-512 data.jar cert.pem key.pem ALIAS
    You'd probably also need the manifest to use the same algorithm,
    with python-javatools this can be done by 'manifest -c -d <algorithm> ...'
    
    NOTE: this requires m2crypto commit dc507654. It can be picked at
    https://gitlab.com/KonstantinShemyak/m2crypto/tree/nondefault-digest-for-pkcs7
Older
You can’t perform that action at this time.