Hanging or can't type into Java TextField after signed Java applet on Macintosh

Apple bug ID # 7423696

Sun / Oracle bug ID # 9000043

Steps to reproduce:

With Safari, after first accepting the certificate (removed when necessary for testing using the Java Control Panel), the applet hangs with a Java image and empty progress bar.

With Firefox it seems to work.

However, with a more sophisticated applet at www.simulconsult.com/run/, for which a password is needed, sometimes the applet hangs on first run and sometimes TextFields don't accept input. On the second run it works. The behavior is seen in both Safari and Firefox.

The problem has some variability, and seems to depend on some combination of these three settings in the Java Control Panel:

The same problems occurred with both the demo applet and the sophisticated applet when this bug was filed in 2009.  For the more sophisticated applet, the problem is often not encountered because its accompanying registration applet (www.simulconsult.com/register/run/) requires accepting the same digital certificate.  But often people use different computers and thereby run into this bug using the sophisticated applet.

All works fine on various browsers on Windows.

The original version of this report at the time the bug was filed in 2009 is at http://www.segal.org/java/FocusTextField/

If you have any insights or comments about this page please contact Mickey Segal.  A listing of  many Java resources is at this link.

Source code:

import java.awt.*;
import java.applet.*;

public class SigningTestApple extends Applet {

public void init()
  setBackground(new Color(255, 240, 200));
  TextField textField = new TextField(20);

public void paint(Graphics g)
   String userHome = System.getProperty("user.home");
   g.drawString("Signing worked. The user.home property is: " + userHome, 10, 70);
  catch (SecurityException e)
   g.drawString("Signing didn't work. The SecurityException is: " + e.getMessage(), 10, 70);
} // END OF Class SigningTestApple