| 1 | <?php |
||
| 9 | class Openssl |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * @var string |
||
| 13 | */ |
||
| 14 | private $cipher; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * @var string |
||
| 18 | */ |
||
| 19 | private $algo; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * @var string |
||
| 23 | */ |
||
| 24 | private $key; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * Openssl constructor. |
||
| 28 | * |
||
| 29 | * @param string $cipher |
||
| 30 | * @param string $algo |
||
| 31 | * @param string $key |
||
| 32 | */ |
||
| 33 | 1 | public function __construct(string $cipher, string $algo, string $key) |
|
| 37 | |||
| 38 | /** |
||
| 39 | * @param string $data |
||
| 40 | * |
||
| 41 | * @throws Exception |
||
| 42 | * |
||
| 43 | * @return string |
||
| 44 | */ |
||
| 45 | 1 | public function decrypt(string $data): string |
|
| 49 | |||
| 50 | /** |
||
| 51 | * @param string $data |
||
| 52 | * |
||
| 53 | * @throws Exception |
||
| 54 | * |
||
| 55 | * @return string |
||
| 56 | */ |
||
| 57 | 1 | public function encrypt(string $data): string |
|
| 61 | } |
||
| 62 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.