Drupal is a registered trademark of Dries Buytaert
Release: Leaflet 10.4.11 Minor update available for module leaflet (10.4.11). Release: Session Inspector 1.0.8 Minor update available for module session_inspector (1.0.8). Release: Migrate QA 2.0.4 Minor update available for module migrate_qa (2.0.4). Release: CKEditor Description List 3.0.0 Major update available for module ckeditor_descriptionlist (3.0.0). Release: FlowDrop 2.4.0 Minor update available for module flowdrop (2.4.0). Release: JWT Token Refresh 1.0.4 Minor update available for module jwt_token_refresh (1.0.4). Release: ConReg 1.0.0-beta1 First beta version released for module conreg (1.0.0-beta1). Release: AI Image Studio 1.0.0-beta8 New beta version released for module ai_image_studio (1.0.0-beta8). Usage Milestone: Role Theme Switcher Module role_theme_switcher crossed 1,000 active installs. Module Revived: Decoupled Router 2.0.7 Module decoupled_router updated after 11 months of inactivity (2.0.7).

Private file token

339 sites Security covered
View on drupal.org

This module allows private files and images to be accessed by appending a time-limited authentication token to their URLs. This is particularly useful for decoupled sites that don't use cookies for authentication, as it provides a secure way to grant temporary access to private content.

Provides access to private files and images by injecting authentication token with a timestamp into their urls. Such a token will be validated when such url is accessed and in case of successful validation the access will be granted. Token is valid for certain period of time.

The intended use case is for decoupled sites which relies on non-cookie authentication. For example when the site uses JWT header authentication. Without a cookie the private files or images cannot be accessed because no form of authentication has been provided (the cookie is missing). This module solves this problem by introducing authentication via token, which is valid for a configurable amount of time.

Example of a private image url containing authentication token and timestamp:

https://example.site/system/files/styles/thumbnail/private/resume/photo/profile_image.png?token=rEezZ9fNlupFtiWb98lJlwct4jFz96987uJovl_c_Zs&timestamp=1605024462&itok=NxuIebsw

Token will be validated along with the timestamp and the path part of the image url. Parameter itok still exists in the url as it is required by Drupal to actually generate image style of the image.

Activity

Tracked releases
1
Tracked since
Jun 2026
Latest release
1 month ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Releases

Version Type Release date
1.0.1 Stable Jun 24, 2026