[Linear power supply] Supplies with transformers isolate the incoming power supply from the powered device and so allow metalwork of the enclosure to be grounded safely. Dangerous if primary/secondary insulation breaks down, unlikely with reasonable design. Transformerless mains-operated supply dangerous. In both linear and switch-mode the mains, and possibly the output voltages, are hazardous and must be well-isolated. [Switching power supply] Common rail of equipment (including casing) is energized to half the mains voltage, but at high impedance, unless equipment is earthed/grounded or doesn't contain EMI/RFI filtering at the input terminals. [Notes] Due to regulations concerning EMI/RFI radiation, many SMPS contain EMI/RFI filtering at the input stage before the bridge rectifier consisting of capacitors and inductors. Two capacitors are connected in series with the Live and Neutral rails with the Earth connection in between the two capacitors. This forms a capacitive divider that energizes the common rail at half mains voltage. Its high impedance current source can provide a tingling or a 'bite' to the operator or can be exploited to light an Earth Fault LED. However, this current may cause nuisance tripping on the most sensitive residual-current devices. [0] 
Risk of electric shock