H25 mast step R&R
The bolts are of two kinds. The front machine screws should be reinstallled in the same holes-- but beforehand, wet out the inside of the holes in epoxy and, when it's dry, ream them through (gently) with a drill bitt for a fresh opening. Then apply a little 5200 or 4200 under the washers as you tighten them. Consider using hex-head cap screws for these with the heads facing down to have the threads and nuts out of the way. It doesn't matter which way they face. Use nylon-insert locknuts on these. You might want to fabricate a backing plate of aluminum or fiberglass for under the deck; but in general nearly all the load on a mast step is downwards-- towards the deck-- and side-to-side. It won't 'fall off' unless the boat goes upside-down.
The back bolts are SS lag screws going straight down into the top of the compression post. In reinstalling these, use a syringe to drip some epoxy down into the blind holes in the top of the wooden compression post. End grain is notorious for soaking up moisture-- however, it will likewise soak up epoxy really well. While the epoxy is still wet in the holes, run the lag screws in (slowly). When cured, the epoxy will keep the lag threads 'fresh' in the wood while also adding adhesion. If ever you need to remove this again and find them hard to budge, don't force them but apply direct heat from a soldering gun and it will warm the epoxy enough to let you back out the screws.
This of course relies upon your having a sound compression post in the first place. If it's questionable, don't live in denial-- its failure can cause the whole deck to cave in and possibly the mast to come down. A pro (like me) can get you a new one made. (Avoid pressure-treated for anything on a boat-- I have cited my half-dozen reasons elsewhere in these boards.)
Your photo doesn't seem to blow up; but from what I can tell that looks like a PO's mod and may be rather bodged-up. I would strongly consider replacing that mess with a tailored plate of G-10 or laid-up fiberglass. (You can find this at McMaster-Carr: mcmaster.com.) Planning to replace this allows you to chisel the heck out of what you have and to clear off the deck and start afresh. The new plate can be about 1/2" thick (this is a stock thickness) and cut to size. I would make it about 1-1/2" or 2" bigger all the way around, the better to spread the load. I would not mount halyard turning blocks through it but would use a stainless-steel plate for this-- Garhauer and DAMCo both make excellent ones that fit the H25' step. (I used the Garhauer one on my boat.) The fewer holes through the deck, the better-- and the plate mounted under the mast step transmits all the upward and outward pull of the halyard blocks in opposition to the downward compression of the spar-- rather a tidy cancellation of unnecessary arms and moments.
Mind that when cutting G-10, it will likely kill every tool you have. This is fiberglass to the tenth power-- so get carbide-tipped jigsaw blades and drill bitts, use plenty of water to keep them cool, clamp the part well, wear a mask and goggles, and go slowly and carefully.
Given a sound deck structure (having no rotting core or other problems), the SS mast-step plate should be bedded down with 5200. Be liberal with it; and be sure to sand the deck surface with at least 100- or 80-grit and clean well with acetone before application of the 5200. The one thing 5200 does not stick well to is dust.