You get a bonus - 1 coin for daily activity. Now you have 1 coin

Public key cryptosystem

Lecture



A public-key cryptographic system (or asymmetric encryption , asymmetric cipher ) is an encryption and / or electronic signature (ES) system in which the public key is transmitted over an open (i.e., unprotected, available for observation) channel and is used to check the ES and encrypt messages. To generate electronic signature and to decrypt the message, use the private key [1]. Public key cryptographic systems are now widely used in various network protocols, in particular, in TLS protocols and its predecessor SSL (underlying HTTPS) in SSH. Also used in PGP, S / MIME.

The idea of ​​a public key cryptosystem

The idea of ​​public-key cryptography is very closely related to the idea of ​​one-way functions, that is, such functions Public key cryptosystem what is known Public key cryptosystem quite easy to find value Public key cryptosystem , while the definition Public key cryptosystem of Public key cryptosystem impossible for a reasonable time.

But the one-way function itself is useless in its application: it can encrypt a message, but it cannot be decrypted. Therefore, public key cryptography uses one-way functions with a loophole. A loophole is a secret that helps to decipher. That is, there is such Public key cryptosystem that knowing Public key cryptosystem and Public key cryptosystem can calculate Public key cryptosystem . For example, if you disassemble a clock into many parts, it is very difficult to assemble again working hours. But if there is an assembly instruction (loophole), then this problem can be easily solved.

The following example helps to understand the ideas and methods of public-key cryptography - storing passwords in a computer. Every user on the network has a password. When entering, he specifies a name and enters a secret password. But if you store the password on a computer disk, then someone can read it (it is especially easy to do it for the administrator of this computer) and get access to secret information. To solve the problem, a one-way function is used. When creating a secret password in a computer, it is not the password itself that is saved, but the result of the calculation of the function from this password and user name. For example, user Alice came up with the password "Gladiolus". When saving this data, the result of the function is calculated. Public key cryptosystem ( ALISA_GLADIOLUS ), let the result be the Daisy string, which will be stored in the system. As a result, the password file will look as follows:

Name Public key cryptosystem (Name: Password)
ALICE CHAMOMILE
BEAN NARCISSUS

Login now looks like this:

Name: ALICE
Password: GLADIOLUS

When Alice enters a “secret” password, the computer checks whether or not the function applied to ALISA_GLADIOL gives the correct result CAMOMILE stored on the computer disk. It is necessary to change at least one letter in the name or in the password, and the result of the function will be completely different. The “secret” password is not stored in the computer in any way. The password file can now be viewed by other users without losing privacy, since the function is almost irreversible.

In the previous example, a one-way function is used without a loophole, since it is not required to receive the original one using an encrypted message. The following example considers a scheme with the ability to restore the original message using a "loophole", that is, inaccessible information. To encrypt text, you can take a large subscriber directory, consisting of several thick volumes (it is very easy to find the number of any resident of the city, but it is almost impossible to find a subscriber by a known number). For each letter from the encrypted message is selected a name that starts with the same letter. Thus, the letter is assigned to the telephone number of the subscriber. The message sent, for example " BOX ", will be encrypted as follows:

Message Selected name Cryptotext
TO Korolev 5643452
ABOUT Nuts 3572651
R Ruzaeva 4673956
O Osipov 3517289
B Baturin 7755628
TO Kirsanova 1235267
BUT Arsenyev 8492746

The cryptotext will be a chain of numbers recorded in the order of their selection in the directory. To make it difficult to decipher, you should choose random names that begin with the desired letter. Thus, the original message can be encrypted with many different lists of numbers (cryptotext).

Examples of such cryptotext:

Cryptotext 1 Cryptotext 2 Cryptotext 3
1235267 5643452 1235267
3572651 3517289 3517289
4673956 4673956 4673956
3517289 3572651 3572651
7755628 7755628 7755628
5643452 1235267 5643452
8492746 8492746 8492746

To decipher the text, you must have a directory, compiled according to the increase of numbers. This handbook is a loophole (a secret that helps get the initial text), known only to legal users. Without a copy of the directory, the cryptanalyst will spend a lot of time decrypting. [2]

Public key encryption scheme

Let be Public key cryptosystem - key space, and Public key cryptosystem and Public key cryptosystem - encryption and decryption keys, respectively. Public key cryptosystem - encryption function for an arbitrary key Public key cryptosystemPublic key cryptosystem Public key cryptosystem such that:

Public key cryptosystem

Here Public key cryptosystemPublic key cryptosystemPublic key cryptosystem where Public key cryptosystem - space of ciphertexts, and Public key cryptosystemPublic key cryptosystemPublic key cryptosystem where Public key cryptosystem - message space.

