The no child left behind act specially gives the Military recruiters access to a list of all graduating students. Specific procedure, and individual styles on how to use this list by recruiters vary and vary in consistency as well.
You did the right thing not to answer anything as I believe a recruiter would have been interested in talking to you about your options and not verifying your personal info. I find the best way to identify a legitimate call is to question the caller, provider no info yourself to them, and then use the internet to call them back.
For example: Ask the caller their name or ID number (full name), the name of their company, their specific location, and the address to mail a letter to their company. You can further ask what dept or div the person is in. If after getting all this info you want to answer their questions and talk to them, call them back by looking up the info they gave you on the internet or via the phone book. For example, "what recruiter station are you calling from", "what is the address". Then look that location up and call him or her back.