The Falun district court in central Sweden found the 30-year-old man, whose name was not disclosed, guilty of sexual coercion, sexual abuse of minors and child pornography charges, the regional Dalarnas Tidningar newspaper reported in its online edition.
The policeman was also ordered to pay 130,000 kronor ($16,000 dollars) in damages to each of the two boys, whose ages were not given.
The crimes took place between 2001 and 2006.
The policeman pleaded innocent to the charges and would probably appeal the
verdict, his lawyer told the paper.