Public key cryptosystem - the decryption function, with which you can find the original message Public key cryptosystem knowing ciphertext Public key cryptosystem :

Public key cryptosystem

{ Public key cryptosystem : Public key cryptosystemPublic key cryptosystem Public key cryptosystem } Is the encryption set, and { Public key cryptosystem : Public key cryptosystemPublic key cryptosystem Public key cryptosystem } Is the appropriate decryption set. Each pair Public key cryptosystem has the property: knowing Public key cryptosystem impossible to solve the equation Public key cryptosystem that is, for a given arbitrary ciphertext Public key cryptosystemPublic key cryptosystemPublic key cryptosystem , unable to find message Public key cryptosystemPublic key cryptosystemPublic key cryptosystem . This means that by this Public key cryptosystem unable to determine appropriate decryption key Public key cryptosystem . Public key cryptosystem is a one-way function, but Public key cryptosystem - eyelet. [3]

Below is a diagram of the transfer of information by person A to person B. They can be both individuals and organizations, and so on. But for easier perception, it is common practice to identify participants with people, most commonly referred to as Alice and Bob. The participant who seeks to intercept and decipher the messages of Alice and Bob is most often called Eva.

Public key cryptosystem

  1. Bob picks a couple Public key cryptosystem and sends the encryption key Public key cryptosystem (public key) Alice through the open channel, and the decryption key Public key cryptosystem (private key) is protected and secret (it should not be transmitted over an open channel).
  2. To send a message Public key cryptosystem Bob, Alice uses a public key encryption function Public key cryptosystem : Public key cryptosystem , Public key cryptosystem - received ciphertext.
  3. Bob decrypts ciphertext Public key cryptosystem by applying the inverse transform Public key cryptosystem uniquely determined by value Public key cryptosystem .

Scientific basis

The beginning of asymmetric ciphers was laid in the work “New Directions in Modern Cryptography” by Whitfield Diffie and Martin Hellman, published in 1976. Being influenced by the work of Ralph Merkle on the distribution of the public key, they proposed a method for obtaining the secret keys using a public channel. This method of exponential key exchange, which became known as Diffie-Hellman key exchange, was the first published practical method for establishing the separation of a secret key between authenticated channel users. In 2002, Hellman proposed to call this algorithm "Diffie - Hellman - Merkle", recognizing the contribution of Merkle to the invention of public key cryptography. The same scheme was developed by Malcolm Williamson in the 1970s, but kept secret until 1997. The Merkle method of public key distribution was invented in 1974 and published in 1978, it is also called the Merkle mystery.

In 1977, scientists Ronald Rivest, Adi Shamir and Leonard Adleman of the Massachusetts Institute of Technology developed an encryption algorithm based on a factoring problem. The system was named after the first letters of their surnames (RSA - Rivest, Shamir, Adleman). The same system was invented in 1973 by Clifford Cox (Eng. Clifford c *** ks ), who worked at the Government Communications Center (GCHQ), but this work was kept only in the internal documents of the center, so its existence was not known until 1977 . RSA was the first algorithm, suitable for both encryption and digital signature.

In general, the basis of known asymmetric cryptosystems is one of the complex mathematical problems, which allows one to construct one-way functions and loophole functions. For example, the Merkle-Hellman and Hora-Rivesta cryptosystems rely on the so-called backpack packing problem.

Basic principles of constructing public-key cryptosystems

  1. We start with a difficult task. Public key cryptosystem . It should be difficult to solve in the sense of a theory: there should not be an algorithm with which one could sort out all the solutions to the problem Public key cryptosystem in polynomial time relative to the size of the problem. It is more correct to say: there should not be a known polynomial algorithm that solves this problem - since it has not yet been proved for any problem that there is no suitable algorithm for it in principle.
  2. There is an easy subtask. Public key cryptosystem of Public key cryptosystem . It should be solved in polynomial time and better if linear.
  3. “Shuffle and Shake” Public key cryptosystem to get the task Public key cryptosystem completely different from the original. Task Public key cryptosystem should at least look like the original intractable task Public key cryptosystem .
  4. Public key cryptosystem opens with a description of how it can be used as an encryption key. How of Public key cryptosystem receive Public key cryptosystem Kept secret as a secret loophole.
  5. The cryptosystem is organized in such a way that the decryption algorithms for the legal user and the cryptanalyst are significantly different. While the second decides Public key cryptosystem -problem, the first uses a secret loophole and solves Public key cryptosystem -task

Multiple public key cryptography

  • The following example shows a scheme in which Alice encrypts a message so that only Bob can read it, and vice versa, Bob encrypts the message so that only Alice can decrypt it.

Let there be 3 keys Public key cryptosystem , Public key cryptosystem , Public key cryptosystem distributed as shown in the table.

