XF 1.1 Bannned user get un-banned

Cheesegrits

Active member
Several times since upgrading to 1.1.4 I've had cases where users that I ban, get magically un-banned. I can ban them from the front end with the spam cleaner, or on the back end from the user manager, banning them permanently, then a few days later they pop back up spamming the forums, and I have to ban them again.

I could simply delete the accounts, and in the past I have, but I'm leaving the current problematic account in plac while I try and work out what the heck is going on.

Any ideas? Anyone seen anything like this?

I run a few addons, but nothing that I would think would be remotely capable of un-banning a user.

-- hugh
 
Do you have it set so they can delete their account? Are they deleting their stuff and then reapplying with the same name?

edit: Also, check your admin logs and see if it's giving a reason why. Maybe someone has cracked your password or has access you didn't know about.
 
Nope, it's the same userid.

-- hugh

Sounds stupid, but are you 100% sure you selected a permanent ban?

The funny thing is, this is happening on a community I help on as well (completely different forum system, Lithium to be precise).

Have you checked the admin logs? What do they say?
 
Yup, 100% sure I banned permanently. I've banned this particular user about 6 times, while I try and work out what's going on.

Log entries for the last two show I banned them on Friday evening:

Code:
banning/users/boancemoott.0/save
Generated By: cheesegrits, (xxx.xxx.xxx.xxx), Friday at 10:53 PM
 
array(3) {
  ["username"] => string(11) "Boancemoott"
  ["ban_length"] => string(9) "permanent"
  ["user_reason"] => string(7) "spammer"
}

... and checked the Banned users list to make sure it "took", which it did. Then today (Monday) they popped back up on the forums posting again, and sure enough they were off the banned list, so I banned 'em again today:

Code:
banning/users/boancemoott.0/save
Generated By: cheesegrits  (xxx.xxx.xxx.xxx), Today at 2:37 PM
Request State
array(3) {
  ["username"] => string(11) "Boancemoott"
  ["ban_length"] => string(9) "permanent"
  ["user_reason"] => string(7) "spammer"
}

I kept a note of the userid after the third time this happened, to make sure it wasn't someone deleting and recreating (although I don't allow self deletion of accounts), and it's definitely the same userid.

I've gone through the code in the two anti-spam addons I run, and there is nothing I can find relevant to clearing the banned status. I'm loath to turn those off, but I may do that this week, to see if this happens without them, just so I can rule them out as the problem.

It's not a huge deal, given that it's only affected a very small handful of accounts which I could opt to delete anyway, but it's gotten my Curiosity Gland all fired up, as it would seem to indicate that there is an issue in some code, somewhere, that needs fixing.

-- hugh
 
BTW, does anyone know offhand if deleting posts with the spam cleaner or the standard moderation popup actually decrements that users post count? In other words, is the post count cached somewhere, rather than counting their actual posts?

I run Stop Human Spam, which should prevent anyone from posting with a link until their post count >3. This person managed to squeeze by that first time round, as the way they were formatting their URL's (with bbcode formatting inside the tag) was not being picked up by Stop Human Spam. So they racked up 10 posts before I found and fixed that problem (which Tak has now folded into the code in a new release).

What I was assuming would happen is that when I permanently delete all posts from a user, it would set their post count back to 0, so they couldn't then start posting links again, even if something like this happens and they manage to get un-banned.

But even though I zapped all their posts on Friday, they were able to immediately start posting links again once they got un-banned, which indicates that their post count probably didn't get decremented.

I'm just being lazy, I could go and look at the code to see how the post count is handled, but if anyone can answer that one off the top of their head, it'd save me some time. :)

-- hugh
 
Are you sure none of your staff are unbanning them? ;)

James - positive. In fact, I just got off our group Skype chat, just to make damn sure, and actually it's the opposite, and other staff members have been banning the same account.

We only have 5 folk with moderation privs, and I've gotten replies from everyone.

-- hugh
 
