AFAIK, not against the law. Against State Department policy.
Quite possibly a Hatch act violation: engaging in political activity while on duty, in uniform, at work or in a government vehicle.
The election is over.
They don’t have to like their instructions from their superiors. They just have to do them ... as Ms. Sally, Esq. painfully learned this evening.
And the pen that writes that policy changes Wednesday when Tillerson gets confirmed.