A new offence will be created for people who hold a government security clearance, or those given access to classified information, who wrongfully communicate, retain or copy it.
Intelligence agency employees who encounter evidence of wrong-doing can make a protected disclosure to the Inspector-General of Intelligence and Security.
But if they give information to others or the media they face a prison sentence of up to five years in jail.
The new legislation will cover both the SIS and GCSB, and accepts one of the most controversial recommendations - allowing the GCSB to spy on Kiwis.
That breaks a longstanding split between the SIS and GCSB, under which the GCSB could only spy on foreigners and the SIS on New Zealanders.
The current law already allows the GCSB to spy on behalf of other agencies, with an approved warrant.
However, in releasing his review in March, Sir Michael said the GCSB had become hesitant to legally assist other agencies in such spying.
That happened after it was found to have possibly unlawfully spied on New Zealanders due to confusion over its powers when acting on behalf of other agencies.
The review recommended a single warranting regime that would have resulted in the SIS and GCSB having the same powers to collect intelligence.
The new legislation does not go quite that far - it will limit the GCSB to conduct remote searches of a computer, for example, while the SIS will be permitted to carry out a physical search of a private property.
If the agencies are operating under a joint warrant they will both be able to carry out all activities, including interception of communications, searching including of private premises, seizure and surveillance.
The new law would establish a single warranting framework for both agencies.
New Zealanders will be targeted only to protect national security or where they are an agent of a foreign power.
A "Type 1" intelligence warrant would be needed to target New Zealanders using otherwise unlawful activities, such as intercepting phone calls.
It would need approval from the Attorney-General and a Commissioner of Intelligence Warrants and will be subject to review by the Inspector-General of Intelligence and Security. This has been called a "triple lock" process.
There will also be new flexibility in terms of getting warrants, including allowing warrants for classes of people and "purpose-based" warrants.
The Government gave the example of the intelligence agencies being alerted to a group of unidentified New Zealanders in Syria. A group warrant would allow them to target those people without having exact information on their identities.
A purpose-based warrant would specify the type of information sought - for example, a warrant to intercept communications to find out if New Zealanders are fighting with Isis in Syria.
Finally, urgent warrants can be sought in special cases, including where someone's life is at stake or there is a serious threat to New Zealand's national security.
In such cases, a warrant must still be applied for within 24 hours and if it is not authorised all information collected would be destroyed.
While allowing the GCSB to spy on New Zealanders, the Government says both it and the SIS will only be allowed to do so on the grounds of national security.
Labour leader Andrew Little said the definition of national security was too broad and "must be narrowed down to actual threats to security and government".
The party will support the legislation at the first hurdle, but wants that and other changes before it would support it further.
Little said it was also concerning that the legislation appeared to have ignored recommendations related to protections for personal information.
"These are vital and must be a part of the legislation. In today's world it is too easy to ignore privacy concerns and we have seen what happens in the past when protections aren't clear."
Under the legislation, intelligence agencies would have direct access to other Government database information including birth, death, marriage, name change, citizenship, immigration and Customs information.
A warrant is needed to access IRD records, numbers assigned to tertiary students and driver licence photos.
The SIS wants to access private student numbers so they can catch spies posing as international students.
Key, who cited the threat from terrorism during a press conference on the changes, said political parties needed to think carefully about opposing the changes.
"It is going to be very difficult for political parties if they don't vote for this legislation and there was ultimately an issue in New Zealand, then clearly fingers would be pointed about whether we could have done more to stop it."
The legislation will be introduced to the House on Thursday.