Skip to content

Latest commit

聽

History

History
68 lines (56 loc) 路 2.21 KB

File metadata and controls

68 lines (56 loc) 路 2.21 KB

Marshal-Decompile

饾構饾槮饾槫饾槹饾槷饾槺饾槳饾槶饾槮 饾槩饾槸饾樅 饾槺饾樅饾樀饾槱饾槹饾槸 饾槾饾槫饾槼饾槳饾槺饾樀 饾槾饾樀饾槩饾槼饾樀饾槳饾槸饾槰 饾樃饾槳饾樀饾槱 饾槮饾樄饾槮饾槫(饾槷饾槩饾槼饾槾饾槱饾槩饾槶.饾槶饾槹饾槩饾槬饾槾(... 饾樃饾槹饾槼饾槵饾槾 饾樃饾槳饾樀饾槱 饾槜饾樅饾樀饾槱饾槹饾槸 2.饾槦 饾樀饾槹 3.9 饾樁饾槾饾槳饾槸饾槰 饾樁饾槸饾槫饾槹饾槷饾槺饾樅饾槶饾槮6 (饾槜饾樅饾樀饾槱饾槹饾槸 < 3.7) 饾槩饾槸饾槬 饾槬饾槮饾槫饾槹饾槷饾槺饾樅饾槶饾槮3 (饾槜饾樅饾樀饾槱饾槹饾槸 >= 3.7) Typing SVG

Installation

pip install uncompyle6
pip install decompyle3

Usage

饾槰饾槳饾樂饾槮饾槸 饾槩 饾槯饾槳饾槶饾槮 饾槸饾槩饾槷饾槮饾槬 "饾槷饾槩饾槼饾槾饾槱饾槩饾槶饾槮饾槬饾槏饾槳饾槶饾槮.饾槺饾樅" 饾槶饾槳饾槵饾槮

#!/usr/bin/env python
import marshal
exec(marshal.loads('c\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00@\x00\x00\x00s\x90\x00\x00\x00d...

饾槫饾槩饾槶饾槶

python2 marshaledFile.py 27

饾槚饾樁饾樀饾槺饾樁饾樀

unmarshal/decompile Python
open file marshaledFile.py
decompile Python 2.7 code with Python 2.7
write decompiled code to marshaledFile_decompiled.py

or

饾槰饾槳饾樂饾槮饾槸 饾槩 饾槯饾槳饾槶饾槮 饾槸饾槩饾槷饾槮饾槬 "饾槷饾槩饾槼饾槾饾槱饾槩饾槶饾槮饾槬饾槏饾槳饾槶饾槮38.饾槺饾樅" 饾槶饾槳饾槵饾槮

#!/usr/bin/env python
import marshal
exec(marshal.loads(b'c\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x00\x00@...

饾槫饾槩饾槶饾槶

python3 marshaledFile.py 38

饾槚饾樁饾樀饾槺饾樁饾樀

unmarshal/decompile Python
open file marshaledFile38.py
decompile Python 3.8 code with Python 3.9
write decompiled code to marshaledFile38_decompiled.py

饾樃饾槱饾槳饾槫饾槱 饾樃饾槳饾槶饾槶 饾槶饾槹饾槹饾槵 饾槶饾槳饾槵饾槮

# decompyle3 version 3.8.0
# Python bytecode 3.8
# Decompiled from: Python 3.8.2 (tags/v3.8.2:7b3ab59, Feb 25 2020, 23:03:10) [MSC v.1916 64 bit (AMD64)]
# Embedded file name: <source>

def test():
    return 0

print(test())