German prosecutors say they are investigating allegations that a 39-year-old police officer abused two immigrants while they were in custody and boasted about it on social media.

Hannover Prosecutor Thomas Klinge told the dpa news agency Monday that the officer is accused of abusing an Afghan and a Moroccan, both 19, in separate incidents in 2014.

Klinge said the officer is being investigated for causing bodily harm. He didn't comment on a report from broadcaster NDR that the man sent a cellphone message saying he'd made the Moroccan man eat spoiled pork from the floor, and boasted on WhatsApp that he choked the Afghan until he "squealed like a pig."

Prosecutors are also trying to determine whether other officers knew of the abuse, and if there are more victims.