Face Key
Alice Public key cryptosystem
Bean Public key cryptosystem
Carol Public key cryptosystem
Dave Public key cryptosystem , Public key cryptosystem
Ellen Public key cryptosystem , Public key cryptosystem
Franc Public key cryptosystem , Public key cryptosystem

Then Alice can encrypt the message with a key. Public key cryptosystem , and Ellen decrypt keys Public key cryptosystem , Public key cryptosystem , Carol - encrypt key Public key cryptosystem , and Dave decrypt the keys Public key cryptosystem , Public key cryptosystem . If Dave encrypts the message with a key Public key cryptosystem , the message will be able to read Ellen, if the key Public key cryptosystem , then Frank will be able to read it, if with both keys Public key cryptosystem and Public key cryptosystem , the message will read Carol. By analogy, there are other participants. Thus, if one subset of keys is used for encryption, the remaining keys of the set are required for decryption. This scheme can be used for n keys.

Encrypted by key Decrypted key
Public key cryptosystem and Public key cryptosystem Public key cryptosystem
Public key cryptosystem and Public key cryptosystem Public key cryptosystem
Public key cryptosystem and Public key cryptosystem Public key cryptosystem
Public key cryptosystem Public key cryptosystem , Public key cryptosystem
Public key cryptosystem Public key cryptosystem , Public key cryptosystem
Public key cryptosystem Public key cryptosystem , Public key cryptosystem
  • Now you can send messages to groups of agents, not knowing in advance the composition of the group.

Consider first a set of three agents: Alice, Bob and Carol. Alice issued keys Public key cryptosystem and Public key cryptosystem Bob - Public key cryptosystem and Public key cryptosystem , Carol - Public key cryptosystem and Public key cryptosystem . Now, if the message being sent is encrypted with a key Public key cryptosystem , then only Alice can read it, consistently applying keys Public key cryptosystem and Public key cryptosystem . If you want to send a message to Bob, the message is encrypted with a key. Public key cryptosystem , Carol - key Public key cryptosystem . If you want to send a message to both Alice and Carol, then keys are used for encryption. Public key cryptosystem and Public key cryptosystem .

Преимущество этой схемы заключается в том, что для её реализации нужно только одно сообщение и n ключей (в схеме с n агентами). Если передаются индивидуальные сообщения, то есть используются отдельные ключи для каждого агента (всего n ключей) и каждого сообщения, то для передачи сообщений всем различным подмножествам требуется Public key cryptosystem ключей.

Недостатком такой схемы является то, что необходимо также широковещательно передавать подмножество агентов (список имён может быть внушительным), которым нужно передать сообщение. Иначе каждому из них придется перебирать все комбинации ключей в поисках подходящей. Также агентам придется хранить немалый объём информации о ключах.[4]

Криптоанализ алгоритмов с открытым ключом

Казалось бы, что криптосистема с открытым ключом — идеальная система, не требующая безопасного канала для передачи ключа шифрования. Это подразумевало бы, что два легальных пользователя могли бы общаться по открытому каналу, не встречаясь, чтобы обменяться ключами. Unfortunately, this is not the case. Рисунок иллюстрирует, как Ева, выполняющая роль активного перехватчика, может захватить систему (расшифровать сообщение, предназначенное Бобу) без взламывания системы шифрования.

Public key cryptosystem

В этой модели Ева перехватывает открытый ключ Public key cryptosystem , посланный Бобом Алисе. Затем создает пару ключей Public key cryptosystem and Public key cryptosystem , «маскируется» под Боба, посылая Алисе открытый ключ Public key cryptosystem , который, как думает Алиса, открытый ключ, посланный ей Бобом. Ева перехватывает зашифрованные сообщения от Алисы к Бобу, расшифровывает их с помощью секретного ключа Public key cryptosystem , заново зашифровывает открытым ключом Public key cryptosystem Боба и отправляет сообщение Бобу. Таким образом, никто из участников не догадывается, что есть третье лицо, которое может как просто перехватить сообщение Public key cryptosystem , так и подменить его на ложное сообщение Public key cryptosystem . Это подчеркивает необходимость аутентификации открытых ключей. Для этого обычно используютсертификаты. Распределённое управление ключами в PGP решает возникшую проблему с помощью поручителей.[5][ неавторитетный источник? 585 дней ][ источник не указан 585 дней ]

Ещё одна форма атаки — вычисление закрытого ключа, зная открытый (рисунок ниже). Криптоаналитик знает алгоритм шифрования Public key cryptosystem , анализируя его, пытается найти Public key cryptosystem . Этот процесс упрощается, если криптоаналитик перехватил несколько криптотекстов с, посланных лицом A лицу B.

