An Indian doctor allegedly connected to a failed terror plot in Britain will be detained for immigration violations, the Australian government said Monday, overriding a magistrate's order granting him bail in the terrorism case. Immigration Minister Kevin Andrews said Mohamed Haneef's work visa was canceled because he «failed the character test,» and that he will be taken into immigration custody while his case is heard. «I reasonably suspect that he has, or has had, an association with persons engaged in criminal activity, namely terrorism, in the U.K.,» Andrews told reporters in Canberra, the national capital. «That's the basis on which I have made this decision.» The Australian government can withdraw a person's visa for a variety of reasons, including if the immigration minister judges a person is not of good character, the Associated Press reported. Hours earlier, Queensland state Magistrate Jacqui Payne granted Haneef 10,000 Australian dollars bail (US$8,700; ¤6,312.58) on a charge of providing support for a terrorist organization, saying there was no clear evidence he was involved in the car bomb plots in London and Scotland. But Andrews said once Haneef's bail processing was complete, immigration officials would step in and bring him to a detention facility in Sydney. Haneef's lawyer Peter Russo said he would appeal the government's decision. «We will start the next battle. If that's the way they want to do it _ bring it on,» he told reporters outside the Brisbane jailhouse where Haneef has been held for two weeks.