Massachusetts became the first state to enact a ban on bump stocks following the mass shooting at a Las Vegas music festival.
Republican Lt. Gov. Karyn Polito signed the bill Friday in her capacity as acting governor because Republican Gov. Charlie Baker is on vacation in California.
A bump stock can make a semi-automatic rifle mimic the fireng actions of a fully automatic weapon.
Earlier in the day, the Gun Owners Action League of Massachusetts, an affiliate of the National Rifle Association, called on Baker to veto the bump stock ban, Fox 25 Boston reported. Among other objections, the group said the potential penalties for possession of the devices were too harsh.
"The provision passed by the legislature ... allows for excessive punishment including life imprisonment, with a minimum sentence of 18 months, for the mere possession of these accessories," said the group.
Authorities investigating the deadliest mass shooting in modern American history said the gunman, Stephen Paddock, used a bump stock when he opened fire Oct. 1 from his Las Vegas hotel room on concert-goers below. Fifty-eight people were killed and hundreds more wounded.
Democratic state Rep. David Linsky, one of the first in Massachusetts to call for outlawing the devices, said it would make the state safer while respecting the rights of gun owners.
"I am proud of my colleagues in the Legislature for continuing Massachusetts' reputation as having among the safest and most effective gun laws in the nation," he said.
California law already prohibited the sale of bump stocks.
The Associated Press contributed to this report.