Michael Zehal-Bibeau, who killed a ceremonial guard at Ottawa's war memorial before bursting into parliament where he was shot dead, made the video message on a phone found in his abandoned car.
"This is in retaliation for Afghanistan and because (Prime Minister Stephen) Harper wants to send his troops to Iraq," Zehaf-Bibeau says in the grainy video released by police.
"Canada's officially become one of our enemies by fighting and bombing us and creating a lot of terror in our countries and killing us and killing our innocents," added the 32-year-old.
Zehaf-Bibeau, a petty criminal who later converted to Islam, was shot dead by parliamentary security and federal police in a hail of bullets.
More From This Section
Royal Canadian Mounted Police Commissioner Bob Paulson told a parliamentary committee the federal police edited out 18 seconds of the video before releasing it -- 13 at beginning and five at the end -- but did not explain what had been cut.
The committee is examining a proposed new anti-terror law written in response to Zehaf-Bibeau's attack and another on a Canadian soldier in rural Quebec the same week. It would provide sweeping new powers to Canada's spy agency.
Canada ended its 10-year military mission in Afghanistan last year. In November its war planes joined US-led airstrikes on Islamic State jihadists in Iraq.
Paulson also testified at the hearing that the RCMP continues to search for possible accomplices or others who may be involved in planning the attack.
"The RCMP believes, on the evidence, that Zehaf-Bibeau was a terrorist," he said. "Anyone who aided him, abetted him, counseled him, facilitated his crimes or conspired with him is also, in our view, a terrorist and, where the evidence exists, we will charge them with terrorist offences."
Paulson said more than 400 people have been interviewed so far as part of the investigation into the shooting rampage.
While in Ottawa, Zehaf-Bibeau used public Internet and payphones to communicate with individuals in Ottawa and British Columbia province.