@@ -23,8 +23,8 @@ discard block |
||
23 | 23 | * @license http://opensource.org/licenses/MIT The MIT License (MIT) |
24 | 24 | * @link https://github.com/mmeyer2k/dcrypt |
25 | 25 | */ |
26 | -class OpensslStack |
|
27 | -{ |
|
26 | +class OpensslStack |
|
27 | +{ |
|
28 | 28 | /** |
29 | 29 | * @var array |
30 | 30 | */ |
@@ -46,8 +46,8 @@ discard block |
||
46 | 46 | * @param string $passkey Password or key |
47 | 47 | * @param int $cost Cost when using password mode |
48 | 48 | */ |
49 | - public function __construct(string $passkey, int $cost = 0) |
|
50 | - { |
|
49 | + public function __construct(string $passkey, int $cost = 0) |
|
50 | + { |
|
51 | 51 | $this->passkey = $passkey; |
52 | 52 | |
53 | 53 | $this->cost = $cost; |
@@ -103,6 +103,6 @@ |
||
103 | 103 | $chk = \hash_hmac($algo, $msg, $key->authenticationKey(), true); |
104 | 104 | |
105 | 105 | // Return iv + checksum + tag + ciphertext |
106 | - return $ivr . $chk . $tag . $msg; |
|
106 | + return $ivr.$chk.$tag.$msg; |
|
107 | 107 | } |
108 | 108 | } |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | * Displays supported |
9 | 9 | */ |
10 | 10 | |
11 | -require __DIR__ . '/../vendor/autoload.php'; |
|
11 | +require __DIR__.'/../vendor/autoload.php'; |
|
12 | 12 | |
13 | 13 | $key = \Dcrypt\OpensslKeyGenerator::newKey(); |
14 | 14 | |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | $d = \Dcrypt\OpensslStatic::decrypt($e, $key, $meth, 'sha256'); |
28 | 28 | |
29 | 29 | echo " [pass] "; |
30 | - } catch (\Exception|\Error $e) { |
|
30 | + } catch (\Exception | \Error $e) { |
|
31 | 31 | $m = $e->getMessage(); |
32 | 32 | echo " [fail] [$m]"; |
33 | 33 | } finally { |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | $d = \Dcrypt\OpensslStatic::decrypt($e, $key, 'aes-256-gcm', $algo); |
51 | 51 | |
52 | 52 | echo " [pass] "; |
53 | - } catch (\Exception|\Error $e) { |
|
53 | + } catch (\Exception | \Error $e) { |
|
54 | 54 | $m = $e->getMessage(); |
55 | 55 | echo " [fail] [$m]"; |
56 | 56 | } finally { |