If its the top hole in the picture (The way its posted here, which is sideways) That is the end of the shaft the camshaft turns on. If it was me and it was not leaking at the other end behind the flywheel, I would clean the hole with Brake cleaner to get the oil off and fill it with RTV. Then let it sit for 24 hours before I ran it.
If its leaking at the other end, it is probably loose in the hole and you need to remove the flywheel and the cover plate and drive it back in. This is right much of a job in most cases. And of course you need a new gasket and probably a pto seal as they are easily damaged.
That pin drives through from the other side of the case and is machined slightly larger on the other end so it wedges in the hole. If you ever take it out for any reason you need to put sealer in the hole before you drive it in.