According to Giuliani it’s constitutional!
According to others it isn't. So I guess the best thing would be for Trump to implement it and let it play out in court, though since it's a local law enforcement matter and not a federal matter I'm not sure how he would do that.