After the Portuguese occupation of Malacca in 1511, many Islamic traders passing the Malacca Straits shifted their trade to Banda Aceh and increased the Acehnese rulers' wealth. During the reign of Sultan Iskandar Muda in the 17th century, Aceh's influence extended to most of Sumatra and the Malay Peninsula. Aceh allied itself with the Ottoman Empire and the Dutch East India Company in their struggle against the Portuguese and the Johor Sultanate. Acehnese military power waned gradually thereafter, and Aceh ceded its territory of Pariaman in Sumatra to the Dutch in the 18th century.