Master Encryption Keys in Autonomous Database on Dedicated Exadata Infrastructure
By default, Autonomous Database on Dedicated Exadata Infrastructure creates and manages all the master encryption keys
used to protect your data, storing them in a secure PKCS 12 keystore on the same Exadata
systems where the databases reside. These are referred to as Oracle-managed
encryption keys.
If your company's security policies require it, Autonomous Database can use the keys you create and manage using Oracle Key Store instead. For Oracle Public Cloud deployments, you can also use the Oracle Cloud Infrastructure Vault service to create and manage keys. Customers with regulatory compliance to store keys outside Oracle Cloud or any third-party cloud premises can use an External Key Management Service (External KMS).
When you create a customer-managed key using the OCI Vault service, you can also import
your own key material (Bring Your Own Key or BYOK) instead of letting the Vault service
generate the key material internally.
Caution:
As customer-managed keys stored in Oracle Key Vault (OKV) are
external to the database host, any configuration change or interruption that
makes the OKV inaccessible to the database using its keys makes its data
inaccessible.
Additionally, regardless of whether you use Oracle-managed or customer-managed keys,
you can rotate the keys used in existing databases when needed in order to meet your
company security policies. See Rotate the Encryption Keys for more details.
Before You Begin: Compartment Hierarchy Best Practice
Oracle recommends that you create a compartment hierarchy for your Autonomous Database deployment on dedicated
infrastructure as follows:
A "parent" compartment for the entire deployment
"Child" compartments for each of the various kinds of
resources:
Autonomous Databases
Autonomous Container Databases and infrastructure
resources (Exadata Infrastructures and Autonomous Exadata VM
Clusters)
The VCN (Virtual Cloud Network) and its subnets
Vaults that contain your customer-managed keys
Following this best practice is especially important when using
customer-managed keys because the policy statement you create to grant Autonomous Database access to your keys must be
added to a policy that is higher in your compartment hierarchy than the compartment
containing your vaults and their keys.
Create a Service Gateway, a Route Rule and an Egress Security Rule Oracle Cloud Infrastructure (OCI) Service Gateway provides private, secure access to multiple Oracle Cloud services simultaneously from within a virtual cloud network (VCN) or on-premises network via a single gateway without traversing the internet.
Create a Dynamic Group and a Policy Statement To grant your Autonomous Database resources permission to access customer-managed keys, you create an IAM dynamic group that identifies these resources and then create an IAM policy that grants this dynamic group access to the master encryption keys you created in the Vault service.
Before you can use customer-managed keys stored in the Vault service, you must perform a number of preparatory configuration tasks to create a vault and master encryption keys and then make that vault and its keys available to Autonomous Database; specifically:
Create a vault in the Vault service by following the instructions in
To create a new vault in Oracle Cloud Infrastructure Documentation. When following
these instructions, Oracle recommends that you create the vault in a compartment
created specifically to contain the vaults containing customer-managed keys, as
described in Compartment Hierarchy Best Practice.
After
creating the vault, you can create at least one master encryption key in the
vault by following the instructions in To create a new master
encryption key in Oracle Cloud Infrastructure
Documentation. When following these instructions, make these
choices:
Create in Compartment: Oracle recommends that you
create the master encryption key in the same compartment as its vault;
that is, the compartment created specifically to contain the vaults
containing customer-managed keys.
Protection Mode: Choose an appropriate value from the
drop-down list:
HSM to create a master encryption key that is
stored and processed on a hardware security module (HSM).
Software to create a master encryption key
that is stored in a software file system in the Vault service.
Software-protected keys are protected at rest using an HSM-based
root key. You may export software keys to other key management
devices or to a different OCI cloud region. Unlike HSM keys,
software-protected keys are free of cost.
Key Shape Algorithm: AES
Key Shape Length: 256 bits
Note
You can also add an encryption key to an existing
vault.
Use the IAM service to Create
a Dynamic Group identifying your Autonomous Database resources and a policy statement granting that dynamic
group access to the master encryption keys you created.
After configuring the customer-managed key using the above steps, you can configure it
while provisioning an Autonomous Container Database (ACD) or by rotating the existing
encryption key from the Details page of ACD or Autonomous Database. Autonomous Databases provisioned in this ACD will automatically
inherit these encryption keys. See Create an Autonomous Container Database or Rotate the Encryption Key of an Autonomous Container
Database for more details.
When you create a customer-managed key using the OCI Vault service, you can also
import your own key material (Bring Your Own Key or BYOK) instead of letting
the Vault service generate the key material internally.
Before you can bring your own keys into the Vault service, you must perform number
of preparatory configuration tasks to create a vault and import the master
encryption key and then make that vault and its keys available to Autonomous
Database; specifically:
Create a vault in the Vault service by following
the instructions in To create
a new vault in Oracle
Cloud Infrastructure Documentation. When
following these instructions, Oracle recommends that you
create the vault in a compartment created specifically to
contain the vaults containing customer-managed keys, as
described in Compartment Hierarchy Best
Practice.
After creating the
vault, you can create at least one master encryption
key in the vault by following the instructions in
To
create a new master encryption key in Oracle Cloud Infrastructure
Documentation. You can also import a
customer encryption key into an existing vault. When
following these instructions, make these choices:
Create in Compartment:
Oracle recommends that you create the master
encryption key in the same compartment as its
vault; that is, the compartment created
specifically to contain the vaults containing
customer-managed keys.
Protection Mode: Choose an
appropriate value from the drop-down list:
HSM to create a master
encryption key that is stored and processed on a
hardware security module (HSM).
Software to create a master
encryption key that is stored in a software file
system in the Vault service. Software-protected
keys are protected at rest using an HSM-based root
key. You may export software keys to other key
management devices or to a different OCI cloud
region. Unlike HSM keys, software-protected keys
are free of cost.
Key Shape Algorithm:
AES
Key Shape Length: 256
bits
Import External Key: To use
a customer encryption key (BYOK), select
Import External Key and
provide the following details:
Wrapping Key Information. This
section is read-only, but you can view the public
wrapping key details.
Wrapping Algorithm. Select a
wrapping algorithm from the drop-down list.
External Key Data Source. Upload
the file that contains the wrapped RSA key
material.
Note
You
can either import the key material as a new
external key version or click the name of an
existing master encryption key and rotate it to a
new key version.
Use the IAM service to Create a Dynamic Group
identifying your Autonomous Database resources and a policy statement
granting that dynamic group access to the master encryption
keys you created.
After configuring the customer-managed BYOK using the above steps, you can use it
by rotating the existing encryption key from the
Details page of Autonomous Container Database
or Autonomous Database. See Rotate the Encryption Key of
an Autonomous Container Database for more details.
Use External Keys from OCI External Key
Management Service (OCI EKMS) 🔗
APPLIES TO: Oracle Public Cloud only
Before you can use external keys from OCI EKMS, you must perform number of preparatory
configuration tasks to create a vault and then make that vault and its keys available to Autonomous Database.
In OCI EKMS, you can store and control master encryption keys (as external keys) on
a third-party key management system hosted outside OCI. You can use this for
enhanced data security or if you have regulatory compliance to store keys
outside Oracle Public Cloud or any third-party cloud premises. With the
actual keys residing in the third-party key management system, you create
only key references in OCI.
You can create and manage a vault that holds key references in
OCI EKMS. You can use the keys from OCI EKMS with Autonomous Database on Dedicated Exadata Infrastructure
deployed on Oracle Public Cloud. See Creating
a vault in OCI EKMS for more details. When
following these instructions, make these choices:
Create in Compartment: Select
a compartment for the OCI EKMS vault.
IDCS Account Name URL: Enter
the authentication URL that you use to access the
KMS service. The Console redirects to a sign in
screen.
Key Management Vendor: Select
a third-party vendor that deploys key management
service. For now, OCI KMS supports only
Thales as the external key
management vendor.
Client application ID: Enter
the OCI KMS client ID generated when you register
the confidential client application in Oracle
Identity Domain.
Client application secret:
Enter the Secret ID of the confidential client
application registered in the Oracle Identity
Domain.
Private endpoint in
compartment: Select the private endpoint GUID
of the external key management.
External Vault URL: Enter
the vault URL that was generated when you created
vault in external key management.
Use the IAM service to Create a Dynamic Group
identifying your Autonomous Database resources and a policy statement
granting that dynamic group access to the master encryption
keys you created.
Create a Service Gateway, a Route Rule and an
Egress Security Rule 🔗
Oracle Cloud Infrastructure (OCI) Service Gateway provides private, secure
access to multiple Oracle Cloud services simultaneously from within a virtual cloud network
(VCN) or on-premises network via a single gateway without traversing the
internet.
Create a service gateway in the VCN (Virtual Cloud Network) where your Autonomous Database resources reside by following
the instructions in Task 1: Create the service
gateway in Oracle Cloud Infrastructure
Documentation.
After creating the service gateway, add a route rule and an egress security
rule to each subnet (in the VCN) where Autonomous Database resources reside so that these resources can use the
gateway to access the Vault service:
Go to the Subnet Details page for the subnet.
In the Subnet Information tab, click the name of the subnet's
Route Table to display its Route Table Details page.
In the table of existing Route Rules, check whether there is
already a rule with the following characteristics:
Destination: All IAD Services In Oracle Services
Network
Target Type: Service Gateway
Target: The name of the service gateway you just
created in the VCN
If such a rule does not exist, click Add Route Rules
and add a route rule with these characteristics.
Return to the Subnet Details page for the subnet.
In the subnet's Security Lists table, click the name of the
subnet's security list to display its Security List Details page.
In the side menu, under Resources, click Egress
Rules.
In the table of existing Egress Rules, check whether there is
already a rule with the following characteristics:
Stateless: No
Destination: All IAD Services In Oracle Services
Network
IP Protocol: TCP
Source Port Range: All
Destination Port Range: 443
If such a rule does not exist, click Add Egress Rules
and add an egress rule with these characteristics.
To grant your Autonomous Database
resources permission to access customer-managed keys, you create an IAM dynamic group that
identifies these resources and then create an IAM policy that grants this dynamic group
access to the master encryption keys you created in the Vault service.
When defining the dynamic group, you identify your Autonomous Database resources by specifying the OCID
of the compartment containing your Exadata Infrastructure resource.
Copy the OCID of the compartment containing your Exadata
Infrastructure resource. You can find this OCID on the Compartment
Details page of the compartment.
Create a dynamic group by following the instructions in To create a dynamic group
in Oracle Cloud Infrastructure Documentation. When
following these instructions, enter a matching rule of this
format:
ALL {resource.compartment.id ='<compartment-ocid>'}
where <compartment-ocid> is
the OCID of the compartment containing your Autonomous Exadata VM Cluster
resource.
After creating the dynamic group, navigate to (or create) an IAM policy in a
compartment higher up in your compartment hierarchy than the compartment containing your
vaults and keys. Then, add a policy statement of this
format:
allow dynamic-group <dynamic-group-name>
to manage keys
in compartment <vaults-and-keys-compartment>
where all {
target.key.id='<key_ocid>',
request.permission!='KEY_MOVE',
request.permission!='KEY_IMPORT'
}
If you are using a replicated virtual vault or replicated virtual private
vault for the Autonomous Data Guard deployment, add an additional policy statement of
this
format:
allow dynamic-group <dynamic-group>
to read vaults
in tenancy | compartment <vaults-and-keys-compartment>
where <dynamic-group> is the name of the
dynamic group you created and
<vaults-and-keys-compartment> is the name of
the compartment in which you created your vaults and master encryption keys.
Oracle Key Vault (OKV) is a full-stack, security-hardened software appliance built
to centralize the management of keys and security objects within your enterprise. You
integrate your on-premises OKV deployment with Oracle Autonomous Database on Dedicated Exadata Infrastructure to create and manage
your own the master keys.
Before you can use customer-managed keys stored in OKV, you must perform a number of
preparatory configuration tasks as described in Prepare to Use Oracle Key Vault.
After configuring the customer-managed keys in OKV, you can configure it
while provisioning an Autonomous Container Database (ACD) or by rotating the existing
encryption key from the Details page of ACD or Autonomous Database. Autonomous Databases provisioned in this ACD will automatically
inherit these encryption keys. See Create an Autonomous Container Database or Rotate the Encryption Key of an Autonomous Container
Database for more details.