Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: OpenID Connect / OAuth client 3.0.0-alpha9 New alpha version released for module openid_connect (3.0.0-alpha9). Usage Milestone: Google Analytics Module google_analytics crossed 1,000 active installs. Release: Timelinr 1.0.1 Minor update available for module timelinr (1.0.1). Release: GraphQL Compose Codegen 1.1.2 Minor update available for module graphql_compose_codegen (1.1.2). Release: Mapy.com 1.1.3 Minor update available for module mapycom (1.1.3). Release: Ckeditor5 entity browser 3.0.3 Minor update available for module ckeditor5_entity_browser (3.0.3). Release: Ckeditor5 entity browser 3.0.1 Minor update available for module ckeditor5_entity_browser (3.0.1). Release: Ckeditor5 entity browser 3.0.2 Minor update available for module ckeditor5_entity_browser (3.0.2). Release: Teamleader Integration 4.0.2 Minor update available for module teamleader (4.0.2). Module Revived: Entityqueue Buttons 1.1.2 Module entityqueue_buttons updated after 8 months of inactivity (1.1.2).

Personal Access Restriction

181 sites Security covered Drupal 8–11
View on drupal.org

This module allows administrators to restrict access to specific content or taxonomy terms for individual users or user roles. It also provides options for how to handle denied access, such as returning an "Access denied" message or a "Page not found" error.

πŸ‡ΊπŸ‡¦

This module is maintained by Ukrainian developers.
Please consider supporting Ukraine in a fight for their freedom and safety of Europe.

Introduction

Personal Access Restriction module provides the ability to restrict access to a particular Node or Taxonomy Term by UID or User role.
Also, it provides the ability to select the type of response ("Access denied" or "Page not found").

To submit bug reports and feature suggestions, or track changes: https://www.drupal.org/project/issues/par

Getting Started

  1. Install Personal Access Restriction module (composer require drupal/par)
  2. Enable Personal Access Restriction module (drush en par)
  3. Set permissions for 'Configure all Personal Access Restrictions', 'Manage Personal Access Restriction' and 'View restricted pages' at /admin/people/permissions
  4. Add your access restrictions for any Node or Taxonomy term on their add/edit pages (you will see the 'Personal Access Restriction' collapsed container).
  5. Fill the User ID field to restrict access to an entity for particular users. You can set multiple UIDs separated by whitespace.
  6. Fill the Roles field in case if you want to restrict access to an entity for all users with some role.
  7. In the "How to show the page?" field you can set the access restriction type for this entity. Also, there is a default variant that you can use in case if you want just to select users or roles for further access restriction but do not want to restrict access right now.
  8. You can see a list of all restrictions at /admin/config/par. On this page you can filter access restrictions by Entity type, Entity ID, UID, User role and action.
  9. If you want to provide the ability to see restricted entities, you can add 'View restricted pages' permission to some User role at /admin/people/permissions#module-par. Users with the 'Administrator' role will see pages with restricted access in any case.

Requirements

No special requirements.

Installation

  • Install as you would normally install a contributed Drupal module.
    See: https://www.drupal.org/node/895232 for further information.
  • If you are using Composer you can install this module by the command:
    composer require drupal/par

Configuration

  • Configure the user permissions in Administration Β» People Β» Permissions:
    • Configure all Personal Access Restrictions (Personal Access Restriction)
    • Manage Personal Access Restriction (Personal Access Restriction)
    • View restricted pages (Personal Access Restriction)

The top-level administration categories require this permission to be accessible.

Maintainers

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
3
Tracked since
Dec 2024
Latest release
1 year ago
Releases (12 mo)
0 ▼ from 3
Maintenance
Dormant

Release Timeline

Releases

Version Type Core Release date
3.0.9 Stable 8–11 Jan 20, 2025
3.0.8 Stable 8–11 Jan 17, 2025
3.0.7 Stable 8–10 Dec 8, 2024