Upload
peter-freeman
View
225
Download
0
Tags:
Embed Size (px)
Citation preview
Chapter 15Chapter 15Electronic Mail Security – Part II
Data & Network Security
Spring 2006
Dr. Jalili
2
AgendaAgenda
In the previous session, we’ve studied PGP. In this session, other email security standards will be studied.
PEM S/MIME
RFC 822 MIME
3
Phil’s feelingsPhil’s feelings
…a week before PGP's first release, I discovered the existence of another email encryption standard called Privacy Enhanced Mail (PEM), which was backed by several big companies, as well as RSA Data Security.
I didn't like PEM's design, for several reasons…
4
Why not PEM?!Why not PEM?!
1. PEM used 56-bit DES to encrypt messages, which I did not regard as strong cryptography.
2. PEM absolutely required every message to be signed, and revealed the signature outside the encryption envelope, so that the message did not have to be decrypted to reveal who signed it.
Not an issue today
5
PEM StandardPEM Standard
PEM is described in RFCs 1421-1424: Privacy Enhancement for Internet Electronic Mail (1993):
1. Part I: Message Encryption and Authentication Procedures;
2. Part II: Certificate-Based Key Management;
3. Part III: Algorithms, Modes, and Identifiers;
4. Part IV: Key Certification and Related Services.
6
Summary of Transformations Summary of Transformations
The incoming/outgoing message undergoes (a subset of) the four-phase transformation:
Message in the system's
native character set
RFC 822 compatible
Authentication &
Encryption
Printable Encoding
7
PEM EncapsulationPEM Encapsulation
Adopted from RFC 934 encapsulation mechanism.
Uses Encapsulation Boundaries (EBs):
-----BEGIN PRIVACY-ENHANCED MESSAGE-----
-----END PRIVACY-ENHANCED MESSAGE-----
8
Encapsulation FormatEncapsulation Format
Encapsulated Message
-----BEGIN PRIVACY-ENHANCED MESSAGE-----
Encapsulated Header Portion
Blank Line
Encapsulated Text Portion
-----END PRIVACY-ENHANCED MESSAGE-----
Pre-Encapsulation
Boundary (Pre-EB)
Post-Encapsulation
Boundary (Post-EB)
Separates Header &
Body
Result of four-phase
transformation
Contains encryption
control fields
9
Example Encapsulated Message Example Encapsulated Message (Symmetric Case)(Symmetric Case)
Pre-EBHeader
Body
Post-EB
10
Proc-Type FieldProc-Type Field
Identifies the type of processing performed on the transmitted message: ENCRYPTED; MIC-ONLY; MIC-CLEAR; CRL; Content-Domain Field; DEK-Info Field;
MIC:Message Integrity
Check
DEK:Data Encrypting
Keys
11
PEM AlgorithmsPEM Algorithms
12
PEM, TodayPEM, Today
Today, PEM is not used as a mail security/privacy tool anymore.
But, as stated in RFC 2315 (PKCS #7: Cryptographic Message Syntax v1.5), PEM & PKCS #7 are totally compatible. PKCS#7 messages can be converted into PEM messages without any cryptographic operations.
13
S/MIMES/MIME
Before studying S/MIME, one must first understand what RFC 822 & MIME are.
RFC 822 defines a format for text messages that are sent using electronic mail.
Consists of envelope & contents. The content includes a set of header
fields that may be used by the mail system to create the envelope.
14
RFC 822 Message FormatRFC 822 Message Format
Date: Tue, 9 May 2006 10:37:17 (EST)
From: “Mahmood Ahmadinejad” <[email protected]>
Subject: no subject
Cc:
Mr. George Bush, president of the United States of America
For some time now, I have been thinking, how one can justify the undeniable contradictions that exist in the international arena -- which are being constantly debated, especially in political forums and amongst university students. Many questions remain unanswered. Those have prompted me to discuss some of the contradictions and questions, in the hopes that it might bring about an opportunity to redress them…
Blank Line
15
RFC 822 SMTP limitationsRFC 822 SMTP limitations
1. Binary object transfer;2. Non-ASCII-7 encoding;3. Message size limitations;4. ASCII-to-EBCDIC translation;5. SMTP gateways to X.400 email
networks can’t handle non-textual X.400 messages;
6. Some SMTP implementations inconsistent with RFC 821 SMTP.
1. Handling CRLF;2. 76-Character lines;3. Trailing white spaces;4. Padding of lines;5. Handling Tab
characters.
16
MIMEMIME
RFCs 2821-2822 obsolete RFCs 821-822.
MIME =Multipurpose Internet Mail Extensions.
An extension to the RFC 822 framework.
Intended to address some of the problems and limitations of the use of SMTP.
17
MIME RFCsMIME RFCs
MIME is discussed in RFCs 2045-2049: 2045: Format of Internet Message Bodies; 2046: Media Types; 2047: Message Header Extensions for Non-
ASCII Text; 2048: Registration Procedures; 2049: Conformance Criteria and Examples;
18
MIME SpecificationMIME Specification
1. Five new message header fields are defined, which may be included in an RFC 822 header.
2. A number of content formats for multimedia electronic mail are defined.
3. Transfer encodings are defined that enable the conversion of any content format into a form that is protected from alteration by the mail system.
19
New Message HeadersNew Message Headers
1. MIME-Version;
2. Content-Type;
3. Content-Transfer-Encoding;
4. Content-ID;
5. Content-Description.
Always 1.0RFCs 2045-2046e.g.
video/quicktime
e.g.binaryUsed to identify MIME
entities uniquely in multiple contexts.Like <alt>
tags
20
MIME Content Types (RFC 2046)MIME Content Types (RFC 2046)
21
Sample MIME MessageSample MIME Message
From: “Mahmood Ahmadinejad” <[email protected]>
To: “George W. Bush” <[email protected]>
Subject: no subject
MIME-Version: 1.0
Content-type: multipart/mixed; boundary=“Mr. President”
Preamble
--Mr. PresidentYou might know that I am a teacher. My students ask me how can these actions be reconciled with the values…
--Mr. President
Content-type: text/plain; charset=us-asciiI am sure you know how -- and at what cost -- Israel was established…
--Mr. President--
Epilogue
Blank Line
22
MIME Transfer EncodingsMIME Transfer Encodings
23
Canonical FormCanonical Form
An important concept in MIME and S/MIME.
Canonical form is a format, appropriate to the content type, that is standardized for use between systems.
May involve character set and EOL conversion, transformation of audio data, compression, etc.
24
S/MIMES/MIME
Secure MIME (RFCs 2632-2634). Provides four functions:
1. Enveloped data;
2. Signed data;
3. Clear-Signed data;
4. Signed & Enveloped data.
Both message & signature are
encoded using Base64.
Only signature is encoded
using Base64.
25
S/MIME AlgorithmsS/MIME Algorithms
DSS: preferred for digital signature. DH (ElGamal): preferred for session key
encryption. RSA: signing and/or encryption. 3DES/RC2 (40 bits): message encryption. SHA-1/MD5: digest.
There are some RULES for algorithm selection (MUST/SHOULD).
RFC 2119
26
S/MIME Content Types
27
S/MIME Certificate ProcessingS/MIME Certificate Processing
S/MIME uses public-key certificates that conform to X.509v3.
The key-management scheme used by S/MIME is in some ways a hybrid between a strict X.509 certification hierarchy and PGP's web of trust.
PGP is suitable for personal use, while S/MIME is appropriate for commercial use.