Advanced concepts in SPARTA

This section explains the full SPARTA meta-model. These concepts are mainly relevant if you are programmatically processing models.

SPARTA DFD Meta-Model

SPARTA DFD Meta-Model

The diagram depicts the SPARTA DFD Meta-Model concepts.

DFDModel

The DFDModel is the root element of a SPARTA DFD Model. It can contain any amount of DFDModelElements.

DFDModelElement

Represents an element that can be contained in the DFDModel. It contains a name and a description. Since a DFDModel is also a DFDModelElement it also has a name and a description.

Asset

An Asset is a type of DFDModelElement which contains one or more Estimates to specify its value. This can be used by risk calculation methods do determine the loss. It is possible with a map, to specify different Estimates for different ThreatTypes.

Example

For example, if the loss for an information disclosure threat is different from the loss for a denial of service threat.

Note

If the relevant threat type does not occur in the map, the first estimate in the list is used.

DFDElement

A DFDElement is a special type of asset which captures shared properties for the system model.

Example

For example, it contains a list of DFDElementAnnotations to enable the attachment of arbitrary information by implementing this DFDElementAnnotation interface.

DFDContainer

A DFDContainer is a DFDElement that can contain other DFDElements. This can be used to express both decompositions (e.g., decomposing a process into subprocesses to include additional detail) and other concepts such as trust boundaries which contain elements.

DataFlowEntity

A DataFlowEntity is an element that can send or receive information. I.e. an element that can be attached to a DataFlow. It contains the common types: Process, DataStore, and ExternalEntity.

DFDBoundaryElement

Is used for expressing containers that delineate a boundary such as a TrustBoundaryContainer.

FlowElement

The FlowElement is used to express DataFlows between elements. The structure in the meta-model enables the specification of a new final recipient or sender of a dataflow when one of the connected elements, such as a process, is decomposed and you want to express to which sub-element the flow goes.

Example

Starting from a simple DataFlow between Process A and B. You may want to decompose Process B into B1 and B2. In this case, it’s unclear to which subprocess of B the data goes. The SenderSpecification or RecipientSpecification enable the inclusion of this information. In this example, the dataflow contains a RecipientSpecification expressing that the final destination is the process B1. This can be applied recursively as subprocesses are further decomposed as well.

        flowchart LR
    pa((A)) --> df
    df --> pb((B))
    
        flowchart LR
    pa((A)) --> df
    subgraph sp [B]
    pb1((B1)) --> pb2((B2))
    end
    df --> sp
    df -- RecSpec --> pb1
    

SPARTA Resources Meta-Model

SPARTA Resources Meta-Model

This diagram illustrates how a DFDModel can link to other relevant resources such as SolutionTypeCatalogs, ThreatTypeCatalogs, etc.

SpartaResource

Any type of resource relevant for a DFDModel. Can be subclassed when developing extensions.

SolutionTypeCatalog

The SolutionTypeCatalog is used to capture a set of reusable security and privacy solutions to apply a different DFDModels.

ThreatTypeCatalog

The ThreatTypeCatalog contains all the threat types, the SPARTA threat elicitation engine will look for in a concrete model.

Note

A DFDModel does not have to contain any resources, but in order to elicit threats with SPARTA, a ThreatTypeCatalog has to be provided to tell SPARTA which types of threats to look for (and how to look for them).

ThreatSpecificationCatalog

The ThreatSpecificationCatalog is an optional resource which enables making modifications to the ThreatTypeCatalog without actually changing the ThreatTypeCatalog itself as it may be used in multiple different DFDModels.

Example

For example, the ThreatSpecificationCatalog can be used to toggle off specific threat types if they are deemed to be irrelevant in the context of a specific DFDModel.

AttackerModel

The AttackerModel resource contains the set of attacker profiles that are taken into account during the threat elicitation. The capability of the attacker profiles expressed in the AttackerModel are used to compare against the strength of security and privacy solutions in the SolutionTypeCatalog to determine how vulnerable the system is to certain type of attacker by assessing how well a solution protects against that type of attacker.

SPARTA Solution Meta-Model

SPARTA Solution Meta-Model

This diagram illustrates how solutions types and concrete solutions are represented in SPARTA.

SolutionType

The SolutionType is used to represent solutions in a reusable way to enable their application in multiple DFDModels.

Role

Roles are used to represents parts of a solution that are fulfilled by concrete elements in a DFD. The bindingType expresses constraints on which concrete DFD elements could fulfil the role. For example, a service role that will have to be filled in by an ExternalEntity or storage role that has to be filled in by a DataStore.

CounterMeasure

CounterMeasures are used to represent the security or privacy effects of a solution by indicating that they mitigate one or more threat types. They use Roles to express which elements are affected by the countermeasure and to limit the scope of the effect.

Example

SSL/TLS in a web context prevents spoofing of website (the server role in the solution), but only for those SSL/TLS data flows (expressed by the corresponding roles). Other communication with the server process is not protected.

Solution

A Solution represents a concrete instance in a concrete DFDModel.

RoleBinding

Every concrete Solution has a set of RoleBindings, these link the Roles from the SolutionType to concrete DFD elements, such as a process or a data flow.

SPARTA Threat Type Meta-Model

SPARTA Threat Type Meta-Model

This diagram illustrates how ThreatTypes and ThreatSpecifications are modelled.

AbstractThreatType

Threat types in SPARTA are implemented using a composite. structure, thereby allowing threats to be decomposed and structured like trees. The AbstractThreatType class serves as a parent to all threat types and contains shared properties and logic.

ThreatType

A simple, leaf threat type which has no children.

CompositeThreatType

A threat type composed of other threat types.

ThreatTypeCatalog

This catalog contains the threat types that have to be elicited.

ThreatSpecificationCatalog

This catalog contains the ThreatSpecifications to overrule specific threat types in a concrete model.

ThreatType & ThreatSpecification

The threat type represent the actual types that are used for the threat elicitation. ThreatSpecifications are used to overrule a threat type (for example, disabling a certain threat type without modifying the threat type catalog). To determine when the threats should be elicited a list of patterns is specified for every threat type. The syntax is explained below.

Threat Type Pattern Syntax

Every threat type that needs to be elicited contains a list of DFD element patterns to elicit. This syntax is as follows: [ElementType][To/Through][ElementType], with a * after one of the three parts to indicate the location of the threat. For example, a threat for a data flow through a trust boundary from an External Entity to a process at, respectively, the sending, data flow, or receiving side is expressed as:

ExternalEntity*ThroughProcess
ExternalEntityThrough*Process
ExternalEntityThroughProcess*

When the trustboundary does not matter:

ExternalEntity*ToProcess
ExternalEntityTo*Process
ExternalEntityToProcess*

Any other combination of element types can be used:

Process*ToProcess
ProcessThrough*DataStore
DataStore*ToProcess

While invalid combinations can also be specified, these will, in correctly constructed DFDs, not yield any threats:

DataStore*ToDataStore

When there are no restrictions on the element type and the threat is positioned at the flow, just [DataFlow/DataFlowThrough] can be used.

SPARTA Attacker Meta-Model

SPARTA Attacker Meta-Model

This diagram illustrates how AttackerProfiles are modelled.

AttackerModel

The attacker model contains a set of AttackerProfiles.

AttackerProfile

An AttackerProfile represents a specific type of attacker, with a certain capability, probability of action and context frequency. To express insiders that are able to bypass certain countermeasures, an AttackerProfile contains an insider list of DFDElements on which countermeasures from security or privacy solutions could be bypassed.