They are not rude words in themselves, but they can be used as insults.
"Mangy" literally means "to have the mange," a disease of animals, caused by skin parasites, that causes their hair to fall out. The patchy appearance is ugly. It shows that the animal is not well cared for. Only animals get the mange, not humans. As far as I know, it is only used literally, and only about animals.
Writing about stray dogs in Constantinople (Istanbul) in the 1800s, Mark Twain wrote: "They are mangy and bruised and mutilated... They are the sorriest beasts that breathe—the most abject—the most pitiful. In their faces is a settled expression of melancholy, an air of hopeless despondency."
"Lousy" literally means "to have lice." Lice are vermin, little insects that live on the skin of mammals, including humans, usually in the places that have hair. They bite the skin, drink blood, and cause itching.
"Lousy" became a slang expression for anything bad or of low quality. "Don't buy [automobile brand], they're lousy cars." "They cut your pay? What a lousy deal!"
"Nasty" simply means disgusting, unpleasant, bad. "Get that chicken out of the refrigerator, it smells nasty." "I think I'll stay indoors today, it's nasty weather out there." "Stay away from X, he's a really nasty person."
In a kind of reversal, I THINK that nowadays "nasty" has acquired a sort of positive meaning among young people with respect to sexuality, but I'm not going to try toe explain because it's NOT language I use myself and therefore I don't understand the usage. But see, for example, Janet Jackson's song "Nasty:" "Nasty boys, let me see your nasty body move, huh."