Passed
Pull Request — master (#11)
by
unknown
07:24
created
CryptoProCli.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
      *
64 64
      * @return string|false|null
65 65
      */
66
-    public function getSigns(): string|false|null
66
+    public function getSigns(): string | false | null
67 67
     {
68 68
         return shell_exec(self::getExec($this->certmgrExec) . ' -list -store uMy');
69 69
     }
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
      * @param bool $detached Создать открепленную подпись
79 79
      * @throws Cli
80 80
      */
81
-    public function signFile(string $file, string|array $thumbprint, string $toFile = '', bool $detached = false): void
81
+    public function signFile(string $file, string | array $thumbprint, string $toFile = '', bool $detached = false): void
82 82
     {
83 83
         list($hash, $pin) = is_array($thumbprint) ? $thumbprint : [$thumbprint, ''];
84 84
         $shellCommand = self::getExec($this->cryptcpExec)
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
      * @return string|false
106 106
      * @throws Cli
107 107
      */
108
-    public function signData(string $data, string|array $thumbprint): string|false
108
+    public function signData(string $data, string | array $thumbprint): string | false
109 109
     {
110 110
         $from = tempnam('/tmp', 'cpsign');
111 111
         $to = tempnam('/tmp', 'cpsign');
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
      * @param string|array $thumbprint SHA1 hash подписи, либо неассоциативный массив собержащий thumbprint и pin пароль ключевого контейнера
129 129
      * @throws Cli
130 130
      */
131
-    public function addSignToFile(string $file, string|array $thumbprint): void
131
+    public function addSignToFile(string $file, string | array $thumbprint): void
132 132
     {
133 133
         list($hash, $pin) = is_array($thumbprint) ? $thumbprint : [$thumbprint, ''];
134 134
         $shellCommand = self::getExec($this->cryptcpExec)
@@ -153,7 +153,7 @@  discard block
 block discarded – undo
153 153
      * @throws Cli
154 154
      * @throws SignatureError
155 155
      */
156
-    public function verifyFileContent(string $fileContent): string|false|null
156
+    public function verifyFileContent(string $fileContent): string | false | null
157 157
     {
158 158
         $file = tempnam(sys_get_temp_dir(), 'cpc');
159 159
         file_put_contents($file, $fileContent);
@@ -219,7 +219,7 @@  discard block
 block discarded – undo
219 219
      * @throws Cli
220 220
      * @throws SignatureError
221 221
      */
222
-    public function verifyFile(string $file): string|false|null
222
+    public function verifyFile(string $file): string | false | null
223 223
     {
224 224
         $shellCommand = self::getExec($this->cryptcpExec)
225 225
             . ' -verify -verall'
@@ -288,11 +288,11 @@  discard block
 block discarded – undo
288 288
      */
289 289
     public function proxyCurl(
290 290
         string $url,
291
-        string|array $thumbprint,
291
+        string | array $thumbprint,
292 292
         string $method = 'GET',
293 293
         ?array $headers = null,
294 294
         ?string $data = null
295
-    ): string|false|null
295
+    ): string | false | null
296 296
     {
297 297
         list($hash, $pin) = is_array($thumbprint) ? $thumbprint : [$thumbprint, ''];
298 298
         $shellCommand = self::getExec($this->curlExec)
Please login to merge, or discard this patch.