envoyproxy / envoyproxy/gateway

HTTP route rule processing does not check for DirectResponse or Redirect when filter processing has an error

Open Beginner friendly
#9,454 0 comments 0 reactions 0 assignees View on GitHub
help wanted kind/bug triage
Dominant language
Go
Stars
3k
Forks
864
Avg merge
2d 2h
Merged PRs (30d)
140

Description

**If you are reporting *any* crash or *any* potential security issue, *do not*
open an issue in this repo. Please report the issue via emailing
envoy-gateway-security@googlegroups.com where the issue will be triaged appropriately.**

*Description*:
>What issue is being seen? Describe what should be happening instead of
the bug, for example: The expected value isn't returned, etc.

The `processFilterError != nil` block in HTTPRoute rule processing ([ref](https://github.com/envoyproxy/gateway/blob/688ade86d2037f61366fe757ed1b0c0ee46978e9/internal/gatewayapi/route.go#L323-L337)) is missing the following check present in GRPCRoute rule processing ([ref](https://github.com/envoyproxy/gateway/blob/688ade86d2037f61366fe757ed1b0c0ee46978e9/internal/gatewayapi/route.go#L1037))

```
if irRoute.DirectResponse != nil || irRoute.Redirect != nil {
continue
}
```

*Repro steps*:
> Include sample requests, environment, etc. All data and inputs
required to reproduce the bug.

>**Note**: If there are privacy concerns, sanitize the data prior to
sharing.

*Environment*:
>Include the environment like gateway version, envoy version and so on.

*Logs*:
>Include the access logs and the Envoy logs.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start in internal/gatewayapi/route.go at the HTTPRoute rule-processing processFilterError block and compare it with the corresponding GRPCRoute block around the referenced line. Done means HTTPRoute processing handles DirectResponse and Redirect consistently with GRPCRoute when filter processing reports an error.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
api
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
84/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.