uuencode(1bnu)


uuencode, uudecode -- encode a binary file, or decode its ASCII representation

Synopsis

uuencode [source_file] file_label

uudecode [encoded_file]

Description

The uuencode command converts a binary file into an ASCII-encoded representation that can be sent using mail(1).

The uudecode command reads encoded_file, strips off any leading and trailing lines added by mailer programs, and recreates the original binary data with the filename, mode and owner specified in the header.

Files


/usr/lib/locale/locale/LC_MESSAGES/uxbnu
language-specific message file (see LANG on environ(5)).

Usage

uuencode encodes the contents of source_file, or the standard input if no source_file argument is given. The file_label argument is required: it is included in the encoded file's header as the name of the file into which uudecode is to place the binary (decoded) data. uuencode also includes the ownership and permission modes of source_file, so that the file specified by file_label is recreated with those same ownership and permission modes.

The encoded file is an ordinary ASCII text file; it can be edited by any text editor. Only the mode or file label in the header should be changed, to avoid corrupting the decoded binary.

The encoded file's size is expanded by 35% (3 bytes become 4, plus control information), causing it to take longer to transmit than the equivalent binary.

The user on the remote system who is invoking uudecode (typically uucp) must have write permission on the file specified in file_label.

Since both uuencode and uudecode run with user ID set to uucp, uudecode can fail with permission denied when attempted in a directory that does not have write permission allowed for other.

Examples

The following command line reads the file in.cpio.Z, encodes its contents, adds a header containing the file label ``out.cpio.Z'', and places the output in the file out.cpio.Z.uu:

uuencode in.cpio.Z out.cpio.Z > out.cpio.Z.uu

The following command line reads the file out.cpio.Z.uu, decodes its contents, and places the output in the file out.cpio.Z:

uudecode out.cpio.Z.uu

References

environ(5), mail(1), uucp(1bnu), uux(1bnu), uuencode(4bnu)
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004