feat(core): traceroute and tcpdump after Java, measured against Java

TerminalRun adds nine stories: traceroute in the LAN, through the router,
unreachable, without a route, to no one, to the host itself, errors and
Ctrl+C; tcpdump on two hosts. traceroute counts failures across hops as
Java does and takes an error that carries its probe; tcpdump tells each
frame's highest capture row with its time of day, at once.

Departures from Java: traceroute tells its summary before the end mark
(Java after it, where its window shows no text) and calls a host at the
20th hop reached. arpsend is not built.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-02 10:46:18 +00:00
co-authored by Claude Opus 5.5
parent 495c449ef2
commit a867c33d64
16 changed files with 11983 additions and 16 deletions
+5 -1
View File
@@ -4203,7 +4203,6 @@ export class NetworkRuntimeEngine {
this.sendEthernetFrame(nodeId, networkInterface.portId, frame);
}
private earliestDeadline(filter: (kind: ScheduledEventKind) => boolean): number | undefined {
let earliest: number | undefined;
for (const event of this.stateValue.pendingEvents) {
@@ -4714,6 +4713,11 @@ export class NetworkRuntimeEngine {
return result;
}
/** The time of day (wallClock) when the simulation was at `milliseconds`, counted back from now. */
wallTime(milliseconds: number): number {
return this.wallClock() - (this.stateValue.currentTimeMilliseconds - milliseconds);
}
/** The first ICMP identifier of a command line (Terminal.setIdentifier: new Random().nextInt(43) * 23). */
drawIcmpIdentifier(): number {
return this.icmpIdentifierRandom.nextInt(43) * 23;