PHPackages                             goldbach-algorithms/mask - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. goldbach-algorithms/mask

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

goldbach-algorithms/mask
========================

Mascarador de valores PHP

1.5.2(3y ago)14901MITPHP

Since Oct 25Pushed 3y agoCompare

[ Source](https://github.com/GoldbachAlgorithms/Mask)[ Packagist](https://packagist.org/packages/goldbach-algorithms/mask)[ RSS](/packages/goldbach-algorithms-mask/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (10)DependenciesVersions (15)Used By (1)

Mask
====

[](#mask)

[![](https://camo.githubusercontent.com/9a175a4f892195cd2ca21501d99e63aca89e0bb10c641d2ac5104496fa02b9e1/68747470733a2f2f62616467656e2e6e65742f62616467652f506f776572656425323062792f4775737461766f204d65737365722f726564)](https://github.com/Goldbach07/)[![](https://camo.githubusercontent.com/49c474f4d41e6571226a814e675889a0569e975426152fc074ca08feffdc2768/68747470733a2f2f62616467656e2e6e65742f62616467652f446576656c6f706564253230666f722f5048502f626c7565)](https://www.php.net/)[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://opensource.org/licenses/MIT)

Goldbach Algorithms Mask (old repository) is a PHP library developed for Symfony for apply a mask to values.

Installation
------------

[](#installation)

Use the composer to install:

```
composer require messer/mask
```

Usage
-----

[](#usage)

It is possible to mask a string to one of the default settings or create a customization from the custom() method.

```
# add use Mask
use GoldbachAlgorithms\Mask\Mask;

# create a new mask
$mask = new Mask();

# returns '89566-410'
$mask->cep('89566410');

# returns '198.298.398-98'
$mask->cpf('19829839898');

# returns '03.635.359/0001-23'
$mask->cnpj('3635359000123');

# returns '12.345.678-9'
$mask->rg('123456789');

# returns '4321.****.****.1234'
$mask->creditCard('4321544534421234');

# returns '(11) 3227-3158'
$mask->phone('1132273158');

# returns '(21) 99943-2343'
$mask->phone('21999432343');

# returns '18/03/1690'
$mask->custom('18031690','##/##/####');
```

License
-------

[](#license)

[MIT](https://choosealicense.com/licenses/mit/)

Copyright © 2023 [Goldbach Algorithms](https://github.com/GoldbachAlgorithms/Mask/blob/main/LICENSE)

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community10

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

Every ~43 days

Recently: every ~140 days

Total

14

Last Release

1101d ago

### Community

Maintainers

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

---

Top Contributors

[![Goldbach07](https://avatars.githubusercontent.com/u/13986904?v=4)](https://github.com/Goldbach07 "Goldbach07 (18 commits)")

---

Tags

cepcnpjcredit-carddocumentgoldbachmaskphonephprg

### Embed Badge

![Health badge](/badges/goldbach-algorithms-mask/health.svg)

```
[![Health](https://phpackages.com/badges/goldbach-algorithms-mask/health.svg)](https://phpackages.com/packages/goldbach-algorithms-mask)
```

###  Alternatives

[xefi/faker-php-locales-fr-fr

Faker extension to include fr\_FR locale

2310.7k](/packages/xefi-faker-php-locales-fr-fr)

PHPackages © 2026

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