Skip to content

Commit

Permalink
update supporting all string-based serialization for experiment defin…
Browse files Browse the repository at this point in the history
…ition
  • Loading branch information
dmnTools committed Dec 20, 2024
1 parent ca147dd commit f5dc647
Show file tree
Hide file tree
Showing 11 changed files with 74 additions and 59 deletions.
49 changes: 25 additions & 24 deletions embedded/template/cpInit.yaml
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
dictname: exampleName
dictname: embedded
initlist:
Crypto:
cfg:
cryptoProcess: '{"timingcode": {}, "directprefix": ["encrypt", "decrypt"], "trace":
0, "msg2mc": {}}'
"0", "msg2mc": {}}'
cptype: Crypto
msgs: []
name: Crypto
useyaml: true
Embedded:
cfg:
embeddedProcess: '{"timingcode": {"process": "packet-process"}, "accelname":
"", "trace": 0, "msg2mc": {}, "msg2msg": {}}'
reqDecrypt: '{"bypass": 0, "trace": 0, "srvCP": "Crypto", "srvLabel": "cryptoProcess",
"srvOp": "decrypt-$crypto", "rspOp": "", "msg2mc": {"*": "default"}, "msg2msg":
{}}'
reqEncrypt: '{"bypass": 0, "trace": 0, "srvCP": "Crypto", "srvLabel": "cryptoProcess",
"srvOp": "encrypt-$crypto", "rspOp": "", "msg2mc": {"*": "default"}, "msg2msg":
{}}'
validateSrc: '{"bypass": 0, "trace": 0, "srvCP": "", "srvLabel": "", "srvOp":
"auth", "rspOp": "", "msg2mc": {"*": "default"}, "msg2msg": {}}'
"", "trace": "0", "msg2mc": {}, "msg2msg": {}}'
reqDecrypt: '{"bypass": "$bypass", "trace": "0", "srvCP": "Crypto", "srvLabel":
"cryptoProcess", "srvOp": "decrypt-$crypto", "rspOp": "", "msg2mc": {"*":
"default"}, "msg2msg": {}}'
reqEncrypt: '{"bypass": "$bypass", "trace": "0", "srvCP": "Crypto", "srvLabel":
"cryptoProcess", "srvOp": "encrypt-$crypto", "rspOp": "", "msg2mc": {"*":
"default"}, "msg2msg": {}}'
validateSrc: '{"bypass": "$bypass", "trace": "0", "srvCP": "", "srvLabel": "",
"srvOp": "auth", "rspOp": "", "msg2mc": {"*": "default"}, "msg2msg": {}}'
cptype: Embedded
msgs:
- ispckt: true
Expand All @@ -35,29 +35,30 @@ initlist:
EmbeddedAuth:
cfg:
authenticate: '{"timingcode": {"auth": "authenticate"}, "directprefix": [],
"trace": 0, "msg2mc": {}}'
"trace": "0", "msg2mc": {}}'
cptype: EmbeddedAuth
msgs: []
name: EmbeddedAuth
useyaml: true
HMI:
cfg:
accelDecrypt: '{"timingcode": {"decrypt": "decrypt-$crypto"}, "accelname": "hmiAccel",
"trace": 1, "msg2mc": {}, "msg2msg": {}}'
"trace": "1", "msg2mc": {}, "msg2msg": {}}'
accelEncrypt: '{"timingcode": {"encrypt": "encrypt-$crypto"}, "accelname": "hmiAccel",
"trace": 1, "msg2mc": {}, "msg2msg": {}}'
endMeasure: '{"msrname": "end2end", "msrop": "end", "trace": 0, "msg2mc": {}}'
endThread: '{"trace": 0, "msg2mc": {"finish": "default"}}'
"trace": "1", "msg2mc": {}, "msg2msg": {}}'
endMeasure: '{"msrname": "end2end", "msrop": "end", "trace": "0", "msg2mc":
{}}'
endThread: '{"trace": "0", "msg2mc": {"finish": "default"}}'
generatePckt: '{"timingcode": {"generate": "packet-generation"}, "accelname":
"", "trace": 1, "msg2mc": {}, "msg2msg": {}}'
"", "trace": "1", "msg2mc": {}, "msg2msg": {}}'
processRtn: '{"timingcode": {"process": "packet-return"}, "accelname": "", "trace":
0, "msg2mc": {}, "msg2msg": {}}'
startMeasure: '{"msrname": "end2end", "msrop": "start", "trace": 0, "msg2mc":
"0", "msg2mc": {}, "msg2msg": {}}'
startMeasure: '{"msrname": "end2end", "msrop": "start", "trace": "0", "msg2mc":
{}}'
startThread: '{"pcktlen": 1000, "msglen": 1500, "msgtype": "measure", "starttime":
10.0, "data": "", "trace": 0}'
validateSrc: '{"bypass": 0, "trace": 0, "srvCP": "", "srvLabel": "", "srvOp":
"auth", "rspOp": "", "msg2mc": {"*": "default"}, "msg2msg": {}}'
startThread: '{"pcktlen": "1000", "msglen": "1500", "msgtype": "measure", "starttime":
"10", "data": "", "trace": "0"}'
validateSrc: '{"bypass": "$bypass", "trace": "0", "srvCP": "", "srvLabel": "",
"srvOp": "auth", "rspOp": "", "msg2mc": {"*": "default"}, "msg2msg": {}}'
cptype: HMI
msgs:
- ispckt: true
Expand All @@ -79,7 +80,7 @@ initlist:
HMIAuth:
cfg:
authenticate: '{"timingcode": {"auth": "authenticate"}, "directprefix": [],
"trace": 0, "msg2mc": {}}'
"trace": "0", "msg2mc": {}}'
cptype: HMIAuth
msgs: []
name: HMIAuth
Expand Down
2 changes: 1 addition & 1 deletion embedded/template/devExec.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
listname: exampleName
listname: embedded
times:
switch:
- devop: switch
Expand Down
14 changes: 7 additions & 7 deletions embedded/template/exp.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
expname: exampleName
expname: embedded
parameters:
- attributes:
- attrbname: name
Expand All @@ -23,22 +23,22 @@ parameters:
attrbvalue: central
param: trace
paramObj: Network
value: 0
value: '0'
- attributes:
- attrbname: '*'
attrbvalue: 1
attrbvalue: '1'
param: latency
paramObj: Interface
value: 5e-06
- attributes:
- attrbname: '*'
attrbvalue: 1
attrbvalue: '1'
param: bandwidth
paramObj: Interface
value: $bndwidth
value: $bndwdth
- attributes:
- attrbname: '*'
attrbvalue: 1
attrbvalue: '1'
param: trace
paramObj: Interface
value: 0
value: '0'
20 changes: 20 additions & 0 deletions embedded/template/experiments.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,32 @@
- $bndwdth,netParams: '1000'
$bypass,cp: '0'
$crypto,cp: AES-256-CBC
name: exp-1
- $bndwdth,netParams: '10'
$bypass,cp: '0'
$crypto,cp: AES-256-CBC
name: exp-2
- $bndwdth,netParams: '1000'
$bypass,cp: '0'
$crypto,cp: AES-128-CBC
name: exp-3
- $bndwdth,netParams: '10'
$bypass,cp: '0'
$crypto,cp: AES-128-CBC
name: exp-4
- $bndwdth,netParams: '1000'
$bypass,cp: '1'
$crypto,cp: AES-256-CBC
name: exp-5
- $bndwdth,netParams: '10'
$bypass,cp: '1'
$crypto,cp: AES-256-CBC
name: exp-6
- $bndwdth,netParams: '1000'
$bypass,cp: '1'
$crypto,cp: AES-128-CBC
name: exp-7
- $bndwdth,netParams: '10'
$bypass,cp: '1'
$crypto,cp: AES-128-CBC
name: exp-8
2 changes: 1 addition & 1 deletion embedded/template/funcExec.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
listname: exampleName
listname: embedded
times:
authenticate:
- cpumodel: AMD EPYC 9534 64-Core Processor
Expand Down
2 changes: 1 addition & 1 deletion embedded/template/map.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
dictname: exampleName
dictname: embedded
map:
Crypto:
funcmap:
Expand Down
8 changes: 1 addition & 7 deletions embedded/template/topo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ endpts:
- cable: intrfc@hub-hmiDev
carry: []
device: hmiDev
devname: hmiDev
devtype: Endpt
faces: central
groups: []
Expand All @@ -23,7 +22,6 @@ endpts:
- cable: intrfc@hub-embeddedDev
carry: []
device: embeddedDev
devname: embeddedDev
devtype: Endpt
faces: central
groups: []
Expand All @@ -39,7 +37,6 @@ endpts:
- cable: intrfc@hub-sslDev
carry: []
device: sslDev
devname: sslDev
devtype: Endpt
faces: central
groups: []
Expand All @@ -48,7 +45,7 @@ endpts:
wireless: []
model: AMD EPYC 9534 64-Core Processor
name: sslDev
name: exampleName
name: embedded
networks:
- endpts:
- hmiDev
Expand All @@ -68,7 +65,6 @@ switches:
- cable: intrfc@hmiDev-hub
carry: []
device: hub
devname: hub
devtype: Switch
faces: central
groups: []
Expand All @@ -78,7 +74,6 @@ switches:
- cable: intrfc@sslDev-hub
carry: []
device: hub
devname: hub
devtype: Switch
faces: central
groups: []
Expand All @@ -88,7 +83,6 @@ switches:
- cable: intrfc@embeddedDev-hub
carry: []
device: hub
devname: hub
devtype: Switch
faces: central
groups: []
Expand Down
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ go 1.22.7
require (
github.com/iti/evt/evtm v0.1.4
github.com/iti/evt/vrtime v0.1.5
github.com/iti/pces v0.0.17
github.com/iti/pces v0.0.19
)

