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

Clear Session Storage from Anonymous User Access #164244

Closed
Tracked by #168126
Martim-Sensefinity opened this issue Aug 18, 2023 · 5 comments
Closed
Tracked by #168126

Clear Session Storage from Anonymous User Access #164244

Martim-Sensefinity opened this issue Aug 18, 2023 · 5 comments
Labels
enhancement New value added to drive a business result Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more!

Comments

@Martim-Sensefinity
Copy link

When using the feature of the anonymous user I would expect that the cookie dashboardStateManagerPanels to not be stored on the session storage.

When using an embedded dashboard with an anonymous user, I want the dashboard filters (the control ones!) to be cleared every time I access the dashboard.

@botelastic botelastic bot added the needs-team Issues missing a team label label Aug 18, 2023
@jsanz jsanz added Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! enhancement New value added to drive a business result labels Aug 31, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-security (Team:Security)

@botelastic botelastic bot removed the needs-team Issues missing a team label label Aug 31, 2023
@azasypkin azasypkin added the Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas label Sep 1, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@ThomThomson
Copy link
Contributor

We currently aren't prioritizing issues relating to the Dashboard embed mode, so I'm going to add this to the icebox.

That said, you can ensure that the filters are always reset on load by adding filters into the _a param of the Dashboard URL. You can see the format by:

  1. Add a filter to a saved dashboard
  2. Don't save the dashboard
  3. Click share -> get links -> snapshot -> get URL

Then you'll have a URL with the filters inside it. This will always override the state from dashboardStateManagerPanels

@ThomThomson ThomThomson closed this as not planned Won't fix, can't repro, duplicate, stale Sep 1, 2023
@Martim-Sensefinity
Copy link
Author

Hi!

The _a solution works for these filters:

image

But not for these types of filters (that are added by the user when using the dashboard):

image

Use Case: I use the anonymous user to embed dashboards on another website, The user adds filters and leaves that page, and when we comes back the filters are still applied, I was not expecting that to be the case with the anonymous feature.

@ThomThomson
Copy link
Contributor

Hi @Martim-Sensefinity, you should be able to do the same process to get the Control selection in the URL.

  1. Make the Control selections you'd like to show up by default
  2. Add any filter pills you'd like to show up by default
  3. Don't save the Dashboard
  4. Click share -> get links -> snapshot -> get URL

Then you'll have a URL with both the filters and the controls selections. You can serialize this into your iframe.

You can follow this process for anything you'd like to override the session storage.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New value added to drive a business result Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more!
Projects
None yet
Development

No branches or pull requests

5 participants