Category Archives: tools

Remove existing jar signature and replacing it with a new signature.

After signing a jar file with an existing signature, you may get an error like this:

jarsigner: java.lang.SecurityException: invalid SHA1 signature file digest

This is because you should first remove the old signature. To do this, they say to unzip the jar file and remove the META-INF directory and zip it back. Fortunately the zip command has an option for this.

zip -d "META-INF/*" yourFile.jar

Then use jarsigner to sign the file, this varies depending on your keystore format. Here’s an example:

jarsigner -keystore yourKeyStore.pfx -storetype PKCS12 yourFile.jar myAliasInKeystore

Free simple screen sharing

Need an easy way to share your screen with someone, but don’t want to pay an arm and a leg and are too lazy to setup a VNC session over an ssh tunnel?  Check out screenleap, it’s simple and you get 2 hours a day of screen sharing for free.  You don’t even have to sign up for an account to try it.

It appears to only need java enabled on the browser of the sharing computer, and the viewing computers just need a browser.  That’s great when trying to share your screen with people in a restricted environment.

convert is awesome

Someone was asking how to convert PDFs to JPGs and I thought to myself, surely there is a Linux utility to do this. Well ImageMagick comes with a utility called convert and the syntax is really easy.

convert test.pdf test.jpg

This will create a jpeg for each page of the pdf.  Simple right?  Plus it supports many input and output formats.

Screen

If you haven’t used screen yet, then you should really check it out. It’s great for running those long jobs (or bittorrent, for legit purposes of course) and coming back to it at a later time. Anyway I always wished that I could share a screen session with another user. Well I should have read the man file because it is already there.

screen -x Attach to a not detached screen. (Multi display mode).

Now if they would just allow scrolling back through the history with <shift><pgup>.