Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pleroma
pleroma
Commits
c7617941
Commit
c7617941
authored
Dec 23, 2018
by
Karen Konou
Browse files
Renamed the things
parent
c92f91ff
Pipeline
#5643
passed with stages
in 3 minutes and 34 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
config/config.exs
View file @
c7617941
...
...
@@ -163,7 +163,7 @@
allow_followersonly:
false
,
allow_direct:
false
config
:pleroma
,
:mrf_hellthread
mitigation
,
threshold:
10
config
:pleroma
,
:mrf_hellthread
,
threshold:
10
config
:pleroma
,
:mrf_simple
,
media_removal:
[],
...
...
docs/config.md
View file @
c7617941
...
...
@@ -121,7 +121,7 @@ This section is used to configure Pleroma-FE, unless ``:managed_config`` in ``:i
*
`allow_followersonly`
: whether to allow followers-only posts
*
`allow_direct`
: whether to allow direct messages
## :mrf_hellthread
mitigation
## :mrf_hellthread
*
`threshold`
: Number of mentioned users after which the message gets discarded as spam
## :media_proxy
...
...
lib/pleroma/web/activity_pub/mrf/hellthread_policy.ex
View file @
c7617941
...
...
@@ -3,7 +3,7 @@ defmodule Pleroma.Web.ActivityPub.MRF.HellthreadPolicy do
@impl
true
def
filter
(
object
)
do
policy
=
Pleroma
.
Config
.
get
(
:mrf_hellthread
mitigation
)
policy
=
Pleroma
.
Config
.
get
(
:mrf_hellthread
)
if
length
(
object
[
"to"
])
+
length
(
object
[
"cc"
])
>
Keyword
.
get
(
policy
,
:threshold
)
do
{
:reject
,
nil
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment