diagnose a collector from its results · lesson 9 of 9 · sources checked 2026-11-22
what the defender sees, and the budget of a probe study
This lesson shows what a defender sees of a diagnosis, and how to write the budget and the plan of a probe study.
status of this lesson: from a public sourcethis page is not legal advice.
purpose
A diagnosis sends attempts, and the defender keeps a record of each of them. In that record, the study can show as a pattern, and the study also has a cost for your own fleet. A written plan keeps the study in a permitted place and inside its limits.
objectives
- List the patterns that a probe study leaves in the log of a gate.
- Explain why one probe is not a measurement.
- Find your own probe pattern in the exported log of a lab gate.
- Write the plan of a probe study with its place, budget, pace, stop condition, and disclosure.
new terms
- incident
- An event that lowers the success of the product below its objective and that the on-call engineer must act on.
- probe budget
- The written limit of attempts, pace, and pool heat for a diagnosis or a probe study.
how it works
A probe study is a planned set of diagnosis attempts. Each attempt is a probe: it reads one result and gives a value. In this course, a probe study runs only against your own lab target, or against a page whose owner approved the study.
what the gate log shows
The defender keeps a log of each web session. A diagnosis leaves a pattern in that log:
- web sessions with no stored state, from one network;
- web sessions that differ in one factor, one after the other;
- a fixed schedule: three or more starts with equal gaps, for example one start each 60 seconds;
- visits to known test pages;
- a burst of requests on one held address.
Each pattern comes from a method of the diagnosis. A control twin gives two equal web sessions at the same time. A one-factor design gives a series of web sessions that each change one factor.
answers that hide the verdict
One cloud firewall documents a rule action that counts a matching request. The action does not decide if the request passes or gets a block, and the firewall goes on with its other rules Amazon Web Services, source 1. Such a rule can also add a label that other rules match.
one probe is not a measurement
A defender can answer a probe with noise, a delay, a decoy, or a rule in count mode. For example, a rule in count mode labels the probe and gives a normal page. A later rule can then act on that label.
Thus a pass of one probe does not show that the defender saw nothing. A block of one probe does not show which layer gave the verdict. A diagnosis compares many attempts under a written design.
read your own pattern in the lab
In the lab, run the methods of the diagnosis against a gate with open-source detection. Then export the log of the gate, and find your own pattern in it. For example, look for two equal web sessions that start 2 seconds apart. The loop of the diagnosis is in The diagnosis loop and the hypothesis ledger (not yet published).
The lab gate gives you the view of the defender. The code example reads such a log, and the chart shows what a log reader found.
the cost of a study
Each attempt costs the operator. It uses capacity, and it adds pool heat to the exits that it uses.
For example, a study on the exits of the work raises the risk of the next work items on those exits. A study that is too large can also lead to fleet burn.
The capacity share and the money cap of a study are in The budget for experiments and diagnosis (not yet published). The cost record of one incident is in The cost of a diagnosis.
the plan of a probe study
Write the plan before the first attempt. It has six parts:
- The permitted place: your own lab target, or a page whose owner approved the study in writing.
- The attempt budget: the highest count of attempts.
- The pace: the highest count of attempts in a time window.
- The limit of pool heat for each exit pool.
- The stop condition: for example a block, a spent budget, or a request of the owner of the page.
- The disclosure: the owner of the page knows of the study, and the report gives the method and the limits.
Parts 2 to 4 are the probe budget. At a block, the study goes slower or stops. It never moves to a different exit.
example A study has four methods with 10 attempts each. Thus the attempt budget is 40. With a pace of one attempt each 30 seconds, the study takes 20 minutes.
the two sides
| automation side | detection side |
|---|---|
| A written budget and a stop condition keep the diagnosis inside its cost. They limit the pool heat and the risk of fleet burn. | The log of the defender shows web sessions with no stored state from one network, and a fixed schedule. It also shows visits to known test pages and a burst on one held address. The lab gate shows you the same view. |
design decisions
| option | gain | cost | when it is correct |
|---|---|---|---|
| One probe and its answer | Fast and cheap | Noise, a delay, a decoy, or count mode can hide the verdict. | Never as a measurement |
| A study under a written design | The comparison has many attempts and a control arm. | More attempts, and a pattern in the log of the defender | Each diagnosis |
| A study in the own lab | You see the log of the gate. | The lab gate is not the defense of a real site. | First, for each method |
| A study on a page with the approval of its owner | A real defense, with a disclosure | It must have a written approval and a stop condition. | When the lab cannot answer the question |
| A written probe budget | The cost has a limit before the start. | Some questions stay open. | Each probe study |
diagram
the probe pattern in the log of a lab gate, in time order
code example
The example reads an exported log of an own lab gate, in JSON, from a path argument. With no argument, it reads the synthetic log rows of the exercise. It finds control twins, one-factor series, and fixed schedules. It also counts the web sessions with no cookie from each network. The network labels and the values are synthetic.
Read the exported log of an own lab gate, and find control twins, one-factor series, and fixed schedules for each network.
import { readFileSync } from "node:fs";
// Gate log reader for an own lab gate. Each row is one web session start.
// With a path argument, it reads an exported JSON log. Else it reads the synthetic log below.
type Row = { t: number; session: string; network: string; cookie: boolean; client: string; pace: string; page: string };
const FACTORS = ["client", "pace", "page"] as const;
const GAP_TOLERANCE_S = 1; // example limit for "almost no spread"
const SAMPLE_LOG: Row[] = [
{ t: 0, session: "s1", network: "network 1", cookie: false, client: "A", pace: "slow", page: "1" },
{ t: 2, session: "s2", network: "network 1", cookie: false, client: "A", pace: "slow", page: "1" },
{ t: 60, session: "s3", network: "network 1", cookie: false, client: "B", pace: "slow", page: "1" },
{ t: 120, session: "s4", network: "network 1", cookie: false, client: "B", pace: "fast", page: "1" },
{ t: 180, session: "s5", network: "network 1", cookie: false, client: "B", pace: "fast", page: "2" },
{ t: 400, session: "s6", network: "network 2", cookie: true, client: "A", pace: "slow", page: "3" },
];
const diff = (a: Row, b: Row) => FACTORS.filter((f) => a[f] !== b[f]);
const names = (rs: Row[]) => rs.map((r) => r.session).join(", ");
function read(input: Row[]): string[] {
const rows = [...input].sort((a, b) => a.t - b.t);
const found: string[] = [];
// 1. Control twins: same network, same factors, starts 5 s apart or less.
rows.forEach((a, i) => {
for (const b of rows.slice(i + 1)) {
if (b.t - a.t > 5) break;
if (a.network === b.network && diff(a, b).length === 0) found.push(`twin pair: ${a.session} and ${b.session}`);
}
});
const byNet = new Map<string, Row[]>();
for (const r of rows) byNet.set(r.network, [...(byNet.get(r.network) ?? []), r]);
for (const [network, group] of byNet) {
// 2. One-factor series: each web session changes one factor of the one before.
let run = [group[0]];
for (let i = 1; i <= group.length; i++) {
const cur = group[i];
if (cur && diff(group[i - 1], cur).length === 1) { run.push(cur); continue; }
if (run.length >= 3) found.push(`one-factor series on ${network}: ${names(run)}`);
run = cur ? [cur] : [];
}
// 3. Fixed schedule: three or more starts with equal gaps.
let start = 0;
for (let i = 1; i <= group.length; i++) {
const gap0 = start + 1 < group.length ? group[start + 1].t - group[start].t : 0;
const ok = i < group.length && Math.abs(group[i].t - group[i - 1].t - gap0) <= GAP_TOLERANCE_S;
if (ok) continue;
if (i - start >= 3) found.push(`fixed schedule on ${network}: ${names(group.slice(start, i))}, gap ${gap0} s`);
start = i - 1;
}
// 4. Web sessions with no stored state from one network.
const cold = group.filter((r) => !r.cookie).length;
found.push(`${network}: ${cold} of ${group.length} web sessions with no cookie`);
}
return found;
}
const rows: Row[] = process.argv[2] ? JSON.parse(readFileSync(process.argv[2], "utf8")) : SAMPLE_LOG;
for (const line of read(rows)) console.log(line);output
One line for each pattern that the reader finds, then the count of web sessions with no cookie for each network.
twin pair: s1 and s2
one-factor series on network 1: s2, s3, s4, s5
fixed schedule on network 1: s3, s4, s5, gap 60 s
network 1: 5 of 5 web sessions with no cookie
network 2: 0 of 1 web sessions with no cookieThe output shows a twin pair, a one-factor series of four web sessions, and a fixed schedule with a gap of 60 seconds. All web sessions of network 1 have no cookie.
data
sessions that each probe pattern flags in the log of a lab gate
status of this figure: simulated
source: Lab result of this course: own lab gate log in count mode, four diagnosis methods; date 2026-11-15; sample of 53; condition: Own lab gate on one shared host. Scripted clients, not people. The patterns were written for these methods, so the flags show the method and not a finding.
data table
| series | diagnosis method | sessions |
|---|---|---|
| pattern: twin pair | control twin | 20 |
| pattern: twin pair | one-factor series | 2 |
| pattern: twin pair | exit series | 14 |
| pattern: twin pair | threshold probe | 2 |
| pattern: one-factor series | control twin | 20 |
| pattern: one-factor series | one-factor series | 15 |
| pattern: one-factor series | exit series | 0 |
| pattern: one-factor series | threshold probe | 0 |
| pattern: exit series | control twin | 20 |
| pattern: exit series | one-factor series | 4 |
| pattern: exit series | exit series | 15 |
| pattern: exit series | threshold probe | 0 |
| pattern: threshold probe | control twin | 0 |
| pattern: threshold probe | one-factor series | 0 |
| pattern: threshold probe | exit series | 0 |
| pattern: threshold probe | threshold probe | 3 |
The chart is a lab result of this course, with scripted clients on an own lab gate. Thus it shows the method, not a finding. The four methods are a control twin, a one-factor design, and a design that changes only the exit. The fourth is a threshold probe: a burst of requests on one held address.
Each method leaves the pattern that the log reader looks for. The patterns also overlap, so one flag does not name the method. The twin pattern, for example, also flags web sessions of other methods.
failure modes
| problem | cause | correction |
|---|---|---|
| A pass of one probe is read as "the defender saw nothing". | The defender can answer with count mode, a delay, or a decoy. | Compare many attempts under a written design. |
| The study adds heat to the exits of the work. | The plan has no limit of pool heat. | Write the probe budget before the first attempt. |
| The study goes on after a block. | The plan has no stop condition. | Stop, or go slower, at the first block. |
| A study runs on a page with no approval. | The permitted place is not in the plan. | Use the own lab target, or get the written approval of the owner. |
| The operator does not know what the defender saw. | Nobody read the log of the gate. | Export the log of the lab gate, and find the own pattern. |
check questions
List the patterns that a diagnosis leaves in the log of a gate.
sample answer
Web sessions with no stored state from one network, and web sessions that differ in one factor, one after the other. Also a fixed schedule, visits to known test pages, and a burst of requests on one held address.
Explain why a pass of one probe does not show that the defender saw nothing.
sample answer
A defender can answer with noise, a delay, a decoy, or a rule in count mode. A rule in count mode labels the probe and gives a normal page, and a later rule can act on the label. Thus a diagnosis compares many attempts under a written design.
Two web sessions from one network have equal factors and start 2 seconds apart in the log of your lab gate. Which pattern is this?
- A fixed schedule
- A twin pair of a control twin
- A burst on one held address
- A one-factor series
answer
b. A twin pair of a control twin
A control twin runs the same configuration two times at the same time. The log shows two equal web sessions that start close together.
A study has 3 methods with 8 attempts each, at one attempt each 30 seconds. What are the attempt budget and the time of the study?
- 11 attempts, 6 minutes
- 24 attempts, 4 minutes
- 24 attempts, 12 minutes
- 48 attempts, 24 minutes
answer
c. 24 attempts, 12 minutes
The attempt budget is 3 times 8, or 24 attempts. 24 attempts at 30 seconds each take 720 seconds, or 12 minutes.
A probe study gets a block. What does the plan of the study say that you must do?
- Go slower, or stop.
- Move the study to a different exit.
- Send the same attempt again at once.
- Remove the limit of pool heat.
answer
a. Go slower, or stop.
At a block, the study goes slower or stops. It never moves to a different exit.
exercise
exercise Do this task on paper, with the synthetic log rows of an own lab gate below. Do not send a request to a site.
The log rows, one for each web session start:
- t 0 s, session s1, network 1, no cookie, client A, pace slow, page 1.
- t 2 s, session s2, network 1, no cookie, client A, pace slow, page 1.
- t 60 s, session s3, network 1, no cookie, client B, pace slow, page 1.
- t 120 s, session s4, network 1, no cookie, client B, pace fast, page 1.
- t 180 s, session s5, network 1, no cookie, client B, pace fast, page 2.
- t 400 s, session s6, network 2, cookie, client A, pace slow, page 3.
- Write the twin pair, if the log has one.
- Write the one-factor series and its network.
- Write the gap of the fixed schedule.
- Write the attempt budget of a study with 3 methods and 8 attempts each.
- Write the time of that study at one attempt each 30 seconds.
sample answer
The answer uses the patterns of the gate log and the example of the budget.
Sessions s1 and s2 are a twin pair: one network, equal factors, 2 seconds apart. Sessions s2 to s5 are a one-factor series on network 1. Each one changes one factor: the client, then the pace, then the page. Sessions s3, s4, and s5 start each 60 seconds, so the fixed schedule has a gap of 60 seconds. Each session on network 1 has no cookie.
The attempt budget is 3 times 8, or 24 attempts. At one attempt each 30 seconds, the study takes 12 minutes.
sources
- Using rule actions in AWS WAF, Amazon Web Services, documentation, read 2026-11-22
- My model of the probe pattern in a gate log, of the cost of a study, and of the plan of a probe study, 2026-11 (not public).
- Lab result of this course: the web sessions that each probe pattern flags in the log of an own lab gate, 2026-11 (not public).