Efficient Memory Safety for TinyOS

Nathan Cooprider Will Archer Eric Eide David Gay John Regehr
coop@cs.utah.edu warcher@cs.utah.edu eeide@cs.utah.edu david.e.gay@intel.com regehr@cs.utah.edu

University of Utah, School of Computing
50 South Central Campus Drive, Room 3190
Salt Lake City, Utah 84112-9205
      Intel Research
2150 Shattuck Avenue, Suite 1300
Berkeley, CA 94704, USA

In Proceedings of the ACM Conference on Embedded Networked Sensor Systems (Sensys). Sydney, Australia, November 2007

© ACM, 2007. This is the author's version of the work. It is posted here by permission of ACM for your personal use. Not for redistribution.

Abstract

Reliable sensor network software is difficult to create: applications are concurrent and distributed, hardware-based memory protection is unavailable, and severe resource constraints necessitate the use of unsafe, low-level languages. Our work improves this situation by providing memory and type safety for TinyOS 2 applications running on the Mica2, MicaZ, and TelosB platforms. Safe execution ensures that array and pointer errors are caught before they can corrupt RAM. Our contributions include showing that aggressive optimizations can make safe execution practical in terms of resource usage; developing a technique for efficiently enforcing safety under interrupt-driven concurrency; extending the nesC language and compiler to support safety annotations; finding previously unknown bugs in TinyOS; and, finally, showing that safety can be exploited to increase the availability of sensor networks applications even when memory errors are left unfixed.



Nathan Cooprider <coop@cs.utah.edu>