 "JAG" stands for "Judge Advocate General". The office of JAG is a  part of the Navy, which according to their official website  "provides legal and policy advice to the Secretary of the Navy in  all legal matters concerning military justice, administrative law,  environmental law, ethics, claims, admiralty, operational and  international law, litigation and legal assistance."