Hard to identify the type but the small brown/rust ones with 2 points on the rear/tail don't harm coral unless they infest and cover the coral blocking light. The longer and larger brown rust flatworms that don't have pointy tails do feed off the flesh of corals (mainly LPS in my experience) and are a pain to eliminate as once you've noticed it, it's probably already laid eggs which aren't killable by coral dip or flatworm exit and only killable once they've hatched. So for these you have to check/treat often and hope you get them all before they lay eggs.
If you use flatworm exit on a huge infestation, they're known to release toxins when they die so be ready to do a huge water change and run carbon. Enough toxins for killing flat worms can wipe a tank.
The below list are fish I know that may eat them to help with population control
Certain wrasse - Yellow Corris, Six Line, Leopard and melanarus
Springer damsel
Mandarins