add FastEdge app ID to outbound requests for backend correlation#152
Open
ruslanti wants to merge 2 commits into
Open
add FastEdge app ID to outbound requests for backend correlation#152ruslanti wants to merge 2 commits into
ruslanti wants to merge 2 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a FastEdge application identifier to outbound backend requests (for correlation) and strengthens protections around internal FastEdge routing headers by reserving the fastedge-* / fastedge_* prefix and rejecting direct backend-host access.
Changes:
- Thread
app_idthrough HTTP/WASI executors into the backend request pipeline and inject it asfastedge-app-id. - Block/strip all
fastedge-*/fastedge_*headers originating from guest modules. - Reject outbound requests that attempt direct access to the configured backend host.
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/context.rs | Passes app_id into executor constructors so it can be used during outbound requests. |
| crates/runtime/src/lib.rs | Forbids guest-set headers with reserved fastedge-* / fastedge_* prefix in WASI HTTP. |
| crates/http-service/src/state.rs | Filters outbound headers and injects fastedge-app-id; adds tests for new behavior. |
| crates/http-service/src/executor/wasi_http.rs | Persists app_id into the backend instance used by the WASI executor. |
| crates/http-service/src/executor/http.rs | Persists app_id into the backend instance used by the native HTTP executor. |
| crates/http-backend/src/lib.rs | Adds app_id storage/injection, reserved-prefix stripping, and backend-host rejection helpers + tests. |
| Cargo.lock | Dependency lockfile updates. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.