-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add context to "tsh ls" in docs #12583
Conversation
docs/pages/includes/node-logins.mdx
Outdated
@@ -0,0 +1,30 @@ | |||
When Teleport's Auth Service receives a request to list Teleport Nodes (e.g., to | |||
display Nodes in the Web UI or via `tsh ls`), it only returns the Nodes that the | |||
current user is authorized to access. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: I would say "see" (or analogue) instead of "access" because you can see the node but still have not permissions to access it if allowed logins don't allow it.
current user is authorized to access. | |
current user is authorized to see. |
docs/pages/includes/node-logins.mdx
Outdated
|
||
{/* | ||
|
||
TODO: We might want to mention that the Auth Service checks the resource's |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Namespaces are basically not used at all in Teleport. All resources always have default
namespace and I don't think this will ever change TBH. So I think this "todo" item won't ever get resolved so we may as well just remove it. But it's up to you if you want to keep it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks—I'll delete this TODO. I think #12580 can be resolved by deleting all references to Teleport namespaces in the docs (looks like there are a couple of --namespace
mentions in the CLI reference, but I don't think anything beyond that)
docs/pages/includes/node-logins.mdx
Outdated
TODO: We might want to mention that the Auth Service checks the resource's | ||
namespace as well, but we currently do not document resource namespaces. | ||
This would not be the appropriate place to include our only namespace | ||
documentation. See gravitational/teleport issue #12580. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you still intend to keep this "todo" item, just paste a link to the issue.
docs/pages/includes/node-logins.mdx
Outdated
|
||
*/} | ||
|
||
- None of the user's roles contains a `deny` rule that matches the Node's labels. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
English grammar question: is "contains" the correct form here, or should it say "contain"? :) I'd think that "none of the roles contain" is more correct cause it's plural but I may be mistaken.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From what I've read, "none" can be singular or plural, and there's no good rule for this. It probably would sound better as "contain," though.
docs/pages/includes/node-logins.mdx
Outdated
*/} | ||
|
||
- None of the user's roles contains a `deny` rule that matches the Node's labels. | ||
- None of the user's roles contains a `deny` rule that matches the user's |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I may be misunderstanding what this is referring to, but I'm not sure this applies to listing nodes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was attempting to paraphrase RoleSet.CheckAccess
, which looks like it would check if one of the matchers
, which I thought would be a services.loginMatcher
in the case of a Node, matches a deny
rule.
`traits.logins`. | ||
- At least one of the user's roles contains an `allow` rule that matches the | ||
Node's labels. | ||
- At least one of the user's roles contains an `allow` rule that matches the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think mentioning traits makes it a bit more confusing. I would just say that at least one of user's roles has allowed logins for the node. Traits aren't really relevant in this context I think.
c228584
to
3315501
Compare
ae36e4a
to
d83f7f9
Compare
d83f7f9
to
9dc4dee
Compare
9dc4dee
to
59cfa81
Compare
Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output.
59cfa81
to
a7fb9d1
Compare
Backports #12583 * Add context to "tsh ls" in docs Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output. * Respond to PR feedback
Backports #12583 * Add context to "tsh ls" in docs Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output. * Respond to PR feedback
Backports #12583 * Add context to "tsh ls" in docs Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output. * Respond to PR feedback
Add context to "tsh ls" in docs Backports #12583 * Add context to "tsh ls" in docs Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output. * Respond to PR feedback
Backports #12583 * Add context to "tsh ls" in docs Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output. * Respond to PR feedback
Add context to "tsh ls" in docs Backports #12583 * Add context to "tsh ls" in docs Fixes #7051 - Create a partial for how the Teleport Auth Service filters Nodes based on user roles/logins in response to queries. - Add the partial to provide context for example commands that include "tsh ls". - Make our existing text on Teleport's authorization checks clearer by enumerating the checks in the order they are executed in services.RoleSet.CheckAccess. Note that this does not change guides that instruct the user to create a new user and role, since a user following these guides will see the correct "tsh ls" output. * Respond to PR feedback
Fixes #7051
based on user roles/logins in response to queries.
"tsh ls".
by enumerating the checks in the order they are executed in
services.RoleSet.CheckAccess.
Note that this does not change guides that instruct the user to create
a new user and role, since a user following these guides will see the
correct "tsh ls" output.