Saturday, March 28, 2020

Some advice for this Coronavirus pandemic

In an earlier post, I was of the opinion this COVID-19 outbreak would sputter out a bit faster than it has, and I was wrong on that. However, I still stand by the contention humanity needs to remain calm and rational no matter what.

Yes, it's deadly if you fall into certain risk groups especially. Yes, it's quite communicable, and yes, there is no easily common cure for it yet, these are all facts.

However, some things that are still worth keeping in mind.

1. Viral outbreaks have yet to cause the end of humanity. The worst-ever outbreak of plague in the Western world was the Black Death, and that never managed to wipe out all of humanity. The Spanish Flu killed a lot of people, but it was less deadly, and thus far this COVID-19 has proven several orders milder than that.

Therefore, there is no sense losing our minds believing the end is nigh. Humanity will survive this unless we all decide to destroy ourselves with our own panic and paranoia.

2. Anyone making life harder for essential businesses or personnel detailed to enforce food supplies, quarantine measures, or public safety in general is just making matters worse. People need to not panic shop and screw over other people, quarantine measures should be obeyed as practicably as possible, and anyone who thinks hassling the overworked officials responding to an emergency situation is a good idea needs to calm down. All you are doing is making their jobs harder and every else's life worse due to stretching the amount of people needed to maintain order in a trying time.

3. Do not fall for anyone peddling miracle cures or touting non-medically approved means of treating or especially curing COVID-19. It's not something anyone can cure by homeopathy or, heaven forfend, those people drinking non human safe alcohol in Iran who have been killing themselves due to self-poisoning because of their misinformed belief it would help.

4. Have a reasonable stockpile of goods on hand to weather this crisis. Get foods that last, focus on non-perishables, and makes sure you aren't one of those people rich in toilet paper but poor in all other prudent emergency supplies.

5. Use some common sense. Don't frequent places of assembly even if such is not formally restricted yet and avoid crowds unless going to do essentials like shopping for food. Maintain a healthy distance and if you have any reasonable degree of concern you may be afflicted with COVID-19, see medical personnel trained to deal with this at your local hospital ASAP.

6. Finally, STAY CALM. Paranoia is a far more deadly enemy than any disease and can lead to far worse consequences if not kept under control. This viral outbreak can be contained and treated to some degree, but only each individual can keep a handle on their own tendency to panic.

Saturday, March 14, 2020

Dumb moments in the history of Cryptology

While reading up on the cryptology profession, I noted some particularly facepalm-worthy things that made me laugh hard at the sheer fail, and since I've always considered history to be a rich mine of comedy, here are some of my favorite moments of utter fail in the cryptological arena of human history.



Battle of Tannenburg - World War I was a pretty dumb war because everyone in it was fighting for some really narrow-minded objectives that clashed hard with reality, with the Russians having a reason that amounted to an alliance with France they should have ignored and a hurt ego they wanted to assauge, but they fought anyway and we got the USSR in replacement of the Tsars.

In cryptology, they screwed up this major battle hard because they were lazy and sent messages in cleartext even though it was no secret the Germans were not ashamed to read other people's mail and this entire battle was an utter failure on their part because the Germans knew exactly what they were doing and where.

The loss didn't knock them out of the war, but it was their most embarrassing defeat and set the tone for their eventual and permanent quitting of WWI.


The "Petit Chiffre" - Napolean was considered a brilliant general, but oddly, he was one of the few people in his entire armed forces who knew squat about communications security, and he used a nomenclature style cipher called the "Petit Chiffre" or "little cipher". It had crap security (nomenclatures typically were easy to crack), but it was genius compared to how most of his sub-commanders were apparent morons who didn't like to bother with such things.

It served his Grand Armee poorly while he tried to invade Russia and played a huge role in his humiliating defeat, mostly because his commanders were paste eaters who couldn't read ciphers very well and were often too stupid and lazy to bother.



