There are a bunch of permutations, sure.
What you are calling "malicious code" could --and likely is-- quality control code.
The fact that fakes fail isn't the responsibility of the legitimate manufacturer.
I don't know how many hypothetical examples I have to concoct to drive the point home.
OK, here's another one. Fake Tesla. The real Tesla writes code that bricks the entire fake car. This is 100% pro-consumer. The fake Tesla could literally kill people.
What you guys are arguing for is that Tesla should ensure that fakes are able to function. And, at the extremes, that Tesla is responsible for their proper function and safety.
Think about that for a moment.