Double Account
#1

Hello !

I use a CLANSYSTEM, so the members can use a clan TAG to make abuse.

For example, if i have name ' Clain ' and the tag of the clan is [PRO], my name will be [PRO]Claim ( if i set the tag ). The problem is that an account could be logged twice ( once with Clain -> set tag -> [PRO]Clain. And then, I can be logged again with Clain without tag. ) Then, I can make abuse with /trasfer or /pay to me and to double my money.
How can I stop it?
I use playerStatus = 1; when a player is logged and check if his status is on 0 when he's connecting but it doesn't work always.

There is an option to verify the name of the both of players before /transfer of pay?


For example
Код HTML:
if(name1 == name 2)
{
   return 1;
}
Thanks a lot.
Reply
#2

Would suggest not to use prefixes in the username. Just make 3d text labels above player names.
Reply
#3

I want something to do with it, i don't want to change it.
Reply
#4

Quote:
Originally Posted by Nin9r
Посмотреть сообщение
I want something to do with it, i don't want to change it.
Lets say a player uses almost nearly 24 characters for his username in some server. Someday he notices your server and he decides to register with the same name. But then he realizes that he can't write his whole username also having his tag together (24+ and sa-mp only allows 24 characters for a username). Now that is some inconvenience.

What you could do is make username and tag separate things. You could make in your database two separate rows - for the players username and for the tag. And you could display the tag in the server by creating a 3d text label. And you wouldn't have any problems with the payment, because the username would not contain any tags.
Reply
#5

This seems poorly coded to me if this is at all able to happen. I have no idea how you've made it so it's hard to give perfect advice, but the person above stated some very good points. What you're doing is simply a poor way of doing it and rather than looking for fixes to it you should make your clan tags appear another way.

Anyhow, assuming that your current way wasn't working correctly and that every player is saved in a database, you could always loop through online players when logging in to see if someone online has the same database user id. You could then just kick them. On phone, sorry if it's poorly written.
Reply
#6

You misunderstand. Our players doesn't registered twice, they are logged twice.
One time i will be logged with Clain. When i will be logged my name will be changed automatically in [PRO]Claim because he used /tag to activate the clan tag. Second time, i will be logged again with Claim and this name will be remain like this.

So, there are connected Clain / [PRO]Clain ( actually, it is the same account ). Then, one of them could /transfer or /pay to another one. After /q, the money will be double in account.
Reply
#7

Alright, so when logging them in and a user Id is fetched can you not simply loop through online players and make sure no player is online with that user id?
Reply
#8

Quote:
Originally Posted by Nin9r
Посмотреть сообщение
You misunderstand. Our players doesn't registered twice, they are logged twice.
One time i will be logged with Clain. When i will be logged my name will be changed automatically in [PRO]Claim because he used /tag to activate the clan tag. Second time, i will be logged again with Claim and this name will be remain like this.

So, there are connected Clain / [PRO]Clain ( actually, it is the same account ). Then, one of them could /transfer or /pay to another one. After /q, the money will be double in account.
Try to explain better. And tell everything step-by-step. Because I don't even know how, where and what you are logging.
Reply
#9

My username is Clain, ok ?

I have a clan system with clanTAG [PRO]. If I use /tag, i will set to my name [PRO] + Clain = [PRO]Clain. It will remain saved on relog, i use if(pTag] == 1 => SetPlayerName TAG+USER.

I will be logged, so my username will be [PRO]Clain. Then, i can log again with name Clain and i can make transfers between a single account.
Reply
#10

I use UPDATE playerStatus when a player is logged. Also, on login I pStatus gets the value of playerStatus from database. After, I will check if a player is logged with pStatus] >= 1 and he is kicked. But sometimes / somehow playerStatus is not saved or a hacker can pass through. This is why I need to check on /transfer command if USER1 = USER2 and deny to make the transfer.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)