The Great Cipher - Ironically, while another French example of crypto fail, the cipher itself, invented by Antonie Rossignol, was a good one. It was one of the few nomenclature style ciphers that held up so well it was pretty effective at concealing French missives to the point it had to be cracked by hand in the late 1800's by Etienne Bazeries over the course of three years so the French could read most of the enciphered material it had once covered.

The fail comes from the fact Rossignol was the only guy (and his family) who knew how it worked. Most nomenclature ciphers were a mix of a cipher alphabet that was a substitution of different letters for a standard set of letters and a bunch of code terms, usually listed in sequence.

Rossignol wisely changed up the cipher alphabet to a syllabary style cipher (which confused most analysis of ciphers for centuries) and listed code terms out of alphabetical order with various different names in place of obvious terms to further baffle people.

While it was very effective, once Rossignol and his heirs died, it fell out of use and the instructions died with them, leaving most French archives in cipher from Louis XIV to 1811 utter gibberish no one could read. Apparently, while secure, Rossignol's instructions on how to use it were never properly recorded for future generations and the French had to wait until Bazeries worked backward over three years in the 1890's to figure out how it worked once more.



Enigma - Also known as the cipher machine that lost WWII for the Nazis. The reason this was utter failure is due to a bunch of technical details that had doomed it since not long after it's creation.

Enigma was a rotor-based, electromechanical enciphering machine, and it had been used for commercial purposes before the Nazis snapped it up as their chief enciphering machines for military purposes. While they thought it was secure, it had several weaknesses that made it's security a laughable joke.

1. While it went through several improvements, the underlying basic mechanical principles of the machine dated back to the 1920s and the Commerical and military-specific models all shared these factors in common.

2. Rotors were much faster than humans at encipherment, but their principles could still be followed mathematically by any reasonably competent arithmetician with a decent knowledge of how the mechanical aspects of the Enigma used math to randomize the security keys.

3. Before the Nazis took it off the market, various other nations forked their own version based off the open-source blueprints of the commercial versions and had a good idea how it worked on a basic level, and when they realized a lot of German missives used Enigma, this gave them a good starting place for uncovering it's cipher shields.


As a result of these factors, the British with Polish help made a frail joke of Enigma and were consistently reading the Germans mail through most of the war.


Zimmerman Telegram - During World War I, the brainlets behind the German war machine very stupidly signed off on a plan that would draw the United States into a conflict it had tried to remain officially neutral on because they wanted to practice unrestricted submarine warfare and couldn't unless they risked US intervention.

So the German ambassador who was guilty of trying to egg Mexico into a war with the US was authorized to try convincing Mexico to go to war with the US to keep the US distracted while the Germans sunk everything they could shoot in the Atlantic, with or without Americans aboard just so they could have naval superiority.

The plan had three big flaws.

1. Mexico was wise enough to realize this was utter idiocy. The last time they fought the US, they got demolished, and when the US withdrew it's forces from Mexico (where they had been pursuing a guy named Pancho Villa who they and the current Mexican leadership wanted with his head on a pike) shortly prior because the US help was wearing out it's welcome, they had no reason to start anything with the US and told the Germans to shove it.

2. The Germans pretended to openly consider the US a potential neutral party for possible peace negotiations up until this little plot came out, and they destroyed any and all good-faith the US had assumed of them when Arthur Zimmerman admitted he was the author of the decrypted telegram that the British intercepted that had him spell out his scheme for getting Mexico onboard with the German war effort.

3. The Germans practiced stupid cipher security. They sent the Zimmerman telegram via two separate channels, one in a rather hard to crack cipher, one that was older and had security flaws, and the British found the weaker of the two, compared it to the other one, and managed to piece together the unencrypted version based on their notes on both ciphers. Because of this laziness, the British provided the US with an intelligence bombshell and President Woodrow Wilson had a perfect causus belli for declaring war on Germany.

Tuesday, March 10, 2020

Spreadsheet Cipher: Numerical Edition

In a previous post, I created a computer-based cipher usable from a spreadsheet program, but that cipher only included letters. Below is an expanded version that also includes numerical ciphering capability. (with numbers 1-9, with 0 at the end)

