A man was sentenced to five years in prison on Friday for conspiring to blow up a busy Manhattan subway station.

James Elshafay, had pleaded guilty and testified against the mastermind of the plot, Shahawar Matin Siraj, at a trial last year in federal court in Brooklyn.

Elshafay, the son of an Egyptian father and Irish mother, testified that after meeting Siraj at an Islamic bookstore, they hatched an initial scheme — later abandoned — to blow up the four bridges connecting Staten Island to Brooklyn and New Jersey. He also told jurors at Siraj's trial that he was taking medication for depression and schizophrenia.

Siraj and Elshafay were caught with crude diagrams of the Herald Square subway station on Aug. 27, 2004, the eve of the Republican National Convention. Prosecutors said the men wanted to avenge the abuses of prisoners at the Abu Ghraib prison.

At the time of the arrests, authorities said that the men never obtained explosives and had not been linked to known terrorist groups.

Siraj was sentenced last year to 30 years in prison.