1.\" Copyright (c) 1989, 1991 The Regents of the University of California. 2.\" All rights reserved. 3.\" 4.\" %sccs.include.redist.roff% 5.\" 6.\" @(#)uuencode.format.5 6.4 (Berkeley) 05/10/91 7.\" 8.Dd 9.Dt UUENCODE 5 10.Os BSD 4.0 11.Sh NAME 12.Nm uuencode 13.Nd format of an encoded uuencode file 14.Sh DESCRIPTION 15Files output by 16.Xr uuencode 1 17consist of a header line, 18followed by a number of body lines, 19and a trailer line. 20The 21.Xr uudecode 1 22command 23will ignore any lines preceding the header or 24following the trailer. 25Lines preceding a header must not, of course, 26look like a header. 27.Pp 28The header line is distinguished by having the first 296 characters 30.Dq begin\ \& 31The word 32.Em begin 33is followed by a mode (in octal), 34and a string which names the remote file. 35A space separates the three items in the header line. 36.Pp 37The body consists of a number of lines, each at most 62 characters 38long (including the trailing newline). 39These consist of a character count, 40followed by encoded characters, 41followed by a newline. 42The character count is a single printing character, 43and represents an integer, the number of bytes 44the rest of the line represents. 45Such integers are always in the range from 0 to 63 and can 46be determined by subtracting the character space (octal 40) 47from the character. 48.Pp 49Groups of 3 bytes are stored in 4 characters, 6 bits per character. 50All are offset by a space to make the characters printing. 51The last line may be shorter than the normal 45 bytes. 52If the size is not a multiple of 3, this fact can be determined 53by the value of the count on the last line. 54Extra garbage will be included to make the character count a multiple 55of 4. 56The body is terminated by a line with a count of zero. 57This line consists of one 58.Tn ASCII 59space. 60.Pp 61The trailer line consists of 62.Dq end 63on a line by itself. 64.Sh SEE ALSO 65.Xr uuencode 1 , 66.Xr uudecode 1 , 67.Xr uusend 1 , 68.Xr uucp 1 , 69.Xr mail 1 70.Sh HISTORY 71The 72.Nm 73file format appeared in 74.Bx 4.0 . 75.\" It was named uuencode.5 prior to 4.3 76