RocketChat / RocketChat/Rocket.Chat
[bug]: Incoming Webhook 'Avatar URL' field has no validation
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 46.1k
- Forks
- 13.9k
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 130
Description
Summary
This PR adds validation for the avatar_url field in incoming webhook configurations to ensure that only valid URLs are accepted.
Currently, the avatar_url field accepts any string value. This allows invalid inputs such as:
avatar_url: "abc123"
Invalid URLs can lead to UI rendering issues when Rocket.Chat attempts to display the avatar associated with webhook messages.
Impact
- Improves validation for webhook payloads.
- Prevents malformed avatar_url values from affecting UI rendering.
- Maintains backward compatibility for valid configurations.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the incoming webhook configuration validation and the avatar_url field. Verify that malformed values such as "abc123" are rejected while valid URLs remain accepted, then run the relevant validation tests or add coverage if none is mentioned.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100