VANCOUVER - Five years ago, Gary Fung set up a small website in his B.C. home to let visitors search for files available through a then-emerging peer-to-peer file-sharing system called BitTorrent.

What started as a hobby project to help Fung improve his programming skills has grown into one of the largest file-sharing websites on the Internet - with five paid staff members and growing advertising revenues -- and has made Fung the target of a major lawsuit launched by the Hollywood film industry.

"At first, it was a side-project to learn some of the language and databases -- mostly for technical reasons," says the 25-year-old Richmond man, who started while studying computer engineering at the University of British Columbia.

"I hosted it off my cable modem at home, so it hardly had any traffic."

But in the years since, Fung has put his studies on hold as he maintains a website that sees 18 million visitors a month, linking them to more than 25 million files ranging from music and movies to video games and software.

Fung first heard from the Motion Picture Association of America -- or MPAA -- more than three years ago, when the association's lawyers wrote him demanding copyrighted movies be taken down immediately.

The MPAA launched a lawsuit in a U.S. court in 2006.

Fung says he's always been watching the long list of legal cases that have dogged other file-sharing websites, prompting many to shut down to avoid costly court battles and in several instances resulting in multimillion-dollar settlements.

But, while other websites have collapsed long before their legal cases were resolved, Fung says he intends to fight the lawsuit through the courts.

BitTorrent works differently than other popular file sharing methods.

Users download a small file - called a torrent - connecting them to a tracker, which keeps tabs on who else has a particular movie, piece of music or software program.

Instead of downloading from one computer, someone obtaining a file through BitTorrent is actually downloading small pieces from hundreds or even thousands of users, as well as also uploading small pieces themselves.

Fung's site doesn't host the actual file or do the tracking -- it crawls other websites looking for the small torrent files and puts them into a searchable database.

Fung argues that sites such as his simply automate the process and don't have any control over whether users share files legally or abuse the system.

"That's really a problem with the copyright system and how people want to share things. It's a social problem, and it's far beyond what we can control," says Fung, who insists he removes material if the copyright owners follow a formal complaint process.

The MPAA, however, claims BitTorrent websites like exist for no other reason than to trade in pirated material.

"All of them are inducing massive copyright infringement, and they are making a lot of money doing so," says John Malcolm, the association's anti-piracy director.

"All of these films that are either being hosted by these sites or to which they are providing links or torrents, are stolen movies. They're not paying any licensing fees, there is no deal with any artists, there is no deal with any studio."

Malcolm rejects Fung's argument that he's not responsible for how people use his site, saying it's not the role of copyright holders to police the Internet and ask for their material not to be shared.

"There are a lot of sites out there where copyrighted material appears, but these are businesses that have a legitimate business model that is not exclusively premised on copyright infringement in order to work," says Malcolm.

The judge in the lawsuit is currently deciding whether to hand down a summary judgment or order a full trial.

Malcolm wouldn't explain why the MPAA is pursuing its lawsuit against Fung -- a Canadian -- in a U.S. court, other than to say it was free to choose from a number of jurisdictions.

But industry associations have long complained that Canada's copyright laws provide a haven for movie and music pirates without much consequence.

"Canada's laws are not up to snuff, that's been recognized by all sorts of people," Malcolm says. "With respect to laws to address online piracy, they are not what they should be."

The MPAA and Fung will both be watching how Ottawa updates Canadian copyright laws with legislation expected sometime this year.

However, University of Ottawa copyright expert Michael Geist says Canada's laws already cover many forms of illegal file sharing, and he says changes to the law likely wouldn't affect sites like Fung's.

Geist, who holds the Canada research chair in Internet and e-commerce, says efforts to paint Canadian law as weak aren't fair.

"Copyright law applies online in the same way that it does offline," he says. "While we are anticipating changes in the law, I think it would be a misnomer to suggest the Internet was a free-for-all."

Trading copyrighted movies and software is already illegal, Geist says, while it is illegal to upload - but not to download - music.

There have already been several criminal cases involving online movie piracy, but those have been against individual users, not large websites.

Under both Canadian and U.S. law, Geist says, one of the issues a court would have to weigh is how much copyright infringement is occurring, compared with legitimate uses.

"They fall in a bit of a grey zone not because the law has a shortcoming, but because their activities themselves include some that are clearly permitted under the law, and some that may involve acts of infringement," says Geist.

Geist notes file sharing systems like BitTorrent are already seeing more legitimate uses.

A national Canadian broadcasting agency recently used BitTorrent to post free downloads of its "Canada's Next Great Prime Minister" program.

"When you think of new technology, it's often the case that it takes time for the authorized uses to exceed the unauthorized uses," says Geist.