Up to 80 percent of the websites that antivirus and search-engine indexes flag as dangerous are in fact legitimate businesses, security experts have warned.

Analysts say that while the security industry is on top of conventional spam and phishing attacks, more effort needs to be put into preventing and eliminating so-called 'drive-by downloads'.

The attacks allow hackers to redirect massive amounts of traffic by inserting malicious 'IFrames' into legitimate websites. The hacks are usually invisible to website visitors and do not often draw attention from security personnel because they only require a single line of code to be manipulated.

Visit Security Advisor for all the latest security news, advice, product reviews and analysis.

Sophos CTO Paul Ducklin said affected organisations risk losing business because they are flagged as malicious by search engines such as Google, and antiphishing software.

"You could imagine the business lost if one of only three or four local sign writers were tagged in a search as malicious," Ducklin said.

"It can be very expensive to fix IFrame attacks because they can originate externally or internally, and they have a very small footprint."

Compromised websites can turn into virtual breeding grounds for further attacks, according to Ducklin, because they are easy targets for hackers wanting to inject additional malicious IFrames.

A 2007 Sophos survey found that more than 80 percent of websites listed as malicious were legitimate organizations that had been compromised by various attacks including iframe injections.

Ducklin said Sophos "tries to be fair" and revisits websites to see if they are still carrying the exploits, but could not specify exactly how long businesses remain blacklisted by security vendors or search engines.