Seems to me he's acing out because he is scared , he sees you are as being a nasty human , and he was probably physically abused by the person who had him before you who probably lost interest in him and may even have hurt him physically on a regular occasions to punish him for defending himself (a real hero).
You need to build a trusting relationship with him , I'd start off by spending a lot of time hanging out with him (him inside his "nice safe enclosure" where he can see and hear you, and you talking calmly to him and showing him you are not going to harm him.
I'd make intrusions into his hand daily only to remove poos, clean and replace food and maybe give him a light misting if it's warm, and would avoid any unnecessary physical contact with him for a few weeks , let him settle in and get to know you.
Then I'd start off with small things like offering a treat and petting him, every time he threatens you , pop a food treat in him open mouth , he's soon come to regard you as food giver and then 3/4 the battle is over.