"Fear not, Abram." From here you learn that Abraham was afraid that the nations would come against him. "I am a shield to you." Just as this shield, all the blows upon it — whether arrows or swords — it bears them, so I will be a shield to you: whoever comes against you, I will fight against him. Another interpretation: Why was he afraid? He said, "Perhaps I struck down a righteous man among them." The Holy One, blessed be He, said to him: "You shall not be punished before Me; rather, 'your reward shall be very great,' and I am obligated to give you a great reward for having killed the wicked."
Why Abram Feared and How God Became His Shield
Midrash Aggadah, Genesis 15:1
אל תירא אברם. מיכאן אתה למד שהיה אברהם מתירא שלא יבואו האומות עליו: אנכי מגן לך. מה המגן הזה כל הכאות עליו בין חצים בין חרבות סובל אותם, כך אני אהיה מגן לך כל מי שיבא עליך אני אלחם כנגדו: ד"א למה נתיירא, אמר שמא הרגשתי צדיק בהם, אמר לו הקב"ה לא תענש לפני, אלא שכרך הרבה מאד ושכר גדול אני חייב ליתן לך על שהרגת את הרשעים: