skip to content

part 1 · sources checked 2026-11-20

html, css, and dom: parsers, selectors, render, extraction

This module shows how a collection system turns response bytes into a document, finds and checks elements, and extracts data with no false success.

purpose

A collection system must turn the bytes of a response into a document before it can extract data. Each step can lose data, or keep data that no user sees. A defender can use the same document to hide traps, decoys, and changed data.

After the module, you can choose a method to parse a page and a selector strategy, and design an extraction check with no false success.

objectives

  1. Compare a regular-expression extractor with a DOM (Document Object Model) parser for one task. State the cost and the failure modes of each.
  2. Write a selector that survives a change of CSS class names.
  3. Explain why a selector cannot cross a shadow root, a cross-origin iframe, or an isolated world.
  4. Decide if an element is visible with the computed style and the bounding box.
  5. Design an extraction rule that gives inconclusive on an empty page, not pass.
  6. Calculate the structural similarity of two captures, and explain what a low value means.
  7. Name the decoy element and honeypot element patterns of the DOM. State the signal of each one.
  8. Measure the break rate of each selector class over time, and test the checks of a collector against changed data.

lessons

5 of 8 published

a dim title is not yet published

  1. L01 from bytes to document: fetch, parse, and text extraction
  2. L02 selectors and the limits of the dom
  3. L03 render and visibility: hidden text, honeypots, and decoys
  4. L04 extraction rules that cannot lie (not yet published)
  5. L05 comparison against a baseline: soft blocks, honeypot pages, and poisoned data (not yet published)
  6. L06 measure selector stability over time (not yet published)
  7. L07 serve plausible but changed data, and detect it
  8. L08 extract from the accessibility tree