Consider the traditional CCS circuit: opamp, FET with shunt resistor, load.
Move the amp's feedback connection to a voltage divider on the load terminal. Boom, you have a shunt regulator!
More generally: if you prepare both of these situations, and connect the amp's feedback to the wiper of a potentiometer going between the two extremes, you can also have a variable resistance load! (The pot can be digitally programmed, or it can be synthesized with some clever, albeit dated, analog circuitry.)
(Note that you can't literally string a pot between a resistor divider and a shunt resistor; the pot will pull down on the divider, and the shunt will impose some of its voltage even when the pot's all the way to one side. Easy solution: buffer the divider with an op-amp follower. Ideally, the same would be done on the shunt signal, but its value may be low enough not to worry about this. If you're making this for very small current ranges, this would be a good idea.)
Tim