import subprocess
with open("pwd.txt","w") as f:#1000-1301是爆破范围
for i in range(1000,1301):
f.write(str(i)+"\n")
g=open("pwd.txt","r")#有其他字典可以放上去
for j in range(300):
pwd=g.readline()
password=pwd.replace("\n","")
command="Decode.exe -X -P %s mp3.mp3"%(password)#这是终端命令,Decode可能根据不同版本的MP3Stego而不同
print(command)
s=subprocess.Popen(command,stdin=subprocess.PIPE,stdout=subprocess.PIPE,stderr=subprocess.PIPE,shell=True)
print(s.communicate()[1].decode("gbk"))
if "unexpected end of cipher message" not in s.communicate()[1].decode("gbk"):
flag=open("mp3.mp3.txt","r")
print(flag.read())
break