No wheel drive

I have a technical question….. I broke my bike a few weeks ago and am just now getting around to fixing it. 2002 Grizzly 660. I popped the rear driveshaft, in a DEEP mud hole, but still had front wheel drive, so I attempted to use it to get me out of the hole. Something popped…. Now the rear driveshaft spins, the front doesn’t. I’m thinking it’s the middle driven shaft. Any thoughts? or recommendations on the best way to perform this repair?

Thanks in advance.

BA