Adding code for wep