"We don't think there's anything in current federal law that endangers anything in San Francisco gun control provisions," spokesman Matt Dorsey said.
But Dorsey said he thinks the lawsuit is part of an effort by the Virginia-based NRA to "push the envelope" of the constitutional Second Amendment right to bear arms in the wake of a key U.S. Supreme Court decision last year.
In that ruling, which overturned a Washington, D.C. handgun ban, the high court said the Second Amendment encompasses an individual right to possess guns for self-defense.
The new lawsuit was filed in federal court in San Francisco Friday by the NRA, six San Francisco residents and a retired police officers' association.
It seeks to invalidate three gun-related provisions of the city police code. One provision, signed into law by Mayor Gavin Newsom in 2007, requires that handguns in the home be stored in a locked container or disabled with a trigger lock.
The other provisions are a rule forbidding the sale of fragmenting bullets that serve no sporting purposes and a ban dating from 1938 on the discharge of firearms within city limits.
The lawsuit claims the three provisions violate the right to keep and bear arms for self-defense.
NRA attorneys wrote in the lawsuit that in "life-threatening situations, one has little time - if any - to fumble around in the dark and remove a trigger lock or open and retrieve a handgun from a safe to ward off a violent attack."
The attorneys noted that the Supreme Court struck down a similar trigger lock measure in the Washington, D.C. case.
In previous lawsuits, the NRA won a state appeals court ruling overturning a voter-approved San Francisco handgun ban in 2008. Earlier this year, it forced the San Francisco Housing Authority to stop enforcing a ban on gun possession in public housing.