ALBANY, N.Y. (CBSNewYork/AP) — The House and Senate’s agreement on a five-year, $281 billion transportation bill could restore funding for a critical mass transit program for New York state, protect NJ TRANSIT from budget cuts and grease the wheels for new rail tunnels under the Hudson River.

The bill, unveiled Tuesday, would increase spending to address the nation’s aging and congested highways and transit systems — a legislative feat that lawmakers and President Barack Obama have struggled throughout his administration to achieve.

READ MORE: New York City Workers, Supporters March Across Brooklyn Bridge To Protest Approaching Vaccine Mandate

The legislation would also put an end to the cycle of temporary extensions and threatened shutdowns of transportation programs that have bedeviled Congress for the past seven years, making it difficult for states to plan long-term projects.

The 1,300-page measure was “a mammoth task,” said Sen. Barbara Boxer, D-Calif., one of the bill’s key negotiators.

“I expect this bill to have a huge amount of support throughout the country from businesses and workers alike,” she said in a statement. “Although it is not perfect, I believe it is a major accomplishment for our people who expect us to fund a top-notch transportation system.”

The bill would boost highway spending by 15 percent and transit spending by 18 percent over its duration. It also authorizes $10 billion over five years for Amtrak, $12 billion for mass transit annually and $1 billion for vehicle safety programs each year.

The bill still falls far short of the $400 billion over six years that Transportation Secretary Anthony Foxx has said is needed to keep traffic congestion from worsening, and it puts off the difficult decision of how to sustainably pay for transportation programs.

The federal 18.4-cents-a-gallon gas tax, the main source of Trust Fund revenues, hasn’t been increased since 1993 and no longer covers annual spending on transportation.

The House and Senate must still vote on the final bill. Passage is expected by Friday, when government authority to process aid payments to states expires.

The bill is paid for through a series of revenue-raising provisions, some of which have been criticized as gimmicks and budgetary sleight of hand.

READ MORE: NYPD Officers Testify As Judicial Inquiry Into 2014 Death Of Eric Garner Gets Underway

One of the hallmarks of the bill is the creation of new programs to focus transportation aid on highways regarded as important “freight corridors” in an effort to reduce major bottlenecks and speed the delivery of goods.

In New York, Sen. Charles Schumer said the bill would protect the “high-density states” program, which provides his state, six others and the District of Columbia with millions of additional dollars annually for mass transit. That includes about $100 million a year for New York transit agencies.

While the Senate-passed transportation bill protected those funds, the House-passed bill cut them.

The funding is intended to help some congested urban areas, including parts of Massachusetts, Connecticut, Rhode Island, Delaware and Maryland.

Schumer, a Democrat, said restoring the program was a top priority. He said it keeps about $1.3 billion for the program over the next five years and adds $18.5 million.

“It’s not the bill I would have written, but elections have consequences, and being in the minority, it was the art of the possible,” U.S. Sen. Robert Menendez, D-N.J., told WCBS 880’s Steve Scott. “It was critical to make sure the ‘high density’ funding that comes to states like New Jersey and New York … didn’t lose billions of dollars,”

“The bill increases transit funding over current levels. That’s a good thing, but nowhere near what we needed to do,” Menendez added.

Although new rail tunnels under the Hudson River are not specifically mentioned, the bill is favorable for the Gateway project, giving Amtrak the extra $10 billion over five years. The federal government has already agreed to pay half for the new tunnels.

The legislation would also spare NJ TRANSIT a budget cut of $50 million per year, WCBS 880’s Sean Adams reported.

MORE NEWS: Kason Parker Arrested In Deadly Stabbing Of 27-Year-Old Meghan Kiefer On Front Lawn Of Coram Home

(TM and © Copyright 2015 CBS Radio Inc. and its relevant subsidiaries. CBS RADIO and EYE Logo TM and Copyright 2015 CBS Broadcasting Inc. Used under license. All Rights Reserved. This material may not be published, broadcast, rewritten, or redistributed. The Associated Press contributed to this report.)