Labour's defence review will learn lessons from Iraq, Afghanistan and Libya that are "sadly lacking" from the National Security Strategy and Strategic Defence and Security Review (SDSR), Jeremy Corbyn has said.

The Labour leader was derided by Tory MPs for his response to Prime Minister David Cameron's statement on plans for security and defence spending.

Mr Corbyn called for a human rights adviser to be placed in every embassy, questioned Mr Cameron on a wide range of issues including climate change and food security, and repeated warnings about neighbourhood policing.

Mr Corbyn, whose remarks were not loudly cheered by his own side, also questioned the choice of new maritime patrol aircraft and the number of frigates due to be purchased, but added: "(Our review) will recognise security is about much more the defence."

The Prime Minister dismissed his Labour shadow, telling MPs: "The best that can be said about that is the longer you went on the less you had to say."

Mr Corbyn urged the defence review to be updated in light of the publication of Chilcot Inquiry next year.

He said: "How will you apply lessons learned in Libya, Iraq, Afghanistan and elsewhere to Britain's role in the escalating war in Iraq and Syria, ensuring further disastrous mistakes are avoided?

"Britain does need strong military and security forces to keep us safe and to take a lead in humanitarian and peacekeeping missions, working with and strengthening the United Nations.

"There is no contradiction between working for peace across the world and doing what is necessary to keep us safe at home. The shadow defence secretary (Maria Eagle) will be leading a review about how we deliver that strong, modern protection for the people of Britain.

"Our review will seek to learn the lessons from Iraq, Afghanistan and Libya, and look to our military capabilities and requirements in that light. We owe it to our Armed Forces and the country as a whole to engage in the kind of review which is sadly lacking today."

Mr Corbyn said Labour would review what else money due to be invested in the renewal of the Trident nuclear deterrent could be spent on.

He said: "Can you confirm the reduction in the number of Type 26 frigates we are procuring from 13 to eight will not impact on the Navy's ability to protect the carriers?

"Can you give some reassurance to the workers on the Clyde? Last year they were told 13 ships would be built, now it is eight - can you confirm this is simply a first batch and 13 frigates still stands?"

Returning to his own review, Mr Corbyn said Labour would "question the wisdom" of British arms sales to "repressive regimes with links to the funding of terrorism".

He said: "It will look to fulfil the huge potential the country has to lead the way in peacekeeping, conflict resolution and peace building."

Mr Corbyn said the "focus" was on tackling terrorism and defeating Isil, making it clear Labour supports increased security spending.

But he added: "However, faced with the current threat, the public will not understand or accept any cuts to frontline policing.

"Everyone will be very concerned about the warnings we know you have had from security officials and police that the cuts will reduce very significantly the ability to respond to a Paris-style attack.

"Cuts to neighbourhood policing will damage the flow of vital intelligence that helps prevent such attacks - will you give an undertaking that police budgets after the review will be sufficient to guarantee no reductions in police or police community support numbers and protect areas such as helicopter cover?"

Mr Corbyn said there was "insufficient analysis" of global threats such as "inequality, poverty, disease, human rights abuses, climate change and water and food security".

The remark prompted barracking from the Tory benches, forcing the Labour leader to add: "I have no idea why MPs opposite find food security such a funny subject."

Mr Corbyn raised concerns about low morale in the armed forces and linked it to caps in pay and revised pension rules.

In his response, Mr Cameron said: "Most of your statement was spent talking about the importance of having troops within the UN, the importance of ship building on the Clyde, the importance of investing in defence, the importance of having high morale amongst our armed forces.

"Yet only two months ago, you said this: 'Why do we have to be able to have planes, transport aircraft, aircraft carriers, and everything else to get anywhere in the world? Why?'.

"Are you the same MP sitting opposite thinking of all these uses for our armed forces when just a few months ago you thought there were none."

Mr Cameron said the Government was "safeguarding" investment in counter-terrorism policing.

He added: "You might want to have a word with the shadow chancellor who recently signed up to a proposal, and I quote, 'at a time when we face this heightened security threat to disband MI5 and special police squads and to disarm the police'.

