Simon Bridges says the National Party has not been involved in any computer hacking and the government is "lashing out in a witch hunt".
The National Party yesterday released what it said were "key details" of the government's Wellbeing Budget, due tomorrow.
Then yesterday evening Treasury announced it had been "deliberately and systematically hacked" and the matter had been referred to police.
Watch Simon Bridges' full media standup:
He said there had been no hacking "under any definition of that word".
"There has been entirely appropriate behaviour from the National Party.
"There has been nothing illegal or anything approaching that from the National Party."
He said he was not going to disclose how National obtained the information.
Mr Bridges told reporters that was the case of a "bungling and incompetent" government that was not in control of what it was doing and was "lashing out" in a "witch hunt".
He said the government was trying to trying to "gag the opposition of New Zealand, and that is an undemocratic outrage".
"They will have got Treasury and others in, and they will be looking for scapegoats.
"Treasury, in the multiple things they have said, have got many things wrong."
"As a former Minister in charge of cyber security issues, there are things going on every day. Frankly if you went six months ago and you had a look around Treasury, there would be actors from all over the place trying to hack the Treasury. But I've been categorical with you, the National Party has not received its information from anything like that."
He said Finance Minister Grant Robertson was lying and smearing the National Party.
"Grant Robertson has made scurrilous, false allegations."
Asked if he would resign if National was found to have hacked Treasury systems, Mr Bridges said: "That is not going to happen. You have my categorical assurance about that."
Mr Bridges said it was "not his intention" to release any more information from the Budget today.
Treasury Secretary Gabriel Makhlouf told Morning Report today its systems had been attacked 2000 times in the past 48 hours in an attempt to get Budget-related information.
Mr Makhlouf said he was not accusing National of the attack.
After the Treasury statement last night, Mr Robertson contacted the National Party asking them to not release any more material given the seriousness of the situation.
But Mr Bridges hit back on Twitter, saying his party was being falsely smeared and that Mr Robertson would have to resign when the truth came out.
Mr Bridges said he had no intention of revealing where the Budget documents came from, but would not go as far as calling it a leak.
"I'm very confident in the information," Mr Bridges said.
"I think what it shows is a loose, incompetent government."