Hackers were able to remotely install surveillance software on phones and other devices using a major vulnerability in messaging app WhatsApp, it has been confirmed.
WhatsApp, which is owned by Facebook, said the attack targeted a "select number" of users, and was orchestrated by "an advanced cyber actor".
A fix was rolled out on Friday.
On Monday, WhatsApp urged all of its 1.5 billion users to update their apps as an added precaution.
The attack was developed by Israeli security firm NSO Group , according to a report in the Financial Times .
The problem was first discovered earlier in May.
WhatsApp promotes itself as a "secure" communications app because messages are end-to-end encrypted , meaning they should only be displayed in a legible form on the sender or recipient's device.
However, the surveillance software would have let an attacker read the messages on the target's device.
"Journalists, lawyers, activists and human rights defenders" are most likely to have been targeted, said Ahmed Zidan from the non-profit Committee to Protect Journalists.