home *** CD-ROM | disk | FTP | other *** search
/ Collection of Hack-Phreak Scene Programs / cleanhpvac.zip / cleanhpvac / PWAULTP3.ZIP / PWAPRGMS.A02 / PWA95 / PWAEF211.ZIP / EXTERNAL.ZIP / SCUMNUKE.PPS < prev    next >
Text File  |  1994-12-05  |  3KB  |  88 lines

  1. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  2. ; SCUMNUKE.PPE by Drew [PWA]
  3. ; Last updated: 12-3-94
  4. ;
  5. ; DESCRIPTION: This is a front-end to SCuM-NuKeR for use with EFLAG.  Other
  6. ;              nukers should work in a similar manner with EFLAG, where they
  7. ;              should be written to expect the filename as a parameter.
  8. ;
  9. ; INSTALLATION: Put SCUMNUKE.PPE and USERS.CFG into the **SAME DIRECTORY** as
  10. ;               SCuM-NuKeR.
  11. ;
  12. ; CONFIGURATION: Edit USERS.CFG to include the names of the users you wish
  13. ;                to allow nuke capabilities.  One user name per line only.
  14. ;                Next, go to where EFLAG is installed and edit PROMPT1.CFG,
  15. ;                PROMPT2.CFG, or both.  This is your choice and depends on
  16. ;                where you want to install it.  Typically, you will probably
  17. ;                just want to install it off of PROMPT2.
  18. ;
  19. ;                Increase the number of commands and add the appropriate lines
  20. ;                for EFLAG to make a call to SCUMNUKE.PPE.  For example:
  21. ;
  22. ;                @X08Nuke@X07                  <- unhighlighted text for EFLAG
  23. ;                @X4FNUKE@X07                  <- highlighted text for EFLAG
  24. ;                N                             <- hotkey inside of EFLAG
  25. ;                !C:\PPE\EFLAG\SCUMNUKE.PPE    <- call to SCUMNUKE.PPE
  26. ;
  27. string filename
  28. string line
  29. boolean allowed
  30.  
  31. ; first check to see if a filename was passed to EFNUKE.  if not, something
  32. ; is messed up inside of EFLAG (read: you must have modified something you
  33. ; probably should not have)
  34. ;
  35. if (tokcount() < 1) then
  36.     println "@X0CError: No filename passed to SCUMNUKE.  Aborting.@X07"
  37.     delay 25
  38.     newline
  39.     end
  40. else
  41.     filename = gettoken()
  42. endif
  43.  
  44.  
  45. ; now check if the user online is even allowed to nuke files
  46. ;
  47. allowed = FALSE
  48. if (exist(ppepath() + "USERS.CFG")) then
  49.     getuser
  50.     fopen 5, ppepath() + "USERS.CFG", O_RD, S_DW
  51.     fget 5, line
  52.     while (!ferr(5)) do
  53.         if (upper(line) == upper(u_name())) then
  54.             allowed = TRUE
  55.             break
  56.         endif
  57.         fget 5, line
  58.     endwhile
  59.     fclose 5
  60. endif
  61.  
  62. if (allowed == FALSE) then
  63.     println "@X0CSorry, you are not allowed to nuke files.@X07"
  64.     delay 25
  65.     newline
  66.     end
  67. endif
  68.  
  69.  
  70.  
  71. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  72. ; the code down here is pretty much exactly from the modified FLAG.PPS source
  73. ; included with SCuM-NuKeR.
  74. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  75. GETUSER
  76. IF (READLINE ((READLINE (PPEPATH()+"FLAG.CFG",PCBNODE()))+"FNUKE."+STRING(PCBNODE()),1) <> U_NAME()) do
  77. IF (EXIST(READLINE (PPEPATH()+"FLAG.CFG",PCBNODE()))+"FNUKE."+STRING(PCBNODE())) DELETE (READLINE (PPEPATH()+"FLAG.CFG",1))+"FNUKE."+STRING(PCBNODE())
  78.     FAPPEND 6,(READLINE (PPEPATH()+"FLAG.CFG",PCBNODE()))+"FNUKE."+STRING(PCBNODE()),O_RW,S_DN
  79.     FPUTLN 6,U_NAME()
  80.     FCLOSE 6
  81. ENDIF
  82. FAPPEND 6,(READLINE (PPEPATH()+"FLAG.CFG",PCBNODE()))+"FNUKE."+STRING(PCBNODE()),O_RW,S_DN
  83. FPUTLN 6,filename
  84. FCLOSE 6
  85. PRINTLN "@X0CFile flagged for nuking!  Don't forget to run NUKER!@X07"
  86. DELAY 25
  87. NEWLINE
  88.