1 | <?php |
||
20 | class OpenSSL extends Abstraction implements Simulator |
||
21 | { |
||
22 | /** |
||
23 | * Path to mcrypt command. |
||
24 | * |
||
25 | * @var string |
||
26 | */ |
||
27 | private $pathToOpenSSL; |
||
28 | |||
29 | /** |
||
30 | * Key file |
||
31 | * |
||
32 | * @var string |
||
33 | */ |
||
34 | private $certFile; |
||
35 | |||
36 | /** |
||
37 | * Algorithm to use |
||
38 | * |
||
39 | * @var string |
||
40 | */ |
||
41 | private $algorithm; |
||
42 | |||
43 | /** |
||
44 | * Password to use |
||
45 | * |
||
46 | * @var string |
||
47 | */ |
||
48 | private $password; |
||
49 | |||
50 | /** |
||
51 | * Keep the not encrypted file |
||
52 | * |
||
53 | * @var boolean |
||
54 | */ |
||
55 | private $keepUncrypted; |
||
56 | |||
57 | /** |
||
58 | * Setup. |
||
59 | * |
||
60 | * @see \phpbu\App\Backup\Crypter |
||
61 | * @param array $options |
||
62 | * @throws Exception |
||
63 | */ |
||
64 | public function setup(array $options = []) |
||
80 | 3 | ||
81 | 3 | /** |
|
82 | 3 | * Return file suffix of encrypted target. |
|
83 | 3 | * |
|
84 | 3 | * @see \phpbu\App\Backup\Crypter |
|
85 | 3 | * @return string |
|
86 | 3 | */ |
|
87 | public function getSuffix() : string |
||
91 | |||
92 | /** |
||
93 | * Create the Executable to run the 'mcrypt' command. |
||
94 | * |
||
95 | * @param \phpbu\App\Backup\Target $target |
||
96 | 2 | * @return \phpbu\App\Cli\Executable |
|
97 | */ |
||
98 | 2 | protected function createExecutable(Target $target) : Executable |
|
114 | } |
||
115 |