Secondary authentication edit
Forum rules
READ NOW: L2j Forums Rules of Conduct
READ NOW: L2j Forums Rules of Conduct
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Secondary authentication edit
If you want to receive support we need this info to help you properly.
» Find Revision
L2J Revision Number:6086
L2JDP Revision Number:9838
I would like to ask, where are the secondary authentication (in char selection screen) settings, and how to edit them so the user can put any number he wants, cause now it rejects most of combinations with reason they follow patterns.
» Find Revision
L2J Revision Number:6086
L2JDP Revision Number:9838
I would like to ask, where are the secondary authentication (in char selection screen) settings, and how to edit them so the user can put any number he wants, cause now it rejects most of combinations with reason they follow patterns.
-
- L2j Veteran
- Posts: 314
- Joined: Mon Mar 11, 2013 4:19 pm
- UnAfraid
- L2j Veteran
- Posts: 4199
- Joined: Mon Jul 23, 2007 4:25 pm
- Location: Bulgaria
- Contact:
Re: Secondary authentication edit
Ofc u can.
Check this com.l2jserver.gameserver.security.SecondaryPasswordAuth.validatePassword(String)
Check this com.l2jserver.gameserver.security.SecondaryPasswordAuth.validatePassword(String)
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Re: Secondary authentication edit
thanks unafraid will check it tommorow, atm i go sleep:) gn everyone!
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Re: Secondary authentication edit
Hmm, i found it, though im not so sure what to edit.
Anyone can help out on this?
My issue is that this secondary authentication has too high restriction regarding the pattern.
I mean it rejects pins like 1414562 / 654265 etc..
If sm1 can understand it better than me, to tell me what to edit to remove such restriction
thanks in adv
Anyone can help out on this?
My issue is that this secondary authentication has too high restriction regarding the pattern.
I mean it rejects pins like 1414562 / 654265 etc..
If sm1 can understand it better than me, to tell me what to edit to remove such restriction

thanks in adv
-
- L2j Veteran
- Posts: 314
- Joined: Mon Mar 11, 2013 4:19 pm
Re: Secondary authentication edit
As i said there is a client side filter he cant do that but it seems that server checks for more combinations than client does.UnAfraid wrote:Ofc u can.
Check this com.l2jserver.gameserver.security.SecondaryPasswordAuth.validatePassword(String)
You can use this patch it makes server to check only for passwords forbidden by client.cheatax21 wrote:Hmm, i found it, though im not so sure what to edit.
Anyone can help out on this?
My issue is that this secondary authentication has too high restriction regarding the pattern.
I mean it rejects pins like 1414562 / 654265 etc..
If sm1 can understand it better than me, to tell me what to edit to remove such restriction![]()
thanks in adv
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Re: Secondary authentication edit
Thank you Nos, very handy patch, solved my issue. I suggest this patch to be commited, since otherwise, its a pain in the *** to manage to make a PIN pwd.. 

- Zoey76
- L2j Inner Circle
- Posts: 7008
- Joined: Tue Aug 11, 2009 3:36 am
Re: Secondary authentication edit
@Nos I think lenght and characters type should be validated server side, otherwise a bot may send a malformed packet, for example.
Powered by Eclipse 4.34
| Eclipse Temurin 21
| MariaDB 11.3.2
| L2J Server 2.6.3.0 - High Five 
Join our Discord! 

-
- L2j Veteran
- Posts: 314
- Joined: Mon Mar 11, 2013 4:19 pm
Re: Secondary authentication edit
oh... I removed function to test if client filter really works and forgot to add checks after.Zoey76 wrote:@Nos I think lenght and characters type should be validated server side, otherwise a bot may send a malformed packet, for example.
Patch on my post updated now its ok.
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Re: Secondary authentication edit
Could you tell me if what i write is correct, so i wont do smth stupid ;p
old patch
In the new there isnt this part of code, this means i put back that lane again ?
These are the changes yes?
1) i put back the import com.l2jserver.gameserver.util.Util;
2) if (forbiddenPasswords.contains(password))
return false;
old patch
Code: Select all
@@ -34,7 +36,6 @@ import com.l2jserver.gameserver.network.serverpackets.Ex2ndPasswordAck; import com.l2jserver.gameserver.network.serverpackets.Ex2ndPasswordCheck; import com.l2jserver.gameserver.network.serverpackets.Ex2ndPasswordVerify;-import com.l2jserver.gameserver.util.Util; import com.l2jserver.util.Base64;
Code: Select all
- for (int i = 0; i < (password.length() - 1); i++)+ if (forbiddenPasswords.contains(password)) {- char curCh = password.charAt(i);- char nxtCh = password.charAt(i + 1);- - if ((curCh + 1) == nxtCh)- {- return false;- }- else if ((curCh - 1) == nxtCh)- {- return false;- }- else if (curCh == nxtCh)- {- return false;- }+ return false; }
1) i put back the import com.l2jserver.gameserver.util.Util;
2) if (forbiddenPasswords.contains(password))
return false;
-
- L2j Veteran
- Posts: 314
- Joined: Mon Mar 11, 2013 4:19 pm
Re: Secondary authentication edit
You can find the file in Eclipse and right click on it then go Team->Revert this will reset the file to its original state then reapply the patch and you will be done.
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Re: Secondary authentication edit
uh, thank you for this, didnt know it!!
- lucan
- Posts: 590
- Joined: Wed Mar 16, 2011 10:39 pm
- Location: Brazil
Re: Secondary authentication edit
Interesting system but i cant register my code, i get critical errors all times, client system problem?
-
- Posts: 115
- Joined: Thu Aug 14, 2008 10:10 am
Re: Secondary authentication edit
First post here your revs, and what errors you get,
also, maybe it needs h5 part 5 client , im not sure about that friend.
also, maybe it needs h5 part 5 client , im not sure about that friend.
-
- L2j Veteran
- Posts: 314
- Joined: Mon Mar 11, 2013 4:19 pm
Re: Secondary authentication edit
it should work in high five part 1 and 2 client in part 3+ i think its broken.lucan wrote:Interesting system but i cant register my code, i get critical errors all times, client system problem?