I am assuming these are steel or stainless steel into an aluminium casting. Never a good mix with seawater included nearby.
1 Make sure the socket used is a snug fit over the head. Also a socket with a slightly star design will ensure the grip point is along the flats of the bolt head and not just on the corners.
2 A sharp tap on the head with a medium size hammer will often shock any corrosion free.
3 Finally a very hot flame such as found with a gas soldering iron adaptor tip concentrated right onto the bolt head for say 30 seconds, then apply the socket and see if it will let go (obviously shut off any petrol nearby first).
4 If none of the above work then the offending heads have to be cut off, followed by grinding back the stub flush, carefully mark and centre punch the centre, then drill out to the tapping size of the bolt thread, then re-tap the thread using a decent quality tap set (taper, middle and bottom or plug taps), although if the tapping hole is sufficiently accurate the remnants of the bolt threads may literally fall out, at least from the first few threads allowing the tap to pick up the original thread. Lubricate the tap thoroughly.
Once they are free replace with a coating of waterproof grease or Duralac. Don't use copper slip.