A Dorchester man has pleaded guilty to trafficking firearms, the U.S. Attorney said Monday.