Network protection

Added functionality to guard network changes.