Software Robustness Testing Service



Similar documents
Robustness Testing of the Microsoft Win32 API

Between Mutual Trust and Mutual Distrust: Practical Fine-grained Privilege Separation in Multithreaded Applications

El Dorado Union High School District Educational Services

Operating Systems and Networks

Evolution of the Major Programming Languages

Object Oriented Software Design II

Lab 4: Socket Programming: netcat part

Testing Automation for Distributed Applications By Isabel Drost-Fromm, Software Engineer, Elastic

Course Name: ADVANCE COURSE IN SOFTWARE DEVELOPMENT (Specialization:.Net Technologies)

Curriculum Map. Discipline: Computer Science Course: C++

Illustration 1: Diagram of program function and data flow

Operating System Structures

C++ Programming Language

GDB Tutorial. A Walkthrough with Examples. CMSC Spring Last modified March 22, GDB Tutorial

RTI Monitoring Library Getting Started Guide

Last Class: OS and Computer Architecture. Last Class: OS and Computer Architecture

Kernel Types System Calls. Operating Systems. Autumn 2013 CS4023

Java (12 Weeks) Introduction to Java Programming Language

The GenomeTools Developer s Guide

System Calls and Standard I/O

How To Use Ibm Tivoli Monitoring Software

Chapter 3 Operating-System Structures

Mimer SQL Real-Time Edition White Paper

vector vec double # in # cl in ude <s ude tdexcept> tdexcept> // std::ou std t_of ::ou _range t_of class class V Vector { ector {


Microkernels & Database OSs. Recovery Management in QuickSilver. DB folks: Stonebraker81. Very different philosophies

HP OO 10.X - SiteScope Monitoring Templates

Chapter 2 System Structures

Blackboard Collaborate Web Conferencing Hosted Environment Technical Infrastructure and Security

The C Programming Language course syllabus associate level

NS3 Lab 1 TCP/IP Network Programming in C

6.088 Intro to C/C++ Day 4: Object-oriented programming in C++ Eunsuk Kang and Jean Yang

Magento & Zend Benchmarks Version 1.2, 1.3 (with & without Flat Catalogs)

1 File Processing Systems

Automating Security Testing. Mark Fallon Senior Release Manager Oracle

PROGRESS DATADIRECT QA AND PERFORMANCE TESTING EXTENSIVE TESTING ENSURES DATA CONNECTIVITY THAT WORKS

INTRODUCTION TO OBJECTIVE-C CSCI 4448/5448: OBJECT-ORIENTED ANALYSIS & DESIGN LECTURE 12 09/29/2011

Introduction to Automated Testing

Polymorphism. Problems with switch statement. Solution - use virtual functions (polymorphism) Polymorphism

Latest Trends in Testing. Ajay K Chhokra

Outside In Image Export Technology SDK Quick Start Guide

Firebird. A really free database used in free and commercial projects

Fault Isolation and Quick Recovery in Isolation File Systems

An Open Source Wide-Area Distributed File System. Jeffrey Eric Altman jaltman *at* secure-endpoints *dot* com

ZFS Backup Platform. ZFS Backup Platform. Senior Systems Analyst TalkTalk Group. Robert Milkowski.

COS 318: Operating Systems

Infrastructure that supports (distributed) componentbased application development

