(CNN) Fifteen people, including five women, were punished with public caning Friday for violating Sharia law in Indonesia's conservative Aceh province.

Two men accused of being gay received 87 lashes each for gay sex, while nine others were sentenced up to 26 lashes for adultery. Four people were caned for being drunk, including one woman who received 27 lashes.

Carried out after Friday prayers, the flogging was attended by hundreds of spectators, including children, outside the Baiturrahim Mosque in Banda Aceh, the provincial capital.

In video of the punishment seen by CNN, people can be heard jeering as the detainees, who are wearing white, traditional koko shirts, are brought up to the scaffold in front of the mosque.

An official checks on a convicted offender during the public flogging.

Others took cellphone video of the punishment being administered by a hooded man while a voice counts the strokes over a loudspeaker. At one point a uniformed official appears to instruct the masked whipper where to land the blow.

Read More