Yup, 100% sure I banned permanently. I've banned this particular user about 6 times, while I try and work out what's going on.

Log entries for the last two show I banned them on Friday evening:

Code:
banning/users/boancemoott.0/save
Generated By: cheesegrits, (xxx.xxx.xxx.xxx), Friday at 10:53 PM
 
array(3) {
  ["username"] => string(11) "Boancemoott"
  ["ban_length"] => string(9) "permanent"
  ["user_reason"] => string(7) "spammer"
}

... and checked the Banned users list to make sure it "took", which it did. Then today (Monday) they popped back up on the forums posting again, and sure enough they were off the banned list, so I banned 'em again today:

Code:
banning/users/boancemoott.0/save
Generated By: cheesegrits  (xxx.xxx.xxx.xxx), Today at 2:37 PM
Request State
array(3) {
  ["username"] => string(11) "Boancemoott"
  ["ban_length"] => string(9) "permanent"
  ["user_reason"] => string(7) "spammer"
}

I kept a note of the userid after the third time this happened, to make sure it wasn't someone deleting and recreating (although I don't allow self deletion of accounts), and it's definitely the same userid.

I've gone through the code in the two anti-spam addons I run, and there is nothing I can find relevant to clearing the banned status. I'm loath to turn those off, but I may do that this week, to see if this happens without them, just so I can rule them out as the problem.

It's not a huge deal, given that it's only affected a very small handful of accounts which I could opt to delete anyway, but it's gotten my Curiosity Gland all fired up, as it would seem to indicate that there is an issue in some code, somewhere, that needs fixing.

-- hugh
You're banning user ID 0, not the actual user.
 
He's baaaaack ...

While we've been talking on this thread, Boancemoott just dropped off the Banned list, and is posting again.

I just had a thought about what may be causing this, going to go follow up on that. More News When There Is News.

-- hugh
 
I have never encountered this issue personally. It looks a very strange one that would need some looking into. Have you considered to start a ticket so one of the staff here can look into this for you?
 
Hmmm, interesting.

I'm using both the spam cleaner, and the back end user manager. So for that log from this morning, I edited his account on the backend and hit the "Ban user ..." button.

I'll go take a look at what's going on there.

-- hugh
If you want me to look into it send me an IM. Maybe be dealing with a bridge issue for you.
 
I'm about 98.73% sure it's not the jFusion bridge, as that was my first thought, although I am debugging that on a local test box just to make sure.

As for the missing useri_id (/foo.0) as the form action on the ban popup ... if someone can sanity check this ... in ./Controller/Admin/Banning.php, ActionUsersAdd(), it initializes $bannedUser['user_id'] with 0, then tests for a valid user_id in $this->_input, and if it's valid, gets and sets the $bannedUser['username'], but NOT the $bannedUser['userid'], which is used in the ban_user_edit template. So that just never gets set.

BUT ... that shouldn't matter, because in actionUsersSave(), if $input['user_id'] is 0, it the attempts to fill in the user_id with a getUserByName($input['username']). So that evens out in the wash, although I think ActionUsersAdd() needs to be fixed so it sets the $bannedUser['user_id'], and save the getusersByname() on submit.

Anyway ... I'm going to do some more debugging on the jFusion bridge code, just to make sure nothing funky is going on there.

-- hugh
 
It does seem like it should be setting the user ID. I'm not sure if it works or not. I've never done it like that. Does spam cleaner attempt to ban the right user? Is there a banned user list in jFusion? Possibly overwriting banned users in xF.
 
OK, well that'll teach me not to go with my gut instinct.

I now have a 98.73% certainty it is the jFusion bridge.

The reason it's not doing it on my local test box is, I forgot to update my live server with some changes I made to the bridge code last week on my test box, when I first started debugging this issue, and added some belt-and-braces code to prevent the bridge from ever touching the banned status.

::hangs head in shame::

Sorry to waste y'all's time!

-- hugh
 
Top Bottom