feat: Enforce remote access restrictions on agent endpoint#3255
feat: Enforce remote access restrictions on agent endpoint#3255mtrezza merged 2 commits intoparse-community:alphafrom
agent endpoint#3255Conversation
|
🚀 Thanks for opening this pull request! We appreciate your effort in improving the project. Please let us know once your pull request is ready for review. Note Please respond to review comments from AI agents just like you would to comments from a human reviewer. Let the reviewer resolve their own comments, unless they have reviewed and accepted your commit, or agreed with your explanation for why the feedback was incorrect. Caution Pull requests must be written using an AI agent with human supervision. Pull requests written entirely by a human will likely be rejected, because of lower code quality, higher review effort and the higher risk of introducing bugs. Please note that AI review comments on this pull request alone do not satisfy this requirement. |
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughIntroduces remote access security controls to the Agent API endpoint by adding an Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant Middleware as Request Middleware
participant LocalCheck as isLocalRequest()
participant RemoteGuard as enforceRemoteAccessRestrictions()
participant Agent as Agent Handler
rect rgba(100, 150, 200, 0.5)
Note over Client,Agent: Local Request Flow
Client->>Middleware: GET /apps/:appId/agent (localhost)
Middleware->>LocalCheck: Check if local request
LocalCheck-->>RemoteGuard: isLocalRequest = true
RemoteGuard-->>Agent: Allow (localhost bypass)
Agent-->>Client: 200 OK
end
rect rgba(200, 100, 100, 0.5)
Note over Client,Agent: Remote Request Flow (No User Config)
Client->>Middleware: GET /apps/:appId/agent (remote IP, HTTP)
Middleware->>LocalCheck: Check if local request
LocalCheck-->>RemoteGuard: isLocalRequest = false
RemoteGuard->>RemoteGuard: Check user configuration
RemoteGuard-->>Client: 401 Unauthorized (missing users)
end
rect rgba(200, 150, 100, 0.5)
Note over Client,Agent: Remote Request Flow (No HTTPS)
Client->>Middleware: GET /apps/:appId/agent (remote IP, HTTP)
Middleware->>LocalCheck: Check if local request
LocalCheck-->>RemoteGuard: isLocalRequest = false
RemoteGuard->>RemoteGuard: Check if HTTPS required
RemoteGuard-->>Client: 403 Forbidden (HTTPS required)
end
Estimated Code Review Effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly Related PRs
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
# [9.1.0-alpha.8](9.1.0-alpha.7...9.1.0-alpha.8) (2026-03-06) ### Features * Enforce remote access restrictions on `agent` endpoint ([#3255](#3255)) ([edef824](edef824))
|
🎉 This change has been released in version 9.1.0-alpha.8 |
Pull Request
Issue
Enforce remote access restrictions on
agentendpoint.Tasks
Summary by CodeRabbit