modified the IP related variable and function