Class AttributeContext

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
io.envoyproxy.envoy.service.auth.v2.AttributeContext
All Implemented Interfaces:
com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, AttributeContextOrBuilder, Serializable

public final class AttributeContext extends com.google.protobuf.GeneratedMessageV3 implements AttributeContextOrBuilder
 An attribute is a piece of metadata that describes an activity on a network.
 For example, the size of an HTTP request, or the status code of an HTTP response.

 Each attribute has a type and a name, which is logically defined as a proto message field
 of the `AttributeContext`. The `AttributeContext` is a collection of individual attributes
 supported by Envoy authorization system.
 [#comment: The following items are left out of this proto
 Request.Auth field for JWTs
 Request.Api for api management
 Origin peer that originated the request
 Caching Protocol
 request_context return values to inject back into the filter chain
 peer.claims -- from X.509 extensions
 Configuration
 - field mask to send
 - which return values from request_context are copied back
 - which return values are copied into request_headers]
 [#next-free-field: 12]
 
Protobuf type envoy.service.auth.v2.AttributeContext
See Also:
  • Field Details

    • SOURCE_FIELD_NUMBER

      public static final int SOURCE_FIELD_NUMBER
      See Also:
    • DESTINATION_FIELD_NUMBER

      public static final int DESTINATION_FIELD_NUMBER
      See Also:
    • REQUEST_FIELD_NUMBER

      public static final int REQUEST_FIELD_NUMBER
      See Also:
    • CONTEXT_EXTENSIONS_FIELD_NUMBER

      public static final int CONTEXT_EXTENSIONS_FIELD_NUMBER
      See Also:
    • METADATA_CONTEXT_FIELD_NUMBER

      public static final int METADATA_CONTEXT_FIELD_NUMBER
      See Also:
  • Method Details

    • newInstance

      protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
      Overrides:
      newInstance in class com.google.protobuf.GeneratedMessageV3
    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
      Overrides:
      internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessageV3
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
    • hasSource

      public boolean hasSource()
       The source of a network activity, such as starting a TCP connection.
       In a multi hop network activity, the source represents the sender of the
       last hop.
       
      .envoy.service.auth.v2.AttributeContext.Peer source = 1;
      Specified by:
      hasSource in interface AttributeContextOrBuilder
      Returns:
      Whether the source field is set.
    • getSource

      public AttributeContext.Peer getSource()
       The source of a network activity, such as starting a TCP connection.
       In a multi hop network activity, the source represents the sender of the
       last hop.
       
      .envoy.service.auth.v2.AttributeContext.Peer source = 1;
      Specified by:
      getSource in interface AttributeContextOrBuilder
      Returns:
      The source.
    • getSourceOrBuilder

      public AttributeContext.PeerOrBuilder getSourceOrBuilder()
       The source of a network activity, such as starting a TCP connection.
       In a multi hop network activity, the source represents the sender of the
       last hop.
       
      .envoy.service.auth.v2.AttributeContext.Peer source = 1;
      Specified by:
      getSourceOrBuilder in interface AttributeContextOrBuilder
    • hasDestination

      public boolean hasDestination()
       The destination of a network activity, such as accepting a TCP connection.
       In a multi hop network activity, the destination represents the receiver of
       the last hop.
       
      .envoy.service.auth.v2.AttributeContext.Peer destination = 2;
      Specified by:
      hasDestination in interface AttributeContextOrBuilder
      Returns:
      Whether the destination field is set.
    • getDestination

      public AttributeContext.Peer getDestination()
       The destination of a network activity, such as accepting a TCP connection.
       In a multi hop network activity, the destination represents the receiver of
       the last hop.
       
      .envoy.service.auth.v2.AttributeContext.Peer destination = 2;
      Specified by:
      getDestination in interface AttributeContextOrBuilder
      Returns:
      The destination.
    • getDestinationOrBuilder

      public AttributeContext.PeerOrBuilder getDestinationOrBuilder()
       The destination of a network activity, such as accepting a TCP connection.
       In a multi hop network activity, the destination represents the receiver of
       the last hop.
       
      .envoy.service.auth.v2.AttributeContext.Peer destination = 2;
      Specified by:
      getDestinationOrBuilder in interface AttributeContextOrBuilder
    • hasRequest

      public boolean hasRequest()
       Represents a network request, such as an HTTP request.
       
      .envoy.service.auth.v2.AttributeContext.Request request = 4;
      Specified by:
      hasRequest in interface AttributeContextOrBuilder
      Returns:
      Whether the request field is set.
    • getRequest

      public AttributeContext.Request getRequest()
       Represents a network request, such as an HTTP request.
       
      .envoy.service.auth.v2.AttributeContext.Request request = 4;
      Specified by:
      getRequest in interface AttributeContextOrBuilder
      Returns:
      The request.
    • getRequestOrBuilder

      public AttributeContext.RequestOrBuilder getRequestOrBuilder()
       Represents a network request, such as an HTTP request.
       
      .envoy.service.auth.v2.AttributeContext.Request request = 4;
      Specified by:
      getRequestOrBuilder in interface AttributeContextOrBuilder
    • getContextExtensionsCount

      public int getContextExtensionsCount()
      Description copied from interface: AttributeContextOrBuilder
       This is analogous to http_request.headers, however these contents will not be sent to the
       upstream server. Context_extensions provide an extension mechanism for sending additional
       information to the auth server without modifying the proto definition. It maps to the
       internal opaque context in the filter chain.
       
      map<string, string> context_extensions = 10;
      Specified by:
      getContextExtensionsCount in interface AttributeContextOrBuilder
    • containsContextExtensions

      public boolean containsContextExtensions(String key)
       This is analogous to http_request.headers, however these contents will not be sent to the
       upstream server. Context_extensions provide an extension mechanism for sending additional
       information to the auth server without modifying the proto definition. It maps to the
       internal opaque context in the filter chain.
       
      map<string, string> context_extensions = 10;
      Specified by:
      containsContextExtensions in interface AttributeContextOrBuilder
    • getContextExtensions

      @Deprecated public Map<String,String> getContextExtensions()
      Deprecated.
      Specified by:
      getContextExtensions in interface AttributeContextOrBuilder
    • getContextExtensionsMap

      public Map<String,String> getContextExtensionsMap()
       This is analogous to http_request.headers, however these contents will not be sent to the
       upstream server. Context_extensions provide an extension mechanism for sending additional
       information to the auth server without modifying the proto definition. It maps to the
       internal opaque context in the filter chain.
       
      map<string, string> context_extensions = 10;
      Specified by:
      getContextExtensionsMap in interface AttributeContextOrBuilder
    • getContextExtensionsOrDefault

      public String getContextExtensionsOrDefault(String key, String defaultValue)
       This is analogous to http_request.headers, however these contents will not be sent to the
       upstream server. Context_extensions provide an extension mechanism for sending additional
       information to the auth server without modifying the proto definition. It maps to the
       internal opaque context in the filter chain.
       
      map<string, string> context_extensions = 10;
      Specified by:
      getContextExtensionsOrDefault in interface AttributeContextOrBuilder
    • getContextExtensionsOrThrow

      public String getContextExtensionsOrThrow(String key)
       This is analogous to http_request.headers, however these contents will not be sent to the
       upstream server. Context_extensions provide an extension mechanism for sending additional
       information to the auth server without modifying the proto definition. It maps to the
       internal opaque context in the filter chain.
       
      map<string, string> context_extensions = 10;
      Specified by:
      getContextExtensionsOrThrow in interface AttributeContextOrBuilder
    • hasMetadataContext

      public boolean hasMetadataContext()
       Dynamic metadata associated with the request.
       
      .envoy.api.v2.core.Metadata metadata_context = 11;
      Specified by:
      hasMetadataContext in interface AttributeContextOrBuilder
      Returns:
      Whether the metadataContext field is set.
    • getMetadataContext

      public Metadata getMetadataContext()
       Dynamic metadata associated with the request.
       
      .envoy.api.v2.core.Metadata metadata_context = 11;
      Specified by:
      getMetadataContext in interface AttributeContextOrBuilder
      Returns:
      The metadataContext.
    • getMetadataContextOrBuilder

      public MetadataOrBuilder getMetadataContextOrBuilder()
       Dynamic metadata associated with the request.
       
      .envoy.api.v2.core.Metadata metadata_context = 11;
      Specified by:
      getMetadataContextOrBuilder in interface AttributeContextOrBuilder
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessageV3
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessageV3
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static AttributeContext parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AttributeContext parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AttributeContext parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AttributeContext parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AttributeContext parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AttributeContext parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static AttributeContext parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static AttributeContext parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static AttributeContext parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static AttributeContext parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static AttributeContext parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static AttributeContext parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public AttributeContext.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static AttributeContext.Builder newBuilder()
    • newBuilder

      public static AttributeContext.Builder newBuilder(AttributeContext prototype)
    • toBuilder

      public AttributeContext.Builder toBuilder()
      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected AttributeContext.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
      Specified by:
      newBuilderForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstance

      public static AttributeContext getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<AttributeContext> parser()
    • getParserForType

      public com.google.protobuf.Parser<AttributeContext> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstanceForType

      public AttributeContext getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder