title: How can I prevent a user change some of the parameters of a standalone dashboard in Apache Superset?
body: <p>I'm trying to <strong>embed</strong> a <strong>standalone</strong> Apache Superset dashboard in another application via <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe" rel="nofollow noreferrer">IFRAME</a>.</p>
  <p>First I managed to have a standalone dashboard by adding <code>&amp;standalone=1</code> to the URL.</p>
  <p>Then I managed to use <code>{{ url_param('custom_parameter') }}</code> macro to pass values to dashboard so that it became <strong>parametric</strong>, changing what it shows based on values passed via URL parameters.</p>
  <p>Then I managed to create a <code>CustomSecurityManager</code> so that I can automatically log in a user, and do some security checks and prevent logging in if credentials aren't correct.</p>
  <p>But in my use case, the system must also prevent that standalone dynamic dashboard user from changing the values of some parameters.</p>
  <p>How can I customize the behavior of Apache Superset, so that it has the following effect?</p>
  <ul>
  <li>If the requested dashboard is X, and the <code>{{ current_user_id() }}</code> is Y, and if <code>{{ url_param('custom_parameter') }}</code> value is <em><strong>different</strong></em> from <code>SOME_VALUE</code>, then <strong>don't show the dashboard</strong>, given an error, etc.</li>
  </ul>
  <p>apart from a brief mention of &quot;Middleware&quot; in <a href="https://superset.apache.org/docs/installation/networking-settings/" rel="nofollow noreferrer">https://superset.apache.org/docs/installation/networking-settings/</a>, I couldn't fine any example that could be helpful.</p>
  <p>Any ideas?</p>