The second attack did not affect Ukraine's power network, Vsevolod Kovalchuk told a news briefing on Friday.
"The virus was slightly different, of a different nature, similar to WannaCry," he said. "The effect from it was insignificant, as some computers remained offline."
A computer virus spread from Ukraine across the world earlier this week, paralysing thousands of machines, shutting down ports, factories and offices as it spread to an estimated 60 countries.
Dispatchers are seen inside the control room of Ukraine's National power company Ukrenergo in Kiev, Ukraine, October 13, 2016.
Ukrainian state power distributor Ukrenergo was hit by another cyber-attack on Thursday which used a computer virus different from one that hit Ukraine on Tuesday, said Ukrenergo's acting head said.