title: Password as argument displayed in stack-trace
body: <p>We log all the exception that occurs in our code, with the stack-trace associated.</p>
  
  <p>The problem comes from this function:</p>
  
  <pre><code>public function Authenticate($user, $password)
      //Authenticate the user
  }
  </code></pre>
  
  <p>When an exception is thrown by this function, the stack-trace contains the parameters used: the user password is displayed in plain text.</p>
  
  <p>How can I deal with that? Should I rewrite Authenticate function to accept only encrypted password? Can I disallow this particular parameter to be displayed in stack trace?</p>
  
  <p>Any idea is welcome.</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>I use the <a href="http://php.net/manual/fr/exception.gettraceasstring.php" rel="nofollow">getTraceAsString</a> function to log the trace.</p>