Social media giant Twitter is going to court, suing the Trump administration to protect the identity of one of its users.

FOX's Jessica Rosenthal reports:

Twitter has filed a lawsuit in federal court in San Francisco. They say it's to prevent Homeland Security and Customs and Border Protection from unlawfully abusing a limited investigative tool, meant to unmask the identify of some users, in this case the user of one account called Alt USCIS.

Twitter acknowledges that after the election a new crop of users surfaced purporting to be alternative government agencies. For example, there is and Alt Forest Service and Alt DHS, etc, but they say the Trump administration has not come close to demonstrating that some civil or criminal offense has been committed here. They also say they fail to demonstrate that this demand is not motivated by a desire to suppress free speech.

CBP and DHS say in email statements that they don't comment on pending litigation.

Jessica Rosenthal, FOX News.

Follow Jessica Rosenthal on Twitter: @JessicaFOXNews