> For the complete documentation index, see [llms.txt](https://docs.prismacloud.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.prismacloud.io/admin-guide/web-application-and-api-security-waas/deploy-waas/deployment-hosts.md).

# Deploy WAAS for Hosts

To deploy WAAS to protect a host running a non-containerized web application, create a new rule, specify the host(s) where the application runs, define protected HTTP endpoints, and select protections.

## Create a WAAS In-Line rule for Hosts

1. Open Console, and go to **Defend > WAAS > {Container|Host} > In-Line**.
2. Select **Add rule**.
   1. Enter a **Rule Name**
   2. Enter **Notes** (Optional) for describing the rule.
   3. Select **Operating system**.
   4. If necessary, adjust the **Proxy timeout**

      The maximum duration in seconds for reading the entire request, including the body. A 500 error response is returned if a request is not read within the timeout period. For applications dealing with large files, adjusting the proxy timeout is necessary.
3. Choose the rule **Scope** by specifying the resource collection(s) to which it applies.

   <figure><img src="/files/aMnGpEi5spoapugFEVtI" alt="waas select scope"><figcaption></figcaption></figure>

   Collections define a combination of hosts to which WAAS should attach itself to protect the web application:

   <figure><img src="/files/SdmeDuymvnLsWpdNtJ3A" alt="waas define host collection"><figcaption></figcaption></figure>

   Applying a rule to all hosts/images using a wild card (`*`) is invalid and a waste of resources. WAAS only needs to be applied to hosts that run applications that transmit and receive HTTP/HTTPS traffic.
4. (Optional) Enable **API endpoint discovery**

   When enabled, the Defender inspects the API traffic to and from the protected API. Defender reports a list of the endpoints and their resource path in **Compute > Monitor > WAAS > API discovery**.
5. (Optional) Enable **Automatically detect ports** for an endpoint to deploy WAAS protection on ports identified in the unprotected web apps report in **Monitor > WAAS > Unprotected web apps** for each of the workloads in the rule scope.

   As an additional measure, you can specify additional ports by specifying them in the protected HTTP endpoints within each app to also include the ports that may not have been detected automatically.

   By enabling both **Automatically detect ports** and **API endpoint discovery**, you can monitor your API endpoints and ports without having to add an application and without configuring any policies.

   **Automatically detect ports** is not available for Windows Operating System.
6. **Save** the rule.

## Add an App (policy) to the rule

1. Select a WAAS rule to add an App in.
2. Select **Add app**.
3. In the **App Definition** tab, enter an **App ID**.

   The combination of **Rule name** and **App ID** must be unique across In-Line and Out-Of-Band WAAS policies for Containers, Hosts, and App-Embedded.

   If you have a Swagger or OpenAPI file, click **Import**, and select the file to load.

   If you do not have a Swagger or OpenAPI file, manually define each endpoint by specifying the host, port, and path.

   1. In **Endpoint Setup**, click **Add Endpoint**.

      Specify endpoint in your web application that should be protected. Each defined application can have multiple protected endpoints.
   2. Enter **HTTP host** (optional, wildcards supported).

      HTTP hostnames are specified in the form of \[hostname]:\[external port].

      The external port is defined as the TCP port on the host, listening for inbound HTTP traffic. If the value of the external port is "80" for non-TLS endpoints or "443" for TLS endpoints it can be omitted. Examples: "\*.example.site", "docs.example.site", "[www.example.site:8080](http://www.example.site:8080)", etc.
   3. Enter **App ports** as the internal port your app listens on.

      (You can skip to enter App ports, if you selected **Automatically detect ports** while creating the rule).

      When **Automatically detect ports** is selected, any ports specified in a protected endpoint definition will be appended to the list of protected ports. Specify the TCP port listening for inbound HTTP traffic.

      If your application uses **TLS** or **gRPC**, you must specify a port number.
   4. Enter **Base path** (optional, wildcards supported):

      Base path for WAAS to match when applying protections.

      Examples: "/admin", "/" (root path only), "/\*", /v2/api", etc.
   5. Enter **WAAS port (only required for Windows, App-Embedded or when using** [**"Remote host"**](/admin-guide/web-application-and-api-security-waas/waas-advanced-settings.md#remote-host) **option)** as the external port WAAS listens on. The external port is the TCP port for the App-Embedded Defender to listen on for inbound HTTP traffic.

      <figure><img src="/files/krD03HpYJpjRjejxHCqK" alt="cwp 42473 add app waas port windows"><figcaption></figcaption></figure>

      Protecting Linux-based hosts does not require specifying a **`WAAS port`** since WAAS listens on the same port as the protected application. Because Windows has its own internal traffic routing mechanisms, WAAS and the protected application cannot use the same **`App port`**. Consequently, when protecting Windows-based hosts the **`WAAS port`** should be set to the port end-users send requests to, and the **`App port`** should be set to a **different** port on which the protected application will listen and to which WAAS will forward traffic.
   6. If your application uses TLS, set **TLS** to **On**.

      You can select the TLS protocol (1.0, 1.1, 1.2, and 1.3 for WAAS In-Line, and 1.0, 1.1, and 1.2 for WAAS Out-Of-Band) to protect the API endpoint and enter the TLS certificate in PEM format.
   7. You can select **Response headers** to add or override HTTP response headers in responses sent from the protected application.

      <figure><img src="/files/3ExdDZW9wbVDMNgUdfe8" alt="waas response headers"><figcaption></figcaption></figure>
   8. Select **Create response header**.
   9. To facilitate inspection, after creating all endpoints, click **View TLS settings** in the endpoint setup menu.

      WAAS TLS settings:

      <figure><img src="/files/WWeYOkdK8EtScV6TPEwy" alt="waas inline app embedded tls"><figcaption></figcaption></figure>

      * **Certificate** - Copy and paste your server’s certificate and private key into the certificate input box (e.g., `cat server-cert.pem server-key > certs.pem`).
      * **Minimum TLS version** - A minimum version of TLS can be enforced by WAAS In-Line to prevent downgrading attacks (the default value is TLS 1.2).
      * **HSTS** - The [HTTP Strict-Transport-Security (HSTS)](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security) response header lets web servers tell browsers to use HTTPS only, not HTTP. When enabled, WAAS would add the HSTS response header to all HTTPS server responses (if it is not already present) with the preconfigured directives - `max-age`, `includeSubDomains`, and `preload`.
        1. `max-age=<expire-time>` - Time, in seconds, that the browser should remember that a site is only to be accessed using HTTPS.
        2. `includeSubDomains` (optional) - If selected, HSTS protection applies to all the site’s subdomains as well.
        3. `preload` (optional) - For more details, see the following [link](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security#preloading_strict_transport_security).
   10. If you application requires [API protection](/admin-guide/web-application-and-api-security-waas/waas-api-protection.md), for each path define the allowed methods and the parameters.
4. Continue to **App Firewall** settings, select the [protections](/admin-guide/web-application-and-api-security-waas/waas-app-firewall.md) to enable and assign them with [actions](/admin-guide/web-application-and-api-security-waas/waas-intro.md#actions).
5. Configure the [DoS protection](/admin-guide/web-application-and-api-security-waas/waas-dos-protection.md) thresholds.
6. Continue to **Access Control** tab and select [access controls](/admin-guide/web-application-and-api-security-waas/waas-access-control.md) to enable.
7. Select the [bot protections](/admin-guide/web-application-and-api-security-waas/waas-bot-protection.md) you want to enable.
8. Select the required [Custom rules](/admin-guide/web-application-and-api-security-waas/waas-custom-rules.md).
9. Proceed to [Advanced settings](/admin-guide/web-application-and-api-security-waas/waas-advanced-settings.md) for more WAAS controls.
10. Select **Save**.
11. The **Rule Overview** page shows all the WAAS rules created.

    Select a rule to display the **Rule Resources**, and for each application a list of protected endpoints and the protections enabled for each endpoint are displayed.
12. Test protected endpoint using the following [sanity tests](/admin-guide/web-application-and-api-security-waas/waas-app-firewall.md#sanity-tests).
13. Go to **Monitor > Events**, click on **WAAS for containers/hosts/App-Embedded**, and observe the events generated.

    For more information, see the [WAAS analytics help page](/admin-guide/web-application-and-api-security-waas/waas-analytics.md).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.prismacloud.io/admin-guide/web-application-and-api-security-waas/deploy-waas/deployment-hosts.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
