Thales' cellular IoT products business is now part of Telit Cinterion, find out more.

You are here

IP Validation before accepting incomming client request | Telit Cinterion IoT Developer Community

November 9, 2015 - 10:59am, 2343 views

Is there any way to validate IP of incoming client request from remote devices before accepting socket request in SocketServer App ?

 Known method like below;

      System.out.println("wait client connection");

   sc = (SocketConnection) scn.acceptAndOpen(); 

   serRemoteIP = sc.getAddress();

   System.out.println("TCPserver Remote IP : " +serRemoteIP);   

       if  (serRemoteIP.indexOf("188.51.29.57")> -1){