A judge on Tuesday rejected Disney’s request for an injunction to block Redbox from selling download codes, dealing a significant setback in the studio’s battle with its low-cost competitor.

Disney sued Redbox in December, alleging that the kiosk company’s sale of download codes for Disney movies constituted copyright infringement. Redbox obtains the codes by buying DVD combo packs, which include a DVD, a Blu-ray, and a download code. Though Disney typically includes a warning with combo packs that “codes are not for sale or transfer,” Redbox separates the codes from the discs and sells them individually.

In his ruling Tuesday, Judge Dean Pregerson held that Disney’s warning does not create a binding contract. Pregerson distinguished the language from other “box-top” licenses that are more detailed and which have been upheld.

Pregerson was also persuaded by Redbox’s argument that Disney is misusing its copyright by imposing restrictions on consumers’ ability to redeem the digital downloads. The license agreement for the download codes requires a consumer to affirm that he or she is the owner of the physical discs that come with the combo pack. But Pregerson held that Disney has no right to restrict consumers’ ability to resell the DVD and Blu-ray discs.

“This improper leveraging of Disney’s copyright in the digital content to restrict secondary transfers of physical copies directly implicates and conflicts with public policy enshrined in the Copyright Act, and constitutes copyright misuse,” Pregerson held.

There was a silver lining in the ruling for Disney, as Pregerson rejected Redbox’s contention that the digital codes should be covered by the “first-sale doctrine.” The doctrine holds that copyright holders cannot control what happens to a copy of a work after the “first sale.” An author may not prevent a reader from selling a used book, and a composer cannot block the resale of a record.

The doctrine applies to the physical discs, and Redbox argued it should apply to the download codes as well. Disney countered that by using a code to download a movie, consumers are creating a new copy, not transferring an existing one, and therefore the “first-sale doctrine” does not apply. Pregerson sided with Disney, finding that the doctrine is inapplicable to the case.

However, in refusing to grant the injunction, Pregerson held that Disney has not shown that it is likely to prevail on its case. A hearing on Redbox’s motion to dismiss the case is set for March 5.

Redbox has filed its own countersuit, accusing Disney of anti-competitive tactics in trying to stamp out a potential rival to its forthcoming streaming service.