The pharaoh was the absolute ruler and religious leader of ancient Egypt, holding the titles of "Lord of the Two Lands" and "High Priest of Every Temple." As ruler, the pharaoh owned all the land and people, made laws, collected taxes, and defended Egypt militarily. Pharaohs would go to war to protect Egyptian lands or expand their territories, requiring conquered people to recognize the pharaoh as their new ruler. In modern times, Egypt is a republic with Islam as the official religion and Sharia law forming the basis of its legal system. Executive power is held by a strong presidency, while the legislature consists of a single elected house.