Whether wiping your phone is a criminal act seems could be a legitimate question depending on the circumstances.
Whether authoring such a feature is itself a criminal act is an outrageous question, to which the answer should be an obvious, and emphatic "no".