]> Pileus Git - ~andy/fetchmail/blob - archived-messages/000887.html
Refer to FETCHMAIL_SSL_SECLEVEL.
[~andy/fetchmail] / archived-messages / 000887.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <HTML>
3  <HEAD>
4    <TITLE> [fetchmail-devel] Security vulnerability in APOP authentication
5    </TITLE>
6    <LINK REL="Index" HREF="index.html" >
7    <LINK REL="made" HREF="mailto:fetchmail-devel%40lists.berlios.de?Subject=Re%3A%20%5Bfetchmail-devel%5D%20Security%20vulnerability%20in%20APOP%20authentication&In-Reply-To=%3Cqlkbqirheq7.fsf%40clipper.ens.fr%3E">
8    <META NAME="robots" CONTENT="index,nofollow">
9    <style type="text/css">
10        pre {
11            white-space: pre-wrap;       /* css-2.1, curent FF, Opera, Safari */
12            }
13    </style>
14    <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
15    <LINK REL="Previous"  HREF="000884.html">
16    <LINK REL="Next"  HREF="000889.html">
17  </HEAD>
18  <BODY BGCOLOR="#ffffff">
19    <H1>[fetchmail-devel] Security vulnerability in APOP authentication</H1>
20     <B>Ga&#235;tan LEURENT</B> 
21     <A HREF="mailto:fetchmail-devel%40lists.berlios.de?Subject=Re%3A%20%5Bfetchmail-devel%5D%20Security%20vulnerability%20in%20APOP%20authentication&In-Reply-To=%3Cqlkbqirheq7.fsf%40clipper.ens.fr%3E"
22        TITLE="[fetchmail-devel] Security vulnerability in APOP authentication">gaetan.leurent at ens.fr
23        </A><BR>
24     <I>Wed Mar 14 15:55:08 CET 2007</I>
25     <P><UL>
26         <LI>Previous message: <A HREF="000884.html">[fetchmail-devel] Bug#413059: --sslcheck - non-existent option      in the man page
27 </A></li>
28         <LI>Next message: <A HREF="000889.html">[fetchmail-devel] Security vulnerability in APOP authentication
29 </A></li>
30          <LI> <B>Messages sorted by:</B> 
31               <a href="date.html#887">[ date ]</a>
32               <a href="thread.html#887">[ thread ]</a>
33               <a href="subject.html#887">[ subject ]</a>
34               <a href="author.html#887">[ author ]</a>
35          </LI>
36        </UL>
37     <HR>  
38 <!--beginarticle-->
39 <PRE>Hello,
40
41 I found a security vulnerability in the APOP authentication.  It is
42 related to recent collision attacks by Wang and al. against MD5.  The
43 basic idea is to craft a pair of message-ids that will collide in the
44 APOP hash if the password begins in a specified way.  So the attacker
45 would impersonate a POP server, and send these msg-id; the client will
46 return the hash, and the attacker can learn some password characters.
47
48 The msg-ids will be generated from a MD5 collision: if you have two
49 colliding messages for MD5 &quot;&lt;????@????&gt;x&quot; and &quot;&lt;&#191;&#191;&#191;&#191;@&#191;&#191;&#191;&#191;&gt;x&quot;, and the
50 message are of length two blocks, then you will use &quot;&lt;????@????&gt;&quot; and
51 &quot;&lt;&#191;&#191;&#191;&#191;@&#191;&#191;&#191;&#191;&gt;&quot; as msg-ids.  When the client computes MD5(msg-id||passwd)
52 with these two, it will collide if the first password character if 'x',
53 no matter what is next (since we are at a block boundary, and the end of
54 the password will be the same in the two hashs).  Therefore you can
55 learn the password characters one by one (actually you can only recover
56 three of them, due to the way MD5 collisions are computed).
57
58 This attack is really a practical one: it needs about an hour of
59 computation and a few hundred authentications from the client, and can
60 recover three password characters.  I tested it against fetchmail, and
61 it does work.
62
63 However, using the current techniques available to attack MD5, the
64 msg-ids sent by the server can easily be distinguished from genuine ones
65 as they will not respect the RFC specification.  In particular, they
66 will contain non-ASCII characters.  Therefore, as a security
67 countermeasure, I think fetchmail should reject msg-ids that does not
68 conform to the RFC.
69
70 The details of the attack and the new results against MD5 needed to
71 build it will be presented in the Fast Software Encryption conference on
72 March 28.  I can send you some more details if needed.
73
74 Meanwhile, feel free to alert any one that you believe is concerned.
75 I am already sending this mail to the maintainers of Thunderbird,
76 Evolution, fetchmail, and mutt.  KMail already seems to do enough checks
77 on the msg-id to avoid the attack.
78
79 Please CC me in any reply.
80
81 -- 
82 Ga&#235;tan LEURENT
83
84 </PRE>
85
86 <!--endarticle-->
87     <HR>
88     <P><UL>
89         <!--threads-->
90         <LI>Previous message: <A HREF="000884.html">[fetchmail-devel] Bug#413059: --sslcheck - non-existent option      in the man page
91 </A></li>
92         <LI>Next message: <A HREF="000889.html">[fetchmail-devel] Security vulnerability in APOP authentication
93 </A></li>
94          <LI> <B>Messages sorted by:</B> 
95               <a href="date.html#887">[ date ]</a>
96               <a href="thread.html#887">[ thread ]</a>
97               <a href="subject.html#887">[ subject ]</a>
98               <a href="author.html#887">[ author ]</a>
99          </LI>
100        </UL>
101
102 <hr>
103 <a href="https://lists.berlios.de/mailman/listinfo/fetchmail-devel">More information about the fetchmail-devel
104 mailing list</a><br>
105 </body></html>