"You think they shouldn't use their weapons, the shadow chancellor thinks they shouldn't have any at all - that is presumably what passes for a defence policy."

Mr Cameron said there are no proposals to reduce pay for armed forces personnel or change "very generous" pension arrangements, adding morale will be boosted by the announcements to increase the size of the military.

He told Mr Corbyn: "One of the best things for morale in our services is that those serving in our army, navy or air force - or planning to join our army, navy or air force - they can now see it's going to be a bigger navy with more ships, they can see it's going to be a bigger air force with more planes and more people, and they can see our armed services are going to be better equipped and better supplied than they ever have been before."

On learning the lessons of previous conflicts, the PM said: "We're determined to do that and that's part of what the inquiry into the Iraq War should be all about.

"But we haven't waited for that to learn the lesson, which is it's so important that we bring together military strategy, diplomatic strategy, political strategy and indeed development strategy. All these things should go together."

Reflecting on UK air strikes in Libya, Mr Cameron said: "Clearly we need to make sure in these situations that there are governments and states that can continue, but I do not apologise for one minute for stepping in with France and preventing Colonel Gaddafi from murdering his own people in his own country."

He said Britain will look at developing a new "multi-purpose" frigate, telling MPs: "Not only one we can create for ourselves but hopefully one we'll be able to sell more overseas as well.

"And this opens the possibility to seeing the number of capital ships in our navy going up rather than down."

The PM recalled a quote from Mr Corbyn, noting that the Opposition leader said in August: "Wouldn't it be wonderful if every politician around the world instead of taking pride in the size of their armed forces did what others have done and abolished their army and took pride in the fact they don't have an army."

Mr Cameron added: "I know it's depressing for people sitting opposite but they might as well know about it, that's the view of the leader of the Opposition."

Conservative former defence secretary Liam Fox said he would like to "unequivocally welcome" the decision to buy new maritime patrol aircraft, adding that "Labour's catastrophic management" of the Nimrod programme had left a gap in this service since 2010.

In response to questions from Mr Fox, the PM said the Royal Navy's personnel will increase by 400 due to decisions in the SDSR.

Senior Conservative Julian Lewis said he believes many MPs on the Defence Select Committee, which he chairs, will "find at least some relief in the plugging of gaps" by the new proposals.

He pressed Mr Cameron about the pay of armed forces personnel and when the contracts for the submarines that carry Britain's Trident nuclear deterrent will be brought before Parliament.

The PM replied: "What I can tell you about pay is that we're keeping the annual pay upgrade and the increments that our armed forces have."

On Trident, Mr Cameron said: "The Main Gate decision, we will be moving ahead with the four submarines and obviously at the appropriate moment we'll want to have a vote in this House."

Meanwhile, Angus Robertson, the SNP's leader in Westminster, hit out at the plan to replace Trident, labelling it a "super expensive vanity project".

The review suggests replacing the Royal Navy's fleet of submarines that carry the UK's nuclear missiles could cost up to £40 billion.

The Ministry of Defence has estimated the cost to be £31 billion but it has also set aside a contingency fund worth £10 billion.

Previous estimates suggested the project would cost £25 billion.

Mr Robertson told the House: "As we learn its replacement is ballooning and will be squeezing out defence alternatives, how expensive does Trident need to be for this Government to realise that it is a super expensive vanity project that does not deter?

"It has not deterred... against terrorism or cyber attack or conventional attacks on the UK and its allies and friends.

"Even at this late stage, may I appeal to the Government and to the Labour Party to realise that it is a huge mistake to renew Trident.

"May I remind them both that in Scotland an overwhelming majority of our parliamentarians and civic organisations, from our national churches and faith groups to the Scottish Trade Union Congress, are all opposed.

"What kind of family of nations with a respect agenda imposes something on one of its members against its will?"

But Mr Cameron hit back.

"It is clearly not squeezing out other defence requirements as this document so clearly shows today," he said.

"Here is the rub: The SNP describe themselves as the effective opposition.

"Well yes, they are wholly opposed to Trident, and therefore wholly unsuited to government."