Show me the law."
I can't remember the specific statute, but 28 USC - Which established the Federal judiciary to include federal law enforcement - empowers federal agents to carry firearms. Title 28 established the FBI, BATF, US Marshalls and each have specific authorization to carry firearms contained within their respective establishing statutes.
The other establishing acts for NCIS or Federal Park Police and the like, have similar authorizing language in them as well.
Keep reading my posts you will se the exact authorizations, but then you would have to go to the cites to determine the effective dates. Since you are an old deck hand check out NCIS and tell me what you think.
FBI did not get authority to carry firearms until 1934, but used them before anyway. INS used implied authority until about 1990, IRS as of 1996 did not have authority and according to them:
According to the IRS, there is no statutory authority for special agents to carry firearms. The General Counsel, Department of the Treasury, has concluded that no specific authority is necessary where a federal officer has the authority to make an arrest and that the authority to carry a firearm is implicit.
http://www.gao.gov/archive/1996/gg96154.pdf This chart show NCIS gets its "statutory authority" 10usc 1585 (1958) Here is an excellent reference book part is available online if you google it: Handbook of Federal Police and Investigative Agencies by Donald Torres. My point was some laws are implied and not necessarily statutory, and I gave an example for the Federal Government. It would be difficult to enforce ciminal laws without firearms, it would be difficult to enforce Presidential Eligibility without an Investigation. See implied contracts or implied in law.