[213] in The Cryptographic File System users list
Re: "out of band" cdetach?
daemon@ATHENA.MIT.EDU (Valdis.Kletnieks@vt.edu)
Tue Oct 17 14:31:58 2000
From owner-cfs-users@crypto.com Tue Oct 17 18:31:58 2000
Return-Path: <owner-cfs-users@crypto.com>
Delivered-To: cfs-mtg@CHARON.MIT.EDU
Received: (qmail 9090 invoked from network); 17 Oct 2000 18:31:58 -0000
Received: from mx.crypto.com (207.140.168.138)
by charon.mit.edu with SMTP; 17 Oct 2000 18:31:58 -0000
Received: (from majordomo@localhost)
by MultiHostMXServer (8.9.3/8.9.x4) id OAA32027
for cfs-users-list; Tue, 17 Oct 2000 14:28:27 -0400 (EDT)
X-Authentication-Warning: mx.crypto.com: majordomo set sender to owner-cfs-users@crypto.com using -f
Received: from nsa.research.att.com (H-135-207-24-155.research.att.com [135.207.24.155])
by MultiHostMXServer (8.9.3/8.9.x4) with ESMTP id OAA07669
for <cfs-users@crypto.com>; Tue, 17 Oct 2000 14:28:25 -0400 (EDT)
Received: from mail-green.research.att.com (mail-green.research.att.com [135.207.30.103]) by nsa.research.att.com (8.7.3/8.7.3) with ESMTP id OAA10195 for <cfs-users@nsa.research.att.com>; Tue, 17 Oct 2000 14:28:23 -0400 (EDT)
Received: by mail-green.research.att.com (Postfix)
id 73F851E0A6; Tue, 17 Oct 2000 14:28:24 -0400 (EDT)
Delivered-To: cfs-users@research.att.com
Received: from black-ice.cc.vt.edu (black-ice.cc.vt.edu [128.173.14.71])
by mail-green.research.att.com (Postfix) with ESMTP
id 3D1C61E095; Tue, 17 Oct 2000 14:28:24 -0400 (EDT)
Received: from black-ice.cc.vt.edu (valdis@localhost [127.0.0.1])
by black-ice.cc.vt.edu (8.12.0.PreAlpha2/8.12.0.PreAlpha2) with ESMTP id e9HISNn25380;
Tue, 17 Oct 2000 14:28:23 -0400
Message-Id: <200010171828.e9HISNn25380@black-ice.cc.vt.edu>
X-Mailer: exmh version 2.2 06/23/2000 with nmh-1.0.4+dev
To: Steve Bellovin <smb@research.att.com>
Cc: cfs-users@research.att.com
Subject: Re: "out of band" cdetach?
In-Reply-To: Your message of "Tue, 17 Oct 2000 13:39:25 EDT."
<20001017173925.7838735DC2@smb.research.att.com>
From: Valdis.Kletnieks@vt.edu
X-Url: http://black-ice.cc.vt.edu/~valdis/
X-Face: 34C9$Ewd2zeX+\!i1BA\j{ex+$/V'JBG#;3_noWWYPa"|,I#`R"{n@w>#:{)FXyiAS7(8t(
^*w5O*!8O9YTe[r{e%7(yVRb|qxsRYw`7J!`AM}m_SHaj}f8eb@d^L>BrX7iO[<!v4-0bVIpaxF#-)
%9#a9h6JXI|T|8o6t\V?kGl]Q!1V]GtNliUtz:3},0"hkPeBuu%E,j(:\iOX-P,t7lRR#
References: <20001017173925.7838735DC2@smb.research.att.com>
Mime-Version: 1.0
Content-Type: multipart/signed; boundary="==_Exmh_-1216023064P";
micalg=pgp-sha1; protocol="application/pgp-signature"
Content-Transfer-Encoding: 7bit
Date: Tue, 17 Oct 2000 14:28:23 -0400
Sender: owner-cfs-users@crypto.com
Precedence: bulk
--==_Exmh_-1216023064P
Content-Type: text/plain; charset=us-ascii
On Tue, 17 Oct 2000 13:39:25 EDT, Steve Bellovin <smb@research.att.com> said:
> Is there any way for a daemon process to cdetach all currently-attached
> directories? I'd like to do something like that in an apm suspend
> script.
Well, the source for cdetach.c is really simple. The two problems I see are:
1) You have to play UID games if there's multiple UID's with outstanding
cattach's. Since the cdetach.c code just does 'ap.uid = getuid();', it
doesn't look TOO hard to just iterate and fake them up as needed.
(Note for CFS V2 - this is a DOS attack waiting to happen ;)
2) You'd have to do a readdir() of /crypt (or whatever mount point you use)
to get the names of the directories to mass-detach. This would however
Lose Big Time if you use the 'leading-dot name mangling' feature. Also,
I'm not sure what scheme you'd use to get the name of the mount point
into the program.
--
Valdis Kletnieks
Operating Systems Analyst
Virginia Tech
--==_Exmh_-1216023064P
Content-Type: application/pgp-signature
-----BEGIN PGP SIGNATURE-----
Version: PGP 6.5.8
Comment: Exmh version 2.2 06/16/2000
iQA/AwUBOeyaR3At5Vm009ewEQITbACeLJR8WxcY2gnRjv5gOAk3R4q2epcAoPr4
SX5+Jt7o7aTfSX9IOejOe5f1
=rFlK
-----END PGP SIGNATURE-----
--==_Exmh_-1216023064P--