How To Understand How A Process Works In Unix (Shell) (Shell Shell) (Program) (Unix) (For A Non-Program) And (Shell).Orgode) (Powerpoint) (Permanent) (Processes

Overview. Big Data in Apache Hadoop. - HDFS - MapReduce in Hadoop - YARN. Big Data Management and Analytics

A Fully Standards-Based Approach to Logging High-Throughput Distributed Real-Time Data. Leveraging the DDS and SQL Standards

<Insert Picture Here> Oracle Database Support for Server Virtualization Updated December 7, 2009

CIS 551 / TCOM 401 Computer and Network Security

Enterprise Manager Performance Tips

MatrixSSL Porting Guide

Client/Server Computing Distributed Processing, Client/Server, and Clusters

Computer Security: Principles and Practice

Objectives. Chapter 2: Operating-System Structures. Operating System Services (Cont.) Operating System Services. Operating System Services (Cont.

Randy Hyde s Win32 Assembly Language Tutorials (Featuring HOWL) #4: Radio Buttons

Availability Digest. Raima s High-Availability Embedded Database December 2011

Design: Metadata Cache Logging

NEOAUG. Custom Web ADI Integrators

An Overview of Java. overview-1

Glassfish Architecture.

The Power of Deduplication-Enabled Per-VM Data Protection SimpliVity s OmniCube Aligns VM and Data Management

Cisco Security Agent (CSA) Network Admission Control (NAC)

MySQL Enterprise Backup

Art of Code Front-end Web Development Training Program

Fast Arithmetic Coding (FastAC) Implementations

C++ INTERVIEW QUESTIONS

Project Proposal. Data Storage / Retrieval with Access Control, Security and Pre-Fetching

How do Users and Processes interact with the Operating System? Services for Processes. OS Structure with Services. Services for the OS Itself

Example of Standard API

Chapter 15 Operating System Security

To Java SE 8, and Beyond (Plan B)

Variable Base Interface

Replication on Virtual Machines

Stacks. Linear data structures

Virtual Private Systems for FreeBSD

Red Hat Enterprise Linux 6. Stanislav Polášek ELOS Technologies

Hypertable Architecture Overview

KITES TECHNOLOGY COURSE MODULE (C, C++, DS)

C++ Class Library Data Management for Scientific Visualization

Performance Test Results Report for the Sled player

CS3600 SYSTEMS AND NETWORKS

Linux/UNIX System Programming. POSIX Shared Memory. Michael Kerrisk, man7.org c February 2015

David Dye. Extract, Transform, Load

Quiz I Solutions MASSACHUSETTS INSTITUTE OF TECHNOLOGY Fall Department of Electrical Engineering and Computer Science

Chapter 11: File System Implementation. Operating System Concepts with Java 8 th Edition

Developing Embedded Software in Java Part 1: Technology and Architecture

Logistics. Software Testing. Logistics. Logistics. Plan for this week. Before we begin. Project. Final exam. Questions?

Recovery Principles in MySQL Cluster 5.1

Chapter 6: Programming Languages

Transcription:

Software Robustness Testing Service http://www.ices.cmu.edu/ballista Philip Koopman ECE Department koopman@cmu.edu - (412) 268-5225 - http://www.ices.cmu.edu/koopman,qvwlwxwh IRU &RPSOH[ (QJLQHHUHG 6\VWHPV

Overview: Practical Issues in a Testing Service Brief review of Ballista testing Robustness testing over the Internet Supporting features: Setting global state Fine-grain test coverage Test scaffolding Legitimate exceptions Future work What we can do What we can t do A Ballista is an ancient siege weapon for hurling objects at fortified defenses. 2

Object-Oriented Test Generation API TESTING OBJECTS write(int filedes, const void *buffer, size_t nbytes) FILE DESCRIPTOR TEST OBJECT MEMORY BUFFER TEST OBJECT SIZE TEST OBJECT TEST VALUES FD_CLOSED FD_OPEN_READ FD_OPEN_WRITE FD_DELETED FD_NOEXIST FD_EMPTY_FILE FD_PAST_END FD_BEFORE_BEG FD_PIPE_IN FD_PIPE_OUT FD_PIPE_IN_BLOCK FD_PIPE_OUT_BLOCK FD_TERM FD_SHM_READ FD_SHM_RW FD_MAXINT FD_NEG_ONE BUF_SMALL_1 BUF_MED_PAGESIZE BUF_LARGE_512MB BUF_XLARGE_1GB BUF_HUGE_2GB BUF_MAXULONG_SIZE BUF_64K BUF_END_MED BUF_FAR_PAST BUF_ODD_ADDR BUF_FREED BUF_CODE BUF_16 BUF_NULL BUF_NEG_ONE SIZE_1 SIZE_16 SIZE_PAGE SIZE_PAGEx16 SIZE_PAGEx16plus1 SIZE_MAXINT SIZE_MININT SIZE_ZERO SIZE_NEG TEST CASE write(fd_open_rd, BUFF_NULL, SIZE_16) 3

Test Value Inheritance Date String 12/1/1899 1/1/1900 Generic String Generic Pointer NULL DELETED 1K PAG ESIZE MAXSIZE SIZE1 IN VALID BIGSTRING STRINGLEN1 ALLASCII NONPRINTABLE 2/29/1984 4/31/1998 13/1/1997 12/0/1994 8/31/1992 8/32/1993 12/31/1999 1/1/2000 12/31/2046 1/1/2047 1/1/8000 Date string inherits test cases from all parents 4

Robustness Testing Service Ballista Server Ballista Client Selects tests Links to user s SW under test Performs pattern Analysis Generates bug reports Can teach new data types to server (definition language) Never sees user s code BALLISTA SERVER TESTING OBJECT COMPILER INTERFACE SPECIFICATION CAPTURE WWW & RPC BALLISTA TEST CLIENT USER S COMPUTER RESULT PATTERN DISCOVERY TEST SELECTION TEST REPORTING MODULE UNDER TEST 5

Specifying the Test Simple demo interface; real interface has a few more steps... 6

Viewing Results Each robustness failure is one test case (one set of parameters) 7

Bug Report program creation Reproduces failure in isolation (>99% effective) /* Ballista single test case Sun Jun 13 14:11:06 1999 * fopen(fname_neg, STR_EMPTY) */... const char *str_empty = "";... param0 = (char *) -1; str_ptr = (char *) malloc (strlen (str_empty) + 1); strcpy (str_ptr, str_empty); param1 = str_ptr;... fopen (param0, param1); 8

Estimated Failure Rates After Analysis Normalized Failure Rate by Operating System AIX FreeBSD Operating System Tested HPUX 9.05 HPUX 10.20 Irix 5.3 Irix 6.2 Linux Lynx NetBSD OSF-1 3.2 OSF-1 4.0 QNX 4.22 QNX 4.24 Abort % Silent % Restart % Catastrophic SunOS 4.13 SunOS 5.5 0% 10% 20% 30% 40% 50% Normalized Failure Rate (after analysis) 9

Support Features Test selection / pattern discovery Randomly selected subset of tests for large testing spaces In future, smarter testing to identify failure-free regions Need fine-grain tests to achieve notion of adjacent test cases Data type compiler Define new testing objects for new data types Want finer grain testing for better testing coverage Want automatic composition of data structures from existing primitives Hardening wrappers Easy wrappers are easy (e.g., NULL pointer hardening) Hard wrappers get harder the more we think about them 10

Physical Structures (work in progress) Flatten structure and use existing primitive constructors Example of single element; linked list of complex numbers 3K\VLFDO 32,17(5D 32,17(5E )/2$7F )/2$7G %DOOLVWD 5HSUHVHQWDWLRQ WHVWBFDVH32,17(5D 32,17(5E )/2$7F )/2$7G $W 5XQWLPH FRQVWUXFW 32,17(5D FRQVWUXFW 32,17(5E ZLWKLQ VWUXFWXUH FRQVWUXFW )/2$7F ZLWKLQ VWUXFWXUH FRQVWUXFW )/2$7G ZLWKLQ VWUXFWXUH FDOO IXQFWLRQ32,17(5D 11

Setting Global State Use phantom parameter idea to set global state User specifies: function(+param0, param1, ) System executes all constructors But, system only passes physical parameters: function(param1) Example: random(+seed_value) establishes a random number seed via a constructor, then calls random() Permits setting substantial amount of state using testing objects Execute test scaffolding (e.g., create federation; join federation) Set global state (e.g., fill up hard disk before file I/O) Set hidden state: (e.g., testing random number generator) 12

Patterns of Testing Result (Jiantao Pan s work) fprintf(file_pointer, STRing) in HP-UX 1-D failures: They form a line in a 2-D function (function that parameter dimensionality=2) They form a hyperplane in a n-d function All 1-D failures this line 3DVV RU HUURU FRGH 5REXVWQHVV )DLOXUH $ERUW5HVWDUW 13

Toward Fine-Grain Characterization Problem: detailed coverage of rich data types (e.g., file handle) Current tests have large grain size Want tests with high degree of flexibility Want useful notion of adjacency in test results Solution: Logical Structs Decompose data type into logical struct of orthogonal sub-types Example for file handle: 1) File exists, does not exist, deleted after creation 2) Open for: read, write, r/w, closed 3) File system permissions for: read, write, r/w, none 4) File positioned at: beginning, middle, end, past end 5)... 14

