Torah sets out examples of when we should take up arms.
(יד) וַיִּשְׁמַ֣ע אַבְרָ֔ם כִּ֥י נִשְׁבָּ֖ה אָחִ֑יו וַיָּ֨רֶק אֶת־חֲנִיכָ֜יו יְלִידֵ֣י בֵית֗וֹ שְׁמֹנָ֤ה עָשָׂר֙ וּשְׁלֹ֣שׁ מֵא֔וֹת וַיִּרְדֹּ֖ף עַד־דָּֽן׃
(יח) וַיַּסֵּ֨ב אֱלֹקִ֧ים ׀ אֶת־הָעָ֛ם דֶּ֥רֶךְ הַמִּדְבָּ֖ר יַם־ס֑וּף וַחֲמֻשִׁ֛ים עָל֥וּ בְנֵי־יִשְׂרָאֵ֖ל מֵאֶ֥רֶץ מִצְרָֽיִם׃
Can we bear arms on Shabbat?
מתני׳ ואלו הן שמצילין אותן בנפשן הרודף אחר חבירו להרגו ואחר הזכר ואחר הנערה המאורסה אבל הרודף אחר בהמה והמחלל את השבת ועובד עבודת כוכבים אין מצילין אותן בנפשן:
גמ׳ ת"ר מניין לרודף אחר חבירו להרגו שניתן להצילו בנפשו ת"ל (ויקרא יט, טז) לא תעמוד על דם רעך והא להכי הוא דאתא האי מיבעי ליה לכדתניא מניין לרואה את חבירו שהוא טובע בנהר או חיה גוררתו או לסטין באין עליו שהוא חייב להצילו ת"ל לא תעמוד על דם רעך אין ה"נ
MISHNA: And these are the ones who are saved from transgressing even at the cost of their lives; that is to say, these people may be killed so that they do not perform a transgression: One who pursues another to kill him, or pursues a male to sodomize him, or pursues a betrothed young woman to rape her. But with regard to one who pursues an animal to sodomize it, or one who seeks to desecrate Shabbat, or one who is going to engage in idol worship, they are not saved at the cost of their lives...
GEMARA: The Sages taught in a baraita: From where is it derived that with regard to one who pursues another in order to kill him, the pursued party may be saved at the cost of the pursuer’s life? The verse states: “You shall not stand idly by the blood of another” (Leviticus 19:16); rather, you must save him from death. The Gemara asks: But does this verse really come to teach us this? This verse is required for that which is taught in a baraita: From where is it derived that one who sees another drowning in a river, or being dragged away by a wild animal, or being attacked by bandits [listin], is obligated to save him? The Torah states: “You shall not stand idly by the blood of another.” The Gemara answers: Yes, it is indeed so that this verse relates to the obligation to save one whose life is in danger.
(ו) מותר ליכנס בב"ה במקלו ובתרמילו ובאפונדתו (פי' מיני כיסים תרגום ובילקוט ובתרמילו) ויש אוסרים ליכנס בו בסכין ארוך או בראש מגולה:
(6) It's permitted to enter the synagogue with one's staff or satchel or backpack (meaning, purses - the Targum has backpack to be briefcase). Some forbid entering with a long knife or with it's blade uncovered.
גמ׳ אמר רבא מאי טעמא דמחתרת חזקה אין אדם מעמיד עצמו על ממונו והאי מימר אמר אי אזילנא קאי לאפאי ולא שביק לי ואי קאי לאפאי קטילנא ליה והתורה אמרה אם בא להורגך השכם להורגו
GEMARA: Rava says: What is the reason for this halakha concerning a burglar who breaks into a house? He explains: There is a presumption that a person does not restrain himself when faced with losing his money, and therefore this burglar must have said to himself: If I go in and the owner sees me, he will rise against me and not allow me to steal from him, and if he rises against me, I will kill him. And the Torah stated a principle: If someone comes to kill you, rise and kill him first.
Do we feel safe returning to synagogues?
אָמַר רַב חִיָּיא בַּר אָשֵׁי אָמַר רַב: כֹּל שֶׁאֵין דַּעְתּוֹ מְיוּשֶּׁבֶת עָלָיו אַל יִתְפַּלֵּל, מִשּׁוּם שֶׁנֶּאֱמַר: ״בְּצָר אַל יוֹרֶה״. רַבִּי חֲנִינָא בְּיוֹמָא דְּרָתַח לָא מְצַלֵּי, אָמַר: ״בְּצָר אַל יוֹרֶה״ כְּתִיב. מָר עוּקְבָא בְּיוֹמָא דְשׁוּתָא לָא הֲוָה נָפֵיק לְבֵי דִינָא.
Is there a safety limitation with regard to the times we extend ourselves to the stranger, the hungry, etc.?
...בגמילות חסדים כתיב (משלי כא, כא) רודף צדקה וחסד ימצא חיים צדקה וכבוד ובהבאת שלום כתיב (תהלים לד, טו) בקש שלום ורדפהו וא"ר אבהו אתיא רדיפה רדיפה כתיב הכא בקש שלום ורדפהו וכתיב התם רודף צדקה וחסד
... With regard to acts of loving kindness it is written: “He who pursues righteousness and kindness shall find life, prosperity, and honor” (Proverbs 21:21), all of which apply in this world. And with regard to bringing peace it is written: “Seek peace and pursue it” (Psalms 34:15). And Rabbi Abbahu says: This is derived through a verbal analogy between the term pursuing written with regard to pursuing peace and the term pursuing written in another verse. It is written here: “Seek peace and pursue it,” and it is written there, with regard to acts of kindness: “Pursues righteousness and kindness.” This teaches that one who pursues peace will also merit life, prosperity, and honor.