Boost logo

Boost :

Subject: Re: [boost] NuDB: A fast key/value insert-only database for SSD drives in C++11
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2017-03-27 12:58:41


On 27/03/2017 12:21, Vinnie Falco via Boost wrote:
> On Mon, Mar 27, 2017 at 6:57 AM, Niall Douglas via Boost
> <boost_at_[hidden]> wrote:
>> The point being made here is that you need to use a high quality secure
>> hash when writing data to storage. That way after power loss you can
>> determine if the database store is truly in a consistent and valid state
>> rather than being tricked into thinking it is, and then unwittingly
>> destroying more user data.
>
> Oh...I misunderstood. The hash function in NuDB is not used to
> calculate a digest of the value, its used only to determine which
> bucket to place the key in the hash table. NuDB is essentially an
> on-disk unordered_map. That is why the hash function does not need to
> be cryptographically secure.

This is why I was mentioning that to achieve durability, during writes
you crypto hash AND fast hash the new item. During lookups you use the
fast hash only.

The issue I am taking here is the claim of durability which is a very
strong guarantee. If you don't claim that, I have no issue.

Niall

-- 
ned Productions Limited Consulting
http://www.nedproductions.biz/ http://ie.linkedin.com/in/nialldouglas/

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk