Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.
Sign upinspector: added --inspect-publish-uid #27741
Conversation
ak239
requested a review
from eugeneo
May 16, 2019
This comment has been minimized.
This comment has been minimized.
nodejs-github-bot
added
C++
lib / src
labels
May 16, 2019
ak239
added
the
inspector
label
May 16, 2019
eugeneo
reviewed
May 17, 2019
src/inspector_socket_server.cc Outdated
eugeneo
requested changes
May 17, 2019
src/inspector_io.h Outdated
src/inspector_socket_server.cc Outdated
src/inspector_socket_server.cc Outdated
ak239
force-pushed the
ak239:inspect-publish-uid
branch
2 times, most recently
from
379d809
to
5070b54
May 17, 2019
This comment has been minimized.
This comment has been minimized.
|
I addressed comments and added another option - |
addaleax
reviewed
May 17, 2019
src/node_options.cc Outdated
src/inspector_js_api.cc Outdated
This comment has been minimized.
This comment has been minimized.
IMHO, that's unnecessary. Code that can access inspector API can already do pretty much anything. |
eugeneo
approved these changes
May 17, 2019
|
Approved modulo other review comments. |
ak239
force-pushed the
ak239:inspect-publish-uid
branch
from
5070b54
to
d48d6b4
May 17, 2019
This comment has been minimized.
This comment has been minimized.
I removed |
This comment has been minimized.
This comment has been minimized.
I think that would warrant more discussions. I do not see utility of disabling the bindings. It would not help with the security (JS bindings are only accessible from inside the Node runtime). My main concern is that people would disable JS bindings "for security" and end up confused why some ecosystem tools stop working. |
ak239
force-pushed the
ak239:inspect-publish-uid
branch
from
d48d6b4
to
177866f
May 18, 2019
This comment has been minimized.
This comment has been minimized.
Imagine for a second compromised In general if I can inject some code to Node process using compromised dependency or some other way, I get access to part of JS heap but not to everything. As soon as I can use inspector in this snippet - I get access to everything.
If people need some tool to work then they need to allow inspection. And some ecosystem tool can easily check that inspection flag was not passed and ask user to pass it - it is not a big deal. |
benjamingr
approved these changes
May 30, 2019
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
I need to fix a test first. |
Trott
added
the
blocked
label
Jun 1, 2019
This comment has been minimized.
This comment has been minimized.
OK, thanks! I've added the |
ak239
force-pushed the
ak239:inspect-publish-uid
branch
from
177866f
to
7129b9e
Jun 3, 2019
This comment has been minimized.
This comment has been minimized.
ak239
force-pushed the
ak239:inspect-publish-uid
branch
from
7129b9e
to
106f4bf
Jun 3, 2019
This comment has been minimized.
This comment has been minimized.
ak239
force-pushed the
ak239:inspect-publish-uid
branch
from
106f4bf
to
ccc51ca
Jun 3, 2019
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
ak239
removed
the
blocked
label
Jun 3, 2019
This comment has been minimized.
This comment has been minimized.
|
Landed in f0018a5 |
ak239
closed this
Jun 3, 2019
ak239
added a commit
that referenced
this pull request
Jun 3, 2019
BridgeAR
added a commit
that referenced
this pull request
Jun 17, 2019
BridgeAR
reviewed
Jun 20, 2019
| @@ -980,6 +987,7 @@ Node.js options that are allowed are: | |||
| - `--inspect` | |||
| - `--inspect-brk` | |||
| - `--inspect-port` | |||
| - `--inspect-publish-uid` | |||
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Should this actually be semver-minor? |
BridgeAR
added
the
semver-minor
label
Jun 20, 2019
ak239
deleted the
ak239:inspect-publish-uid
branch
Jun 20, 2019
ak239
restored the
ak239:inspect-publish-uid
branch
Jun 20, 2019
This comment has been minimized.
This comment has been minimized.
|
@BridgeAR this pull request does not change default behavior so I believe we do not need |
This comment has been minimized.
This comment has been minimized.
|
@ak239 if it would change the default, I'd expect it to be semver-major? We normally declare all new features as semver-minor. |
This comment has been minimized.
This comment has been minimized.
|
@BridgeAR I see, thank you for clarification. It is new feature so |
ak239 commentedMay 16, 2019
•
edited
This flag specifies how inspector websocket url should be exposed.
Supported options:
url,
require('inspector').url().Related discussion: nodejs/diagnostics#303
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes