[#158] Settings → Restrict custom provider to local development - #161
Conversation
|
@greptileai Review PR |
|
@MFA-G Can you address the comment and 3/5 confidence please? |
|
@MFA-G Do you need any help with this PR? |
endpointFor interpolates the persisted region straight into the URL authority for the s3 provider, so a region containing authority delimiters (x@attacker.example:443#) redirects signed connection and sync requests, vault data included, to an unintended host. Validate the region as an AWS region identifier: endpointFor returns "" for anything else, hasConnectionConfig treats it as incomplete, and testConnection reports it as a missing region with an example.
|
Sorry for the delay @revett — no help needed, addressed now in 2e77bf7. Greptile P1 (region can redirect S3 requests): valid. The fix validates the region as an AWS region identifier before it can reach a URL:
r2 is untouched (it signs with Added 16 test cases including the exact |
|
@MFA-G Great! Thanks for the update 🙏 Could you resolve the conflicts? |
Resolves conflicts in settings.ts, tab.ts, settings.test.ts and storage.ts against the prefix (8thpark#154) and endpoint-normalization (8thpark#79) work on main. All conflicting hunks were additive on both sides, so both are kept.
|
Conflicts resolved in 97abfc5 (merged The overlap was with the prefix work (#154) and the endpoint normalization (#79) that landed while this was open. Every conflicting hunk was additive on both sides, so both sides are kept:
One thing worth flagging: main's
|
|
@greptileai Review PR |
Resolves #158
Problem
Changes
NODE_ENVValidation
npm run lintnpm run buildnpm test(198 passed)npm run check-versionsnpm run auditgit diff --checkIntegration tests were not run locally because Docker is not installed in this environment.
Greptile Summary
Adds Amazon S3 as a persisted storage provider while restricting the custom S3-compatible provider to development builds.
Confidence Score: 5/5
The PR appears safe to merge.
No blocking failure remains; the S3 endpoint is now produced only when the persisted region passes a restrictive alphabet-and-shape check that excludes URL authority and path delimiters.
Important Files Changed
Reviews (2): Last reviewed commit: "Update docs" | Re-trigger Greptile
Context used: