Three men and a high-school student have been arrested for allegedly planning to bomb a Muslim community in upstate New York, authorities said on Tuesday.

The Rochester-area residents are accused of plotting to attack the small Muslim enclave of Islamberg, a rural settlement about 150 miles (241km) northwest of New York City.

Brian Colaneri, 20, Andrew Crysel, 18, and Vincent Vetromile, 19, face weapons and conspiracy charges. A 16-year-old student at Odyssey Academy, a school in Greece, New York, was charged with the same offences but was not identified due to his age.

At the time of their weekend arrests, the men, three of whom were in the Boy Scouts together, had access to 23 rifles and shotguns and three home-made explosives

A lunchroom comment by the student during school on Friday launched the investigation, Greece Police Chief Patrick Phelan told reporters at a news conference.

181101185805274

"He looks like the next school shooter, doesn't he?" the student allegedly said while showing students a picture of another boy on his phone, according to Phelan.

'People would have died'

The remark was reported to school security, which along with local police interviewed both the student who had the photograph, as well as the student in the picture. The pictured student was not charged, Phelan said.

The investigation eventually led police to execute several search warrants and arrest four people, including the student who showed off the photograph.

Police also searched five locations and seized 23 weapons and numerous electronic devices, including phones and computers. Most of the weapons were rifles and shotguns, some of which were legally owned by relatives of the suspects, authorities said.

Three improvised explosive devices were found at the 16-year-old's house, Phelan said.

"They were homemade bombs with various items - black powder, BBs, nails, inside a container," he said.

Phelan credited the students who reported the lunchroom comment with saving lives.

"If they had carried out this plot, which every indication is that they were going to, people would have died," the police chief said. "I don't know how many and who, but people would have died."

Islamberg was founded more than three decades ago by a group of black Muslims who follow the teachings of Pakistani Sufi scholar Mubarik Ali Shah Gilani.

The town in Delaware County has been targeted in the past. Two years ago, a Tennessee man was sentenced to nearly 20 years in prison for plotting to attack the enclave.