Every call made, email sent and website visited is now being logged under new regulations. What does that mean for investigative journalists - and their need to protect sources?

Want to be an investigative journalist of the future? You'll need a pen and paper, pay-as-you-go phone, and a motorbike. We'll explain the motorbike later. But you may be an endangered species. New regulations that came into force last week - requiring telephone and internet companies to keep logs of what numbers are called, and which websites and email services and internet telephony contacts are made - have left some wondering if investigative journalism, with its need to protect sources (and its sources' need, often, for protection), has been dealt a killer blow.

Worries focus on the fact that every government department, local council and even quango can access this telephone and internet data, given a judge's clearance. What will they use it for? To investigate everything from treason to flytipping. Might it also be used to find out who has been tipping off a journalist on a local paper about the misdeeds of local councillors? That's the concern.

"I would say that investigative reporting is desperately threatened by what this government is doing. I've been thinking a long time about how to stay one step ahead of the game," says the Brighton-based investigative journalist Duncan Campbell (not the reporter of the same name on this paper). "The good news is that the surveillance methods that would close down what we do are still one step away. This isn't the one that does the real harm."

That will come, Campbell thinks, when the police put all sorts of information - vehicle licence plates' movements, emails, phone calls - into a real-time system that anyone can access. But that's not to say the new regulations will not have an impact.

In 1986, Campbell uncovered and revealed the UK's secret Zircon spy satellite, and in 1988 the Echelon worldwide eavesdropping system; more recently he has written for this paper about police errors in Operation Ore prosecutions, meant to target viewers of child pornography but which accused people who had had their credit card details stolen.

A story that spread about Zircon was that Campbell spotted its existence because of the difference between two press releases - one from a satellite manufacturer and one from the Ministry of Defence. In fact he also had inside help. "I had confidential sources," he says. "There was always 5% in the stories that came from a whistleblower."

Sources are essential to Campbell's work. Investigative journalists may write many dull stories and meet lots of dull people, but some of those they meet or influence through those stories matter enormously. Bob Woodward - who, with Carl Bernstein, uncovered the Watergate scandal while at the Washington Post - met Mark Felt, who became his contact, Deep Throat, by chance at the White House in 1970. Woodward was in the navy, working as a courier; Felt was in the FBI. Both were waiting outside the Situation Room one day. They chatted and kept in touch: two years later Woodward had a top-level source. His identity remained secret until Felt admitted it in 2005; he died last December.

But what of such sources now? The concern is that if someone gets in touch with a journalist, who then writes a story based on that information, the new regulations mean that the police - or intelligence services or local council - can work back from the database of all the contacts made to the journalist and figure out who the whistleblower is. It blows a huge hole in the journalist's legal defence under section 10 of the Contempt of Court Act of 1981 that sources can stay secret unless "the court is satisfied disclosure is necessary in the interests of justice or national security or for the prevention of disorder or crime". Join the communications dots, and a suspect is fingered.

How do you counter that risk? "Step down a couple of technological rungs," says David Leigh, the Guardian's investigations editor. "Just send a letter - you know, snail mail." He adds: "When I've dealt with secret sources they take very great care not to communicate on any electronic medium."

The next step, says Campbell, is to do what drug dealers and terrorists do: use pay-as-you-go phones and unregistered sim cards, bought with cash. Such closed rings are almost unbreakable - once you've met to swap numbers.

But must journalists and sources really use the same tactics as terrorists and drug dealers? If that's the price of free, civil society, then yes, Campbell says. "The abuse of free communications by a minority is part of the price of liberty. [But] this government appears to think that it is civil society [itself] and so needs no checks or balances on its intrusions into private lives."

Then again, don't many scandals involve private companies, which won't have access to the communications data? Neil Hamilton, Jonathan Aitken, British Aerospace (BAE) - none of those would be affected by this change, surely?

Leigh isn't so sure. He and Campbell both say that any database will eventually spill out to those who pay enough or know the right people. Where big companies are involved, big money is at stake. "I have sources in the US who refuse to communicate via electronic means because they say it's insecure," Leigh says. "I know there are sources who already felt this before the new regulations. The bottom line about this is that anybody who imagines that electronic communications are secure is crazy."

There can't be investigative journalism without people willing to talk. And more and more important stories are emerging not from journalistic prying, but from those involved: the pictures from Abu Ghraib, taken by the US guards themselves; the details of Home Office failings, leaked from within it to the Tory MP Damian Green; the video provided to the Guardian last week showing a police officer assaulting Ian Tomlinson, who died during the G20 protests in London.

Technology is, however, also making life easier for investigative journalists. "I have more information at my fingertips than ever before," says Leigh. The government and its agencies may be able to track journalists, but equally journalists can spread information over the web, from where it can't be removed. The Freedom of Information Act also provides some leverage against government, if not a counterbalance to the new surveillance methods.

Leigh calls it a game of "attack and defence" - the internet works both ways, but slightly more in the journalist's favour. He has just returned from Berkeley, California, and the presentation of a new film based on this newspaper's investigation into BAE's slush funds. How was the mood of journalists over there? "They were all miserable, but it wasn't about this. It was because they were being thrown out of their jobs because the newspapers are going bust." Oh, yes - a method even the government couldn't dream up. Campbell observes wryly: "I don't think, despite the claims of the blogocracy, that they [bloggers] have stepped into legally hard investigative journalism."

He thinks that if unchecked, the government's monitoring proposals "within a decade will threaten to bring [investigative journalism] to an end. It's not that whistleblowers will be rounded up, but that the chilling effect of the surveillance society means no whistleblower will feel a journalist can protect them."

What really troubles him is the automatic numberplate recognition (ANPR) system implemented by the police across the country to track vehicle tax evaders and criminals, but also potentially to record where you've been. Currently it can only be accessed by the police and intelligence services, and you can't yet do it in real time - when that moment comes, it will be truly dangerous, says Campbell.

The system does pose a threat to sources' anonymity, agrees Leigh: if you assume that CCTV is watching any public journey, the only way left to meet is through a private journey in your car. "ANPR is a greater threat [than internet and phone-logging] because it's tracking the physical movement of vehicles that are closely correlated to people," Campbell says. "Unlike sim cards."

We ponder solutions. Bicycles? Horses? Too slow. Motorbikes? Those usually only have a numberplate on the back - and the ANPR cameras focus on the front plate. Campbell and Leigh like it. Add it to the future armoury.