From owner-freebsd-ports Mon Mar 12 4: 0:11 2001 Delivered-To: freebsd-ports@freebsd.org Received: from blizzard.sabbo.net (ns.sabbo.net [193.193.218.18]) by hub.freebsd.org (Postfix) with ESMTP id 7DFCE37B718 for ; Mon, 12 Mar 2001 04:00:03 -0800 (PST) (envelope-from sobomax@FreeBSD.org) Received: from vic.sabbo.net (root@vic.sabbo.net [193.193.218.112]) by blizzard.sabbo.net (8.10.1/8.10.1) with ESMTP id f2CBxZJ07898; Mon, 12 Mar 2001 13:59:35 +0200 Received: from FreeBSD.org (big_brother.vega.com [192.168.1.1]) by vic.sabbo.net (8.11.2/8.11.2) with ESMTP id f2CBxcG23694; Mon, 12 Mar 2001 13:59:38 +0200 (EET) (envelope-from sobomax@FreeBSD.org) Message-ID: <3AACBA28.FA288681@FreeBSD.org> Date: Mon, 12 Mar 2001 13:59:36 +0200 From: Maxim Sobolev Organization: Vega International Capital X-Mailer: Mozilla 4.76 [en] (WinNT; U) X-Accept-Language: uk,ru,en MIME-Version: 1.0 To: Trevor Johnson Cc: Kris Kennaway , ports@FreeBSD.org, Alistair Crooks Subject: Re: new message digest support in pkgsrc (fwd) References: <20010312052254.X2937-100000@blues.jpj.net> Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 7bit Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Trevor Johnson wrote: > > > A scheme has been described which is computationally expensive but not > > > infeasible. See the references I gave. > > > > I did not mean md5 attack, I meant scheme of attack using trojaned distfile specially tailored in such a way > > that its md5 checksum matches original one. This attack while possible in principle, but have the following > > difficulties, that turn its possibility close to 0: > > > > - attacker should specially tailor trojaned distfile to have the same checksum as original one (md5 attack); > > > > - attacker should put trojaned distfile onto one of the MASTER_SITES; > > This is as difficult as opening an account at sourceforge.net, tripod.com, > nbci.com, or geocities.com, and starting a software project which a > FreeBSD committer will consider worth adding to the ports collection. > Someone capable of breaking MD5 would surely have no difficulty. Please think about it again: in the case when author is in fact attacker he would not have to break md5 to get his code into users' machines. How many FreeBSD port maintainers read every single line of code/configure scripts/makefiles/whatever in the new version of software to detect possible trojans? Stronger checksum will not help in this case, sorry. > > - attacker should ensure somehow that the victim will fetch trojaned distfile from that site; > > It is almost a matter of course that the master site is listed in > MASTER_SITES, so this was taken care of already. See above. > > - attacker should ensure that the victim will build that package. > > Well, the attacker may not have a particular victim in mind. Perhaps his > purposes would be served if he had many victims and many unaffected users. > Then it would be sufficient to let FreeBSD's package-building system > prepare the package for distribution on CD-ROM, or to choose a software > license that would prohibit packages from being distributed (perhaps one > that would prohibit mirroring). Such licenses do not seem to raise > suspicion. > > If he had a particular victim in mind, and for some reason wanted everyone > else to be unaffected, then the malicious code could check for something > particular to that victim's system(s)--its IP address, for example. Some > social engineering might be needed in convincing the victim to install the > package, especially because it would be easiest to create a new software > project rather than subverting an existing one. Depending on the hacker's > goals, the expense of constructing the colliding distfiles might not be > worthwhile for a single victim (except a large institutional one). > Another kind of attack would probably be more suitable, for a single > victim. > > If these things were considered truly difficult, we would be using a > simple CRC check, for example cksum(1), rather than MD5 to check the > integrity of files. That would be adequate to detect non-malicious > changes. See above. In the case when author == attacker checksum algorithm doesn't protect anything, in all other cases MD5 is more than adequiate. -Maxim To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message