Leakage of toString() result for a PrintWriter
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/11076992/presvent-exposure-of-sensitive-data-against-pci-standards-response-getwriter">Presvent exposure of sensitive data against PCI standards - response.getWriter().write(xml.toString())</a>  </p>
</blockquote>



<p>I am getting the message "Leakage of toString() result" in the following Java code:</p>

<pre><code>PrintWriter out = response.getWriter();
out.println("&lt;a href=\""
            + XYZAC
            + "?"
            + fieldArray.get(i)
            + "="
            + content[j].split("=")[0]
            + "&amp;sessionId="
            + request.getAttribute("sessionId").toString()
            + "&amp;mSA=" + pHNO
            + "\"" + "&gt;"
            + content[j].split("=")[1]
            + "&lt;/a&gt;");
</code></pre>

<p>Can any one tell me where the leakage is, and how to fix it? The message is from a code auditing tool.</p>
