Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 11 Next »

Goal

This article provides information about the functionality, configuration and workflow behind the filter by permissions feature of the Sitefinity connector.

Prerequisite

Configured Connector - Configure Hawksearch

Steps to configure filtering by Permissions

  1. Open the Sitefinity backend, create a user (your-site-domain/Sitefinity/Administration/Users)

  2. Assign that user a role by editting the user profile or by click Assign to role

  3. Edit the permission for that role so that the user cannot view a certain content type e.g News

  4. Go to Content and create one blog post and one news (your-site-domain/Sitefinity/adminapp/content/newsitems)

  5. Go to Administration → Search Indexes , create an index and reindex (your-site-domain/Sitefinity/Administration/Search)

  6. Create a Sitefinity page and open it for editting (your-site-domain/Sitefinity/adminapp/pages)

  7. Place the Hawksearch box and Hawksearch results widgets

  8. Open the widget designer of each widget and click the Filter by permissions checkbox

  9. Under Where to search choose the newly created index and save the changes

  10. Open the page in the Frontend and search for the news that was created

Filter by permissions workflow

When filtering is active the connector exposes endpoints for the search and autocomplete queries making it work as a proxy.

  1. Typing in the search box triggers the connector’s autocomplete endpoint, searching triggers the connector's search endpoint.

  2. A server-side call to the Hawksearch API is made which returns the results for that request.

  3. The user’s permissions are evaluated and used to filter the results server-side.

  4. After the filtering is completed the results are displayed to the user though the Hawksearch results widget.

By filtering the results on the server the request cannot be intercepted client-side therefore making sure the results cannot be seen before they were filtered.

  • No labels