It predates Ubuntu and Debian, and the design decision in these OSes has been, as far as I can tell, lack of a contrary design to change historical X-Windows behavior.
I realize I'm responding to an old question, but I'm talking about the 80s and 90s, so I think that's fitting.
See also Jeff Atwood's post at Codinghorror.com. (2008, sheesh! Practically yesterday.)
In the UNIX and X Windows world, the middle button has also meant
paste since way, way back in the 1980s. I can't find any evidence of
this behavior on Windows or the Mac, however. Pasting into text areas
wouldn't necessarily conflict with the tab behavior, but it's an odd
hodgepodge of behaviors to attach to a single button.
Indeed, I pasted that block quote with my ancient and still functioning PS/2 three-button mouse (no scroll-wheel ; a real three-button mouse).
I recently ordered a new-fangled yet old-school 3-button mouse. This one is optical and has a usb connector. Wow. It was about $20 USD, and available from many online vendors.
Behold, the HP DY651A :
I'd say buy one now, so you can enjoy an authentic X-Windows *nix experience before it disappears.