Cue the sputtering outrage...until someone points out that Canada does the same thing to other nations. 

The Snowden documents showed that Canada, along with its Five Eyes partners, is up to its eyeballs in committing cyber-espionage. We hacked the Brazilian Ministry of Mines for example, likely seeking secret information on their oil industry. So it's a simple case of other nations doing to us what we're doing to them. 

Getting our moral knickers in a knot about this is a waste of time and resources.  The best solutions are cyber-treaties with other nations, combined with the best possible cyber-defences to ward off everyone else. Treaty nations don't hack us, we don't hack them. The problem isn't eliminated completely, but the best-funded and most capable attacks are greatly reduced.