She works as an Auror in the Ministry of Magic under the eye of Mad-Eye Moody. She worked as a spy for the Order of the Phoenix. So did Arthur Weasley, Kingsley Shacklebolt, and a few others, as they themselves worked inside the Ministry.