Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

github.com/opaas-cloud/traefik-plugin-proxy-cookie

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/opaas-cloud/traefik-plugin-proxy-cookie

  • v1.4.1
  • Source
  • Go
  • Socket score

Version published
Created
Source

Proxy Cookie Plugin is a middleware plugin for Traefik which adds the functionylity of the proxy_cookie directives known from NGINX to Traefik.

Configuration

Static

experimental:
  plugins:
    proxyCookie:
      modulename: "github.com/SchmitzDan/traefik-plugin-proxy-cookie"
      version: "v0.0.x" #replace with newest version

Dynamic

To configure the plugin you should create a middleware in your dynamic configuration as explained here. The following example creates and uses the plugin to add the prefix "/foo" to the cookie paths and change the cookie domain from "subdomain.foo." to "foo.":

http:
  routes:
    my-router:
      rule: "Host(`localhost`)"
      service: "my-service"
      middlewares : 
        - "proxyCookie"
  services:
    my-service:
      loadBalancer:
        servers:
          - url: "http://127.0.0.1"
  middlewares:
    proxyCookie:
      plugin:
        proxyCookie:
          domain:
            rewrites:
              - regex: "^subdomain.foo.(.+)$"
                replacement: "foo.$1"
          path:
            prefix: "foo"

Configuration can also be set via toml or docker labels.

You can also define a set of rewrites for the path. If both, a prefix and one or more rewrites is defined for the path, the path will be prefixed first and afterwords the rewrites are applied to the path.

FAQs

Package last updated on 12 Aug 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc