P is the health code illegal?

P picture itself is not illegal, but if you use P picture to go in and out of public places with illness, it may constitute a crime of endangering public safety.

Legal basis:

One of the crimes of setting fire, breaking water, exploding, throwing dangerous substances and endangering public security by dangerous means mentioned in Article 114 of the Criminal Law of People's Republic of China (PRC) refers to setting fire, breaking water, exploding, throwing toxic, radioactive, infectious disease pathogens and other substances or endangering public security by other dangerous means, but it has not caused serious consequences, and shall be sentenced to fixed-term imprisonment of not less than three years but not more than ten years.