Research Article
A Minimum Defense Cost Calculation Method for Attack Defense Trees
Algorithm 2
Calculation of the minimum defense cost of ADTrees.
| Input A2DTree | | Output The minimum defense cost of the A2DTree and the set of attack nodes that need to be defended | (1) | BooleanExpression: = A2DTree logical expression; | (2) | PathSets: = {All simple conjunctions in BooleanExpression, that is, the set of all path sets of the A2DTree}; | (3) | MinCost: = ; | (4) | PathSet: = {}; | (5) | j: = 1; | (6) | repeat | (7) | pathset: = jth path set in PathSets; | (8) | cur_cost:= Cut-set defense cost; | (9) | if cur_cost < MinCost | (10) | then | (11) | MinCost: = cur_cost; | (12) | PathSet: = pathset; | (13) | end if | (14) | j: = j + 1; | (15) | until j = Number of subsets in PathSets +1; |
|