[935] in arla-drinkers
Re: User level permissions
daemon@ATHENA.MIT.EDU (Dr A V Le Blanc)
Tue Jun 29 08:43:44 1999
From owner-arla-drinkers@stacken.kth.se Tue Jun 29 12:43:43 1999
Return-Path: <owner-arla-drinkers@stacken.kth.se>
Delivered-To: arla-drinkers-mtg@bloom-picayune.mit.edu
Received: (qmail 25243 invoked from network); 29 Jun 1999 12:43:41 -0000
Received: from unknown (HELO sundance.stacken.kth.se) (130.237.234.41)
by bloom-picayune.mit.edu with SMTP; 29 Jun 1999 12:43:41 -0000
Received: (from majordom@localhost)
by sundance.stacken.kth.se (8.8.8/8.8.8) id OAA16562
for arla-drinkers-list; Tue, 29 Jun 1999 14:35:15 +0200 (MET DST)
Received: from serenity.mcc.ac.uk (serenity.mcc.ac.uk [130.88.200.93])
by sundance.stacken.kth.se (8.8.8/8.8.8) with ESMTP id OAA16554
for <arla-drinkers@stacken.kth.se>; Tue, 29 Jun 1999 14:35:10 +0200 (MET DST)
Received: from meissen.mcc.ac.uk ([130.88.203.42])
by serenity.mcc.ac.uk with esmtp (Exim 1.92 #3)
for arla-drinkers@stacken.kth.se
id 10yx6S-000KPy-00; Tue, 29 Jun 1999 13:35:08 +0100
Received: (from zlsiial@localhost)
by meissen.mcc.ac.uk (8.7.6/8.8.4)
id NAA01371 for arla-drinkers@stacken.kth.se; Tue, 29 Jun 1999 13:35:07 +0100 (BST)
Message-ID: <19990629133507.A1363@afs.mcc.ac.uk>
Date: Tue, 29 Jun 1999 13:35:07 +0100
From: Dr A V Le Blanc <LeBlanc@mcc.ac.uk>
To: arla-drinkers@stacken.kth.se
Subject: Re: User level permissions
Reply-To: Dr A V Le Blanc <LeBlanc@mcc.ac.uk>
References: <xofzp1k5ovi.fsf@blubb.pdc.kth.se> <Pine.LNX.4.10.9906281258390.30322-100000@shaft.engin.umich.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 0.93.1i
In-Reply-To: <Pine.LNX.4.10.9906281258390.30322-100000@shaft.engin.umich.edu>; from Chris Wing on Mon, Jun 28, 1999 at 01:14:14PM -0400
Sender: owner-arla-drinkers@stacken.kth.se
Precedence: bulk
On Mon, Jun 28, 1999 at 01:14:14PM -0400, Chris Wing wrote:
> I agree that emulating every minor detail is a waste of time. However,
> regarding the output of 'tokens', printing out the correct AFS ID is a
> useful feature in my opinion, and I think it should be implemented in
> Arla/KTH-KRB.
What I do in some of my programs (linked with Transarc libraries) is
this:
rc(pr_Initialize(0, AFSCONF_CLIENTNAME, client.cell),
"Unable to contact ptserver");
rc(pr_SNameToId(who, &id), "Can't get AFS id");
pr_End();
rc(id == ANONYMOUSID, "Got bad AFS id");
sprintf(client.name, "AFS ID %ld", id);
PR_NameToId() is already a function in the arla libptserver. As I
understand it, arla's equivalent of pr_Initialize is something like
connptdb = arlalib_getconnbyname(cell, host,
afsprport,
PR_SERVICE_ID,
arlalib_getauthflag (noauth, 0, 0, 0));
if (connptdb == NULL)
errx(1, "Could not connect to ptserver");
and instead of pr_End, you just need
arlalib_destroyconn(connptdb);
So that ought to give you 90% of the code...
-- Owen
LeBlanc@mcc.ac.uk