Or maybe capitalization is not even part of the name
That's pretty much it. No court would fail to recognize the name "John Doe" in the string "JOHN DOE"; similarly, if someone established or claimed to establish their legal name as "john doe" then the only violations committed by someone writing it as "John Doe" or "JOHN DOE" would be violations of style, perhaps, or of etiquette.
Now, just in case this is related to the crackpot conspiracy theorists from the "sovereign citizen" or "freeman on the land" movements, a few words are in order. If you don't already know about this, you might find it interesting. In general, this is a school of thought that attempts to establish the illegitimacy of government authority by employing a number of illogical and willful misinterpretations of (often obsolete, foreign, or otherwise irrelevant) legal texts. Among these is the idea that the capitalization of a name is significant.
From Wikipedia's article on the sovereign citizen movement:
In a criminal case in 2013, the United States District Court for the Western District of Washington noted:
Defendant [Kenneth Wayne Leaming] is apparently a member of a group loosely styled "sovereign citizens". The Court has deduced this from a number of Defendant's peculiar habits.
First, like Mr. Leaming, sovereign citizens are fascinated by capitalization. They appear to believe that capitalizing names have some sort of legal effect. For example, Defendant writes that "the REGISTERED FACTS appearing in the above Paragraph evidence the uncontroverted and uncontrovertible FACTS that the SLAVERY SYSTEMS operated in the names UNITED STATES, United States, UNITED STATES OF AMERICA, and United States of America ... are terminated nunc pro tunc by public policy, U.C.C. 1-103 ..." (Def.'s Mandatory Jud. Not. at 2.) He appears to believe that by capitalizing "United States", he is referring to a different entity than the federal government. For better or for worse, it's the same country.
From its article on strawman theory:
One argument used by proponents of the strawman theory is based on a misinterpretation of the term capitis deminutio, used in ancient Roman law for the extinguishment of a person's former legal capacity. Adherents to the theory spell the term "Capitis Diminutio", and claim that capitis diminutio maxima (meaning, in Roman law, the loss of liberty, citizenship, and family) was represented by an individual's name being written in capital letters, hence the idea of individuals having a separate legal personality.
Proponents of the theory believe the evidence is found on the birth certificate itself. Because many certificates show all capitals to spell out a baby's name, JOHN DOE (under the Strawman theory) is the name of the "straw man", and John Doe is the baby's "real" name. As the child grows, most legal documents will contain capital letters, which means that his state-issued driver's license, his marriage license, his car registration, his criminal court records, his cable TV bill, correspondence from the IRS, etc., pertain to his strawman and not his sovereign identity.
(Note that there was no distinction between majuscule and minuscule letters in the Latin alphabet in ancient Roman times; this distinction arose in the 8th century, a few hundred years after the fall of the western empire.)
And finally, from Meads v. Meads, 2012 ABQB 571 (CanLII):
[323] Given the obsessive focus of the OPCA movement for documentary and procedural formalities (real or imagined), it is unsurprising that they have developed a wealth of arbitrary name-related rules. For example, Canadian courts have evaluated and rejected the following nomenclature-related schemes:
a person is not immune from court action if that person identifies himself by an entirely different name, for example, “Mythlim‑Axkw” instead of “Kazimierz Chester Crischuk”: R. v. Crischuk, 2010 BCSC 716 at paras. 31-32, affirmed 2010 BCCA 391, 2010 D.T.C. 5141; Shakes v. Canada (Public Safety and Emergency Preparedness), 2011 CanLII 60494 at para. 11 (I.R.B.); Services de financement TD inc. c. Michaud, 2011 QCCQ 14868 at para. 6;
structuring a name in the format of [Firstname]-[Middlename]: [Lastname], i.e. “David-Kevin: Lindsay”, does not mean one is a separate person from “David Kevin Lindsay”: R. v. Lindsay, 2006 BCCA 150 at para. 3, 265 D.L.R. (4th) 193; R. v. Lindsay, 2008 BCPC 203 at para. 7, [2009] 1 C.T.C 86, affirmed 2010 BCSC 831, [2010] 5 C.T.C. 174, affirmed 2011 BCCA 99, 302 B.C.A.C. 76, leave refused [2011] S.C.C.A. No. 265;
structuring a name in the format [Firstname] of the [family] of [Lastname], i.e. “John Donald of the family Sargent”, does not mean one is a separate person from “John Donald Sargent”: R. v. Sargent, 2004 ONCJ 356 at para. 29, [2005] 1 C.T.C. 448;
there is no legal distinction between a name in upper case and lower case letters, and a name all in capital letters: R. v. Linehan, 2000 ABQB 815 at para. 13, 276 A.R. 383; R. v. Loosdrecht, 2008 BCPC 400 at para. 36, [2009] 4 C.T.C. 49; R. v. Lemieux, 2007 SKPC 135 at paras. 45-46, [2008] 2 C.T.C. 291;
a claim that the person named in litigation is incorrectly identified by a “war name” or “nom de guerre” is irrelevant: Canada v. Galbraith, 2001 BCSC 675 at paras. 25-29, 54 W.C.B. (2d) 504; and
a name all in capitals is not a “legal fiction” and not different from “a flesh, blood and bone man”: Ontario (Director, Family Responsibility Office) v. Boyle, [2006] O.J. No. 2181 (QL) at paras. 3-5, 149 A.C.W.S. (3d) 127 (Ont. Sup. Ct. J.).