This is a knurled nut for Goiot boat hatches which are used for example on older Amel sailboats. In the photos on the left there is the original, on the right the 3D printed replacement part. The M8 thread is allready in the 3D model, but you should need to tap it in order to work smoothly.
I printed it in PETG, it may get hot under boat hatches, so do not use PLA.
The author marked this model as their own original creation.