Testing security of CPS with Formal Methods Application (in - - PowerPoint PPT Presentation

testing security of cps with formal methods
SMART_READER_LITE
LIVE PREVIEW

Testing security of CPS with Formal Methods Application (in - - PowerPoint PPT Presentation

Testing security of CPS with Formal Methods Application (in progress) to industrial protocols IoS & IoT Roland Groz, Jean-Luc Richier, Maxime Puys, Laurent Mounier Univ. Grenoble Alpes LIG/Vasco + Vrimag/PACSS Kobe Universit


slide-1
SLIDE 1

Testing security of CPS with Formal Methods Application (in progress) to industrial protocols IoS & IoT

Roland Groz, Jean-Luc Richier, Maxime Puys, Laurent Mounier

  • Univ. Grenoble Alpes

LIG/Vasco + Vérimag/PACSS

Kobe – Université Grenoble-Alpes Workshop

slide-2
SLIDE 2

Industrial systems & security

n Hot topic since Stuxnet (Iran 2009)

¨ Even military-nuclear protected industrial sites

can be damaged by cyberattacks

n ~1000 centrifuges destroyed

¨ Significant attacks (before and) after Stuxnet

n E.g.: Ukraine black out (2015), German steel plant,

Finland heating breakdown… n Protection becoming a priority for

government agencies (France: ANSSI, LPM 2013, OIV)

2

slide-3
SLIDE 3

Testing for security (LIG)

n Goal: early detection of vulnerabilities (security

flaws) in systems

n Approach: based on models, Model-Driven

Engineering (MDE) and Model Based Testing (MBT), with Formal Methods

n Main techniques:

¨ Model learning, reverse engineering ¨ Model checking and analysis ¨ Test generation, fuzzing

3

slide-4
SLIDE 4

Past and current projects

n European: Diamonds, SPaCIoS

¨ + many national projects

n Application domains:

¨ Internet of Services (web applications) ¨ Communication protocols ¨ Transport systems (automotive, aerospace,

rail)

¨ Industrial systems, CPS

4

slide-5
SLIDE 5

Industrial (&IoT) vs Business IT

n Security priorities differ from IT

¨ IT: Confidentiality > Authentication > Integrity >

Availability

¨ (Indus) Availability > Integrity > Authent. > Confid. ¨ IoT: domain dependent, e.g. Integrity > Avail. > Conf.

n Long lived, hard to patch, legacy (+Indus, -IoT) n Proprietary protocol implementations (~IoT) n Real-time n Cyber Physical Systems (physical/vital hazards)

5

slide-6
SLIDE 6

SCADA (Supervisory Control and Data Acquisition)

n SCADA controls variable Motor Status on PLC

(Programmable Logic Controller)

6

slide-7
SLIDE 7

Industrial Communication Protocols

n MODBUS (1979)

¨ Mostly read/write PLC variables (+config…) ¨ No security

n OPC-UA (2006)

¨ Open PF Communications, Unified Arch. ¨ Complex standard (978 pages) ¨ Provisions for security

n Signed or encrypted messages n OPC-UA SecureConversation (similar to TLS with

handshake)

7

slide-8
SLIDE 8

Current responses to threats

n Legal requirements on companies: risk

analysis, human and technical measures

n Zoning: Data diodes, Firewalls for ICS

protocols…

n Intrusion Detection Systems & IPS

¨ Multiple systems (cf hierarchical distributed

structure)

n Research: advanced IDS/IPS, vulnerability

detection in protocol specs & implems

8

slide-9
SLIDE 9

LIG security projects for SCADA

n ARAMIS (PIA)

¨ Isolation device (~firewall based on protocol

rupture)

n SACADE (ASTRID)

¨ SCADA platform for detecting and playing

attacks

n SRED (PIAVE)

¨ Intrusion detection for electric distribution

9

slide-10
SLIDE 10

ARAMIS security gateway

n Deep Packet Inspection n Rewriting packet contents, with protocol-specific rules n Physically separated processors

10

slide-11
SLIDE 11

SACADE

n Started 2017 n Investigating Attack scenarios against PLC n Special focus on scenarios combining

Distribution and Encapsulation:

¨ Payload recombined from multiple

encapsulated sources

11

slide-12
SLIDE 12

Focus: encapsulation+distrib

Encapsulation: Payload is legal at all levels of protocols, so espaces protocol filtering Distribution: Noxious behaviour is obtained by combining commands from several legal commands from distributed sources

slide-13
SLIDE 13

Examples of attack elements

n Playing on protocol levels

¨ Data injection to move towards dangerous

states

¨ Device reconfiguration ¨ Combining reconfiguration followed by

injection

n Timing dependence

¨ Commands sent in transient states of CPS

13

slide-14
SLIDE 14

Experimental Pla.orm (Grenoble)

Execu&on pla-orm G-ICS Hierarchical architecture model Test genera&on Security proper&es Sta&c analysis Monitor synthesis Func&onal proper&es Monitors AAack library

slide-15
SLIDE 15

Model Based analysis to detect vulnerabilities in protocol implem.

n Previous work for vulnerability detection

¨ SPaCIoS: tool box for vulnerability in IoS

(Internet of Services: Web applications),

n Based on model of cryptographic protocols +

Model-checking, model based testing, model inference…

¨ Kameleon Fuzz: smart fuzzing

n Based on protocol model and grammar

15

slide-16
SLIDE 16

SPaCIoS tool

n Modelling with

¨ ASLan++

n Models can be

retrieved

¨ From source

code (jModex)

¨ Black box

testing (SIMPA)

16

Abstract execution trace

The SPaCIoS Tool

Model

  • f the

SUV

Security Analyst

Legend :

Test Stub

System Under Validation (SUV)

Test drivers

Model inference and adjustment

Test Results

SUV source code

Vulnerabilities Attack Patterns Security Goals Attacker Models Libraries

User guidance Test case generation Model of the attacker Security goals

Model of the SUV

Property-driven and vulnerability-driven test case generation

Trace- driven fault localization Source based inference

Fault location

User interface

slide-17
SLIDE 17

Objectives Results WP 3 § Validation techniques

  • model checking
  • property-driven testing
  • vulnerability-driven testing
  • bridge components

ü Working prototypes of (and more)

  • Model inference SIMPA
  • Model extraction jModex
  • Mutation-based testing SPaCiTE
  • Instrumentation-based testing IBT
  • LTL separation for testing Fred
  • Low level attacker models Vera
  • Fuzzing KameleonFuzz & SVCov

WP 4 § SPaCIoS Tool § Validation methodology patterns

ü SPaCIoS Tool released

ü Valid. method. patterns & Tutorials

Model of the SUV Abstract execution trace Test case

The SPaCIoS Tool

Test Execution Engine

Vulnerabilities Attack Patterns Security Goals Attacker Models

User Interface

Model

  • f the

SUV Security goals User guidance

Security Analyst

Model inference and adjustment Property-driven and vulnerability-driven test case generation Libraries

Test Results

Model of the attacker Fault location SUV source code Source based inference Trace- driven fault localization

SUV Model Property Model Checker Attack trace

Real system

slide-18
SLIDE 18

26/02/18 18

  • B. Approximate

Taint Dataflow

  • taint inputs
  • infer taint in outputs
  • annotate model

C.1. Malicious Inputs Generation

  • generate inputs

C.2. Precise Taint Dataflow

  • attack successful?
  • A. Inferring

SUT state model

Evolutionary Algorithm if new page or state discovered evolve inputs

KameleonFuzz overview

D.

slide-19
SLIDE 19

Other approach: test patterns

19

slide-20
SLIDE 20

Back to SCADA & CPS security

n Weak protocols => easily found attacks n Difficulties lie in concretization

¨ Bypassing security architecture

n firewall through encapsulation & multiple interface n IDS through non monitored channels

¨ Dealing with proprietary undocumented

protocols and features

n Methods above might be too

sophisticated ?

20

slide-21
SLIDE 21

THANK YOU FOR YOUR ATTENTION.

Contact: Roland.Groz@univ-grenoble-alpes.fr Professor at Grenoble INP Ensimag

21

slide-22
SLIDE 22

BACKUP SLIDES

22

slide-23
SLIDE 23

Architecture of Industrial Control Systems

23

slide-24
SLIDE 24

24

Projet: AAP sécurité SCADA

21/10/2013 – V1

Architecture Générique SCADA à sécuriser - Draft Schéma d’aRchitecture SCADA.VSD Atos Worldgrid

Serv

Stations SCADA Clients Lourds RTU DMZ Externe DMZ Interne Relais Proxy FW VPN ERP SAP Archivage Central Boursorama Météo France

Niveau 1 Zones Automatismes Niveau 2 Zones SCADA Niveau 3 Zone Hypervision métiers

Protocoles Automates : OPC UA, Modbus TCP, protocoles spécifiques constructeur sur TCP ou UDP Flux de services administration, FTP...

Site Extérieur Entreprise

Postes Consultation Métiers

Zone Isolation « DMZ »

FW Admin / Log : Anti Viris Domaine de Confiance FW n°2 FW n°1 Serveurs de dépôt / pubication

Sites de confiance

Autres Systémes Serveurs SCADA

Salles de Commande

Concentrateur Automates Bases de Données Métier / Historian Télé Maintenance des Infrastructures Point Coupure

National Entreprise Local Entreprise

Légende RTU = Remote Transmission Unit serveur anti virus

Serv

Reduction de surface - Zoning

Serv Serv Serv

Ethernet TCP IP Automates Concentrateur / Agrégateur RTU RTU Procédés Concentrateur / Agrégateur Capteurs / Compteurs Intélligents Capteurs / compteurs Intélligents

Niveau 0 Capteurs / Actionneurs Procédés

Equipements Réseaux Switchs etc Firewall IPS/IDS – Data Diode Autre Zone Automatisme Autre SCADA Local ou Distant

Serv

SCADA Hyperviseur Administration Système / Logs / Accounta.. Reduction de surface - Zoning

Ateliers

Autres Systémes Autres Systémes Server Administration Ethernet TCP IP Ethernet TCP IP Nombreux protocoles internes SCADA Protocoles Standards : OPC UA, Autres Flux de services administration, FTP... Surveillance / corrélation événements

slide-25
SLIDE 25

ARAMIS

25

slide-26
SLIDE 26

Low-level attacker models: Vera

Attacker model library Instantiation Library Concrete Attack trace Real system

Vulnerabilities?

Model of the SUV Abstract execution trace Test case

The SPaCIoS Tool

Test Execution Engine

Vulnerabilities Attack Patterns Security Goals Attacker Models

User Interface

Model

  • f the

SUV Security goals User guidance

Security Analyst

Model inference and adjustment Property-driven and vulnerability-driven test case generation Libraries

Test Results

Model of the attacker Fault location SUV source code Source based inference Trace- driven fault localization

SUV

26

slide-27
SLIDE 27

KameleonFuzz

Inferred tainted model Attack input grammar Genetic fuzzing Real system

Vulnerabilities?

Model of the SUV Abstract execution trace Test case

The SPaCIoS Tool

Test Execution Engine

Vulnerabilities Attack Patterns Security Goals Attacker Models

User Interface

Model

  • f the

SUV Security goals User guidance

Security Analyst

Model inference and adjustment Property-driven and vulnerability-driven test case generation Libraries

Test Results

Model of the attacker Fault location SUV source code Source based inference Trace- driven fault localization

SUV

Interactions with the system 27

slide-28
SLIDE 28

26/02/18 28

  • Attack Input Grammar
  • Mutation & Crossover
  • Fitness & Test Verdict
  • B. Approximate

Taint Dataflow

  • taint inputs
  • infer taint in outputs
  • annotate model

C.1. Malicious Inputs Generation

  • generate inputs

C.2. Precise Taint Dataflow

  • attack successful?
  • A. Inferring

SUT state model

Evolutionary Algorithm if new page or state discovered evolve inputs

  • C. Evolutionary Fuzzing

D.

slide-29
SLIDE 29

Attack Input Grammar

26/02/18 29

Payloads production rules

several realistic payloads

anti-filters production rules

considered SUT filters

Attack Input Grammar

browser specific string transformations

Sets of Attack Vectors (evtly structured)

hacker sources (Shazzer ..)

slide-30
SLIDE 30

Mutation (at input param. value)

26/02/18 30

slide-31
SLIDE 31

Crossover (at input param. value)

26/02/18 31

slide-32
SLIDE 32

Other approach: test patterns

n Developed by FEMTO-ST & Smartesting

(Besançon)

n Based on CertifyIt tool n « High level » test patterns based on

¨ Expert knowledge ¨ Known high level vulnerability classes ¨ Tool uses TP to guide symbolic exploration of model ¨ Unfolding of patterns based on constraint solving

32

slide-33
SLIDE 33

Language for security properties

n TOCL: Temporal OCL (Dwyer99, patterns) n TOCL property = Pattern+Scope n Pattern: event ordering

¨ (always, never, eventually k times, precedes, follows)

n Scope: restricts pattern to interval

¨ (globally, between, after, before)

33