Closed flamingo-cant-draw closed 7 months ago
This is something I'd like to work on, but I just wanted to get the design OKed
My idea was to:
url_blocklist
or something,process_markdown
function in api_common
to check the body elements of posts and comments,The only thing I'm not sure about is what the API endpoints for retrieving and modifying the blocklist should be.
Yes this sounds good to me. A good place for it in the api would be as part of the existing local_site endpoints. In the database it could be called like local_site_url_blocklist
accordingly.
Checking the full link is going to be easier for the initial implementation, but it would be more flexible to use a regex, or simply a list of blocked domains. But that can be changed after you figure out the initial db and api changes.
Requirements
Is your proposal related to a problem?
There are occasions where Lemmy communities or instances are spammed by bots/people posting the same link over and over again, like around two weeks ago where some Japanese teen was able to spam Lemmy and the wider Fediverse.
Describe the solution you'd like.
Admins should be able to set a blocklist of URLs that Lemmy will check post/comments against and deny creation when there's a match.
Describe alternatives you've considered.
Admins can deploy an automod of some kind to do this. This is what we currently have on feddit.uk, but I think this is something that should be built into Lemmy itself.
Additional context
No response