IN THE Haskell Free Library and Opera House, which straddles Quebec and Vermont, you can watch a show with one foot in Canada and the other in the United States. Built at the turn of the last century, when both countries boasted about the world’s longest undefended border, the cultural centre was created for Derby Line, Vermont, and Stanstead, Quebec. Nancy Rumery, the librarian, says the towns were a “single community that just happened to have an imaginary line drawn through it.”

Al-Qaeda’s September 2001 attacks on America put paid to that. You can still park in Canada and walk across the border to the front door. But now American officials watch to make sure you go back the same way. Elsewhere in the twin towns, movement has been curbed; gates have turned streets into dead ends. Although Derby Line and Stanstead share water and sewerage systems and a Rotary Club, they are no longer one community, says Brian Smith, a local politician.

Many locals hesitate to cross the border to shop, worship or see friends—for fear of being detained and fined, as befell a local pharmacist who did not report to customs when he crossed over to get a pizza. “It’s not like it used to be,” says Mr Smith.

The attack in Ottawa last month by a lone gunman, who killed a Canadian soldier and stormed parliament, seems likely to make matters worse. Although there is still uncertainty about the motives of the gunman, Michael Zehaf-Bibeau—possibly a deranged outcast, possibly a religious extremist—the United States is reviewing security along the 5,525-mile (8,890km) line which separates the two countries (including the Alaskan land border). After meeting his Canadian counterpart in Ottawa in the wake of the attacks, John Kerry, the United States secretary of state, was euphemistic but firm about the need to tighten up. He voiced confidence that the two countries could come up with “some tweaks, some changes, some additions that will promote even greater security than we have today.” It is debatable whether more security on what Senator John McCain recently called the “porous” northern border really will make Americans much safer from terrorism. But it seems hard for politicians to shake off the habit of Canada-bashing. Both Mr McCain and Hillary Clinton (in 2004) have stated, wrongly, that the 9/11 terrorists entered American territory through Canada. An article on the politico.com website last month (before the Ottawa shootings) had the headline: “Fear Canada: the real terrorist threat next door”. What is more certain is that “tweaks and changes” will impede economic exchanges between two countries who are each others’ largest trading partners; and they may further fray social relations between once-friendly neighbours. Nik Nanos, a pollster who has tracked cross-border attitudes for a decade, says Canadians and Americans still like each other but have lost enthusiasm for further co-operation, most notably on terrorism.

Unlike the turbulent border with Mexico, the northern frontier usually gets little attention in the United States. It “just doesn’t squeak as loud as the southern border,” says Paul Frazer, a consultant on diplomatic affairs. Jeh Johnson, homeland-security secretary in the United States, gave a speech on “Border Security in the 21st Century” last month in which the only allusions to Canada were about the 1920s.

Illegal immigration, which haunts American relations with Mexico, is less of a concern in Canada’s case. Of the 420,789 people apprehended by America’s border patrol in 2013, 98% were caught on the country’s south-western edge. On the northern side, guns and drugs are the big worry, says Jose Acosta, an American patrol officer who knows both frontiers and now works near Abbotsford, British Columbia. “We have Ecstasy, meth and marijuana coming south,” he says. “Canada gets illegal aliens and guns going north.” Mr Acosta often sees guns and drugs hidden in vehicles or on persons heading into Canada. But for anyone who knows the southern border, “it’s pretty quiet here.”

Still, comparisons with Mexico can understate the difficulty of policing a line which runs through remote spots like the hills of Montana and Alberta (pictured) and four Great Lakes. There has been a rise in security measures since 2001. The number of American border agents looking atCanada seems paltry, at about 2,200, compared with 18,600 dealing with Mexico; but the former figure was only 340 in 2001.

Since that time the United States has also added aircraft with sensor arrays, thermal cameras, video surveillance and unmanned aircraft to watch remoter areas. Aaron Heitke, deputy chief patrol agent in Montana, says that when he started 13 years ago his main item of equipment was binoculars. Now, in addition to his weapon, he has a radiation detector, night goggles and thermal imaging. Perfect security is impossible. Ross Finlayson, a member of a globe-trotting club, trekked through wild terrain from Montana to Canada last summer, bringing a passport and some anti-bear spray. Neither proved necessary.

Canada has assuaged some American concerns—by arming 5,685 customs officers; agreeing to joint patrols on the Great Lakes; and helping to form teams that include coast guards, border agencies and police from both countries. By one estimate, Canada spent an additional C$92 billion ($77 billion) on security in the ten years after 9/11. On November 4th it announced a new surveillance web, with radar, ground sensors and thermal radiation detectors, along 700km of the border.

Yet while the United States sees the border through the lens of security, Canada thinks of bilateral trade worth $2 billion a day. Businesses of all kinds moan that stringent procedures depress activity. Costs rise when lorries have to queue for hours to be inspected several times over.

Although border security is not the only factor, Canada’s share of trade in the United States has stalled since 2001 (see chart). The near-quadrupling of North American trade in the first 20 years of the 1994 North American Free Trade Agreement largely concerned the United States and Mexico. (The value of United States trade with Canada tripled over the period, while that with Mexico grew more than sixfold.)