The History and Mathematics of Codes and Code Breaking

Month: September 2018 (Page 1 of 9)

Ethics in Wartime

Would you sacrifice one life to save a thousand? It is a morally stupefying question that has gone against our societies ethics. Do we favor the collective good over the good of the individual? However ambiguous the answer is during peace, I believe the answer is clear in wartime. The collective good takes precedent. Admiral William Hall knew this to be true when making the decision to keep the Zimmerman telegram a secret.

The implications of the Zimmerman telegram were possibly multiple civilian casualties as a result of unrestricted U-boat warfare. Admiral Hall knew this and weighed his options. He knew if he passed on the information to President Wilson, the Germans would inevitable know that the British had cracked their code. This with the fact that Admiral Hall knew that the U-boat warfare would most likely incite The U.S. to enter the war all factored into his decision to keep the intelligence a secret.

Admiral William Halls decision reminded me of the movie The Imitation Game staring Benedict Cumberbatch. In the final scene after the British cryptanalysis team crack the seemingly unbreakable Enigma code machine, Alan Turing (played by Benedict Cumberbatch) realizes they cannot immediately act on every piece of information, even if it means saving hundreds of life's. In a captivating moment the characters agree that the outcome of the war depends on the secrecy of their work's completion. In closing, I believe that Admiral Hall's decision was ethical in the time and place he made it, even if today we might regard it conversely.


Is cryptanalysis really as easy as Singh makes it seem?

As Singh deciphered the example of the Vigènere cipher on page 116, and also other ciphers previously, I contemplated just how simple he was making them. He makes a lot of assumptions, and he also never points out some flaws that I have seen in his messages. In the example on page 16, Singh uses a message that makes his technique work very well. In this example, he uses a keyphrase that is as long as the message. Normally, this should be almost impossible to crack, because none of the cipher alphabets would be repeated in a pattern. He proposes a solution, by placing common words (he uses "the") in random locations in the plaintext. In his example, he gets it right on the first try. This is not that unlikely with such a short message, but a full paragraph of a long letter would take many more tries. He also makes the assumption that the cryptographer encrypting the message would use the word "the", or "and", or whatever word. If a cryptographer knew their code could be broken that way, they could simply refrain from using common words often. Once there are fewer common words present,  it becomes much more difficult to crack. In addition, using the method he proposed can cause false positives. It's possible that the letters "the" in the plaintext produce a discernible string of three letters in the ciphertext. If the cryptographer was smart, they could place a few traps, so that random keywords would show up in the cipher text. This would completely confuse the person deciphering the code, and may just make it extremely difficult to crack. Singh fails to address these flaws in his examples, and it makes it cryptanalysis seem easier than it really is.

Why Cryptanalysis Seems Easier Than It Actually Is

Singh's examples in book seem easy to comprehend. The methods are relatively straightforward and codes were broken within few pages of the book. However, in practice the process of cryptanalysis is usually much more complicated. I believe there are three reasons for that.

First of all, the cryptanalyst has no idea what type of code is being used. Surely a frequency analysis could narrow the answer: if frequency is equal for all letters it's probably a Vigenère cipher; if frequencies don't change it's probably a transposition cipher; if frequencies follow the same pattern as English alphabets it's probably some type of shift cipher. However, those are not the only types of ciphers that can be utilized, and even if we manage to narrow it down to a few of them, they might each require different cryptanalysis methods, and that takes time.

Secondly, cryptographers could mix unimportant information with the actual content. For instance, they could encode a string of random letters and hide the real message in between them. For a cryptanalyst, if the bunk of the message doesn't make sense, he/she would assume the analysis is wrong and resort to the next solution.

Last but not least, it's hard to guess. In a lot of the examples in the book, the author takes several guesses and one of them yielded the right result. When we are doing cryptanalysis, sometimes it takes a dozen guesses to find the right answer. Sometimes we are not finding the right piece of code to guess upon. All of which takes up a lot of time and in the world of cryptanalysis, time is everything.

General Michael V. Hayden: The Assault on Intelligence

