Reverted the "The md5() of their kafra code is now stored in #kafra_code$" change from r13728.
Added md5calc to vs8/vs7/vs6 project files. Applied svn:eol-style to the new sql upgrade file. Note that if you already applied the sql upgrade, your kafra passwords are lost. Also note that txt users will still have to implement their own migration code into the kafra scripts since it was omitted in the previous commits. git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@13729 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
53998c9f3d
commit
bae7ecf012
@ -1,7 +1,6 @@
|
|||||||
Date Added
|
Date Added
|
||||||
======
|
======
|
||||||
2009/05/04
|
2009/05/04
|
||||||
- The md5 checksum of the kafra code is now stored in #kafra_code$ [brianluau]
|
|
||||||
- Added a missing zeny check in the Jawaii Bartender. (bugreport:2897) [brianluau]
|
- Added a missing zeny check in the Jawaii Bartender. (bugreport:2897) [brianluau]
|
||||||
- Added a missing 'close' in the Mage quest Bookshelf. (bugreport:2873)
|
- Added a missing 'close' in the Mage quest Bookshelf. (bugreport:2873)
|
||||||
2009/05/03
|
2009/05/03
|
||||||
|
@ -71,7 +71,6 @@
|
|||||||
// - Special warpname menu option name bug fixed
|
// - Special warpname menu option name bug fixed
|
||||||
//-2.1 Updated names to fall within retrictions. [L0ne_W0lf]
|
//-2.1 Updated names to fall within retrictions. [L0ne_W0lf]
|
||||||
//-2.2 #kafra_code is now stored as is. [brianluau]
|
//-2.2 #kafra_code is now stored as is. [brianluau]
|
||||||
//-2.2b The md5() of their kafra code is now stored in #kafra_code$ [brianluau]
|
|
||||||
//=================================================================
|
//=================================================================
|
||||||
|
|
||||||
//========================Function=&=Script========================
|
//========================Function=&=Script========================
|
||||||
@ -598,11 +597,11 @@ L_Storage:
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
F_CheckKafCode:
|
F_CheckKafCode:
|
||||||
if(#kafra_code$=="") return;
|
if(#kafra_code==0) return;
|
||||||
mes "Enter your storage password:";
|
mes "Enter your storage password:";
|
||||||
set @code_,0;
|
set @code_,0;
|
||||||
input @code_;
|
input @code_;
|
||||||
if(md5(@code_) != #kafra_code$) {
|
if(@code_ != #kafra_code) {
|
||||||
dispbottom "Wrong storage password.";
|
dispbottom "Wrong storage password.";
|
||||||
close;
|
close;
|
||||||
}
|
}
|
||||||
|
@ -58,7 +58,6 @@
|
|||||||
//= 6.1 Added menu for Turbo Track Kafra Staff. [L0ne_W0lf]
|
//= 6.1 Added menu for Turbo Track Kafra Staff. [L0ne_W0lf]
|
||||||
//= 6.2 Updated/Fixed warp cords. [Kisuka]
|
//= 6.2 Updated/Fixed warp cords. [Kisuka]
|
||||||
//= 6.3 #kafra_code is now stored as is. [brianluau]
|
//= 6.3 #kafra_code is now stored as is. [brianluau]
|
||||||
//= 6.3b The md5() of their kafra code is now stored in #kafra_code$ [brianluau]
|
|
||||||
//============================================================
|
//============================================================
|
||||||
|
|
||||||
|
|
||||||
@ -558,11 +557,11 @@ function script F_KafEnd {
|
|||||||
|
|
||||||
// Check Storage Password Function ====================
|
// Check Storage Password Function ====================
|
||||||
function script F_CheckKafCode {
|
function script F_CheckKafCode {
|
||||||
if(#kafra_code$=="") return;
|
if(#kafra_code==0) return;
|
||||||
mes "Enter your storage password:";
|
mes "Enter your storage password:";
|
||||||
set @code_,0;
|
set @code_,0;
|
||||||
input @code_;
|
input @code_;
|
||||||
if(md5(@code_) != #kafra_code$) {
|
if(@code_ != #kafra_code) {
|
||||||
dispbottom "Wrong storage password.";
|
dispbottom "Wrong storage password.";
|
||||||
close2;
|
close2;
|
||||||
cutin "",255;
|
cutin "",255;
|
||||||
@ -577,7 +576,7 @@ function script F_CheckKafCode {
|
|||||||
// getarg(0) = NPC Name, getarg(1) = Company Name
|
// getarg(0) = NPC Name, getarg(1) = Company Name
|
||||||
function script F_SetKafCode {
|
function script F_SetKafCode {
|
||||||
mes getarg(0);
|
mes getarg(0);
|
||||||
if(#kafra_code$) {
|
if(#kafra_code) {
|
||||||
mes "Your storage is protected with a password. What would you do now?";
|
mes "Your storage is protected with a password. What would you do now?";
|
||||||
next;
|
next;
|
||||||
menu "Change old password -> 5000z",-,
|
menu "Change old password -> 5000z",-,
|
||||||
@ -594,7 +593,7 @@ function script F_SetKafCode {
|
|||||||
mes getarg(0);
|
mes getarg(0);
|
||||||
mes "At first, please enter your ^0000FFold password^000000.";
|
mes "At first, please enter your ^0000FFold password^000000.";
|
||||||
set @code,callfunc("F_EntKafCode");
|
set @code,callfunc("F_EntKafCode");
|
||||||
if(@code==0 || md5(@code) != #kafra_code$) {
|
if(@code==0 || @code != #kafra_code) {
|
||||||
mes "Wrong password. You can't set a new password.";
|
mes "Wrong password. You can't set a new password.";
|
||||||
emotion e_hmm;
|
emotion e_hmm;
|
||||||
goto M_END;
|
goto M_END;
|
||||||
@ -616,7 +615,7 @@ M_SET:
|
|||||||
set Zeny,Zeny-5000;
|
set Zeny,Zeny-5000;
|
||||||
//set RESRVPTS, RESRVPTS + (5000/50); //hardcoded password doesn't add pts
|
//set RESRVPTS, RESRVPTS + (5000/50); //hardcoded password doesn't add pts
|
||||||
|
|
||||||
set #kafra_code$,md5(@code);
|
set #kafra_code,@code;
|
||||||
mes "You've protected your storage with a secret password.";
|
mes "You've protected your storage with a secret password.";
|
||||||
mes "Thank you for using "+getarg(1)+".";
|
mes "Thank you for using "+getarg(1)+".";
|
||||||
emotion e_thx;
|
emotion e_thx;
|
||||||
@ -636,8 +635,8 @@ M_CLEAR:
|
|||||||
if(Zeny < 1000) goto L_ZENY;
|
if(Zeny < 1000) goto L_ZENY;
|
||||||
set Zeny,Zeny-1000;
|
set Zeny,Zeny-1000;
|
||||||
//set RESRVPTS, RESRVPTS + (1000/50); //hardcoded password doesn't add pts
|
//set RESRVPTS, RESRVPTS + (1000/50); //hardcoded password doesn't add pts
|
||||||
if(md5(@code) == #kafra_code$) {
|
if(@code == #kafra_code) {
|
||||||
set #kafra_code$,"";
|
set #kafra_code,0;
|
||||||
mes "You've successfully cleared your storage password.";
|
mes "You've successfully cleared your storage password.";
|
||||||
mes "Thank you for using "+getarg(1)+".";
|
mes "Thank you for using "+getarg(1)+".";
|
||||||
emotion e_thx;
|
emotion e_thx;
|
||||||
|
@ -1 +0,0 @@
|
|||||||
UPDATE `global_reg_value` SET `str`='#kafra_code$',`value`=MD5(`value`) WHERE `str` = '#kafra_code';
|
|
@ -107,6 +107,14 @@ SOURCE=..\src\common\malloc.h
|
|||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=..\src\common\md5calc.c
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=..\src\common\md5calc.h
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=..\src\common\mapindex.c
|
SOURCE=..\src\common\mapindex.c
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
@ -107,6 +107,14 @@ SOURCE=..\src\common\malloc.h
|
|||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=..\src\common\md5calc.c
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
|
SOURCE=..\src\common\md5calc.h
|
||||||
|
# End Source File
|
||||||
|
# Begin Source File
|
||||||
|
|
||||||
SOURCE=..\src\common\mapindex.c
|
SOURCE=..\src\common\mapindex.c
|
||||||
# End Source File
|
# End Source File
|
||||||
# Begin Source File
|
# Begin Source File
|
||||||
|
@ -374,6 +374,12 @@
|
|||||||
<File
|
<File
|
||||||
RelativePath="..\src\common\malloc.h">
|
RelativePath="..\src\common\malloc.h">
|
||||||
</File>
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.c">
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.h">
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\src\common\mapindex.c">
|
RelativePath="..\src\common\mapindex.c">
|
||||||
</File>
|
</File>
|
||||||
|
@ -374,6 +374,12 @@
|
|||||||
<File
|
<File
|
||||||
RelativePath="..\src\common\malloc.h">
|
RelativePath="..\src\common\malloc.h">
|
||||||
</File>
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.c">
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.h">
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\src\common\mapindex.c">
|
RelativePath="..\src\common\mapindex.c">
|
||||||
</File>
|
</File>
|
||||||
|
@ -255,6 +255,14 @@
|
|||||||
RelativePath="..\src\common\malloc.h"
|
RelativePath="..\src\common\malloc.h"
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.c"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\src\common\mapindex.c"
|
RelativePath="..\src\common\mapindex.c"
|
||||||
>
|
>
|
||||||
|
@ -502,6 +502,14 @@
|
|||||||
RelativePath="..\src\common\malloc.h"
|
RelativePath="..\src\common\malloc.h"
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.c"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\src\common\md5calc.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\src\common\mapindex.c"
|
RelativePath="..\src\common\mapindex.c"
|
||||||
>
|
>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user