linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jesper Juhl" <jesper.juhl@gmail.com>
To: "Miklos Szeredi" <miklos@szeredi.hu>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org,
	linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH 4/7] fuse: add POSIX file locking support
Date: Mon, 19 Jun 2006 11:04:27 +0200	[thread overview]
Message-ID: <9a8748490606190204n6e2ea0caua0015f4edd2fe7ac@mail.gmail.com> (raw)
In-Reply-To: <E1FsFGX-0002Pp-00@dorka.pomaz.szeredi.hu>

On 19/06/06, Miklos Szeredi <miklos@szeredi.hu> wrote:
> > How about; on fuse startup, pick some semirandom number, store it
> > somewhere, then do an XOR of the pointer with the saved value to
> > scramble it, when you need to use it, simply XOR it again with the
> > stored value...  Not especially strong, but better than nothing and
> > better than just adding a constant that people can find out from the
> > source
>
> I think Andrew was suggesting a random key for the ADD function.
>
> > (and the scramble value would be differene each time fuse loads, so
> > at a minimum a different scramble key every boot) - also, XOR is a
> > quite fast operation so overhead should be low.
>
> I think XOR might be even weaker than ADD, because from gessing the
> difference between two values (easy) you might be able to guess the
> bits of the key.
>
> I'm actually looking for something stronger than XOR or ADD, but it's

How about using TEA (Tiny Encryption Algorithm), XTEA or XXTEA then?
They are quite simple algorithms, easy to implement and resonably fast
(with TEA being the simplest, but also weakest).
A hell of a lot better than just a simple XOR or ADD and probably more
than sufficient for this purpose.

  http://en.wikipedia.org/wiki/Tiny_Encryption_Algorithm
  http://www.simonshepherd.supanet.com/tea.htm
  http://www.ftp.cl.cam.ac.uk/ftp/papers/djw-rmn/djw-rmn-tea.html


-- 
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post  http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please      http://www.expita.com/nomime.html

  reply	other threads:[~2006-06-19  9:04 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-12 12:21 [PATCH 0/7] fuse: file locking + misc Miklos Szeredi
2006-06-12 12:25 ` [PATCH 1/7] fuse: use MISC_MAJOR Miklos Szeredi
2006-06-12 12:27 ` [PATCH 2/7] fuse: no backgrounding on interrupt Miklos Szeredi
2006-06-12 12:28 ` [PATCH 3/7] fuse: add control filesystem Miklos Szeredi
2006-06-19  6:55   ` Andrew Morton
2006-06-19  8:06     ` Miklos Szeredi
2006-06-12 12:29 ` [PATCH 4/7] fuse: add POSIX file locking support Miklos Szeredi
2006-06-19  6:58   ` Andrew Morton
2006-06-19  8:12     ` Miklos Szeredi
2006-06-19  8:21   ` Jesper Juhl
2006-06-19  8:37     ` Miklos Szeredi
2006-06-19  9:04       ` Jesper Juhl [this message]
2006-06-19  9:10         ` Miklos Szeredi
2006-06-12 12:30 ` [PATCH 5/7] fuse: ensure FLUSH reaches userspace Miklos Szeredi
2006-06-12 12:31 ` [PATCH 6/7] fuse: rename the interrupted flag Miklos Szeredi
2006-06-12 12:33 ` [PATCH 7/7] fuse: add request interruption Miklos Szeredi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9a8748490606190204n6e2ea0caua0015f4edd2fe7ac@mail.gmail.com \
    --to=jesper.juhl@gmail.com \
    --cc=akpm@osdl.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miklos@szeredi.hu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).