An excoriation is a harsh criticism. If your senior prank involves releasing a flock of chickens into the halls of your high school, you're practically asking for an excoriation from the principal.
Excoriation comes from the Latin roots ex, meaning off, and corium, meaning skin. The medical meaning of excoriation refers to a place where your skin is scraped or abraded. If you fall off your bicycle, you may get excoriations on your hands and knees. The idea of excoriation as severe censure comes from this medical definition. If you give someone a harsh lecture, you have verbally whipped and abraded that person, perhaps leaving mental scrapes and scratches.