Floods cross the backbone to their victim again, whatever order the POPs were built in
Each ingress slice gave its junk the ingress city as source, so a flood only filled the port it came in on: it never loaded the backbone or the victim's router, as it did before distributed ingress. Junk is now created at the victim, pinned to its entry port, before any real traffic and in attack order, so S.pops order no longer decides who gets a full port. A port the victim cannot reach still fills.
This commit is contained in:
parent
6d839102b5
commit
675c63d561
2 changed files with 36 additions and 8 deletions
|
|
@ -15,3 +15,26 @@ test('a flood entering over a PNI with NetChill competes on that PNI at its own
|
|||
assert.deepEqual(errors, []);
|
||||
}
|
||||
});
|
||||
|
||||
// Frankfurt has the eyeballs and no transit; all transit is in Amsterdam, 100G of wave away.
|
||||
const remoteIngress = (ev, flip) => {
|
||||
ev("ACT.start({});S.cash=1e9;S.nextFail=1e9;S.nextEvent=1e9;ACT.buildPop({city:'ams'});ACT.launchBB({city:'fra'});S.links.push({id:'L',a:'fra',b:'ams',kind:'wave',tier:1,km:400,mo:1,cut:0});ACT.buyTransit({city:'ams',net:NETS.find(n=>sellsAt(n,'ams')).id,tier:1})");
|
||||
if (flip) ev("const p=S.pops;S.pops={ams:p.ams,fra:p.fra}");
|
||||
ev("compute()");
|
||||
};
|
||||
|
||||
test('a flood entering in another city crosses the backbone to its victim, whatever order the POPs were built in', () => {
|
||||
const out = [];
|
||||
for (const flip of [false, true]) {
|
||||
const { ev, errors } = load({ seed: 5 });
|
||||
remoteIngress(ev, flip);
|
||||
assert.ok(ev("sfOf(R,'fra')") > 0.95, 'fine before the attack');
|
||||
ev("S.day=60;S.ev.ddos={id:'a',city:'fra',vec:'http',gbps:300,start:S.day,until:S.day+3,entry:{k:'distributed',lab:''},entries:[{k:'t',id:S.transit[0].id,city:'ams',share:1}]};compute()");
|
||||
assert.equal(ev('R.load.L'), 100, 'the junk fills the wave to the victim');
|
||||
assert.ok(ev("R.nodeLoad.fra") >= 100, "and the victim's router");
|
||||
assert.ok(ev("sfOf(R,'fra')") < 0.05, 'the victim goes dark');
|
||||
out.push(ev("JSON.stringify([R.load.L,R.useT[S.transit[0].id],sfOf(R,'fra')])"));
|
||||
assert.deepEqual(errors, []);
|
||||
}
|
||||
assert.equal(out[0], out[1], 'POP build order does not change the outcome');
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue