spring-cloud / spring-cloud/spring-cloud-vault

VaultTransitOperations.decrypt method returns a strange string, which expects the plaintext of the data key.

Open
#686 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
291
Forks
152
Avg merge
11h 24m
Merged PRs (30d)
3

Description

Describe the bug
I'm using Spring Cloud Vault to test decryption through Transit engine.

If I simply encrypt a string like "hello world" in the Transit engine and send the cipher text to VaultTransitOperations.decrypt, I can see hello world normally.

However, if I create a data key and put the received cipher text into VaultTransitOperations.decrypt and execute it, it responds with a strange string.

I don't know what else to do, so I'm reporting it here.

Sample

Test the cipher text received by encrypting hello world through transit engine.
2023-03-31_19-01-05

Test the cipher text received by generating a data key through the transit engine. The expected value is the plain text of the data key.
2023-03-31_19-02-32

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at VaultTransitOperations.decrypt and reproduce the two Transit engine cases described: encrypting "hello world" and generating a data key. Compare the returned values with the expected plaintext, then identify what "done" means for the data-key case: decrypt should return the plaintext data key rather than the reported strange string.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring
Domain
cryptography, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.