Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support the full extent of the encryption module configurability #3

Closed
robobario opened this issue Jun 20, 2023 · 1 comment
Closed

Comments

@robobario
Copy link

robobario commented Jun 20, 2023

Currently we use a hardcoded test-kms only, that offers up a hardcoded key. Lets support some real KMS implementations 😁

The encryption module is configured by two configuration files loaded with Jackson. We could embed these configuration classes directly into our YAML configuration, or instead reference the two files from the kroxy configuration YAML, loading them exactly as the encmod would. Or support both styles.

For vault integration it would be cool to integration test it with a vault testcontainer. Maybe there's something out there for key-protect testing too.

We currently only support the test-kms, to build the others into a fat jar will require combining their META-INF. Or we could remove the KMS implementations from the fat jar and install them separately into the Kroxylicious classpath.

Here's an example of the JSON configuration

embedded YAML style

kroxylicious-config.yaml

filters:
  type: TopicEncryption::DecryptFetch
  config:
    kmsDefs:
      - name: cloud
        type: key-protect
        uri: http://sfsffs.ibm.com/abc
        instanceId: shdjkjahkjahd
        credential: <apikey>
    topicPolicies:
      - name: topicA
        kmsName: cloud
        keyReference: topicAKey

separate configuration with references

kroxylicious-config.yaml

filters:
  type: TopicEncryption::DecryptFetch
  config:
    kmsDefsFile: "/path/to/kmsdefs.json"
    topicPoliciesFile: "/path/to/topicPolicies.json"
@robobario
Copy link
Author

Implemented with #7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant