RocketChat / RocketChat/Rocket.Chat

[bug]: Incoming Webhook 'Avatar URL' field has no validation

Open Beginner friendly
#39,877 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type: bug
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

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. 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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.