Secret Service spokesman Ed Donovan said RJ "Renae" Kapheim, 41, of Davenport, Iowa was arrested on Wednesday, EFE news agency cited from the New York Times.
Agents at a checkpoint near the executive mansion questioned Kapheim, who said he drove to Washington after somebody in Davenport told him to go to the White House.
When they inspected the car parked nearby, the agents found a rifle and more than 40 rounds of ammunition.
Security around the White House has been beefed up following such incidents.
Kapheim was arrested for possession of an unregistered firearm, which is an offence in the district of Columbia.
Security around the White House has been beefed up following a string of incidents, including one in which an intruder made it inside the mansion before he was intercepted.