# PGP Signature verification?

**URL:** <https://discuss.hashicorp.com/t/pgp-signature-verification/29287>\
**Category:** Vault\
**Created:** [September 8, 2021, 3:22pm UTC](https://discuss.hashicorp.com/t/pgp-signature-verification/29287 "2021-09-08T15:22:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![dcgsteve](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/dcgsteve/32/22153_2.png) [@dcgsteve](https://discuss.hashicorp.com/u/dcgsteve)\
**Post date:** [September 8, 2021, 3:22pm UTC](https://discuss.hashicorp.com/t/pgp-signature-verification/29287/1 "2021-09-08T15:22:08Z")

</div>

We are currently passing hashed text into Vault and signing, verifying ok I think. However, I’m confused how someone without access to Vault could confirm the authenticity of, say, a file we have supplied them.

I.E.

- SHA256 hash produced from file A
- Hash is signed using a transit/key in Vault
- File A is sent to customer

What does the customer need and how do they verify the file?

I have private/public encryption keys available in transit/key and also have the signature produced when I signed the File A hash

Is the public key all they need, and how do they confirm that it’s correct?

There is a GPG 3rd party plugin which more closely matches the type of information I was expecting to see e.g.

```auto
{
  "real_name": "John Doe",
  "email": "john.doe@example.com",
  "key_bits": 4096
}

```

…but I’m not hugely keen on 3rd party non-official plugins and it doesn’t seem to have any key rotation support built-in so we would have to roll our own ☹

---

<div class="post-metadata">

**Author:** ![jboero](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/jboero/32/8396_2.png) [@jboero](https://discuss.hashicorp.com/u/jboero)\
**Post date:** [April 28, 2022, 11:15am UTC](https://discuss.hashicorp.com/t/pgp-signature-verification/29287/2 "2022-04-28T11:15:21Z")

</div>

Sorry this was a long time ago but I thought I’d drop in my blog post on this topic. This can be easily done with the Transit engine. If you’re doing a test on the cli/api there are examples here. Note that when using `echo` or redirection for testing you may hit issues with the implicit newline it adds, `echo -n` preferred.

> **[Hashicorp Vault for Tamper Protection and — Whoops I Accidentally Created a...](https://medium.com/hashicorp-engineering/hashicorp-vault-for-tamper-protection-and-whoops-i-accidentally-created-a-blockchain-1980dbeb909b)**
>
> A recent project in which I used Vault Transit to sign and verify certification badge images presented an interesting use case for…
