home *** CD-ROM | disk | FTP | other *** search
/ Hacker Chronicles 1 / HACKER1.ISO / phrk3 / phrack32.8 < prev    next >
Text File  |  1992-09-26  |  17KB  |  402 lines

  1.  
  2.                               ==Phrack Classic==
  3.  
  4.                      Volume Three, Issue 32, File #8 of 12
  5.  
  6.  
  7.                        +-------------------------------+
  8.                        | Inside the SYSUAF.DAT file of |
  9.                        +-------------------------------+           
  10.  
  11.            +------------------------------------------------------+
  12.            | Digital Equipment Corporation's VMS Operating System |
  13.            +------------------------------------------------------+
  14.  
  15.                                    -= by =-
  16.  
  17.                          -----:>  Pain Hertz  <:----
  18.  
  19.  
  20.  
  21. Overview
  22. ~~~~~~~~
  23.         In this file, I will explain what the System User Authorization File
  24. is, what information it contains, what the logical and physical characteristics
  25. of the file are, and how one can manipulate it to reveal and/or modify its
  26. contents.
  27.  
  28. Background
  29. ~~~~~~~~~
  30.         The Virtual Memory System (VMS) Operating System's System User
  31. Authorization File (SYSUAF) contains the information that determines a given
  32. user's username, password(s), security priviledges, as well as many other
  33. similar data which either allow or disallow the user to have the system
  34. perform certain tasks.
  35.  
  36. Characteristics
  37. ~~~~~~~~~~~~~~~
  38.         The SYSUAF.DAT file (UAF) is usually located on the system on the
  39. device pointed to by the logical SYS$COMMON, and under the [SYSEXE]
  40. subdirectory.  However, if the logical SYSUAF exists, it will point to the
  41. location and name of the UAF.
  42.  
  43.         The UAF is a binary, indexed data file.  It's indexed on 4 keys:
  44. username, UIC, extended user identifier, and owner identifier.  Using
  45. the VMS ANALYZE utility reveals the following about the UAF:
  46.  
  47.  
  48. IDENT   "01-JAN-1990 13:13:13   VAX/VMS ANALYZE/RMS_FILE Utility"
  49.  
  50. SYSTEM
  51.         SOURCE                  VAX/VMS
  52.  
  53. FILE
  54.         ALLOCATION              24
  55.         BEST_TRY_CONTIGUOUS     yes
  56.         BUCKET_SIZE             3
  57.         CLUSTER_SIZE            3
  58.         CONTIGUOUS              no
  59.         EXTENSION               3
  60.         FILE_MONITORING         no
  61.         GLOBAL_BUFFER_COUNT     0
  62.         NAME                    "SYS$COMMON:[SYSEXE]SYSUAF.DAT;1"
  63.         ORGANIZATION            indexed
  64.         OWNER                   [SYSTEM]
  65.         PROTECTION              (system:RWED, owner:RWED, group:RWED, world:RE)
  66.  
  67. RECORD
  68.         BLOCK_SPAN              yes
  69.         CARRIAGE_CONTROL        none
  70.         FORMAT                  variable
  71.         SIZE                    1412
  72.  
  73. AREA 0
  74.         ALLOCATION              9
  75.         BEST_TRY_CONTIGUOUS     yes
  76.         BUCKET_SIZE             3
  77.         EXTENSION               3
  78.  
  79. AREA 1
  80.         ALLOCATION              3
  81.         BUCKET_SIZE             3
  82.         EXTENSION               3
  83.  
  84. AREA 2
  85.         ALLOCATION              12
  86.         BUCKET_SIZE             2
  87.         EXTENSION               12
  88.  
  89. KEY 0
  90.         CHANGES                 no
  91.         DATA_KEY_COMPRESSION    yes
  92.         DATA_RECORD_COMPRESSION yes
  93.         DATA_AREA               0
  94.         DATA_FILL               100
  95.         DUPLICATES              no
  96.         INDEX_AREA              1
  97.         INDEX_COMPRESSION       yes
  98.         INDEX_FILL              100
  99.         LEVEL1_INDEX_AREA       1
  100.         NAME                    "Username"
  101.         NULL_KEY                no
  102.         PROLOG                  3
  103.         SEG0_LENGTH             32
  104.         SEG0_POSITION           4
  105.         TYPE                    string
  106.  
  107. KEY 1
  108.         CHANGES                 yes
  109.         DATA_KEY_COMPRESSION    no
  110.         DATA_AREA               2
  111.         DATA_FILL               100
  112.         DUPLICATES              yes
  113.         INDEX_AREA              2
  114.         INDEX_COMPRESSION       no
  115.         INDEX_FILL              100
  116.         LEVEL1_INDEX_AREA       2
  117.         NAME                    "UIC"
  118.         NULL_KEY                no
  119.         SEG0_LENGTH             4
  120.         SEG0_POSITION           36
  121.         TYPE                    bin4
  122.  
  123. KEY 2
  124.         CHANGES                 yes
  125.         DATA_KEY_COMPRESSION    no
  126.         DATA_AREA               2
  127.         DATA_FILL               100
  128.         DUPLICATES              yes
  129.         INDEX_AREA              2
  130.         INDEX_COMPRESSION       no
  131.         INDEX_FILL              100
  132.         LEVEL1_INDEX_AREA       2
  133.         NAME                    "Extended User Identifier"
  134.         NULL_KEY                no
  135.         SEG0_LENGTH             8
  136.         SEG0_POSITION           36
  137.         TYPE                    bin8
  138.  
  139. KEY 3
  140.         CHANGES                 yes
  141.         DATA_KEY_COMPRESSION    no
  142.         DATA_AREA               2
  143.         DATA_FILL               100
  144.         DUPLICATES              yes
  145.         INDEX_AREA              2
  146.         INDEX_COMPRESSION       no
  147.         INDEX_FILL              100
  148.         LEVEL1_INDEX_AREA       2
  149.         NAME                    "Owner Identifier"
  150.         NULL_KEY                yes
  151.         NULL_VALUE              0
  152.         SEG0_LENGTH             8
  153.         SEG0_POSITION           44
  154.         TYPE                    bin8
  155.  
  156. ANALYSIS_OF_AREA 0
  157.         RECLAIMED_SPACE         0
  158.  
  159. ANALYSIS_OF_AREA 1
  160.         RECLAIMED_SPACE         0
  161.  
  162. ANALYSIS_OF_AREA 2
  163.         RECLAIMED_SPACE         0
  164.  
  165. ANALYSIS_OF_KEY 0
  166.         DATA_FILL               71
  167.         DATA_KEY_COMPRESSION    75
  168.         DATA_RECORD_COMPRESSION 67
  169.         DATA_RECORD_COUNT       5
  170.         DATA_SPACE_OCCUPIED     3
  171.         DEPTH                   1
  172.         INDEX_COMPRESSION       85
  173.         INDEX_FILL              1
  174.         INDEX_SPACE_OCCUPIED    3
  175.         LEVEL1_RECORD_COUNT     1
  176.         MEAN_DATA_LENGTH        644
  177.         MEAN_INDEX_LENGTH       34
  178.  
  179. ANALYSIS_OF_KEY 1
  180.         DATA_FILL               7
  181.         DATA_KEY_COMPRESSION    0
  182.         DATA_RECORD_COUNT       4
  183.         DATA_SPACE_OCCUPIED     2
  184.         DEPTH                   1
  185.         DUPLICATES_PER_SIDR     0
  186.         INDEX_COMPRESSION       0
  187.         INDEX_FILL              2
  188.         INDEX_SPACE_OCCUPIED    2
  189.         LEVEL1_RECORD_COUNT     1
  190.         MEAN_DATA_LENGTH        15
  191.         MEAN_INDEX_LENGTH       6
  192.  
  193. ANALYSIS_OF_KEY 2
  194.         DATA_FILL               8
  195.         DATA_KEY_COMPRESSION    0
  196.         DATA_RECORD_COUNT       4
  197.         DATA_SPACE_OCCUPIED     2
  198.         DEPTH                   1
  199.         DUPLICATES_PER_SIDR     0
  200.         INDEX_COMPRESSION       0
  201.         INDEX_FILL              2
  202.         INDEX_SPACE_OCCUPIED    2
  203.         LEVEL1_RECORD_COUNT     1
  204.         MEAN_DATA_LENGTH        19
  205.         MEAN_INDEX_LENGTH       10
  206.  
  207. ANALYSIS_OF_KEY 3
  208.         ! This index is uninitialized - there are no records.
  209.  
  210. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  211.  
  212. Examination
  213. ~~~~~~~~~~
  214.  
  215.         Generally, an interactive user would use the AUTHORIZE utility to
  216. modify or examine the UAF, while a program would use the $GETUAI system
  217. services (get user authorization information service) to examine the file.
  218. The $GETUAI system services reference provide an excellent description of what
  219. fields the UAF contains, and how many bytes are used within the file to store
  220. each of those fields.  However, it may not be within your realm of skills to
  221. program using system services.  It would probably be considerably easier to
  222. use a sector editor/browser to locate values within the UAF.  You could use a
  223. sector editor/browser online (such as VFE.EXE), or you you might choose to
  224. download the UAF and use an editor/browse for your personal computer.  
  225. Regardless of which method you choose, you will have to know the offset of
  226. each field within the user authorization file.  This is what I have provided
  227. for you.
  228.  
  229.         The contents of the UAF under VMS release 5.3-1 are as follows:
  230.  
  231. Offset   Description                                            Length
  232. -----------------------------------------------------------------------------
  233.    0     Record Header                                             4
  234.    4     Username (loginid)                                       32
  235.   36     Member UIC - Mem UIC decimal   1 = 0100                   2
  236.                       Mem UIC decimal  10 = 0A00
  237.                       Mem UIC decimal 256 = FF01
  238.  
  239.   38     Group UIC  - Same as format as member UIC                 2
  240.  
  241.          Note:  UICs as displayed in the VMS environment 
  242.          are OCTAL.  A UIC of [010,001] would be saved as
  243.          '01000800' in bytes 36-39 (offset).
  244.  
  245.   40     Nulls                                                    12
  246.   52     Account name                                             32
  247.   84     1 byte - value = length of owner                          1
  248.   85     Owner                                                    31
  249.  116     1 byte - value = length of device                         1
  250.  117     Device (default disk device)                             31
  251.  148     1 byte - length of default (SYS$LOGIN) directory          1
  252.  149     Default (SYS$LOGIN) directory name                       63
  253.  212     1 byte - length of default login command file             1
  254.  213     Default login command file                               63
  255.  276     1 byte - length of default CLI                            1
  256.  277     Default command language interpeter                      31
  257.  
  258.          Note: CLI is assumed to be in SYS$SYSTEM directory
  259.          and have an .EXE extension.
  260.  
  261.  308     1 byte - length of user defined CLI tables                1
  262.  309     User defined CLI table name                              31
  263.  340     Encrypted primary password                                8
  264.  348     Encrypted secondary password                              8
  265.  356     Number of login fails                                     2
  266.  358     Password encryption salt                                  2
  267.  360     Encryption algorithm code byte - primary password         1
  268.  361     Encryption algorithm code byte - secondary password       1
  269.  362     Password minimum length                                   1
  270.  363     Filler (1 byte)                                           1
  271.  364     Account expiration date                                   8
  272.  372     Password lifetime                                         8
  273.  380     Password change date/time - primary password              8
  274.  388     Password change date/time - secondary password            8
  275.  396     Last interactive login date/time                          8
  276.  404     Last non-interactive login date/time                      8
  277.  412     Authorize priviledges                                     8
  278.  420     Default priviledges                                       8
  279.  428     Filler (40 bytes)                                        40
  280.  
  281.  468     Login Flags bits as follows:                              4
  282.  
  283.            7  6  5  4  3  2  1  0         
  284.          -------------------------
  285.          |  |  |  |  |  |  |  |  |
  286.          -------------------------
  287.  
  288.          Byte Offset 468:
  289.  
  290.          Bit 0            - User can not use CTRL-Y
  291.          Bit 1            - User is restricted to default
  292.                             command interpeter
  293.          Bit 2            - SET PASSWORD command is disabled
  294.          Bit 3            - Prevent user from changing any
  295.                             defaults at login
  296.          Bit 4            - User account is disabled
  297.          Bit 5            - User will not receive the login
  298.                             welcome message
  299.          Bit 6            - Announcement of new mail is suppressed
  300.          Bit 7            - Mail delivery to user is disabled
  301.  
  302.          Byte Offset 469:
  303.  
  304.          Bit 0            - User is required to use generated
  305.                             passwords
  306.          Bit 1            - Primary password is expired
  307.          Bit 2            - Secondary password is expired
  308.          Bit 3            - All actions are audited
  309.          Bit 4            - User will not receive last login
  310.                             messages
  311.          Bit 5            - User can not reconnect to existing
  312.                             processes
  313.          Bit 6            - User can only login to terminals
  314.                             defined by the automatic login
  315.                             facility (ALF)
  316.          Bit 7            - User is required to change expired
  317.                             passwords
  318.  
  319.          Byte Offset 470:
  320.  
  321.          Bit 0            - User is restricted to captive account
  322.          Bit 1            - Prevent user from executing RUN, MCR
  323.                             commands, or foreign commands at the
  324.                             DCL level
  325.          Bits 2-7         - Reserved for future use
  326.  
  327.          Byte Offset 471:
  328.  
  329.          Bits 0-7         - Reserved for future use
  330.      
  331.  
  332.          Note On Access Bytes:
  333.  
  334.          Each bit set represents a 1-hour period, from bit 0 as
  335.          midnight to 1 a.m. to bit 23 as 11 p.m. to midnight.
  336.  
  337.  472     Network access bytes - primary days                       3
  338.  475     Network access bytes - seconday days                      3
  339.  478     Batch access bytes - primary days                         3
  340.  481     Batch access bytes - seconday days                        3
  341.  484     Local access bytes - primary days                         3
  342.  487     Local access bytes - seconday days                        3
  343.  490     Dialup access bytes - primary days                        3
  344.  493     Dialup access bytes - secondary days                      3
  345.  496     Remote access bytes - primary days                        3
  346.  499     Remote access bytes - seconday days                       3
  347.  
  348.  502     Filler (12 bytes)                                        12 
  349.  514     Prime days                                                1
  350.  
  351.          Bits 0-7 toggled on represents primedays, respective
  352.          to Mon, Tue, ..., Sun.
  353.  
  354.  515     Filler (1 byte)                                           1
  355.  516     Default base priority                                     1
  356.  517     Maximum job queue priority                                1
  357.  518     Active process limit                                      2
  358.  520     Max. number of interactive, detached, and batch jobs      2
  359.  524     Detached process limit                                    2
  360.  526     Subprocess creation limit                                 2
  361.  528     Buffered I/O count                                        2
  362.  530     Timer queue entry limit                                   2
  363.  532     AST queue limit                                           2
  364.  534     Lock queue limit                                          2
  365.  536     Open file limit                                           4
  366.  538     Shared file limit                                         2
  367.  540     Working set quota                                         4
  368.  548     Working set extent                                        4
  369.  552     Paging file quota                                         4
  370.  556     Maximum CPU time limit (in 10-milliseconds)               4
  371.  560     Buffered I/O byte limit                                   4
  372.  564     Paged buffer I/O byte count limit                         4
  373.  568     Initial byte quota (jobwide logical name table uses)      4
  374.  572     Filler (72 bytes)                                        72
  375.  
  376.         Dates and times are stored as 8 bytes representing the number of
  377. seconds elapsed since November 17, 1858, 12:00:00 a.m.
  378.  
  379.         Earlier versions of the VMS UAF will contain much of the same data,
  380. which should be at the same offset as listed above.
  381.  
  382.  
  383.         Should you decide to attempt to modify the SYSUAF.DAT file, keep in
  384. mind that if you download the file, when you upload it, it will not be the
  385. same as it was before; it will not be an indexed file.  You *might* be able
  386. to create an .FDL file (using ANALYZE/RMS/FDL SYSUAF.DAT), and use that .FDL
  387. file to convert it back to an indexed file
  388. (with CONVERT/FDL=SYSUAF.FDL UPLOAD_UAF.DAT NEW_UAF.DAT), but chances that it
  389. will contain the proper indexing and file attributes are slim.  Remember when
  390. altering the SYSUAF.DAT file to keep a copy around (on the system) in case
  391. you need to repair the damage.
  392.  
  393.  
  394. -PHz       
  395.  
  396. Feel free to make any comments or corrections to the following address:
  397.  
  398. [phz@judy.indstate.edu]
  399. _______________________________________________________________________________
  400.  
  401. Downloaded From P-80 International Information Systems 304-744-2253 12yrs+
  402.