Skip to content

Instantly share code, notes, and snippets.

@j1g54w1337
Last active February 4, 2022 07:13
Show Gist options
  • Select an option

  • Save j1g54w1337/356598bef84b4818c09292676f5ededa to your computer and use it in GitHub Desktop.

Select an option

Save j1g54w1337/356598bef84b4818c09292676f5ededa to your computer and use it in GitHub Desktop.
java tips and trick

Java tips and tricks

Verify .jar checksum

jarsigner -verify -verbose -certs <jarfile>

Unsigning .jar file

zip -d <jarfile> 'META-INF/*.SF' 'META-INF/*.RSA'

Create .jar file

jar cmvf META-INF/MANIFEST.MF <jarfile> .

Compile Java class file

export CLASSPATH=<path to jar including the .jar>
javac -classpath $CLASSPATH <path to .java file>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment