io.vertx.ext.web

## Enum AllowForwardHeaders

- java.lang.Object
- - java.lang.Enum<AllowForwardHeaders>
  - - io.vertx.ext.web.AllowForwardHeaders

- All Implemented Interfaces:
    Serializable, Comparable<AllowForwardHeaders>

      public enum AllowForwardHeaders
      extends Enum<AllowForwardHeaders>

  What kind of forward header parsing are we allowing.
  Author:
    Paulo Lopes

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `ALL` Will process both `FORWARD` and `X_FORWARD`.
    `FORWARD` Only process the standard `Forward` header as defined by | `NONE` No parsing shall be performed.
    `X_FORWARD` Only process the non standard but widely used `X-Forward-*` headers.

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static AllowForwardHeaders` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static AllowForwardHeaders[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### NONE

          public static final AllowForwardHeaders NONE

      No parsing shall be performed.

    - #### FORWARD

          public static final AllowForwardHeaders FORWARD

      Only process the standard `Forward` header as defined by https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Forwarded

    - #### X_FORWARD

          public static final AllowForwardHeaders X_FORWARD

      Only process the non standard but widely used `X-Forward-*` headers. These headers are not official standards but widely used. Users are advised to avoid them for new applications.

    - #### ALL

          public static final AllowForwardHeaders ALL

      Will process both `FORWARD` and `X_FORWARD`. Be aware that mixing the 2 headers can open security holes as specially crafted requests that are not validated as proxy level can allow bypassing the proxy desired forward value. For example, a proxy will add the `X-Forward-*` headers to a request but not filter out if the original request includes the `Forward` header.

  - ### Method Detail

    - #### values

          public static AllowForwardHeaders[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (AllowForwardHeaders c : AllowForwardHeaders.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static AllowForwardHeaders valueOf(String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `IllegalArgumentException` - if this enum type has no constant with the specified name
        `NullPointerException` - if the argument is null

Copyright © 2022 Eclipse. All rights reserved.