I apologize for the verbosity - I don't know the relevant terminology that would make my situation clearer.
I have a metal cabinet with this lock (which doubles as the door handle). The first image shows the locking mechanism (this is it in the allegedly "locked" configuration, with the moveable flange pushed out). The second image is the lock physically rotated 180 degrees, with a static metal flange. The third image shows the mounting point on the door; the indentation on the right corresponds to the moveable flange (which should prevent the handle from rotating when the moveable flange from image 1 is pushed out, i.e. the door is locked), and the indentation on the left combined with the static flange from image 2 allows the handle to rotate 90 degrees when the door is unlocked. Note the square shape of the back of the lock, which connects to rods that move to actually prevent the cabinet from being opened when the lock is engaged. The issue is that the moveable flange that should lock the door does not project far enough out, so the door handle can be rotated when the door is locked.
My main question is whether this lock is some kind of standard type that can be replaced, or whether it is a bespoke piece of hardware specific to this cabinet door. I don't know the terminology for the square shape on the back, so I'm hoping that I'm simply not using the right search terms.
If it is bespoke and not replaceable, do I have any alternatives to potentially lock this door? This mount point is on the right door, and the left door has a flange that prevents it from being opened unless the right door opens, so I could potentially use something like a standard cabinet door cam lock to keep the door closed, although I would need a longer flange.