PHPackages                             benxmy/laravel-dual-use-signed-url - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. benxmy/laravel-dual-use-signed-url

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

benxmy/laravel-dual-use-signed-url
==================================

Laravel Dual Use Signed URL

0.2.1(6y ago)010MITPHPPHP ^7.1

Since Nov 22Pushed 6y agoCompare

[ Source](https://github.com/benxmy/laravel-dual-use-signed-url)[ Packagist](https://packagist.org/packages/benxmy/laravel-dual-use-signed-url)[ Docs](https://github.com/benxmy/laravel-dual-use-signed-url)[ RSS](/packages/benxmy-laravel-dual-use-signed-url/feed)WikiDiscussions master Synced 6d ago

READMEChangelog (2)Dependencies (3)Versions (6)Used By (0)

Description
===========

[](#description)

This is a fork of [Laravel Single Use Signed URL](https://github.com/intellow/laravel-single-use-signed-url). This version allows two accesses to the generated URL. This package was created specifically for signed URLs that can be used as a temporary `src` url for media files. Due to the way browsers often handle these urls, the request will be made twice -- once for a preflight request and the second time for the actual file. This implementation allows for the url to be used twice in quick succession, but then the url will become unavailable. The url generated will only be available to the user who generates it and an expiration time can be set for the url usage. A future update will include the optional paramater of 'uses\_allowed' so the number of times the url is used can be set dynamically.

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require benxmy/laravel-dual-use-signed-url
```

Run `php artisan migrate` after you install.

Usage
-----

[](#usage)

I originally forked this from [Laravel Single Use Signed URL](https://github.com/intellow/laravel-single-use-signed-url) so I could make it more difficult for someone to actually access a direct download link for an embedded `src` attribute url. The original package is quite useful for single-use URLs for password resets, etc.

First create a route that accepts a {user} as a parameter and give it a name. For example:

```
Route::get('/play-media/{user}', [DualUseSignedUrlController::class, 'handle'])
->name('dual-use-url')
->middleware('validateDualUseSignedUrl');
```

The above route can be whatever you want really. The package will append the extra paramaeters in the background. For example, you could create a route like: `Route::get('/play-media/{user}/{media}', ...)`. However, you **must** include the `{user}` as the first parameter in the route.

Then in a controller you can generate a dual use signed url to this route with the following:

```
$url = DualUseSignedUrl::make('dual-use-url', $userId, $expiresInMinutes);
```

For my use (as the `src` attribute), I can then simply pass the `$url` to the view and use it in the audio or video tag.

### Testing

[](#testing)

Tests are not working right now.

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Credits
-------

[](#credits)

- This customization: [benxmy](https://github.com/benxmy)
- Original package by: [Intellow](https://github.com/intellow)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

Laravel Package Boilerplate
---------------------------

[](#laravel-package-boilerplate)

This package was generated using the [Laravel Package Boilerplate](https://laravelpackageboilerplate.com).

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~25 days

Total

4

Last Release

2290d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/20016973?v=4)[benxmy](/maintainers/benxmy)[@benxmy](https://github.com/benxmy)

---

Top Contributors

[![benxmy](https://avatars.githubusercontent.com/u/20016973?v=4)](https://github.com/benxmy "benxmy (8 commits)")[![intellow](https://avatars.githubusercontent.com/u/40676515?v=4)](https://github.com/intellow "intellow (2 commits)")

---

Tags

benxmylaravel-dual-use-signed-url

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/benxmy-laravel-dual-use-signed-url/health.svg)

```
[![Health](https://phpackages.com/badges/benxmy-laravel-dual-use-signed-url/health.svg)](https://phpackages.com/packages/benxmy-laravel-dual-use-signed-url)
```

###  Alternatives

[bezhansalleh/filament-shield

Filament support for `spatie/laravel-permission`.

2.8k2.9M88](/packages/bezhansalleh-filament-shield)[illuminate/auth

The Illuminate Auth package.

9327.3M1.0k](/packages/illuminate-auth)[olssonm/l5-very-basic-auth

Laravel stateless HTTP basic auth without the need for a database

1662.5M1](/packages/olssonm-l5-very-basic-auth)[stechstudio/laravel-jwt

Helper package that makes it easy to generate, consume, and protect routes with JWT tokens in Laravel

126117.6k](/packages/stechstudio-laravel-jwt)[scaler-tech/laravel-saml2

SAML2 Service Provider integration for Laravel applications, based on OneLogin toolkit

2737.5k](/packages/scaler-tech-laravel-saml2)[truckersmp/steam-socialite

Laravel Socialite provider for Steam OpenID.

1516.7k](/packages/truckersmp-steam-socialite)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
