1 | <?php |
||
10 | class EncryptionMnemonic |
||
11 | { |
||
12 | const CHUNK_SIZE = 4; |
||
13 | const PADDING_DUMMY = "\x81"; |
||
14 | |||
15 | /** |
||
16 | * @var Mnemonic |
||
17 | */ |
||
18 | protected static $encoder; |
||
19 | |||
20 | /** |
||
21 | * @return Mnemonic |
||
22 | */ |
||
23 | 4 | protected static function getEncoder() |
|
30 | |||
31 | /** |
||
32 | * @param string $data |
||
33 | * @return string |
||
34 | */ |
||
35 | 4 | private static function derivePadding($data) |
|
44 | |||
45 | /** |
||
46 | * @param BufferInterface $data |
||
47 | * @return string |
||
48 | */ |
||
49 | 4 | public static function encode(BufferInterface $data) |
|
62 | |||
63 | /** |
||
64 | * @param string $mnemonic |
||
65 | * @return BufferInterface |
||
66 | */ |
||
67 | 4 | public static function decode($mnemonic) |
|
83 | } |
||
84 |