The vast majority of analogue and digital scopes have switched, passive input attenuators using small resistors, trim capacitors and wafer switches employing several banks. All these components have max voltage ratings that do not include supply voltages like 240 volts AC.
Possibly the most vulnerable component to high voltages is the tiny trim capacitor connected * directly across the input * to equalise capacitance loading for all ranges - it is crucial that a scope's input present a constant value of C ( usually 15 to 20 pF) in parallel with 1 Mohms on all ranges so that the trimmer on a 10:1 probe can be adjusted once and left.
Wafer switches are also not rated for high voltages and lack sufficient insulation and clearances to survive the spike voltages that regularly appear on the AC supply. Insulation breakdown in the trimmer or switch would be sudden and bit spectacular when full AC mains power is available.
Many scopes have a max input rating of 400 volts ( DC+AC) peak - which means they are capable of accepting such peaks on a wave being viewed without damage, despite the fact the actual peaks may not be shown. It also means that when AC coupled, the max DC voltage should not exceed 400 volts as that is the rating of the series input capacitor.
The worst case of ACCEPTABLE input overload is with 400 volts at the input and the attenuator set to pass the voltage straight through to the FET preamp. Makers typically fit a series resistor of 100kohms to 470kohms between the switch and the gate of the first FET to limit current to a few mA - then add one or more diodes to direct this current safely into the
+/- DC supply rails. These diodes must be low leakage types so not to create an DC offset at the gate of the FET.This high value series resistor needs a cap in parallel to pass high frequencies that would otherwise be lost due stray capacitance to ground at the gate of the FET - typically a 10nF cap is used and this too must be rated for at least 400 volts.
In short - whenever scoping the AC supply make damn sure to use a 10:1 probe and be DAMN certain the switch is the right position.
... Phil