Agreed. That is the challenge and whether the law should deal with those differently or not is part of it.
Again, our legal tradition disavows prior restraint.
Publishers are not the ones we should go after. (The Russians, Chinese et al would disagree)
Those who leaked the material have no 1st Amendment defense to the charge of theft or espionage.