This one follows the same basic rules as the previous cipher, but with the punctuation marks not included. Letters can be placed where that would go, such as for commas, according to any additional rules the cipher maker wishes to specify if that is needed.

The table below is again a sample set of tables that can be randomized and expanded as needed for security, so long as all the rules of the base cipher are still adhered to.

While still reasonably secure, this cipher can be strengthened by having each row mix the numbers and letters at random on each line, as opposed to having the letters than numbers mixed as seen below. Otherwise, knowledge numbers are used to encrypt other numbers alone may provide a hint to break the cipher shield.



V W X Y Z A B C D E F G H I J K L M N O P Q R S T U 4 8 6 9 2 7 3 0 1 5
M N O P Q R S T U V W X Y Z A B C D E F G H I J K L 9 1 0 3 7 5 4 2 6 8
U V W X Y Z A B C D E F G H I J K L M N O P Q R S T 8 6 7 5 0 3 1 4 2 9
B C D E F G H I J K L M N O P Q R S T U V W X Y Z A 3 0 5 7 1 4 2 6 8 9
H I J K L M N O P Q R S T U V W X Y Z A B C D E F G 9 8 6 2 4 7 0 3 1 5
D E F G H I J K L M N O P Q R S T U V W X Y Z A B C 7 3 5 9 1 4 2 6 0 8
I J K L M N O P Q R S T U V W X Y Z A B C D E F G H 3 9 7 5 6 8 1 4 0 2
Q R S T U V W X Y Z A B C D E F G H I J K L M N O P 4 1 5 7 3 0 2 6 8 9
J K L M N O P Q R S T U V W X Y Z A B C D E F G H I 8 6 9 2 4 1 5 7 0 3
W X Y Z A B C D E F G H I J K L M N O P Q R S T U V 0 3 7 5 1 4 2 9 8 6
F G H I J K L M N O P Q R S T U V W X Y Z A B C D E 4 7 2 8 6 8 3 9 5 1
C D E F G H I J K L M N O P Q R S T U V W X Y Z A B 2 6 9 3 0 5 1 0 7 8
P Q R S T U V W X Y Z A B C D E F G H I J K L M N O 6 1 9 0 3 7 4 1 5 2
Z A B C D E F G H I J K L M N O P Q R S T U V W X Y 9 5 4 1 7 3 0 2 2 6
X Y Z A B C D E F G H I J K L M N O P Q R S T U V W 7 8 2 6 4 1 5 3 0 9
G H I J K L M N O P Q R S T U V W X Y Z A B C D E F 3 0 7 5 1 2 6 4 8 9
L M N O P Q R S T U V W X Y Z A B C D E F G H I J K 6 7 0 3 2 4 1 5 8 9
Y Z A B C D E F G H I J K L M N O P Q R S T U V W X 7 1 2 6 8 9 4 6 3 5
E F G H I J K L M N O P Q R S T U V W X Y Z A B C D 8 9 7 3 0 5 2 7 6 4
K L M N O P Q R S T U V W X Y Z A B C D E F G H I J 9 6 4 2 1 0 3 8 5 7
R S T U V W X Y Z A B C D E F G H I J K L M N O P Q 2 5 7 0 3 1 4 9 6 8
O P Q R S T U V W X Y Z A B C D E F G H I J K L M N 4 9 8 6 2 7 0 3 5 1
S T U V W X Y Z A B C D E F G H I J K L M N O P Q R 0 3 5 1 4 7 2 9 8 6
N O P Q R S T U V W X Y Z A B C D E F G H I J K L M 9 8 4 6 2 1 5 7 0 3
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 9 0 7 5 1 8 4 3 2 6
T U V W X Y Z A B C D E F G H I J K L M N O P Q R S 7 6 9 2 3 0 5 4 8 1

Monday, March 2, 2020

The Spreadsheet Cipher: Further Information

When I designed my spreadsheet cipher, I examined several classical cryptographic systems and decided I wanted to have many of their strengths and very few of their weaknesses while still leaving it easy for a single person to encrypt and decrypt.

What my method does and does not have are the following.


