Hackers have spent years eavesdropping on the diplomatic communications of European Union officials, a U.S. cybersecurity firm said Wednesday, an operation disrupted only after researchers discovered hundreds of intercepted documents lying around on the internet.