As a federal appeals court ruled Thursday that the collection of bulk telephone records by the National Security Agency is not authorized by law, the three judge panel also dropped the issue squarely in the lap of Congress, prodding lawmakers to act just weeks before several controversial provisions of the anti-terrorism Patriot Act are set to expire.

The panel from the Second Circuit Court of appeals issued a decision in favor of a legal challenge from the American Civil Liberties Union, finding that "the telephone metadata program exceeds the scope of what Congress has authorized."

“This decision is a resounding victory for the rule of law," said ACLU lawyer Alex Abdo.

The entire Second Circuit ruling can be found here.

At issue in this case is Section 215 of the Patriot Act, which backers of the NSA have argued allows U.S. intelligence to collect bulk telephone records to assist with terrorism investigations.

In Congress, opponents of the NSA surveillance plan said the court's ruling was a death knell for the bulk records program.

"They said, if you want to do bulk collection of data, Congress, go ahead and pass a law, but the present law doesn't allow you to do that," said Sen. Charles Schumer (D-NY).

"Simply extending the current system is no longer a viable option," said Sen. Richard Blumenthal (D-CT).

The ruling also brought forth political echoes within the 2016 race for the White House, led by Sen. Rand Paul (R-KY), who has long championed an end to the NSA bulk collections program.

On the same side as Paul was, Sen. Bernie Sanders (I-VT), who announced last week that he will run for the Democratic Party nomination.

On the other side was Sen. Marco Rubio (R-FL), who joined with a group of other Republicans on the Senate floor in arguing that the NSA surveillance plan is legitimately needed by U.S. intelligence agencies, labeling it a "valuable tool."

"There is not one single documented case, not one single documented case, there is not one single case that’s been brought to us as an example of how this program is being abused," Rubio said on the Senate floor.

But Rubio found himself isolated on the issue within the realm of the 2016 race.

"The National Security Agency’s data collection program went too far in collecting the phone records of Americans," declared Sen. Ted Cruz (R-TX), another GOP hopeful for President.

Rubio endorsed a plan from Senate Majority Leader Mitch McConnell to renew Section 215 and two other expiring provisions from the Patriot Act; McConnell wants a Senate vote on that before lawmakers take a Memorial Day break.

But in the House, momentum is gaining for a different, bipartisan bill to be voted on next week, which would end the bulk collection of phone records by the NSA, and make other changes related to civil liberties and intelligence gathering linked to American citizens.

That plan has the support of President Obama, as well as some Republicans who rarely agree with him on much of anything.

Details on the USA Freedom Act can be found here.

One final note about this ruling from the Second Circuit Court of Appeals - while the judges found that the NSA bulk collection program was not authorized, the judges refused to declare it unconstitutional - saying that determination should wait for whatever action is taken by the Congress.