如何对 QuickBasic 应用程序进行逆向工程?

发布于 11-02 23:26 字数 133 浏览 4 评论 0原文

我有一个用 QuickBasic 编写的应用程序(游戏)。我拥有它的权利,但没有编写原始代码。我面前有源代码,但我在试图理解这一切时有点绞尽脑汁。有什么方法可以让逆向工程变得更容易吗?现在我正在使用 FbEdit,只是尝试将应用程序分解为各个组成部分。

I have an application written in QuickBasic (a game). I own the rights to it, but didn't write the original code. I have the source code in front of me, but I'm banging my head a bit in trying to make sense of it all. Are there any ways to make reverse engineer easier? Right now I'm using FbEdit and just trying to pull the application apart into its various component parts.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

少女的英雄梦2024-11-09 23:26:35

如果你有代码并且只是试图理解它,那么你并不是真正的逆向工程。听起来更像你只是在做“维护”,但除此之外。

处理遗留项目需要大量阅读代码、弄清楚它在做什么、做笔记和重命名内容,直到您可以分离出各个部分,无论是 UI/菜单、动画、AI 还是游戏的任何功能。

对于逆向工程 DOS 游戏(在汇编中),我倾向于:

找到调用图形中断的代码区域,并开始命名这些graphics_N,文件处理或声音等也是如此。然后你您可能会注意到文本/菜单的位置,并且因为您知道游戏中的位置,所以您可以单步执行代码并查看代码如何跳转。您可能会注意到一些子函数更新了动画,您可以将其命名,然后找到调用它的位置,以更好地了解它的使用方式和位置。

通过访问代码,如果变量、函数和结构具有毫无意义的名称,我会感到震惊。但是 QB 对于小名称来说更容易......

我没有使用过 FBEdit,但是 Visual Studio 在读取 QB 代码方面做得很好(它认为它是 VB6/VB.Net),但从那里你可以很快地将其重写为 C#。我已经为一些旧的 QB 代码完成了此操作。您只需要编写一些执行经典 QB 功能的辅助函数,直到删除这些基本抽象。

You're not really reverse engineering if you have the code and you're just trying to understand it. Sounds more like you're just doing "maintenance", but that aside.

Handling a legacy project involves lots of reading the code, working out what it is doing, making notes, and renaming stuff, until you can separate out the parts, be that UI/menu's, animation, AI, or whatever it is the game does.

For reverse engineering DOS games (in assembly) I tend to:

Find area's of the code that call graphics interrupts, and start naming those graphics_N, and the same for file handling, or sound, etc. Then you may notice where text/menu's are, and because you know where in the game that is, you can single step through the code and see how the code is jumping around. You might notice some sub-function updating an animation, and you can name it that, and then find where that is called to get a better understanding of how and where it's used.

With access to the code, I'd be shocked if the variables, functions and structures had meaningless names. But QB was easier with small names...

I've not used FBEdit, but Visual Studio does an ok job of reading QB code (it thinks it's VB6/VB.Net) but from there you can rewrite it pretty quickly into C#. I've done this for some of my older QB code. You just need to write some helper functions that do classic QB functions, until you remove those basic abstractions.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文