<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>Captcha image Corrupted / Garbled</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=3535201" />
  <subtitle>Captcha image Corrupted / Garbled</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=3535201</id>
  <updated>2026-04-16T21:55:07Z</updated>
  <dc:date>2026-04-16T21:55:07Z</dc:date>
  <entry>
    <title>RE: Captcha image Corrupted / Garbled</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=4055350" />
    <author>
      <name>Lisa Simpson</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=4055350</id>
    <updated>2009-09-22T21:48:32Z</updated>
    <published>2009-09-22T21:48:32Z</published>
    <summary type="html">Try changing your mime type to something &amp;#34;image-y&amp;#34; and see if that doesn&amp;#39;t fix it.  I can see where some other code might come into play and try to &amp;#34;render&amp;#34; your &amp;#34;text&amp;#34;.&lt;br /&gt;&lt;br /&gt;.gif 	image/gif, etc.</summary>
    <dc:creator>Lisa Simpson</dc:creator>
    <dc:date>2009-09-22T21:48:32Z</dc:date>
  </entry>
  <entry>
    <title>RE: Captcha image Corrupted / Garbled</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=4053520" />
    <author>
      <name>Jim Klo</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=4053520</id>
    <updated>2009-09-22T16:14:47Z</updated>
    <published>2009-09-22T16:14:47Z</published>
    <summary type="html">&lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;Actually, this is more or less the default captcha with a custom dictionary, different color scheme, and some CSS.&lt;br&gt;&lt;br&gt;My captcha-ext.properties is:&lt;br&gt;&lt;pre&gt;&lt;code&gt;
cap.border=yes
cap.border.c=0,0,0,0
cap.border.th=1

cap.font.color=255,255,255
cap.noise.c=0,0,0

cap.background.c.to=0,0,0,0
cap.background.c.from=0,0,0,0

cap.image.height=50
cap.image.width=280
&lt;/code&gt;&lt;/pre&gt;&lt;br&gt;&lt;br&gt;Since my original post, I've practically rewritten every class for SimpleCaptcha with our own custom Obfuscation, Distortion, Noise, WordRenderer, WordGenerator - and the only thing I've not changed is the underlying framework.  I needed a more hardened CAPTCHA, thus I had to randomize Distortion, Noise, Fonts, Sizing and fix a placement bug in the original distro.  The issue happens a lot less frequently since the rewrite, thus, I'm almost convinced it's an issue of poor cleanup.&lt;br&gt;&lt;br&gt;Another possibility, which I've not pursued yet, is that the headers sent by the captcha image servlet are wrong.  The mime type is sent as text/html, which might be related, but not sure yet..&lt;/body&gt;&lt;/html&gt;</summary>
    <dc:creator>Jim Klo</dc:creator>
    <dc:date>2009-09-22T16:14:47Z</dc:date>
  </entry>
  <entry>
    <title>RE: Captcha image Corrupted / Garbled</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=4026317" />
    <author>
      <name>Lisa Simpson</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=4026317</id>
    <updated>2009-09-15T19:13:21Z</updated>
    <published>2009-09-15T19:13:21Z</published>
    <summary type="html">Since that looks absolutely nothing like the CAPTCHA I get on Liferay, I&amp;#39;m guessing it&amp;#39;s a JBOSS related thing.</summary>
    <dc:creator>Lisa Simpson</dc:creator>
    <dc:date>2009-09-15T19:13:21Z</dc:date>
  </entry>
  <entry>
    <title>Captcha image Corrupted / Garbled</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=3535200" />
    <author>
      <name>Jim Klo</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=3535200</id>
    <updated>2009-07-10T06:46:07Z</updated>
    <published>2009-07-10T06:46:07Z</published>
    <summary type="html">Wondering if anyone else has experienced this and has a solution.&lt;br /&gt;&lt;br /&gt;We&amp;#39;re using  captcha in several places on our site.  It seems that quite frequently we get a very garbled image, as if something went wrong with the image processing.&lt;br /&gt;&lt;br /&gt;I&amp;#39;ve noticed that no where in the liferay or the simple captcha settings is JAVA AWT set to headless mode (I&amp;#39;ve set alas, with not improvments - however, AFAIK, I&amp;#39;ve had long term issues when doing image processing without having that set)&lt;br /&gt;&lt;br /&gt;Attached are examples of garbled and ungarbled images, so you understand what I mean.&lt;br /&gt;&lt;br /&gt;Anyone have any ideas what might be wrong or any config that might be tweaked?&lt;br /&gt;&lt;br /&gt;I&amp;#39;m using Liferay 5.1.1 running on JBoss.&lt;br /&gt;&lt;br /&gt;Thanks,&lt;br /&gt;&lt;br /&gt;Jim</summary>
    <dc:creator>Jim Klo</dc:creator>
    <dc:date>2009-07-10T06:46:07Z</dc:date>
  </entry>
</feed>
