KENSINGTON, MD-JANUARY 20: Inner loop evening traffic on the Beltway approaching Georgia Avenue on January 20, 2010 in Maryland. Under a bill sent to Md. Gov. Martin O’Malley on Friday, April. 5, illegal immigrants would be allowed to obtain state driver’s licenses. (Mark Gail/WASHINGTON POST)

Illegal immigrants could obtain Maryland driver’s licenses under a measure the General Assembly sent to Gov. Martin O’Malley on Friday, and that aides said the governor supports.

The measure, which passed the House of Delegates 82 to 55, would reinstate and expand a program that allowed some immigrants to obtain licenses prior to 2009, when it was ended so Maryland could conform to a stricter, federal rule on IDs.

Maryland lawmakers, however, voted to repeal that decision. Proponents argued that the measure would make the state’s roads safer by allowing the Maryland Motor Vehicles Administration to administer written and road tests for illegal immigrants, and for insurance companies to issue them liability coverage.

The measure was titled the Maryland Highway Safety Act of 2013. It was introduced by Sen. Victor Ramirez (D-Prince George’s).

Gustavo Torres, executive director of CASA of Maryland, an immigrant rights group, praised the vote: “Maryland once again proved that despite a broken immigration system, reasonable minds can build safe communities that are knit together by our common interests,” Torres said in a statement.

Maryland voters last fall upheld a decision by the state legislature to grant another benefit for illegal immigrants: In-state tuition rates at public colleges and universities.

Republican opponents of the measure tied up a final vote for hours on the floor of the House of Delegates. They argued that the bill would make it easier for terrorists to obtain IDs, as well as to reward the behavior of those who have entered the country illegally.

The legislation would require Maryland to establish a second-class driver’s license, which applicants could obtain without a Social Security number or proof of lawful status.

Immigrants would have to show some form of identification, such as a birth certificate or passport. And to suggest long-term Maryland residency, senators added a requirement that applicants also provide two years of state income tax filings. State analysts, however, said there appeared to be nothing in the proposal restricting applicants from filing returns retroactively.

The licenses would afford undocumented immigrants almost all of the same rights as citizen driver’s licenses. They would be the same color as regular licenses, but would be marked as not valid for federal purposes, such as entering federal buildings and boarding commercial airline flights.

Some 275,000 illegal immigrants live in Maryland, according to a recent study. An additional 400,000 live in states that neighbor Maryland, including the District and Virginia.

The state Senate last month approved the measure 29 to 18. Raquel Guillory, the governor’s spokeswoman, said O’Malley would sign it into law.

In light of the state’s lengthy debate this year on tightening gun-control laws, opponents were able to successfully tack on one provision requiring the state to make clear on the licenses that they are not valid for purchases of firearms.

The action on the driver’s license bill came as the House and Senate also gave final approval to a nearly $37 billion spending plan. The budget increases overall spending by nearly 3 percent and includes raises for state employees, new tax credits and more money for school security after the December massacre in Newtown, Conn.