“This is war, and I know war is ugly, and is violent. And I know young people sometimes caught up in the moment make some very foolish decisions,” Panetta told a news conference during a meeting of NATO allies in Brussels. “I am not excusing that.”

He added: “My apology is on behalf of the Department of Defense and the US government ... Again, that behavior is unacceptable.”

Panetta said he regretted the decision of the Los Angeles Times to publish some of the photos, which he said might trigger retaliatory violence against foreign soldiers stationed in Afghanistan.

“Neither do I want these images to bring further injury to our people, or our relationship with the Afghan people. Those kinds of photos are used by (the) enemy to incite violence, and lives have been lost as a result,” he said.