1 / 18

The TTCN-3 module and template concepts revisited

Michael Schmitt · University of Trier · Germany. Michael Ebner · University of Göttingen · Germany. The TTCN-3 module and template concepts revisited. TestCom 2003. Outline. Revised module concept Parallel operator Enhanced matching mechanisms for records, arrays, and sets.

yanni
Download Presentation

The TTCN-3 module and template concepts revisited

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Michael Schmitt· University of Trier · Germany Michael Ebner· University of Göttingen · Germany The TTCN-3 module and template concepts revisited TestCom 2003

  2. Outline • Revised module concept • Parallel operator • Enhanced matching mechanismsfor records, arrays, and sets

  3. Combine groups and modulesand introduce a control function Why a revised module concept? • Coping with large amounts of test cases • cascading can only be realised by auxiliary functions called in the module control part • Limitations of groups • groups have no own scope • no semantic purpose (except for import) • No signature defined

  4. Module Concept Comparison Current Style module CGIabuses{ control { IIS.control_IIS(); } group IIS { functioncontrol_IIS() { ExAir.control_ExAir(); } groupExAir { functioncontrol_ExAir() { … } Proposed Style module CGIabuses { functioncontrol() returnverdicttype{ IIS(); } moduleIIS { functioncontrol() returnverdicttype{ ExAir();} moduleExAir { functioncontrol() { … }

  5. Why a Parallel Operator? • Sequential test case execution is too time-consuming in case of a large number of test cases • Test cases may depend on each other

  6. Parallel Operator Example module SecurityTests( integer maxNoOfTestCases, boolean denialOfService ) { function control() { var verdicttype v := pass; par ( maxNoOfTestCases ) { info [ true ] { v.set( execute( findServices() ) ); } mssql [ v == passandinfo == trueand port[1433] == open ] { v.set( execute( MSSQLPasswords() ) ); } smurf[10] [ v == pass and info == true and denialOfService == true ] { v.set( execute( smurfAttack() ) ); } else { ... } } } } module SecurityTests( integer maxNoOfTestCases, boolean denialOfService ) { function control() { var verdicttype v := pass; par ( maxNoOfTestCases ) { info [ true ] { v.set( execute( findServices() ) ); } mssql [ v == pass and info == true and port[1433] == open ] { v.set( execute( MSSQLPasswords() ) ); } smurf[10] [ v == pass and info == true and denialOfService == true ] { v.set( execute( smurfAttack() ) ); } else { ... } } } } module SecurityTests( integer maxNoOfTestCases, boolean denialOfService ) { function control() { var verdicttype v := pass; par ( maxNoOfTestCases ) { info [ true ] { v.set( execute( findServices() ) ); } mssql [ v == pass and info == true and port[1433] == open ] { v.set( execute( MSSQLPasswords() ) ); } smurf[10] [ v == pass and info == true and denialOfService == true ] { v.set( execute( smurfAttack() ) ); } else { ... } } } } module SecurityTests( integer maxNoOfTestCases, boolean denialOfService ) { functioncontrol() { varverdicttype v := pass; par ( maxNoOfTestCases ) { info [ true ] { v.set( execute( findServices() ) ); } mssql [ v == passandinfo == trueand port[1433] == open ] { v.set( execute( MSSQLPasswords() ) ); } smurf[10] [ v == passandinfo == trueand denialOfService == true ] { v.set( execute( smurfAttack() ) ); } else { ... } } } } module SecurityTests( integer maxNoOfTestCases, booleandenialOfService ) { function control() { var verdicttype v := pass; par ( maxNoOfTestCases ) { info [ true ] { v.set( execute( findServices() ) ); } mssql [ v == pass and info == true and port[1433] == open ] { v.set( execute( MSSQLPasswords() ) ); } smurf[10] [ v == passandinfo == trueand denialOfService == true ] { v.set( execute( smurfAttack() ) ); } else { ... } } } } Degree of concurrency Goal Prerequisite Command Repetitions Goal variable Termination

  7. Enhanced Matching Mechanisms • Powerful mechanisms can be used to describe templates for character strings • Same expressiveness as regular expressions • Less powerful mechanisms are available for structured types • * matches a sequence of zero or more elements • Goal • Provide the power of regular expressions on the level of arrays, records of, and sets of • Find a suitable, non-ambiguous notation

  8. Enhanced Matching Mechanisms Example varinteger myInt := 8; templaterecord of integer RegExp1 := { <1,2>#(2,5), 3#(,), 4, (5,6,7), myInt, ?}; Alternatives At least 2 and at most 5 occurrences of 1,2 Group

  9. ENDThank you for your attention!Any questions?

  10. Design Issues of Parallel Operator • alt-like structure • Degree of concurrency can be restricted • Execution of many identical test cases • Scheduling • non-blocked scheduler • blocked scheduler • Termination • else goal

  11. Module Concept Comparison (1) Current Style module CGIabuses{ control { . . . } } Proposed Style module CGIabuses{ functioncontrol( in integer number ) returnverdicttype { . . . } }

  12. Module Example (1) • module CGIabuses { • importfrom DenialOfService all; • functioncontrol() { • IIS(); PHP-Nuke(); • execute( IIS.ExAir.ExAirSearch() ); • } • module IIS { • functioncontrol() { • varverdicttype v; • DenialofService.IIS(); • if( execute( DangerousSampleFiles ) == pass) • v := ExAir(); • } • module ExAir { • functioncontrol() returnverdicttype { • } } } }

  13. Module Example (2) • module DenialofService { • module IIS { • functioncontrol() { • } • } • }

  14. Enhanced Matching Mechanisms • Enhanced matching mechanisms for structured types (arrays, sets, records) • x#(min,max) • matches at least min and at most max occurrences of x • < … > • Grouping of sequential elements • Description of alternatives • use existing notation for value lists

  15. Why Enhanced Matching Mechanism? • Powerful character patterns are provided for templates • For structured types less powerful matching mechanism are provided

  16. Summary & Outlook • Better module concept • A new parallel operator • New matching mechanisms for records, arrays, and sets

  17. Advantages of a Control Function • Hierarchically structured control parts • Call from detached modules • Improved Characteristics • Parameterisation • Return value

  18. Michael Ebner, University of Göttingen The TTCN-3 module and template concepts revisited Michael Schmitt, University of Trier TestCom 2003

More Related