Where is there a discussion where one can or can not injure or kill anybody who trespasses one's property?
I took a class earlier this year that addressed your question and related topics. Here's what I learned. The following sources are from a class at Kulam Pittsburgh taught by R' Will Friedman from the Pardes Institute:
First, the torah tells us in Shemot 22:1-2 that if a thief is found breaking in and is killed there is no guilt (for the killer), but if the thief comes by daylight and is killed there is guilt.
Tosefta Sanhedrin 11:9 understands the first case (the thief breaking in, literally tunneling in, by night):
- If he came to kill, one may kill him extrajudicially.
- If he came to steal money, one may not kill him extrajudicially.
- If there is doubt about which of those it is, one must not kill him extrajudicially.
Sanhedrin 72a says in the mishna that one found breaking in may be killed. The g'mara explains:
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.
R' Nissim (the Ra"n, according to my class handout), writing in the 14th century, argues: surely not all thieves come with murderous intent; some would drop the stolen goods and run if confronted, and since theft is not a capital transgression the homeowner is not justified in killing the thief. However, he continues, this concern is overriden by the fact that some homeowners won't restrain themselves, and all thieves know this and must accept it. So since it's the thief who set everything in motion, the torah deems the thief a rodef and he can be killed.
Meanwhile, the Yerushalmi in Sanhedrin 8:8 says: R' Shimon ben Yochai permits the homeowner to chase after the thief even after he leaves and kill him, because a person's money is as dear to him as his life. Rav Huna says the homeowner is not guilty if the thief, while still in his house, turns to leave.
hazoriz suggested the following additional sources in a comment (thanks!):
The Rambam here rules:
When a person breaks into a home - whether at night or during the day - license is granted to kill him. If either the homeowner or another person kills him, they are not liable. The license to kill him applies both on the Sabbath and during the week; one may kill in any possible manner. This is all implied by Exodus 22:1, which literally reads: "He has no blood."
The license mentioned above applies to a thief caught breaking in or one caught on a person's roof, courtyard or enclosed area, whether during the day or during the night. Why does the Torah mention "breaking in," because it is the general practice for thieves to break in at night.
Why did the Torah permit the blood of such a thief to be shed, although he is only attempting to steal money? Because it is an accepted presumption that if the house-owner arises and attempts to prevent the thief from stealing, the thief will slay him. And thus the thief entering his colleague's house to steal is in effect a pursuer seeking to kill his colleague. Therefore, he should be killed, whether he is an adult or a minor, or a man or a woman.
If it is clear to the house-owner that the thief who breaks in will not kill him and instead is only seeking financial gain, it is forbidden to kill the thief. If the house-owner kills him, the house-owner is considered to be a murderer. This is alluded to by Exodus 22:2, which states: "If the sun shines upon him..." - i.e., if it is as clear to you as the sun that he is at peace with you, do not kill him. Therefore, a father who breaks into his son's home should not be killed. But a son who breaks into his father's home may be killed.
See also the Rema here:
One who "tunnels in order to steal" has this rule of pursuer applied to him, however if it is understood that his only intent is monetary gain, and that he would not kill the owner in a confrontation, then it is forbidden to kill him.
The Rambam and the Rema agree that if it's clear the thief doesn't intend to kill then it's not ok to kill him, but otherwise it is (at any time of day). This appears to be the halacha. Not addressed there (and I think it's beyond the scope of the current question) is how one should determine the intent of the thief.