Skip to content

Commit 81a8608

Browse files
authored
cmd/dlv: Fix same-user check and add flag to disable it (#1839)
* service: also search IPv6 connections when checking user When checking if the user is allowed to connect to this Delve instance also search IPv6 connections even though the local address is IPv4. Fixes #1835 * cmd: add flag to disable same-user check Fixes #1835
1 parent 99532c4 commit 81a8608

File tree

17 files changed

+45
-5
lines changed

17 files changed

+45
-5
lines changed

Documentation/usage/dlv.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ Pass flags to the program you are debugging using `--`, for example:
3030
--log Enable debugging server logging.
3131
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3232
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
33+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
3334
--wd string Working directory for running the program. (default ".")
3435
```
3536

Documentation/usage/dlv_attach.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ dlv attach pid [executable]
3030
--log Enable debugging server logging.
3131
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3232
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
33+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
3334
--wd string Working directory for running the program. (default ".")
3435
```
3536

Documentation/usage/dlv_backend.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ are:
2929
--log Enable debugging server logging.
3030
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3131
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
32+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
3233
--wd string Working directory for running the program. (default ".")
3334
```
3435

Documentation/usage/dlv_connect.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ dlv connect addr
2525
--log Enable debugging server logging.
2626
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
2727
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
28+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
2829
--wd string Working directory for running the program. (default ".")
2930
```
3031

Documentation/usage/dlv_core.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ dlv core <executable> <core>
3131
--log Enable debugging server logging.
3232
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3333
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
34+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
3435
--wd string Working directory for running the program. (default ".")
3536
```
3637

Documentation/usage/dlv_debug.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ dlv debug [package]
3737
--log Enable debugging server logging.
3838
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3939
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
40+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
4041
--wd string Working directory for running the program. (default ".")
4142
```
4243

Documentation/usage/dlv_exec.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ dlv exec <path/to/binary>
3737
--log Enable debugging server logging.
3838
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3939
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
40+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
4041
--wd string Working directory for running the program. (default ".")
4142
```
4243

Documentation/usage/dlv_log.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ mode.
4343
--log Enable debugging server logging.
4444
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
4545
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
46+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
4647
--wd string Working directory for running the program. (default ".")
4748
```
4849

Documentation/usage/dlv_replay.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ dlv replay [trace directory]
2929
--log Enable debugging server logging.
3030
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
3131
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
32+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
3233
--wd string Working directory for running the program. (default ".")
3334
```
3435

Documentation/usage/dlv_run.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ dlv run
2525
--log Enable debugging server logging.
2626
--log-dest string Writes logs to the specified file or file descriptor (see 'dlv help log').
2727
--log-output string Comma separated list of components that should produce debug output (see 'dlv help log')
28+
--only-same-user Only connections from the same user that started this instance of Delve are allowed to connect. (default true)
2829
--wd string Working directory for running the program. (default ".")
2930
```
3031

0 commit comments

Comments
 (0)