diff options
| author | mestre <> | 2019-08-08 16:49:35 +0000 |
|---|---|---|
| committer | mestre <> | 2019-08-08 16:49:35 +0000 |
| commit | a75adc8cc022f9aeb180784c28b747d3b5ce39a4 (patch) | |
| tree | bd8a88cce3f2f7953e1542173483a59da677a2f0 | |
| parent | 5f9a583184d5cf6310ec471270a5d282ad43844b (diff) | |
| download | openbsd-a75adc8cc022f9aeb180784c28b747d3b5ce39a4.tar.gz openbsd-a75adc8cc022f9aeb180784c28b747d3b5ce39a4.tar.bz2 openbsd-a75adc8cc022f9aeb180784c28b747d3b5ce39a4.zip | |
added /* no filesystem visibility */ above unveil("/", "") since "" is too easy
to misread.
as per suggestion by and OK deraadt@
Diffstat (limited to '')
| -rw-r--r-- | src/usr.bin/nc/netcat.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/usr.bin/nc/netcat.c b/src/usr.bin/nc/netcat.c index c2e769c4c0..c04298f64c 100644 --- a/src/usr.bin/nc/netcat.c +++ b/src/usr.bin/nc/netcat.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: netcat.c,v 1.205 2019/06/28 13:35:02 deraadt Exp $ */ | 1 | /* $OpenBSD: netcat.c,v 1.206 2019/08/08 16:49:35 mestre Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2001 Eric Jackson <ericj@monkey.org> | 3 | * Copyright (c) 2001 Eric Jackson <ericj@monkey.org> |
| 4 | * Copyright (c) 2015 Bob Beck. All rights reserved. | 4 | * Copyright (c) 2015 Bob Beck. All rights reserved. |
| @@ -383,6 +383,7 @@ main(int argc, char *argv[]) | |||
| 383 | err(1, "unveil"); | 383 | err(1, "unveil"); |
| 384 | } | 384 | } |
| 385 | } else { | 385 | } else { |
| 386 | /* no filesystem visibility */ | ||
| 386 | if (unveil("/", "") == -1) | 387 | if (unveil("/", "") == -1) |
| 387 | err(1, "unveil"); | 388 | err(1, "unveil"); |
| 388 | } | 389 | } |
