The Trump administration has immediately barred New York residents from enrolling in “trusted traveller programmes” (TTP), in retaliation for a new state law which blocks federal immigration officials from accessing motor vehicle records.

The US Department of Homeland Security (DHS) confirmed the move on Thursday, the morning after acting homeland security secretary Chad Wolf first announced the measure on Fox News.

The drastic change came just hours after Mr Trump attacked New York’s sanctuary city status during his State of the Union address.

Sanctuary cities are localities that provide added protection to immigrants and refuse to cooperate with federal officials and federal law enforcement, which has only escalated since Mr Trump took office.

In a three-page letter, DHS said the New York legislation, dubbed the "Green Light" law, prevents federal agencies from protecting residents from "menacing threats to national security and public safety".

The law, which went into effect in December, allows people without legal permission to be in the US to apply for driver's licences. It also included a provision prohibiting state DMV officials from providing any of its data to entities that enforce immigration law unless a judge orders them to do so.

The law blocks US Customs and Border Protection (CBP), which patrols the US-Canada border in New York and US Immigration and Customs Enforcement (ICE) from obtaining the vehicle's owner information.

Mr Wolf called New York's new law "disappointing" during a Fox News interview with Tucker Carlson late on Wednesday night. He said the suspension of Global Entry and similar TTP initiatives was effective immediately.

The programmes allow quick clearance at select airports for pre-approved travellers who are considered “low risk” by CBP upon arrival in the US. Members enter the country through automatic kiosks in order to reduce waiting time.

"They (New York residents) can't enrol or re-enrol in these trusted traveller programmes that customs and border protections offers because we no longer have access to make sure that they meet those programme requirements," he said.

A senior adviser to New York governor Andrew Cuomo, Rich Azzopardi, said the move by DHS was politically motivated.

"This is obviously political retaliation by the federal government and we're going to review our legal options," Mr Azzopardi said.

https://cdn.jwplayer.com/players/wBSVm3Tb-QoL8Kre2.htmlPresident Donald Trump holds up newspaper that reads "ACQUITTED" at 68th annual National Prayer Breakfast

Mr Cuomo, a Democrat, approved the Green Light law last summer, allowing individuals to use foreign-issued documents to prove their age and identity so they can apply for driving privileges.

Lawmakers and Mr Cuomo became worried that ICE and CBP would be able to easily obtain information about people seeking a licence, and possibly making it easier for them to be deported.

Since becoming president, Mr Trump has routinely attacked New York; a liberal state which opted by more than 20 points for Hillary Clinton in the 2016 presidential election.

Last month Mr Trump attacked the city over plans to build sea barriers to protect the region from rising sea levels.

"A massive 200 Billion Dollar Sea Wall, built around New York to protect it from rare storms, is a costly, foolish & environmentally unfriendly idea that, when needed, probably won’t work anyway," Mr Trump tweeted. "It will also look terrible. Sorry, you’ll just have to get your mops & buckets ready!"

Additional reporting by AP