A Portland man was sentenced to 30 months in federal prison after pleading guilty to throwing a rock that struck an ICE officer in the face at a protest.