Did not know that. Does that catechism also include that one may have a right and duty to protect another person from a similar danger? Especially the weaker among us? Like elderly or women, children?
"Legitimate defense can be not only a right but a grave duty for one who is responsible for the lives of others. The defense of the common good requires that an unjust aggressor be rendered unable to cause harm. For this reason, those who legitimately hold authority also have the right to use arms to repel aggressors against the civil community entrusted to their responsibility."
I personally think that the father of a family has a right and under Natural Law to protect and defend his family, and I would go so far as to say an neighbor has the right and duty to use force, even lethal force, to stop an aggressor who is aggressing against his neighbor, broadly construed. It's a corollary of "love your neighbor."
However I am not sure how this plays out in terms of magisterial teaching. It seems that the magisterial teachings assume that in ordinary times, these functions can safely be reserved to the civil government. However, there are places and times in which this clearly not the case.
Interesting note, there is a popular Patron Saint for gun-owners: St. Gabriel Possenti.