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 Details

    • 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 invalid input: '<'a href="https://tools.ietf.org/html/rfc7239#section-4>RFC 7239, section 4: Forwarded. For more info see: 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 Details

    • values

      public static AllowForwardHeaders[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      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