WASHINGTON (Reuters) - U.S. cyber spies last year unmasked the identities of nearly 17,000 U.S. citizens or residents who were in contact with foreign intelligence targets, a sharp increase from previous years attributed partly to hacking and other malicious cyber activity, according to a U.S. government report released on Tuesday.

The unmasking of American citizens’ identities swept up in U.S. electronic espionage became a sensitive issue after U.S. government spying on communications traffic expanded sharply following the Sept. 11, 2001 attacks and started sweeping up Americans’ data.

The report by the U.S. Director of National Intelligence (DNI) said that in 2018 cyber spies at the National Security Agency (NSA) unmasked the identities of 16,721 “U.S. persons”, compared to 9,529 unmaskings in 2017 and 9,217 between September 2015 and August 2016.

According to U.S. intelligence rules, when the NSA intercepts messages in which one or more participants are U.S. citizens or residents, the agency is supposed to black out American names. But the names can be unmasked upon request of intelligence officers and higher-ranking government officials, including presidential appointees.

Alex Joel, a DNI official, said it was likely that the higher number of U.S. persons unmasked last year was inflated by names of victims of malicious cyber activity.

Another official said the definition of U.S. person used by spy agencies includes actual individuals, email addresses and internet protocol (IP) addresses.

The expanded collection of data that affected Americans was exposed by whistleblowers like former NSA contractor Edward Snowden, prompting politicians and the public to demand greater accountability.

Annual reports on the extent of NSA and other government electronic surveillance were one notable reform. NSA’s operations historically were so secretive that agency employees joked its initials stood for “No Such Agency.”

Not long after President Donald Trump took office, Devin Nunes, the Republican who then chaired the House Intelligence Committee, touched off a political flap by claiming intercepted messages involving members of Trump’s transition team had been unmasked at the direction of top Obama administration officials.

The report says that the number of “non-US persons” targeted by the U.S. for foreign intelligence surveillance rose to 164,770 in calendar year 2018 compared to 129,080 the year before.

The report adds that not a single FBI investigation was opened on U.S. persons based on NSA surveillance in either 2017 or 2018.