Java Keystore password pointless?

android, java, keystore, keytool

Solution

On a JKS or BKS keystore the password is not pointless, but it doesn't do what you might assume, either.

It doesn't encrypt the data in the keystore or in any way prevent access to it, but it does verify the integrity of the keystore. Without knowing the password, it is not possible to make changes to a keystore without the normal user of it finding out (typically due to their tools telling them "Keystore was tampered with, or password was incorrect")

In some other keystore types (such as Keystore.BouncyCastle) the keystore password protects against inspection as well as tampering.

Problem

What exactly is the sense behind a Keystore password, eg on JKS/BKS keystores? It is obviously NOT for security, because i can open the file with an editor and copy all entries into new files without passwordcheck. Data inside a passwordprotected Keystore is not encrypted! what does this password protect? It seems to be just for anoying developers oO...

Original source