/usr.bin/uuencode/uuencode.format.5

https://bitbucket.org/freebsd/freebsd-head/ · Unknown · 102 lines · 102 code · 0 blank · 0 comment · 0 complexity · dea51d1cffa08deec76181889ccc650d MD5 · raw file

  1. .\" Copyright (c) 1989, 1991, 1993
  2. .\" The Regents of the University of California. All rights reserved.
  3. .\"
  4. .\" Redistribution and use in source and binary forms, with or without
  5. .\" modification, are permitted provided that the following conditions
  6. .\" are met:
  7. .\" 1. Redistributions of source code must retain the above copyright
  8. .\" notice, this list of conditions and the following disclaimer.
  9. .\" 2. Redistributions in binary form must reproduce the above copyright
  10. .\" notice, this list of conditions and the following disclaimer in the
  11. .\" documentation and/or other materials provided with the distribution.
  12. .\" 4. Neither the name of the University nor the names of its contributors
  13. .\" may be used to endorse or promote products derived from this software
  14. .\" without specific prior written permission.
  15. .\"
  16. .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  17. .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  18. .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  19. .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  20. .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  21. .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  22. .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  23. .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  24. .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  25. .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  26. .\" SUCH DAMAGE.
  27. .\"
  28. .\" @(#)uuencode.format.5 8.2 (Berkeley) 1/12/94
  29. .\" $FreeBSD$
  30. .\"
  31. .Dd January 12, 1994
  32. .Dt UUENCODE 5
  33. .Os
  34. .Sh NAME
  35. .Nm uuencode
  36. .Nd format of an encoded uuencode file
  37. .Sh DESCRIPTION
  38. Files output by
  39. .Xr uuencode 1
  40. consist of a header line,
  41. followed by a number of body lines,
  42. and a trailer line.
  43. The
  44. .Xr uudecode 1
  45. command
  46. will ignore any lines preceding the header or
  47. following the trailer.
  48. Lines preceding a header must not, of course,
  49. look like a header.
  50. .Pp
  51. The header line is distinguished by having the first
  52. 6 characters
  53. .Dq begin\ \&
  54. (note the trailing space).
  55. The word
  56. .Em begin
  57. is followed by a mode (in octal),
  58. and a string which names the remote file.
  59. A space separates the three items in the header line.
  60. .Pp
  61. The body consists of a number of lines, each at most 62 characters
  62. long (including the trailing newline).
  63. These consist of a character count,
  64. followed by encoded characters,
  65. followed by a newline.
  66. The character count is a single printing character,
  67. and represents an integer, the number of bytes
  68. the rest of the line represents.
  69. Such integers are always in the range from 1 to 45 or 64 and can
  70. be determined by subtracting the character space (octal 40)
  71. from the character.
  72. Character 64 represents a count of zero.
  73. .Pp
  74. Groups of 3 bytes are stored in 4 characters, 6 bits per character.
  75. All characters are always in range from 1 to 64 and are offset by a
  76. space (octal 40) to make the characters printing.
  77. Character
  78. 64 represents a count of zero.
  79. The last line may be shorter than the normal 45 bytes.
  80. If the size is not a multiple of 3, this fact can be determined
  81. by the value of the count on the last line.
  82. Extra null characters will be included to make the character count a multiple
  83. of 4.
  84. The body is terminated by a line with a count of zero.
  85. This line consists of one
  86. .Tn ASCII
  87. backquote (octal 140) character.
  88. .Pp
  89. The trailer line consists of
  90. .Dq end
  91. on a line by itself.
  92. .Sh SEE ALSO
  93. .Xr mail 1 ,
  94. .Xr uucp 1 ,
  95. .Xr uudecode 1 ,
  96. .Xr uuencode 1
  97. .Sh HISTORY
  98. The
  99. .Nm
  100. file format appeared in
  101. .Bx 4.0 .
  102. .\" It was named uuencode.5 prior to 4.3