1 | <?php |
||
21 | class Mcrypt extends Key implements Crypter |
||
22 | { |
||
23 | /** |
||
24 | * Path to mcrypt command. |
||
25 | * |
||
26 | * @var string |
||
27 | */ |
||
28 | private $pathToMcrypt; |
||
29 | |||
30 | /** |
||
31 | * Key to pass via cli |
||
32 | * |
||
33 | * @var string |
||
34 | */ |
||
35 | private $key; |
||
36 | |||
37 | /** |
||
38 | * Key file |
||
39 | * |
||
40 | * @var string |
||
41 | */ |
||
42 | private $keyFile; |
||
43 | |||
44 | /** |
||
45 | * Algorithm to use |
||
46 | * |
||
47 | * @var string |
||
48 | */ |
||
49 | private $algorithm; |
||
50 | |||
51 | /** |
||
52 | * Hash to use |
||
53 | * |
||
54 | * @var string |
||
55 | */ |
||
56 | private $hash; |
||
57 | |||
58 | /** |
||
59 | * Path to config file |
||
60 | * |
||
61 | * @var string |
||
62 | */ |
||
63 | private $config; |
||
64 | |||
65 | /** |
||
66 | * Keep the not encrypted file |
||
67 | * |
||
68 | * @var boolean |
||
69 | */ |
||
70 | private $keepUncrypted; |
||
71 | |||
72 | /** |
||
73 | * Setup. |
||
74 | * |
||
75 | * @see \phpbu\App\Backup\Crypter |
||
76 | * @param array $options |
||
77 | * @throws Exception |
||
78 | */ |
||
79 | public function setup(array $options = array()) |
||
97 | 4 | ||
98 | /** |
||
99 | 4 | * (non-PHPDoc) |
|
100 | 1 | * |
|
101 | * @see \phpbu\App\Backup\Crypter |
||
102 | 3 | * @return string |
|
103 | */ |
||
104 | public function getSuffix() |
||
108 | |||
109 | /** |
||
110 | * Create the Exec to run the 'mcrypt' command. |
||
111 | * |
||
112 | 2 | * @param \phpbu\App\Backup\Target $target |
|
113 | * @return \phpbu\App\Cli\Executable |
||
114 | 2 | */ |
|
115 | public function getExecutable(Target $target) |
||
130 | } |
||
131 |