• Forum
  • Doc
  • Screenshots
  • Download
  • Donate
  • Contributors
  • Contact
  • Follow @phpfreechat
  • DEMO
  • Board index ‹ Version 1.x branch ‹ General Support (v1.x)
  • Change font size
  • FAQ
  • Register
  • Login

Kicking a user because of the nickname not showing correctly

Moderators: OldWolf, re*s.t.a.r.s.*2

Post a reply
8 posts • Page 1 of 1

Postby pyro117 » Thu Feb 04, 2010 10:25 pm

I have the latest version of the phpFreeChat and he found a "bug/glitch" in the system. He is one of my admins for the chat, but he found a way to list his nickname on the chat as . but it really is something else. Here is an example of a chat transcript:

15:17:39 ‹.› or ., after your name
04/02/2010 15:17:41 ‹.› not sure
04/02/2010 15:17:42 ‹admin1› hmmm.... if I ever figure out how you are doing it, then I will stop it. I'm not good at finding glitches.
04/02/2010 15:18:07 ‹.› meantime, im going to unblock your name so its kick city!
04/02/2010 15:18:07 ‹.› lol
04/02/2010 15:18:15 ‹.› well actually i am heading home
04/02/2010 15:18:15 ‹.› take care
04/02/2010 15:18:20 * admin2 quit


I changed the usernames to admin1 and admin2. But <.> is actually admin2. It shows on the chat member list as . and in the chat window as . but the actual name he is using is admin2.

Any ideas on how I can stop this behavior?
pyro117
Member
 
Posts: 40
Joined: Wed Jan 14, 2009 7:32 pm
Top

Postby pyro117 » Thu Feb 04, 2010 10:30 pm

Okay I just found out how the user is doing it. I need help in fixing it.

Here is how to reproduce the problem in the demo verison on this site:

1. Connect to the demo site - doesn't matter the username
2. type the following command /connect .
You must use the period . on the keyboard as your new nickname
3. type the following command /nick <new name>
Doesn't seem to matter the name here
4. now type in the chat window. You will be <new name> on the screen but int he chat window all your responses are .
pyro117
Member
 
Posts: 40
Joined: Wed Jan 14, 2009 7:32 pm
Top

Postby pyro117 » Thu Feb 04, 2010 10:59 pm

Let me correct the procedure. I was doing some more testing and I find that all you need to do is the following:

/nick .
/nick <new name>

Your name will show up as . the first time you type out a response. Obviously the nick command is not handling the . (period) character correctly
pyro117
Member
 
Posts: 40
Joined: Wed Jan 14, 2009 7:32 pm
Top

Postby pyro117 » Fri Feb 05, 2010 3:08 pm

Hopefully one last update to this problem. It seems that the following 2 nicknames creates this problem:

.
..

Yes, that is 1 period nickname or 2 periods of a nickname. 3 periods or more do not seem to exhibit this behavior.
pyro117
Member
 
Posts: 40
Joined: Wed Jan 14, 2009 7:32 pm
Top

Postby pyro117 » Mon Feb 08, 2010 2:57 pm

One last note about this bug - you don't have to be an admin to do it. Anybody can do it and then they become un-kickable.

Has anybody looked into this problem?
pyro117
Member
 
Posts: 40
Joined: Wed Jan 14, 2009 7:32 pm
Top

Postby foy » Fri Jul 02, 2010 1:18 am

Hello.
Yes, it es a bug that still continue in version 1.3
I solved this problem and some others problems like strange characters in nick names.
This is my solution:

file nick.class.php
line 21
add this:
$param = phpFreeChat::FilterNickname($param);
before:
if (trim($param) == '')
---------------------------------------------------------
file phpfreechat.class.php
line 144
add this:
$nickname = preg_replace('/[^a-zA-Z0-9 _-:@☺☻♥♦♣♠áéíóúÁÉÍÓÚñÑüÜ]/','-',$nickname);
before:
$nickname = utf8_substr($nickname, 0, $c->max_nick_len);

--------------------------------------------------------------
file: pfcglobalconfig:
line 1161
add this:
$nickname = preg_replace('/[^a-zA-Z0-9 _-:@☺☻♥♦♣♠áéíóúÁÉÍÓÚñÑüÜ]/','-',$nickname);
before:
require_once dirname(__FILE__)."/../lib/utf8/utf8_substr.php";
----------------------------------------------------------------
remember to /rehash the chat or it did not work

enjoy
foy
New member
 
Posts: 6
Joined: Fri Jul 02, 2010 1:04 am
Top

Postby re*s.t.a.r.s.*2 » Fri Jul 02, 2010 3:10 am

Thanks bro , you fixed it... appreciate that
Free Singles Chat Rooms No Registration Required
Text and Chat Singles no need to register or app required
Sala De Bate Papo Online Grátis E Sem Cadastro
re*s.t.a.r.s.*2
Support Team
 
Posts: 612
Joined: Wed Sep 24, 2008 4:04 pm
Location: los angeles CA
  • Website
Top

Postby CodezStar » Tue Mar 01, 2011 10:34 pm

WOWOW!!! thank you so much. YOU FIXED IT!! thanks.
CodezStar
New member
 
Posts: 6
Joined: Tue Mar 01, 2011 3:25 pm
Top


Post a reply
8 posts • Page 1 of 1

Return to General Support (v1.x)

Who is online

Users browsing this forum: No registered users and 5 guests

  • Board index
  • The team • Delete all board cookies • All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
cron
Sign in
Wrong credentials
Sign up I forgot my password
.
jeu-gratuit.net | more partners
Fork me on GitHub