Despite his hard-line stand , Netanyahu signed an agreement with the Palestinian leadership to share Hebron , a highly contested city in the occupied West Bank , during his earlier tenure as prime minister .