如何解压缩Electron pack生成的单个EXE文件? [英] How to unpack a single EXE file produced by Electron pack?

查看:687
本文介绍了如何解压缩Electron pack生成的单个EXE文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个由Electron打包并运行的EXE文件。现在,我想解压缩单个EXE文件(不是asar)以研究该应用程序的源代码。但是如何呢?

I have an EXE file which is packed and run by Electron. Now I want to unpack the single EXE file (not asar) to study the source code of this app. But how?

我试图通过将此文件的扩展名从exe更改为zip,7z和tar来解压缩此Web桌面应用程序(由Electron打包的EXE文件)。但是所有操作都失败了,并表明此文件为 PE格式。

I have tried to unpack this web desktop app (EXE file packed by Electron) by change the extension of this file from exe to zip, 7z and tar. But all failed and indicates that this file is in "PE" format.

您能否显示一些将这个Electron应用程序解压缩为单个exe文件的方法?谢谢。

Could you please show some ways to unpack this Electron app in a single exe file? Thank you.

推荐答案

您不解压缩可执行文件,而是将其反编译。

You don't unpack an executable file, you decompile it.

AFAIK,您不会从可执行文件中获取源代码,所获得的只是作为汇编指令的机器代码。有一些工具可以帮助您将汇编指令转换为可读的C代码,例如, IDA Pro 可以做到这一点。

AFAIK, you won't get the source code from executable, all you get is machine code that is assembly instructions. There are tools out there which can help you to convert this assembly instructions to readable C code, for example, IDA Pro can do this.

在这种情况下,还有许多其他反编译器和调试器可以为您提供帮助。像 x64调试器

There are lot many other decompilers and debuggers which can help you in this scenario. Like x64 debugger or Olly Debugger.

相信我,您需要很多时间来精通这些工具,然后才能真正理解这些知识。

Trust me, you need a lot many hours to get proficient with these tools before you can actually make sense out of the raw assembly instructions, getting the source code out is a long way ahead.

出于好奇,为什么要电子可执行文件的源代码?电子应用程序的所有实际实现都应在ASAR压缩文件中(可以将其解压缩,然后获得所有JavaScript源代码)。电子可执行文件就像运行JavaScript的包装程序一样。

And out of curiosity, why you wanted the source code of electron executable? All the real implementations for electron app should be inside ASAR packed file (which can be decompressed and then you have all the JavaScript source code). Electron executable is just like a wrapper which runs the JavaScript.

您可以查看电子实现此处

这篇关于如何解压缩Electron pack生成的单个EXE文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