From owner-freebsd-arch@FreeBSD.ORG Fri Dec 10 13:48:09 2004 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6A39B16A4CE; Fri, 10 Dec 2004 13:48:09 +0000 (GMT) Received: from pittgoth.com (14.zlnp1.xdsl.nauticom.net [209.195.149.111]) by mx1.FreeBSD.org (Postfix) with ESMTP id A1C7443D46; Fri, 10 Dec 2004 13:48:08 +0000 (GMT) (envelope-from trhodes@FreeBSD.org) Received: from localhost (64-144-75-100.client.dsl.net [64.144.75.100]) (authenticated bits=0) by pittgoth.com (8.12.10/8.12.10) with ESMTP id iBADm6ag024978 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Fri, 10 Dec 2004 08:48:07 -0500 (EST) (envelope-from trhodes@FreeBSD.org) Date: Fri, 10 Dec 2004 08:48:13 -0500 From: Tom Rhodes To: Mark Murray Message-ID: <20041210084813.3adab69b@localhost> In-Reply-To: <200412101014.iBAAEict086798@grovel.grondar.org> References: <41B96772.4010000@wadham.ox.ac.uk> <200412101014.iBAAEict086798@grovel.grondar.org> X-Mailer: Sylpheed-Claws 0.9.12b (GTK+ 1.2.10; i386-portbld-freebsd5.3) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit cc: Colin Percival cc: freebsd-arch@FreeBSD.org Subject: Re: Adding standalone RSA code X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Dec 2004 13:48:09 -0000 On Fri, 10 Dec 2004 10:14:44 +0000 Mark Murray wrote: > Colin Percival writes: > > Mark Murray wrote: > > > Colin Percival writes: > > >>I was comparing /usr/lib/libcrypto.a (1.7 MB on my system) to the sum > > >>of the sizes of the object files built from my library code (38 kB). > > >> > > >>If you look at the number of lines of C files (counted using `wc -l` > > >>since I don't want to bother installing sloccount), my code is 1489 > > >>lines compared to openssl's 202982 lines. > > > > > > Do you have a version of your code linked against OpenSSL? What is the > > > size difference between a static link of your code vs a static link > > > against OpenSSL? > > > > I don't have a version using openssl, but my key generation program > > (statically linked against my crypto code) is 37kB, while a program > > which calls RSA_generate_key (statically linked against openssl) is > > 240kB. So even under the most favourable conditions (adding overhead > > to my code but not to openssl) it's a size ratio of more than 6. > > Hmm. > > I must profess to having a degree of discomfort with duplicated > functionality. See, right here I can agree. > > 240k is not a big binary, and it sounds like your applet is one that > may get heavy use. Its not built for speed; how much of a problem is > this? If OpenSSL grows hardware BigNum support, your app will not > benefit; how will this affect the user? Is size really a concern? > I can't find a disk smaller than 10 GB at my local dealer. Now with this last one, I think you're being a little difficult, Mark. Not to be rude, of course, if I come off as such I'm sorry. Either way, I think what Colin is proposing is a good idea. -- Tom Rhodes