mirror of
https://github.com/grp/Wii.py.git
synced 2025-06-18 14:55:35 -04:00
createNAND.py update
This commit is contained in:
parent
9cf91ef298
commit
002c2a6fb1
@ -3,19 +3,12 @@
|
||||
import os, sys, Wii
|
||||
|
||||
def lolcrypt( string ):
|
||||
key = 0x73b5dbfa
|
||||
out = ""
|
||||
#while(*string)
|
||||
key = 0x73B5DBFA
|
||||
out = ''
|
||||
for x in xrange(len(string)):
|
||||
if ord(string[x]) == '\0':
|
||||
continue
|
||||
#*string ^= (key & 0xff)
|
||||
out = out + chr( ord(string[x]) ^ (key & 0xff) )
|
||||
#string += 1
|
||||
#key = ((key<<1) | (key>>31))
|
||||
key = ((key & 0x8fffffff) << 1) | ((key & 0xfffffffe) >> 1)
|
||||
for x in xrange( 0x100 - len(out) ):
|
||||
out = out + '\0'
|
||||
out += chr( ord(string[x]) ^ (key & 0xff) )
|
||||
key = ((key << 1) & 0xffffffff) | ((key >> 31) & 0xffffffff)
|
||||
out += ( '\x00' * ( 0x100 - len(out) ) )
|
||||
return out
|
||||
|
||||
def main():
|
||||
@ -29,17 +22,20 @@ def main():
|
||||
sysV = 417
|
||||
iosV = 6174
|
||||
|
||||
nand.importTitle(Wii.NUS.download(0x0000000100000002, sysV), False)
|
||||
nand.importTitle(Wii.NUS.download(0x000000010000003C, iosV), False)
|
||||
#nand.importTitle(Wii.NUS.download(0x0001000848414C45), False)
|
||||
#nand.importTitle(Wii.NUS.download(0x0001000848414B45), False)
|
||||
settings = "AREA=USA\r\nMODEL=RVL-001(USA)\r\nDVD=0\r\nMPCH=0x7FFE\r\nCODE=LU\r\nSERNO=56866191\r\nVIDEO=NTSC\r\nGAME=US\r\n"
|
||||
nand.importTitle(Wii.NUS.download(0x0000000100000002, sysV), False, True, False)
|
||||
nand.importTitle(Wii.NUS.download(0x000000010000003C, iosV), False, True, False)
|
||||
#nand.importTitle(Wii.NUS.download(0x0001000848414C45), False, False, True, False)
|
||||
#nand.importTitle(Wii.NUS.download(0x0001000848414B45), False, False, True, False)
|
||||
settings = "AREA=USA\r\nMODEL=RVL-001(USA)\r\nDVD=0\r\nMPCH=0x7FFE\r\nCODE=LU\r\n\nSERNO=568661910\r\nVIDEO=NTSC\r\nGAME=US\r\n"
|
||||
#settings = "CODE=LU\r\nAREA=EUR\r\nDVD=0\r\nGAME=EU\r\nVIDEO=PAL\r\nMPCH=0x7FFE\r\nMODEL=RVL-001(EUR)\r\nSERNO=-559038737\r\n"
|
||||
file = open(sys.argv[1] + '/title/00000001/00000002/data/setting.txt', 'wb')
|
||||
file.write(lolcrypt(settings))
|
||||
file.close()
|
||||
print lolcrypt(lolcrypt(settings))
|
||||
#print lolcrypt(lolcrypt(settings))
|
||||
settings_txt = Wii.CONF(sys.argv[1] + '/title/00000001/00000002/data/setting.txt')
|
||||
print settings_txt.getKeysName()
|
||||
#print settings_txt.getKeysName()
|
||||
#for x in settings_txt.getKeysName():
|
||||
# print settings_txt.getKeyValue(x)
|
||||
#nand.add('setting.txt')
|
||||
sys.exit(0)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user