Let’s just say I encrypt illegal.content prior to uploading it to Platform A. And share the public key separately via Platform B. Maybe even refer Platform A users to a private forum on Platform B to obtain the keys. Are both platforms now on the wrong side of the law?
This is a big problem. Why are we talking about "cooperation"? What does it mean? A judge doesn't ask you to cooperate, he seizes your servers. Ah, it's not a court. It's the police? The state? It's not a free country, sir.
In principle, the police can tell if a song infringes copyright, or if a message spreads hate (I'm trying to sound American here). Or if a picture is really a "cheese pizza" or just a strange artistic depiction of youth. Not because the police don't know about music or TC/IP, or don't care about art or reading. Everyone knows they care. But because it is a legal problem.
In my country, let's call it a republic, at least it was a long time ago, even the state can own all your bases because you don't pay taxes, the police can only arrest you for six hours while they call the prosecutor to check that the 200 grams of white powder is what it is. They knew. They had already stolen the rest. If the forensics aren't quite sure what you're bringing them, it's the stuff that makes the stuff what the stuff is, you're free to go.
The prosecutor can make a case and send the 100 grams of white powder the same day, claiming that the stuff is the same stuff that other similar stuff is made of. He expresses his strong conviction. The judge then sends an arrest warrant to the police. You've been arrested, you have no money, the judge imposes some restrictions on you: you can't leave the country, you can't contact certain people, you have to go to court every week to sign a book. The investigation is open.
You have access to all the documents. Nothing happens without your approval and control.
This is how it works if SIA (yes, the singer) is not involved. If it is, you will be dead for a week and no one will ever find your body.
Aware of what? Government says a file is illegal? Sounds like a censorship regime to me.
Not if the key is provided to the platform operators to confirm the contents. Otherwise yes anyone could claim any encrypted file contains illicit material and people would game that system.
For what it's worth the key may not need to be manually shared to the provider as referrers often leak where people learned about the file and that source location may also contain the key or password. All it takes is one person using a web interface or addon that leaks such information. Some addons break the referrer-policy header and many website operators don't even set the header [1] in the first place. Example header testing [2]. Please test the sites you visit and kindly ask the website operators to address any missing headers.
# nginx example
referrer-policy "strict-origin" always;
Often is the case but I would still suggest setting the referrer policy should the file be enticing enough for people to register an account assuming forum ranks and further actions are not part of the picture.