[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference iosg::all-in-1_v30

Title:*OLD* ALL-IN-1 (tm) Support Conference
Notice:Closed - See Note 4331.l to move to IOSG::ALL-IN-1
Moderator:IOSG::PYE
Created:Thu Jan 30 1992
Last Modified:Tue Jan 23 1996
Last Successful Update:Fri Jun 06 1997
Number of topics:4343
Total number of notes:18308

1820.0. "UAI$.DEFPRIVLEGE translation into meaning full text ?" by GIDDAY::SETHI (Man from Downunder) Fri Nov 20 1992 05:46

    G'day All,
    
    The UAI$ DSAB allows you to check if a user has say SYSLCK priv. or you
    can check the users UAI$.DEFPRIVILEGES.
    
    <GET UAI$.DEFPRIVILEGES["USERNAME"] gives you a HEX number, is there
    away of translating the value show all the priveleges are displayed ?
    For example if a user has TMPMBX and NETMBX the value displayed is 
    "0000000000108000" can this be translated to mean TMPMBX, NETMBX ?
    
    I looked at the ALL-IN-1 lexical functions FN$<what ever>, I could not
    find anything.
    
    Thanks 
    
    Sunil
T.RTitleUserPersonal
Name
DateLines
1820.1UAI$ comes back to haunt me...SCOTTC::MARSHALLFri Nov 20 1992 10:1017
Sunil,

The PRIVILEGES and DEFPRIVILEGES fields of UAI$ are designed primarily for
storing, copying, etc, privilege masks, without being too concerned about what
the individual privileges are.  There was discussion about providing some sort
of conversion for these two fields, as well as for all the access-hours fields,
but schedules, resources, etc, etc.  Customers would still be waiting for V3.0
to ship if we'd put in it everything that everyone wanted!

UAI$ provides fields like .NETMBX, .TMPMBX, .DEFTMPMBX, etc, for all the
individual privileges.  These fields have value 1 if the user has that
privilege, and 0 if they don't.  Maybe those will serve your purpose?

If you really need to "decode" the privilege bit mask, then it's pretty easy
to write a little script to do it, using those wonderful FN$ functions :-)

Scott
1820.2GIDDAY::SETHIMan from DownunderSun Nov 22 1992 22:2917
    Hi Scott,
    
    I was going to suggest that the customer actually check for the
    required privs. using UAI$.<priv. name>. I just thought that there may
    have been a lexical function that did the translation.
    
    You know the old saying give them an inch and they want a mile.
                    
>If you really need to "decode" the privilege bit mask, then it's pretty easy
>to write a little script to do it, using those wonderful FN$ functions :-)
    
    Wonderful you say, I thought they are the best thing since before
    slice bread :-).
    
    Thanks
    
    Sunil