Re: M13 and api M17

2013-06-25 Thread Emmanuel Lécharny
Le 6/25/13 12:59 AM, carlo.acco...@ibs-ag.com a écrit :
 Hi, I'm using the  M13  build and Api M17.
 I create an entry no problem then try and update it with a Modification[]  
 array and it fails.
 I've tried it with and without the userPassword and the same issue occurs.  
 Without digging in too deep, is there anything you can see from the message?
 We just swapped out M11 server for M13 ( startup with new partitions) and 
 tried to create a new user.
 Do we need to use the M18 API with this release?  Will work to provide more 
 information. Thanks!

Hi,

we have fixed an issue in the way we handle modifications in M13, when
processing a replace Modification with a null attribute. This may be the
cause of your issue.

I'll investigate the pb you have.


 Modifications are printed just before I call. modify()

 for (Modification mod: mods)
 {
 log.debug(mod.getOperation().name() +  -   +mod.getAttribute().toString());
 }
 connection.modify(dn, mods); // mods = Modification[] array


 2013-24-06 18:29:14.406 DEBUG DirectoryServerConnection:537 - ADD_ATTRIBUTE 
 -  mail: testuse...@testuser12.com

 2013-24-06 18:29:14.406 DEBUG DirectoryServerConnection:537 - 
 REPLACE_ATTRIBUTE -  sn: testuser12

 2013-24-06 18:29:14.406 DEBUG DirectoryServerConnection:537 - 
 REPLACE_ATTRIBUTE -  cn: Test User12

 2013-24-06 18:29:14.406 DEBUG DirectoryServerConnection:537 - ADD_ATTRIBUTE 
 -  telephoneNumber: 123213

 2013-24-06 18:29:14.407 DEBUG DirectoryServerConnection:537 - ADD_ATTRIBUTE 
 -  userPassword: 123456

 2013-24-06 18:29:14.407 DEBUG DirectoryServerConnection:537 - ADD_ATTRIBUTE 
 -  givenName: testuser12

 2013-24-06 18:29:14.407 DEBUG DirectoryServerConnection:537 - ADD_ATTRIBUTE 
 -  displayName: Test User12

 2013-24-06 18:29:14.407 DEBUG DirectoryServerConnection:537 - ADD_ATTRIBUTE 
 -  employeeNumber: testuser12

 2013-24-06 18:29:30.753 DEBUG LdapNetworkConnection:284 - Adding 4, 
 org.apache.directory.ldap.client.api.future.ModifyFuture
 2013-24-06 18:29:30.764 DEBUG ProtocolCodecFilter:211 - Processing a 
 MESSAGE_RECEIVED for session 53
 2013-24-06 18:29:30.765 DEBUG LdapDecoder:124 - Decoding the PDU :
 2013-24-06 18:29:30.765 DEBUG LdapDecoder:140 - 0x30 0x82 0x04 0x91 0x02 0x01 
 0x04 0x67 0x82 0x04 0x8A 0x0A 0x01 0x50 0x04 0x00 0x04 0x82 0x04 0x81 0x4F 
 0x54 0x48 0x45 0x52 0x3A 0x20 0x66 0x61 0x69 0x6C 0x65 0x64 0x20 0x66 0x6F 
 0x72 0x20 0x4D 0x65 0x73 0x73 0x61 0x67 0x65 0x54 0x79 0x70 0x65 0x20 0x3A 
 0x20 0x4D 0x4F 0x44 0x49 0x46 0x59 0x5F 0x52 0x45 0x51 0x55 0x45 0x53 0x54 
 0x0A 0x4D 0x65 0x73 0x73 0x61 0x67 0x65 0x20 0x49 0x44 0x20 0x3A 0x20 0x34 
 0x0A 0x20 0x20 0x20 0x20 0x4D 0x6F 0x64 0x69 0x66 0x79 0x20 0x52 0x65 0x71 
 0x75 0x65 0x73 0x74 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x4F 0x62 
 0x6A 0x65 0x63 0x74 0x20 0x3A 0x20 0x27 0x75 0x69 0x64 0x3D 0x31 0x33 0x37 
 0x32 0x31 0x31 0x32 0x38 0x34 0x32 0x33 0x32 0x35 0x2C 0x6F 0x75 0x3D 0x75 
 0x73 0x65 0x72 0x73 0x2C 0x6F 0x75 0x3D 0x69 0x6E 0x74 0x2C 0x6F 0x3D 0x63 
 0x70 0x72 0x6F 0x27 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x4D 0x6F 0x64 0x69 0x66 0x69 0x63 0x61 0x74 0x69 0x6F 0x6E 0x5B 
 0x30 0x5D 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x4F 0x70 0x65 0x72 0x61 0x74 0x69 0x6F 0x6E 0x20 0x3A 
 0x20 0x20 0x61 0x64 0x64 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x4D 0x6F 0x64 0x69 0x66 0x69 0x63 0x61 
 0x74 0x69 0x6F 0x6E 0x0A 0x6D 0x61 0x69 0x6C 0x3A 0x20 0x74 0x65 0x73 0x74 
 0x75 0x73 0x65 0x72 0x31 0x32 0x40 0x74 0x65 0x73 0x74 0x75 0x73 0x65 0x72 
 0x31 0x32 0x2E 0x63 0x6F 0x6D 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x4D 0x6F 0x64 0x69 0x66 0x69 0x63 0x61 0x74 0x69 0x6F 
 0x6E 0x5B 0x31 0x5D 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x20 0x20 0x4F 0x70 0x65 0x72 0x61 0x74 0x69 0x6F 0x6E 
 0x20 0x3A 0x20 0x20 0x72 0x65 0x70 0x6C 0x61 0x63 0x65 0x0A 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x4D 0x6F 
 0x64 0x69 0x66 0x69 0x63 0x61 0x74 0x69 0x6F 0x6E 0x0A 0x73 0x6E 0x3A 0x20 
 0x74 0x65 0x73 0x74 0x75 0x73 0x65 0x72 0x31 0x32 0x0A 0x20 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x4D 0x6F 0x64 0x69 0x66 0x69 0x63 
 0x61 0x74 0x69 0x6F 0x6E 0x5B 0x32 0x5D 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x4F 0x70 0x65 0x72 0x61 
 0x74 0x69 0x6F 0x6E 0x20 0x3A 0x20 0x20 0x72 0x65 0x70 0x6C 0x61 0x63 0x65 
 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 
 0x20 0x20 0x4D 0x6F 0x64 0x69 0x66 0x69 0x63 0x61 0x74 0x69 0x6F 0x6E 0x0A 
 0x63 0x6E 0x3A 0x20 0x54 0x65 0x73 0x74 0x20 0x55 0x73 0x65 0x72 0x31 0x32 
 0x0A 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x4D 0x6F 
 0x64 0x69 0x66 0x69 0x63 0x61 0x74 0x69 0x6F 0x6E 0x5B 0x33 0x5D 0x0A 0x20 
 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 