Being completely honest, most of this talk went over my head. I tried to take notes as I was trying to take notes as I was listening, but they were speaking very quickly, and I couldn't really comprehend what they were saying. This is my attempt at notes:

  • First off, this talk has started out very political, which is not what I was expecting. They are barely talking about security of surveillance or anything like that, which is what I was expecting. I’m not a very political person and I’ve never been interested in political issues in America, so a lot of this stuff just kind of flew over my head. As of now, it’s been 25 minutes, and they’ve mostly been talking about politics. It seems like they don’t like Trump.
  • Hamiltonian, Jeffersonian, Wilsonian, Jacksonian. Says Trump is Jeffersonian.
  • Why did x happen in America? x= Al-qaeda, rise of Isis, etc. A mixture of instability between people in America, and a drifting of political culture. Grievance to post-truth drift. Social Media is like a Dorito. A Dorito looks like a tortilla chip, but instead it just delivers salt and fat. Social media seems good, but the more you use it, the more you get pulled into your own self-identity.
  • 3 principles in internationalist view: immigration is good for America’s economy, trade is good for America’s economy, and alliances are good. Isn’t that kind of obvious?
  • If the president decides that the national security of the US needs a nuclear attack, how does that happen?
    • It has to bounce between a few groups/people.
    • Hayden is concerned about miscalculation.
    • This man definitely doesn’t like Trump.
  • They talked a bit about what is going on today on Capitol Hill with Kavanaugh and Dr. Ford and all that business.
  • Drew a relationship between the William Jennings Bryant and the presidential race today. Bryant didn’t want to adapt to the times and go along with industrialization. It was a bit unclear what he said about how it relates today.
  • The audience is probably 85% adults, 12% law students who were either interested or had to come to this, and then there are a few undergrads here. I was definitely not prepared for this. I think most of the people here know this stuff well enough to know what is being talked about, so I definitely don’t fit in here very well.






Breaking (Almost) Unbreakable Ciphers

The strength of the Vigenère Cipher depends largely on the length of the keyword. If the keyword is just one letter, then it is nothing more than a simple shift cipher; if the keyword is the same length as the plain text, there will be little to no discernable pattern. However, Singh clearly demonstrates that even with a keyword as long as the text, breaking the Vigenère is doable by guessing common words like "the."

Even though it is relatively straightforward to break even these more secure ciphers, doing so in practice is often much harder. Primarily, this is because of the amount of guessing and checking required and the creative insights necessary to realize the best way to break the code. During the process of deciphering the message, and essential step is guessing words either in the plain text or in the keyword, and if your guess is wrong, you have to backtrack until you are confident that all of your work is correct and start from there again. This makes the process of cryptanalysis tedious and time-consuming.

Once you know what method to use to break the cipher, deciphering the message is only a matter of time, but often, figuring out how to approach a complicated cipher takes even the smartest cryptanalysts years to figure out on their own. For example, breaking the simple Vigenère cipher was not difficult; once Charles Babbage figured out how to break it, the Vigenère went from being an unbreakable cipher to extremely insecure overnight. This demonstrates that breaking the cipher itself is often not the most difficult part; the hardest part of breaking complex ciphers is coming up with a foolproof method which exploits weaknesses in the cipher.

Ethics Versus Strategy

I believe that the decision taken by Admiral William Hall was the right one, even though it was unethical. While it was morally wrong for him to let civilians die for a strategic gain, it was the right course of action to take for a man in his position. He was responsible for winning the war for his country. As an Admiral, he was first a patriot and then maybe a philanthropist. In an epoch of war, his loyalty and compassion was largely towards the citizens of his own country. He believed that the involvement of America in the World War was imminent which meant that giving them this telegram would bear no strategic advantage. Sacrificing a few civilian lives to potentially save several others over the course of the War by intercepting and decrypting German messages seemed like a good bargain to him.

The reason why the unethical choice in this case seemed to be the right choice was that he was in a situation where everyone else seemed to be lacking moral fiber. The Germans, his enemies in the War, were willing to attack civilians and break the rules set up by consensus in international court. To try to follow your conscience in a time of war will most likely cause you to the lose the war since a sense of self preservation always prevails over ethics.

Admiral Hall's Choice to Consider the Long Term Threats to a Nation.

Admiral William Hall decided to keep the information that the English broke the enciphered Zimmerman telegram a secret because he believed that the knowledge for decrypting the telegram would be an asset to the them in the near future. Those who were thoughtful of the future such as Admiral Hall would believe this choice to be ethical. This choice is very strategic and could be useful if the Germans continued to pass similarity sensitive and important information with the same encryption key. Having the ability to decipher these messages could save the lives of many civilians if the Germans eventually decided to attack. Through this lens it is reasonable to consider the decision as ethical because it is in the interest of the public and benefits their well being.

However, when considering the immediate importance of the content within the Zimmerman telegram, it makes sense that the choice to withhold the information seems unethical. The sensitive information about unrestricted U-boat warfare and threat of Mexican aggression posed immediate harm to many civilians in American and at sea. Hall’s choice seems indifferent to the lives current at stake and prioritized the future of a nation more than the nation’s current safety. It can be argued that the welfare of the nation’s future is dependent on that nation’s present welfare and that Admiral Hall should have responded with more urgency to the immediate threat to the people. His choice can be seen as ethical or unethical depending on what one prioritizes more.


How was the German cipher deciphered in World War II?

At the Brechley Manor, in addition to Knox, the deciphering community, there is also a mathematics wizard, Turing. He graduated from Cambridge University and relied on his research on cryptography after the war. He became one of the pioneers in the era of electronic computing.

First of all, they started with the development of a machine that can imitate or explain every "dummy mystery" of the German Defence Force, so that it can launch all the coding procedures that are frequently changed when the main command of the German army is issued day and night, and when the adult orders are issued. After a difficult attack, the British finally made the machine with the above functions and named it "bomb."

