A man has been arrested after he was found with an assault rifle outside the New York City home of an Iranian-American journalist who has been critical of Iran’s regime.

The journalist — 45-year-old Masih Alinejad — was the target of a kidnap plot by Iranian intelligence agents last year, according to US prosecutors.

On Wednesday and Thursday of last week, suspect Khalid Mehdiyev was spotted acting suspiciously outside a house in Brooklyn, the FBI said in documents filed in a Manhattan criminal court.

He was apprehended by New York Police Department officers who found in his Subaru car a loaded AK-47 and approximately 66 rounds of ammunition, the report added.

Feminist activist Alinejad was not named in the documents but confirmed on Twitter that the man had been outside her home.

“These are the scary scenes capturing a man who tried to enter my house in New York with a loaded gun to kill me,” Alinejad wrote, posting CCTV footage of a man on her porch.

“Last year the FBI stopped the Islamic Republic from kidnapping me. My crime is giving voice to voiceless people. The US administration must be tough on terror,” she added.

Mehdiyev was charged with one count of possessing a firearm with an obliterated serial number and was ordered detained without bond by a judge.

Dual US-Iranian citizen Alinejad is known for her criticism of Iran’s clerical regime, including its requirement that women veil themselves.

She founded the My Stealthy Freedom movement, which encourages women to remove their hijabs.

In July last year, the US Justice Department revealed charges against four Iranian intelligence agents, who had allegedly planned to seize the dissident and smuggle her to Iran.

According to the indictment, intelligence officers had first tried in 2018 to force relatives of their kidnap target to lure her to a third country to be arrested and brought to Iran to be imprisoned.

They then moved to surveilling the victim and other members of her household in Brooklyn “on multiple occasions in 2020 and 2021,” the Justice Department’s statement had said.

A fifth person in California was accused of financing the alleged operation.

Iran called the US charges “baseless and absurd.”