Skip to content
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

Handling auditing errors out of our control #199

Open
amstilp opened this issue Oct 13, 2022 · 1 comment
Open

Handling auditing errors out of our control #199

amstilp opened this issue Oct 13, 2022 · 1 comment

Comments

@amstilp
Copy link
Contributor

amstilp commented Oct 13, 2022

In some cases, the AnVIL team adds their own people or groups to our resources (e.g., groups, workspace sharing, etc). How do we want to handle this?

  • Create an equivalent record in Django (e.g., sharing with the anvil-admins group)? Likely this would need to be done manually from the admin interface.
  • Implement a way to ignore certain records (e.g., if an AnVIL dev created a workspace, they may be marked an owner. This is ok and we don't want the record in the app). The audit could report the "ignored" resources but not consider them errors.
@amstilp
Copy link
Contributor Author

amstilp commented Mar 3, 2023

After discussing with @smgogarten, for the second bullet (if we end up implementing this instead of just removing them):

  • Add a new model with two fields, workspace and EmailField. This model tracks which emails to ignore when auditing sharing records for a given workspace. This table should only be populated via the Admin interface, so no extra views are necessary.
  • Modify the Workspace.audit_sharing() method to ignore any emails in this table.
  • Modify AnVILAuditResults classes to handle ignored records - they should be tracked but reported as ignored.
  • Modify audit views to show ignored records but not mark them as errors.
  • Modify run_anvil_audit command to report ignored records only if --errors-only is not passed.
  • Make sure to add tests for case-insensitivity etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant