Well, this is obviously not supported functionality, since Apple knows that you might not own all the music on your network. But at least 2 ways of accomplishing it have been around: a program called Blue Coconut, which was an Applescript that you accessed from iTunes, and getTunes, which was its own application. I think what they do is pretend to be iTunes sharing clients, so they get the audio streamed to them, saving them locally in the process. This is slow, and for the last couple versions, iTunes has had a connections-per-library-per-day limitation, so if you're on a busy local network they might not be usable.
Plus I'm not sure if those two solutions are still around, but I'm sure if you Google 'em, you'll find comparisons between them and other options..