Given by Geoffrey C. Fox at CPS714 Computational Science Information Track on June 2 99. Foils prepared May 30 99
Outside Index
Summary of Material
Note this material is not impacted by recent (Web) advances and so can be studied in "venerable" books such as: |
Network Security: Private Communication in a Public World, Kaufman, Perlman and Speciner, Prentice Hall 1995 |
Web leads to important new applications of security mathematics and nifty pure mathematics is making progress in cracking longer and longer keys |
We discuss Secret Key Technology and Public Key Technology with applications to
|
Outside Index Summary of Material
Geoffrey Fox |
Syracuse University |
NPAC |
111 College Place Syracuse NY 13244 4100 |
3154432163 |
Note this material is not impacted by recent (Web) advances and so can be studied in "venerable" books such as: |
Network Security: Private Communication in a Public World, Kaufman, Perlman and Speciner, Prentice Hall 1995 |
Web leads to important new applications of security mathematics and nifty pure mathematics is making progress in cracking longer and longer keys |
We discuss Secret Key Technology and Public Key Technology with applications to
|
This is old technology first attributed to Julius Caesar who used the nifty cipher which replaced every letter with that three letters further in the alphabet
|
Most ciphers involve an algorithm and a parameter (this is 3 in the above) where usually algorithm can be public but parameter is kept secret and is called a key
|
It would be easy to break Caesar's cipher but in general it is hard and in fact exponentially hard as breaking cipher involves some sort of combinatorial (exhaustive) search combined with clever ideas
|
Note that encoding/decoding can be computationally expensive but much less so than code breaking
|
Methods exist for three scenarios
|
There are three major types of cryptographic function which differ in functionality and performance |
Secret Key Cryptography is what we are most familiar with and has medium performance and functionality. It has one secret key |
Public Key Cryptography is a remarkable idea with some very important and non-intuitive capabilities. It is computationally intense and requires some infrastructure to implement. It involves one secret (called private) and one public key known to everybody.
|
Hash functions (or one way transformations) involve zero keys and encrypt in a way that cannot be decrypted. It is very fast |
Methods are combined to produce hybrid approaches that combine necessary speed and functionality |
1)Transmitting over insecure channels |
2)Storage on insecure media (essentially the same ideas as 1) but applied to a different need) |
3)Authentication of computers or people at end of a message transmission. This includes digital signatures and password hashing |
4)Integrity check that message delivered was the one sent (this is different from ensuring that nobody read information which is 1)). This is called message integrity |
This involves a single secret key and standards are DES (Digital Encryption Standard) and IDEA (International Data Encryption Algorithm) |
Commercial systems (used in SSL) are RC2 RC4 RC5
|
There is the natural use for either transmission over an insecure network or for storage on an insecure media. |
Strong Authentication implies that one can prove knowledge of a secret (key) without revealing the key and in particular without sending key between two individuals |
This is effective authentication but requires as many secrets as pairs of people who need to communicate. |
Public key version will only require one key for each individual wishing to be authenticated with anybody else and so is more practical for widespread deployment. N keys and not N2 as for secret key authentication. |
Secret key authentication is however faster and much easier to implement for any sets of sites that wish to establish authenticated communication with a shared secret. |
Each individual A and B picks a random number rA and rB which are only known to themselves and a fresh for session to be authenticated. There is shared key KAB which is not to be transmitted but A needs to know that B knows KAB and B needs to know that A knows KAB. The random numbers are known as challenges. |
rA |
Decrypt xA and see it gives rA |
Encrypt rA to give xA |
xA |
rB |
Encrypt rB to give xB |
xB |
Decrypt xB and see it gives rB |
Checksums are well known and a simple version can be gotten by dividing message into 32 bit groups and anding these groups together.
|
Such checksums or hashes (designed properly) cannot be inverted and represent a unique fingerprint of original message. |
A secret checksum combines this process with a secret key and produces a MIC (message integrity code) which can be decoded and checked |
This can be used with either a ciphertext or plaintext message and guarantees that information is stored or transmitted faithfully |
Note encrypting a message does not guarantee that it is not changed! |
MIC with plaintext is used by bank electronic fund transfer |
This is much younger than other approaches and was first published in 1975. As we have discussed this has distinctive feature of only needing one key per individual/organization requiring encrypted authenticated messaging |
It has nontrivial infrastructure to distribute the N public keys for N organizations but this is better than N2 keys for secret key cryptography |
Roughly the public key is a very large number that is the product of two primes. The private key is (related to) one of these primes. |
It is used differently in two cases which following foils do in detail
|
Suppose A has (public key,private key) <eA,dA> and B keys <eB,dB> |
A transmits a message mA to B encrypting it with B's public key eB |
B decrypts this message and reads it using private key dB |
Similarly B sends a message mB to A encrypting with eA which A decrypts with private key dA |
Plaintext |
Encryption |
Public Key |
Private Key |
Here A chooses a challenge -- a random number r and can verify that B is at other end using solely public information! |
A Sends x |
Decrypt x with dB and send back challenge |
A Encrypts r using eB to give x |
Send r |
Only B could have sent back r |
Alice is A |
Bob is B |
eB is public key of B |
dB is B's private key |
Digital Signatures reverse the use of public and private keys |
You encrypt with the private and decrypt with the public key |
Plaintext |
Verification |
Plaintext |
Signing |
Private Key |
Public Key |
Here B starts with a document that it is required to prove only could come from B |
This could be a piece of software that we wish to know comes from a reputable source |
We combine software with a "certificate" (a statement that B is Bob) and either encrypt this with dB or more normally encrypt a message digest (or hash that depends on both message and signature) with dB |
This use of a message digest is done for performance as it is time consuming to use public key encryption on full message |
Note this signature cannot be forged either by A or any other person pretending to be B.
|
Given a message m, the hash h(m) must satisfy
|
As hash function is known, the security of a hash comes from the unknown message.
|
These are called one-way transformations as hashes cannot be inverted
|
Message Digests (such as MD2 MD4 MD5 -- MD is Message Digest with 128 bit output -- or SHS -- Secure Hash Standard with 160 bit output output) are used in Public key Systems to reduce computational complexity of encryption (see previous foil) |
Secret Key algorithms are based on elaborating a simple idea |
Caesar rotated alphabet in his cipher. An obvious extension of this is use a 1<-ɭ permutation of a group of N bits |
for DES N=64 and permutation is calculated from a 48 bit key |
To make decoding harder, this is done 16 times with different keys extracted from an original 56 bit secret
|
This strategy is combined with (ad-hoc) transformations to further obfuscate the process |
The full message must be divided into blocks before applying this process and the method of running secret key cryptography on long messages is non trivial (but not very fundamental) as doing in 64 bit separate units would allow information to be freely shuffled! |
RSA stands for inventors: Rivest Shamir and Adleman |
Take a number n = p * q where p and q are primes |
Choose a "suitable" number e |
Public key is <e,n> and basic encryption algorithm takes message m to be encrypted and forms
|
Decryption involves private key d which is found so that
|
Then m = cd mod(n) |
As factorization is computationally infeasible (for n of 512 bits in length or more), this encryption cannot be broken.
|
n,c,d are 512 bits; p,q are 256 bits; e could be small (3 or 65537); m must be less than or equal to bit length of n |
lengths are doubled in recent implementations |
As encoding is time consuming, we only use RSA for small messages anyway. However as in secret key methods, one must in general break longer messages into smaller sizes
|
PKCS (Public Key Encryption Standard) is a standard from RSA for encoding the information to be signed or encrypted through RSA. It incorporates "know-how" to make RSA work reliably. |
Diffie-Hellman, El Gamal and DSS (Digital Signature Standard) are RSA like approaches aimed at digital signatures |
So one can take advantage of both security approaches by using Public Key Infrastructure to initialize a session
|
Thereby they have set up joint knowledge of a secret key without usual disadvantages
|
Note secret key is only used for this session and so one must break in real time |