Re: M13 and api M17

2013-06-25 Thread Emmanuel Lécharny
Le 6/25/13 12:59 AM, carlo.acco...@ibs-ag.com a écrit :
 Hi, I'm using the  M13  build and Api M17.
 I create an entry no problem then try and update it with a Modification[]  
 array and it fails.
 I've tried it with and without the userPassword and the same issue occurs.  
 Without digging in too deep, is there anything you can see from the message?
 We just swapped out M11 server for M13 ( startup with new partitions) and 
 tried to create a new user.

Are you using any control in the LDAP message you are sending ?

If possible, can you provide the dump for the ModifyRequest ? i'd like
to test the code that does the modification too.



-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com 



Re: M13 and api M17

2013-06-25 Thread Emmanuel Lécharny
Le 6/25/13 12:59 AM, carlo.acco...@ibs-ag.com a écrit :
 Hi, I'm using the  M13  build and Api M17.
 I create an entry no problem then try and update it with a Modification[]  
 array and it fails.
 I've tried it with and without the userPassword and the same issue occurs.  
 Without digging in too deep, is there anything you can see from the message?
 We just swapped out M11 server for M13 ( startup with new partitions) and 
 tried to create a new user.
 Do we need to use the M18 API with this release?  Will work to provide more 
 information. Thanks!

More specifically, I wonder if you are using the PasswordPolicy control.
I would be interested to know if using M18 imrpovs the result you get.

-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com 



Re: M13 and api M17

2013-06-25 Thread Kiran Ayyagari
On Tue, Jun 25, 2013 at 1:07 PM, Emmanuel Lécharny elecha...@gmail.comwrote:

 Le 6/25/13 12:59 AM, carlo.acco...@ibs-ag.com a écrit :
  Hi, I'm using the  M13  build and Api M17.
  I create an entry no problem then try and update it with a
 Modification[]  array and it fails.
  I've tried it with and without the userPassword and the same issue
 occurs.  Without digging in too deep, is there anything you can see from
 the message?
  We just swapped out M11 server for M13 ( startup with new partitions)
 and tried to create a new user.
  Do we need to use the M18 API with this release?  Will work to provide
 more information. Thanks!
 
 More specifically, I wonder if you are using the PasswordPolicy control.
 I would be interested to know if using M18 imrpovs the result you get.

 besides, can you show us your ppolicy configuration

 --
 Regards,
 Cordialement,
 Emmanuel Lécharny
 www.iktek.com




-- 
Kiran Ayyagari
http://keydap.com


RE: M13 and api M17

2013-06-25 Thread Carlo.Accorsi
For this modification, I'm not using any controls. The attributes are not null 
either. We set the cn and sn (which are required) to the string 'null' when the 
entry is created to have a stub entry. 
Then we update, replace modification those fields, add modification on new 
fields with the user provided data.  The password policy control I use only on 
a bind request to see if they are expiring, need to change pw, etc. 
I'll try M18 and get back to you in about 30 minutes. 


-Original Message-
From: Emmanuel Lécharny [mailto:elecha...@gmail.com] 
Sent: Tuesday, June 25, 2013 3:38 AM
To: users@directory.apache.org
Subject: Re: M13 and api M17

Le 6/25/13 12:59 AM, carlo.acco...@ibs-ag.com a écrit :
 Hi, I'm using the  M13  build and Api M17.
 I create an entry no problem then try and update it with a Modification[]  
 array and it fails.
 I've tried it with and without the userPassword and the same issue occurs.  
 Without digging in too deep, is there anything you can see from the message?
 We just swapped out M11 server for M13 ( startup with new partitions) and 
 tried to create a new user.
 Do we need to use the M18 API with this release?  Will work to provide more 
 information. Thanks!

More specifically, I wonder if you are using the PasswordPolicy control.
I would be interested to know if using M18 imrpovs the result you get.

-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com 



Re: M13 and api M17

2013-06-25 Thread Emmanuel Lécharny
Le 6/25/13 2:48 PM, carlo.acco...@ibs-ag.com a écrit :
 For this modification, I'm not using any controls. The attributes are not 
 null either. We set the cn and sn (which are required) to the string 'null' 
 when the entry is created to have a stub entry. 

Which is wrong : cn and sn have a DirectoryString syntax which does need
at least one char :

DirectoryString = 1*UTF8

So injecting null value sis not allowed. Now, you should get an explicit
error, instead of sucha OTHER resultCode.


-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com