summaryrefslogtreecommitdiff
path: root/Tools/scripts/sunshar/sunshar.1
diff options
context:
space:
mode:
authorAkinori MUSHA <knu@FreeBSD.org>2004-02-28 14:29:09 +0000
committerAkinori MUSHA <knu@FreeBSD.org>2004-02-28 14:29:09 +0000
commitac6314f977225821d519ce06419c32c29da3ddea (patch)
treeb7c53feca6bfbc8e3ccc054a774b900db4ae1db1 /Tools/scripts/sunshar/sunshar.1
parent- Update to 2.1.3 (diff)
Add sunshar, a "secure unshar" for ports committers, which:
- Does not execute unknown commands nor call sh(1) at all. - Does not overwrite existing files by default. - Does not extract files into upper directories. - Does have a dry run (-n) flag to see what would have been extracted. - Does have a strip (-p N) flag to strip any number of levels from pathnames. It (so far) only supports shell archives made with BSD shar.
Notes
Notes: svn path=/head/; revision=102409
Diffstat (limited to 'Tools/scripts/sunshar/sunshar.1')
-rw-r--r--Tools/scripts/sunshar/sunshar.156
1 files changed, 56 insertions, 0 deletions
diff --git a/Tools/scripts/sunshar/sunshar.1 b/Tools/scripts/sunshar/sunshar.1
new file mode 100644
index 000000000000..ee24f229fbc5
--- /dev/null
+++ b/Tools/scripts/sunshar/sunshar.1
@@ -0,0 +1,56 @@
+.\" $FreeBSD$
+.\" $Idaemons: /home/cvs/sunshar/sunshar.1,v 1.2 2004/02/28 14:14:53 knu Exp $
+.\"
+.Dd September 9, 2001
+.Dt SUNSHAR 1
+.Os FreeBSD
+.Sh NAME
+.Nm sunshar
+.Nd a secure unshar
+.Sh SYNOPSIS
+.Nm
+.Op Fl hfnq
+.Op Fl p Ar number
+.Op Ar file ...
+.Sh DESCRIPTION
+The
+.Nm
+command extracts files from the given shell archive(s). If no file
+name is given, it reads from the standard input.
+.Pp
+It brings you security because it never executes dangerous commands
+possibly contained in a shell archive. Also, it does not overwrite
+existing files unless the
+.Fl f
+option is specified.
+.Sh OPTIONS
+The following command line arguments are supported:
+.Pp
+.Bl -tag -width "-p number" -compact
+.It Fl h
+Show help and exit.
+.Pp
+.It Fl f
+Allow overwriting existing files, and ignore errors and continue.
+.Pp
+.It Fl p Ar number
+Strip
+.Ar number
+levels of path components from path names. (cf.
+.Xr patch 1 's
+.Fl p
+option)
+.Pp
+.It Fl n
+Do not extract anything but just show what would have been extracted.
+.Pp
+.It Fl q
+Be quiet.
+.El
+.Sh SEE ALSO
+.Xr shar 1
+.Sh AUTHORS
+.An Akinori MUSHA Aq knu@iDaemons.org
+.Sh BUGS
+.Nm
+only supports shell archives made with BSD shar.