Rehoboam fortified several towns to defend Judah from the east, south, and west. This protected the valleys leading into the Judean hill country and important crossroads. Rehoboam's first task was to strengthen a small but defensible position. The defensive lines were strategically sensible against an Egyptian attack and likely started before Pharaoh Shishak's invasion in 926 or 925 BC.