Mr Cameron said the prime minister was making a mistake
David Cameron has urged the prime minister to make his controversial plans to extend the detention limit for terror suspects a vote of confidence.
The Tory leader claimed to have been sent a Labour report detailing its MPs' concerns over the controversial plans.
He said Mr Brown was sticking with them as part of a "political calculation" to appear "tough on terror".
Mr Brown said Mr Cameron was a "shallow salesman" who did not address the substance of issues.
Home Secretary Jacqui Smith has been meeting potential Labour rebels to try to win them over to the government's plans to extend the limit on holding suspects without charge from 28 to 42 days. A vote is expected mid-June.
At prime minister's questions Mr Cameron read out a list of comments on a report leaked from the Labour whips' office, suggesting many Labour MPs would oppose the plans.
He asked whether the prime minister would "admit that he's going to have to make major concessions" in order to see off a backbench rebellion.
The prime minister denied it, saying the proposals would be put to the House of Commons and urged opposition parties to vote for them.
But Mr Cameron asked why the PM would not listen to the director of public prosecutions, the former attorney general and former lord chancellor who oppose the plans.
Mr Brown said concerns about "arbitrary detention" had been addressed, by making the power dependent on the home secretary having to come to Parliament to make an order, and giving new powers to the judiciary and independent reviewer of terrorism laws to rule on each individual case.
But Mr Cameron asked him: "How far will he take this battle with his party? Will this vote be an issue of confidence for his government?"
Mr Brown repeatedly said he would bring the plans before the house and said the Conservatives were making "a mistake" in opposing the plans and said Mr Cameron should be "ashamed".
Mr Brown argued the plans were supported by the UK's most senior policeman, Sir Ian Blair, and said Mr Cameron was not addressing "the substantial issue" - ensuring the power in law was in place to go beyond 28 days, in the event of a "substantial terrorist incident".
But Mr Cameron accused Mr Brown of pushing the plans through, not because he thought they were right, but because he wanted to appear "tough on terror" in the same way he had abolished the 10p tax rate to appear as a "tax cutter".
In a reference to a BBC interview earlier, Mr Cameron said: "Today apparently he's admitting mistakes, why doesn't he admit the biggest mistake of all - he puts political calculation and self interest ahead of the right decisions and the national interest?"
Mr Brown replied: "Once again he never addresses the substance of the question.
"This is the man who wants to be both tough on crime and hug a hoodie at the same time. This is the man, where political calculation meant he cycled to work, but at the same time he had the chauffeur-driven car coming behind.
"This is the man who's a shallow salesman and never addresses the substance of the issue."
He said the evidence before the government was that police needed 42 days to question suspects - and urged the Conservatives to "think again".