# Encrypting databases on creation

You configure a Derby database for encryption when you create the database by specifying the dataEncryption=true attribute on the connection URL.

The Java Runtime Environment (JRE) determines the default encryption provider, as follows:

- For J2SE/J2EE 1.4 or higher, the JRE's provider is the default.
- For an IBM Corp J2SE/J2EE 1.3 JRE, the default provider is com.ibm.crypto.provider.
- For a Sun Microsystem J2SE/J2EE 1.3 JRE, the default provider is com.sun.crypto.provider.SunJCE.
- For any other J2SE/J2EE 1.3 JRE, a provider must be specified.

You have the option of specifying an alternate encryption provider. The default encryption algorithm is DES, but you have the option of specifying an alternate algorithm as well.

Parent topic: Working with encryption
Related concepts
Creating the boot password
Booting an encrypted database
Changing the boot password
Specifying an alternate encryption provider
Specifying an alternate encryption algorithm
Related tasks
Encrypting databases with a new key