PHPackages                             opqnext/xor-encryption - 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. opqnext/xor-encryption

ActiveLibrary[Security](/categories/security)

opqnext/xor-encryption
======================

php xor-encryption

v1.0.1(8y ago)3562MITPHPPHP &gt;=5.3.0

Since Aug 18Pushed 8y ago1 watchersCompare

[ Source](https://github.com/opqnext/XorEncryption)[ Packagist](https://packagist.org/packages/opqnext/xor-encryption)[ RSS](/packages/opqnext-xor-encryption/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (2)Used By (0)

XorEncryption(异或加密)
===================

[](#xorencryption异或加密)

> XorEncryption(异或加密)

- 使用方法(1)

使用默认 key \[opqnext\] 进行加密解密。

```
require 'vendor/autoload.php';

// 实例化类
$xor = new XorEncryption\XorEncryption();

// 要加密的字符串
$str = "opqnext";

// XOR加密
$secret = $xor->encode($str);
echo $secret."\n";

// XOR解密
$str = $xor->decode($secret);
echo $str."\n";

```

- 使用方法(2)

使用自定义 key 进行加密解密。

```
require 'vendor/autoload.php';

$key = "2fc2b4aaa8d087af4d6dc085f3316c0a";

// 实例化类
$xor = new XorEncryption\XorEncryption($key);

// 要加密的字符串
$str = "opqnext";

// XOR加密
$secret = $xor->encode($str);
echo $secret."\n";

// XOR解密
$str = $xor->decode($secret);
echo $str."\n";

```

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity58

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

3238d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/13477243?v=4)[郭贰小姐](/maintainers/opqnext)[@opqnext](https://github.com/opqnext)

---

Top Contributors

[![opqnext](https://avatars.githubusercontent.com/u/13477243?v=4)](https://github.com/opqnext "opqnext (1 commits)")

---

Tags

phpxor

### Embed Badge

![Health badge](/badges/opqnext-xor-encryption/health.svg)

```
[![Health](https://phpackages.com/badges/opqnext-xor-encryption/health.svg)](https://phpackages.com/packages/opqnext-xor-encryption)
```

###  Alternatives

[stymiee/php-simple-encryption

The PHP Simple Encryption library is designed to simplify the process of encrypting and decrypting data while ensuring best practices are followed. By default is uses a secure encryption algorithm and generates a cryptologically strong initialization vector so developers do not need to becomes experts in encryption to securely store sensitive data.

438.8k](/packages/stymiee-php-simple-encryption)[ukrbublik/openssl_x509_crl

Missing OpenSSL function on PHP to create CRL (certificate revocation list) for CA

182.1k](/packages/ukrbublik-openssl-x509-crl)

PHPackages © 2026

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