mirror of
https://github.com/opnsense/src.git
synced 2026-04-15 14:29:58 -04:00
This is an initial take on documenting vulnerability mitigations. Connect mitigations(7) to the build Also add some cross references. Reviewed by: gbe (earlier) Sponsored by: The FreeBSD Foundation Co-authored-by: Olivier Certner <olce.freebsd@certner.fr> Differential Revision: https://reviews.freebsd.org/D41794 (cherry picked from commit b6a61ac2d475fba9c45f7f407549a522f60dea18) (cherry picked from commit 6e5dcc6113da649a79e5bc2c3ea9329bcd1d85d5) (cherry picked from commit a2b289608d6b54b6e1ce85096560807e551bb5ac)
109 lines
3.1 KiB
Groff
109 lines
3.1 KiB
Groff
.\" Copyright 2019 The FreeBSD Foundation.
|
|
.\"
|
|
.\" This software was developed by Bora Ozarslan under sponsorship from
|
|
.\" the FreeBSD Foundation.
|
|
.\"
|
|
.\" Redistribution and use in source and binary forms, with or without
|
|
.\" modification, are permitted provided that the following conditions
|
|
.\" are met:
|
|
.\" 1. Redistributions of source code must retain the above copyright
|
|
.\" notice, this list of conditions and the following disclaimer.
|
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|
.\" notice, this list of conditions and the following disclaimer in the
|
|
.\" documentation and/or other materials provided with the distribution.
|
|
.\"
|
|
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS''
|
|
.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
|
|
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
.\" SUCH DAMAGE.
|
|
.\"
|
|
.Dd October 5, 2023
|
|
.Dt ELFCTL 1
|
|
.Os
|
|
.Sh NAME
|
|
.Nm elfctl
|
|
.Nd change an ELF binary's feature control note
|
|
.Sh SYNOPSIS
|
|
.Nm
|
|
.Op Fl h | Fl -help
|
|
.Op Fl i
|
|
.Op Fl l
|
|
.Op Fl e Ar featurelist
|
|
.Ar
|
|
.Sh DESCRIPTION
|
|
The
|
|
.Nm
|
|
utility modifies feature flags in the feature control note in an ELF binary.
|
|
.Pp
|
|
The options are as follows:
|
|
.Bl -tag -width indent
|
|
.It Fl h | Fl -help
|
|
Print a usage message and exit.
|
|
.It Fl i
|
|
Ignore unknown feature flags in
|
|
.Ar featurelist .
|
|
.It Fl l
|
|
List known ELF feature flags.
|
|
.It Fl e Ar featurelist
|
|
Edit features from the given comma separated list
|
|
.Ar featurelist .
|
|
.Ar featurelist
|
|
starts with one of the three operations:
|
|
.Dq Li +
|
|
to turn on the features,
|
|
.Dq Li -
|
|
to turn off the features,
|
|
.Dq Li =
|
|
to only turn on the given features.
|
|
A comma separated list of feature names or numeric values follows the
|
|
operation.
|
|
.El
|
|
.Pp
|
|
If
|
|
.Fl e
|
|
is not specified
|
|
.Nm
|
|
displays the status of each feature in the ELF note in each
|
|
.Ar .
|
|
.Sh EXIT STATUS
|
|
Exit status is 0 on success, and 1 if the command
|
|
fails if a file does not exist, is too short,
|
|
or fails to find or edit features note.
|
|
.Sh EXAMPLES
|
|
The following is an example of a typical usage
|
|
of the
|
|
.Nm
|
|
command:
|
|
.Bd -literal -offset indent
|
|
elfctl file
|
|
elfctl -e +noaslr file
|
|
.Ed
|
|
.Pp
|
|
Features may be specified as numerical values:
|
|
.Bd -literal -offset -indent
|
|
elfctl -e =0x0001,0x0004 file
|
|
.Ed
|
|
.Pp
|
|
Features may also be specified as a single combined value:
|
|
.Bd -literal -offset -indent
|
|
elfctl -e =0x5 file
|
|
.Ed
|
|
.Sh SEE ALSO
|
|
.Xr mitigations 7
|
|
.Sh HISTORY
|
|
.Nm
|
|
first appeared in
|
|
.Fx 12.2 .
|
|
.Sh AUTHORS
|
|
.Nm
|
|
was written by
|
|
.An Bora Ozarslan Mt borako.ozarslan@gmail.com
|
|
under sponsorship from the
|
|
.Fx Foundation.
|