https://docs.microsoft.com/en-us/dotnet/standard/assembly/file-format

.NET defines a binary file format - "assembly" - that is used to fully-describe and contain .NET programs.

Assemblies are used for the programs themselves as well as any dependent libraries.

A .NET program can be executed as one or more assemblies, with no other required artifacts, beyond the appropriate .NET implementation.

Native dependencies, including operating system APIs, are a separate concern and are not contained within the .NET assembly format, although are sometimes described with this format (for example, WinRT).

Each CLI component carries the metadata for declarations, implementations, and references specific to that component. Therefore, the component-specific metadata is referred to as component metadata, and the resulting component is said to be self-describing – from ECMA 335 I.9.1, Components and assemblies.

The format is fully specified and standardized as ECMA 335.

All .NET compilers and runtimes use this format.

The presence of a documented and infrequently updated binary format has been a major benefit (arguably a requirement) for interoperability.

The format was last updated in a substantive way in 2005 (.NET 2.0) to accommodate generics and processor architecture.

The format is CPU- and OS-agnostic.

It has been used as part of .NET implementations that target many chips and CPUs.

While the format itself has Windows heritage, it is implementable on any operating system.

Its arguably most significant choice for OS interoperability is that most values are stored in little-endian format.

It doesn’t have a specific affinity to machine pointer size (for example, 32-bit, 64-bit).

The .NET assembly format is also very descriptive about the structure of a given program or library.

It describes the internal components of an assembly, specifically: assembly references and types defined and their internal structure.

Tools or APIs can read and process this information for display or to make programmatic decisions.

Format

https://en.wikipedia.org/wiki/Portable_Executable

The .NET binary format is based on the Windows PE file format. In fact, .NET class libraries are conformant Windows PEs, and appear on first glance to be Windows dynamic link libraries (DLLs) or application executables (EXEs). This is a very useful characteristic on Windows, where they can masquerade伪装 as native executable binaries and get some of the same treatment (for example, OS load, PE tools).

Assembly Headers from ECMA 335 II.25.1, Structure of the runtime file format.

Processing the Assemblies

It is possible to write tools or APIs to process assemblies.

Assembly information enables making programmatic decisions at runtime, re-writing assemblies, providing API IntelliSense in an editor and generating documentation.

System.Reflection and Mono.Cecil are good examples of tools that are frequently used for this purpose.

.NET Assembly File Format的更多相关文章

  1. dnSpy PE format ( Portable Executable File Format)

    Portable Executable File Format PE Format  微软官方的 What is a .PE file in the .NET framework? [closed] ...

  2. could not read symbols: File format not recognized

    arm-linux-gnueabi-readelf工具解决问题 编译一个32位平台的内核时,出现如下错误提示: libschw.a: could not read symbols: File form ...

  3. Java class file format specfication

    Java class file format spec Link: https://docs.oracle.com/javase/specs/jvms/se7/html/jvms-4.html Her ...

  4. NopCommerce 发布时 Could not load file or assembly 'file:///...\Autofac.3.5.2\lib\net40\Autofac.dll' or one of its dependencies

    本文转自:http://www.nopcommerce.com/boards/t/33637/4-errors.aspx 问题: The 3.5 solution compiles fine, and ...

  5. Does the OpenSceneGraph have a native file format?

    From OpenSceneGraph-3.0 onwards we have new native file formats based on generic serializers that ar ...

  6. 遇到一个奇葩的问题,could not load the assembly file XXX downloaded from the Web

    在我这编译好好滴,发给客户那边居然不通过,报could not load the assembly file:///xxx.dll, 查阅了一些文档后,发现原来是文件的安全问题,是由于我把文件压缩打包 ...

  7. VMWare File Format Learning && Use VHD File To Boot VMWare && CoreOS Docker Configuration And Running

    目录 . Virtual Machine Introduce . Vmware Image File Format . VHD File Format . Convert VHD File Into ...

  8. 配置tomcat连接器后,启动服务报错“No Certificate file specified or invalid file format"异常

    1:原来的配置是 <Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true&quo ...

  9. 配置CAS错误No Certificate file specified or invalid file format

    配置tomcat证书 keystore文件后启动一直报错:(tomcat版本:apache-tomcat-6.0.43) tomcat配置: <Connector port="8443 ...

随机推荐

  1. php操作 cookie

    1,设置cookie <?php setcookie('key'); setcookie('key1','value1'); setcookie(***); setcookie('key4', ...

  2. 正确理解这四个重要且容易混乱的知识点:异步,同步,阻塞,非阻塞,5种IO模型

    本文讨论的背景是Linux环境下的network IO,同步IO和异步IO,阻塞IO和非阻塞IO分别是什么 概念说明 在进行解释之前,首先要说明几个概念: - 用户空间和内核空间 - 进程切换 - 进 ...

  3. vue入门 0 小demo (挂载点、模板、实例)

    vue入门 0 小demo  (挂载点.模板) 用直接的引用vue.js 首先 讲几个基本的概念 1.挂载点即el:vue 实例化时 元素挂靠的地方. 2.模板 即template:vue 实例化时挂 ...

  4. 纯净CentOS搭建harbor镜像私仓

    物理宿主机IP:  192.168.1.4 在官网下载 CentOS-7-x86_64-DVD-1810 用Hyper-v建立一代虚机,安装时遇分辨率问题无法继续,需要在选择启动界面按TAB键以编辑启 ...

  5. ln建立时符号链接时出现同名文件或目录

    给ln命令加上-s选项,则建立软链接. 格式:ln -s [真正的文件或者目录] [链接名]   [链接名]可以是任何一个文件名或者目录名,并且允许它与原文件不在同一个文件系统中. 如果[链接名]是一 ...

  6. SDK更新失败问题解决

    环境:1. win102. Have over fire wall 解决办法:1.启动 Android SDK Manager ,打开主界面,依次选择「Tools」.「Options...」,弹出『A ...

  7. zencart用sql将某个产品属性值设为只读和默认

    zencart用sql将某个产品属性值设为只读和默认 UPDATE `products_attributes` SET `attributes_display_only` = '1', `attrib ...

  8. Django学习系列21:为每一个清单添加唯一URL

    现在让我们来解决我们真正的问题,即我们的设计只允许一个全局列表. 我将演示一个关键的TDD技术:如何使用一个渐进的.循序渐进的过程来适应现有的代码,这些过程将您从工作状态转移到工作状态.测试山羊,而不 ...

  9. 返回的json数据中有属性为null的情况,报错 "message" : "Could not write JSON: Object is null

  10. 谷歌插件学习笔记:把iframe干掉……

    好久不写博客了,感觉自己变得越来越懒了,是没有时间吗?不是,是自己变得越来越懒了,好多东西不愿意去总结了,可能也是学的不精总结不出来什么玩意儿.不过,一切都是借口.还是坚持学习,坚持写博客吧,虽然写的 ...