President Dr Arif Alvi on Saturday signed the Official Secrets and Army Amendment Acts into law.
The assembly had passed the laws before their term ended last week.
Amendments made to the Official Secrets Act 1923, were to ensure the security of official documents effectively.
When the bill was presented in the senate, it came under severe criticism from both sides of the aisle, and Pakistan Peoples Party Senator Raza Rabbani even tore copies of his agenda and walked out.
Following opposition from the Muttahida Qaumi Movement, Jamaat-e-Islami, National Party and the Pakistan Tehreek-e-Insaf (PTI) that the provisions in the law would effectively allow the state to kill off political parties, the bill was referred to the relevant Senate committee where objectionable clauses were removed.
Similar objections in the Army Act were also addressed, and both bills were again presented on the Senate floor for voting.
It was then sent to the President for approval.
What is the Official Secrets (Amendment) Bill?
The Official Secrets (Amendment) Bill says anyone who deliberately creates a law and order situation or works against the state, attacks classified and prohibited locations or damages them to directly or indirectly benefit the enemy, then that would be considered a crime.
The amendments further suggest that unauthorized access to classified documents or information will be considered criminal.
Anyone inside or outside Pakistan, who works against its security or interests will also be prosecuted.
Those charged under this law will be tried before a special court, and the court will be bound to complete its trial within 30 days.
Per the amendments to the Army Act, any military official will not indulge in any political activity for two years after retirement, resignation or dismissal from service. At the same time, those deputed on posts or assignments deemed sensitive will be barred from participating in politics for five years.
Further, any officer or official found sharing information detrimental to the sanctity or interests of the state would be prosecutable.