Sen. Ted Cruz (R-Tex.), above, accused Sen. Marco Rubio (R-Fla.) of not supporting border security efforts in the United States. (Mark Kauzlarich/Reuters)

Sen. Ted Cruz (R-Tex.), who has spent the past few weeks taking oblique swipes at Senate colleague and presidential campaign rival Marco Rubio (R-Fla.), took a direct swing at him Thursday in a clash that signaled a newly bitter fight between the two rising candidates — and illustrated the GOP field’s contentious fault lines on immigration policy.

Cruz blasted Rubio for his support of a failed immigration reform bill that would have granted a pathway to citizenship for illegal immigrants, telling conservative radio host Laura Ingraham that Rubio had opposed adding provisions to the bill that would have strengthened border security.

“He opposed every single one of them. Every single amendment,” said Cruz, who had introduced some of those amendments. “It’s not like people were quiet in sharing their concerns at the time. It’s not like one had to engage. . . . It’s not like this was rocket science.”

Rubio pushed back on those claims Thursday, saying that the bill had the correct security components but was waylaid by voter mistrust — and arguing that he and Cruz shared “almost all the same views on immigration.”

“Ted is a supporter of legalizing people that are in this country illegally,” Rubio said after a campaign stop in South Carolina. “In fact, when the Senate bill was proposed, he proposed giving them work permits. He’s also supported a massive expansion of the green cards. He’s supported a massive expansion of the [H-1B visa] program, a 500 percent increase.”

“Ted is a supporter of legalizing people that are in this country illegally,” Rubio, above, said after a campaign stop Thursday in South Carolina. (Josh Mitelman/The Island Packet via AP)

As the campaigns battled Thursday, other candidates jumped into the fray. Sen. Rand Paul (R-Ky.) said Rubio’s tax plan would give money to illegal immigrants, and called him “the leading proponent for allowing people in the country illegally to be citizens.” Former Arkansas governor Mike Huckabee called the H1-B program “worse than amnesty.” And Rick Santorum turned his sights on Cruz, with the campaign of the former senator from Pennsylvania saying Cruz was “not a real conservative on immigration.”

Donald Trump on Thursday ratcheted up his attacks on Rubio, saying he is “weak on illegal immigration, you know that. Weak — Rubio — weak on illegal immigration. Like weak like a baby. Like a baby.”

On CNN’s “Erin Burnett OutFront” Thursday night, Burnett noted to Trump that Rubio is Hispanic and that his parents are Cuban.

“That’s why he wants amnesty,” Trump said.

But the toughest blows of the day were exchanged by the Cruz and Rubio camps, who have both gained momentum in the wake of strong debate performances. Cruz spokeswoman Catherine Frazier said Thursday that Rubio’s claim that Cruz is in favor of legalizing illegal immigrants is “simply not true.” Cruz has supported increasing the number of H-1B visas — at one point, as much as fivefold — but has since said he now believes the system needs to be reformed before the number can be increased. He has also called for doubling the caps on green cards.

Rubio’s campaign tweeted a video Thursday afternoon from an account called “Hypo-Cruz” that showed Cruz discussing his amendments to the bill, saying that one would prevent illegal immigrants from obtaining citizenship, but would grant them work permits.

Frazier said the amendment was a gesture intended to highlight “the hypocrisy of the Democrats” focused on a path to citizenship. “He had to work within the parameters of something that was already fundamentally flawed,” she said.

Cruz has said he is a strong supporter of legal immigration. He defended Trump’s remarks on immigration when the billionaire came under attack earlier this year, and has also not answered the question of what he would do with the 11 million people in the United States illegally, stating that the border must be secured first.

When asked by Ingraham on Thursday about increasing the number of foreign workers coming into the United States, Cruz said: “I don’t believe that’s a good idea.”

As Cruz and Rubio have ascended of late, Cruz has slowly tried to highlight policy differences between the two, drawing contrasts between them even as he rarely mentioned Rubio by name.

During Tuesday night’s debate, Cruz made an unprompted call for an end to sugar subsidies, calling them “corporate welfare.” Rubio has aggressively supported the subsidies. Cruz has made veiled references to Rubio’s spotty Senate voting record and his support for the immigration bill.

There have been more pointed references, such as when Cruz knocked Rubio on trade and called him a “moderate,” a subtle dig at a candidate who came into office as a Tea Party darling.

But Cruz on Thursday took the gloves off in response to Ingraham’s questions, which were pointedly about Rubio and the bipartisan “Gang of Eight” coalition that introduced the 2013 immigration bill.

“The Gang of Eight, all eight of them, agreed to vote against every amendment that would strengthen the bill from an enforcement perspective,” Cruz said. “The Gang of Eight voted as a gang against enforcing and securing the border.”

At a Chamber of Commerce summit in Hilton Head, S.C., Rubio offered a defense of the “Gang of Eight” bill.

“I was involved in an effort in 2013 to try to fix our immigration issue,” Rubio said, in response to a friendly question about how immigration policies affected agriculture. “There was a powerful lesson from 2013. The American people do not trust the federal government to enforce our immigration policies. That exists even if you pass a law that says we’re going to build more walls, we’re going to have e-verify, we’re going to have an entry/exit tracking system. That was a shocking realization.”

Rubio did not blame the collapse of the process on the 2014 migrant crisis or President Obama’s executive orders, but he quickly did so in a press conference after the event.

“It’s going to be impossible to move forward until you can prove to people that illegal immigration is under control,” Rubio said. “If you can prove that it’s under control, I honestly believe it opens up the ability to make these changes.”

Asked about Cruz’s charges, Rubio said that the immigration reforms needed after border security was addressed did not amount to “amnesty.” He did not discuss any ways that foreign-born workers who entered the United States illegally could become citizens, only how some could earn 10-year work permits. And he argued that “every candidate on [the debate] stage” — including Cruz — favored some sort of legalization for workers now in the country illegally.

“If you look at it,” Rubio said, “I don’t believe our positions are dramatically different.”