My dog and I are trained in 'personal protection'. This sounds very similar to what you are asking about. A brief description of what we do: at the command 'watch', Indigo will bark, snarl, lunge, snap-ALL on leash. At the command to stop 'out', he stops immediately and comes to a heel position. We do not do bite or chase work; tho I have no doubt that Indigo would do both if he was let off leash. I live alone and frequently walk at night, so I am fine if, when I am threatened, Indigo would bite if I let him.
You will need an experienced trainer to help you, as they act like the bad guy, My trainer is also very good at assessing the abilities of the dog. Not all are able to protect, some take to it well and some do it out of fear, which is a whole 'nother issue. I have seen personal protection offered by other trainers in different areas. Speaking for me and Indigo, it is our favourite part of training!