At the end of 1939, the "bomb" deciphered the German code, and the British were ecstatic. Since then, the German secret plan and action plan has been continuously transmitted from the Brenchley Manor to Colonel Menzies, and then directly to Churchill's desk. In fact, most of the German actions during the "World War II" failed to win the British, but the British have always concealed the source of intelligence, and have never caused doubts from opponents.

On July 2, 1940, Hitler released the first "Sea Lion" combat plan, which is also the British local landing operations plan. At the beginning of the campaign, Churchill and the Air Force staff learned most of the German Air Force – sometimes even all of them – through “super secrets”.

In response to the command of the German Air Force Commander Goring to seize the air superiority, the Royal Air Force has developed a plan to concentrate its superiority against the enemy. Since the number of aircraft of the British Air Force is not much in Germany, the fighter squadron and the main defensive forces can only be concentrated at the appropriate time, in the right place and at the appropriate height to deal with the enemy's main attack power. Relying on early warning radars and deciphered German military intelligence, the Royal Air Force can always take advantage of the arrival of the Nazi Air Force to accurately intercept the interception, without the need for time and space patrols to guard against German raids - the British Air Force has greatly reduced the pilot's physical consumption and gasoline Wait for strategic material consumption.

On August 13, 1940, over Sussex and Kent, 80 German "Donil 17" bombers, and a larger number of "Junker 88" dive bombers, flew to the British hinterland and coastline to carry out bombing missions. Due to the dense clouds in the sky, the German escort fighters could not take off as planned, and the bombers had to attack alone.

The British Air Force Command had already known the German action plan in advance. When the German plane was found on the radar, it immediately launched an operational plan that was already ready. In this confrontation, the German Air Force lost a total of 47 aircraft and more than 80 were injured. The British Air Force lost only 13 aircraft.

So actually in the WW1, the cipher of the German military should not be posted. It directly results in that the cipher of WW2 is deciphered.

Ethical? Necessary.

In the movie “The Imitation Game,” there is a scene that Alan Turing and his team deciphered a message indicating that there is going to be an attack on the British Navy. After celebrating for finally able to beat the Enigma Machine made by Germany, they calmed down quickly and decided not to present the message to the British Navy. It's confusing for me at first of why they chose to keep the attack as a secret, but I then understood the importance of keeping some of the messages private for the good of the big picture. It took unimaginable great effort for Turing’s team to figure out how to defeat the Enigma Machine. They can’t risk the chance to let the German Intelligence find out that they cracked the code. If they changed the Enigma Machine into other types of encrypting methods, more damage than a team of warships would be made and the war might have gone in another direction. In special times, some small sacrifices need to be made to win the war.

      It’s just like what Admiral Hall did to President Wilson. If they can’t find a source of retrieving the information that they can explain, the Germans will change the encrypting methods, and the British cryptanalysts will lose the advantage. Is it ethical? It’s probably not. However, it’s the war situation; so it needs to be treated differently. Admiral Hall did this so that the American, the most powerful country in the world, can join the Allies and fight German. It’s the war strategy and leads to an acceptable result. When the messages were spread out later, the damage made can be accepted for the privilege of the great world war.

On the other hand, after the Americans joined the Allies, it’s also helping the Americans if they have access to decipher the German messages. Therefore, it’s necessary for Admiral Hall to keep some messages secret. It’s too much to risk as they will lose all of their achievements the fact that they broke the German Code was known.

Insightful ideas provided by General Hayden

The former NSA and CIA director, General Michael V. Hayden, was interviewed by Chancellor Nicholas Zeppos and Professor Jon Meacham. Before going to the lecture, I thought that the interview’s going to be a debate of “Security versus Privacy.” However, it is more about political views and the current direction of the United States.

During the interview, questions regarding President Donald Trump’s presidency were asked. It’s the first time I heard political figures being categorized into different groups using the name of the representative presidents. For example, he classified President Trump as a “Jacksonian” and President Obama as a “Jeffersonian.” It’s interesting to see the present figures fit into past groups to help understand the current presidential positions.

What I also paid attention to was the general’s view of the trade war with China. He said in the lecture that Beijing is not the enemy. It’s quite interesting to see a director of CIA from the time of George Bush to have a friendly view of the Chinese government. He claimed that trades and connections with China are beneficial for both sides, especially for the United States. Media these days often exaggerate the crisis and conflicts between the United States and China. They want to make the tension seem more intense so that they’ll have more stories to write about. But it's not the real situation. There’s a statement in economic that “Trades make everyone better off.” The positive connection between two super countries in the world will definitely increase the economic growth of each country or even the whole world. That’s the point of global cooperation.

The lecture provided several insightful ideas about the current global situation and developing directions that I never heard before. It’s not so much on the topic “The Assault on Intelligence,” but it’s still interesting anyway.

Page 1 of 9

Powered by WordPress & Theme by Anders Norén