require (
github.com/iti/cmdline v0.1.1 // indirect
github.com/iti/evt/evtq v0.1.4 // indirect
github.com/iti/mrnes v0.0.16 // indirect
github.com/iti/mrnes v0.0.17 // indirect
github.com/iti/rngstream v0.2.2 // indirect
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c // indirect
golang.org/x/exp v0.0.0-20241217172543-b2144cdd0a67 // indirect
gonum.org/v1/gonum v0.15.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
12 changes: 6 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ github.com/iti/evt/evtq v0.1.4 h1:cLkfhqiCRUSeiDVN/YN2ZC2L1mznL9n5o9CFKt/pwkc=
github.com/iti/evt/evtq v0.1.4/go.mod h1:85Zm3A+dgRd72YV8DS2VoNExUCt3Ckq2GqYnI4oqlBY=
github.com/iti/evt/vrtime v0.1.5 h1:5d2O3ZGb9OruBkBxZ1PzyXBlHkAUmW27jz9fUXHc6MI=
github.com/iti/evt/vrtime v0.1.5/go.mod h1:NtgQQ20CSeaLxWNsAROKuHtAdeXNZ86Wg6ox2l5LtrU=
github.com/iti/mrnes v0.0.16 h1:TiyBzSFo4teG0EvKjbdOPHhvC6HywDmGmVRRtD06wkI=
github.com/iti/mrnes v0.0.16/go.mod h1:1P8kC384qaei5i84ZK42VYDrXmRLiYZHmx52yeLL37E=
github.com/iti/pces v0.0.17 h1:lvKIPrlzTHesEJDO6QeCv9vwjXqvN5+3gkXMI/cn+zo=
github.com/iti/pces v0.0.17/go.mod h1:puOlSzKF8W6wXiK6IwSGOjR7S3gGGKpC0fn9JjakXeA=
github.com/iti/mrnes v0.0.17 h1:0OAg0M+XTuiX65DN2rhk7c5sbsmuEu1SBjakpbMPtCw=
github.com/iti/mrnes v0.0.17/go.mod h1:1P8kC384qaei5i84ZK42VYDrXmRLiYZHmx52yeLL37E=
github.com/iti/pces v0.0.19 h1:1kTDa8SCisJS+aap13/S5O3nkKvtsV5cf7hCpfqBCFg=
github.com/iti/pces v0.0.19/go.mod h1:MokpQUKXx3cRfPAOyV5/Q00Px8ziLkUuM+CPXupAHqM=
github.com/iti/rngstream v0.2.2 h1:9cfSikwWPW1Yie+RjdJ23uUuMryLu+Ou38/TChYLPZ8=
github.com/iti/rngstream v0.2.2/go.mod h1:sf9vdWtEjVW4dxOocgIqbivkNIrfcl10H8jEeeqFNnQ=
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c h1:7dEasQXItcW1xKJ2+gg5VOiBnqWrJc+rq0DPKyvvdbY=
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c/go.mod h1:NQtJDoLvd6faHhE7m4T/1IY708gDefGGjR/iUW8yQQ8=
golang.org/x/exp v0.0.0-20241217172543-b2144cdd0a67 h1:1UoZQm6f0P/ZO0w1Ri+f+ifG/gXhegadRdwBIXEFWDo=
golang.org/x/exp v0.0.0-20241217172543-b2144cdd0a67/go.mod h1:qj5a5QZpwLU2NLQudwIN5koi3beDhSAlJwa67PuM98c=
gonum.org/v1/gonum v0.15.1 h1:FNy7N6OUZVUaWG9pTiD+jlhdQ3lMP+/LcTpJ6+a8sQ0=
gonum.org/v1/gonum v0.15.1/go.mod h1:eZTZuRFrzu5pcyjN5wJhcIhnUdNijYxX1T2IcrOGY0o=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
Expand Down
6 changes: 3 additions & 3 deletions simulator/sim-dir/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ go 1.22.7
require (
github.com/iti/evt/evtm v0.1.4
github.com/iti/evt/vrtime v0.1.5
github.com/iti/pces v0.0.17
github.com/iti/pces v0.0.19
)

require (
github.com/iti/cmdline v0.1.1 // indirect
github.com/iti/evt/evtq v0.1.4 // indirect
github.com/iti/mrnes v0.0.16 // indirect
github.com/iti/mrnes v0.0.17 // indirect
github.com/iti/rngstream v0.2.2 // indirect
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c // indirect
golang.org/x/exp v0.0.0-20241217172543-b2144cdd0a67 // indirect
gonum.org/v1/gonum v0.15.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
12 changes: 6 additions & 6 deletions simulator/sim-dir/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ github.com/iti/evt/evtq v0.1.4 h1:cLkfhqiCRUSeiDVN/YN2ZC2L1mznL9n5o9CFKt/pwkc=
github.com/iti/evt/evtq v0.1.4/go.mod h1:85Zm3A+dgRd72YV8DS2VoNExUCt3Ckq2GqYnI4oqlBY=
github.com/iti/evt/vrtime v0.1.5 h1:5d2O3ZGb9OruBkBxZ1PzyXBlHkAUmW27jz9fUXHc6MI=
github.com/iti/evt/vrtime v0.1.5/go.mod h1:NtgQQ20CSeaLxWNsAROKuHtAdeXNZ86Wg6ox2l5LtrU=
github.com/iti/mrnes v0.0.16 h1:TiyBzSFo4teG0EvKjbdOPHhvC6HywDmGmVRRtD06wkI=
github.com/iti/mrnes v0.0.16/go.mod h1:1P8kC384qaei5i84ZK42VYDrXmRLiYZHmx52yeLL37E=
github.com/iti/pces v0.0.17 h1:lvKIPrlzTHesEJDO6QeCv9vwjXqvN5+3gkXMI/cn+zo=
github.com/iti/pces v0.0.17/go.mod h1:puOlSzKF8W6wXiK6IwSGOjR7S3gGGKpC0fn9JjakXeA=
github.com/iti/mrnes v0.0.17 h1:0OAg0M+XTuiX65DN2rhk7c5sbsmuEu1SBjakpbMPtCw=
github.com/iti/mrnes v0.0.17/go.mod h1:1P8kC384qaei5i84ZK42VYDrXmRLiYZHmx52yeLL37E=
github.com/iti/pces v0.0.19 h1:1kTDa8SCisJS+aap13/S5O3nkKvtsV5cf7hCpfqBCFg=
github.com/iti/pces v0.0.19/go.mod h1:MokpQUKXx3cRfPAOyV5/Q00Px8ziLkUuM+CPXupAHqM=
github.com/iti/rngstream v0.2.2 h1:9cfSikwWPW1Yie+RjdJ23uUuMryLu+Ou38/TChYLPZ8=
github.com/iti/rngstream v0.2.2/go.mod h1:sf9vdWtEjVW4dxOocgIqbivkNIrfcl10H8jEeeqFNnQ=
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c h1:7dEasQXItcW1xKJ2+gg5VOiBnqWrJc+rq0DPKyvvdbY=
golang.org/x/exp v0.0.0-20241009180824-f66d83c29e7c/go.mod h1:NQtJDoLvd6faHhE7m4T/1IY708gDefGGjR/iUW8yQQ8=
golang.org/x/exp v0.0.0-20241217172543-b2144cdd0a67 h1:1UoZQm6f0P/ZO0w1Ri+f+ifG/gXhegadRdwBIXEFWDo=
golang.org/x/exp v0.0.0-20241217172543-b2144cdd0a67/go.mod h1:qj5a5QZpwLU2NLQudwIN5koi3beDhSAlJwa67PuM98c=
gonum.org/v1/gonum v0.15.1 h1:FNy7N6OUZVUaWG9pTiD+jlhdQ3lMP+/LcTpJ6+a8sQ0=
gonum.org/v1/gonum v0.15.1/go.mod h1:eZTZuRFrzu5pcyjN5wJhcIhnUdNijYxX1T2IcrOGY0o=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
Expand Down

0 comments on commit f5dc647

Please sign in to comment.