From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mo-p00-ob.rzone.de (mo-p00-ob.rzone.de [81.169.146.162]) by krisdoz.my.domain (8.14.5/8.14.5) with ESMTP id q58CPAWX019955 for ; Fri, 8 Jun 2012 08:25:11 -0400 (EDT) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/afgnrylriWFBK0cGH4A= X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de (ip-109-42-145-86.web.vodafone.de [109.42.145.86]) by smtp.strato.de (josoe mo56) (RZmta 29.10 DYNA|AUTH) with (AES128-SHA encrypted) ESMTPA id 5028aco58BF15p for ; Fri, 8 Jun 2012 14:25:08 +0200 (CEST) Received: by britannica.bec.de (sSMTP sendmail emulation); Fri, 08 Jun 2012 14:25:05 +0200 Date: Fri, 8 Jun 2012 14:25:05 +0200 From: Joerg Sonnenberger To: tech@mdocml.bsd.lv Subject: Re: mandocdb tools, sqlite3, and ohash Message-ID: <20120608122505.GA18779@britannica.bec.de> Mail-Followup-To: tech@mdocml.bsd.lv References: <4FD0C58C.5040104@bsd.lv> <20120607180605.GA295@iris.usta.de> <4FD1D406.9020704@bsd.lv> X-Mailinglist: mdocml-tech Reply-To: tech@mdocml.bsd.lv MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4FD1D406.9020704@bsd.lv> User-Agent: Mutt/1.5.21 (2010-09-15) On Fri, Jun 08, 2012 at 12:29:26PM +0200, Kristaps Dzonsons wrote: > > 4. Function dbopen with real=0: > > There seems to be a race, open to symlink attacks, > > between remove(file) and sqlite3_open(file); > > some kind of O_EXCL or something might be required. > > Fixed---good point. Pity there's no O_TRUNC for sqlite3. SQLITE_OPEN_EXCLUSIVE. Joerg -- To unsubscribe send an email to tech+unsubscribe@mdocml.bsd.lv