How do you get a federal gun permit?

There is no such thing as a federal gun permit. ADDED: If you are referring to Federal Firarms Dealers License (more commonly known as an "FFL") you need to contact the Bureau of Alcohol, Tobacco, and Firearms (BATF).