I think people sometimes forget that dogs are animals. I really do. All animals, in order to survive in nature have a flight distance that they keep between them and something that is unfamiliar or novel to them. It varies depending on a lot of factors. Dogs can be 1) curious about something which is harmless that they never saw before and will decrease the distance. And they can be 2) afraid of something and increase the distance between them and the unfamiliar thing. The later is the stronger of the two. If they made too many mistakes about the thing they were curious about and it is not harmless, but dangerous, they would not reproduce, could not pass on the genes to be curious because they'd be dead or injured. So, the stronger propensity is to keep distance between them and the unfamiliar. The thing that they're curious about is not necessary to survive. They haven't seen it so far in their life so it is not necessary...only a curiosity. When something is scary, the necessity to increase distance is very strong.
In other words, it's all about socialization. There is a window of time during puppyhood where their curiosity and willingness to adapt to novel things is strong. When that window closes at somewhere before 5 months, getting habituated to new things is extremely difficult. If they haven't seen something before, they will tend to want to keep distance between them and the novel thing. If they are cornered, and can't flee, they'll fight.
Some breeds are more difficult to socialize and it takes more management to compensate. They have been bred to be more aloof with novel things than some other breeds.
Biting is normal behavior for dogs to settle disputes and such. There aren't two kinds of dogs; dogs that don't bite (good dogs) and dogs that do bite (bad dogs) or dangerous dogs....They all can be dangerous. They all can bite. They're animals. That's how they work out their issues. We use lawyers and police and law makers. Dogs use their teeth and growls and other displays of intention to bite. Growling and biting is normal behavior in dogs. As predators, the distance between them and their prey must be reduced.
If animals did not have this flight distance mechanism, they could not survive. Fear of novel things, increasing flight distance is the default setting for all animals, including humans. For a dog to become habituated to the novel things in a human's world, it must be done artificially by humans. Pressure is put on the dogs to adapt to our human world. This comes by way of early socialization and training. And continued socialization.
There are two choices with regard to reaction to dangerous/scary novel things; fight or flight. With artificial selective breeding, some dogs have had the aloofness to novel things extenuated. And the flight part of fight and flight reduced.
Anyhow, as it was said, habituation and compensation for more aloof dogs, dogs that have a stronger propensity to either increase distance or fight has to be managed differently than dogs that are more easily adaptable to novel things.
Bottom line and part of why I wrote all that stuff: I really think that often, people forget dogs are animals and think something is abnormal or wrong with dogs that bite, that they are "bad" dogs. Then they get executed for being what they are and what humans have neglected to do with them in order to make them fit into a human world.