从.exe C#恢复源代码 [英] Recover source code from .exe C#

查看:107
本文介绍了从.exe C#恢复源代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我为一个应用程序支付了一名自由职业者程序员来修理我的诊所。他完成了大约95%的项目,但后来在其他地方找到了工作并且随着我的源代码消失了......所以,我有一个半工作程序,我需要完成它。如何将源代码(Visual Studio,C#)恢复到可以完成我需要的程度,然后再重新编译它?这可能吗?我愿意购买/支付......



我尝试过:



我没有尝试过任何东西 - 不知道如何开始恢复源代码

解决方案

你可以使用Redgate的Reflector。有一个内置选项可以从它从可执行文件中提取的代码中生成一个Visual Studio项目。



它不会是一个漂亮的项目,你可能会必须修复一些东西让它再次起作用,但这是一个开始。



没有什么可以做得很完美。


< blockquote>不再有Reflector的免费版本,但更新的开源ILSpy完全取代了它。反向工程代码的质量非常好。请参阅: ILSpy [ ^ ]。



到目前为止,还有其他一些我从未尝试过的替代方案。



只是一个注意:如果您没有使用某些合适的版本控制系统,那么您实际上并不是在进行软件开发。您有价值的代码断言可能会因任何失败的随机错误而牺牲。你应该最好停止做你正在做的事情并开始使用这样的系统。请参阅此页:修订控制系统,可供选择?



-SA


来自Telerik的免费'JustDecompile应用程序也可以从.NET .exe文件创建一个新项目:[ ^ ]。这是VS2015准备就绪,此时正在积极维护和开发。



但是,如果程序员在源代码上使用了混淆,那么你将遇到更多麻烦比你已经拥有的更多。



程序员消失在空气中的想法似乎有点幻想:除非你付钱给他,否则就会有争议可交付成果,或未来的工作。


I paid a freelancer programmer for an app to tun my clinic. He got about 95% of the project done, but then got a job elsewhere and vanished into thin air, along with my source code... So, I have a semi-working program and I need to finish it. How can I recover the source code (Visual Studio, C#) to a point I can finish what I need and then recompile it again? Is this possible? I'm willing to buy/pay...

What I have tried:

I haven't tried anything - don't know how to start recovering the source code

解决方案

You can use Redgate's Reflector. There's an option built in to generate a Visual Studio project from the code it pulls out of the executable.

It's not going to be a pretty project and you'll probably have to fix stuff to make it work again, but it's a start.

There's nothing that's going to do a perfect job.


There is no free version of Reflector anymore, but newer open-source ILSpy perfectly replaced it. The quality of reverse-engineered code is very good. Please see: ILSpy[^].

There are several other alternatives I never tried so far.

Just a note: if you are not using some suitable Revision Control system, you are not really doing software development. Your valuable code asserts may be sacrificed to any random mistake of failure. You should better stop doing of what you are doing and start using such system. Please see this page: Revision control systems, which to choose from?.

—SA


The free 'JustDecompile app from Telerik can also create a new project from a .NET .exe file: [^]. It's VS2015 ready and is being actively maintained, and developed, at this time.

However, if the programmer used obfuscation on the source, you are going to have more trouble than you already have.

The idea of the programmer "disappearing into thin air" seems a bit fanciful: unless you paid him, already, and there is a dispute about the deliverable, or about future work.


这篇关于从.exe C#恢复源代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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