# Http-connector authentication? + Secret storage?

**URL:** <https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070>\
**Category:** Discussion & Questions\
**Tags:** process-engine\
**Created:** [July 11, 2016, 4:54pm UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070 "2016-07-11T16:54:28Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![StephenOTT](https://forum.camunda.io/letter_avatar_proxy/v4/letter/s/d2c977/32.png) [@StephenOTT](https://forum.camunda.io/u/StephenOTT)\
**Post date:** [July 11, 2016, 4:54pm UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/1 "2016-07-11T16:54:28Z")

</div>

Is there any code examples of having http connector use any form of authentication to a web service?  
Looking for some patterns. My initial thought is your store any sort of credentials as a process variable?

But additional question is: any sort of patterns for Secret/credential storage? Something like use case with Hashicorp Vault, etc?

I know you can abstract into delegate code, but looking at http connector first and then expand from there 🙂

---

<div class="post-metadata">

**Author:** ![Webcyberrob](https://forum.camunda.io/user_avatar/forum.camunda.io/webcyberrob/32/5990_2.png) [@Webcyberrob](https://forum.camunda.io/u/Webcyberrob)\
**Post date:** [July 11, 2016, 9:35pm UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/2 "2016-07-11T21:35:10Z")

</div>

Hi Stephen,  
Ive wrestled with this myself. One option Ive considered is store the secrets in the catalina.properties file and thus they are available as system properties. Hence in connector code, use an expression to substitute the property value. In addition, I can have different property file in each environment (dev, test etc). Hence the process model works in each environment unchanged.

In terms of restricted access, for a production linux machine, Id create a system account for tomcat, but disable login/console access. Hence the system can run as tomcat, but nobody can get onto the consol as tomcat. The admins must login with a privileged account and sudo. Hence the ‘secrets’ are protected via access controls on a need to know basis…

regards

Rob

---

<div class="post-metadata">

**Author:** ![StephenOTT](https://forum.camunda.io/letter_avatar_proxy/v4/letter/s/d2c977/32.png) [@StephenOTT](https://forum.camunda.io/u/StephenOTT)\
**Post date:** [July 11, 2016, 9:42pm UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/3 "2016-07-11T21:42:30Z")

</div>

Interesting.

In your example, the properties file would be accessible to all processes within a deployment or across all deployments? (In my scenario we use shared engine with only Camunda Deployments/REST API deployments. No WAR deployments).

I don’t see a problem with storing something like Hashicorp Vault keys in the process as long as it is auditable and could roll the access as required through the Vault. Additionally you could add restrictions that would make is so only the specific process would be able to access information in the vault. But again not a “perfect” solution as of yet.

[@camunda](https://forum.camunda.io/groups/camunda) any thoughts or best practices?

---

<div class="post-metadata">

**Author:** ![hawky4s](https://forum.camunda.io/user_avatar/forum.camunda.io/hawky4s/32/25_2.png) [@hawky4s](https://forum.camunda.io/u/hawky4s)\
**Post date:** [July 12, 2016, 8:52am UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/4 "2016-07-12T08:52:51Z")

</div>

Hi Stephen,

Imo using Vault or a similar token-based mechanism is probably the best tradeoff of security / auditing / usability.  
You could inject a (one-/multiple-time-usage) token from vault at the start of the process which allows the process to use the token to pull in the credentials from vault one or more times at the right time. It shouldn’t be a problem to save the token as a process variable because of its short lifetime. When using Vault, probably the [cubbyhole backend](https://www.hashicorp.com/blog/vault-cubbyhole-principles.html) is the way to go. I experimented with it for injecting secrets in docker image/containers for our CI environment.  
Imo Vault is especially nice to work with because of its rich right/namespace model and the REST API.

Cheers,  
Christian

---

<div class="post-metadata">

**Author:** ![StephenOTT](https://forum.camunda.io/letter_avatar_proxy/v4/letter/s/d2c977/32.png) [@StephenOTT](https://forum.camunda.io/u/StephenOTT)\
**Post date:** [July 12, 2016, 1:43pm UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/5 "2016-07-12T13:43:56Z")

</div>

@hawky4s Thanks! You see the token from vault is being invoked/injected from outside of the process or called from inside of the process?

---

<div class="post-metadata">

**Author:** ![StephenOTT](https://forum.camunda.io/letter_avatar_proxy/v4/letter/s/d2c977/32.png) [@StephenOTT](https://forum.camunda.io/u/StephenOTT)\
**Post date:** [April 27, 2017, 6:55pm UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/6 "2017-04-27T18:55:23Z")

</div>

@hawky4s did you ever do any more in this space? I have circled back to it and looking at doing a implementation with “something” in the next few weeks.

---

<div class="post-metadata">

**Author:** ![StephenOTT](https://forum.camunda.io/letter_avatar_proxy/v4/letter/s/d2c977/32.png) [@StephenOTT](https://forum.camunda.io/u/StephenOTT)\
**Post date:** [November 23, 2017, 12:48am UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/7 "2017-11-23T00:48:51Z")

</div>

Cross-Reference for future info:

> [@Using secrets/passwords securely in processes (Using Docker Secrets, not storing passwords in process variables)](https://forum.camunda.io/t/using-secrets-passwords-securely-in-processes-using-docker-secrets-not-storing-passwords-in-process-variables/5367):
>
> Hey all So we have had some discussions about how to store secrets/passwords when working with Processes: Recently we came up with the following solution: Using Docker Secrets ([Blog | Docker](https://blog.docker.com/2017/02/docker-secrets-management/)) you can manage sensitive data: with the Secrets feature, which basically creates a in-memory volume that stores your secret(s): [Manage sensitive data with Docker secrets | Docker Docs](https://docs.docker.com/engine/swarm/secrets) How Docker manages secrets When you add a secret to the swarm, Docker sends the secret to the swarm manager over a m…

---

<div class="post-metadata">

**Author:** ![system](https://forum.camunda.io/uploads/default/original/3X/5/8/58d50142eacca605d35cb1ef9e6b86ae85f49436.png) [@system](https://forum.camunda.io/u/system)\
**Post date:** [January 30, 2024, 10:37am UTC](https://forum.camunda.io/t/http-connector-authentication-secret-storage/1070/8 "2024-01-30T10:37:57Z")

</div>

Closed on January 30, 2024, 10:37am UTC


