"Down poured the wine like oil on blazing fire. And still the riot went on - the debauchery gained its height - glasses were dashed upon the floor by hands that could not carry them to lips, oaths were shouted out by lips which could scarcely form the words to vent them in; drunken losers cursed and roared; some mounted on the tables, waving bottles above their heads and bidding defiance to the rest; some danced, some sang, some tore the cards and raved. Tumult and frenzy reigned supreme ..." Nicholas Nickleby, by Charles Dickens, 1839.

All politicians who seek to justify repressive legislation claim that they are responding to an unprecedented threat to public order. And all politicians who cite such a threat draft measures in response which can just as easily be used against democratic protest. No act has been passed over the past 20 years with the aim of preventing antisocial behaviour, disorderly conduct, trespass, harassment and terrorism that has not also been deployed to criminalise a peaceful public engagement in politics. When Walter Wolfgang was briefly detained by the police after heckling the foreign secretary last week, the public caught a glimpse of something that a few of us have been vainly banging on about for years.

On Friday, six students and graduates of Lancaster University were convicted of aggravated trespass. Their crime was to have entered a lecture theatre and handed out leaflets to the audience. Staff at the university were meeting people from BAE Systems, Rolls-Royce, Shell, the Carlyle Group, GlaxoSmithKline, DuPont, Unilever and Diageo, to learn how to "commercialise university research". The students were hoping to persuade the researchers not to sell their work. They were in the theatre for three minutes. As the judge conceded, they tried neither to intimidate anyone nor to stop the conference from proceeding.

They were prosecuted under the 1994 Criminal Justice Act, passed when Michael Howard was the Conservative home secretary. But the university was able to use it only because Labour amended the act in 2003 to ensure that it could be applied anywhere, rather than just "in the open air".

Had Mr Wolfgang said "nonsense" twice during the foreign secretary's speech, the police could have charged him under the Protection from Harassment Act 1997. Harassment, the act says, "must involve conduct on at least two occasions ... conduct includes speech". Parliament was told that its purpose was to protect women from stalkers, but the first people to be arrested were three peaceful protesters. Since then it has been used by the arms manufacturer EDO to keep demonstrators away from its factory gates, and by Kent police to arrest a woman who sent an executive at a drugs company two polite emails, begging him not to test his products on animals. In 2001 the peace campaigners Lindis Percy and Anni Rainbow were prosecuted for causing "harassment, alarm or distress" to American servicemen at the Menwith Hill military intelligence base in Yorkshire, by standing at the gate holding the Stars and Stripes and a placard reading "George W Bush? Oh dear!" In Hull a protester was arrested under the act for "staring at a building".

Had Mr Wolfgang said "nonsense" to one of the goons who dragged him out of the conference, he could have been charged under section 125 of the Serious Organised Crime and Police Act 2005, which came into force in August. Section 125 added a new definition of harassment to the 1997 act, "a course of conduct ... which involves harassment of two or more persons". What this means is that you need only address someone once to be considered to be harassing them, as long as you have also addressed someone else in the same manner. This provision, in other words, can be used to criminalise any protest anywhere. But when the bill passed through the Commons and the Lords, no member contested or even noticed it.

Section 125 hasn't yet been exercised, but section 132 of the act is already becoming an effective weapon against democracy. This bans people from demonstrating in an area "designated" by the government. One of these areas is the square kilometre around parliament. Since the act came into force, democracy campaigners have been holding a picnic in Parliament Square every Sunday afternoon (see www1.atwiki.com/picnic/). Seventeen people have been arrested so far.

But the law that has proved most useful to the police is the one under which Mr Wolfgang was held: section 44 of the Terrorism Act 2000. This allows them to stop and search people without the need to show that they have "reasonable suspicion" that a criminal offence is being committed. They have used it to put peaceful protesters through hell. At the beginning of 2003, demonstrators against the impending war with Iraq set up a peace camp outside the military base at Fairford in Gloucestershire, from which US B52s would launch their bombing raids. Every day - sometimes several times a day - the protesters were stopped and searched under section 44. The police, according to a parliamentary answer, used the act 995 times, though they knew that no one at the camp was a terrorist. The constant harassment and detention pretty well broke the protesters' resolve. Since then the police have used the same section to pin down demonstrators outside the bomb depot at Welford in Berkshire, at the Atomic Weapons Establishment at Aldermaston, at Menwith Hill and at the annual arms fair in London's Docklands.

The police are also rediscovering the benefits of some of our more venerable instruments. On September 10, Keith Richardson, one of the six students convicted of aggravated trespass on Friday, had his stall in Lancaster city centre confiscated under the 1824 Vagrancy Act. "Every Person wandering abroad and endeavouring by the Exposure of Wounds and Deformities to obtain or gather Alms ... shall be deemed a Rogue and Vagabond... " The act was intended to prevent the veterans of the Napoleonic wars from begging, but the police decided that pictures of the wounds on this man's anti-vivisection leaflets put him on the wrong side of the law. In two recent cases, protesters have been arrested under the 1361 Justices of the Peace Act. So much for Mr Blair's 21st century methods.

What is most remarkable is that until Mr Wolfgang was held, neither parliamentarians nor the press were interested. The pressure group Liberty, the Green party, a couple of alternative comedians, the Indymedia network and the alternative magazine Schnews have been left to defend our civil liberties almost unassisted. Even after "Wolfie" was thrown out of the conference, public criticism concentrated on the suppression of dissent within the Labour party, rather than the suppression of dissent throughout the country. As the parliamentary opposition falls apart, the extra-parliamentary one is being closed down with hardly a rumble of protest from the huffers and puffers who insist that civil liberties are Britain's gift to the world. Perhaps they're afraid they'll be arrested.

www.monbiot.com