Public key cryptosystem

Большинство криптосистем с открытым ключом основаны на проблеме факторизации больших чисел. К примеру, RSA использует в качестве открытого ключа n произведение двух больших чисел. Сложность взлома такого алгоритма состоит в трудности разложения числа n на множители. Но эту задачу решить реально. И с каждым годом процесс разложения становится все быстрее. Ниже приведены данные разложения на множители с помощью алгоритма «Квадратичное решето».

Year Число десятичных разрядов
в разложенном числе
Во сколько раз сложнее разложить
на множители 512-битовое число
1983 71 > 20 млн
1985 80 > 2 млн
1988 90 250 тыс.
1989 100 30 тыс.
1993 120 500
1994 129 100

Также задачу разложения потенциально можно решить с помощью Алгоритма Шора при использовании достаточно мощного квантового компьютера.

Для многих методов несимметричного шифрования криптостойкость, полученная в результате криптоанализа, существенно отличается от величин, заявляемых разработчиками алгоритмов на основании теоретических оценок. Поэтому во многих странах вопрос применения алгоритмов шифрования данных находится в поле законодательного регулирования. В частности, в России к использованию в государственных и коммерческих организациях разрешены только те программные средства шифрования данных, которые прошли государственную сертификацию в административных органах, в частности, в ФСБ,ФСТЭК.[6]

Особенности системы

Application

Алгоритмы криптосистемы с открытым ключом можно использовать[7]

  • как самостоятельное средство для защиты передаваемой и хранимой информации,
  • как средство распределения ключей (обычно с помощью алгоритмов криптосистем с открытым ключом распределяют ключи, малые по объёму, а саму передачу больших информационных потоков осуществляют с помощью других алгоритмов),
  • как средство аутентификации пользователей.

Benefits

Преимущества асимметричных шифров перед симметричными:

  • Не нужно предварительно передавать секретный ключ по надёжному каналу.
  • Только одной стороне известен ключ шифрования, который нужно держать в секрете (в симметричной криптографии такой ключ известен обеим сторонам и должен держаться в секрете обеими).
  • Пару Public key cryptosystem можно не менять значительное время (при симметричном шифровании необходимо обновлять ключ после каждого факта передачи).
  • В больших сетях число ключей в асимметричной криптосистеме значительно меньше, чем в симметричной.

disadvantages

Недостатки алгоритма несимметричного шифрования в сравнении с симметричным:

  • В алгоритм сложнее внести изменения.
  • Хотя сообщения надежно шифруются, но получатель и отправитель самим фактом пересылки шифрованного сообщения «засвечиваются».[8]
  • Более длинные ключи. Ниже приведена таблица, сопоставляющая длину ключа симметричного алгоритма с длиной ключа RSA с аналогичной криптостойкостью:
Длина симметричного ключа, бит Длина ключа RSA, бит
56 384
64 512
80 768
112 1792
128 2304
  • Шифрование-расшифрование с использованием пары ключей проходит на два-три порядка медленнее, чем шифрование-расшифрование того же текста симметричным алгоритмом.
  • Требуются существенно бо́льшие вычислительные ресурсы, поэтому на практике асимметричные криптосистемы используются в сочетании с другими алгоритмами:
    1. Для ЭЦП сообщение предварительно подвергается хешированию, а с помощью асимметричного ключа подписывается лишь относительно небольшой результатхеш-функции.
    2. Для шифрования они используются в форме гибридных криптосистем, где большие объёмы данных шифруются симметричным шифром на сеансовом ключе, а с помощью асимметричного шифра передаётся только сам сеансовый ключ.

Виды асимметричных шифров

  • RSA (Rivest-Shamir-Adleman)
  • DSA (Digital Signature Algorithm)
  • Elgamal (Шифросистема Эль-Гамаля)
  • Diffie-Hellman (Обмен ключами Диффи — Хелмана)
  • ECDSA (Elliptic Curve Digital Signature Algorithm) is a public key algorithm for creating a digital signature.
  • GOST R 34.10-2001
  • Rabin
  • Luc
  • Mceliece
  • Williams System (Williams Cryptosystem)

see also

  • Block cipher
  • Stream cipher
  • public key infrastructure (PKI)
  • CEILIDH
  • Password complexity
  • Hushmail is a web based email service based on public key encryption.
created: 2014-08-31
updated: 2023-12-24
132646



Rating 9 of 10. count vote: 2
Are you satisfied?:



Comments


To leave a comment
If you have any suggestion, idea, thanks or comment, feel free to write. We really value feedback and are glad to hear your opinion.
To reply

Cryptography and cryptanalysis, Steganography and Stegoanalysis

Terms: Cryptography and cryptanalysis, Steganography and Stegoanalysis