Bug 586571

Summary: DS Console shows escaped DNs
Product: [Retired] 389 Reporter: Noriko Hosoi <nhosoi>
Component: UI - General UIAssignee: Rich Megginson <rmeggins>
Status: CLOSED CURRENTRELEASE QA Contact: Viktor Ashirov <vashirov>
Severity: medium Docs Contact:
Priority: high    
Version: 1.2.6CC: jgalipea
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-12-07 16:47:53 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 434914, 543590    
Attachments:
Description Flags
screenshot showing the escaped DNs (DIT & Suffix name)
none
0001-Bug-586571-DS-Console-shows-escaped-DNs.patch
nhosoi: review+
screenshot of directory browser showing various ways that DNs are displayed
none
screenshot with raw DN in the status area at the bottom of the window
none
screenshot of suffixes and databases
none
main console patch
nkinder: review+
0001-Bug-586571-DS-Console-shows-escaped-DNs.patch
nkinder: review+
0001-Bug-586571-DS-Console-shows-escaped-DNs.patch
nkinder: review+
RHDS 8.2 admin screenshot none

Description Noriko Hosoi 2010-04-27 21:47:43 UTC
Created attachment 409596 [details]
screenshot showing the escaped DNs (DIT & Suffix name)

Description of problem:
It looks Console is showing the Suffix cut from cn="<suffix>",
cn=mapping tree, cn=config. They are now escaped as seen on the
screenshot. :( Do we consider this is a bug (especially for 8.2)? Should
we fix it?

Rich Megginson wrote:
> Yes, I think this is a bug, and I think we should fix this. A DN only
> needs to be escaped if it is used inside another DN. In this case (and
> likely many others) we should display the unescaped DN to the user.

Kevin Unthank wrote:
> Rich is right. It's a bug, we should fix it.

Comment 1 Noriko Hosoi 2010-04-28 22:38:51 UTC
Related issues... 
(I'm sure these are known problems.  I'm listing them not to forget to verify...)

1. On the Configuration panel, backend node for each suffix is not displayed under DATA.

2. Creating a sub suffix from Console fails due to invalid syntax.  This is because the Console sends "ou=subExample,dc\\3Dexample\\2Cdc\\3Dcom" for the sub suffix DN.
(gdb) p *val
$10 = {bv = {bv_len = 37, 
    bv_val = 0xb27610d8 "ou=subExample,dc\\3Dexample\\2Cdc\\3Dcom"}, 
  v_csnset = 0x0, v_flags = 0}

Comment 2 Rich Megginson 2010-04-29 22:11:56 UTC
Created attachment 410247 [details]
0001-Bug-586571-DS-Console-shows-escaped-DNs.patch

Comment 3 Rich Megginson 2010-04-29 22:13:49 UTC
Created attachment 410248 [details]
screenshot of directory browser showing various ways that DNs are displayed

Comment 4 Rich Megginson 2010-04-29 22:14:40 UTC
Created attachment 410249 [details]
screenshot with raw DN in the status area at the bottom of the window

Comment 5 Rich Megginson 2010-04-29 22:18:12 UTC
Created attachment 410250 [details]
screenshot of suffixes and databases

Comment 6 Rich Megginson 2010-04-30 02:12:47 UTC
To ssh://git.fedorahosted.org/git/389/ds-console.git
   3b45c4a..1ce76be  master -> master
commit 1ce76be162d0ccd812511815e6176dfcd626ecea
Author: Rich Megginson <rmeggins>
Date:   Thu Apr 29 16:10:43 2010 -0600
    Reviewed by: nhosoi (Thanks!)
    Branch: HEAD
    Fix Description: Changed the console to be aware of LDAPv3 escapes.  The
    console can now correctly read and display DN values that contain escapes,
    and can correctly escape DNs sent to the server.  The console will still
    display the "raw" DN with the escapes in certain cases - for example, the
    status area at the bottom of the window shows the raw DN for the entry
    selected in the directory browser; the Advanced... editor will show the
    raw DN in DN valued fields.
    Platforms tested: RHEL5 x86_64
    Flag Day: no
    Doc impact: no

Comment 7 Rich Megginson 2010-05-03 17:35:41 UTC
Created attachment 411075 [details]
main console patch

Comment 8 Rich Megginson 2010-05-03 17:37:28 UTC
Created attachment 411077 [details]
0001-Bug-586571-DS-Console-shows-escaped-DNs.patch

Comment 9 Rich Megginson 2010-05-03 20:40:00 UTC
Checking in src/com/netscape/management/client/ug/ResourcePageObservable.java;
/cvs/dirsec/console/src/com/netscape/management/client/ug/ResourcePageObservable.java,v  <--  ResourcePageObservable.java
new revision: 1.2; previous revision: 1.1
Checking in src/com/netscape/management/client/util/LDAPUtil.java;
/cvs/dirsec/console/src/com/netscape/management/client/util/LDAPUtil.java,v  <--  LDAPUtil.java
new revision: 1.4; previous revision: 1.3

To ssh://git.fedorahosted.org/git/389/ds-console.git
   2044ad9..b2e8292  master -> master
commit b2e8292736c270424f2e60a4e0e3bb243dacde74
Author: Rich Megginson <rmeggins>
Date:   Mon May 3 11:33:34 2010 -0600
    Reviewed by: nkinder (Thanks!)
    Branch: HEAD
    Fix Description: Was not working correctly in the property and advanced
    editor for editing some DNs that contained other DNs as RDN values.
    I also moved a lot of the DN handling code into the main console package
    into the LDAPUtil class.  This will allow the main console to handle DN
    escapes as well.  Unfortunately, if managing a new DS on a machine which
    only has the old console framework, these methods will be missing.
    So, use the new methods if available, otherwise, fallback on the DSUtil
    implementation.
    Platforms tested: RHEL5 x86_64
    Flag Day: no
    Doc impact: no

Comment 10 Rich Megginson 2010-05-05 01:38:10 UTC
Created attachment 411455 [details]
0001-Bug-586571-DS-Console-shows-escaped-DNs.patch

This patch is for the directory server itself, to be able to use a 3 digit ds console jar file version.

Comment 11 Rich Megginson 2010-05-05 15:33:15 UTC
To ssh://git.fedorahosted.org/git/389/ds.git
   a0b60b0..fe4d09a  master -> master
commit fe4d09a3f984fe821635a1147da12dc3510cd4d6
Author: Rich Megginson <rmeggins>
Date:   Tue May 4 16:12:35 2010 -0600
    Reviewed by: nkinder (Thanks!)
    Branch: HEAD
    Fix Description: In order for the console fixed to be used to manage the
    correct directory server, the directory server needs to be able to specify
    the ds console jar file version down to 3 digits, as opposed to the curren
    two digits.  To support this, instead of overriding PACKAGE_BASE_VERSION,
    a new configure macro is introduced - CONSOLE_VERSION.  This value is
    set in VERSION.sh, so it can be easily updated, and it is used to set
    the value for BaseVersion in slapd.inf, which is what the admin server
    setup uses to set the ds console jar file version corresponding to the
    directory server.
    Platforms tested: RHEL5 x86_64, Fedora 12
    Flag Day: no
    Doc impact: no

Comment 12 Fedora Update System 2010-05-05 15:39:55 UTC
idm-console-framework-1.1.5-1.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/idm-console-framework-1.1.5-1.fc11

Comment 13 Fedora Update System 2010-05-05 15:39:59 UTC
idm-console-framework-1.1.5-1.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/idm-console-framework-1.1.5-1.fc12

Comment 14 Fedora Update System 2010-05-05 15:40:04 UTC
idm-console-framework-1.1.5-1.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/idm-console-framework-1.1.5-1.fc13

Comment 15 Fedora Update System 2010-05-05 15:42:04 UTC
389-ds-console-1.2.2-1.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/389-ds-console-1.2.2-1.fc12

Comment 16 Fedora Update System 2010-05-05 15:42:09 UTC
389-ds-console-1.2.2-1.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/389-ds-console-1.2.2-1.fc11

Comment 17 Fedora Update System 2010-05-05 15:42:13 UTC
389-ds-console-1.2.2-1.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/389-ds-console-1.2.2-1.fc13

Comment 18 Jenny Severance 2010-05-12 20:47:27 UTC
fix verified - RHEL 4

redhat-ds-base-8.2.0-2010051204.el4dsrv
redhat-admin-console-8.2.0-1.el4dsrv
redhat-idm-console-1.0.0-26.el4idm
redhat-ds-console-8.2.0-2.el4dsrv
redhat-ds-base-devel-8.2.0-2010051204.el4dsrv
redhat-ds-admin-8.2.0-2.el4dsrv
redhat-ds-8.2.0-1.el4dsrv

See attached screen shot.

Comment 19 Jenny Severance 2010-05-12 20:48:10 UTC
Created attachment 413558 [details]
RHDS 8.2 admin screenshot