Can't restore or update iPhone 5 - TATSU declined to authorize
I'm attempting to either restore or update an iPhone 5 which won't boot. It's stuck on the apple logo boot screen. Hard reset does nothing. There was no physical or water damage it just stopped booting last week.
Each time I try and either do update or restore I get the following error from iTunes:
iPhone could not be restored (or updated). TATSU declined to authorize this image on this device for this user.
I have noticed the IPSW file iTunes automatically downloads says iPhone4 in its filename which seems weird to me considering it's an iPhone5: iPhone_4.0_32bit_10.1.1_14B150_Restore.ipsw
I have also tried downloading one for iPhone 5 and doing command click on the update or restore button in iTunes to select that particular ipsw file but I still always get the same error.
I have tried normal restore mode and DFU mode via iTunes.
I'm signed into iTunes as the same apple ID as the phone.
I've authorized the mac for this apple ID in iTunes.
Anything else I can try? it does not matter if I lose the data on the phone. Just needs to work again. Is there a way to view the boot sequence from my mac or the phone either via terminal or xcode or something so I can see where it's hanging in the boot sequence?
iPhone 5, iOS 10.1.1