Skip to content

Commit ffe27e5

Browse files
committed
upstream: add some cautionary text about % token expansion and
shell metacharacters; based on report from vinci AT protonmail.ch OpenBSD-Commit-ID: aa1450a54fcee2f153ef70368d90edb1e7019113
1 parent 60ec3d5 commit ffe27e5

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

ssh_config.5

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@
3333
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
3434
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3535
.\"
36-
.\" $OpenBSD: ssh_config.5,v 1.386 2023/08/28 09:52:09 djm Exp $
37-
.Dd $Mdocdate: August 28 2023 $
36+
.\" $OpenBSD: ssh_config.5,v 1.387 2023/10/04 04:03:50 djm Exp $
37+
.Dd $Mdocdate: October 4 2023 $
3838
.Dt SSH_CONFIG 5
3939
.Os
4040
.Sh NAME
@@ -2206,6 +2206,16 @@ accepts all tokens.
22062206
and
22072207
.Cm ProxyJump
22082208
accept the tokens %%, %h, %n, %p, and %r.
2209+
.Pp
2210+
Note that some of these directives build commands for execution via the shell.
2211+
Because
2212+
.Xr ssh 1
2213+
performs no filtering or escaping of characters that have special meaning in
2214+
shell commands (e.g. quotes), it is the user's reposibility to ensure that
2215+
the arguments passed to
2216+
.Xr ssh 1
2217+
do not contain such characters and that tokens are appropriately quoted
2218+
when used.
22092219
.Sh ENVIRONMENT VARIABLES
22102220
Arguments to some keywords can be expanded at runtime from environment
22112221
variables on the client by enclosing them in

0 commit comments

Comments
 (0)