#186 Console throws exception trying to generate certificate key/pair with HSM
Closed: wontfix None Opened 12 years ago by rmeggins.

https://bugzilla.redhat.com/show_bug.cgi?id=724829

Using builds..

[root@dhcp-151 ~]# rpm -qa | egrep -i -e "^389" -e "^redhat-ds"
389-adminutil-1.1.14-1.el6.i386
redhat-ds-console-doc-9.0.0-1.el6.noarch
389-ds-base-libs-1.2.8.2-1.el6_1.7.i686
389-console-1.1.7-1.el6.noarch
389-admin-console-1.1.7-1.el6.noarch
redhat-ds-9.0.0-1.el6.i386
389-ds-base-1.2.8.2-1.el6_1.7.i686
redhat-ds-admin-9.0.0-0.2.el6.i386
redhat-ds-console-9.0.0-1.el6.noarch
redhat-ds-base-9.0.0-0.17.el6dsrv.i386
389-ds-console-1.2.6-1.el6.noarch
389-admin-console-doc-1.1.7-1.el6.noarch
389-admin-1.1.20-1.el6.i386
389-ds-console-doc-1.2.6-1.el6.noarch

I performed the following steps..

[1] attach hsm pkcs11 module to /etc/dirsrv/slapd-localhost/ using modutil
[2] open redhat-idm-console
[3] open ds console
[4] goto manage certificates
[5] select hsm token. enter password.
[6] click Request
[7] enter certificate request details on the wizard..
     hostname: dhcp-151.sjc.redhat.com
     O : redhat
     OU: redhat
[8] click Next
[9] enter password for hsm token
[10] click Next

console throws exception like this. It does not generate the certificate
request.

CommManager> New CommRecord
(http://localhost.localdomain:9830/admin-serv/tasks/configuration/SecurityOp)
http://localhost.localdomain:9830/[5:0] open> Ready
http://localhost.localdomain:9830/[5:0] accept>
http://localhost.localdomain:9830/admin-serv/tasks/configuration/SecurityOp
http://localhost.localdomain:9830/[5:0] send> POST  \
http://localhost.localdomain:9830/[5:0] send>
/admin-serv/tasks/configuration/SecurityOp \
http://localhost.localdomain:9830/[5:0] send>  HTTP/1.0
http://localhost.localdomain:9830/[5:0] send> Host: localhost.localdomain:9830
http://localhost.localdomain:9830/[5:0] send> Connection: Keep-Alive
http://localhost.localdomain:9830/[5:0] send> User-Agent:
Red-Hat-Management-Console/1.1.7
http://localhost.localdomain:9830/[5:0] send> Accept-Language: en
http://localhost.localdomain:9830/[5:0] send> Authorization: Basic  \
http://localhost.localdomain:9830/[5:0] send>
Y249ZGlyZWN0b3J5IG1hbmFnZXI6U2VjcmV0MTIz \
http://localhost.localdomain:9830/[5:0] send>
http://localhost.localdomain:9830/[5:0] send> Content-Length:221
http://localhost.localdomain:9830/[5:0] send> Content-Type:
application/x-www-form-urlencoded
http://localhost.localdomain:9830/[5:0] send> Content-Transfer-Encoding: 7bit
http://localhost.localdomain:9830/[5:0] send>
http://localhost.localdomain:9830/[5:0] send> Writing 221 bytes...
http://localhost.localdomain:9830/[5:0] send> 221 bytes written
AbstractServerObject.StatusThread: waiting for change listeners to register
http://localhost.localdomain:9830/[5:0] recv> HTTP/1.1 200 OK
http://localhost.localdomain:9830/[5:0] recv> Date: Thu, 21 Jul 2011 22:40:26
GMT
http://localhost.localdomain:9830/[5:0] recv> Server: Apache/2.2
HttpChannel.invoke: admin version = 2.2
http://localhost.localdomain:9830/[5:0] recv> Admin-Server:
389-Administrator/1.1.20
HttpChannel.invoke: admin version = 1.1.20
http://localhost.localdomain:9830/[5:0] recv> Content-Length: 0
http://localhost.localdomain:9830/[5:0] recv> Connection: close
http://localhost.localdomain:9830/[5:0] recv> Content-Type: text/html
http://localhost.localdomain:9830/[5:0] recv>
http://localhost.localdomain:9830/[5:0] recv> Reading 0 bytes...
http://localhost.localdomain:9830/[5:0] recv> 0 bytes read


Exception occurred during event dispatching:
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
        at java.lang.String.substring(String.java:1943)
        at com.netscape.management.client.security.CertRequestWizard$PluginWiza
rdPage.nextInvoked(Unknown Source)
        at com.netscape.management.client.components.WizardNavigator.actionPerf
ormed(Unknown Source)
        at
javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2012)
        at
javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2335)
        at
javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:404)
        at
javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
        at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButton
Listener.java:253)
        at java.awt.Component.processMouseEvent(Component.java:6203)
        at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
        at java.awt.Component.processEvent(Component.java:5968)
        at java.awt.Container.processEvent(Container.java:2105)
        at java.awt.Component.dispatchEventImpl(Component.java:4564)
        at java.awt.Container.dispatchEventImpl(Container.java:2163)
        at java.awt.Component.dispatchEvent(Component.java:4390)
        at
java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4461)
        at
