How to get private key out of vault

Hi All,

I am very new to hashicorp vault and have few basic question:

  1. using transit secret engine , is there a way to get private key the way we get public key : GET /transit/keys/:name.

This is required as we are still trying to use own crypto service but use vault for only creating/storing/updating key materials.

Hi @sunil001repo!

You have to mark the key exportable ( during key creation/generation.
Afterwards, you can use the key export API endpoint ( to export the private key.


1 Like

Thanks Michel. This is what I was looking for :smile:

Just to tag on to this, once the key is made exportable, this can not be reveresed.