The first court-ordered transit ban in MTA history was executed in Suffolk County Supreme Court on Friday.
Huntington native Michael Harewood pleaded guilty this week to sexually attacking a Long Island Rail Road conductor.
Harewood is now banned from using the train until 2025. An order of protection has also been issued to the victim.
The ban was written into law two years ago by the state. It allows criminals who harass transit workers to be barred from the train for up to three years.