You mean the text which restates 1917 CJC can. 1012: "there can be no valid matrimonial contract between baptized persons which is not also necessarily a sacrament"?
You can't read 1 canon in isolation from the entire canon law section on matrimony. That's out of context. Canon law goes on to define what a "valid matrimonial contract" is, and this has separate requirements, which if not followed, means the marriage isn't valid.
.
To show the absurdity of your too-general understanding of the above canon, i'll give you an example:
.
Two baptized, practicing catholics get married by a justice-of-the-peace. Is this a valid marriage? No. Thus, it's not a sacrament. Would it be a valid natural law marriage? For protestants, pagans, muslims, or Jєωs -- yes, because they aren't bound by church canon law, being they aren't catholic.
.
So if 2 baptized protestants get married by a justice-of-the-peace, is that a sacrament? Of course not! Canon law is not meant to apply to non-catholics or their situations. You can only have a sacrament through the Catholic Church...if the couple gets married under the church's laws. Protestants aren't under the church, so they cannot have a sacrament.
.
All sacramental marriages are valid natural-law marriages...and valid catholic marriages.
Not all valid natural-law marriages are sacramental.
.
When canon law speaks of "valid" they are speaking of sacramental validity (not natural law validity), because canon law is dealing with catholic ceremonies.
But when speaking of natural law marriages and validity, canon law doesn't address this, because it is only dealing with catholic marriages. You can't apply canon law to non-catholic ceremonies/marriages and expect it to make sense. That's not its purpose.