Alyssa Rosenberg has a good discussion of the anti-torture themes in the Harry Potter series. But she neglects two other ways in which J.K. Rowling critiques the US conduct of the war on terror: Azkaban and arbitrary detention.
Harry’s disdain for the ministry in The Half-Blood Prince focuses on their detention of Stan Shunpike in Azkaban — Stan’s obvious innocence doesn’t deter Minister of Magic Rufus Scrimgeour from scapegoating the young man as part of his effort to create the illusion of security in the Wizarding world. Indeed, Azkaban itself could be any number of soul-devouring prisons in the Muggle world, but in the the last few books it sometimes seems a stand in for Guantanamo Bay.
Given the obvious connections between the Death Eaters and terrorist organizations — from their methods to their cell-structure organization — it doesn’t take much to read the later novels as, in part, a claim that state terror, whatever its purpose, inevitably corrupts democratic governance and renders it vulnerable to fascism and totalitarianism.
(note: I’ve edited this post a bit. Still getting used to blogging from iPad)