A scuba diver used his speargun to fend off a great white shark that got a little too close for comfort in a video that's gone viral.

The footage, taken off the east coast of Florida, shows a fin smacking the camera as the shark swims past Jimmy Roseman.

It reappears, and Roseman stabs it with his speargun after it turns on him.

Watch the headcam video by clicking here.