It would have been so much better if Matthews told Dexter he knew who he was the whole time.I like to think he really did but played stupid and didn't want Maria to prove it so that's why he warned Dexter what she was up to.
He knew!