Hackers increasingly are exploiting a little-discussed weak spot in Internet security: The byzantine network of ad makers and sellers that target online ads based on users’ browsing habits. The trend was reinforced recently when Yahoo Inc. displayed an advertisement laced with malicious computer code to European users for a week. Other major websites have run malicious ads in recent months, including those of newspapers, blogs and Dailymotion, a popular destination for streaming video. In some cases, the fake ads can download viruses without a user even clicking on them. In other instances, the ads serve up a legitimate-looking alert- “Your computer’s antivirus is out of date!”-to trick people into paying fraudsters money or downloading a virus. The spots sometimes are served unknowingly by major ad networks and can slip by antivirus software.