You must config: your server ip, and the files of the client.
You must cript your .py file like base64 if we want to do the ip protection more better..
You must cript your .py file like base64 if we want to do the ip protection more better..
Python script:
PHP Code:
def login_UP(self):
t_serverInfo = serverInfo.TESTADDR["ip"]
if not t_serverInfo == "your server ip":
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupDisplayMessage(text.EN["modify_file"])
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupDisplayMessage(text.DE["modify_file"])
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupDisplayMessage(text.IT["modify_file"])
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupDisplayMessage(text.RO["modify_file"])
net.Disconnect()
return
else:
self.login_Find()
def login_Find(self):
PrincipalyFiles = ['artpclnt.dll','channel.inf','devil.dll','DSETUP.dll','errorlog.exe','ErrorLog.txt','granny2.dll','ijl15.dll','ilu.dll','locale.cfg','metin2.cfg','metin2client.exe','mouse.cfg','mscoree.dll','MSS32.DLL','msvcp60.dll','MSVCRTD.DLL','python22.dll','SpeedTreeRT.dll','syserr.txt','unicows.dll','Thumbs.db','ymir.wmv','gf.wmv','BGM','lib','mark','miles','pack','screenshot','upload']
BGMFiles = ['a_rhapsody_of_war.mp3','another_way.mp3','back_to_back.mp3','blacksea.mp3','catacomb_of_devil.mp3','characterselect.mp3','death_of_landmark.mp3','desert.mp3','enter_the_east.mp3','follow_war_god.mp3','last-war2.mp3','login_window.mp3','lost_my_name.mp3','m2bg.mp3','misty_forest.mp3','monkey_temple.mp3','mountain_of_death.mp3','mt.mp3','Only_my_battle.mp3','open_the_gate.mp3','save_me.mp3','wedding.mp3','wonderland.mp3','xmas.mp3']
LibFiles = ['__future__.pyc','copy_reg.pyc','linecache.pyc','ntpath.pyc','os.pyc','site.pyc','stat.pyc','string.pyc','traceback.pyc','types.pyc','UserDict.pyc']
MilesFiles = ['mss32.dll','mssa3d.m3d','mssds3d.m3d','mssdsp.flt','mssdx7.m3d','msseax.m3d','mssmp3.asi','mssrsx.m3d','msssoft.m3d','mssvoice.asi']
PackFiles = ['BGM.eix','BGM.epk','Effect.eix','Effect.epk','ETC.eix','ETC.epk','guild.eix','guild.epk','icon.eix','icon.epk','Index','indoordeviltower1.eix','indoordeviltower1.epk','indoormonkeydungeon1.eix','indoormonkeydungeon1.epk','indoormonkeydungeon2.eix','indoormonkeydungeon2.epk','indoormonkeydungeon3.eix','indoormonkeydungeon3.epk','indoorspiderdungeon1.eix','indoorspiderdungeon1.epk','item.eix','item.epk','locale_ro.eix','locale_ro.epk','monster2.eix','monster2.epk','Monster.eix','Monster.epk','npc2.eix','npc2.epk','NPC.eix','NPC.epk','Outdoor.eix','Outdoor.epk','OutdoorA1.eix','OutdoorA1.epk','OutdoorA2.eix','OutdoorA2.epk','OutdoorA3.eix','OutdoorA3.epk','OutdoorB1.eix','OutdoorB1.epk','OutdoorB3.eix','OutdoorB3.epk','OutdoorC1.eix','OutdoorC1.epk','OutdoorC3.eix','OutdoorC3.epk','outdoordesert1.eix','outdoordesert1.epk','outdoorduel.eix','outdoorduel.epk','outdoorempirebattle1.eix','outdoorempirebattle1.epk','outdoorfielddungeon1.eix','outdoorfielddungeon1.epk','outdoorflame1.eix','outdoorflame1.epk','outdoorgmguildbuild.eix','outdoorgmguildbuild.epk','outdoorguild1.eix','outdoorguild1.epk','outdoorguild2.eix','outdoorguild2.epk','outdoorguild3.eix','outdoorguild3.epk','outdoormilgyo1.eix','outdoormilgyo1.epk','OutdoorSnow1.eix','OutdoorSnow1.epk','outdoort1.eix','outdoort1.epk','outdoort2.eix','outdoort2.epk','outdoort3.eix','outdoort3.epk','outdoort4.eix','outdoort4.epk','outdoortrent02.eix','outdoortrent02.epk','outdoortrent.eix','outdoortrent.epk','outdoorwedding.eix','outdoorwedding.epk','pc2.eix','pc2.epk','PC.eix','PC.epk','Property.eix','Property.epk','Psyco.eix','Psyco.epk','root.eix','root.epk','season1.eix','season1.epk','season2.eix','season2.epk','season3_eu.eix','season3_eu.epk','sound2.eix','sound2.epk','Sound.eix','Sound.epk','Terrain.eix','Terrain.epk','textureset.eix','textureset.epk','Tree.eix','Tree.epk','uiloading.eix','uiloading.epk','uiscript.eix','uiscript.epk','Zone.eix','Zone.epk']
path = os.getcwd()
principaly = os.listdir(path)
bgm = os.listdir('BGM')
lib = os.listdir('lib')
miles = os.listdir('miles')
pack = os.listdir('pack')
if principaly != PrincipalyFiles:
for item in principaly:
if not item in PrincipalyFiles:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["corrupted_file"] + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["corrupted_file"] + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["corrupted_file"] + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["corrupted_file"] + str(item) + " .")
net.Disconnect()
return
else:
pass
if PrincipalyFiles != principaly:
for missing in PrincipalyFiles:
if not missing in principaly:
if str(missing) == "Thumbs.db":
pass
else:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["missing_file"] + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["missing_file"] + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["missing_file"] + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["missing_file"] + str(missing) + " .")
net.Disconnect()
return
else:
pass
if bgm != BGMFiles:
for item in bgm:
if not item in BGMFiles:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["corrupted_file"] + "../BGM/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["corrupted_file"] + "../BGM/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["corrupted_file"] + "../BGM/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["corrupted_file"] + "../BGM/" + str(item) + " .")
net.Disconnect()
return
else:
pass
if BGMFiles != bgm:
for missing in BGMFiles:
if not missing in bgm:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["missing_file"] + "../BGM/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["missing_file"] + "../BGM/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["missing_file"] + "../BGM/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["missing_file"] + "../BGM/" + str(missing) + " .")
net.Disconnect()
return
else:
pass
if lib != LibFiles:
for item in lib:
if not item in LibFiles:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["corrupted_file"] + "../lib/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["corrupted_file"] + "../lib/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["corrupted_file"] + "../lib/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["corrupted_file"] + "../lib/" + str(item) + " .")
net.Disconnect()
return
else:
pass
if LibFiles != lib:
for missing in LibFiles:
if not missing in lib:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["missing_file"] + "../lib/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["missing_file"] + "../lib/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["missing_file"] + "../lib/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["missing_file"] + "../lib/" + str(missing) + " .")
net.Disconnect()
return
else:
pass
if miles != MilesFiles:
for item in miles:
if not item in MilesFiles:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["corrupted_file"] + "../miles/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["corrupted_file"] + "../miles/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["corrupted_file"] + "../miles/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["corrupted_file"] + "../miles/" + str(item) + " .")
net.Disconnect()
return
else:
pass
if MilesFiles != miles:
for missing in MilesFiles:
if not missing in miles:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["missing_file"] + "../miles/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["missing_file"] + "../miles/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["missing_file"] + "../miles/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["missing_file"] + "../miles/" + str(missing) + " .")
net.Disconnect()
return
else:
pass
if pack != PackFiles:
for item in pack:
if not item in PackFiles:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["corrupted_file"] + "../pack/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["corrupted_file"] + "../pack/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["corrupted_file"] + "../pack/" + str(item) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["corrupted_file"] + "../pack/" + str(item) + " .")
net.Disconnect()
return
else:
pass
if PackFiles != pack:
for missing in PackFiles:
if not missing in pack:
snd.PlaySound("sound/ui/loginfail.wav")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/en"):
self.PopupNotifyMessage(text.EN["missing_file"] + "../pack/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/it"):
self.PopupNotifyMessage(text.IT["missing_file"] + "../pack/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/de"):
self.PopupNotifyMessage(text.DE["missing_file"] + "../pack/" + str(missing) + " .")
if (locale.IsEUROPE() and app.GetLocalePath() == "locale/ro"):
self.PopupNotifyMessage(text.RO["missing_file"] + "../pack/" + str(missing) + " .")
net.Disconnect()
return
else:
pass
if not IsLoginDelay():
snd.PlaySound("sound/ui/loginok.wav")
self.PopupDisplayMessage(locale.LOGIN_CONNECT_SUCCESS)
PHP Code:
Open your introLogin.py, and find:
def OnHandShake(self):
now cancel that and the option of this self and replace it:
def OnHandShake(self):
self.login_UP()
you must add:
import os on line 1.
now copy the php of python script and reply on your introLogin.
PHP Code:
EN = {"modify_file" : "Some files have been modified.", "corrupted_file" : "Corrupted file: ","missing_file" : "Missing file: "}
IT = {"modify_file" : "Alcuni file sono stati modificati.", "corrupted_file" : "File danneggiato: ","missing_file" : "File mancante: "}
DE = {"modify_file" : "Einige dateien geändert wurden.", "corrupted_file" : "Beschädigte datei: ","missing_file" : "Fehlende datei: "}
RO = {"modify_file" : "Unele fiºiere au fost modificate.", "corrupted_file" : "Fiºier corupt: ","missing_file" : "Lipseºte fiºierul: "}
PHP Code:
Create a new file and named it text.py, now copy and paste the php code into your new file. (you must use ANSI character) after you finish put text.py on your root file.
PHP Code:
At the moment i work at a new check more better like this:
import md5
m01 = md5.md5(read.yourfile).hexdigest()
if not m01 = "right hexdigest":
file = open("syserr.txt", "w")
file.write("Corupted file")
net.Disconnect()
else
pass






