Made NullCryptoStream compatible again wit implemented interface.
[core.git] / inc / classes / main / streams / crypto / class_NullCryptoStream.php
index 25372a9944ee49e1173737b3ee99ac82bf84f563..c42e6d1fbefed0b1d384a343c8efcd97b7c7a478 100644 (file)
@@ -3,11 +3,11 @@
  * A null-encryption stream does not encrypt anything but can be used if e.e.
  * mcrypt is not installed.
  *
- * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @author             Roland Haeder <webmaster@shipsimu.org>
  * @version            0.0.0
  * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009  Developer Team
  * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.ship-simu.org
+ * @link               http://www.shipsimu.org
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -50,9 +50,10 @@ class NullCryptoStream extends BaseStream implements EncryptableStream {
         * Encrypt the string with fixed salt
         *
         * @param       $str            The unencrypted string
+        * @param       $key            Optional key, if none provided, a random key will be generated
         * @return      $encrypted      Encrypted string
         */
-       public function encryptStream ($str) {
+       public function encryptStream ($str, $key = NULL) {
                // Just handle it over
                $encrypted = (string) $str;