Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
37 | protected function execute(InputInterface $input, OutputInterface $output) |
||
38 | { |
||
39 | $filename = $input->getArgument('file'); |
||
40 | $args = []; |
||
41 | foreach (['use', 'alg'] as $key) { |
||
42 | $value = $input->getOption($key); |
||
43 | if (null !== $value) { |
||
44 | $args[$key] = $value; |
||
45 | } |
||
46 | } |
||
47 | |||
48 | $jwk = JWKFactory::createFromCertificateFile($filename, $args); |
||
49 | $json = json_encode($jwk); |
||
50 | $this->prepareOutput($input, $output, $json); |
||
51 | } |
||
52 | } |
||
53 |