a choreography driven approach to apis the opendxl case
play

A Choreography-Driven Approach to APIs: The OpenDXL Case Study - PowerPoint PPT Presentation

A Choreography-Driven Approach to APIs: The OpenDXL Case Study Leonardo Frittelli @ McAfee, Cordoba, AR Facundo Maldonado @ McAfee, Cordoba, AR Hern an Melgratti @ UBA, AR Emilio Tuosto @ GSSI, IT & UoL, UK Coordination 2020 15-20 July


  1. A Choreography-Driven Approach to APIs: The OpenDXL Case Study Leonardo Frittelli @ McAfee, Cordoba, AR Facundo Maldonado @ McAfee, Cordoba, AR Hern´ an Melgratti @ UBA, AR Emilio Tuosto @ GSSI, IT & UoL, UK Coordination 2020 15-20 July 2020 Research partly supported by the EU H2020 RISE programme under the Marie Sk� lodowska-Curie grant agreement No 778233.

  2. Prelude

  3. A fairy tale (pictures from Matteo Garrone’s “Pinocchio”) Tell them...

  4. A fairy tale (pictures from Matteo Garrone’s “Pinocchio”) and they’ll behave

  5. A fairy tale (pictures from Matteo Garrone’s “Pinocchio”) unless they don’t

  6. A fairy tale (pictures from Matteo Garrone’s “Pinocchio”) So, keep an eye on’em

  7. A fairy tale (pictures from Matteo Garrone’s “Pinocchio”) of course, it’s for their own good

  8. At a glance API-based development difficult in theory... ...and in practice BehAPI Behavioural specification of APIs can help document monitor Case study: OpenDXL

  9. Managing expectations This work reports on a collaboration with industry uses existing behavioural types proposes a methodology strives to be easily usable by non-experts to attain practical benefits

  10. Managing expectations This work reports on a collaboration with industry uses existing behavioural types proposes a methodology strives to be easily usable by non-experts to attain practical benefits No new technical contributions

  11. OpenDXL & Threat Intelligence Exchange

  12. Open Data Exchange Layer

  13. Architecture of OpenDXL Env C S Env C B S Env S C B Brokers abstracted away

  14. Architecture of OpenDXL Env C S Env C S Env S C Brokers abstracted away Event-based communication

  15. Architecture of OpenDXL Env C S Env C S Env check S C Brokers abstracted away Event-based communication

  16. Architecture of OpenDXL Env C S r e s Env res C S res Env res S C Brokers abstracted away Event-based communication

  17. An instance of OpenDXL services TIE’s features coordination of activities involving assessment of the security threats of configuration files, certificates, unsigned or unknown files, etc. prioritisation of analysis steps focusing on malicious or unknown files customisation of security queries based on reputation-based data such as product or company names reaction to suspicious indicators

  18. Documenting TIE Semi-formal diagrams Verbal recommendations a client “must have permission to send messages to the /mcafee/service/tie/reputation/set topic”

  19. Sounds good...in theory In practice “Stuff” developed @McAfee works fine McAfee provides the service and clients but it’s a SOA: 3 rd -party clients misbehave sometimes hence, defensive programming of TIE services

  20. Sounds good...in theory In practice “Stuff” developed @McAfee works fine McAfee provides the service and clients but it’s a SOA: 3 rd -party clients misbehave sometimes hence, defensive programming of TIE services Caveat 3 rd -party code may not be available for analysis Hence, post-mortem analysis of execution logs to identify misbehaviour and communicate it to 3 rd -parties

  21. A methodology

  22. Idea Adding more precision: 1 draw the protocol (global choreography) 2 turn the “drawing” into a behavioural type 3 project to component specs (local types) 4 turn local specs into state machines Advantages global choreographies: formal & precise (Pomset or Event Structure semantics a ), yet intuitive algorithmically generate monitors enhance “program comprehension” a See Ugo de’Liguoro’s talk @ ICE 2020

  23. Let’s tie our TIE After a couple of meetings... � + C − → S: Req(x) + C − → S: MD(x) S − → C: Res tt (x) S − → C: Res ft (x) S − → C: Res tf (x) S − → C: Res ff (x) C − → S: MD(x) C − → S: File(x) C − → S: MD(x) C − → S: File(x) + + K NR �

  24. Let’s tie our TIE After a couple of meetings... C sends meta-data � + C − → S: Req(x) + C − → S: MD(x) S − → C: Res tt (x) S − → C: Res ft (x) S − → C: Res tf (x) S − → C: Res ff (x) C − → S: MD(x) C − → S: File(x) C − → S: MD(x) C − → S: File(x) + + K NR �

  25. Let’s tie our TIE After a couple of meetings... � C requests an assessment + C − → S: Req(x) + C − → S: MD(x) S − → C: Res tt (x) S − → C: Res ft (x) S − → C: Res tf (x) S − → C: Res ff (x) C − → S: MD(x) C − → S: File(x) C − → S: MD(x) C − → S: File(x) + + K NR �

  26. Let’s tie our TIE After a couple of meetings... � + C − → S: Req(x) nested choice + C − → S: MD(x) S − → C: Res tt (x) S − → C: Res ft (x) S − → C: Res tf (x) S − → C: Res ff (x) C − → S: MD(x) C − → S: File(x) C − → S: MD(x) C − → S: File(x) + + K NR �

  27. Let’s tie our TIE After a couple of meetings... � + C − → S: Req(x) + C − → S: MD(x) S − → C: Res tt (x) S − → C: Res ft (x) S − → C: Res tf (x) S − → C: Res ff (x) C − → S: MD(x) C − → S: File(x) C − → S: MD(x) C − → S: File(x) + + K NR S publishes a new report �

  28. Let’s tie our TIE After a couple of meetings... � + C − → S: Req(x) + C − → S: MD(x) S − → C: Res tt (x) S − → C: Res ft (x) S − → C: Res tf (x) S − → C: Res ff (x) C − → S: MD(x) C − → S: File(x) C − → S: MD(x) C − → S: File(x) + + K NR � DISCLAIMER No greek letters were used in the making of this global view

  29. If you’re versed in behavioural types Behavioural types Suitable devices for specification and analysis focus on control (mostly) assume point-to-point channels

  30. If you’re versed in behavioural types Behavioural types Suitable devices for specification and analysis focus on control (mostly) assume point-to-point channels vs Klaimographies Behavioural types with focus on data (mostly) interactions based on generative communication unit & multi-roles

  31. Monitors from projections UML-like @startuml left to right direction [*] --> S0 S0 --> S0: ’MD’ @l @Dgt S0 --> S1: ’Req’@l S1 --> S2: (’Res’, ’1’, ’1’)@l -> @Dgt S1 --> S3: (’Res’, ’0’, ’1’)@l -> @Dgt S1 --> S4: (’Res’, ’1’, ’0’)@l -> @Dgt S1 --> S0: (’Res’, ’0’, ’0’)@l S2 --> S3: ’MD’@l -> @Dgt S3 --> S0: ’File’@f S4 --> S0: ’MD’@l @enduml Transformation Manual (for now) but algorithmic ’@...’ for data-flow analysis huge logs (can’t fit memory) Monitor checks expected data correspondences (e.g., ’file’ corresponds to a ’file req’)

  32. Lessons learned

  33. Effectiveness & Reproducibility (of (meta-)communication) non-deterministic & visual abstractions help communication among stakeholders provide insights & “inspirations” but semantics is necessary to attain precision to change mind a reviewer was “missing the difficulties in this formalisation”

  34. Generality how tight to TIE are we? klaimographies were not designed for OpenDXL a reviewer noted: “event-based middleware are becoming the norm” choreography can go bottom-up (as noted by another reviewer)

  35. Other FM? Sure / but ... Model checking but it is not easy for lay-users to express properties in some temporal logic Other behavioural types usually too many greek letters Other FM (Petri nets, event structures,...) too low level (and (sadly) not much studied anymore)

  36. What’s next? Tool support (extend ChorGram ) validated global views ensure properties automatise projections code generation (eg TIE vs many versions/variants) Extend the application to other services of TIE / OpenDXL Klaimographies-inspired abstractions for CAS

  37. Thank you and to the anonymous reviewers!

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend