A bill passed by the Florida Senate would let children who are victims or potential victims of rape and other violent acts secretly record their attackers.

The Senate unanimously approved the bill (HB 7001) on Wednesday. It applies to victims who are under the age of 18.

The law generally prohibits conversations to be recorded or otherwise intercepted without the consent of both parties.

The bill was filed after the Supreme Court ordered a new trial for an ice cream truck driver convicted of raping his teenage stepdaughter over a period of years.

The girl twice secretly recorded him talking about the assaults with an MP3 player hidden under her shirt. The court said the recordings shouldn't have been used as evidence.

The bill now goes to Gov. Rick Scott.