Tech UPTechnologyCryptography and the Mystery of the Man in the...

Cryptography and the Mystery of the Man in the Iron Mask


Legend has it that in the 1670s the inhabitants of Pignerol (today Pinerolo, Italy), in the Duchy of Savoy, could see a man covered in a black velvet mask walking through the rampant towers of the prison. The guards said that he was treated with exquisite courtesy, and that he even dined with the commander of the fortress. One day, the mysterious prisoner dropped a written tablet from the top of the wall . A villager picked her up, but was quickly stopped by soldiers. It took him several weeks, locked in a dark and cold cell, to convince them that he could not read or write and that he was not part of any conspiracy to free the prisoner.

The first surviving records of the famous masked prisoner date back to the end of July 1669, when a minister of Louis XIV, the Marquis de Louvois, sent a letter to Bénigne Dauvergne de Saint-Mars, governor of the Pignerol prison (which in part of France at the time) informing him that a prisoner named Eustache Dauger would arrive next month. In the letter, he gave her a series of instructions, such as preparing a cell with several doors that close one on top of the other , and thus prevent anyone from the outside from accidentally hearing anything. Besides, Saint-Mars was to see Dauger once a day to provide him with food and whatever else he needed. Furthermore, he was to tell Dauger that if he spoke of anything other than his immediate needs, he would be executed , but, Louvois added, the prisoner should not demand too much as he was only “a valet”.

On April 30, 1687, he was transferred to the Sainte-Marguerite prison, an island opposite Cannes. That same year, a Jansenist gazette specified the circumstances of his arrival: “M. De Cinq-Marc (sic) transported by order of the king a prisoner of the state from Pignerol to the islands of Sainte-Marguerite; Nobody knows who he is; it is forbidden say his name and there is an order to kill him if he says it (…) he arrived in a palanquin with a steel mask on his face”.

Arrival at the Bastille

The matter began to be known with the arrival of a prisoner at the Bastille on September 18, 1698. According to the king’s lieutenant Étienne Du Junca -responsible for the famous prison-, it was the same masked prisoner from Sainte-Marguerite. Soon they began to talk about this strange character that everyone knew nothing about. For a long time it was a topic of conversation at Court, but no one could find out one iota.

The man in the mask died on November 19, 1703 after 34 years of imprisonment, apparently always in the custody of the same jailer, Bénigne Dauvergne de Saint-Mars. In the penitentiary registry of the prison, which was kept by du Junca, the following entry appears: “having felt a little ill when leaving mass, he died today at ten o’clock at night […] and this unknown prisoner kept for so long, he was buried on Tuesday at four in the afternoon of November 20 in the cemetery of Saint-Paul, our parish; in the mortuary registry we have given such an unknown name and Mr. de Rosarges, mayor, and Mr. Reil, surgeon, signed in the registry”. He added in the margin: “£40 was paid for the burial.” The parish register reveals that he was buried under the assumed name of Marchioly . All his belongings were destroyed and the walls of his cell were scraped and whitewashed.

They went to great lengths to erase that man from history. Who was that mysterious character? Alexandre Dumas speculated in The Man in the Iron Mask that he was the twin brother of Louis XIV . Other rumors pointed to an illegitimate son. The list of candidates proposed throughout history is long.

An encrypted letter

In 1891 a French officer interested in history named Victor Gendron discovered a coded letter. He sent it to Étienne Bazeries, of the Office of Figures of the Ministry of Foreign Affairs. Bazeries was interested in crypto thanks to newspapers. At that time it was quite common for married people to contact their lovers through newspaper advertisements using secret codes . Its authors could never imagine the many ranches that enlivened their messages at the Bazeries barracks.

Gradually his skills increased, until he was able to read the codes of the French army without difficulty. His fame grew so much that he was demanded by the Ministry of Foreign Affairs: he had just become a professional cryptanalyst. Bazeries became interested in old French codes that were yet to be cracked. Patiently, he ended up reading the secret correspondence from the times of Louis XIV and Napoleon . It was at that moment that the letter found by Gendron arrived.

Bazeries suspected that each of them corresponded to a French syllable and, moreover, that individual letters could be represented by one or more numbers. The most frequent was 22 -it appeared 187 times-, followed by 124, 42, 311 and 125. Bazeries assumed that they corresponded to the most frequent syllables in French, so he assigned 124 the word les , 22 en and 125 and 146, ne . In the end he was able to decode the message.

It was a letter from the minister of war, the Marquis de Louvois, to Lieutenant General Nicolas Catinat, commander-in-chief of the army in Piedmont. In it he told how General Vivien de Boulonde had been arrested for fleeing during the siege of Cuneo (1691) and imprisoned in the fortress of Pignerol , where he would be locked up at night but during the day “he could walk along the battlements with 330 309 ”. These were two numbers that did not appear anywhere else in the text and it was impossible to discern their meaning from the context. Bazeries knew the story of the man in the mask and guessed that 330 meant masque and 309 was a sign of enclosure. Thus, Bazeries announced that the man in the mask was General Boulonde.

Now, it is strange that the word mask, which is not usually part of military language, was encrypted only with a number, something that only happens with the most common words. The rest were composed as strings of numbers that represented letters. In addition, Boulonde survived the death of the man in the mask for five years.

In 2015, the inventories of goods and papers of the jailer Saint-Mars were discovered (one inventory, 64 pages long, was drawn up in the Bastille in 1708; the other, 68 pages long, in the citadel of Sainte-Marguerite in 1691). These documents had been sought in vain for over a century and were thought to be lost. They were discovered among the 100 million documents of the Minutier central des notaires de Paris, one of the departments of the French National Archive that keeps the minutes of the notaries who practiced in Paris between the end of the 15th century and the beginning of the 20th century. These documents confirm the avarice of Saint-Mars, who ‘diverted’ the funds sent by the king to support the prisoner. They also describe a cell occupied by the masked prisoner: it contained only a sleeping mat .

Despite all efforts to identify him, we still do not know who was locked up and erased from history by express order of Louis XIV.


Burgaud E. y commandant Bazeries (1893) Le Masque de fer, revelation of the encrypted correspondence of Louis XIV, study supported by unpublished documents from the archives of the war depot, Firmin Didot

Loquin, A. (2020) [1st pub. 1900]. The masked prisoner of the Bastille, his authentic story, Hachette

Sonino, P. (2016) The Search for the Man in the Iron Mask: A Historical Detective Story, Rowman & Littlefield

Drag me out, baby! When the Earth is taken from the street to spacetime

What should we know about the Thirring-Lense effect and how and when was this theory confirmed since its appearance in 1917?

The incredible symbiosis of a lichen

Lichens, an iconic example of symbiosis, hide more than you think.

A spectacular supernova was visible in the sky during the Middle Ages

Astronomers turned back the clock on the stellar explosion to determine when it took place. How long did this starburst occur? It was 670 years ago. How did they find out? We explain it here.

The only five people who have two Nobel Prizes

The first person to win two Nobel Prizes in different categories was the physicist and chemist Marie Curie.

The Moon formed instantly after a massive collision, according to a new study

The Moon's origin would not have been progressive within a debris disk around the Earth, but rather abrupt and rapid.