The District of Columbia Council approved new firearms legislation Tuesday that will allow residents to begin applying for handgun permits this week.

The council's unanimous vote comes as officials try to comply with last month's U.S. Supreme Court ruling that struck down the city's 32-year-old ban on handguns.

The emergency legislation will allow handguns to be kept in the home if they are used only for self-defense and carry fewer than 12 rounds of ammunition.

Handguns, as well as other legal firearms such as rifles and shotguns, also must be kept unloaded and disassembled, or equipped with trigger locks — unless there is a "reasonably perceived threat of immediate harm" in the home.

"This is not perfect legislation," said D.C. Council member Phil Mendelson, who worked with the mayor's office on the bill. "The first step is what we have before us today so that we maintain important provisions in our gun registration law while we continue look at how we can further refine our gun registration law."

Gun rights groups, including the National Rifle Association, said at least some of the new regulations will likely be challenged.

The emergency legislation will remain in effect for 90 days, and the council expects to begin work in September on permanent legislation.

Though residents can begin applying for handgun permits this week, city officials have said the entire process could take weeks or months.

"It depends on what your situation is — whether you owned the gun before or purchased it outside the District of Columbia," police Chief Cathy Lanier said.

The process involves a written exam, proof of residency and good vision. Successful applicants must pay a registration fee and agree to fingerprinting and a criminal background check before obtaining a weapon.

Even with Tuesday's vote, Washington's gun regulations will remain among the strictest in the country, said Paul Helmke, president of the Brady Campaign to Prevent Gun Violence.

He said Chicago, where it is illegal to possess or sell handguns, now has the toughest ordinance, though the city is facing a legal challenge following the Supreme Court ruling.

It remains to be seen how much of the district's new regulations will withstand constitutional challenges, Helmke said, adding that it could take years for the courts to sort it all out.

The Supreme Court's 5-4 decision June 26 that affirmed the right to have guns for self-defense "raised more questions than it's probably answered," Helmke said. "They haven't explained where you draw the line."