Describe the bug
I am unable to migrate away from awskms seal type if vault was initialized with the awskms seal configuration originally.
To Reproduce
seal "awskms" {
#disabled = "true"
region = "eu-central-1"
kms_key_id = "*redacted*"
}
Then I get the following error.
Error unsealing: Error making API request.
URL: PUT https://127.0.0.1:8200/v1/sys/unseal
Code: 500. Errors:
* error setting new barrier key information during migrate: stored keys are not supported
Expected behavior
I excpected the vault to be unsealed and converted to shamir Seal Type like described in the documentation: https://www.vaultproject.io/docs/concepts/seal.html#seal-migration
If the vault is first initialized without awskms the migration works as expected both ways. I believe this is a bug, or at least it is unclear in the documentation.
Is there a way to work around this for an existing cluster?
Environment:
vault status): Version 1.3.0vault version): Version 1.3.0Vault server configuration file(s):
seal "awskms" {
region = "eu-central-1"
kms_key_id = "*redacted*"
}
I'm hitting the same issue with the transit autounseal method.
My configuration is:
{
"listener": {
"tcp": {
"address": "127.0.0.1:8200",
"tls_disable": 1
}
},
"storage": {
"file": {
"path": "/data"
}
},
"disable_mlock": true,
"seal": {
"transit": {
"disabled": "true",
"address": "http://vaultInfra:8200",
"disable_renewal": "false",
"key_name": "autounseal",
"mount_path": "transit/",
"tls_skip_verify": "true"
}
}
}
And when I try to migrate, i get:
$ vault operator unseal -migrate
Unseal Key (will be hidden):
Key Value
--- -----
Seal Type shamir
Initialized true
Sealed true
Total Shares 3
Threshold 2
Unseal Progress 1/2
Unseal Nonce 41531879-5565-bd37-5278-a6ca7dc242f3
Seal Migration in Progress true
Version 1.3.0
HA Enabled false
$ vault operator unseal -migrate
Unseal Key (will be hidden):
Error unsealing: Error making API request.
URL: PUT http://localhost:8200/v1/sys/unseal
Code: 500. Errors:
* error setting new barrier key information during migrate: stored keys are not supported
same issue for me too
Same issue also for 1.3.1 using gcpckms keys when converting to shamir
I also hit this issue when attempting to convert from awskms to shamir
This issue has been resolved in Vault 1.3.2 https://github.com/hashicorp/vault/pull/8172
Conversion from auto seal gcpckms to shamir is working as expected without the error.
Most helpful comment
This issue has been resolved in Vault 1.3.2 https://github.com/hashicorp/vault/pull/8172
Conversion from auto seal gcpckms to shamir is working as expected without the error.