While Ms. Coakley kept a low profile over the holidays, Mr. Brown hammered her as soft on terrorists and as a “crusader” for abortion rights. He has played up his military credentials — he serves in the Army National Guard — and his opposition to the health care overhaul headed for a final vote in Congress. That, too, has unnerved Democrats, who cannot afford to lose a single vote on the embattled legislation.

Republicans are hoping that diminished support for President Obama and his party among independents could give Mr. Brown a shot at winning. About half of the state’s voters are not affiliated with a party.

“Scott’s done a great job of tapping into the economy as an issue and the fact that people aren’t happy with what’s going on in Washington,” said Charles Manning, a Republican strategist here. “When you couple that with the coronation campaign that Martha’s been trying to run, it’s really made a difference.”

Democrats dismiss such statements as wishful thinking whipped up by conservative commentators outside Massachusetts. Still, Mary Anne Marsh, a Democratic strategist, said Ms. Coakley erred in not campaigning more aggressively last month.

“By taking a low-profile approach, she invited more of a race than she would have had otherwise,” Ms. Marsh said. “Sometimes I wanted to say, ‘My God, woman, take it up a notch.’ ”

In a direct attack on his Democratic opponent in the U.S. Senate race, Republican state Sen. Scott Brown has filed a bill that would require proof of citizenship or legal residency for people seeking action against employers for violating the state’s wage laws.

As attorney general, Martha Coakley has aggressively enforced laws protecting workers’ wages. Before the campaign, her office often announced settlements with companies she sued for allegedly violating prevailing wage laws or avoiding payroll taxes. Coakley represented everyone, including illegal immigrants.

Her opponent, Scott Brown, said that encourages people who are here illegally.

“As a top law enforcement official, her No. 1 job is to enforce the laws of the state and to protect citizens here legally and the people who are here with the appropriate immigration status,” Brown said during a telephone interview.