How did they get constant hot and neutral at far switch?
I’ll be darned.  I’ve never seen one of those before in the wild.
It’s a “Carter” 3-way

How did this wiring work?

It’s specifically for a case where the lamp is between the 3-way switches.  Always-Hot and neutral go to each switch, and through the lamp without connecting to it.   Obviously hot and neutral can also extend from or beyond either 3-way.  So we have hot and neutral everywhere (except the lamp doesn’t use either one).
Now, each of the 3-ways has 1 traveler going to the lamp.   The 3-way connects the traveler either to always-hot, or to neutral.   This gives us 4 conditions.
 Sw1    Sw2       Resulting state
 Neu    Neu       Lamp does not light. Socket is neutral. 
 Neu    Hot       Lamp lights.  Socket is hot, obviously.
 Hot    Neu       Lamp lights.  Socket is hot, obviously.
 Hot    Hot       Lamp does not light. SOCKET IS HOT!


Is/was this illegal?

Oh you bet it was, because of that last case there.  Holy smoke-Andy!  The Edison shell is electrified at all, normally that’s impossible since it’s keyed to neutral and unswitched; and to compound the crime, it’s hot with the switch off! No, no, no!
However, we now live in an age where “bulbs” outlast “fixtures”, and therefore, the bulb socket is no longer useful and is only another failure point.  As such, it’s being done away with altogether.   Alternately, we have new socket designs such as GU24 specifically keyed to prevent incandescent use, and those are Euro-influenced (Europe doesn’t polarize, so they want to insulate both contacts).  This casts the Carter 3-way in a new light.
Personally, I don’t see a problem with it, as long as a) the fixture is bulbless and hardwired (I’ll guess Code supports my interpretation there), or b) the bulb socket is a modern “both pins protected” type like GU24 (and I’ll guess Code does not agree).
How to fix it
So.  My advice is to a) leave it, and b) fit a bulbless lamp there. You certainly don’t want anything with an Edison socket.   If the spouse is in love with a particular chandelier with Edison, then re-do the wiring as follows:

The traveler to one switch gets deprecated; cap it off on both ends.
The traveler to the other switch becomes switched-hot to the switch.
Place a smart-switch “master” at the switch box with switched-hot.
Place a smart-switch “remote” at the switch box with the deprecated wire.  It won’t use red at all.

Boy, I winding up to write you a solution with steam-era switches, then I realized “what am I doing, this is the 21st century”.
You will need to select smart switches that use wireless or powerline signaling, and whose remote wants always-hot and neutral.