-
-
C# ildasm 与 ilasm 能对称使用吗?
-
发表于:
2010-12-2 17:31
5232
-
C# ildasm 与 ilasm 能对称使用吗?
都说这两个工具很牛,我试了一下对exe 文件是可以的。但是我试验了一下另外一个dll 却是不可以的。
我的主要操作步骤及过程如下:
第一步:用ildasm反编译c# dll 为 .il 文件
E:\wide-video\Disassembler\bin\Debug>ildasm ExtensionCommon.dll /out:ExtensionCommon.il
第二步:用ilasm 编译为 dll 文件
E:\wide-video\Disassembler\bin\Debug>ilasm /dll /res:ExtensionCommon.res ExtensionCommon.il
但结果新生成的 ExtensionCommon.dll 不能运行, 为什么呢 ?
附上具体的操作过程。是哪个地方出问题了吗? 还是还缺少操作步骤? 请达人指教!
E:\wide-video\Disassembler\bin\Debug>ls ExtensionCommon.*
ExtensionCommon.dll
E:\wide-video\Disassembler\bin\Debug>ildasm ExtensionCommon.dll /out:ExtensionCommon.il
E:\wide-video\Disassembler\bin\Debug>ls ExtensionCommon.*
ExtensionCommon.dll ExtensionCommon.il ExtensionCommon.res
E:\wide-video\Disassembler\bin\Debug>rm ExtensionCommon.dll
E:\wide-video\Disassembler\bin\Debug>ilasm /dll /res:ExtensionCommon.res ExtensionCommo
n.il
Microsoft (R) .NET Framework IL Assembler. Version 2.0.50727.3053
Copyright (c) Microsoft Corporation. All rights reserved.
Assembling 'ExtensionCommon.il' to DLL --> 'ExtensionCommon.dll'
Source file is ANSI
Assembled method Common.SettingDefaultEventArgs::get_Guid
Assembled method Common.SettingDefaultEventArgs::set_Guid
Assembled method Common.SettingDefaultEventArgs::.ctor
Assembled method Common.UI.ExtensionConfigForm::add_SettingOk
Assembled method Common.UI.ExtensionConfigForm::remove_SettingOk
Assembled method Common.UI.ExtensionConfigForm::add_SettingApply
Assembled method Common.UI.ExtensionConfigForm::remove_SettingApply
Assembled method Common.UI.ExtensionConfigForm::add_SettingDefault
Assembled method Common.UI.ExtensionConfigForm::remove_SettingDefault
Assembled method Common.UI.ExtensionConfigForm::.ctor
Assembled method Common.UI.ExtensionConfigForm::ShowDialog
Assembled method Common.UI.ExtensionConfigForm::InitializeComponent
Assembled method Common.UI.ExtensionConfigForm::InitializeTreeView
Assembled method Common.UI.ExtensionConfigForm::OnTvExtensions_NodeMouseClick
Assembled method Common.UI.ExtensionConfigForm::GetSettingTabPage
Assembled method Common.UI.ExtensionConfigForm::OnBtnOk_Click
Assembled method Common.UI.ExtensionConfigForm::OnBtnDefault_Click
Assembled method Common.UI.ExtensionConfigForm::SettingDefaultCallback
Assembled method Common.UI.ExtensionConfigForm::RefreshSettingPanel
Assembled method Common.UI.ExtensionConfigForm::OnBtnApply_Click
Assembled method Common.UI.ExtensionConfigForm::DisplayErrorDialog
Assembled method Common.HostExBrowser::.ctor
Assembled method Common.HostExBrowser::CreateNewPage
Assembled method Common.HostExBrowser::Navigate
Assembled method Common.HostExBrowser::GoForward
Assembled method Common.HostExBrowser::GoBack
Assembled method Common.HostExBrowser::Stop
Assembled method Common.HostExBrowser::Refresh
Assembled method Common.HostExBrowser::GoHome
Assembled method Common.HostExBrowser::FullScreen
Assembled method Common.UI.ExtensionManageForm::.ctor
Assembled method Common.UI.ExtensionManageForm::ShowDialog
Assembled method Common.UI.ExtensionManageForm::InitializeComponent
Assembled method Common.UI.ExtensionManageForm::InitializeListView
Assembled method Common.UI.ExtensionManageForm::OnLvExtensions_ItemSelectionChanged
Assembled method Common.UI.ExtensionManageForm::OnStateChange
Assembled method Common.UI.ExtensionManageForm::OnLnkDownloadMore_Click
Assembled method Common.UI.ExtensionManageForm::OnLnkLearnMore_Click
Assembled method Common.UI.ExtensionManageForm::OnBtnOk_Click
Assembled method Common.HostEventArgs::get_UserId
Assembled method Common.HostEventArgs::set_UserId
Assembled method Common.HostEventArgs::.ctor
Assembled method Common.ExtensionManager::get_Extensions
Assembled method Common.ExtensionManager::get_Host
Assembled method Common.ExtensionManager::get_Adapters
Assembled method Common.ExtensionManager::.ctor
Assembled method Common.ExtensionManager::LoadConfig
Assembled method Common.ExtensionManager::SaveConfig
Assembled method Common.ExtensionManager::LoadExtension
Assembled method Common.ExtensionManager::UnloadExtension
Assembled method Common.ExtensionManager::QueryExtension
Assembled method Common.ExtensionManager::CheckNewExtension
Assembled method Common.ExtensionManager::RegCmd
Assembled method Common.ExtensionManager::OnConfigChanged
Assembled method Common.ExtensionManager::Excute
Assembled method Common.ExtensionAdapter::.ctor
Assembled method Common.ExtensionAdapter::CreateUI
Assembled method Common.ExtensionAdapter::UpdateUI
Assembled method Common.ExtensionAdapter::OnUpdateUI
Assembled method Common.ExtensionAdapter::CreateContextMenu
Assembled method Common.ExtensionAdapter::CreateMainMenu
Assembled method Common.ExtensionAdapter::GetRealName
Assembled method Common.ExtensionAdapter::CreateMenuItem
Assembled method Common.ExtensionAdapter::CreateToolButton
Assembled method Common.ExtensionAdapter::CreateToolButtonItem
Assembled method Common.ExtensionAdapter::CreateStatusLabel
Assembled method Common.ExtensionAdapter::CreateStatusLabelItem
Assembled method Common.ExtensionAdapter::CreateSideTab
Assembled method Common.ExtensionAdapter::UpdateMenuItem
Assembled method Common.ExtensionAdapter::UpdateToolButton
Assembled method Common.ExtensionAdapter::UpdateStatusLabel
Assembled method Common.ExtensionAdapter::UpdateSideTab
Assembled method Common.ExtensionConstants::.ctor
Assembled method Common.ExtensionConstants::.cctor
Assembled method Common.ExtensionHost::.ctor
Assembled method Common.ExtensionHost::OnQuit
Assembled method Common.ExtensionHost::OnLogin
Assembled method Common.ExtensionHost::OnLogout
Assembled method Common.ExtensionHost::get_Version
Assembled method Common.ExtensionHost::set_Version
Assembled method Common.ExtensionHost::LoadConfig
Assembled method Common.ExtensionHost::SaveConfig
Assembled method Common.ExtensionHost::QueryInterface
Assembled method Common.ExtensionHost::add_Quit
Assembled method Common.ExtensionHost::remove_Quit
Assembled method Common.ExtensionHost::add_Login
Assembled method Common.ExtensionHost::remove_Login
Assembled method Common.ExtensionHost::add_Logout
Assembled method Common.ExtensionHost::remove_Logout
Creating PE file
Emitting classes:
Class 1: Common.SettingDefaultEventArgs
Class 2: Common.IExtensionItem
Class 3: Common.UI.SettingDefaultEventHandler
Class 4: Common.UI.RefreshSettingPanelDelegate
Class 5: Common.UI.ExtensionConfigForm
Class 6: Common.ExtensionManager
Class 7: Common.IExtension
Class 8: Common.ISettingTabPage
Class 9: Common.IHostExBrowser
Class 10: Common.IRssManager
Class 11: Common.IFavoriteManager
Class 12: Common.IExtensionSideTabPage
Class 13: Common.HostExBrowser
Class 14: Common.IExtensionMeta
Class 15: Common.IExtensionHost
Class 16: Common.ExtensionButtonType
Class 17: Common.IExtensionToolButton
Class 18: Common.IExtensionMenuItem
Class 19: Common.ExtensionLabelType
Class 20: Common.IExtensionLabelItem
Class 21: Common.ExtensionMenuType
Class 22: Common.UI.ExtensionManageForm
Class 23: Common.HostEventArgs
Class 24: Common.ExtensionHost
Class 25: Common.ExtensionAdapter
Class 26: Common.ExtensionConstants
Emitting fields and methods:
Global
Class 1 Fields: 1; Methods: 3;
Class 2 Methods: 9;
Class 3 Methods: 4;
Class 4 Methods: 4;
Class 5 Fields: 12; Methods: 18;
Class 6 Fields: 6; Methods: 13;
Class 7 Methods: 14;
Class 8 Methods: 2;
Class 9 Methods: 8;
Class 10
Class 11
Class 12 Methods: 4;
Class 13 Fields: 1; Methods: 9;
Class 14 Methods: 5;
Class 15 Methods: 10;
Class 16 Fields: 3;
Class 17 Methods: 4;
Class 18 Methods: 11;
Class 19 Fields: 4;
Class 20 Methods: 5;
Class 21 Fields: 4;
Class 22 Fields: 14; Methods: 9;
Class 23 Fields: 1; Methods: 3;
Class 24 Fields: 8; Methods: 15;
Class 25 Fields: 9; Methods: 17;
Class 26 Fields: 8; Methods: 2;
Resolving local member refs: 562 -> 562 defs, 0 refs, 0 unresolved
Emitting events and properties:
Global
Class 1 Props: 1;
Class 2 Events: 1; Props: 7;
Class 3
Class 4
Class 5 Events: 3;
Class 6 Props: 3;
Class 7 Props: 8;
Class 8 Props: 2;
Class 9
Class 10
Class 11
Class 12 Props: 2;
Class 13
Class 14 Props: 5;
Class 15 Events: 3; Props: 1;
Class 16
Class 17 Props: 3;
Class 18 Props: 7;
Class 19
Class 20 Props: 4;
Class 21
Class 22
Class 23 Props: 1;
Class 24 Events: 3; Props: 1;
Class 25
Class 26
Resolving local member refs: 0 -> 0 defs, 0 refs, 0 unresolved
Writing PE file
Operation completed successfully
E:\wide-video\Disassembler\bin\Debug>ls ExtensionCommon.*
ExtensionCommon.dll ExtensionCommon.il ExtensionCommon.res
[招生]科锐逆向工程师培训(2024年11月15日实地,远程教学同时开班, 第51期)