Skip to content

Commit e3a36bb

Browse files
committed
v1.0.0
1 parent eea670a commit e3a36bb

17 files changed

+44
-50
lines changed

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "tcloud.ax/password-entropy-bundle",
2+
"name": "phptcloud/password-entropy-bundle",
33
"description": "Symfony bundle for calculating password entropy",
44
"type": "symfony-bundle",
55
"license": "MIT",
@@ -19,7 +19,7 @@
1919
},
2020
"autoload": {
2121
"psr-4": {
22-
"PasswordEntropyBundle\\": "src/"
22+
"PHPTCloud\\PasswordEntropyBundle\\": "src/"
2323
}
2424
},
2525
"require-dev": {

docs/usage.md

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,8 @@
44

55
```php
66
<?php
7-
// /src/DTO
8-
...
97

10-
use PasswordEntropyBundle\Validator as EntropyAssert;
8+
use PHPTCloud\PasswordEntropyBundle\Validator as EntropyAssert;
119

1210
class User
1311
{
@@ -24,10 +22,8 @@ class User
2422

2523
```php
2624
<?php
27-
// /src/DTO
28-
...
2925

30-
use PasswordEntropyBundle\Validator as EntropyAssert;
26+
use PHPTCloud\PasswordEntropyBundle\Validator as EntropyAssert;
3127

3228
class User
3329
{
@@ -37,4 +33,4 @@ class User
3733
*/
3834
public ?string $password;
3935
}
40-
```
36+
```

readme.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
### Установка
1212

1313
```shell
14-
composer require tcloud.ax/password-entropy-bundle
14+
composer require phptcloud/password-entropy-bundle
1515
```
1616

1717
### Примеры
@@ -58,4 +58,4 @@ composer require tcloud.ax/password-entropy-bundle
5858
5 уровень - `occurrence` < 9%,
5959

6060

61-
где `occurrence` - процент количества вхождений символа в пароле от его длины.
61+
где `occurrence` - процент количества вхождений символа в пароле от его длины.

src/DependencyInjection/PasswordEntropyBundleExtension.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle\DependencyInjection;
5+
namespace PHPTCloud\PasswordEntropyBundle\DependencyInjection;
66

77
use Symfony\Component\Config\FileLocator;
88
use Symfony\Component\DependencyInjection\ContainerBuilder;
@@ -25,4 +25,4 @@ public function load(array $configs, ContainerBuilder $container): void
2525
{
2626
// ...
2727
}
28-
}
28+
}

src/Exception/PasswordEntropyBundleException.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle\Exception;
5+
namespace PHPTCloud\PasswordEntropyBundle\Exception;
66

77
use Exception;
88

99
class PasswordEntropyBundleException extends Exception
1010
{
11-
}
11+
}

src/Exception/PasswordIsEmptyException.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,8 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle\Exception;
6-
7-
use PasswordEntropyBundle\Exception\PasswordEntropyBundleException;
5+
namespace PHPTCloud\PasswordEntropyBundle\Exception;
86

97
class PasswordIsEmptyException extends PasswordEntropyBundleException
108
{
11-
}
9+
}

src/Interfaces/PasswordEntropyLevelInterface.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle\Interfaces;
5+
namespace PHPTCloud\PasswordEntropyBundle\Interfaces;
66

77
interface PasswordEntropyLevelInterface
88
{
99
public const FIRST_STRENGHT_LEVEL = 1;
1010
public const SECOND_STRENGHT_LEVEL = 2;
1111
public const THIRD_STRENGHT_LEVEL = 3;
1212
public const FOURTH_STRENGHT_LEVEL = 4;
13-
}
13+
}

src/PasswordEntropyBundle.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle;
5+
namespace PHPTCloud\PasswordEntropyBundle;
66

7-
use PasswordEntropyBundle\DependencyInjection\PasswordEntropyBundleExtension;
7+
use PHPTCloud\PasswordEntropyBundle\DependencyInjection\PasswordEntropyBundleExtension;
88
use Symfony\Component\HttpKernel\Bundle\Bundle;
99

1010
/**
@@ -20,4 +20,4 @@ public function getContainerExtension(): PasswordEntropyBundleExtension
2020
{
2121
return new PasswordEntropyBundleExtension();
2222
}
23-
}
23+
}

src/Service/NistEntropyCalculator.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle\Service;
5+
namespace PHPTCloud\PasswordEntropyBundle\Service;
66

7-
use PasswordEntropyBundle\Exception\PasswordIsEmptyException;
8-
use PasswordEntropyBundle\Interfaces\PasswordEntropyLevelInterface;
7+
use PHPTCloud\PasswordEntropyBundle\Exception\PasswordIsEmptyException;
8+
use PHPTCloud\PasswordEntropyBundle\Interfaces\PasswordEntropyLevelInterface;
99

1010
/**
1111
* @link https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-63ver1.0.2.pdf
@@ -106,4 +106,4 @@ private function hasNonAlphabetic(string $password): bool
106106

107107
return count($matches[0]) > 0 ? true : false;
108108
}
109-
}
109+
}

src/Service/OccurrenceEntropyCalculator.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22

33
declare(strict_types=1);
44

5-
namespace PasswordEntropyBundle\Service;
5+
namespace PHPTCloud\PasswordEntropyBundle\Service;
66

7-
use PasswordEntropyBundle\Exception\PasswordIsEmptyException;
8-
use PasswordEntropyBundle\Interfaces\PasswordEntropyLevelInterface;
7+
use PHPTCloud\PasswordEntropyBundle\Exception\PasswordIsEmptyException;
8+
use PHPTCloud\PasswordEntropyBundle\Interfaces\PasswordEntropyLevelInterface;
99

1010
/**
1111
* @author tcloud.ax <tcloud.ax@gmail.com>
@@ -82,4 +82,4 @@ public function checkLevel(string $password): int
8282

8383
return 0;
8484
}
85-
}
85+
}

0 commit comments

Comments
 (0)