update the way to handle ipaddress attribute

http://tickets.opscode.com/browse/COOK-3134