首页 | 官方网站   微博 | 高级检索  
     

Java虚拟机动态类加载的形式化模型
引用本文:左天军,朱智林,韩俊刚,陈平.Java虚拟机动态类加载的形式化模型[J].计算机科学,2005,32(7):209-213.
作者姓名:左天军  朱智林  韩俊刚  陈平
作者单位:1. 西安电子科技大学软件工程研究所,西安,710071
2. 西安邮电学院计算机系,西安,710061
基金项目:Supported by thd National Natural Science Foundation of China under Grant No.90207015(国家自然科学基金)
摘    要:Java虚拟机支持一种功能很强的动态加戡类的机制.它具有惰性加戡、类型安全连接、用户自定义加戡策略、以及劝态名字空间等特性。但是,在Java的早期实现(JDK1.0和1.1)中,这种机制包含了一种称为类型欺骗的严重设计错误.尽管JDK1.2通过引入一种类加戡约束策略修正了这个错误,但是由动态加戡引起的其它形式的类型欺骗仍然存在于JDK1.2和1.3中。本文详细讨论了与动态类加戡相关的类型欺骗问题,提出了一个严格定义Java虚拟机操作语义和静态语义的形式化模型。其中,操作语义描述了类加戡约束策略、字段及方法解析算法等类加戡的主要特性;静态语义采用类型规修正了JDK1.2和1.3中的类型欺骗。

关 键 词:Java虚拟机  形式化模型  动态  JDK1.2  加载  静态语义  用户自定义  安全连接  名字空间  设计错误  操作语义  语义描述  解析算法  类型  欺骗  机制  字段

A Formal Model for Dynamic Class Loading in the Java Virtual Machine
ZUO Tian-Jun,ZHU Zhi-Lin,HAN Jun-Gang,Chen Pin.A Formal Model for Dynamic Class Loading in the Java Virtual Machine[J].Computer Science,2005,32(7):209-213.
Authors:ZUO Tian-Jun  ZHU Zhi-Lin  HAN Jun-Gang  Chen Pin
Affiliation:ZUO Tian-Jun,ZHU Zhi-Lin,HAN Jun-Gang,CHEN Pin Institute of Software Engineering,Xidian University,Xi'an 710071 Department of Computer,Xi'an Institute of Post and Telecoms. Xi'an 710061
Abstract:The Java Virtual Machine(JVM)supports a novel and powerful class loading mechanism which incorporates all of the following features: lazy loading, type-safety linkage, user-definable class loading policy and multiple names- paces. However, that class loading methanism contained a seerious type-spoofing bug in earlier implementations (JDK 1.0 and 1.1), which leads to type safety violations. Although JDK 1.2 introduces a class loading constraint scheme to fix the bug, subtle type spoofing related to class loaders still exists in JDK 1.2 and 1.3. We develop a formal model to specity the operational semantics and static semantics of the Java virtual machine, rigorously. In the model, the opera- tional semantics describes the main features of class loading such as class loading constraints scheme, field and method resolutions etc. The static semantics uses typing rules to fix the type-spoofing bug in JDK 1.2 and 1.3.
Keywords:Dynamic class loading  Type safety  Type system  Operational semantics  Multiple loaders  Java virtual machine
本文献已被 CNKI 维普 万方数据 等数据库收录!
点击此处可从《计算机科学》下载全文
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司    京ICP备09084417号-23

京公网安备 11010802026262号