PHPackages                             anton-panfilov/cryptographer - 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. anton-panfilov/cryptographer

ActiveLibrary[Security](/categories/security)

anton-panfilov/cryptographer
============================

1.0.0(1y ago)041MITPHPPHP ^8.3

Since Dec 31Pushed 1y ago1 watchersCompare

[ Source](https://github.com/anton-panfilov/cryptographer)[ Packagist](https://packagist.org/packages/anton-panfilov/cryptographer)[ Docs](https://github.com/anton-panfilov/cryptographer)[ RSS](/packages/anton-panfilov-cryptographer/feed)WikiDiscussions main Synced today

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

The Cryptographer
=================

[](#the-cryptographer)

Generate the passphrase once and save it securely in your configuration
-----------------------------------------------------------------------

[](#generate-the-passphrase-once-and-save-it-securely-in-your-configuration)

> **IMPORTANT:** Ensure this passphrase is stored in a secure location (e.g., environment variables, secrets manager)

### PHP:

[](#php)

```
$algo       = "aes-256-cfb";
$key_length = openssl_cipher_key_length();
$passphrase = openssl_random_pseudo_bytes($key_length);

// if you're planing to save this to the environment, better to make base64
$passphrase_base64 = base64_encode($passphrase);
```

### Bash:

[](#bash)

```
echo $(openssl rand -base64 32)
```

Use cases:
----------

[](#use-cases)

AlgorithmIntegrity CheckOverheadUsage Example[**AES-256-GCM**](docs%2Faes-256-gcm.md)✅ Yes16-28 bytes, IV 12 bytes + Tag 4-12 bytesEncrypting sensitive messages where data integrity is critical, e.g., API tokens.
Storing sensitive configuration data with integrity protection.
Optional authenticated additional data (AAD), not included in ciphertext but verified.[**AES-256-CFB**](docs%2Faes-256-cfb.md)❌ No16 bytes, IV onlyStreaming data encryption where low latency is required, e.g., video streaming.

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance38

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity53

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

Unknown

Total

1

Last Release

549d ago

### Community

Maintainers

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

---

Top Contributors

[![anton-panfilov](https://avatars.githubusercontent.com/u/1083546?v=4)](https://github.com/anton-panfilov "anton-panfilov (6 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/anton-panfilov-cryptographer/health.svg)

```
[![Health](https://phpackages.com/badges/anton-panfilov-cryptographer/health.svg)](https://phpackages.com/packages/anton-panfilov-cryptographer)
```

###  Alternatives

[mews/purifier

Laravel 5/6/7/8/9/10 HtmlPurifier Package

2.0k18.7M143](/packages/mews-purifier)[paragonie/ecc

PHP Elliptic Curve Cryptography library

24820.0k37](/packages/paragonie-ecc)

PHPackages © 2026

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