Justice C T Selvam granted the relief to the five -- Roopesh, Anoop Mathew George, Kannan, Veeramani and Shyna who were arrested by the Q Branch police on May 4, 2015.
They had also been detained under National Security Act.
The five were arrested in a combined operation by police forces of Andhra Pradesh, Kerala and Tamil Nadu from Karumathampatti in Coimbatore on May 4.
Roopesh has more than 20 cases against him in Kerala while Shyna has at least two cases against her in Ernakulam.