A new Israeli law barring contact with the UN refugee agency for Palestinians is set to take effect at the end of January.