When the Apple store looks at the warranty, there is a little barcode on the mac that they scan.
It'll have the dude from whom you bought it's name. (sorry about the bad grammar, haha)
You may say "No, I know I'm not (previous owner's name), but I bought it from him on eBay" and show an email to them or something so they don't think that you stole it, just to be safe.