This is a regression tested in //UE4/Release-4.27 CL 18319896
Visualizing Custom Stencil Buffer returns incorrect results when an Actor with Render CustomDepth Pass enabled is visible.
Character and Scene are render black
When ever the character is visible RBGA artifacts are present
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-163921 in the post.