Today's Question:  What are you most afraid of as a programmer?        GIVE A SHOUT



  Different types of keystore in Java -- PKCS11

PKCS11 keystore is designed for hardware storage modules(HSM). It's an interface to talk to the HSMs. It doesn't actually store any keys but provide a set of classes to communicate with the underlying HSM. The actual keys and certificates are stored on the HSMs. The reason for storing the keys and materials is to ensure security and efficiency. Since the keys are on the HSMs, they are safe to be stolen. All encryption/decryption operations are performed on the HSMs as well, this increase the...

8,919 2 0          JAVA KEYSTORE PKCS11 HSM

  What does super.clone() do?

Object class has a protected clone() method declared to make it possible for all classes make a clone of itself when needed. The clone() is often used when a new instance of the class is needed while at the same time to maintain the same state as the original object. Any class which wants to have clone enabled has to implement the marker interface Cloneable. If a class which implements Cloneable doesn't override the Object.clone() method, the Object.clone() method will be called to just make a b...


  Different types of keystore in Java -- JCEKS

JCEKS stands for Java Cryptography Extension KeyStore and it is an alternative keystore format for the Java platform. Storing keys in a KeyStore can be a measure to prevent your encryption keys from being exposed. Java KeyStores securely contain individual certificates and keys that can be referenced by an alias for use in a Java program. The process of storing and loading different entries in JCEKS is similar to what JKS does. So please refer to the article Different types of keystore in Java -...


  Different types of keystore in Java -- PKCS12

PKCS12 is an active file format for storing cryptography objects as a single file. It can be used to store secret key, private key and certificate.It is a standardized format published by RSA Laboratories which means it can be used not only in Java but also in other libraries in C, C++ or C# etc. This file format is frequently used to import and export entries from or to other keystore types. Next we will explain the operations which can be performed on PKCS12 keystore. Create PKCS12 keystore Be...

20,182 10 2          JAVA PKCS12 KEYSTORE TUTORIAL

  Remote execute command in Java example

Frequently there is a need to logon to a remote system and run some commands or programs to get the output, many software can serve this purpose such as putty and gitshell.These software usually provide secure access to the remote system. But have you ever wondered what to do if you need to run commands on many different systems at the same time and get all these results back at a single place? Especially in big data era, many tasks may run on different distributed systems and you want o have a ...


  Use Memory Analyzer Tool in Eclipse

When developing applications, we often encounter memory issues of an application. To analyze how much memory each class takes, we need to have some specific tools to assist us. One of them is Memory Analyzer Tool on Eclipse. The Eclipse Memory Analyzer is a fast and feature-rich Java heap analyzer that helps you find memory leaks and reduce memory consumption. To use the Memory Analyzer Tool, you first need to install it on Eclipse. You can go to Help -> Install New Software.... Paste  h...


  ConcurrentHashMap vs Collections.synchronizedMap()

ConcurrentHashMap and Collections.synchronizedMap() both provide thread-safe operations of collections of data. They are used in multithreaded programs to provide both thread safety and performance improvements. In many cases, we can use either of them. But the realization of thread safety is different for these two implementations. ConcurrentHashMap will create an HashEntry[] array internally to store the elements passed in from a Map, while Collections.synchronizedMap() will return a Synchroni...


  Different types of keystore in Java -- JKS

JKS is Java Keystore, a proprietary keystore type designed for Java. It can be used to store private keys and certificates used for SSL communication, it cannot store secret keys however. The keytool shipped with JDKs cannot extract private keys stored on JKS. This type of keystore usually has an extension of jks. Next we will show how to operate the JKS keystore with pure Java code. Create JKS keystore The simplest method to create a JKS keystore to create an empty keystore. We can first get an...

15,264 2 0          DEMO EXAMPLE KEYSTORE JKS