What About Required Scaffolding? Operating system code: No scaffolding required All durable system state set in constructors / restored by destructors File creation/deletion Process creation/deletion HLA RTI distributed simulation framework: Requires scaffolding e.g., create Federation, create Federate, join Federation But, not that many distinct scaffolding sets 10 sets of scaffolding for 86 modules Only a few lines of code each Expect to see a similar outcome on many other applications 15

What About Different Exception Models? Not all programs use error return codes What is a robustness failure in context of thrown exceptions? But, assume that interface spec. defines all valid exceptions We consider these failures (based on HLA RTI results): System crashes/hangs = Catastrophic Task hangs = Restart Exception system panic = Abort+ Unknown/default exception = Abort SIGSEGV (uncaught system exception) = Abort No exception thrown = Silent (difficult to test for) Undocumented exception = Hindering 16

Future Work Heavy load testing Resource exhaustion Timing-dependent failures Varied applications HLA RTI simulation backplane Paper submitted to ISSRE Plans to make Ballista testing part of RTI certification suite Windows (Win32 API) State-intensive object repository for train control (ABB) Factory process control (Emerson) 17

What Ballista Does (and Doesn t Do) Quantification of exception handling robustness Scalable, inexpensive compared to traditional testing approaches Makes a contribution toward the ~80% of code for exception handling In the future, will include heavy-load testing But, any such metric is difficult to relate to an operational profile Currently, uses heuristic tests Fine grain searching will enable use of adaptive testing + search methods Easier than it appears to test some system state Small amounts of system state in parameter-based tests Larger system state possible using phantom parameters But, will it work on a database-like system? (we ll find out ) 18

Other Potential Uses Best used as a QA technique Quality must be designed in, not tested in Perhaps extend to light-weight correctness testing Dynamic tension between scalability and specificity Can other behaviors be represented with a simple oracle? Memory consumption Touching (or not touching) safety critical objects High-level security check Buffer over-run testing Detect touching non-permissible items (e.g., security logs) Potentially useful as a metric for diversity 19