home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 October / usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso / misc / volume2 / bencode-man < prev    next >
Internet Message Format  |  1991-08-07  |  2KB

  1. From: wilber@gauss.UUCP (Bob Wilber)
  2. Newsgroups: comp.sources.misc
  3. Subject: v02i028: man page for bencode/bdecode
  4. Message-ID: <7153@ncoast.UUCP>
  5. Date: 30 Jan 88 21:34:36 GMT
  6. Approved: allbery@ncoast.UUCP
  7.  
  8. Comp.sources.misc: Volume 2, Issue 28
  9. Submitted-By: Bob Wilber <wilber@gauss.UUCP>
  10. Archive-Name: bencode-man
  11.  
  12. I just snarfed bencode/bdecode off comp.sources.misc.  Here's a man page
  13. I wrote that you might want to add to the shar file.  (Use nroff -man.)
  14.  
  15. Bob Wilber   wilber@research.att.com  or ihnp4!gauss!wilber or
  16.              wilber%btl@csnet
  17.  
  18. ----------------- Cut Here ---------------------------------------------------
  19. #! /bin/sh
  20. # "sh" this file to produce the file "bencode.1"
  21. sed 's/^X//' << \_END_ > bencode.1
  22. X.TH BENCODE 1 "9 January 1988"
  23. X.UC 4
  24. X.SH NAME
  25. Xbencode, bdecode \- encode a binary file into printable ASCII; decode it back
  26. Xinto binary.
  27. X.SH SYNOPSIS
  28. X.B /usr/local/bin/bencode [source]
  29. X.br
  30. X.B /usr/local/bin/bdecode [source]
  31. X.SH DESCRIPTION
  32. X.I Bencode
  33. Xis used to a encode a binary file into printable ASCII, and
  34. X.I bdecode
  35. Xis used to decode an encoded file back into binary.
  36. XThese functions are typically used to package a binary file for mailing.
  37. X.PP
  38. X.I Bencode
  39. Xtakes the named source file (the default is standard input) and
  40. Xproduces an encoded version on the standard output.
  41. XThe encoding uses only the ASCII characters ``A'' \- ``Z'', ``a'' \- ``z'', ``0''
  42. X\- ``9'', ``+'', and ``-''.
  43. XThe ASCII characters blank, newline, and ``/'' also appear in the
  44. Xencoded file, but do not represent encoded bits.
  45. XThe encoded file is terminated with
  46. Xa byte count and cyclic redundancy check for detecting corrupted files.
  47. X.PP
  48. X.I Bdecode
  49. Xreads a file encoded by bencode (the default is standard input), strips off
  50. Xany leading and trailing lines added by mailers,
  51. Xand writes the decoded version to standard output.
  52. X.PP
  53. XThese functions are similar to
  54. X.I uuencode
  55. Xand
  56. X.I uudecode,
  57. Xbut are more robust because of the CRC check and because
  58. Xthey don't send characters like ``^'' and ``\\'', which are likely to get
  59. Xmangled if the file should happen to pass through a
  60. Xnon-ASCII machine.
  61. X.PP
  62. X.SH SEE\ ALSO
  63. Xuuencode(1)
  64. X.SH AUTHORS
  65. XKen Lalonde and Reg Quinton
  66. X.SH BUGS
  67. XThe file is expanded by 35% (3 bytes become 4 plus control information)
  68. Xcausing it to take longer to transmit.
  69. _END_
  70. exit 0
  71.