Killswitch: switchable high voltage path/shunt to ground without any additional power supply
First, I notice that in your question, you refer to 400VAC. But your circuit only handles DC. So I am going to presume that you only need to short DC.
Second, the term 400VAC refers to an rms value, not peak. When it is rectified, it is considerably more than 400VDC. Peak value is about 400*1.4=560V. But in your schematic, you have 400VDC, so I am going to assume that 400VDC is actually what you have, not 560V. But that is something you need to check.
I offer the following alternative circuit.



simulate this circuit &ndash; Schematic created using CircuitLab
It is guaranteed that if Vcheck goes below the turn-on voltage of M1, that M1 will stop conducting, and in turn, the gate of M2 will rise to the point that M2 conducts.
I don't know how fast you need to discharge your capacitors. I used a 1k\$\Omega\$ discharge resistor, which will drain 400V at at a rate of 400mA. That is about 160W. That may or may not be OK in your application. Also, the resistors I chose give a fairly low quiescent current. You may want to change them to fit your requirements. Use smaller values if the circuit is too slow. Use larger values if the quiescent current is too high. But obviously, there are practical limits to how high they can be.
Note that I said that the circuit is guaranteed to provide a shunt if Vcheck goes under the threshold voltage of M1. I didn't say what voltage guarantees that the circuit does not shunt the high voltage. The IRF830 datasheet gives the threshold voltage as anywhere between 2V and 4V. If you need a more definite transition voltage, especially if you are using a 3.3V MCU a 5V MCU with weak output pins, let me know.
One concern that I have is that this circuit will be in the shunt state until the MCU outputs the threshold voltage. Hopefully, that is not too long a time. However, it could heat up the shunt resistor R4 significantly. Perhaps it would work to just have the 5V Vcc be the check voltage? I don't know your application requirements, so I can't say, but that is just something that concerns me.