Why my discourse's syster always block users itself?

(sunshengguang) #1

I have changed the settings , but the system will still automatically block users.
What are causes Banned Users?

System admin actions should include reason
(Felix Freiberger) #2

One reason would be that these users require less then 3 seconds to type their first post, or simply paste their first post. See the site settings min first post typing time and auto block fast typers on first post for details.

(sunshengguang) #3

Thank you for your reply!
I have setted the min first post typing time and auto block fast typers on first post

But system still blocked some user.

(Felix Freiberger) #4

Did these users receive flags?

(sunshengguang) #5

no,they are new user, just write some question.

(cpradio) #6

How is your system hosted? Are you using Cloudflare? Are you behind a nginx proxy? Are you properly passing the user’s IP address into Discourse if any of those are the case? As they might be getting blocked due to sockpuppets

(Helperhaps) #7

mine’s too.

What i know is my user was blocked by system by no reasons. I don’t think this have something to do with what you said about how discourse hosted or somthing.There must be some thick for system to block user. But where to set them.I did not find any in /admin/site_settings, or it is just hard code in the project? if true, can u tell me where it is.

(cpradio) #8

Easiest way to check if it is sockpuppets is to open the Admin > Users section and go through each user to see if they all have the same IP address, if they do, that is likely part of the problem.

If they don’t then chances are the users are posting too quickly while in TL0. Which is based on min first post typing time (shorter time means less likely to catch users)

In fact, it may be wise to search for auto block and check all 3 settings (reset them to defaults if need be).

(Helperhaps) #9

users blocked by system seems to have the same IP address. But where to disable it?

i had set min_first_post_typing_time to 0, auto_block_fast_typers_on_first_post to unchecked, auto_block_fast_typers_max_trust_level to 0, max_new_accounts_per_registration_ip to 0

But as u said, it may be the IP issue. What else can i do to solve it ?

(Felix Freiberger) #10

These questions are super important now, as the next steps depend on the answer.

(Helperhaps) #11

I never use Cloudflare. i know what it is after i googled it just now :joy_cat:

Surely, my discourse is hebind nginx. But i don’t know clearly how many nginxes we are using.

And after looking in the user’s section metioned, these users’ IPs are the same. But i have set max_new_accounts_per_registration_ip to 0 according to the following code

class SpamHandler

  def self.should_prevent_registration_from_ip?(ip_address)
    return false if SiteSetting.max_new_accounts_per_registration_ip <= 0

(Felix Freiberger) #12

You just significantly increased the risk of spam and sockpuppets. Don’t do that!

Instead, you should fix your nginx config – most likely your configuration is missing something like this:

proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;

(Helperhaps) #13

OK, I’ll set max_new_accounts_per_registration_ip to default.

But my ngnix already has that line in ngnix.conf.

(Felix Freiberger) #14

You can try comparing your config to mine to find the error.

(Helperhaps) #15

i don’t think it has somthing to do with my ngnix.
it seems to be a SiteSettings called auto_block_first_post_regex.
Discourse works well when i set that back to blank. :smile:

(Mittineague) #16

What pattern were you trying?

(Helperhaps) #17

I don’t know, It was a very long one. When I saved it as a file