Some probing with an ohmeter, followed by some simple driver code on your microprocessor and you'll be stepping in style.
Step 1: Get to Know Steppers
First step is to figure out if it's a unipolar or bipolar motor. Have a look at Jones on Steppers for some deeper background, then at Ian Harries' Site for a simple method to figure out an unknown motor.
Read up a bit, then join me in a walkthrough of this motor I got for cheap. (They're on sale for $0.99 right now. They're small, relatively light, but don't have much torque. Don't know what it'll be good for yet.)
Step 2: Find Common Ground
If you're only looking at four wires, you're in luck -- it's a bipolar motor. All you have to do is figure out which two pairs of wires go together.
If you've got a unipolar motor, or more than 4 wires, you're going to have to break out your ohmeter. What you're looking for is the common (ground) wire for each half. You can tell which is ground in a bipolar motor because it has half the resistance to either of the poles than the poles do across themselves.
Pictured is my notes from hooking up wires to wires and noting the resistance (or if they're connected at all). You can see that White is the ground for the bottom trio b/c it has half the resistance to Red or Blue that they have to each other.
(This motor's strange and doesn't have a center tap on the top magnet coil. It's like it's half-bipolar, half-unipolar. Maybe you could use this to sense rotation in the Red-White-Blue coil when the Black-Yellow coil is being driven.)