Skip to main content

Tools for working with Java class files and JARs

Project description

Overview of python-javatools

A python module for unpacking and inspecting Java Class files, JARs, and collections of either. Supporting features up to JDK 8.

It can do deep checking of classes to perform comparisons of functionality, and output reports in multiple formats.

If you have suggestions, please use the issue tracker on github. Or heck, just fork it!

Requirements

In addition, the following tools are used in building and testing the project.

All of these packages are available in most linux distributions (eg. Fedora), and for OSX via MacPorts and HomeBrew, or available directly from pip.

M2Crypto can be difficult on some platforms, and so is set as an optional dependency. If an execution path attempts to perform an action which requires M2Crypto (primarily Jar signing and Jar signature verification), then a CryptoDisabled exception will be raised, or a message will be printed to stdout explaining that the feature is unavailable. See the M2Crypto Install Guide for workarounds in your environment.

Building

This module uses setuptools, so running the following will build the project:

python setup.py build

to install, run:

python -m pip install . --user

Testing

Tests are written as unittest test cases. If you'd like to run the tests, simply invoke:

python setup.py test

or invoke tests across a wider range of platforms via tox

RPM

If you'd prefer to build an RPM, see the wiki entry for Building as an RPM.

Javatools Scripts

  • classinfo - similar to the javap utility included with most JVMs. Also does provides/requires tracking.

  • classdiff - attempts to find differences between two Java class files

  • jarinfo - prints information about a JAR. Also does provides/requires tracking.

  • jardiff - prints the deltas between the contents of a JAR, and runs classdiff on differing Java class files contained in the JARs

  • jarutil - creates and signs JARs, verifies JAR signatures

  • manifest - creates and queries JAR manifests

  • distinfo - prints information about a mixed multi-jar/class distribution, such as provides/requires lists.

  • distdiff - attempts to find differences between two distributions, deep-checking any JARs or Java class files found in either directory.

Additional References

Contact

Author: Christopher O'Brien obriencj@gmail.com

If you're interested in my other projects, feel free to visit my blog.

Original Git Repository: https://github.com/obriencj/python-javatools

License

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, see http://www.gnu.org/licenses/.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

javatools-1.6.0-py3-none-any.whl (159.3 kB view details)

Uploaded Python 3

javatools-1.6.0-py2-none-any.whl (159.3 kB view details)

Uploaded Python 2

File details

Details for the file javatools-1.6.0-py3-none-any.whl.

File metadata

  • Download URL: javatools-1.6.0-py3-none-any.whl
  • Upload date:
  • Size: 159.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for javatools-1.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b92ac541baa10c623aeba50f3e2041781d80bbdaea2624e7d730a240b5f379df
MD5 db66dd62e998c33a12b511e09fb511ab
BLAKE2b-256 05e08b8b8c811be4e99c1be226065c5190dba703634ec75d185b8bbb6230eb4e

See more details on using hashes here.

File details

Details for the file javatools-1.6.0-py2-none-any.whl.

File metadata

  • Download URL: javatools-1.6.0-py2-none-any.whl
  • Upload date:
  • Size: 159.3 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for javatools-1.6.0-py2-none-any.whl
Algorithm Hash digest
SHA256 f6c025260d06719e7b1c241112b5d779b87b324aecab4cf40dc37a77daed95c0
MD5 0125f83bddbfeb6f27659f9f3a7d578b
BLAKE2b-256 d43043d4ff45efdc7d261640fdff32833042cf34a4dd718c4eb36bea10a0a349

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page