5 Cryptography Part2
5 Cryptography Part2
Review:
Cryptography Domain –
Part 2
Version: 5.9
CISSP Common Body of Knowledge Review by Alfred Ouyang is licensed under the Creative Commons
Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a copy of this license, visit
http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 444 Castro Street, Suite
900, Mountain View, California, 94041, USA.
Learning Objective
Cryptography Domain
The Cryptography domain addresses the principles, means, and
methods of applying mathematical algorithms and data
transformations to information to ensure its integrity, confidentiality,
and authentication.
The candidate is expected to know basic concepts within
cryptography; public and private key algorithms in terms of their
applications and uses; algorithm construction, key distribution and
management, and methods of attack; the applications, construction
and use of digital signatures to provide authenticity of electronic
transactions, and non-repudiation of the parties involved; and the
organization and management of the Public Key Infrastructure
(PKIs) and digital certification and management.
-2-
Review of Part 1
• Classic ciphers:
– Substitution cipher
– Transposition cipher
– Polyalphabetic (or running key) cipher
– Concealment
• Modern ciphers:
– Block cipher
– Stream cipher
– Steganography
– Combination
-3-
Review of Part 1
• Hash Function Cryptography
– Non-keyed Digest (for integrity)
– Keyed Digest (for authentication)
– Digital Signature (for non-repudiation)
• Symmetric Cryptography
– Block Ciphers
• Confusion & Diffusion
– Confusion: S-box
– Diffusion: Feistel network & Columnar transposition
– Stream Ciphers
• XOR operation
– Modes of operation
• Block mode: ECB and CBC
• Stream mode: CFB, OFB, CTR
-4-
Review of Part 1
• Asymmetric Cryptography
– Diffie-Hellman Algorithm
– Factorization Algorithm
– Discrete Logarithm Algorithm
• Hybrid Cryptography
– Make use of asymmetric cryptography to keep the
ephemeral secret key secret.
– Make use of hash functions to ensure integrity and non-
repudiation of the ephemeral secret key.
– Use the transported ephemeral secret key to perform bulk/
link encryption using symmetric cryptography.
-5-
Discussion on Part 2
• Utilization of Cryptography
– Public Key Infrastructure (PKI)
– HTTP, S-HTTP, IPsec, SSH, SET
– Single Sign-On (SSO)
– Secured E-mail
• Types of Crypto Attacks
– Cryptoanalytic Attacks
– Cryptographic Attacks
• Discussion on export of crypto technologies
-6-
Topics
-7-
Utilization of Cryptography
Certification Certification
Subordinate CA
path path
Sub CA1.1 Sub CA1.2 Sub CA2.1
CA certificate path
Certification
EE End entity (subject)
path
EE EE EE EE
-8-
Utilization of Cryptography
-9-
Utilization of Cryptography
- 10 -
Utilization of Cryptography:
C=US Employee HR
C=US Country system
O=US Government Organization
O=US Government
OU=Department of the Interior Organizational Unit
Secure E-mail
CN=Alice CN=Alice CN=Alice (S/MIME)
Cryptographer Cryptographer Cryptographer
- 11 -
Utilization of Cryptography
FWS
(A Subordinate CA)
NPS
PIV Card Reader (A Subordinate CA)
OSM
` (A Subordinate CA)
DOI User
User Workstation
Local CA
BOR
AD/DC (A Subordinate CA)
NBC
(A Subordinate CA)
Fingerprint Scanner
- 12 -
Utilization of Cryptography
• Algorithm ID
Signature Algorithm: md5WithRSAEncryption
Issuer: C=ZA, ST=Western Cape, L=Cape Town, O=Thawte
Consulting cc,
• Issuer
OU=Certification Services Division,
CN=Thawte Server CA/[email protected]
Validity
• Validity
Not Before: Aug 1 00:00:00 1996 GMT
Not After : Dec 31 23:59:59 2020 GMT
Subject: C=ZA, ST=Western Cape, L=Cape Town, O=Thawte
– Not Before
Consulting cc,
OU=Certification Services Division,
CN=Thawte Server CA/[email protected]
•
Exponent: 65537 (0x10001)
Issuer Unique Identifier (Optional) X509v3 extensions:
X509v3 Basic Constraints: critical
•
CA:TRUE
Subject Unique Identifier (Optional) Signature Algorithm: md5WithRSAEncryption
07:fa:4c:69:5c:fb:95:cc:46:ee:85:83:4d:21:30:8e:ca:d9:
- 13 -
Utilization of Cryptography
Crypto-period
Key Type
Originator Usage Period Recipient Usage Period
1. Private Signature Key 1-3 years
2. Public Signature Key Several years (depends on key size)
3. Symmetric Authentication Key ≤ 2 years ≤ OUP + 3 years
4. Private Authentication Key 1-2 years
5. Public Authentication Key 1-2 years
6. Symmetric Data Encryption Keys ≤ 2 years ≤ OUP + 3 years
7. Symmetric Key Wrapping Key ≤ 2 years ≤ OUP + 3 years
8. Symmetric and asymmetric RNG Keys Upon reseeding
9. Symmetric Master Key About 1 year
10. Private Key Transport Key ≤ 2 years
- 18 -
Questions:
• What are the four key functional services for PKI?
–
–
–
–
- 19 -
Answers:
• What are the four key functional services for PKI?
– Directory Service,
– Certificate Management Service,
– Key Management Service, and
– Cryptography Service.
- 20 -
Questions:
• What are the six functions performed by PKI key
management service?
–
–
–
–
–
–
- 21 -
Answers:
• What are the six functions performed by PKI key
management service?
– Key establishment
– Key exchange
– Key backup & recovery
– Key revocation
– Key destruction
– Key escrow
- 22 -
Topics
- 23 -
Utilization of Cryptography
- 24 -
Utilization of Cryptography
Secure Pipe
Message (SSL/TLS) Message
- 25 -
Utilization of Cryptography
finished
3DES or AES.
change cipher specification
– One-way hash functions: MD5 or SHA. finished
Application Data...
- 26 -
Utilization of Cryptography
SSLv3/TLSv1 SSLv3/TLSv1
IPsec…
Remote Client DOI ESN Networks
- 27 -
Utilization of Cryptography
certificate
certificate verification
negotiated between client/server at change cipher specification
finished
- 28 -
Utilization of Cryptography
IPsec Key
Exchange (IKE)
ISAKMP ISAKMP
Application
Layer
Security
Security
Association (SA)
Security Transport
IPSP IPSP
Association Association Layer
Database Database
AH protection
ESP protection
Bits
0 4 8 12 16 20 24 28 31
1 Next Header Payload Length Reserved
3 Sequence Number
0 4 8 12 16 20 24 28 31
1 Security Parameters Index (SPI)
2 Sequence Number
Words
Reference: http://en.wikipedia.org/wiki/IPsec
- 32 -
Utilization of Cryptography
Reference:
• http://en.wikipedia.org/wiki/IPsec
• http://en.wikipedia.org/wiki/L2TP
• http://www.cisco.com/en/US/tech/tk583/tk372/tech_configuration_examples_list.html
• http://www.cisco.com/univercd/cc/td/doc/product/software/ios120/12cgcr/secur_c/scprt4/scipsec.htm
• RFC 4301, Security Architecture for the Internet Protocol (http://tools.ietf.org/html/rfc4301)
- 33 -
Utilization of Cryptography
Target
Application
components:
– Transport Layer Protocol [SSH-TRANS] provides server
authentication, confidentiality, and integrity.
– User Authentication Protocol [SSH-USERAUTH]
authenticates the client-side user to the server.
– Connection Protocol [SSH-CONNECT] multiplexes the
encrypted tunnel into several logical channels.
- 34 -
Utilization of Cryptography
• SSH protects:
– Eavesdropping of data transmitted over the network.
– Manipulation of data at intermediate elements in the network
(e.g. routers).
– IP address spoofing where an attack hosts pretends to be a
trusted host by sending packets with the source address of
the trusted host.
– DNS spoofing of trusted host names/IP addresses.
– IP source routing.
- 35 -
Utilization of Cryptography
- 36 -
Questions:
• What is the difference between HTTPS and S-HTTP?
– HTTPS is
– S-HTTP is
- 37 -
Answers:
• What is the difference between HTTPS and S-HTTP?
– HTTPS is a uniform resource identifier (URI) scheme that
refers the use of HTTP over an encrypted SSL/TLS session.
– S-HTTP is a message-oriented protocol that provides
encryption through a secure port using SSL/TLS.
- 38 -
Topics
- 39 -
Cryptography for Single Sign-On (SSO) – Using PKI
Security Assertion is the Users Directory Service Principle CA SOA Components
relationships.
Security Assertion
IT infrastructure.
validate identity & credential
- 40 -
Topics
- 41 -
Utilization of Cryptography
- 42 -
Utilization of Cryptography
Encrypting/Signing...
Alice Bob
CRL
Abcdefalsdasdfasdf
asdfasdfAsdfasdfas
dfasdfasdfasdfasdfa
Abcdefalsdasdfasdf
asdfasdfAsdfasdfas
dfasdfasdfasdfasdfa
Entrust Profile
sdfpolaskjflieaseifjas
sdfpolaskjflieaseifjas
leifjalsiejf;
leifjalsiejf;lasiejfflasij
efj;lialakjsdf asd
;laksdjfladksjflaksjdfl
kasjdlfjsald;jf;lakjasl
kdjjfasdfasdfasdlkj
aslkdjf;laskjdflasjdlfj
ks;ldkjfsalkjlkj;lkjasf
• Alice’s
The
Alice
Hash
This
A CRL
validity
Retrieves
verification
ofisthe
one-time
one-time
package
opens
composesretrieved
ofsymmetric
message
Bob’s
Bob’s
symmetric
her
is public
sent Certificate
to
privateEncryption
is
a message
to check
encryption
key
created
forisBob’s
encryption
Bob
key store is
included
Bob Public
and
verified
keykey
revocation
isis
is Key
signed
to
using
itself
allow
Certificate
generated encrypted
using
status
the
Bob
CA
andAlice’s
to
from
Public
verify
with
used the
tosigning
Key
her
Bob’s
Directory
signature
private
encrypt the
encryption
Certificate
message
key and
public
signed
keyhash
Source: ISSA-NOVA CISSP Study Group
- 44 -
Utilization of Cryptography
Alice Bob
Abcdefalsdasdfasdf
Abcdefalsdasdfasdf
asdfasdfAsdfasdfas
asdfasdfAsdfasdfas
dfasdfasdfasdfasdfa
dfasdfasdfasdfasdfa
sdfpolaskjflieaseifjas
sdfpolaskjflieaseifjas
leifjalsiejf;
leifjalsiejf;lasiejfflasij
efj;lialakjsdf asd
;laksdjfladksjflaksjdfl
kasjdlfjsald;jf;lakjasl
CRL kdjjfasdfasdfasdlkj
aslkdjf;laskjdflasjdlfj
ks;ldkjfsalkjlkj;lkjasf
• retrieves
confirms
Bob logs
usesinto
the the
his CRLsignature
Alice’s and
Private
his one-time
encryption confirms
Key on
Store
private
symmetric key Alice’s
the
toto
key revocation
message
retrieve hash
the
retrieve status
and compares
one-time
the message it tokey
symmetric
text and a
hash ofhash
signed the message created locally
EE5 EE2
EE2 EE3 EE4 EE1 EE1
Certification
paths
CA certificate path
EE4 EE3
EE1 EE2 EE3 EE1 EE2
- 46 -
Utilization of Cryptography
of)… Validity
CN=Thawte Server CA/[email protected]
–
Not After : Dec 31 23:59:59 2020 GMT
PGP version number Subject: C=ZA, ST=Western Cape, L=Cape Town, O=Thawte
Consulting cc,
OU=Certification Services Division,
– Validity 68:75:47:a2:aa:c2:da:84:25:fc:a8:f4:47:51:da:
85:b5:20:74:94:86:1e:0f:75:c9:e9:08:61:f5:06:
6d:30:6e:15:19:02:e9:52:c0:62:db:4d:99:9e:e2:
- 48 -
Answers:
• What are the three secure e-mail standards?
– Privacy Enhanced Mail (PEM)
– Secure/Multipurpose Internet Mail Extension (S/MIME)
– Pretty Good Privacy (PGP)
- 49 -
Topics
- 50 -
Crypto Attacks
• Types of cryptanalytic attacks:
– Ciphertext-only attack
– Known-plaintext attack
– Chosen-plaintext attack
– Chosen-ciphertext attack
– Adaptive-chosen-plaintext attack
– Adaptive-chosen-ciphertext attack
• Types of cryptographic attacks
– Brute-force attack
– Symmetric block cipher attacks
– Stream cipher attacks
– Hash function attack
– Message authentication code (MAC) attack
– Birthday attack
– Man-in-the-middle attack
Reference: http://en.wikipedia.org/wiki/Category:Cryptographic_attacks
- 51 -
Crypto Attacks
• Known-plaintext attack
– Attacker has: ciphertext and plaintext messages
– Goal: discover the key.
Reference: http://en.wikipedia.org/wiki/Known-plaintext_attack
• Chosen-ciphertext attack
– Attacker selects: a series of same ciphertext messages
– Goal: discover the key
Reference: http://en.wikipedia.org/wiki/Chosen-ciphertext_attack
• Chosen-plaintext attack
– Attacker selects: a series of ciphertext and corresponding
plaintext messages
– Goal: discover the key.
Reference: http://en.wikipedia.org/wiki/Chosen-plaintext_attack
- 52 -
Crypto Attacks
• Adaptive-chosen-plaintext attack
– Attacker choose: plaintext samples dynamically, and alter his
or her choice based on the results of the previous
operations.
– Goal: discover key.
Reference: http://en.wikipedia.org/wiki/Adaptive_chosen-plaintext_attack
- 53 -
Crypto Attacks
- 54 -
Crypto Attacks
- 55 -
Crypto Attacks
Reference: http://en.wikipedia.org/wiki/Stream_cipher_attack
- 56 -
Crypto Attacks
Reference: How to Break MD5 and Other Hash Functions, Xiaoyun Wang and Hongbo
Yu, Shandong University, 2005
- 57 -
Crypto Attacks
Reference: http://en.wikipedia.org/wiki/Birthday_attack
- 58 -
Questions:
• Name the type of crypto-analytic attack where the
attacker uses ciphertext and plaintext messages to
discover the key?
–
- 59 -
Answers:
• Name the type of crypto-analytic attack where the
attacker uses ciphertext and plaintext messages to
discover the key?
– Known-plaintext attack
- 60 -
Questions:
• Brute-force attack is what type of attack?
–
- 61 -
Answers:
• Brute-force attack is what type of attack?
– Cryptographic attack.
- 62 -
Topics
- 63 -
Export Issues
• Coordinating Committee for Multilateral Export Controls
(COCOM)
– 17 member nations, dissolved in March 1994.
– Maintained International Industrial List & International Munitions
List. To prevent export of cryptography to “dangerous”
countries.
• Wassenaar Arrangement on Export Controls for
Conventional Arms and Dual-Use Goods and
Technologies (1995)
– December 1998, 33 nations has agree to restrict export of
crypto products based on key length. (56-bit for symmetric, 512-
bit for asymmetric)
– Products that use encryption to protect intellectual property (e.g.
DVDs) is relaxed.
– Export of all other crypto require license.
Reference: Official (ISC)2® Guide to the CISSP® Exam
- 64 -
Export Issues
• U.S. Export Administration Regulations (EAR)
– Administered by Bureau of Industry and Security,
Department of Commerce (DOC).
(http://www.access.gpo.gov/bis/ear/ear_data.html).
– EAR, Part 774, Category 5 (Part 2) – Information Security:
Mass market & retail cryptography can be exported without a
license.
• Parity bits are not included in the key length
• Key length of 56-bit for symmetric (DES)
• Key length of 512-bit for asymmetric (RSA, Diffie-Hellman)
• Key length of 112-bit for ECC-DH