I know how to use different java tools like jarsigner, keytool etc to sign general jar files and java applets too. But i want to do it in my application, i mean using my own application interface, using different functions at back end. Also i want to use Keys generated in HSM. Is it something different from simple file signing? Where does the signature go ? Any difference in contents of applet jar file? I have seen few examples but there does not look any difference. How to deploy signed applets and how to use when they are downloaded. I know i have asked many questions but i am looking forward for your kind response.