1. No cipher block limit. The cylindrical cryptograph of Etienne Bazeries had twenty discs with twenty-five letters on the outer rim of the discs. Thomas Jefferson's wheel cypher had thirty-six discs with twenty-six letters on rims. The strip cipher of Parker Hitt had twenty-five discs and letters, though the non-cylindrical version could be enlarged with as many additional lines of ciphertexts whenever desired and the position of each ciphertext was not fixed like on the cylinder version.

A common flaw in all these methods is the overreliance on the imposed limits. For example, the Hitt cipher could only decrypt twenty-five characters of any ciphertext before you had to use another ciphertext for the next segment. The other systems mentioned all had similar weaknesses.

I, therefore, got rid of the limit, the message can be of any length and the cipher key for that message will be applicable for the entire length of what that message is keyed to be solved with, This should prevent using knowledge of the length of each ciphertext being used to create frequency tables for cracking the cipher.



2. Ease of encryption while making cryptanalysis difficult.

Another challenge I had when creating my method was that I needed to balance the ease of use by the intended cipher solver to the third party who I would NOT want to solve it via cryptanalysis.

The Vigenere system of Blaise de Vigenere is anything but secure. The Confederacy of Northern America found to their sorrow their trust in that system was to their detriment, and I did not want to use it's known alphabet table sequence since it's a very easily solved one by anyone with knowledge of how the table is created.

I, therefore, made it so the alphabet table rows and columns can be randomized so long as each row or column (whichever is used for plaintext and ciphertext encryption and decryption) contained twenty-six letters and each part of the row or column uses each letter once.

This allows for cipher keys to be quickly created and changed on the fly so different portions of the enciphered text can switch between different sections of the alphabet tables for different encryption alphabets while keeping things just random enough a cryptanalyst would be flying completely blind so long as both the keys and alphabet table are kept secure, though only one at minimum need to remain completely secret at the very least.


3. I created this cipher on a computer, and I wanted it to be easily editable and readable on all electronic devices, and since spaced digits and characters translate well to any spreadsheet program and whatever rows and columns the cipher alphabets sit on can be completely randomized, this allows anyone to modify this cipher at will for their own purposes so long as they keep both the cipher keys and the alphabet tables from both being available to those not entrusted with them. That is the only weak link in the security chain I could not avoid, but other modern-day methods of concealing documents can be combined with my method for better concealment of that information at the discretion of the cipher creator.

The Spreadsheet Cipher: My fun little experiment in creating a cipher system

I've been reading up on cryptology for a while, so I thought I'd try my hand at making a cipher of my own, just for fun. It's not anywhere as secure as modern-day cipher systems, my version is a modified variant that borrows elements from several classical ciphers that have fallen out of regular use, but that all said, I designed this cipher to be fairly secure and easily usable for anyone with access to a spreadsheet program like Microsoft Excel or LibreOffice Calc.

Now, a little background. It's a polyalphabetic (uses more than one series of letters in several rows) substitution cipher with a key system similar to that used by the M-94 and M-138 that were the brainchild of US Army officers Joseph Mauborgne and Parker Hitt. My version uses an altered variant of the alphabet tables used by Blaise de Vigenere, but I otherwise want to avoid the security flaws of the Vigenere system. I also decided to take some hints from the one-time pad system, particularly the German variant the Weimar Republic used in 1923 and became the regular standard for most espionage organizations even to this day.

The resulting 26 x 26 alphabet tables I came up with looks like this:


