The owner will fund one: rewriting the memory-unsafe parser, or another year of exploit mitigations. How do you frame the choice?
answer
- refuse the safe-or-unsafe question
- mitigations buy schedule, a rewrite buys a class
- who can still afford it
- reduce the gain, not only the odds
- remaining service life decides amortisation
basics
~20 sRefuse the safe-or-unsafe framing. Mitigations set a price on exploitation, and the price decides which adversaries can still pay; a rewrite removes the defect class for that component. Decide on component lifetime, exposure and which adversary you are actually funding against.
solid answer
~50 sPresent two different products, not two strengths of the same one. Mitigations buy schedule: they make a published exploit fail unmodified, force an attacker to find a second defect and rebuild a chain, and apply estate-wide for the price of a build and a deployment change. They do not remove the class, so every new parsing defect re-enters at the same price. Rewriting the parsing surface removes the class for that component permanently, costs real engineering time, and imports different risk - new logic defects and a migration. Then decide on facts the owner already holds: remaining service life, whether the input is reachable unauthenticated, and which adversary is in scope. Against someone firing a public exploit, mitigations plus fresh worker creation convert execution into a crash; against a funded operator they cost a month. Both are true, and only one is a security position.
go deeper
Know the core distinction: a mitigation makes exploitation harder, a fix removes the defect, and only the second one takes the class away.
Be able to say what each mitigation costs an attacker in concrete terms - an extra disclosure defect, a rebuilt chain - rather than describing them as protection in general.
Show that you would scope the rewrite to the untrusted-input surface and change worker creation so a failed attempt costs the attacker something, instead of treating this as one large all-or-nothing project.
Own the decision frame in front of somebody spending money: price rather than safety, remaining service life and reachability as the deciding facts, a third option that reduces the value of a win, and a written commitment that survives being tested.
## The framing to refuse The question will arrive as *are we safe*. Answering it in those terms loses either way: yes is false, and no sounds like the mitigations were wasted. The truthful frame is price. Every mitigation on this surface - randomised layout, non-executable data pages, stack guards, control-flow constraints - removes one link of an exploit chain and forces the attacker to buy a replacement. The chain remains constructible. What changes is what it costs, and cost is what decides *who* can still run it. So the sentence to put in front of an owner is: with the current mitigations, exploiting this defect class requires an additional memory-disclosure defect and a purpose-built chain, which is roughly a month of a competent specialist. That is a number the owner can reason about against the adversary they believe they have. ## What each option actually buys **Another year of mitigations.** - Estate-wide. One build configuration and a deployment change protect every service that shares the toolchain, not just this parser. - Cheap per unit and fast to land. - Prices out the population that reuses published exploits unmodified - which is most of the volume most estates ever see. - Does not remove the class. The next parsing defect arrives at the same price, and the year is bought again. - Priced by deployment, not by flags. If workers are copies of one parent rather than fresh loads, retries are free to the attacker and the mitigations are worth materially less than the datasheet implies. Fixing that is a small change with a real effect, and it belongs in this proposal rather than in the rewrite. **Rewriting the parsing surface in a memory-safe language.** - Removes the class for that component, permanently, for every future defect in it. - Costs engineering time and calendar, and the estimate is usually wrong in the familiar direction. - Imports different risk. New code carries new logic defects, the interface between the safe component and the rest of the process is a new surface, and any period of running two implementations invites disagreement over inputs. - Is not all-or-nothing, and this is the part the owner will not have been offered. The untrusted-input parsing surface is typically a small, well-specified fraction of the daemon and the fraction that touches attacker-controlled bytes first. Porting only that, and leaving the rest, gets most of the benefit for a fraction of the cost. ## The third option to put on the table Both of the above reduce the *likelihood* of a successful exploit. Neither reduces what the attacker gets when one succeeds. Running the parsing component as a separate low-privilege process behind a narrow interface changes the outcome of a win rather than its probability: a compromised parser holds no credential, opens no connection, and reaches nothing worth having. It is often cheaper than a rewrite and it composes with either choice. Denying that process the ability to make pages executable is a related, smaller move in the same direction. An architect who presents only the two options that were offered has failed the owner. ## How to decide Facts that settle it, in rough order of weight: - **Remaining service life.** A daemon with five years ahead of it amortises a rewrite. One being retired in eighteen months should buy the year and spend the engineering on the replacement. - **Reachability.** Unauthenticated exposure to arbitrary senders is a different risk from a surface behind an authenticated boundary, because it changes how many adversaries can even attempt it. - **Defect history.** A component that has produced memory-safety defects repeatedly will produce more; that history is the best available evidence that mitigation is a recurring cost rather than a one-off. - **Adversary in scope.** If the organisation has decided it defends against opportunistic use of public exploits, mitigations plus fresh worker creation meet that bar honestly. If a funded operator is in scope, a month of their time is not a deterrent and the class has to go. ## What to commit to in writing Never *this is now safe*. Commit to statements that survive being wrong: this class is removed from component X; for the remaining components the class is present and priced at roughly this much work; here is the retry cost per attempt after the worker-creation change; here is the date the rest is scheduled. An owner who is told a price can revisit the decision when the price changes. An owner who is told *safe* will find out otherwise from somebody else.
- The owner says the mitigations are already funded and asks what more the rewrite buys. What is the one-sentence answer?The mitigations are re-bought every time a new parsing defect appears, because they price exploitation without removing the defect class; the rewrite is paid once and removes the class from that component, so the comparison is a standing tax against a capital cost.
- Why propose privilege separation when neither option asked for it?Because both options offered reduce the probability of a successful exploit and neither reduces what a successful exploit yields. Running the parser as a low-privilege process behind a narrow interface changes the outcome of a win, usually costs less than a rewrite, and composes with whichever option is funded.
- How would you word the commitment so it survives a later compromise?State removal per component and price everywhere else: this class is gone from the ported parser; elsewhere it is present and currently costs an attacker a disclosure defect plus a purpose-built chain. Give the retry cost per attempt and the schedule for the remainder. Never write that the daemon is safe.
saying these in an interview costs you the question
- Answers the are-we-safe question with yes or no
- Presents only the two options the owner offered
- Treats a rewrite as risk-free because the language is safe
- Ignores remaining service life when comparing costs
- Confuses reducing the odds of a win with reducing its value