-
Notifications
You must be signed in to change notification settings - Fork 14
Implement redacting of fields for MPA, apply it to httpoverrpc #562
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
base: main
Are you sure you want to change the base?
Conversation
@@ -106,7 +106,6 @@ allow { | |||
|
|||
# Allow MPA setting when not sending a proxied identity. The proxy is allowed above. | |||
allow { | |||
not input.metadata["proxied-sansshell-identity"] |
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.
could you also update
sansshell/services/mpa/README.md
Line 81 in 4777f2e
If you use OPA for authz, you'll also need to update the server's rego policies to reject requests that unexpectedly set `proxied-sansshell-identity` metadata if it allows callers other than the proxy to make direct calls. If you fail to do so, a direct caller can manipulate the metadata to approve their own request. For example, the policy below will reject calls if proxied identity information is in the metadata and the caller is something other than a peer with an identity of `"proxy"`. |
Another q: after this change, the MPA approval will be valid for any requests to the same {hostname, port, tlsconfig, and protocol} correct?
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.
Sorry, I got this just for testing purposes in place, we shouldn't merge this change to default policy.
Re the second point, indeed the MPA for httpoverrpc
will become valid after this change for all combination of {hostname, port, tlsconfig, and protocol}
, after a debate on what are meaningful levels of authz policy for MPA here we ended up saying that for httpoverrpc
current MPA of each request does not make much sense.
@@ -0,0 +1,27 @@ | |||
/* Copyright (c) 2019 Snowflake Inc. All rights reserved. |
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.
update copyright year
Currently httpoverrpc is unusable with MPA as every single request need to be separately approved. This change ignores requests to the server while constructing MPA.