An alleged gang member who was photographed with Rob Ford has lost his bid to gain access to a video that allegedly shows the mayor smoking from a glass pipe.

A lawyer for Mohammad Khattak confirms the application was dismissed by Ontario Superior Court Justice Ian Nordheimer on Monday.

In his written ruling, Nordheimer said that Khattak does have a “legal interest” in the video but he said it is “very much a contingent one.”

“He thought it might be a bit premature to release this video before Mr. Khattak actually commenced civil action against those people who may have associated him (with the video),” Brown told CP24.

“The question is now about timing. When does that legal interest crystalize. The judge says it likely crystalizes after he has commenced civil action, so it will be up to Mr. Khattak to review his options and decide whether he wants to pursue that avenue in light of this ruling.”

Last week Nordheimer viewed two videos that were reportedly seized during the Project Traveller raids in June.

Though the Crown had suggested that one video was simply a longer version of the other, Nordheimer said in his ruling that the videos are “separate and apart” from one and other.

Nordheimer also confirmed that the first video does depict Ford, but he did not say whether the mayor is featured in the second video.

“Crown counsel said that the two videos were part of each other in the sense that one was a subset of the other. From what I was shown, that is not correct. The video that I viewed is approximately 90 seconds long. It is the one in which the Mayor of the City of Toronto is featured,” he wrote.

“The second video is much shorter and is separate and apart from that first video. However, from the content of the second video, it might be reasonably concluded that what is revealed in the second video relates back to the first video.”