PHPackages                             mdma4d/laravel-vault - 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. mdma4d/laravel-vault

ActiveLibrary[Security](/categories/security)

mdma4d/laravel-vault
====================

Laravel HashiCorp Vault integration (secrets, database dynamic creds, encryption, hashing)

v1.1.0(1y ago)0120MITPHP

Since Sep 15Pushed 11mo ago1 watchersCompare

[ Source](https://github.com/mdma4d/laravel-vault)[ Packagist](https://packagist.org/packages/mdma4d/laravel-vault)[ RSS](/packages/mdma4d-laravel-vault/feed)WikiDiscussions main Synced 1mo ago

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

Simple Laravel configuration from Hashicorp Vault.
==================================================

[](#simple-laravel-configuration-from-hashicorp-vault)

Installation
============

[](#installation)

### Add the package via composer

[](#add-the-package-via-composer)

```
composer require mdma4d/laravel-vault

```

Usage with Laravel
------------------

[](#usage-with-laravel)

### Add the Service Provider

[](#add-the-service-provider)

Add the following to the `providers` array in your application config:

```
Mdma4d\Vault\VaultServiceProvider::class,

```

### Configure Hashicorp Vault

[](#configure-hashicorp-vault)

Create approle to access Hashicorp Vault.

Create KV secrets engine with laravel configuration

```
{
  "app": {
    "key": "base64:cYrLP5mFSK1S5P1OQwk3tA16x2Uwkzf8Wxb5azBhcdE="
  },
  "database.connections.mysql": {
    "database": "laravel",
    "host": "mysql"
  },
  "hashing": {
    "driver": "vault",
    "old": "bcrypt"
  }
}

```

app.key contains old app key to decrypt old cryptograms

Create transit engine for encryption and hashing

Create databases engine, connection and role to connect to mysql

### Set the environment variables

[](#set-the-environment-variables)

```
VAULT_ADDR=https://vault:8200
VAULT_ROLE_ID=14c64adb-80ff-1d90-da6a-9f991a76b5e0
VAULT_SECRET_ID=a3ba16c5-aec1-965b-e5b3-360acad8b799
VAULT_CONFIG=/v1/kv/laravel
VAULT_TRANSIT_PATH=/v1/laravel
VAULT_TRANSIT_KEY=key
VAULT_DATABASE=/v1/database/creds/laravel

```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance47

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity40

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 ~148 days

Total

2

Last Release

461d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/bb75d353c35176df76940c2d4ce572405168ddc31c34eb470a2b5c12273254f5?d=identicon)[mdma4d](/maintainers/mdma4d)

---

Top Contributors

[![mdma4d](https://avatars.githubusercontent.com/u/13422531?v=4)](https://github.com/mdma4d "mdma4d (5 commits)")

### Embed Badge

![Health badge](/badges/mdma4d-laravel-vault/health.svg)

```
[![Health](https://phpackages.com/badges/mdma4d-laravel-vault/health.svg)](https://phpackages.com/packages/mdma4d-laravel-vault)
```

###  Alternatives

[akaunting/laravel-firewall

Web Application Firewall (WAF) package for Laravel

999465.8k2](/packages/akaunting-laravel-firewall)[masterro/laravel-xss-filter

Filter user input for XSS but don't touch other html

41254.5k](/packages/masterro-laravel-xss-filter)[nickurt/laravel-pwned-passwords

PwnedPasswords for Laravel 11.x/12.x/13.x

187.5k](/packages/nickurt-laravel-pwned-passwords)[potelo/laravel-block-bots

Block bots and high traffic offenders using Redis

5514.0k](/packages/potelo-laravel-block-bots)

PHPackages © 2026

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