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

ActiveLibrary[Security](/categories/security)

jccp/vault
==========

v4.0.0(8y ago)0152GPL-3.0+PHPPHP &gt;=7.0

Since Jun 5Pushed 8y ago1 watchersCompare

[ Source](https://github.com/jccpdev/vault)[ Packagist](https://packagist.org/packages/jccp/vault)[ RSS](/packages/jccp-vault/feed)WikiDiscussions master Synced 2w ago

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

[![Build Status](https://camo.githubusercontent.com/f4ff396c78a75d98a95ef78793460dac9ddbce10ca59a97d68211708134d0f6e/68747470733a2f2f7472617669732d63692e6f72672f6a6363706465762f7661756c742e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/jccpdev/vault)

Vault SDK
=========

[](#vault-sdk)

Supports:

- auth
    - tokens
    - authrole
- general
    - read
    - write

Examples
--------

[](#examples)

### Configure Environment

[](#configure-environment)

The default client will leverage the environment variables `VAULT_ADDR` and `VAULT_TOKEN`

```
export VAULT_ADDR=http://localhost:8200
export VAULT_TOKEN=horde

```

### Read and Write Secrets

[](#read-and-write-secrets)

```
$secrets = [
	"foo" => "bar",
	"baz" => "boo",
];

$config = new DefaultVaultConfig('http://localhost:8200', new Tokens('horde'), '');

$vaultClient = new VaultClient(new Client());
$vaultClient->withConfig($config);
$vaultClient->write('secret/testing', $secrets);
$found = $vaultClient->read('secret/testing');

print_r($found['data']);

// Output:
// Array
// (
//     [baz] => boo
//     [foo] => bar
// )

```

### Login with AppRole

[](#login-with-approle)

```
$roleId = "...";
$secretId = "...";
$secrets = [
	"foo" => "bar",
	"baz" => "boo",
];

$vaultClient = new VaultClient(new Client());

$auth = new AppRole($vaultClient);
$auth->with('theRoleId', 'theSecretId');

$config = new DefaultVaultConfig('http://localhost:8200', $auth, '');

$vaultClient->withConfig($config);
$vaultClient->write('secret/testing', $secrets);

$found = $vaultClient->read('secret/testing');
print_r($found['data']);

// Output:
// Array
// (
//     [baz] => boo
//     [foo] => bar
// )

```

### Credit

[](#credit)

This is a fork of

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity62

Established project with proven stability

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

Total

6

Last Release

3210d ago

Major Versions

v2.1.0 → v3.0.02017-09-09

v3.1.0 → v4.0.02017-09-15

PHP version history (2 changes)2.1.x-devPHP &gt;=5.3

v3.0.1PHP &gt;=7.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3801193?v=4)[Juan Carlos](/maintainers/jccpdev)[@jccpdev](https://github.com/jccpdev)

---

Top Contributors

[![benschw](https://avatars.githubusercontent.com/u/98852?v=4)](https://github.com/benschw "benschw (21 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

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

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

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.2k532.1M2.5k](/packages/aws-aws-sdk-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k34](/packages/neuron-core-neuron-ai)[craftcms/cms

Craft CMS

3.6k3.6M2.9k](/packages/craftcms-cms)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M46](/packages/tencentcloud-tencentcloud-sdk-php)[tempest/framework

The PHP framework that gets out of your way.

2.2k31.1k12](/packages/tempest-framework)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

252.5k](/packages/eslazarev-wildberries-sdk)

PHPackages © 2026

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