PHPackages                             etics/phpseclib-bundle - 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. etics/phpseclib-bundle

ActiveLibrary[Security](/categories/security)

etics/phpseclib-bundle
======================

PHP Secure Communications Library - Pure-PHP implementations of RSA, AES, SSH2, SFTP, X.509 etc. Created By Jim Wigginton and Modified to be a Symfony2 Bundle.

026PHP

Since Mar 2Pushed 10y ago1 watchersCompare

[ Source](https://github.com/eticsGitHub/PhpseclibBundle)[ Packagist](https://packagist.org/packages/etics/phpseclib-bundle)[ RSS](/packages/etics-phpseclib-bundle/feed)WikiDiscussions master Synced 4w ago

READMEChangelogDependenciesVersions (1)Used By (0)

PhpseclibBundle - PHP Secure Communications Library modified to be a Symfony2 Bundle
====================================================================================

[](#phpseclibbundle---php-secure-communications-library-modified-to-be-a-symfony2-bundle)

PHP Secure Communications Library - Pure-PHP implementations of RSA, AES, SSH2, SFTP, X.509 etc. Created By Jim Wigginton and Modified to be a Symfony2 Bundle.

This Fork fixes some bugs in the original repository.

MIT-licensed pure-PHP implementations of an arbitrary-precision integer arithmetic library, fully PKCS#1 (v2.1) compliant RSA, DES, 3DES, RC4, Rijndael, AES, SSH-1, SSH-2, SFTP, and X.509

### Step 1: Download phpseclib-bundle using composer

[](#step-1-download-phpseclib-bundle-using-composer)

Add FOSUserBundle in your composer.json:

```
{
    "require": {
        ...
        "etics/phpseclib-bundle": "dev-master"
        ...
    }
}
```

Now tell composer to download the bundle by running the command:

```
$ php composer.phar update etics/phpseclib-bundle
```

or

```
$ composer update etics/phpseclib-bundle
```

Composer will install the bundle to your project's `vendor/sinner` directory.

### Step 2: Activate PHPSecLibBundle in you Symfony2 Project

[](#step-2-activate-phpseclibbundle-in-you-symfony2-project)

Edit the appKernel.php file in the $bundles array area:

```
    //"app/appKernel.php"
    ...
    $bundles = array(
	...
	new Sinner\Phpseclib\PhpseclibBundle();
	...
    );
    ...
```

### Step 3: Encrypt, Decrypt and Enjoy

[](#step-3-encrypt-decrypt-and-enjoy)

Suppose that you have a User Entity...

```
    /**
     * Entity/Usuario.php
     * */

    class Usuario {

        public $id;

        public $nombre;

        public $apellido;

        public $email;

        public $twitter;

    }
```

... and you want to save the User data on Encrypted Way (For example in a Session) from your Controller

```
    /**
     * Controller/DefaultController.php
     * */

    use Sinner\Phpseclib\Crypt\Crypt_TripleDES as TripleDES;

    Class DefaultController extends Controller{

        public fucntion indexAction(){

             //...

            $usuario_obj = new Usuario();
            $usuario_obj->id = 1;
            $usuario_obj->nombre = 'Jos&eacute; Gabriel';
            $usuario_obj->apellido = 'Gonz&aacute;lez P&eacute;rez';
            $usuario_obj->email = 'jgabrielsinner10@gmail.com';
            $usuario_obj->twitter = '@JGabrielTupac';

            const KEY_ENCRYPT = '548c286a61462d896573567b7a30335d4959427e5c7a675e325b6c7a7c';

            $_KEY_ENCRYPT = KEY_ENCRYPT;

            $encrypter = new TripleDES();
            $encrypter->setKey($_KEY_ENCRYPT);
            $usuario_obj_encrypt = $encrypter->encrypt(serialize($usuario_obj));
            $usuario = unserialize($encrypter->decrypt($usuario_obj_encrypt));

            var_dump($usuario_obj_encrypt);

            var_dump($usuario);

            //...

        }

    }

```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

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

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/etics-phpseclib-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/etics-phpseclib-bundle/health.svg)](https://phpackages.com/packages/etics-phpseclib-bundle)
```

###  Alternatives

[mews/purifier

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

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

PHP Elliptic Curve Cryptography library

24820.0k36](/packages/paragonie-ecc)

PHPackages © 2026

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