Police are still search for two others, who allegedly trained in Libya alongside the man behind the attack, the official said as cited by the BBC.
On June 26, a gunman, later identified as Seifeddine Rezgui, walked down a beach in Sousse fatally shooting nearly 40 holidaymakers with an automatic rifle. A further 40 people were injured. The gunman, shot dead by police at the site, is believed to have been assisted by a local support group.
On Monday, Tunisian security officials detained seven people, including the gunman's father and three university roommates, on suspicion of aiding and encouraging the suspect to carry out the deadly massacre.
The Islamic State (ISIL) jihadist group has claimed responsibility for the attack.