# A formal framework for the Java bytecode language and verifier

@inproceedings{Freund1999AFF, title={A formal framework for the Java bytecode language and verifier}, author={Stephen N. Freund and John C. Mitchell}, booktitle={Conference on Object-Oriented Programming Systems, Languages, and Applications}, year={1999} }

This paper presents a sound type system for a large subset of the Java bytecode language including classes, interfaces, constructors, methods, exceptions, and bytecode subroutines. This work serves as the foundation for developing a formal specification of the bytecode language and the Java Virtual Machine's bytecode verifier. We also describe a prototype implementation of a type checker for our system and discuss some of the other applications of this work. For example, we show how to extend…

## 68 Citations

### A Type System for the Java Bytecode Language and Verifier

- Computer ScienceJournal of Automated Reasoning
- 2004

This paper develops a specification in the form of a type system for a subset of the bytecode language that includes classes, interfaces, constructors, methods, exceptions, and bytecode subroutines, and presents a type checking algorithm and prototype bytecode verifier implementation.

### A Type System for JVM Threads 1

- Computer Science
- 2000

This paper isolates a sublanguage of the Java Virtual Machine with thread creation and mutual exclusion with a semantics and a formal verifier that enforces basic properties of threads and critical sections.

### Fixing the Java bytecode verifier by a suitable type domain

- Computer ScienceSEKE '02
- 2002

The enhanced bytecode verifier is proposed, based on a domain of types which is more expressive than the one used in standard verification, to accept legal Java programs which are correctly compiled into a bytecode that is rejected by the verifier.

### Verified bytecode verification and type-certifying compilation

- Computer ScienceJ. Log. Algebraic Methods Program.
- 2004

### Veried Bytecode Veriers

- Computer Science
- 2002

Using the theorem prover Isabelle/HOL it is shown that under certain conditions Kildall’s algorithm yields a correct bytecode verier and an abstract framework for proving correctness of data ow based type inference algorithms for assembly languages is formalized.

### Verified Bytecode Verifiers

- Computer ScienceFoSSaCS
- 2001

Using the theorem prover Isabelle/HOL we have formalized and proved correct an executable bytecode verifier in the style of Kildall's algorithm for a significant subset of the Java Virtual Machine.…

### Verified Bytecode Model Checkers

- Computer ScienceTPHOLs
- 2002

This work builds on, and extends, the formalization of the Java Virtual Machine and data flow analysis framework of Pusch and Nipkow, and builds on their results that relate the run-time behavior of programs with the existence of well-typings for the programs.

### A Coq Formalization of a Type Checker for Object Initialization in the Java Virtual Machine

- Computer Science
- 2000

A type system proposed in [11], to enforce a discipline for object initialization in the Java Virtual Machine language, was used to prove the theorems of [11] and to construct an effective verifier for this discipline.

### Type-Certifying Compilation

- Computer Science
- 2003

This article presents a type certifying compiler for a subset of Java and proves the type correctness of the bytecode it generates in the proof assistant Isabelle and shows a correspondence between bytecode and the certicate which entails welltyping.

## References

SHOWING 1-10 OF 42 REFERENCES

### A simple, comprehensive type system for Java bytecode subroutines

- Computer Science, GeologyPOPL '99
- 1999

This work presents an alternative type system, based on conventional ideas of type constraints, polymorphic recursion and continuations, for bytecode subroutines, that is simpler and able to type strictly more programs, including code that could be produced by Java compilers and cannot be typed in JVML-0.

### A simple, comprehensive type system for Java bytecode subroutines

- Computer Science, GeologyPOPL 1999
- 1999

This work presents an alternative type system, based on conventional ideas of type constraints, polymorphic recursion and continuations, for bytecode subroutines, that is simpler and able to type strictly more programs, including code that could be produced by Java compilers and cannot be typed in JVML-0.

### Toward a provably-correct implementation of the JVM bytecode verifier

- Computer ScienceProceedings DARPA Information Survivability Conference and Exposition. DISCEX'00
- 2000

This paper takes the perspective that bytecode verification is a data flow analysis problem, or more generally, a constraint-solving problem on lattices, and employs SPECWARE, a system available from Kestrel Institute that supports the development of programs from specifications, to formalize the bytecode verifier.

### A type system for object initialization in the Java bytecode language

- Computer ScienceOOPSLA '98
- 1998

A precise specification of statically-correct Java bytecode, in the form of a type system, is developed and it is proved that for every Javabytecode program that satisfies the authors' typing constraints, every object is initialized before it is used.

### A type system for Java bytecode subroutines

- Computer SciencePOPL '98
- 1998

This paper proposes using typing rules to describe the bytecode verifier because they are more precise than prose, clearer than code, and easier to reason about than either.

### Proving the Soundness of a Java Bytecode Verifier Specification in Isabelle/HOL

- Computer ScienceTACAS
- 1999

Large parts of the JVM are formalized, covering the central parts of object orientation, within the theorem prover Isabelle/HOL, and a specification for a Java bytecode verifier is formalized and formally proved its soundness.

### A specification of Java loading and bytecode verification

- Computer ScienceCCS '98
- 1998

The approach is to specify a generic dataflow architecture and formalize the JVM verifier as an instance of this architecture, and focuses on the use of data flow analysis and typing contexts to insure global type consistency in the context of an arbitrary strategy for dynamic class loading.

### The Functions of Java Bytecode

- Computer Science
- 1998

The key to the approach is to model individual bytecode instructions, and their compositions, as appropriately typed functions in a fairly standard functional language, which gives a exible way to build up and extend the instruction set.

### A formal specification of java(tin) virtual machine instructions

- Computer Science
- 1998

This paper formally specify a large subset of Java Virtual Machine instructions based on the descriptions in the Java Speciication, and proves that if the type inference system can derive certain compile-time (or link-time) types for a program, then the runtime data of the program will be type-correct with respect to these types in a certain sense.