From 822f57782573f7a76fc5ea7aa3f15e0fc56d6829 Mon Sep 17 00:00:00 2001 From: apopova <61460069+AnastasiaTWW@users.noreply.github.com> Date: Thu, 6 Jun 2024 17:35:04 +0400 Subject: [PATCH] describe the new APIFW_SERVER_REQUEST_HOST_HEADER env var (#105) --- docs/installation-guides/docker-container.md | 1 + docs/installation-guides/graphql/docker-container.md | 1 + docs/release-notes.md | 4 +++- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/installation-guides/docker-container.md b/docs/installation-guides/docker-container.md index c4103e6..91efcd5 100644 --- a/docs/installation-guides/docker-container.md +++ b/docs/installation-guides/docker-container.md @@ -98,6 +98,7 @@ Pass API Firewall configuration in **docker-compose.yml** → `services.api-fire | `APIFW_SHADOW_API_UNKNOWN_PARAMETERS_DETECTION` | This specifies whether requests are identified as non-matching the specification if their parameters do not align with those defined in the OpenAPI specification. The default value is `true`.

If running API Firewall in the [`API` mode](api-mode.md), this variable takes on a different name `APIFW_API_MODE_UNKNOWN_PARAMETERS_DETECTION`. | No | | `APIFW_MODSEC_CONF_FILES` | Allows to set the list of [ModSecurity](../migrating/modseс-to-apif.md) configuration files. The delimiter is ;. The default value is [] (empty). Example: `APIFW_MODSEC_CONF_FILES=modsec.conf;crs-setup.conf.example`. | No | | `APIFW_MODSEC_RULES_DIR` | Allows to set the [ModSecurity](../migrating/modseс-to-apif.md) directory with the rules that should be loaded. The files with the `*.conf` wildcard will be loaded from the directory. The default value is `""`. | No | +| `APIFW_SERVER_REQUEST_HOST_HEADER` | Sets a custom `Host` header for requests forwarded to your backend after API Firewall validation. | No | **With `services.api-firewall.ports` and `services.api-firewall.networks`**, set the API Firewall container port and connect the container to the created network. The provided **docker-compose.yml** instructs Docker to start API Firewall connected to the `api-firewall-network` [network](https://docs.docker.com/network/) on the port 8088. diff --git a/docs/installation-guides/graphql/docker-container.md b/docs/installation-guides/graphql/docker-container.md index 42bc5d9..9b979a3 100644 --- a/docs/installation-guides/graphql/docker-container.md +++ b/docs/installation-guides/graphql/docker-container.md @@ -103,6 +103,7 @@ Pass API Firewall configuration in **docker-compose.yml** → `services.api-fire | `APIFW_LOG_LEVEL` | API Firewall logging level. Possible values: The default value is `DEBUG`. Logs on requests and responses that do not match the provided schema have the ERROR type. | No | | `APIFW_SERVER_DELETE_ACCEPT_ENCODING` | If it is set to `true`, the `Accept-Encoding` header is deleted from proxied requests. The default value is `false`. | No | | `APIFW_LOG_FORMAT` | The format of API Firewall logs. The value can be `TEXT` or `JSON`. The default value is `TEXT`. | No | +| `APIFW_SERVER_REQUEST_HOST_HEADER` | Sets a custom `Host` header for requests forwarded to your backend after API Firewall validation. | No | **With `services.api-firewall.ports` and `services.api-firewall.networks`**, set the API Firewall container port and connect the container to the created network. diff --git a/docs/release-notes.md b/docs/release-notes.md index 09fdddc..22feae8 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -6,7 +6,9 @@ This page describes new releases of Wallarm API Firewall. * Dependency upgrade * Supported new interface for the `api` mode usage, only for internal use -* Added the APIFW_SERVER_REQUEST_HOST_HEADER env variable to set the custom host value for proxied requests +* Added the `APIFW_SERVER_REQUEST_HOST_HEADER` environment variable to set a custom `Host` header for requests forwarded to your backend after API Firewall validation + + This variable is supported in the [`PROXY`](installation-guides/docker-container.md) and [`graphql`](installation-guides/graphql/docker-container.md) API Firewall modes. ## v0.7.2 (2024-04-16)