V W X Y Z A B C D E F G H I J K L M N O P Q R S T U
M N O P Q R S T U V W X Y Z A B C D E F G H I J K L
U V W X Y Z A B C D E F G H I J K L M N O P Q R S T
B C D E F G H I J K L M N O P Q R S T U V W X Y Z A
H I J K L M N O P Q R S T U V W X Y Z A B C D E F G
D E F G H I J K L M N O P Q R S T U V W X Y Z A B C
I J K L M N O P Q R S T U V W X Y Z A B C D E F G H
Q R S T U V W X Y Z A B C D E F G H I J K L M N O P
J K L M N O P Q R S T U V W X Y Z A B C D E F G H I
W X Y Z A B C D E F G H I J K L M N O P Q R S T U V
F G H I J K L M N O P Q R S T U V W X Y Z A B C D E
C D E F G H I J K L M N O P Q R S T U V W X Y Z A B
P Q R S T U V W X Y Z A B C D E F G H I J K L M N O
Z A B C D E F G H I J K L M N O P Q R S T U V W X Y
X Y Z A B C D E F G H I J K L M N O P Q R S T U V W
G H I J K L M N O P Q R S T U V W X Y Z A B C D E F
L M N O P Q R S T U V W X Y Z A B C D E F G H I J K
Y Z A B C D E F G H I J K L M N O P Q R S T U V W X
E F G H I J K L M N O P Q R S T U V W X Y Z A B C D
K L M N O P Q R S T U V W X Y Z A B C D E F G H I J
R S T U V W X Y Z A B C D E F G H I J K L M N O P Q
O P Q R S T U V W X Y Z A B C D E F G H I J K L M N
S T U V W X Y Z A B C D E F G H I J K L M N O P Q R
N O P Q R S T U V W X Y Z A B C D E F G H I J K L M
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
T U V W X Y Z A B C D E F G H I J K L M N O P Q R S


Now, by itself, this is just some bog standard series of alphabet tables. As one might be able to guess, one is to decrypt one line or paragraph at a time using this system, and any non-letter symbol can be used to denote spaces between words if you like (I discourage this to prevent frequency analysis based on word length, nulls are an easy tell to suss out cipher solutions in this case). Now for this cipher to maintain security, the spreadsheet keys will come on a separate page, each line or series of lines to decipher prefaced by a number in this format before the ciphered text : (1+2)


The first number denotes row one is the plaintext, and the second number is the row used for the cipher text.


V W X Y Z A B C D E F G H I J K L M N O P Q R S T U
M N O P Q R S T U V W X Y Z A B C D E F G H I J K L

Using the above with the first two rows assumes that the plain text "This is an example" will render the following in ciphertext (without spaces)

KYZJZJREVORDGCV

With knowledge of the key for the plain and cipher text rows, we can render this back into intelligible words.

For security purposes, the letters in the rows can be randomized on occasion to make for a one-time pad system, and so long as you keep the keys for each line secure between you and the party you want to solve the message and you each have an updated copy of the alphabet tables, it will drive the average cipher solver a little crazy if they don't know how to decrypt the ciphertext without knowing which row helps recover the actual text. I used a modified version of classic Vigenere tables for my demonstration, but any 26 x 26 series of randomized tables using a standard A-Z alphabet with every line using each letter just once will work fine and can be adapted to any spreadsheet program and keys for solving each line of text can be easily created. You can enhance security further by limiting each key to a single word if you really want to frazzle cryptanalysis by a third party, without knowledge of the key lines for decipherment, even having the whole table will give them far too many possibilities to check without knowing the exact keys for decipherment of each item that keys are assigned for decrypting.

Now, this method is not foolproof. Frequency analysis of certain letters by a dedicated cipher solver can eventually break the encryption shield, my method is very similar to the US Army M-138A strip cipher the Germans finally cracked in 1944, but uses a slight different keying method. Regardless, the logic is similar between both encryption systems.

It would be possible to go by columns instead of rows for cipher and plaintext for this method, which would add some extra difficulty to guessing the actual key for the cipher. One can also add a THIRD line to encipher the ciphertext to create a super encipherment, which would really annoy third-party cryptanalysis.

Now, I just want to reiterate this is just something I came up with for fun. I don't advise anyone seriously put their faith in this to hide anything important, it was just a fun little experiment I did after reading a lot of texts on cryptology recently. Besides, everything I based this on is public domain knowledge, and in the cryptology world, anything in the public domain is not and will never be foolproof.

A Farewell to My Father

 My father just passed April 1, 2024 6:36 PM. For those reading this, I want to make absolutely clear the world lost a great man named John ...