It's GNU Readline[0] or similar. It's all over the place, on Linux at least. Being GNU it defaults to emacs, but the vi support is also excellent. The first thing I type in any foreign bash is 'set -o vi'.

[0] - https://en.wikipedia.org/wiki/GNU_Readline