The tension between Silicon Valley and the federal government over digital privacy has taken a bizarre twist: Twitter has reportedly barred the analytics firm Dataminr, which scans the Twitterverse for breaking news and trends, from selling its services to US intelligence agencies. Twitter seems to have no good reason for standing in the way of national security—beyond advancing its own public relations strategy.

While the details remain hazy, US intelligence agencies and Dataminr are said to have been working together for several years in an unpaid pilot programme. Twitter, which claims it’s just learning about the arrangement, won’t allow it to be extended, because it has a policy against selling its content for purposes of government surveillance.

Twitter’s resistance is remarkably arbitrary, considering that any private company can pay Dataminr for the service. The Department of Homeland Security has a $255,000 contract to receive breaking news, although it’s unclear whether that allows surveillance use. (Disclosure: Many media competitors of Bloomberg News are Dataminr clients.) Ironically, the CIA’s venture-capital arm, In-Q-Tel, is a Dataminr investor. So is Twitter, with a 5% stake.

Twitter says this is not a big deal, and that intelligence agencies could develop their own methods for tracking public accounts on the social-media site. This is true—Twitter’s interface is public—but beside the point: It makes little sense for the CIA to re-create a programme that Dataminr has already made, hemmed in as it would be by intellectual property concerns. What’s more, Dataminr’s product has already proved applicable to national security: It reportedly sent an alert to clients about the Brussels terror attacks 10 minutes before any news organization reported them.

Of course, this brouhaha has implications beyond Twitter. Ever since Edward Snowden began leaking documents revealing telecommunications companies’ complicity in government spying on US citizens, tech firms have become standard-bearers for privacy rights and unbreakable encryption. In defending its unwillingness to unlock the iPhone belonging to a shooter in the San Bernardino massacre, Apple argued that it was standing at the edge of a slippery slope; if it cooperated, the government would assume the power to force private-sector cooperation. Twitter has been suing the justice department to be allowed to give users more information on government surveillance.

We may be a long way from consensus on how to balance privacy with national security. But private companies doing business in a country that sends young men and women overseas to risk their lives fighting global terrorism should be expected to demonstrate some patriotism. The government and military have been making a good-faith effort to bring Silicon Valley on board with its surveillance efforts. Some tech firms—although not all—have reacted with unreasonable obstinacy, hiding behind an abstract concept of blanket privacy rights.

This is not just dangerous, but hypocritical: Companies such as Twitter and Facebook are more than happy to sell all sorts of personal data on users to advertisers.

In the case of Dataminr, the tweets the government wants to monitor are messages freely sent out to the world—with no expectation of privacy. Twitter’s baseless stand against the US intelligence agencies may set back national security, but it will do nothing to advance personal freedom. Bloomberg

Close