Docsity

Secure Software Development: Risk-Based Security Testing and Quality Assurance, Slides of Software Engineering

Partial preview of the text

Download Secure Software Development: Risk-Based Security Testing and Quality Assurance and more Slides Software Engineering in PDF only on Docsity!

Secure Software Development

Risk-Based Security Testing

Application of Touchpoints

Requirement andUse cases Architectureand Design Test Plans Code (^) Test ResultsTests and Feedback fromthe Field

5. Abuse cases 6. Security Requirements 2. Risk Analysis

External Review

4. Risk-Based Security Tests 1. Code Review (Tools) 2. Risk Analysis 3. Penetration Testing 7. Security Operations

Quality Assurance

  • External quality: correctness, reliability, usability, integrity
  • Interior (engineering) quality: efficiency, testability, documentation, structure
  • Future (adaptability) quality: flexibility, reusability, maintainability

Correctness Testing

  • Black box:
    • Test data are derived from the specified functional requirements without regard to the final program structure
    • Data-driven, input/output driven, or requirements-based
    • Functional testing
    • No implementation details of the code are considered

Performance Testing

  • Goal: bottleneck identification, performance comparison and evaluation, etc.
  • Explicit or implicit requirements
  • "Performance bugs" – design problems
  • Test: usage, throughput, stimulus-response time, queue lengths, etc.
  • Resources to be tested: network bandwidth requirements, CPU cycles, disk space, disk access operations, memory usage, etc.

Reliability Testing

  • Probability of failure-free operation of a system
  • Dependable software: it does not fail in unexpected or catastrophic ways
  • Difficult to test

Risk-Based Testing

  • Identify risks
  • Create tests to address identified risks
  • Security testing vs. penetration testing
    • Level of approach
    • Timing of testing

Penetration Testing

  • Performed after the software is completed
    • Evaluate operational environment
    • Dynamic behavior
  • Outside  in activity – defending perimeters
  • Cursory

Risk Analysis

  • Design phase analysis:
    • Identify and rank risks
    • Discusses inter-component assumptions
  • Component/unit testing
    • Test for:
      • Unauthorized misuse of and access to the target assets
      • Violations of assumptions
    • Breaking system into a number of discrete parts
    • Risk can be mitigated within the bounds of contextual assumptions

System-Level Testing

  • Focus on the properties of the integrated software system
  • Penetration testing = Security testing
  • Using data flow diagrams, models, and inter- component documentations, identify - Inter-component failures - Design level security risks
  • Use misuse cases to enhance test plan

Vulnerabilities

  • Design-level
    • Hardest to detect
    • Prevalent and critical
    • Requires great expertise to detect – hard to automate
  • Implementation specific
    • Critical
    • Easier to detect – some automation

Security Testing

  • Functional security testing: testing security mechanisms for functional capabilities
  • Adversarial security testing: risk-based security testing - Understanding and simulating the attacker’s approach
  • Both approaches must be used
  • Security attacks may ignore the security mechanism to exploits of the software defects

How to Test?

  • White box analysis
    • Understanding and analyzing source code and design
    • Very effective finding programming errors
    • Can be supported by automated static analyzer
    • Disadvantage: high rate of false positives
  • Black box analysis
    • Analyze a running program
    • Probe the program with various input (malicious input)
    • No need for any code – can be tested remotely

Malicious Input

  • Software: takes input
  • Trust input?
    • Malformed or malicious input may lead to security compromise
    • What is the input?
      • Data vs. control
  • Attacker toolkit