2019-05-10 19:14:57来源:本站作者:maro
目前刚换了黑苹果系统, 之前在 win上面远程工具一直用的teamviewer,换 ID 也比较方便,一键换 ID
Mac 系统没那么方便,而且要天天换 ID, 不过总能比不能用强.如果你发现更好用的方法,请回复交流
源代码和文件放到最后
1) 本人实测 TV13, 另外 死杰马克丁版本用不了一定要用官方的
2) 死杰马克丁法务全家 男性 jjboom
始教程:
1.打开 Mac终端
2.输入 命令sudo su 点回车 然后输入 Mac 的开机密码 继续点回车
3.输入 python 空格(别忘了空格),然后 直接把 py 文件拖到终端里面(或者输入文件所在路径)点回车
4.连续按回车,什么意思?不用管 直接回车,然后关掉你的 tv 重新打开
[Asm] #!/usr/bin/env python #coding:utf-8import sysimport osimport globimport platformimport reimport randomimport stringprint('''--------------------------------TeamViewer ID Changer for MAC OS--------------------------------''')if platform.system() != 'Darwin': print('This script can be run only on MAC OS.') sys.exit();if os.geteuid() != 0: print('This script must be run form root.') sys.exit();if os.environ.has_key('SUDO_USER'): USERNAME = os.environ['SUDO_USER'] if USERNAME == 'root': print('Can not find user name. Run this script via sudo from regular user') sys.exit();else: print('Can not find user name. Run this script via sudo from regular user') sys.exit();HOMEDIRLIB = '/Users/' + USERNAME+ '/library/preferences/'GLOBALLIB='/library/preferences/'CONFIGS = []# Find config filesdef listdir_fullpath(d): return [os.path.join(d, f) for f in os.listdir(d)]for file in listdir_fullpath(HOMEDIRLIB): if 'teamviewer'.lower() in file.lower(): CONFIGS.append(file)if not CONFIGS: print ('''There is no TemViewer configs found.Maybe you have deleted it manualy or never run TeamViewer after installation.Nothing to delete.''')# Delete config fileselse: print("Configs found:n") for file in CONFIGS: print file print('''This files will be DELETED permanently.All TeamViewer settings will be lost''') raw_input("Press Enter to continue or CTR+C to abort...") for file in CONFIGS: try: os.remove(file) except: print("Cannot delete config files. Permission denied?") sys.exit(); print("Done.")# Find binaryesTMBINARYES = ['/Applications/TeamViewer.app/Contents/MacOS/TeamViewer','/Applications/TeamViewer.app/Contents/MacOS/TeamViewer_Service','/Applications/TeamViewer.app/Contents/Helpers/TeamViewer_Desktop',]for file in TMBINARYES: if os.path.exists(file): pass else: print("File not found: " + file) print ("Install TeamViewer correctly") sys.exit();# Patch filesdef idpatch(fpath,platf,serial): file = open(fpath, 'r+b') binary = file.read() PlatformPattern = "IOPlatformExpert.{6}" SerialPattern ="IOPlatformSerialNumber%s%s%sUUID" binary = re.sub(PlatformPattern, platf, binary) binary = re.sub(SerialPattern % (chr(0), "[0-9a-zA-Z]{8,8}", chr(0)), SerialPattern%(chr(0), serial, chr(0)), binary) file = open(fpath,'wb').write(binary) return Truedef random_generator(size=8, chars=string.ascii_uppercase + string.digits): return ''.join(random.choice(chars) for _ in range(size))RANDOMSERIAL = random_generator()RANDOMPLATFORM = "IOPlatformExpert" + random_generator(6)for file in TMBINARYES: try: idpatch(file,RANDOMPLATFORM,RANDOMSERIAL) except: print "Error: can not patch file " + file print "Wrong version?" sys.exit();print "PlatformDevice: " + RANDOMPLATFORMprint "PlatformSerial: " + RANDOMSERIALprint('''ID changed sucessfully.!!! Restart computer before using TeamViewer !!!!''')
热门下载榜人气排行榜
辐射岛中文版
类型:休闲益智
大小:26.62MB
祖宗保佑最新版
类型:模拟塔防
大小:59.86MB
魔兽之旅
类型:角色扮演
大小:117.78MB
箭之岛屿汉化版
类型:战争策略
大小:62.01MB
pubg绝地求生国际服最新版
类型:枪战射击
大小:1.13GB
nba2k23手游安卓直装版
类型:体育竞技
大小:
怪物火车手机版
类型:卡牌对战
大小:
派对世界中文版
类型:模拟塔防
大小:38.11MB
辐射岛联机版
类型:休闲益智
大小:18.08MB
2048大招版
类型:休闲益智
大小:49.83MB
专题推荐更多>>