@@ -110,7 +110,7 @@ |
||
| 110 | 110 | /** |
| 111 | 111 | * Check if an setting is enabled (value of 1) |
| 112 | 112 | * |
| 113 | - * @param $setting |
|
| 113 | + * @param string $setting |
|
| 114 | 114 | * @return bool |
| 115 | 115 | */ |
| 116 | 116 | public function isEnabled($setting) { |
@@ -206,6 +206,10 @@ discard block |
||
| 206 | 206 | return array($cipherKey, $macKey, $iv); |
| 207 | 207 | } |
| 208 | 208 | |
| 209 | + /** |
|
| 210 | + * @param string $a |
|
| 211 | + * @param string $b |
|
| 212 | + */ |
|
| 209 | 213 | protected function hash_equals($a, $b) { |
| 210 | 214 | if (function_exists('random_bytes')) { |
| 211 | 215 | $key = random_bytes(128); |
@@ -247,7 +251,7 @@ discard block |
||
| 247 | 251 | /** |
| 248 | 252 | * Pad the data with a random char chosen by the pad amount. |
| 249 | 253 | * |
| 250 | - * @param $data |
|
| 254 | + * @param string $data |
|
| 251 | 255 | * @return string |
| 252 | 256 | */ |
| 253 | 257 | protected function pad($data) { |
@@ -263,8 +267,8 @@ discard block |
||
| 263 | 267 | /** |
| 264 | 268 | * Unpad the the data |
| 265 | 269 | * |
| 266 | - * @param $data |
|
| 267 | - * @return bool|string |
|
| 270 | + * @param string $data |
|
| 271 | + * @return false|string |
|
| 268 | 272 | */ |
| 269 | 273 | protected function unpad($data) { |
| 270 | 274 | $length = $this->getKeySize(); |