Philippine President Rodrigo Duterte said on Friday he would respect defense treaties with "friends" and "ally" the United States, but still wanted foreign troops to leave his country by the end of his term.

Duterte spared the United States one of his trademark verbal lashings and took a more conciliatory tone than usual, although he hinted at revoking the 2014 Enhanced Defense Cooperation Agreement (EDCA) that gives U.S. troops rotational access to Philippine bases.

"We are friends, with an ally, we have a military pact that would bind us," he told a pre-dawn news conference upon his return from a visit to Malaysia.