Restrict available RPC methods for `snap.request()` by means of an allowlist
Open
area-capabilities
type-security
- Dominant language
- TypeScript
- Stars
- 853
- Forks
- 662
- Avg merge
- 2d 8h
- Merged PRs (30d)
- 8
Description
Currently, we restrict the RPC methods available to `snap.request()` by means of a blocklist. We should consider replacing this with an allowlist explicitly listing each permitted method. In this way, we will never fail to prevent an RPC method from being allowed through the snap RPC provider.
Contributor guide
Research direction
Locate the snap.request() RPC provider and the current blocklist implementation. Review how permitted RPC methods are determined, then define the allowlist scope and verify that unlisted methods cannot pass through the provider. The issue does not name specific files or tests, so repository exploration and security-domain context are needed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, security
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100