home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / emacs / 2834 < prev    next >
Encoding:
Internet Message Format  |  1992-08-12  |  2.1 KB

  1. Path: sparky!uunet!usc!noiro.acs.uci.edu!news.service.uci.edu!hardy
  2. From: hardy@golem.ps.uci.edu (Meinhard E. Mayer (Hardy))
  3. Subject: Re: Question: How to use Emacs to access root-owned files
  4. Nntp-Posting-Host: golem.ps.uci.edu
  5. Message-ID: <HARDY.92Aug12175216@golem.ps.uci.edu>
  6. In-reply-to: bob@MorningStar.Com's message of Wed, 12 Aug 1992 16:01:49 GMT
  7. Newsgroups: comp.emacs
  8. Organization: Department of Physics, UC Irvine, CA 92717-4575, USA
  9. Lines: 35
  10. Distribution: comp
  11. References: <BETSYS.92Aug10171110@ra.cs.umb.edu>
  12.     <BOB.92Aug12120143@volitans.MorningStar.Com>
  13. Date: 13 Aug 92 00:52:43 GMT
  14.  
  15. In article <BOB.92Aug12120143@volitans.MorningStar.Com> bob@MorningStar.Com (Bob Sutterfield) writes:
  16.  
  17. ?
  18. ?   In article <BETSYS.92Aug10171110@ra.cs.umb.edu> betsys@cs.umb.edu (Elizabeth Schwartz) writes:
  19. ?
  20. ?      I need a bit of code that prompts me for the root passwd and then
  21. ?      lets me read and write as root. (obviously, it mustn't know the
  22. ?      passwd!)
  23. ?
  24. ?   Get ftp.cis.ohio-state.edu:pub/gnu/emacs/elisp-archive/packages/ange-ftp.tar.Z.
  25. ?
  26. ?   I say ^X^F/user@hostname:/path/to/file, and ange-ftp prompts me for
  27. ?   that user's password on that host.  If "user" is "root", you'll be
  28. ?   editing a file as root on that host.  If "hostname" is "localhost",
  29. ?   you'll have an Emacs buffer that's root on the same machine as the
  30. ?   Emacs is running on.  When you ^X^S (or whatever), ange-ftp does
  31. ?   whatever's necessary to write the file back appropriately via FTP.
  32.  
  33. If your system is secure enough you can do even better -- make an
  34. appropriate entry in your .netrc file 
  35. machine localhost login root password <rootpassword>
  36. or put this in a file which ange-ftp knows about and which is
  37. read-write-protected and mayne hidden in some subdirectory. 
  38. Then ange-ftp lets you dired as root to your heart's delight. 
  39. If you are concerned about doing "bad things" as root you may try to
  40. log in as bin, or something like this. 
  41.  
  42. I don't know how we lived before Andy Norman made ange-ftp available
  43. ...
  44. --
  45. Hardy 
  46. -----
  47. Meinhard E. Mayer,  Department of Physics, UC Irvine 
  48. e-mail: hardy@golem.ps.uci.edu (preferred) or MMAYER@UCI.BITNET
  49.  
  50.