# Encrypting header value

**URL:** <https://community.traefik.io/t/encrypting-header-value/10426>\
**Category:** Traefik v2\
**Tags:** middleware, docker\
**Created:** [April 22, 2021, 10:17am UTC](https://community.traefik.io/t/encrypting-header-value/10426 "2021-04-22T10:17:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![hoefling](https://sea2.discourse-cdn.com/flex020/user_avatar/community.traefik.io/hoefling/32/3695_2.png) [@hoefling](https://community.traefik.io/u/hoefling)\
**Post date:** [April 22, 2021, 10:17am UTC](https://community.traefik.io/t/encrypting-header-value/10426/1 "2021-04-22T10:17:57Z")

</div>

Hi, is there a possibility to encrypt an arbitrary header value in Traefik? Suppose I have configured in my `docker-compose.yml`:

```auto
pypi:
  labels:
      - "traefik.enable=true"
      - "traefik.http.routers.pypi.rule=Host(`pypi.localhost`)"
      - "traefik.http.routers.pypi.entrypoints=web"
      - "traefik.http.routers.pypi.middlewares=pypi-auth"
      - "traefik.http.middlewares.pypi-auth.headers.customrequestheaders.Private-Token=v3rys3cr3t"

```

Is there a way to avoid storing `v3rys3cr3t` in plaintext? Similar as it can be done e.g. for the basic auth.
