Retired Marine General James Mattis, President-elect Donald Trump's nominee for the post of Defense Secretary, said Thursday that the capital of Israel was Tel Aviv.

>> Get all updates on the U.S. and Israel: Download our App, sign up to Breaking News Alerts, and Subscribe >>

"Right now, I'd stick with the U.S. policy," the retired Marine general told Republicans and Democrats on the Senate Armed Services Committee, which is vetting his nomination. "The capital of Israel that I go to is Tel Aviv."

Mattis made the statement in response to a question posed to him by Sen. Lindsey Graham. Official U.S. policy doesn't recognize Israeli sovereignty in Jerusalem, which Israel claims as its capital. The U.S. embassy is in Tel Aviv, however U.S. policy doesn't explicitly state that Tel Aviv is Israel's capital.

Mattis also explained that "that's where all the government people are." While Israel's Prime Minister's Office and the Ministry of Foreign Affairs are both located in Jerusalem, the Israeli Defense Ministry and the IDF headquarters - two places that Mattis has visited many times when he served in the U.S. military - are in fact located in Tel Aviv.

>> Meeting with Kushner’s friend convinced Abbas: Trump serious about moving U.S. embassy >>

Mattis also said during the discussion that he supports the two-state solution - "if it brings peace to the Middle East" - but that he was also open to hearing other ideas. Mattis added that solving the Israeli-Palestinian is a "vital interest" for the United States.

Mattis also said that the maintenance of Israel's qualitative military edge in the region is dependent on "improved relationships" between Israel and its Arab neighbors. "We can help with that," he added.

Mattis described Israel as a "fellow democracy" with the United States and said that there were no other democracies in the Middle East.

Regarding the Iranian nuclear agreement, Mattis said that he thought it could be adequately monitored by the U.S. but that he needed to "see the actual data" before giving an authoritative answer. He called Iran "the biggest destabilizing force in the Middle East."

He also declined to condemn the recent United Nations Security Council resolution against the Israeli settlements, saying that he would need to "get back to look at that." While maintaining that he "has no authoritative view" on the issue, Mattis, who previously severely criticized Israel's settlements in the West Bank, stressed that the U.S. needed to restore good relations between Israel and the Palestinians. "It's time to build trust," he said. "We should be a partner."

Asked whether the U.S. needed to assist Israel in restoring its military qualitative edge, Mattis responded that he was not aware that the qualitative edge doesn't exist right now.

Mattis, who retired from the Marine Corps in 2013, will need a waiver from Congress to dodge the requirement that a military officer must be retired for at least seven years before serving as Pentagon chief.

After Mattis' testimony, the waiver cleared its first hurdle in Congress when the Senate Armed Services Committee approved it in a 24-3 vote.

Mattis ran U.S. Central Command in from August 2010 to March 2013. In that position he had command authority for all U.S. forces in the Middle East.

“I paid a military security price every day as the commander of CentCom because the Americans were seen as biased in support of Israel, and that moderates all the moderate Arabs who want to be with us, because they can’t come out publicly in support of people who don’t show respect for the Arab Palestinians,” Mattis said in 2013 at the Aspen Security Forum in Colorado.

At the same forum he criticized Israel for settlement building, saying that the settlements “are going to make it impossible to maintain the two-state option.”

He said the settlements would undermine Israel as both a Jewish and Democratic state, and said the settlements would lead to apartheid.

“If I’m in Jerusalem and I put 500 Jewish settlers out here to the east and there’s 10,000 Arab settlers in here, if we draw the border to include them, either it ceases to be a Jewish state or you say the Arabs don’t get to vote — apartheid,” he said.

Mattis was an outspoken critic of the Iran nuclear deal, which exchanged a nuclear rollback for sanctions relief.