On Mon, Jul 22, 2013 at 4:52 PM, Kiran Ayyagari <[email protected]>wrote:
> > > > On Mon, Jul 22, 2013 at 4:38 PM, Ado Dao <[email protected]> wrote: > >> When I search anonymous, e.g. with MS Outlook or so >> >> ldapsearch -h <host> -p 389 -x -b "dc=foo,dc=com" "[email protected]" >> >> IOSession is null >> >> with authentication >> >> ldapsearch -h <host> -p 389 -w secret -D "uid=admin,ou=system" -x -b >> "dc=foo,dc=com" "[email protected]" >> >> IOSession is != null >> >> you are right, in anonymous case we are not storing the IoSession in the > CoreSession > >> >> I was wrong, (I looked at the wrong code block (related to SASL auth)) the IoSession is set even in case of anonymous authentication, please check your code or give us a test case(or steps) to reproduce this issue > I Used the embedded sample from: >> >> https://svn.apache.org/repos/asf/directory/sandbox/kayyagari/embedded-sample-trunk/src/main/java/org/apache/directory/seserver/EmbeddedADSVerTrunk.java >> >> Is there any possibility to get the Client-IP address with anonymous bind. >> >> -- >> Regards >> Ado >> >> >> >> >> >> > Date: Sat, 20 Jul 2013 06:03:56 +0200 >> > From: [email protected] >> > To: [email protected] >> > Subject: Re: getClientAddress() does not provide remote connection info >> for anonymous connections >> > >> > Le 7/20/13 2:22 AM, Ado Dao a écrit : >> > > Hi Emmanuel, >> > > thanks for your answer. >> > > >> > > From DefaultCoreSession.java: >> > > ... >> > > public SocketAddress getClientAddress() >> > > { >> > > if ( ioSession != null ) >> > > { >> > > return ioSession.getRemoteAddress(); >> > > } else { >> > > return null; >> > > } >> > > } >> > > ... >> > > >> > > >> > > In Anonymous Mode is the IOSession == null. Only in Authentication >> Mode is the IOSession != null. >> > >> > You are doing a search without a bind, I guess ? >> > >> > >> > -- >> > Regards, >> > Cordialement, >> > Emmanuel Lécharny >> > www.iktek.com >> > >> >> > > > > -- > Kiran Ayyagari > http://keydap.com > -- Kiran Ayyagari http://keydap.com
