Trump said on social media the agreement had been approved by countries including Israel, Saudi Arabia, Qatar and the United Arab Emirates.
Parliament passed the amendments to the law known as Pakistan Electronic Crimes Act last week.