In a T-shirt emblazoned with a red maple leaf, Tahmid Khan was led to a Bangladeshi court Saturday, where a judge authorized police to continue holding the University of Toronto student in connection with a deadly café attack claimed by ISIS that killed 20 hostages.

The six-day extension comes about one week after Bangladeshi police announced that the 22-year-old had been arrested, seeking permission from the court to question him along with British national Hasnat Karim, 47, for 10 days.

Friends and family of the Canadian permanent resident have vigorously maintained that Khan has been held in police custody since the July 1 attack, and is innocent.

"They don't have to articulate to the court what the suspicion is, whether they have any evidence," lawyer Marlys Edwardh told CBC News of the Bangladeshi authorities.

"They're not obliged to do anything more than saying, 'We have a suspicion and we'd like a few more days to investigate.' That's what happened today."

Saturday's decision followed on the publication of photos in the Dhaka Tribune apparently showing Khan holding a gun on the rooftop of the Holey Artisan Bakery restaurant, along with one of the suspects in the attack. Security forces would later storm the restaurant on July 2, killing the gunmen and rescuing the remaining 13 hostages.

'Playing detective in their heads'

Edwardh, along with Khan's friends, says the photos were released without context.

Edwardh argues that "there was evidence from other witnesses that he had been ordered to pick up a gun." She says it was one of Khan's two female friends who chose the bakery that day.

University of Toronto student Josh Grondin agrees.

"People see this picture, they're jumping to conclusions, sort of playing detective in their heads thinking that they know more about the investigation," Grondin says.

"Anyone that has known him for five seconds knows that he's not capable of doing something like this ... To have people who don't know him think so poorly of him, it's just very hard to see someone that you love so much go through something like this."

Photos published in the Dhaka Tribune apparently show Khan holding a gun on the rooftop of the Holey Artisan Bakery restaurant along with another of the suspects in the July 1 attack. (Dhaka Tribune) On Saturday a judge authorized police to continue holding the University of Toronto student. (Dhaka Tribune)

Edwardh, who maintains Khan only arrived in Bangladesh that morning to visit his parents for Eid, is equally sceptical he was involved in the attack.

"Has he had any military training? No. Has he ever had any interest in weapons? No… The man who was there loves his guitar, not weapons," she says of Khan, the brother of her client and Canadian citizen Talha Khan.

"There is not, really, from our perspective a remote chance or possibility he's connected to what happened at the bakery, other than being one of the hostages."

Rusaro Nyinawumwami (left) and Josh Grondin published a letter in the U of T's Varsity student newspaper recently describing him as a typical student who plays guitar, sings and plays soccer. (CBC)

It's a refrain echoed by friend Rusaro Nyinawumwami, who travelled with Khan to Italy in 2013 on a summer abroad trip through the university, from which he was set to graduate next year. She describes him as "forward thinking, very open-minded, a feminist, a student ... He is one of us."

Nyinawumwami and Grondin have organized a social media campaign in support of Khan, and hope the Canadian government will continue to push for Khan to receive a fair trial.

'The world is watching'

The federal government has confirmed that officials have been in contact with Bangladeshi authorities about the case, but says there are limits on what it can do in any case involving someone who's not a Canadian citizen.

"If this were remotely connected to Canadian legal proceedings, there would be not a doubt in my mind for a second that he'd be walking out the door," Edwardh says, acknowledging the limitations.

Marlys Edwardh told CBC News Sunday that Bangladeshi authorities can continue holding Khan without articulating to the court what their suspicion is or whether they have any evidence. (CBC)

Edwardh has called on the University of Toronto to write a letter in support of Khan to the Bangladeshi High Commissioner in Ottawa; the university has confirmed it will be submitting a letter Monday.

In the meantime, she hopes the federal government will continue to do what it can to secure Khan's release.

"I am very hopeful that they will continue to send a message to the Bangladeshi authorities which is nothing less than, 'the world is watching.'"