NORTH CHARLESTON, S.C. — The Republican presidential candidates sparred over their respective qualifications for the White House in a lively debate Thursday night, and front-runner Donald Trump gave an impassioned defense of his harshly nativist rhetoric that has been a defining feature of the campaign.

Trump was put on the defensive this week not by any of his rivals on stage, but by Nikki Haley, the South Carolina governor who, in the GOP response to President Obama's State of the Union speech Tuesday, delivered a thinly veiled rebuke to Trump's campaign. She urged Americans to resist "the siren call of the angriest voices,'' an obvious reference to Trump.


Asked to respond, Trump did not lash out at Haley, who was in the audience. But he strongly defended his frequent attacks on Latin American and Syrian immigrants as a required response to the Obama administration's policies.

"I will gladly accept the mantle of anger," he said. "Our military is a disaster. Our health care is a horror show. Obamacare, we're going to repeal it and replace it. We have no borders. Our vets are being treated horribly. Illegal immigration is beyond belief. Our country is being run by incompetent people. And yes, I am angry."

With less than three weeks to go until the Iowa caucuses, the debate took place several miles away from the Emanuel African Methodist Episcopal Church, where nine people were shot and killed in June while participating in a Bible study. Obama has renewed his efforts to pass tighter gun control legislation, and is taking several executive actions that Republicans have criticized as an unnecessary infringement on the constitutional right to bear arms.

The GOP rivals maintained a drumbeat of criticism over those moves Thursday, with several equating them to the acts of a desperate imperial president with no regard to Congress or the American public. Senator Ted Cruz of Texas, in particular, was adamant that the Second Amendment right of gun ownership was ironclad, saying he led the fight against any gun control in the Senate. Trump implied that if victims of last month's terrorist attack in San Bernardino, Calif., had guns, they would have survived the assault.


"This guy is a petulant child," New Jersey Governor Chris Christie said of Obama's use of executive actions to change gun regulations.

The debate, sponsored by Fox Business Network, featured the fewest number of candidates — seven — of any GOP debate this primary season and with fewer principals on stage there were more one-on-one, pointed exchanges. The lineup offered two competing subplots: Cruz and Trump battling for the mantle of top outsider, while a quartet of others — Senator Marco Rubio of Florida, former Florida governor Jeb Bush, Christie, and Governor John Kasich of Ohio — brandished their experience in government as they vied to top the list of mainstream conservatives. (Retired neurosurgeon Ben Carson occupied the seventh spot, but his star has faded with the loss of social conservatives to Cruz and disruptions in his top campaign staff.)

The debate presented one of the last opportunities to shake up a race that has been fundamentally unchanged for months. There is only one more debate before the Feb. 1 caucuses, with candidates facing off in Des Moines on Jan. 28.

Some of the most intense exchanges came between Trump and Cruz, who over the past week have abandoned a fragile truce that benefited them both earlier in the race. Instead, they have been on the brink of the sort of "cage match" that Cruz once said he wanted to avoid.


Cruz has said Trump "embodies New York values," a direct reference to urban liberalism and a coded allusion to Trump's two failed marriages.

"I think most people know exactly what New York values are," Cruz said. "Not a lot of conservatives come out of Manhattan. I'm just saying." Trump referenced the Sept. 11, 2001, attacks, the national unity, the dismay of New Yorkers, and the "smell of death."

"That was a very insulting statement that Ted made," he said.

Trump — who spent years calling for Obama to release his long form birth certificate to prove he was born in Hawaii — has repeatedly raised doubts about Cruz's legal qualifications to be president because of his birth, to an American mother, in Canada. The Constitution requires the chief executive to be a natural-born citizen. Trump's remarks have fueled a debate about whether Cruz qualifies.

"There's a big question mark on your head, and you can't do that to the party," Trump said. "Who the hell knows if you can run for office?"

"Listen, I've spent my entire life defending the Constitution," Cruz responded. "And I'm not going to be taking legal advice from Donald Trump."

"I recognize that Donald is dismayed that his poll numbers are falling," Cruz added.


Eventually, Rubio jumped in and said, "I hate to interrupt this episode of Court TV."

The nominating contest has become a divisive referendum on the current state of the Republican Party. The dominance of Trump, a casino magnate and media personality who has never held elective office, and Cruz, a first-term senator from Texas who has been criticized for his obstructionist tactics, reflects a deep distrust of Washington politicians.

Longtime party stalwarts have struggled to make sense of the new dynamics, questioning why flaws that in the past would have proved fatal have had little impact this time. Although he's been married three times, Trump is popular among evangelical Christians. He has a history of liberal positions — supporting single-payer health care during a short-lived presidential campaign in 2000, for example — that would have sunk other GOP candidates.

Trump also has proved adept at skewering his opponents with simply phrased but devastating insults and put-downs. His attack on Cruz's qualifications is an example of sowing doubt about his rivals.

Cruz has also faced new scrutiny over his finances, and Thursday night was his first chance to respond. The New York Times reported Thursday that Cruz did not properly disclose to the Federal Elections Commission a loan from Goldman Sachs of up to $1 million, which was used to help fund his 2012 Senate campaign.

"The New York Times and I don't exactly have the warmest of relationship," Cruz said. He admitted that he made "a paperwork error," but largely dismissed the criticism.


The primary campaign has grown particularly intense among candidates trying to break out of the pack in New Hampshire. Those candidates are fighting to consolidate the more mainstream Republican and moderate votes with the hopes that they could then face off against Trump or Cruz. On the campaign trail, it sometimes has the feel of a circular firing squad.

Christie and Bush have criticized Rubio for not showing up enough for Senate votes in Washington, and for being too young and inexperienced. Rubio and Bush have criticized Christie for the more liberal positions he adopted in the past in New Jersey. Christie and Rubio have criticized Bush for criticizing them.

"Unfortunately, Governor Christie has endorsed many of the ideas that Barack Obama supports," Rubio said, listing a series of issues. "Our next president, and our Republican nominee can not be someone who supports those positions."

Christie gave a long answer, pushing back on several of the charges and then used Rubio's own words to defend himself.

"Two years ago, he called me a conservative reformer that New Jersey needed," Christie said. "That was before he was running against me. Now that he is, he's changed his tune."

Rubio has been seen as a strong contender with some of the greatest potential in the field. But his willingness to push for an immigration overhaul in 2013 has also come under renewed scrutiny.

Toward the end of the debate — after Cruz accused Rubio of being weak on immigration — Rubio unleashed a series of criticisms against Cruz, saying he'd switched his positions on a variety of issues.

"That is not consistent conservatism," he said. "That is political calculation"

"I appreciate you dumping your oppo research folder in the debate," Cruz said.

"No," Rubio responded. "It's your record."

Bush, who has been trying to overcome Trump's tag that he is "low energy," eventually jumped in and said the debate between "two back-bench senators" illustrated why voters were so aggravated with Washington. Bush also became impassioned while criticizing Trump's proposal to temporarily ban Muslims from entering the United States. Trump was asked if he had any regrets about the proposal. "No," he said. "We have to stop with political correctness."

"Ban all Muslims? Seriously?" Bush said, incredulously. "What kind of signal does that send to the rest of the world that the United States is a serious player in creating peace and security?"

Trump then again returned to the themes that have driven his campaign.

"I want security," he said. "I'm tired of seeing what's going on, between the border where the people flow over; people come in; they live; they shoot. I want security for this country. We have a serious problem with, as you know, with radical Islam. We have a tremendous problem."

Matt Viser can be reached at matt.viser@globe.com.