java.awt.LightweightDispatcher.processMouseEvent(Container.java:4125)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4055)
        at java.awt.Container.dispatchEventImpl(Container.java:2149)
        at java.awt.Window.dispatchEventImpl(Window.java:2478)
        at java.awt.Component.dispatchEvent(Component.java:4390)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:649)
        at java.awt.EventQueue.access$000(EventQueue.java:96)
        at java.awt.EventQueue$1.run(EventQueue.java:608)
        at java.awt.EventQueue$1.run(EventQueue.java:606)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:105)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:116)
        at java.awt.EventQueue$2.run(EventQueue.java:622)
        at java.awt.EventQueue$2.run(EventQueue.java:620)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:105)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:619)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThr
ead.java:275)
        at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
        at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:194)
        at java.awt.Dialog$1.run(Dialog.java:1072)
        at java.awt.Dialog$3.run(Dialog.java:1126)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.awt.Dialog.show(Dialog.java:1124)
        at com.netscape.management.client.components.Wizard.show(Unknown
Source)
        at java.awt.Component.show(Component.java:1496)
        at java.awt.Component.setVisible(Component.java:1448)
        at java.awt.Window.setVisible(Window.java:842)
        at java.awt.Dialog.setVisible(Dialog.java:1011)
        at
com.netscape.management.client.security.CertRequestWizard.setVisible(Unknown
Source)
        at com.netscape.management.client.security.ServerCertificatePane.reques
tInvoked(Unknown Source)
        at com.netscape.management.client.security.CertificateListPane$1.action
Performed(Unknown Source)
        at
javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2012)
        at
javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2335)
        at
javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:404)
        at
javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
        at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButton
Listener.java:253)
        at
java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
        at java.awt.Component.processMouseEvent(Component.java:6203)
        at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
        at java.awt.Component.processEvent(Component.java:5968)
        at java.awt.Container.processEvent(Container.java:2105)
        at java.awt.Component.dispatchEventImpl(Component.java:4564)
        at java.awt.Container.dispatchEventImpl(Container.java:2163)
        at java.awt.Component.dispatchEvent(Component.java:4390)
        at
java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4461)
        at
java.awt.LightweightDispatcher.processMouseEvent(Container.java:4125)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4055)
        at java.awt.Container.dispatchEventImpl(Container.java:2149)
        at java.awt.Window.dispatchEventImpl(Window.java:2478)
        at java.awt.Component.dispatchEvent(Component.java:4390)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:649)
        at java.awt.EventQueue.access$000(EventQueue.java:96)
        at java.awt.EventQueue$1.run(EventQueue.java:608)
        at java.awt.EventQueue$1.run(EventQueue.java:606)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:105)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:116)
        at java.awt.EventQueue$2.run(EventQueue.java:622)
        at java.awt.EventQueue$2.run(EventQueue.java:620)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:105)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:619)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThr
ead.java:275)
        at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
        at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:194)
        at java.awt.Dialog$1.run(Dialog.java:1072)
        at java.awt.Dialog$3.run(Dialog.java:1126)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.awt.Dialog.show(Dialog.java:1124)
        at com.netscape.management.client.util.AbstractDialog.show(Unknown
Source)
        at
com.netscape.management.client.security.CertificateDialog.show(Unknown Source)
        at java.awt.Component.show(Component.java:1496)
        at java.awt.Component.setVisible(Component.java:1448)
        at java.awt.Window.setVisible(Window.java:842)
        at java.awt.Dialog.setVisible(Dialog.java:1011)
        at
com.netscape.management.client.security.CertificateDialog.setVisible(Unknown
Source)
        at com.netscape.admin.dirserv.task.KeyCert.run(Unknown Source)
        at com.netscape.management.client.TaskModel.actionObjectRun(Unknown
Source)
        at com.netscape.management.client.TaskPage$TaskList$ButtonMouseListener
.mouseClicked(Unknown Source)
        at
java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:270)
        at java.awt.Component.processMouseEvent(Component.java:6206)
        at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
        at java.awt.Component.processEvent(Component.java:5968)
        at java.awt.Container.processEvent(Container.java:2105)
        at java.awt.Component.dispatchEventImpl(Component.java:4564)
        at java.awt.Container.dispatchEventImpl(Container.java:2163)
        at java.awt.Component.dispatchEvent(Component.java:4390)
        at
java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4461)
        at
java.awt.LightweightDispatcher.processMouseEvent(Container.java:4134)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4055)
        at java.awt.Container.dispatchEventImpl(Container.java:2149)
        at java.awt.Window.dispatchEventImpl(Window.java:2478)
        at java.awt.Component.dispatchEvent(Component.java:4390)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:649)
        at java.awt.EventQueue.access$000(EventQueue.java:96)
        at java.awt.EventQueue$1.run(EventQueue.java:608)
        at java.awt.EventQueue$1.run(EventQueue.java:606)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:105)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:116)
        at java.awt.EventQueue$2.run(EventQueue.java:622)
        at java.awt.EventQueue$2.run(EventQueue.java:620)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessC
ontrolContext.java:105)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:619)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThr
ead.java:275)
        at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThr
ead.java:190)
        at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
        at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
AbstractServerObject.StatusThread: waiting for change listeners to register
AbstractServerObject.StatusThread: waiting for change listeners to register
http://localhost.localdomain:9830/[5:0] close> Closed

batch update moving tickets to future

set default ticket origin to Community

Added initial screened field value.

Works for me on rhel 5 and 7.1.

Metadata Update from @mreynolds:
- Issue assigned to mreynolds
- Issue set to the milestone: 389-admin,console 1.1.36

7 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/389ds/389-ds-base/issues/186

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata Update from @spichugi:
- Issue close_status updated to: wontfix (was: Invalid)

3 years ago

Login to comment on this ticket.

Metadata