-
Notifications
You must be signed in to change notification settings - Fork 2
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
chore: adjust row and column access permissions in Hasura #4220
Conversation
🤖 Hasura Change Summary compared a subset of table metadata including permissions: Updated Tables (4)
|
Removed vultr server and associated DNS entries |
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.
A few things I think we need to roll back here and explain to the pen testers in terms of our data model.
The changes for feedback and submissions are correct and ones we've missed though 👍
GetUsersForTeam
Added row-level "select" permissions for both teamEditor & demoUser roles, toggled all columns (any reason no one was allowed to "select"
staging_only
before?)
staging_only
was just unchecked because it wasn't used - just used in the API in one place. We can allow access (or not) dependant on permissions - it's not a sensitive field.
I believe this was intentional that anybody logged in could access users - we call this table in order to populate the "last edited by" text in a few places.
I think it's totally fine for our permission model that any logged in user can access the firstName and lastName of all users (as they can view their flows, edits, etc).
GetTeamBySlug
I think this was right as it was - it's possibly not been understood by the pen testers how our multi-tenancy works. teamEditor
users should be able to select other teams.
GetTeamSettings
This was already correct I believe and should match the public
role - the only slightly sensitive column is submission_email
. I don't think this is an issue for logged in users realistically, but we could move this to team_integrations
to properly limit it.
GetFlow
This is and should be public ✅ Good question re:new readme columns - happy to leave as-is for now for simplicity and turn on when we need them but no strong opinions.
Co-authored-by: Dafydd Llŷr Pearson <[email protected]>
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.
Great thanks! Will sum things up and email pen testers back tomorrow morning once I've re-tested all on staging 👍
Co-authored-by: Dafydd Llŷr Pearson <[email protected]>
Per audit feedback:
GetSubmissions
$api
role so unchanged)submission_services_log
view which previously did not have row-level permissions configuredteam_id
, established "relationship" toteams
, added row-level permissions for bothteamEditor
&demoUser
rolesGetFeedbackForFlow
$api
role so unchanged)feedback_summary
view which DID have row-level permissions configured alreadyFollowing changes are rolled back per PR feedback / comments below:
GetUsersForTeam
$api
role so unchanged)users
table which does not have row-level permissions configuredteamEditor
&demoUser
roles, toggled all columns (any reason no one was allowed to "select"staging_only
before?)GetTeamBySlug
teams
with relationship tothemes
andsettings
teams
does not have row-level "select" permissions configured for theteamEditor
role - these are now addedteam_themes
has full select-all access across rows and row-level "update" permissions already - I think this is correctteam_settings
handled in point belowGetTeamSettings
team_settings
table which does not have row-level "select" permissions configured (only "update")teamEditor
&demoUser
rolesGetFlow
flows
table which only has row-level permissions configured fordemoUser
templated_from
,description
) - do we want this or select-all ?Future todo: