Skip to main content

Java is type safe — Probably

  • Conference paper
  • First Online:
ECOOP'97 — Object-Oriented Programming (ECOOP 1997)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 1241))

Included in the following conference series:

Abstract

Amidst rocketing numbers of enthusiastic Java programmers and internet applet users, there is growing concern about the security of executing Java code produced by external, unknown sources. Rather than waiting to find out empirically what damage Java programs do, we aim to examine first the language and then the environment looking for points of weakness. A proof of the soundness of the Java type system is a first, necessary step towards demonstrating which Java programs won't compromise computer security.

We consider a type safe subset of Java describing primitive types, classes, inheritance, instance variables and methods, interfaces, shadowing, dynamic method binding, object creation, null and arrays. We argue that for this subset the type system is sound, by proving that program execution preserves the types, up to subclasses/subinterfaces.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. M. Abadi and L. Cardelli. A semantics of object types. In LICS'94 Proceedings, 1994.

    Google Scholar 

  2. Joseph A. Bank, Barbara Liskov, and Andrew C. Myers. Parameterized types and Java. In POPL'97 Proceedings, January 1997.

    Google Scholar 

  3. Gerald Baumgartner and Vincent F. Russo. Signatures: A language extension for improving type abstraction and subtype polymorphism in C++. Software-Practice & Experience, 25(8):863–889, August 1995.

    Google Scholar 

  4. John Boyland and Giuseppe Castagna. Type-safe compilation of covariant specialization: A practical case. In ECOOP'96 Proceedings, July 1996.

    Google Scholar 

  5. P. Canning, William Cook, and William Olthoff. Interfaces for object-oriented programming. In OOPLSA'89, pages 457–467, 1989.

    Google Scholar 

  6. Giuseppe Castagna. Parasitic Methods: Implementation of Multimethods for Java. Technical report, C.N.R.S, November 1996.

    Google Scholar 

  7. Giuseppe Castagna, Giorgio Ghelli, and Giuseppe Longo. A calculus for overloaded functions with subtyping. Information and Computation, 117(1):115–135, 15 February 1995.

    Article  MathSciNet  Google Scholar 

  8. William Cook. A Proposal for making Eiffel Type-safe. In S. Cook, editor, ECOOP'87 Proceedings, pages 57–70. Cambridge University Press, July 1989.

    Google Scholar 

  9. William Cook, Walter Hill, and Peter Canning. Inheritance is not subtyping. In POPL'90 Proceedings, January 1990.

    Google Scholar 

  10. Luis Damas and Robin Milner. Principal Type Schemes for Functional Languages. In POPL'82 Proceedings, 1982.

    Google Scholar 

  11. Drew Dean, Edward W. Felten, and Dan S. Wallach. Java security: From Hot Java to Netscape and beyond. In Proceedings of the 1996 IEEE Symposium on Security and Privacy, pages 190–200, May 1996.

    Google Scholar 

  12. Sophia Drossopoulou and Susan Eisenbach. Is the Java type system sound? In Proceedings of the Fourth International Workshop on Foundations of Object-Oriented Languages, January 1997.

    Google Scholar 

  13. James Gosling, Bill Joy, and Guy Steele. The Java Language Specification. Addison-Wesley, August 1996.

    Google Scholar 

  14. R. Harper. A simplified account of polymorphic references. Technical Report CMU-CS-93-169, Carnegie Mellon University, 1993.

    Google Scholar 

  15. Daniel Ingalls. The smalltalk-76 programming system design and implementation. In POPL'78 Proceedings, pages 9–15, January 1978.

    Google Scholar 

  16. The Java language specification, October 1995.

    Google Scholar 

  17. The Java language specification, May 1996.

    Google Scholar 

  18. Bertrand Meyer. Static typing and other mysteries of life, December 1995.

    Google Scholar 

  19. Martin Odersky and Philip Wadler. Pizza into Java: Translating theory into practice. In POPL'97 Proceedings, January 1997.

    Google Scholar 

  20. Peter Sellinger. private communication, October 1996.

    Google Scholar 

  21. Mads Tofte. Type Inference for Polymorphic References. In Information and Computation'80 Conference Proceedings, pages 1–34, November 1980.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Mehmet Akşit Satoshi Matsuoka

Rights and permissions

Reprints and permissions

Copyright information

© 1997 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Drossopoulou, S., Eisenbach, S. (1997). Java is type safe — Probably. In: Akşit, M., Matsuoka, S. (eds) ECOOP'97 — Object-Oriented Programming. ECOOP 1997. Lecture Notes in Computer Science, vol 1241. Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0053388

Download citation

  • DOI: https://doi.org/10.1007/BFb0053388

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-63089-0

  • Online ISBN: 978-3-540-69127-3

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics