Section 34 of The Criminal Code of Canada (Defense of Person, paraphrased) states that anyone who experiences an unprovoked assault has the right to respond with force if the force used is no more than necessary to allow self defense.
34. (1) A person is not guilty of an offence if
(a) they believe on reasonable grounds that force is being used against them or another person or that a threat of force is being made against them or another person;
(b) the act that constitutes the offence is committed for the purpose of defending or protecting themselves or the other person from that use or threat of force; and
(c) the act committed is reasonable in the circumstances.
This represents our teaching goal for self-defense: to give you the tools you need to defend yourself, to ensure that you survive an adverse encounter and go home safely.