I'm sure you could use SAE5 there, but why take chances? I got SAE8, and suggest you do as well. I also know that CRES capscrews will work there as well - I used them for a while just to check (CRES is typically H&T to ~SAE6-7 level. It's just not carbon steel, and SAE-spec screws have to be carbon steel H&T to specified levels.)
.312-24x1.170 comes out to 5/16"-24x1-1/8" (you're not likely to find these,) x1" (you can find these at the hardware store, but I don't like using shorter screws without a compelling reason) or x1-1/4" (which I used. There's room.)
The socket heads should only be used on the axle yokes - you don't have room to get a hex key in on the double Cardan yoke screws between the yoke and the transfer case. I've tried...
You should be able to find the 1/4"-28x1" socket heads and the 5/16"-24x1-1/4" capscrews at the local hardware store without any difficulty and for a reasonable price (I think the capscrews run me about a dime each, and the socket heads about forty-fifty cents the pair.) I don't go to the dealer very often - although I do send a lot of parts business their way... Go figure.