spacebarchat / spacebarchat/server

Embed Links and Attach File Permissions Not Functional

Open
#1,595 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
2.2k
Forks
323
Avg merge
14h 48m
Merged PRs (30d)
4

Description

Describe the bug
Denying the permissions Embed Links and Attach Files do not correctly prevent these actions. Regardless of if a channel specifically denies the permissions, or a role has the permission denied entirely, users can always embed links and attach files. Permissions are being reported together since they both must function to control a user's ability to post images.

To Reproduce
Steps to reproduce the behavior:

  1. Create a channel.
  2. Deny the permissions Embed Links and Attach Files in any way (by user, by role, or by channel)
  3. Post a link.
  4. Attach a file.

Expected behavior
Users who can not embed links should not be have links embed.
Users who can not attach files should not have their files attached.

Env and Software info
Encountered on the live instance of spacebar.chat

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 reproducing the issue on the live instance or a local setup using the listed channel, role, and user permission cases. Trace the permission checks used when posting links and attaching files. Done means denying Embed Links prevents link embedding and denying Attach Files prevents file attachments in each described scenario.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
authorization, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.