The Trump administration is now screening the social media accounts of visa applicants in order to weed out any potential national security threats.

A State Department official told The Daily Caller on Friday that visa application forms have been updated to ask applicants for their social media identifiers. The social media accounts will then be checked against government watchlists to ensure there are no “red flags” associated with the applicant’s online statements.

If the applicant is discovered to have been flagged by the government, the State Department will put the application aside and conduct more research into the applicant’s online behavior to ensure they are not a threat. (RELATED: Trump Signing Memo Cracking Down On Visa Overstays)

The official argued that the measure could prevent possible terrorists from entering the U.S. legally through a visa program.

“There have been incidents where terror attacks have been planned almost entirely on social media,” the official explained. “This is one more step in strengthening U.S. border security.”

Tashfeen Malik, one of the San Bernardino terrorists, made online posts advocating for violent jihad prior to applying for a visa to the U.S. Law enforcement officials, however, said that because the posts were made under a pseudonym and on a private account, it is unlikely that they would have been uncovered even if Malik’s accounts were reviewed.

The new visa application featuring social media identifiers will affect approximately 11-12 million immigrants, according to the official. The plan was first reported on last year when a State Department filing revealed a proposal to collect five years of social media identities from people seeking admittance to the U.S.

“This is a critical step forward in establishing enhanced vetting of foreign nationals seeking entry into the United States. As we’ve seen around the world in recent years, social media can be a major forum for terrorist sentiment and activity,” a senior administration official told The Daily Caller. “This will be a vital tool to screen out terrorists, public safety threats, and other dangerous individuals from gaining immigration benefits and setting foot on U.S. soil.”

The new measure will likely cause pushback from civil libertarians concerned about the potential privacy issues of looking into immigrants’ social media accounts. The State Department official asserted that they are “following all legal guidelines” and intend to “protect the privacy and data” of the accounts shared with them.

The collection will not include passwords to any accounts, and the official noted that the State Department already collects sensitive data from applicants that require protection, such as addresses and phone numbers.

U.S. Customs and Border Protection under the Obama administration in August 2016 proposed a similar policy that would allow officials to request social media information from people crossing the border.

Follow Amber on Twitter