summaryrefslogtreecommitdiffstats
path: root/lib/public/Security
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2018-01-13 21:39:34 +0100
committerRoeland Jago Douma <roeland@famdouma.nl>2018-01-13 21:39:34 +0100
commitde5d7aa3317c8547e1ad338613896001fe1aabaf (patch)
treea2b207650db961aa1c9b866507e16b35af9e2f71 /lib/public/Security
parent60f38d37fe5ca505258510adc1e106da54426510 (diff)
downloadnextcloud-server-de5d7aa3317c8547e1ad338613896001fe1aabaf.tar.gz
nextcloud-server-de5d7aa3317c8547e1ad338613896001fe1aabaf.zip
Strict ISecure random
* Declare strict * Scalar arguments * Return type * Use fully qualified name for strlen Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib/public/Security')
-rw-r--r--lib/public/Security/ISecureRandom.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/public/Security/ISecureRandom.php b/lib/public/Security/ISecureRandom.php
index 76e207fbbd8..14976831a1a 100644
--- a/lib/public/Security/ISecureRandom.php
+++ b/lib/public/Security/ISecureRandom.php
@@ -23,6 +23,8 @@
*
*/
+declare(strict_types=1);
+
namespace OCP\Security;
/**
@@ -87,7 +89,7 @@ interface ISecureRandom {
* @return string
* @since 8.0.0
*/
- public function generate($length,
- $characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/');
+ public function generate(int $length,
+ string $characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'): string;
}