First of all UNSCR 242 is clear, there is some ambiguity in the English version but the French version is crystal clear. Both versions have the same legal importance and when they are considered together there is no gray-area whatsoever. Further more the acquisition of territory through force is banned in international law not only through treaties but also in customary law. So you will be no doubt be glad to find that the occupation is illegal after all.
Malaysia sends team to Reunion Island to see if aircraft debris is from MH370 flight (Reuters)
from the article: It's wrong to push out Israeli settlers, even if its legal