PHPackages                             tahaazare/secure-download - 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. [Security](/categories/security)
4. /
5. tahaazare/secure-download

ActiveLibrary[Security](/categories/security)

tahaazare/secure-download
=========================

Generate secure download links with expiration in Laravel

v1.0.1(9mo ago)06MITPHPPHP ^8.1

Since Jul 14Pushed 9mo agoCompare

[ Source](https://github.com/TahaaZare/secure-download)[ Packagist](https://packagist.org/packages/tahaazare/secure-download)[ RSS](/packages/tahaazare-secure-download/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

🔒 Laravel Secure Download | لینک دانلود امن در لاراول
=====================================================

[](#-laravel-secure-download--لینک-دانلود-امن-در-لاراول)

📖 Introduction | معرفی
----------------------

[](#-introduction--معرفی)

این پکیج به شما کمک می‌کند تا برای فایل‌های خود لینک دانلود **امن و موقت** تولید کنید.
به‌طوری‌که لینک فقط برای مدت مشخصی معتبر باشد (مثلاً ۳۰ ثانیه، ۵ دقیقه یا ۲ ساعت)
و فقط برای یک مسیر مشخص قابل استفاده باشد. همچنین برای اینکه محدودیت تعداد دانلود و اطلاعات لینک‌ها به درستی ذخیره شود،
باید پس از نصب پکیج دستور migrate را اجرا کنید تا جدول‌های لازم در دیتابیس ساخته شود.

This package helps you generate secure, temporary download links for your files in Laravel. Each link is valid for a specific time (e.g., 30 seconds, 5 minutes, or 2 hours) and is only usable for the given file path.

To track download limits and link information, you must run database migrations after installation to create the necessary table
--------------------------------------------------------------------------------------------------------------------------------

[](#to-track-download-limits-and-link-informationyou-must-run-database-migrations-after-installation-to-create-the-necessary-table)

📦 نصب | Installation
--------------------

[](#-نصب--installation)

1. Install the Package
----------------------

[](#1-install-the-package)

Run the following command in your Laravel project terminal:

```
composer require tahaazare/secure-download
```

2. Publish the Configuration File (Optional but Recommended)
------------------------------------------------------------

[](#2-publish-the-configuration-file-optional-but-recommended)

```
php artisan vendor:publish --provider="Tahaazare\SecureDownload\SecureDownloadServiceProvider"
```

The config file will be located at

```
config/secure-download.php
```

3. Migration
------------

[](#3-migration)

```
php artisan migrate
```

---

🛠 Generate Secure Download Link | ساخت لینک دانلود امن (Quick Usage)
--------------------------------------------------------------------

[](#-generate-secure-download-link--ساخت-لینک-دانلود-امن-quick-usage)

```
$link = SecureDownload::generate(
    'files/report.pdf',
    30,
    TimeUnitEnum::Seconds,
    FileTypeEnum::Storage,
    null, //int | max_downloads
);
```

###  Health Score

30

—

LowBetter than 65% of packages

Maintenance55

Moderate activity, may be stable

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

2

Last Release

299d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5272d3a5f85f8018f0f8b0d0aabb728d5d99c104c4dc9bd488ed20507a51ba6d?d=identicon)[TahaaZare](/maintainers/TahaaZare)

---

Top Contributors

[![TahaaZare](https://avatars.githubusercontent.com/u/81828931?v=4)](https://github.com/TahaaZare "TahaaZare (10 commits)")

### Embed Badge

![Health badge](/badges/tahaazare-secure-download/health.svg)

```
[![Health](https://phpackages.com/badges/tahaazare-secure-download/health.svg)](https://phpackages.com/packages/tahaazare-secure-download)
```

###  Alternatives

[illuminate/encryption

The Illuminate Encryption package.

9229.7M278](/packages/illuminate-encryption)[tzsk/otp

A secure, database-free One-Time Password (OTP) generator and verifier for PHP and Laravel.

241641.4k1](/packages/tzsk-otp)[genealabs/laravel-governor

Managing policy and control in Laravel.

201262.8k](/packages/genealabs-laravel-governor)[dgtlss/warden

A Laravel package that proactively monitors your dependencies for security vulnerabilities by running automated composer audits and sending notifications via webhooks and email

8745.6k](/packages/dgtlss-warden)[ercsctt/laravel-file-encryption

Secure file encryption and decryption for Laravel applications

642.6k](/packages/ercsctt-laravel-file-encryption)[laragear/poke

Keep your forms alive, avoid TokenMismatchException by gently poking your Laravel app

2211.5k](/packages/laragear-poke)

PHPackages © 2026

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